Function opencv::sfm::reconstruct_1_def

source ·
pub fn reconstruct_1_def(
    points2d: &impl ToInputArray,
    rs: &mut impl ToOutputArray,
    ts: &mut impl ToOutputArray,
    k: &mut impl ToInputOutputArray,
    points3d: &mut impl ToOutputArray
) -> Result<()>
Expand description

Reconstruct 3d points from 2d correspondences while performing autocalibration.

§Parameters

  • points2d: Input vector of vectors of 2d points (the inner vector is per image).
  • Rs: Output vector of 3x3 rotations of the camera.
  • Ts: Output vector of 3x1 translations of the camera.
  • points3d: Output array with estimated 3d points.
  • K: Input/Output camera matrix inline formula. Input parameters used as initial guess.
  • is_projective: if true, the cameras are supposed to be projective.

Internally calls libmv simple pipeline routine with some default parameters by instatiating SFMLibmvEuclideanReconstruction class.

Note:

  • Tracks must be as precise as possible. It does not handle outliers and is very sensible to them.
  • To see a working example for camera motion reconstruction, check the following tutorial: [tutorial_sfm_trajectory_estimation].

§Note

This alternative version of reconstruct_1 function uses the following default values for its arguments:

  • is_projective: false