paroj / pose_calib

Efficient Pose Selection for Interactive Camera Calibration

Home Page:https://www.calibdb.net/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Unable to calibrate fisheye camera

zwn opened this issue · comments

I am not able to get past the position when the pattern should be over the whole screen. I can perfectly align the middle of the picture (9 squares) but the rest is off due to the optics. Does this tool support fisheye cameras?

try varying the distance to camera. The tool does not consider distortion for the first two images, so what you see is not what you get.
The capture is triggered by comparing the overlap (projecting a virtual non-distorted image).

You are using cv2.calibrateCamera at https://github.com/paroj/pose_calib/blob/master/utils.py#L268) but that assumes perspective projection (plus distortion). For fish eye we need cv2.fisheye.calibrate that assumes fish eye projection (plus distortion).

while you will get bad results in border regions (approximating 180°), you should still be able to calibrate a fisheye lens.
Also note that due to some implementation issues even the cv2.fisheye.calibrate gives suboptimal results: opencv/opencv#6801

I'm unable to get past this screen with my 170 degree fisheye camera.
image