Ask Your Question
0

Reproject3D: Where is exactly the origin of the point cloud?

asked 2016-02-25 05:01:58 -0600

GermanDude gravatar image

I am asking which point is the reference point of the Reprojection-Matrix Q or rather the xyz-data. There are to my mind two possible options:

  1. The origin of the xyz-data lies in the optical center of the right of the two physical cameras.

  2. The origin of the xyz-data lies in the optical center of the right virtual and rectified camera. The right camera with horizontal epipolar lines.

The reason why im asking is, that I have with a baseline of ca. 2 inch a constant negative offset in the z-distances data of nearly 1 inch. I have calculated with stereoRectify with CV_CALIB_ZERO_DISPARITY and alpha =1 the rectification maps. When I look at the rectified images, there is a black edge around them. It looks like the cameras are virtually shifted a little bit backwards, possibly exactly 1 inch. If this assumption that the origin is also shifted was true, I had an explanation for the negative offset, because I have measured the distance to the physical camera for comparison, not the virtual camera.

edit retag flag offensive close merge delete

Comments

At first glance, I would say that the origin of the frame is the left rectified camera as Q is computed from cv::stereoRectify and as far as I know, you can only triangulate only if the two cameras are well vertically aligned, the fronto parallel rectification allows to search directly the correspondences in the rows if I have understood correctly.

Eduardo gravatar imageEduardo ( 2016-02-25 08:34:04 -0600 )edit

Thanx for the answer. In my application I swapped the cameras so that the disparity is negative. So the other camera is the reference camera and this is why the origin is in the other camera.

GermanDude gravatar imageGermanDude ( 2016-02-26 10:46:56 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2016-02-29 04:32:24 -0600

GermanDude gravatar image

updated 2016-02-29 04:34:15 -0600

After thinking about it, I assume at the moment, that the origin is the optical center or rather the nodal point of the lens. And the nodal point of the physical and the virtual reference camera lie together. This is why there is in stereoRectify only R1, R2 and no T1, T2 for the virtual camera. The scaling with alpha is then compensated with f in Q. Do you think this is right? An early reply will oblige.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2016-02-25 05:01:58 -0600

Seen: 527 times

Last updated: Feb 29 '16