UNPKG

@opensubtitles/video-metadata-extractor

Version:

A comprehensive NPM package for video metadata extraction and subtitle processing using FFmpeg WASM. Supports metadata extraction, individual subtitle extraction, batch subtitle extraction with ZIP downloads, and memory-safe processing of files of any siz

22 lines 948 B
/** * Optimized and simplified video metadata hook * Reduces code duplication and improves maintainability */ import { VideoMetadata, ProgressState, ErrorState } from '../types/index.js'; interface UseOptimizedVideoMetadataResult { metadata: VideoMetadata | null; progress: ProgressState; error: ErrorState; handleFileSelect: (file: File) => Promise<void>; extractSubtitle: (file: File, streamIndex: number, language?: string, codecName?: string, isForced?: boolean) => Promise<void>; extractStream: (file: File, streamIndex: number, streamType: string) => Promise<void>; extractAllSubtitles: (file: File) => Promise<void>; hideError: () => void; hideProgress: () => void; isLoaded: boolean; selectedFile: File | null; currentMethod: string; } export declare const useOptimizedVideoMetadata: () => UseOptimizedVideoMetadataResult; export {}; //# sourceMappingURL=useOptimizedVideoMetadata.d.ts.map