Skip to main content

segment_intersection

Function segment_intersection 

Source
pub fn segment_intersection(
    a1: Point2,
    a2: Point2,
    b1: Point2,
    b2: Point2,
) -> SegmentIntersection
Expand description

Compute the intersection of two 2D line segments using filtered predicates.

Handles all degeneracies: T-intersections, endpoint-on-segment, collinear overlap, and parallel/disjoint segments.

Uses filtered_orient2d for robust classification.