kicad/libs/kimath/src/geometry
Tomasz Wlostowski 2be352b9f9 geometry: more robust colinearity test in SHAPE_LINE_CHAIN::Simplify()
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 3aed13278d)
2022-06-08 16:13:15 +00:00
..
circle.cpp Wide characterize libs and bitmap2component source. 2022-02-09 09:01:53 -05:00
convex_hull.cpp Pass wxPoint objects by reference instead of on the stack. 2021-07-26 15:35:33 -04:00
direction_45.cpp PNS: Add support for 90-degree corner modes 2021-11-03 02:14:23 +00:00
geometry_utils.cpp Fix incorrect calculation in TransformCircleToPolygon(), only noticeable 2021-06-28 18:51:37 +02:00
poly_grid_partition.cpp POLY_GRID_PARTITION: detect a divide by 0, set a wxASSERT and avoid the crash. 2021-12-08 16:07:11 +01:00
seg.cpp geometry: use dedicated 64-bit integer square root for distance computations 2022-06-08 16:12:59 +00:00
shape.cpp Refactor all math into a new kimath library 2020-01-07 17:12:59 +00:00
shape_arc.cpp SHAPE_ARC::Collide( aSeg ) must check segment end points as candidates 2021-12-14 16:14:56 +00:00
shape_collisions.cpp Wide characterize libs and bitmap2component source. 2022-02-09 09:01:53 -05:00
shape_compound.cpp Added a lot of consts and refactored a few lines 2021-03-08 12:49:48 -08:00
shape_file_io.cpp More NULL expunging. 2021-07-18 14:31:55 -04:00
shape_line_chain.cpp geometry: more robust colinearity test in SHAPE_LINE_CHAIN::Simplify() 2022-06-08 16:13:15 +00:00
shape_poly_set.cpp Initialize area check 2022-05-26 08:20:15 -07:00
shape_rect.cpp geometry: SHAPE_RECT: use SquaredDistance() for collision detection 2020-10-07 16:36:37 +02:00
shape_segment.cpp geometry: SHAPE::Format() now outputs C-like code for easy test cases... 2020-10-07 16:36:37 +02:00