本文介绍了鱼眼镜头校准的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在进行鱼眼镜头相机校准,但未获得预期的结果,也不知道哪里出了问题.我是这个相机校准的新手.

I am working on Fisheye camera calibration, and I'm not getting the expected result and I don't know where I'm wrong. I'm new to this camera calibration.

我的校准参数

Focal Length:          fc = [ 410.7476   408.0925 ]
Principal point:       cc = [ 369.3690   299.0193 ]
Skew:             alpha_c = [ 0.8336 ]
Fisheye Distortion:    kc = [ -0.3726   0.0931   0.0107   0.0000 ]

我要取消扭曲的代码:

fisheye::estimateNewCameraMatrixForUndistortRectify(intrinsic, distCoeffs, input.size(), Matx33d::eye(), newK, 1);
fisheye::undistortImage(input, output, intrinsic, distCoeffs, newK, input.size());//Size(640,360));

这是我的输入图片:

这是我得到的输出:

推荐答案

在完全不使用fisheye::estimateNewCameraMatrixForUndistortRectify()fisheye::undistortImage()的情况下,在使鱼眼图像不失真的情况下获得良好的效果是可能的.通过fisheye::calibrate()获得K(相机矩阵)和D(失真系数)后,可以将它们直接放入initUndistortRectifyMap().这将通过cv::remap()

It's possible to get good results in undistortion of fisheye image without using fisheye::estimateNewCameraMatrixForUndistortRectify() and fisheye::undistortImage() at all.After obtaining K (camera matrix) and D (distortion coeffs) via fisheye::calibrate(), you can put them directly to initUndistortRectifyMap(). This will produce maps for undistorted image production via cv::remap()

这篇关于鱼眼镜头校准的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

07-26 00:20