API

Interface USDFileLoaderOptions

Options for the OpenUSD scene loader.

interface USDFileLoaderOptions {
    dataUrl?: string;
    files?: Readonly<Record<string, USDBinaryInput>>;
    glueUrl?: string;
    onComplete?: (diagnostics: USDImportDiagnostics) => void;
    onLog?: (level: "error" | "warning" | "info", message: string) => void;
    onProgress?: (progress: USDLoadProgress) => void;
    resolveByFileName?: boolean;
    rootFileName?: string;
    wasmUrl?: string;
    workerUrl?: string | URL;
}
Index
dataUrl?: string

URL of the OpenUSD preloaded resource bundle.

files?: Readonly<Record<string, USDBinaryInput>>

Supporting layers, payloads, and textures keyed by virtual path in the same virtual file system as rootFileName.

glueUrl?: string

URL of the generated Emscripten JavaScript module.

onComplete?: (diagnostics: USDImportDiagnostics) => void

Called after extraction and Babylon.js object creation complete.

onLog?: (level: "error" | "warning" | "info", message: string) => void

Called for OpenUSD diagnostic messages.

onProgress?: (progress: USDLoadProgress) => void

Called when the importer moves to a new processing phase.

resolveByFileName?: boolean

Enables conservative file-name fallback for unresolved absolute references. Defaults to true.

rootFileName?: string

Virtual path used to stage the root layer. Set this when supporting files need to resolve relative to a directory hierarchy.

wasmUrl?: string

URL of the OpenUSD WebAssembly binary.

workerUrl?: string | URL

URL of the module worker. Defaults to the protocol-versioned worker hosted on the Babylon.js CDN.