Skip to main content

Import

signedAreaXZ

Shoelace area on the XZ plane.

ringAreaXZ

Absolute (unsigned) shoelace area of the ring.

perimeterXZ

Sum of edge lengths around the (implicitly closed) ring.

areaCentroidXZ

Area-weighted centroid (shoelace formula).

centroidXZ

Average of all points.

pointInPolygonXZ

Crossing-number point-in-polygon test on the XZ plane.

ringsOverlap

True if any vertex of one ring lies inside the other, OR any pair of edges crosses.

ringStrictlyInside

True if every vertex of inner lies inside outer AND no edge of inner crosses any edge of outer.

isConvexXZ

True when every turn around the ring has the same sign (collinear runs allowed).

distancePointToSegmentXZ

Distance from p to the segment a→b (clamped to the segment).

ringDistanceXZ

Minimum distance between two rings’ boundaries: 0 when they overlap or touch, else the closest vertex-to-edge approach in either direction.

offsetRingOutwardXZ

Offset every edge of the ring outward (away from the interior) by distance, rebuilding vertices as miter intersections of adjacent offset edges.

rotatePointsXZ

Rotate every point around anchor by angleRad (right-handed about +Y, i.e.

translatePointsXZ

Translate every point.

validateAndNormalizeProfile

Validate, dedupe/auto-close, and normalize winding of a polygon profile.

clonePolygonProfile

Deep-clone a profile so caller mutations don’t bleed into element state.

Types

PolygonProfile

Closed polygon profile in the world XZ plane.

NormalizedPolygonProfile

Winding

PointXZ

Last modified on October 6, 2026