disp_caltab ( : : CalTabDescrFile, CamParam, CamPose, ScaleFac : )

Project and visualize the 3D model of the calibration table in the image.

disp_caltab is used to visualize the calibration marks and the connecting lines between the marks of the used calibration table (CalTabDescrFile) in the actual output window. Thus, the 3D model of the calibration table is projected into the image plane using the internal camera parameters (CamParam) and the camera pose (external camera parameters (CamPose). The underlying camera model (pinhole camera with radial distortion) is described in write_cam_par.

Typically disp_caltab is used to verificate the result of the camera calibration (see camera_calibration) by superimposing it onto the original image. The actual linewidth can be set by set_line_width, the actual color can be set by set_color.

The parameter ScaleFac influences the number of supporting points to approximate the elliptic contours of the calibration marks. You should increase the number of supporting points, if the image part in the actual output window is displayed with magnification (see set_part).


Parameters

CalTabDescrFile (input_control)
string -> string
File name of the calibration table description.
Default value: 'caltab.descr'

CamParam (input_control)
number-array -> real / integer
Internal camera parameters.
Number of elements: 8

CamPose (input_control)
number-array -> real / integer
External camera parameters.
Number of elements: 7

ScaleFac (input_control)
real -> real
Scaling factor for the visualization.
Default value: 1.0
Suggested values: 0.5, 1.0, 2.0, 3.0
Recommended increment: 0.05
Restriction: 0.0 < ScaleFac


Example
/* read calibration image */
read_image(:Image1:'calib-01.tiff':) >
/* find calibration pattern */
find_caltab(Image1:Caltab1:'caltab.descr',3,112:) >
/* find calibration marks and start poses */
find_marks_and_pose(Image1,Caltab1::'caltab.descr',[0.008,0.0,
  0.000011,0.000011,384,288,768,576],128,10:RCoord1,CCoord1,StartPose1) >
/* read 3D positions of calibration marks */
caltab_points(::'caltab.descr':NX,NY,NZ) >
/* camera calibration */
camera_calibration(::NX,NY,NZ,RCoord1,CCoord1,
  [0.008,0.0,0.000011,0.000011,384,288,768,576],
  StartPose1,11:CamParam,FinalPose,Errors) >
/* visualize calibration result */
disp_image(Image1:::) >
set_color(::'red':) >
disp_caltab(::'caltab.descr',CamParam,FinalPose,1.0:).

Result

disp_caltab returns TRUE if all parameter values are correct. If necessary an exception is raised.


Possible Predecessors

camera_calibration, read_cam_par, read_cam_pose


See also

find_marks_and_pose, camera_calibration, sim_caltab, write_cam_par, read_cam_par, write_cam_pose, read_cam_pose, project_3d_point, inverse_project_pixel



Copyright © 1996-1997 MVTec Software GmbH