Ask Your Question

MarcelDebout's profile - activity

2016-11-10 22:19:17 -0600 received badge  Teacher (source)
2015-07-24 08:03:31 -0600 received badge  Necromancer (source)
2015-05-20 10:21:54 -0600 answered a question Difference between undistort and initUndistortRectifyMap+remap?

Hey FooBar!

I figured out, that changing the line:

initUndistortRectifyMap(camm, dist, Mat(), newCamMatrix, Size(img.cols,img.rows),CV_32FC1,map1,map2);

to

initUndistortRectifyMap(camm, dist, Mat(), camm, Size(img.cols,img.rows), CV_32FC1, map1, map2);

should solve your problem.

The funciton

initUndistortRectifyMap

offers you to apply a transformation. The translation is given by the c_x and c_y values of your camera matrix.

2015-05-20 04:56:13 -0600 received badge  Supporter (source)