For every point in one of the two images of stereo-pair the function cvComputeCorrespondEpilines finds equation of a line that contains the corresponding point (i.e. projection of the same 3D point) in the other image. Each line is encoded by a vector of 3 elements l=[a,b,c]^T, so that:
l^T*[x, y, 1]^T=0, or
a*x + b*y + c = 0
From the fundamental matrix definition (see cvFindFundamentalMatrix discussion), line l2 for a point p1 in the first image (which_image=1) can be computed as:
l2=F*p1 and the line l1 for a point p2 in the second image (which_image=1) can be computed as:
l1=F^T*p2Line coefficients are defined up to a scale. They are normalized (a2+b2=1) are stored into correspondent_lines
Namespace: Emgu.CVAssembly: Emgu.CV (in Emgu.CV.dll) Version: 2.2.1.1150 (2.2.1.1150)
Syntax
C# | Visual Basic | Visual C++ |
Parameters
- points
- IntPtr
The input points. 2xN, Nx2, 3xN or Nx3 array (where N number of points). Multi-channel 1xN or Nx1 array is also acceptable.
- whichImage
- Int32
Index of the image (1 or 2) that contains the points
- fundamentalMatrix
- IntPtr
Fundamental matrix
- correspondentLines
- IntPtr
Computed epilines, 3xN or Nx3 array