Commit Graph

3 Commits

Author SHA1 Message Date
John Beard ce84c19a38 QA: Test arc to polylines - this has a bug
Add unit test of SHAPE_ARC::ConvertToPolyline.

This function has a bug when the arc is of zero radius. This
test shows the bug, but does not fix it yet.
2019-04-17 10:52:56 +01:00
John Beard d6f4f3aca0 Geom: Account for quadrant points in arc bbox calc
This means arcs that pass though quadrant points (multiple of
0, 90, 180, 270 degrees) include these points in the bbox.
2019-01-10 07:52:25 -05:00
John Beard dc71a73178 QA: Add unit test of SHAPE_ARC
Test a few "centre-point-angle" cases and add some
generic geom code for testing vectors and boxes are within
tolerance (since rounding often creeps in).

Much of the arc-checking code will be useful to other
construction methods (e.g. point-point-point).

There are expected failures for the bbox code when
the arc passes though, but does not end on, a quadrant point
(0, 90, 180, 270). This is due to a defective
implementation of SHAPE_ARC::BBox() that does not take
into account the quadrant points. This will be fixed
as a follow-up.
2019-01-10 07:52:25 -05:00