0

So I am trying to use openCV's solvePNP (with python) for the first time, and I am having some troubles with the inputs. I assume that the image points are just the pixel coordinates, and the object points are a 3d list of points, in the same order, in millimetres.

However, I'm not sure which units the Intrinsic Matrix and the Distortion are in. I read some references to "35mm units", as well as other places which multiply Focal Length with Resolution and divide by Sensor sizes. I'm also not sure how to calculate the distortion values. I assume I can approximate them as 0, but if I do choose to find them, what units will they be/need to be?

  • afaik, intrinsics are in unit [pixel]. If you calibrate the camera yourself, you can choose the units of object points yourself. Same for the object points of solvePnp – Micka Jan 13 '20 at 08:19
  • What do you mean by unit [pixel]? Do you mean in the size of each pixel on the sensor? – Sam Richards Jan 13 '20 at 09:11
  • yes. See https://docs.opencv.org/2.4/modules/calib3d/doc/camera_calibration_and_3d_reconstruction.html with `(u, v) are the coordinates of the projection point in pixels` and `fx, fy are the focal lengths expressed in pixel units.` – Micka Jan 13 '20 at 09:17
  • there is a function `calibrationMatrixValues` which transforms the values to [mm] if you provide the size of the sensor in [mm] – Micka Jan 13 '20 at 09:18

0 Answers0