gis-tools-ts - v0.6.0
    Preparing search index...

    Function intersectionOfSegments

    • Find the intersection of two segments

      NOTE: Segments that are only touching eachothers endpoints are considered intersections

      Type Parameters

      • D extends Properties = Properties

      Parameters

      • a: [VectorPoint<D>, VectorPoint<D>]

        the first segment

      • b: [VectorPoint<D>, VectorPoint<D>]

        the second segment

      Returns undefined | IntersectionOfSegments<D>

      A point if the segments intersect where the intersection occurs, otherwise undefined