Skip to content

Commit 24baeaa

Browse files
authored
Fix omnidir::undistortPoints
The relevant bug was reported in opencv#1612 The _xi was erroneously applied at points re-projection to camera plane. _xi parameter was already taken in use while projection of points to unit sphere.
1 parent 4e85f8c commit 24baeaa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/ccalib/src/omnidir.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -330,7 +330,7 @@ void cv::omnidir::undistortPoints( InputArray distorted, OutputArray undistorted
330330
Vec3d Xs = Xw / cv::norm(Xw);
331331

332332
// reproject to camera plane
333-
Vec3d ppu = Vec3d(Xs[0]/(Xs[2]+_xi), Xs[1]/(Xs[2]+_xi), 1.0);
333+
Vec3d ppu = Vec3d(Xs[0]/Xs[2], Xs[1]/Xs[2], 1.0);
334334
if (undistorted.depth() == CV_32F)
335335
{
336336
dstf[i] = Vec2f((float)ppu[0], (float)ppu[1]);

0 commit comments

Comments
 (0)