fitNearPlane property

bool fitNearPlane
getter/setter pair

Whether perspective views rasterize with a near plane fitted to the content they draw, each frame.

Depth precision scales with the near plane, so a camera that never gets close to anything (a chase, orbit, or aerial camera) wastes most of it on the default 0.1, and surfaces a few centimetres apart flicker (z-fighting) in the distance. With this on, the projection's near is a floor: the engine raises the plane it rasterizes with to just short of the nearest thing the view draws, judged from bounds, so nothing visible is ever clipped and the image changes only in precision. Picking, the public projection, and shadow cascades keep the authored plane.

Costs one bounds query per view per frame. Turn it off when something draws near the camera outside the scene's bounds (a custom pass, or a vertex shader that moves geometry beyond its bounds). Defaults to true.

Implementation

bool fitNearPlane = true;