Fixing a notch distortion.

User may assume a notch is not precisely position because of accuracy issue. To
avoid this force search of "real intersection".

--HG--
branch : develop
This commit is contained in:
Roman Telezhynskyi 2018-10-20 22:18:27 +03:00
parent 61ced5d7f5
commit 427d3d48c2

View File

@ -316,6 +316,16 @@ bool FixNotchPoint(const QVector<QPointF> &seamAllowance, const QPointF &notchBa
} }
} }
} }
else
{ // Fixing distortion
QLineF axis = QLineF(notchBase, *notch);
axis.setLength(axis.length() + accuracyPointOnLine * 10);
const QVector<QPointF> points = VAbstractCurve::CurveIntersectLine(seamAllowance, axis);
if (points.size() == 1)
{
*notch = points.first();
}
}
return fixed; return fixed;
} }