Luxar Viewer API Documentation - v2026.9.22
    Preparing search index...
    interface OfflineCaptureDriver {
        setup(ctx: CaptureContext): Promise<boolean>;
        captureFrame(
            ctx: CaptureContext,
            frameIndex: number,
            progress: CaptureProgress,
        ): Promise<void>;
        finalize(
            ctx: CaptureContext,
            capturedFrames: number,
            progress: CaptureProgress,
        ): Promise<void>;
        shouldAbort?(): boolean;
        abort?(
            ctx: CaptureContext,
            reason: "error" | "disposed" | "user-cancel",
        ): Promise<void>;
    }

    Implemented by

    Index
    • Capture one frame. Called once per turntable frame after the animation loop has rendered the rotated camera. May throw on encoder errors — the loop tolerates up to MAX_CONSECUTIVE_ERRORS before aborting.

      frameIndex is the OUTPUT sequence index (number of successful captures so far), not the source loop index. With tolerated frame failures the source loop's index advances while the output index stays contiguous — drivers that use this index for timestamps (VideoModeDriver) get gap-free output timing. Drivers that name files use ZipSequenceCapture's own success counter and can ignore this parameter.

      Parameters

      Returns Promise<void>

    • Optional partial-resource cleanup hook. Called from the panel's finally block when:

      • setup completed but capture/finalize threw, OR
      • the offline session was aborted (dispose / user cancel). Drivers should release encoder/zip/file resources without downloading or toasting "saved". Distinct from finalize, which is the success path that delivers the artifact.

      Parameters

      Returns Promise<void>