Ask Your Question
0

fisheye::undistortPoints() missing to apply camera matrix

asked 2016-07-19 10:40:32 -0600

MrBrown gravatar image

Well - using fisheye::undistortPoints() for transforming captured pixel coordinates to the 'planar domain', ends up with result coordinates in the range -1..+1, when applying the camera matrix to this points I get the correct results. I'm wondering if this is the intended behavior?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2016-07-19 13:44:36 -0600

With the regular undistortPoints function you have to pass your camera matrix as the P parameter in addition to passing it as the K parameter to convert the coordinates from -1..+1 back to pixels. I imagine fisheye::undistortPoints works the same way.

void fisheye::undistortPoints(InputArray distorted, OutputArray undistorted, InputArray K, InputArray D, InputArray R=noArray(), InputArray P=noArray())

Here's how I call it:

undistortPoints(thePoints, undistortedPoints, _cameraMatrix, _distortionCoefficients, noArray(), _cameraMatrix);
edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2016-07-19 10:40:32 -0600

Seen: 273 times

Last updated: Jul 19 '16