Search code examples
c++opencvcomputational-geometry

How to get the angle of correction in ORB detection OpenCV ++?


// Find homography

h = findHomography( points1, points2, RANSAC );

// Use homography to warp image

warpPerspective(im1, im1Reg, h, im2.size());

I see here that the output image is warped but I wanted to know by how much the angle is changed with respect to the input image?


Solution

  • What angle?

    Perspective changing would not be defined with a simple rotation. That angle you are looking for, exists in Euclidean (rigid) transformation which preserves the euclidean distance between every pair of points.