Geometry · function
solidVolume
The enclosed volume by the divergence theorem: the sum of each triangle's signed tetrahedron with the origin. Positive for a closed, outward-wound solid; meaningless for an open one.
Explained in Hello world, Meshes and geometry.
function solidVolume(solid: Solid): numberimport { solidVolume } from '@driftengine/core';Parameters
| Parameter | Type | Description |
|---|---|---|
solid | Solid |
In depth
Exact for any closed surface, T-junctions included, which is why the CSG tests can use it on a boolean's output where an edge-pairing check cannot.