Click or drag to resize

Cv2RecoverPose Method (InputArray, InputArray, InputArray, InputArray, OutputArray, OutputArray, InputOutputArray)

Recover relative camera rotation and translation from an estimated essential matrix and the corresponding points in two images, using cheirality check. Returns the number of inliers which pass the check.

Namespace:  OpenCvSharp
Assembly:  OpenCvSharp (in OpenCvSharp.dll) Version: 1.0.0
Syntax
public static int RecoverPose(
	InputArray E,
	InputArray points1,
	InputArray points2,
	InputArray cameraMatrix,
	OutputArray R,
	OutputArray t,
	InputOutputArray mask = null
)

Parameters

E
Type: OpenCvSharpInputArray
The input essential matrix.
points1
Type: OpenCvSharpInputArray
Array of N 2D points from the first image. The point coordinates should be floating-point (single or double precision).
points2
Type: OpenCvSharpInputArray
Array of the second image points of the same size and format as points1.
cameraMatrix
Type: OpenCvSharpInputArray
Camera matrix K=⎡⎣⎢fx000fy0cxcy1⎤⎦⎥ . Note that this function assumes that points1 and points2 are feature points from cameras with the same camera matrix.
R
Type: OpenCvSharpOutputArray
Recovered relative rotation.
t
Type: OpenCvSharpOutputArray
Recovered relative translation.
mask (Optional)
Type: OpenCvSharpInputOutputArray
Input/output mask for inliers in points1 and points2. : If it is not empty, then it marks inliers in points1 and points2 for then given essential matrix E. Only these inliers will be used to recover pose. In the output mask only inliers which pass the cheirality check. This function decomposes an essential matrix using decomposeEssentialMat and then verifies possible pose hypotheses by doing cheirality check. The cheirality check basically means that the triangulated 3D points should have positive depth.

Return Value

Type: Int32

[Missing <returns> documentation for "M:OpenCvSharp.Cv2.RecoverPose(OpenCvSharp.InputArray,OpenCvSharp.InputArray,OpenCvSharp.InputArray,OpenCvSharp.InputArray,OpenCvSharp.OutputArray,OpenCvSharp.OutputArray,OpenCvSharp.InputOutputArray)"]

See Also