Module containment

Source
Expand description

Exact inside/outside for a point against a closed triangle mesh.

The winding number counts signed crossings of a ray from the point. For a closed surface the count is 1 inside and 0 outside, and the sign carries orientation: an inside-out shell reports -1, which a caller can act on.

Every decision is a certified orient3d sign. No intersection point is constructed, so there is no epsilon to tune and no near-miss to misjudge.

Functionsยง

contains
Whether point lies strictly inside the mesh.
winding_number
Signed number of times the surface wraps point.
winding_number_along
Winding number along a caller-chosen ray direction.