Commit b47c9ac6 authored by logic1988's avatar logic1988 Committed by heqian

Update aff_trans.cpp

When the fullAffine parameter is set to false, the estimateRigidTransform function maybe return empty, then the _localAffineEstimate function will be called, but the bug in it will result in incorrect results.
parent 6700fdb8
......@@ -165,8 +165,8 @@ static Mat _localAffineEstimate(const std::vector<Point2f>& shape1, const std::v
}
else
{
therow.at<float>(0,0)=-shape1[contPt].y;
therow.at<float>(0,1)=shape1[contPt].x;
therow.at<float>(0,0)=shape1[contPt].y;
therow.at<float>(0,1)=-shape1[contPt].x;
therow.at<float>(0,3)=1;
therow.row(0).copyTo(matM.row(ii));
matP.at<float>(ii,0) = shape2[contPt].y;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment