The InputFormat API provides functionality to specify input format for media sources.
const format = new ffmpeg.InputFormat([name])name(string, optional): The input format name. Defaults to a platform-specific value:darwin,ios:'avfoundation'linux:'v4l2'win32:'dshow'
Returns: A new InputFormat instance
Gets the file extensions associated with this input format.
Returns: string - Comma-separated list of file extensions (e.g., 'mkv,mk3d,mka,mks,webm')
Gets the MIME type for this input format.
Returns: string - The MIME type (e.g., 'audio/webm,audio/x-matroska,video/webm,video/x-matroska')
Returns format name
Returns: string - The short-name (e.g., webm)
const format = new ffmpeg.InputFormat('webm')
console.log(format.extensions) // 'mkv,mk3d,mka,mks,webm'
console.log(format.mimeType) // 'audio/webm,audio/x-matroska,video/webm,video/x-matroska'Destroys the InputFormat and frees all associated resources. Automatically called when the object is managed by a using declaration.
Returns: void