ClassesClassesClassesClasses | | | | Operators

cam_par_to_cam_matT_cam_par_to_cam_matCamParToCamMatcam_par_to_cam_matCamParToCamMatCamParToCamMat (Operator)

Name

cam_par_to_cam_matT_cam_par_to_cam_matCamParToCamMatcam_par_to_cam_matCamParToCamMatCamParToCamMat — Compute a camera matrix from internal camera parameters.

Signature

cam_par_to_cam_mat( : : CameraParam : CameraMatrix, ImageWidth, ImageHeight)

Herror T_cam_par_to_cam_mat(const Htuple CameraParam, Htuple* CameraMatrix, Htuple* ImageWidth, Htuple* ImageHeight)

Herror cam_par_to_cam_mat(const HTuple& CameraParam, HTuple* CameraMatrix, HTuple* ImageWidth, HTuple* ImageHeight)

void CamParToCamMat(const HTuple& CameraParam, HTuple* CameraMatrix, HTuple* ImageWidth, HTuple* ImageHeight)

void HHomMat2D::CamParToCamMat(const HTuple& CameraParam, Hlong* ImageWidth, Hlong* ImageHeight)

void HOperatorSetX.CamParToCamMat(
[in] VARIANT CameraParam, [out] VARIANT* CameraMatrix, [out] VARIANT* ImageWidth, [out] VARIANT* ImageHeight)

Hlong HHomMat2DX.CamParToCamMat(
[in] VARIANT CameraParam, [out] Hlong* ImageHeight)

static void HOperatorSet.CamParToCamMat(HTuple cameraParam, out HTuple cameraMatrix, out HTuple imageWidth, out HTuple imageHeight)

void HHomMat2D.CamParToCamMat(HTuple cameraParam, out int imageWidth, out int imageHeight)

Description

cam_par_to_cam_matcam_par_to_cam_matCamParToCamMatcam_par_to_cam_matCamParToCamMatCamParToCamMat computes the camera matrix CameraMatrixCameraMatrixCameraMatrixCameraMatrixCameraMatrixcameraMatrix as well as the image width ImageWidthImageWidthImageWidthImageWidthImageWidthimageWidth, and the image height ImageHeightImageHeightImageHeightImageHeightImageHeightimageHeight from the internal camera parameters CameraParamCameraParamCameraParamCameraParamCameraParamcameraParam. The internal camera parameters CameraParamCameraParamCameraParamCameraParamCameraParamcameraParam can be determined with camera_calibrationcamera_calibrationCameraCalibrationcamera_calibrationCameraCalibrationCameraCalibration. cam_par_to_cam_matcam_par_to_cam_matCamParToCamMatcam_par_to_cam_matCamParToCamMatCamParToCamMat converts this representation of the internal camera parameters into the representation used by stationary_camera_self_calibrationstationary_camera_self_calibrationStationaryCameraSelfCalibrationstationary_camera_self_calibrationStationaryCameraSelfCalibrationStationaryCameraSelfCalibration. The conversion can only be performed if the camera is an area scan pinhole camera and the distortion coefficients in CameraParamCameraParamCameraParamCameraParamCameraParamcameraParam are 0. If necessary, change_radial_distortion_cam_parchange_radial_distortion_cam_parChangeRadialDistortionCamParchange_radial_distortion_cam_parChangeRadialDistortionCamParChangeRadialDistortionCamPar must be used to set the distortion coefficients to 0.

Parallelization

Parameters

CameraParamCameraParamCameraParamCameraParamCameraParamcameraParam (input_control)  number-array HTupleHTupleHTupleVARIANTHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong) (double / Hlong) (double / Hlong)

Internal camera parameters.

Number of elements: CameraParam == 8 || CameraParam == 12

CameraMatrixCameraMatrixCameraMatrixCameraMatrixCameraMatrixcameraMatrix (output_control)  hom_mat2d HHomMat2D, HTupleHTupleHTupleHHomMat2DX, VARIANTHtuple (real) (double) (double) (double) (double) (double)

3x3 projective camera matrix that corresponds to CameraParamCameraParamCameraParamCameraParamCameraParamcameraParam.

ImageWidthImageWidthImageWidthImageWidthImageWidthimageWidth (output_control)  extent.x HTupleHTupleHTupleVARIANTHtuple (integer) (int / long) (Hlong) (Hlong) (Hlong) (Hlong)

Width of the images that correspond to CameraMatrixCameraMatrixCameraMatrixCameraMatrixCameraMatrixcameraMatrix.

Assertion: ImageWidth > 0

ImageHeightImageHeightImageHeightImageHeightImageHeightimageHeight (output_control)  extent.y HTupleHTupleHTupleVARIANTHtuple (integer) (int / long) (Hlong) (Hlong) (Hlong) (Hlong)

Height of the images that correspond to CameraMatrixCameraMatrixCameraMatrixCameraMatrixCameraMatrixcameraMatrix.

Assertion: ImageHeight > 0

Example (HDevelop)

* For the input data to camera_calibration, please refer to the
* example for camera_calibration.
camera_calibration (X, Y, Z, Rows, Cols, StartCamParam, StartPoses, \
                    ['all','~kappa'], CameraParam, FinalPoses, Errors)
cam_par_to_cam_mat (CameraParam, CameraMatrix, ImageWidth, ImageHeight)

* Alternatively, the following calls can be used.
camera_calibration (X, Y, Z, Rows, Cols, StartCamParam, StartPoses, \
                    'all', CameraParam, FinalPoses, Errors)
change_radial_distortion_cam_par ('adaptive', CameraParam, 0, CamParamOut)
cam_par_to_cam_mat (CamParamOut, CameraMatrix, ImageWidth, ImageHeight)

Result

If the parameters are valid, the operator cam_par_to_cam_matcam_par_to_cam_matCamParToCamMatcam_par_to_cam_matCamParToCamMatCamParToCamMat returns the value 2 (H_MSG_TRUE). If necessary an exception is raised.

Possible Predecessors

camera_calibrationcamera_calibrationCameraCalibrationcamera_calibrationCameraCalibrationCameraCalibration

See also

stationary_camera_self_calibrationstationary_camera_self_calibrationStationaryCameraSelfCalibrationstationary_camera_self_calibrationStationaryCameraSelfCalibrationStationaryCameraSelfCalibration, cam_mat_to_cam_parcam_mat_to_cam_parCamMatToCamParcam_mat_to_cam_parCamMatToCamParCamMatToCamPar

Module

Calibration


ClassesClassesClassesClasses | | | | Operators