Luxar Viewer API Documentation - v2026.9.22
    Preparing search index...

    Ctx supplied by SceneManager. The materials helpers read these refs but never mutate the host class. _bufferSize is a pre-allocated Vector2 owned by SceneManager so resize callbacks don't allocate on every frame.

    interface CameraMaterialsCtx {
        renderer: Renderer;
        camera: LuxarCamera;
        scene: Scene;
        boundsCache: SceneBoundsCache;
        bufferSize: Vector2;
    }
    Index
    renderer: Renderer
    camera: LuxarCamera
    scene: Scene
    boundsCache: SceneBoundsCache
    bufferSize: Vector2

    Pre-allocated Vector2 receiver for getDrawingBufferSize.

    Borrow contract: This Vector2 is owned by SceneManager (a single shared instance) and is mutated on every camera-materials update. Downstream consumers MUST treat it as read-only and scoped to the current call. To retain the value across frames, .copy() it into private storage — never store the reference itself, or a subsequent resize will silently mutate your "saved" value.