Attention! This forum will be made read-only by Dec-20. Please migrate to https://forum.opencv.org. Most of existing active users should've received invitation by e-mail.
Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Your code looks right. However, to estimate an affine transformation you need at least 3 points, but if these points are all aligned, there is an infinity of solutions, which seems to lead the estimation to result in a degenerate solution.

Although that might no longer be true as you set fullAffine to false, perhaps the function is implemented in such a way that it still needs points that are not aligned. But that is a supposition.

What is the result if you add another point? For example:

obj1.push_back(Point2f(0, 0));
scene1.push_back(Point2f(10, 10));