Updated by Kirill Kornyakov almost 13 years ago

The documentation states that points returned in @OutputArray dst@ will be in pixels coordinates but they are actually in normalized image coordinates.

<pre>
//
@// (u,v) is the input point, (u', v') is the output point
// camera_matrix=[fx 0 cx; 0 fy cy; 0 0 1]
// P=[fx' 0 cx' tx; 0 fy' cy' ty; 0 0 1 tz]
x" = (u - cx)/fx
y" = (v - cy)/fy
(x',y') = undistort(x",y",dist_coeffs)
[X,Y,W]T = R*[x' y' 1]T
x = X/W, y = Y/W

------------------------------------------------------------------
THIS STEP IS NOT PERFORMED INSIDE THIS FUNCTION
-----------------------------------------------------------------
u' = x*fx' + cx'
v' = y*fy' + cy'
</pre>
@

Back