Computes all intersection points between two polygons.
Iterates over each edge of polygonA and checks against polygonB using intersectLinePolygon. Removes duplicates. Also detects corner–corner touches.
polygonA
polygonB
First polygon
Second polygon
Array of intersection points (empty if none found)
Computes all intersection points between two polygons.
Iterates over each edge of
polygonA
and checks againstpolygonB
using intersectLinePolygon. Removes duplicates. Also detects corner–corner touches.