Find epipolar lines from fundamental matrix

7.4k Views Asked by At

I have two sets of 2D points and a matching between them (correspond to the same 3D points captured on two photographs). I found a fundamental matrix F.

I would like to find epipolar lines. I.e. in each photo, I want to draw a line from each point to the coordinate of the opposite camera projected to that photo. How do I find a 2D coordinate of a camera? Or any second point on each epipolar line?

I found only implementations, which call epipolarLine() in Matlab, or computeCorrespondEpilines() in OpenCV. But I would like to compute it myself without any libraries. I can already compute singular value decomposition.

The F is

 0.0000076735   0.0000065266  -0.0026484181
-0.0000077379   0.0000190241   0.0003274198
-0.0024171562  -0.0038670395   1.0000000000

and one matched pair is $231.9210, 100.3261$ and $289.8867, 29.6767$.

1

There are 1 best solutions below

6
On BEST ANSWER

You can find the answer to this in any standard reference, such as Hartley and Zisserman’s Multiple View Geometry In Computer Vision, chapter 9.

The fundamental matrix $\mathtt F$ maps a point to its corresponding epipolar line in the other image. Thus, the epipolar line in the second image of a point $\mathbf x$ in the first image is $\mathbf l'=\mathtt F\mathbf x$ and, going the other way, $\mathbf l=\mathtt F^T\mathbf x'$. The epipoles themselves are right and left null vectors, respectively, of $\mathtt F$, i.e., $\mathtt F\mathbf e=0$ and $\mathtt F^T\mathbf e'=0$.