Ask Your Question
0

Imgproc.undistort() seems missing in OpenCV4

asked 2019-11-05 19:20:14 -0500

lobsterman gravatar image

Java video app uses

Imgproc.undistort(frameIn,frameout_undist,cameraMatrix,distCoeffs,camUndistortMatrix);

to flatten a radially distorted image with versions up to OpenCV 3.4.3. My upgrade to OpenCV 4.1.1 just broke this call and I cannot find the equivalent function in the new API. I provide the distorted image frameIn, a buffer for the undistorted image frameout_undist, the camera and distance coefficients cameraMatrix and distCoeffs, and the optimal undistortion matrix derived from Calib3d.getOptimalNewCameraMatrix(). I was hoping someone would point me to the approve way to undistort images in Opencv 4.

edit retag flag offensive close merge delete

1 answer

Sort by » oldest newest most voted
1

answered 2019-11-06 00:59:44 -0500

berak gravatar image

updated 2019-11-06 01:03:06 -0500

with opencv4, undistort() is in the calib3d.Calib3d module , not in Ìmgproc

edit flag offensive delete link more
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2019-11-05 19:20:14 -0500

Seen: 28 times

Last updated: Nov 06