def set_alpha(self, a):
"""
Set the alpha value for the calibrated camera solution. The
alpha value is a zoom, and ranges from 0 (zoomed in, all pixels
in calibrated image are valid) to 1 (zoomed out, all pixels in
original image are in calibrated image).
"""
cv2.stereoRectify(self.l.intrinsics,
self.l.distortion,
self.r.intrinsics,
self.r.distortion,
self.size,
self.R,
self.T,
self.l.R, self.r.R, self.l.P, self.r.P,
alpha = a)
cv2.initUndistortRectifyMap(self.l.intrinsics, self.l.distortion, self.l.R, self.l.P, self.size, cv2.CV_32FC1,
self.l.mapx, self.l.mapy)
cv2.initUndistortRectifyMap(self.r.intrinsics, self.r.distortion, self.r.R, self.r.P, self.size, cv2.CV_32FC1,
self.r.mapx, self.r.mapy)
calibrator.py 文件源码
python
阅读 34
收藏 0
点赞 0
评论 0
评论列表
文章目录