Ask Your Question

How to convert stereo camera distances, pixels to mm [closed]

asked 2020-09-21 06:31:18 -0500

yoshihiko gravatar image


I calibrated and stereo-parallelized the stereo camera.I would like to know how to find the coefficient to convert from pixels to mm.

From the Q matrix obtained by stereo rectification, Tx: baseline and f: focal length were determined. As you know, the depth z is found by the following formula

z = Bf/(x-x') z:[pixels]

However, the units of z obtained from this formula are pixels. A factor k[mm/pixel] is needed to convert it to mm. Then the equation is as follows

z = (Bf/(x-x'))*k z:[mm]

Is there a smart way to find this coefficient k? Please use something other than how to actually measure z several times to derive k, or how to examine the pitch pixels of the camera's image sensor.

In the case of HALCON, I was able to find it by a function instead of using the method described above.

Couldn't it be calculated from the camera and Q matrices obtained from calibration and stereo parallelization? Thank you.

image description

image description

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by yoshihiko
close date 2020-09-26 17:45:01.852004


Eduardo gravatar imageEduardo ( 2020-09-26 09:00:45 -0500 )edit

1 answer

Sort by ยป oldest newest most voted

answered 2020-09-26 17:43:25 -0500

yoshihiko gravatar image

I didn't know there was such a useful function. Thank you.

edit flag offensive delete link more

Question Tools

1 follower


Asked: 2020-09-21 06:31:18 -0500

Seen: 241 times

Last updated: Sep 26 '20