Using Calib GEOM parameters in OpenCV¶
Choose the OpenCV camera model in Calib GEOM, complete the calibration, and select Calibration → Export Parameters.
The libCalibGeom documentation provides integration examples for reading the export and obtaining camera matrices, distortion coefficients, and camera extrinsics.
libCalibGeom is a separate product and is not included with Calib GEOM. The C++ parameter-reader example requires libCalibGeom; the Python example uses OpenCV and NumPy without requiring libCalibGeom.
The C++ example runs as:
opencv_parameters calibration.json
The Python example undistorts an image:
python opencv_parameters.py calibration.json image.png
See the libCalibGeom documentation for example setup and build instructions.
Compatibility¶
Direct conversion applies to Calib GEOM's OpenCV model. OpenCV Fisheye and other Calib GEOM models use different projection functions and must not be used with OpenCV's standard distortion functions by copying coefficients.
For models your application does not support, consider distortion maps or unprojection maps.
Integration reference¶
The focal lengths are fx = f and fy = f × ar. The principal point is
(cx, cy). All four are in pixels and use OpenCV's zero-based image coordinates.
The full distortion vector uses this order:
[k1, k2, p1, p2, k3, k4, k5, k6, s1, s2, s3, s4, tauX, tauY]
Check that the OpenCV function you use supports the required terms. The supplied readers preserve all stored values, including fixed and disabled parameters.
Camera extrinsics map from the first camera to the selected camera. They are not the target pose in each image. Check transform direction when using stereo or projection functions. See Exporting calibration parameters for units and coordinate conventions.