[][src]Function opencv::calib3d::init_camera_matrix_2d

pub fn init_camera_matrix_2d(
    object_points: &dyn ToInputArray,
    image_points: &dyn ToInputArray,
    image_size: Size,
    aspect_ratio: f64
) -> Result<Mat>

Finds an initial camera matrix from 3D-2D point correspondences.

Parameters

  • objectPoints: Vector of vectors of the calibration pattern points in the calibration pattern coordinate space. In the old interface all the per-view vectors are concatenated. See calibrateCamera for details.
  • imagePoints: Vector of vectors of the projections of the calibration pattern points. In the old interface all the per-view vectors are concatenated.
  • imageSize: Image size in pixels used to initialize the principal point.
  • aspectRatio: If it is zero or negative, both inline formula and inline formula are estimated independently. Otherwise, inline formula .

The function estimates and returns an initial camera matrix for the camera calibration process. Currently, the function only supports planar calibration patterns, which are patterns where each object point has z-coordinate =0.

C++ default parameters

  • aspect_ratio: 1.0