1var t,e,a,s,i,h,E,r,l,o=Object.defineProperty,n=(t,e,a)=>(((t,e,a)=>{e in t?o(t,e,{enumerable:!0,configurable:!0,writable:!0,value:a}):t[e]=a})(t,"symbol"!=typeof e?e+"":e,a),a),d=(t,e,a)=>{if(!e.has(t))throw TypeError("Cannot "+a)},c=(t,e,a)=>(d(t,e,"read from private field"),a?a.call(t):e.get(t)),R=(t,e,a)=>{if(e.has(t))throw TypeError("Cannot add the same private member more than once");e instanceof WeakSet?e.add(t):e.set(t,a)},p=(t,e,a,s)=>(d(t,e,"write to private field"),s?s.call(t,a):e.set(t,a),a);(l=r||(r={})).LOAD="LOAD",l.EXEC="EXEC",l.FFPROBE="FFPROBE",l.WRITE_FILE="WRITE_FILE",l.READ_FILE="READ_FILE",l.DELETE_FILE="DELETE_FILE",l.RENAME="RENAME",l.CREATE_DIR="CREATE_DIR",l.LIST_DIR="LIST_DIR",l.DELETE_DIR="DELETE_DIR",l.ERROR="ERROR",l.DOWNLOAD="DOWNLOAD",l.PROGRESS="PROGRESS",l.LOG="LOG",l.MOUNT="MOUNT",l.UNMOUNT="UNMOUNT";const D=(()=>{let t=0;return()=>t++})(),O=new Error("ffmpeg is not loaded, call `await ffmpeg.load()` first"),F=new Error("called FFmpeg.terminate()");class L{constructor(){R(this,t,null),R(this,e,{}),R(this,a,{}),R(this,s,[]),R(this,i,[]),n(this,"loaded",!1),R(this,h,()=>{c(this,t)&&(c(this,t).onmessage=({data:{id:t,type:h,data:E}})=>{switch(h){case r.LOAD:this.loaded=!0,c(this,e)[t](E);break;case r.MOUNT:case r.UNMOUNT:case r.EXEC:case r.FFPROBE:case r.WRITE_FILE:case r.READ_FILE:case r.DELET
1E_FILE:case r.RENAME:case r.CREATE_DIR:case r.LIST_DIR:case r.DELETE_DIR:c(this,e)[t](E);break;case r.LOG:c(this,s).forEach(t=>t(E));break;case r.PROGRESS:c(this,i).forEach(t=>t(E));break;case r.ERROR:c(this,a)[t](E)}delete c(this,e)[t],delete c(this,a)[t]})}),R(this,E,({type:s,data:i},h=[],E)=>c(this,t)?new Promise((r,l)=>{const o=D();c(this,t)&&c(this,t).postMessage({id:o,type:s,data:i},h),c(this,e)[o]=r,c(this,a)[o]=l,E?.addEventListener("abort",()=>{l(new DOMException(`Message # ${o} was aborted`,"AbortError"))},{once:!0})}):Promise.reject(O)),n(this,"load",({classWorkerURL:e,...a}={},{signal:s}={})=>(c(this,t)||(p(this,t,e?new Worker(new URL(e,import.meta.url),{type:"module"}):new Worker(new URL("/assets/worker-2cf8c996.js",self.location),{type:"module"})),c(this,h).call(this)),c(this,E).call(this,{type:r.LOAD,data:a},void 0,s))),n(this,"exec",(t,e=-1,{signal:a}={})=>c(this,E).call(this,{type:r.EXEC,data:{args:t,timeout:e}},void 0,a)),n(this,"ffprobe",(t,e=-1,{signal:a}={})=>c(this,E).call(this,{type:r.FFPROBE,data:{args:t,timeout:e}},void 0,a)),n(this,"terminate",()=>{const s=Object.keys(c(this,a));for(const t of s)c(this,a)[t](F),delete c(this,a)[t],delete c(this,e)[t];c(this,t)&&(c(this,t).terminate(),p(this,t,null),this.loaded=!1)}),n(this,"writeFile",(t,e,{signal:a}={})=>{const s=[];return e instanceof Uint8Array&&s.push(e.buffer),c(this,E).call(this,{type:r.WRITE_FILE,data:{path:t,data:e}},s,a)}),n(this,"mount",(t,e,a)=>c(this,E).call(this,{type:r.MOUNT,data:{fsType:t,options:e,mountPoint:a}},[])),n(this,"unmount",t=>c(this,E).call(this,{type:r.UNMOUNT,data:{mountPoint:t}},[])),n(this,"readFile",(t,e="binary",{signal:a}={})=>c(this,E).call(this,{type:r.READ_FILE,data:{path:t,encoding:e}},void 0,a)),n(this,"deleteFile",(t,{signal:e}={})=>c(this,E).call(this,{type:r.DELETE_FILE,data:{path:t}},void 0,e)),n(this,"rename",(t,e,{signal:a}={})=>c(this,E).call(this,{type:r.RENAME,data:{oldPath:t,newPath:e}},void 0,a)),n(this,"createDir",(t,{signal:e}={})=>c(this,E).call(this,{type:r.CREATE_DIR,data:{path:t}},void 0,e)),n(this,"listDir",(t,{signal:e}={})=>c(this,E).call(this,{type:r.LIST_DIR,data:{path:t}},void 0,e)),n(this,"deleteDir",(t,{signal:e}={})=>c(this,E).call(this,{type:r.DELETE_DIR,data:{path:t}},void 0,e))}on(t,e){"log"===t?c(this,s).push(e):"progress"===t&&c(this,i).push(e)}off(t,e){"log"===t?p(this,s,c(this,s).filter(t=>t!==e)):"progress"===t&&p(this,i,c(this,i).filter(t=>t!==e))}}var I,T;t=new WeakMap,e=new WeakMap,a=new WeakMap,s=new WeakMap,i=new WeakMap,h=new WeakMap,E=new WeakMap,(T=I||(I={})).MEMFS="MEMFS",T.NODEFS="NODEFS",T.NODERAWFS="NODERAWFS",T.IDBFS="IDBFS",T.WORKERFS="WORKERFS",T.PROXYFS="PROXYFS";export{I as FFFSType,L as FFmpeg};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.