http://www.emgu.com
computes the rectification transformations without knowing intrinsic parameters of the cameras and their relative position in space, hence the suffix "Uncalibrated". Another related difference from cvStereoRectify is that the function outputs not the rectification transformations in the object (3D) space, but the planar perspective transformations, encoded by the homography matrices H1 and H2. The function implements the following algorithm [Hartley99].

Namespace: Emgu.CV
Assembly: Emgu.CV (in Emgu.CV.dll) Version: 2.4.2.1777 (2.4.2.1777)

Syntax

C#
public static int cvStereoRectifyUncalibrated(
	IntPtr points1,
	IntPtr points2,
	IntPtr F,
	Size imageSize,
	IntPtr H1,
	IntPtr H2,
	double threshold
)
Visual Basic
Public Shared Function cvStereoRectifyUncalibrated ( _
	points1 As IntPtr, _
	points2 As IntPtr, _
	F As IntPtr, _
	imageSize As Size, _
	H1 As IntPtr, _
	H2 As IntPtr, _
	threshold As Double _
) As Integer
Visual C++
public:
static int cvStereoRectifyUncalibrated(
	IntPtr points1, 
	IntPtr points2, 
	IntPtr F, 
	Size imageSize, 
	IntPtr H1, 
	IntPtr H2, 
	double threshold
)

Parameters

points1
Type: System..::..IntPtr
The array of 2D points
points2
Type: System..::..IntPtr
The array of 2D points
F
Type: System..::..IntPtr
Fundamental matrix. It can be computed using the same set of point pairs points1 and points2 using cvFindFundamentalMat
imageSize
Type: System.Drawing..::..Size
Size of the image
H1
Type: System..::..IntPtr
The rectification homography matrices for the first images
H2
Type: System..::..IntPtr
The rectification homography matrices for the second images
threshold
Type: System..::..Double
If the parameter is greater than zero, then all the point pairs that do not comply the epipolar geometry well enough (that is, the points for which fabs(points2[i]T*F*points1[i])>threshold) are rejected prior to computing the homographies

Return Value

[Missing <returns> documentation for "M:Emgu.CV.CvInvoke.cvStereoRectifyUncalibrated(System.IntPtr,System.IntPtr,System.IntPtr,System.Drawing.Size,System.IntPtr,System.IntPtr,System.Double)"]

Remarks

Note that while the algorithm does not need to know the intrinsic parameters of the cameras, it heavily depends on the epipolar geometry. Therefore, if the camera lenses have significant distortion, it would better be corrected before computing the fundamental matrix and calling this function. For example, distortion coefficients can be estimated for each head of stereo camera separately by using cvCalibrateCamera2 and then the images can be corrected using cvUndistort2

See Also