Skip to main content

Module calibrate

Module calibrate 

Source
Expand description

Pure-Rust camera calibration (port of OpenCV cv::calibrateCamera).

Built bottom-up:

  1. per-view homography estimation (find_homography),
  2. initial intrinsics (init_intrinsics),
  3. initial extrinsics per view (init_extrinsics),
  4. joint Levenberg-Marquardt refinement of intrinsics, distortion, and extrinsics (calibrate_camera).

Structs§

CalibrationResult
Result of calibrate_camera.
CorrespondingPoint
One object<->image correspondence. The object point must be planar (z == 0) for the homography-based initialization.
Extrinsics
Camera pose of the target plane relative to the camera.
InitialIntrinsics
Initial pinhole intrinsics (fx, fy, cx, cy).

Enums§

CalibrateError

Functions§

calibrate_camera
Calibrate a pinhole+distortion camera from planar-target correspondences.
find_homography
Estimate the homography H mapping src points to dst points so that dst ~ H * src (in homogeneous coordinates), normalized to H[(2,2)] = 1.
init_extrinsics
Recover the pose for one view from intrinsics k and homography h.
init_intrinsics
Estimate initial intrinsics from per-view homographies and the image size.