/** * FFmpegLoader - Async loader for WASM module */ import type { MoviWasmModule } from './types'; /** * Point the loader at a specific `movi.wasm` URL. Only meaningful for the slim * build; must be called before the engine first loads (the element does this * from its `wasmurl` attribute on connect). */ export declare function setWasmUrl(url: string | null): void; export interface LoaderOptions { wasmBinary?: Uint8Array; workerPath?: string; } /** * Discard the cached main-playback module so the next loadWasmModule() builds a * fresh one. Emscripten's abort() (a WASM trap / OOB in an FFmpeg call) leaves * the module PERMANENTLY dead: every later avformat_open_input on it fails with * "File is corrupted or in an unsupported format". Because the main demuxer uses * this cached singleton, that error then repeats for EVERY source — a new video, * a quality switch, anything — until a full page reload rebuilds the JS context. * Calling this on a fatal WASM error makes the next load recover in-page, exactly * as a reload would. */ export declare function resetWasmModule(): void; /** * Load the WASM module (cached singleton for main playback) */ export declare function loadWasmModule(options?: LoaderOptions): Promise; /** * Load a NEW WASM module instance (not cached). * Use this for preview pipeline to get completely isolated WASM memory. * Each call creates a separate WebAssembly.Memory - no sharing with main module. */ export declare function loadWasmModuleNew(options?: LoaderOptions): Promise; /** * Get the loaded module (throws if not loaded) */ export declare function getWasmModule(): MoviWasmModule; /** * Check if module is loaded */ export declare function isWasmModuleLoaded(): boolean; //# sourceMappingURL=FFmpegLoader.d.ts.map