Expand description
Shared edge detection and collinear contact classification. Ported from polygon.move::has_exact_shared_edge, edges_match_exactly, segments_contact, and shared_edge_relation.
Used for topology validation (parts must connect via shared edges, not just vertices, and partial collinear contact is rejected as a T-junction).
Enums§
- Contact
Kind - Classification of how two polygon parts touch along their boundaries.
Functions§
- classify_
contact - Classify the contact between two polygon parts.
- has_
exact_ shared_ edge - True if polygon A and polygon B share at least one exact edge. An “exact shared edge” is an edge (v_i, v_{i+1}) that appears in both polygons, possibly in reverse order.
- segments_
contact - True if two line segments are collinear and overlap along a non-degenerate interval. Contact means: parallel, collinear, and 1D intervals strictly overlap. Touching at a single endpoint is NOT contact (strict overlap required).