简体   繁体   中英

what is the unit of “focal length = 1.0” in findEssentialMat (openCV)?

Recently I tried to calculate essential matrix by findEssentialMat function in openCV ( https://docs.opencv.org/master/d9/d0c/group__calib3d.html#ga13f7e34de8fa516a686a56af1196247f ) I noticed that the parameter focal length=1.0 and pp=(0,0) by default, but what is the unit of these two values, m/mm/pixels?

Furthermore, shouldn't the principal point at the image center, ie (h/2,w/2) in pixel coordinates or (0.5,0.5) in normalized coordinates?

Micka is already right in his comment. The camera model of OpenCV is eg illustrated here . As you can see the image coordinate system is defined such that the x-axis points to the right and the y-axis points down. The origin is at the image center (where the optical axis z intersects the image plane) and that is why the default value for the principal point is (0px,0px) . This is a standard coordinate system definition in Computer Vision and eg Matlab uses the same.

The focal length is set to 1.0 px because if your camera is not calibrated you can still calculate eg the Essential Matrix and the math gets easier.

If you want to use your camera matrix for a 3D reconstruction you should definitely calibrate your camera or insert appropriate values for focal length (and principal point). Theoretically, you can convert the pixel system to a metric system if you know the sensor size.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM