Non-negative distance from point to a BoundsShape — 0 when the point is
inside or on the shape. Precedence when several are set: sphere > box >
position; returns Infinity when none is provided. Pure math (no rendering
dependencies), so it can drive level-of-detail decisions and be unit tested directly.
Mirrors three.js' Sphere/Box3.distanceToPoint (clamped to 0 on the inside).
Non-negative distance from
pointto a BoundsShape —0when the point is inside or on the shape. Precedence when several are set:sphere>box>position; returnsInfinitywhen none is provided. Pure math (no rendering dependencies), so it can drive level-of-detail decisions and be unit tested directly.Mirrors three.js'
Sphere/Box3.distanceToPoint(clamped to0on the inside).