We now test the midpoint (B) of the 3 consecutive polyline points (A, B, C), since (assuming the angle between AB and BC is > 90 degrees) AC is always longer than
AB or BC. This minimizes the distance computation rounding error (in the previous algorithm, taking the point C for colineraity test) if AB is short and BC is very long, the test would
often fail due to rouding error in projection/line distance computation
(cherry picked from commit
|
||
---|---|---|
.. | ||
geometry | ||
math | ||
bezier_curves.cpp | ||
convert_basic_shapes_to_polygon.cpp | ||
md5_hash.cpp | ||
trigo.cpp |