Triangle soup for one source SceneObject. May span multiple SceneMeshes; their triangles are concatenated into a single polygon for placement.
Projection basis used to flatten world positions to (u, v).
Number of grid cells along the longer
side of the polygon's AABB. Default 32. Increase to push
placement accuracy closer to the inscribed circle's true
centre at the cost of O(N²) more samples.
Approximate the pole-of-inaccessibility for a triangle-soup polygon, returned in projection-basis (u, v) space.
Strategy:
(right, up)plane, building a u/v point list parallel to the original triangle indices.This is a coarse-grid approximation of the recursive subdivision used in Mapbox's
polylabel— accurate to one cell at the chosen grid resolution, which is sub-decimetre at the default 32×32 grid on a typical 5–15 m room. Fine for label placement; not fine enough to drive a CAM tool.Returns
nullwhen the polygon has no boundary edges (every edge was shared by two triangles — degenerate input) or no grid sample landed inside.