Luxar Viewer API Documentation - v2026.9.22
    Preparing search index...
    • Auto-adjust clipping planes from scene bounds.

      Prefers metadata bounds (full dataset extent, available before geometry loads); falls back to a Box3 over the loaded scene graph. Also feeds the bounding-box diagonal into the scale-aware controls.

      Parameters

      Returns { near: number; far: number; applied: boolean }

      the derived near/far and whether they were applied; on empty scenes, returns the configured defaults with applied: false without touching the camera.

      Note on that empty-scene return: those configured defaults (near 0.1 / far 1000) are a ratio of 10,000 — well past MAX_NEAR_FAR_RATIO. That is deliberate and inert, not an oversight to "fix": the branch touches no camera, and its only production caller (SceneManager.autoAdjustClippingPlanes) uses applied: false to avoid dispatching a view change. It is reached only when the scene has neither metadata bounds nor geometry — i.e. when there is nothing to z-fight. The camera keeps the same defaults it was constructed with, and the first real bounds put it back under the bound.