Skip to content

Shapemetry API


Shapemetry API / TriangulationOptions

Interface: TriangulationOptions

Defined in: polyShape/triangulation/triangulate.ts:20

Properties

holes?

optional holes?: Point2d[][]

Defined in: polyShape/triangulation/triangulate.ts:22

Inner loops that punch holes in contour. Each must be a simple polygon.


steinerPoints?

optional steinerPoints?: Point2d[]

Defined in: polyShape/triangulation/triangulate.ts:24

Additional interior points to include as triangulation vertices.


constraintEdges?

optional constraintEdges?: [Point2d, Point2d][]

Defined in: polyShape/triangulation/triangulate.ts:32

Segments whose endpoints lie among (contour ∪ holes.flat() ∪ steinerPoints) that must appear as triangulation edges. Used by co-refinement to force intersection segments to be honored — without this, the CDT picks arbitrary diagonals and adjacent triangulations produce T-junctions along shared cuts.