jiuyiUniapp/jiuyi2/node_modules/trtc-sdk-v5/plugins/video-effect/virtual-background/virtual-background.iife.js

32 lines
314 KiB
JavaScript
Raw Normal View History

2024-12-18 15:46:27 +08:00
"use strict";var VirtualBackground=(()=>{var Tn=Object.defineProperty,uc=Object.defineProperties,dc=Object.getOwnPropertyDescriptor,Ec=Object.getOwnPropertyDescriptors,fc=Object.getOwnPropertyNames,ti=Object.getOwnPropertySymbols;var ri=Object.prototype.hasOwnProperty,Ic=Object.prototype.propertyIsEnumerable;var TA=(X,R,n)=>R in X?Tn(X,R,{enumerable:!0,configurable:!0,writable:!0,value:n}):X[R]=n,ni=(X,R)=>{for(var n in R||(R={}))ri.call(R,n)&&TA(X,n,R[n]);if(ti)for(var n of ti(R))Ic.call(R,n)&&TA(X,n,R[n]);return X},Ai=(X,R)=>uc(X,Ec(R));var Cc=(X=>typeof require!="undefined"?require:typeof Proxy!="undefined"?new Proxy(X,{get:(R,n)=>(typeof require!="undefined"?require:R)[n]}):X)(function(X){if(typeof require!="undefined")return require.apply(this,arguments);throw Error('Dynamic require of "'+X+'" is not supported')});var pc=(X,R)=>{for(var n in R)Tn(X,n,{get:R[n],enumerable:!0})},Bc=(X,R,n,T)=>{if(R&&typeof R=="object"||typeof R=="function")for(let se of fc(R))!ri.call(X,se)&&se!==n&&Tn(X,se,{get:()=>R[se],enumerable:!(T=dc(R,se))||T.enumerable});return X};var hc=X=>Bc(Tn({},"__esModule",{value:!0}),X);var Ce=(X,R,n)=>(TA(X,typeof R!="symbol"?R+"":R,n),n);var wc={};pc(wc,{VirtualBackground:()=>Sn,default:()=>Dc});async function ii({sdkAppId:X,userId:R,userSig:n,core:T}){var be;let se=T.utils.getAbilityConfigUrl(X),ce=Math.round(new Date().getTime()/1e3),ge=`${se}?sdkAppId=${X}&userId=${R}&userSig=${n}&timestamp=${ce}`;try{let Re=await(await fetch(ge)).json();T.log.info(`virtual background send ${ge}, response: ${JSON.stringify(Re)}`);let{data:Se}=Re;return(be=Se==null?void 0:Se.trtcAutoConf)!=null&&be.web_ar?{auth:!0,timestamp:ce}:{auth:!1}}catch(Te){return T.log.error("beauty fetch error",Te),{auth:!1}}}var mc={sdkAppId:{required:!0,type:"number"},userId:{required:!0,type:"string"},userSig:{required:!0,type:"string"}};function oi(X){return{name:"VirtualBackgroundOptions",type:"object",required:!0,allowEmpty:!1,properties:Ai(ni({},mc),{type:{required:!1,type:"string",values:["image","blur"]},src:{required:!1,type:"string"},blurLevel:{required:!1,type:"number",min:1,max:10},onError:{required:!1}}),validate(R,n,T,se){var Je;let{RtcError:ce,ErrorCode:ge,ErrorCodeDictionary:be}=X.errorModule;if(!R)return;let{type:Te,src:Re,onError:Se}=R;if(Te==="image"&&!Re)throw new ce({code:ge.INVALID_PARAMETER,extraCode:be.INVALID_PARAMETER_REQUIRED,fnName:T,messageParams:{key:"src"}});if(Se&&!X.utils.isFunction(Se))throw new ce({code:ge.INVALID_PARAMETER,extraCode:be.INVALID_PARAMETER_TYPE,fnName:T,messageParams:{key:"onError",value:typeof Se,rule:{type:"Function"}}});if(!((Je=X.room.videoManager.cameraTrack)!=null&&Je.mediaTrack))throw new ce({code:ge.INVALID_OPERATION,extraCode:be.INVALID_OPERATION_NEED_VIDEO,fnName:T});if(X.environment.CHROME_MAJOR_VERSION<90)throw new ce({code:ge.ENV_NOT_SUPPORTED,extraCode:be.NOT_SUPPORTED_CHROME_VERSION,fnName:T})}}}function si(X){return{name:"UpdateVirtualBackgroundOptions",type:"object",required:!0,allowEmpty:!1,properties:{type:{required:!0,type:"string",values:["image","blur"]},src:{required:!1,type:"string"},blurLevel:{required:!1,type:"number",min:1,max:10}},validate(R,n,T,se){if(!R)return;let{RtcError:ce,ErrorCode:ge,ErrorCodeDictionary:be}=X.errorModule,{type:Te,src:Re}=R;if(Te==="image"&&!Re)throw new ce({code:ge.INVALID_PARAMETER,extraCode:be.INVALID_PARAMETER_REQUIRED,fnName:T,messageParams:{key:"src"}})}}}function ai(X){return{name:"StopVirtualBackgroundOptions",required:!1}}var Qc=function(){let X=typeof document!="undefined"&&document.currentScript?document.currentScript.src:void 0;return typeof __filename!="undefined"&&(X=X||__filename),function(R){R=R||{};let n=typeof R!="undefined"?R:{},T,se;n.ready=new Promise((e,t)=>{T=e,se=t}),Object.getOwnPropertyDescriptor(n.ready,"_main")||(Object.defineProperty(n.ready,"_main",{configurable:!0,get(){u("You are getting _main on the Promise object, instead of the instance. Use .then() to get called back with the instance, see the MODULARIZE docs in src/settings.js")}}),Object.defineProperty(n.ready,"_main",{configurable:!0,set(){u("You are
${n.extraStackTrace()}`),xt(e)}function tr(e){return Jt(e+16)+16}function $n(e,t){}function Kr(e,t){return void 0}function Lt(e){this.excPtr=e,this.ptr=e-16,this.set_type=function(t){m[this.ptr+4>>2]=t},this.get_type=function(){return m[this.ptr+4>>2]},this.set_destructor=function(t){m[this.ptr+8>>2]=t},this.get_destructor=function(){return m[this.ptr+8>>2]},this.set_refcount=function(t){m[this.ptr>>2]=t},this.set_caught=function(t){t=t?1:0,oe[this.ptr+12>>0]=t},this.get_caught=function(){return oe[this.ptr+12>>0]!=0},this.set_rethrown=function(t){t=t?1:0,oe[this.ptr+13>>0]=t},this.get_rethrown=function(){return oe[this.ptr+13>>0]!=0},this.init=function(t,r){this.set_type(t),this.set_destructor(r),this.set_refcount(0),this.set_caught(!1),this.set_rethrown(!1)},this.add_ref=function(){let t=m[this.ptr>>2];m[this.ptr>>2]=t+1},this.release_ref=function(){let t=m[this.ptr>>2];return m[this.ptr>>2]=t-1,M(t>0),t===1}}function rr(e){this.free=function(){ut(this.ptr),this.ptr=0},this.set_base_ptr=function(t){m[this.ptr>>2]=t},this.get_base_ptr=function(){return m[this.ptr>>2]},this.set_adjusted_ptr=function(t){m[this.ptr+4>>2]=t},this.get_adjusted_ptr_addr=function(){return this.ptr+4},this.get_adjusted_ptr=function(){return m[this.ptr+4>>2]},this.get_exception_ptr=function(){if(aa(this.get_exception_info().get_type()))return m[this.get_base_ptr()>>2];let r=this.get_adjusted_ptr();return r!==0?r:this.get_base_ptr()},this.get_exception_info=function(){return new Lt(this.get_base_ptr())},e===void 0?(this.ptr=Jt(8),this.set_adjusted_ptr(0)):this.ptr=e}let Fe=[];function zn(e){e.add_ref()}let nr=0;function Vr(e){let t=new rr(e),r=t.get_exception_info();return r.get_caught()||(r.set_caught(!0),nr--),r.set_rethrown(!1),Fe.push(t),zn(r),t.get_exception_ptr()}let ke=0;function $r(e){try{return ut(new Lt(e).ptr)}catch(t){Z(`exception during cxa_free_exception: ${t}`)}}function zr(e){if(e.release_ref()&&!e.get_rethrown()){let t=e.get_destructor();t&&v.get(t)(e.excPtr),$r(e.excPtr)}}function pr(){H(0),M(Fe.length>0);let e=Fe.pop();zr(e.get_exception_info()),e.free(),ke=0}function Zn(e){let t=new rr(e),r=t.get_base_ptr();throw ke||(ke=r),t.free(),`${r} - Exception catching is disabled, this exception cannot be caught. Compile with -s NO_DISABLE_EXCEPTION_CATCHING or -s EXCEPTION_CATCHING_ALLOWED=[..] to catch.`}function Zr(){let e=ke;if(!e)return Ye(0),0;let r=new Lt(e).get_type(),A=new rr;if(A.set_base_ptr(e),A.set_adjusted_ptr(e),!r)return Ye(0),A.ptr|0;let i=Array.prototype.slice.call(arguments);for(let o=0;o<i.length;o++){let s=i[o];if(s===0||s===r)break;if(qA(s,r,A.get_adjusted_ptr_addr()))return Ye(s),A.ptr|0}return Ye(r),A.ptr|0}function qn(){let e=ke;if(!e)return Ye(0),0;let r=new Lt(e).get_type(),A=new rr;if(A.set_base_ptr(e),A.set_adjusted_ptr(e),!r)return Ye(0),A.ptr|0;let i=Array.prototype.slice.call(arguments);for(let o=0;o<i.length;o++){let s=i[o];if(s===0||s===r)break;if(qA(s,r,A.get_adjusted_ptr_addr()))return Ye(s),A.ptr|0}return Ye(r),A.ptr|0}function eA(){let e=Fe.pop();e||u("no exception to throw");let t=e.get_exception_info(),r=e.get_base_ptr();throw t.get_rethrown()?e.free():(Fe.push(e),t.set_rethrown(!0),t.set_caught(!1),nr++),ke=r,`${r} - Exception catching is disabled, this exception cannot be caught. Compile with -s NO_DISABLE_EXCEPTION_CATCHING or -s EXCEPTION_CATCHING_ALLOWED=[..] to catch.`}function tA(e,t){return void 0}function qr(e,t,r){throw new Lt(e).init(t,r),ke=e,nr++,`${e} - Exception catching is disabled, this exception cannot be caught. Compile with -s NO_DISABLE_EXCEPTION_CATCHING or -s EXCEPTION_CATCHING_ALLOWED=[..] to catch.`}function en(e){return m[na()>>2]=e,e}var ee={splitPath(e){return/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/.exec(e).slice(1)},normalizeArray(e,t){let r=0;for(let A=e.length-1;A>=0;A--){let i=e[A];i==="."?e.splice(A,1):i===".."?(e.splice(A,1),r++):r&&(e.splice(A,1),r--)}if(t)for(;r;r--)e.unshift("..");return e},normalize(e){let t=e.charAt(0)==="/",r=e.substr(-1)==="/";return e=ee.normalizeArray(e.split("/").filter(A=>!!A),!t).join("/"),!e&&!t&&(e="."),e&&r&
`)):typeof readline=="function"&&(t=readline(),t!==null&&(t+=`
`));if(!t)return null;e.input=wn(t,!0)}return e.input.shift()},put_char(e,t){t===null||t===10?(ye(Qt(e.output,0)),e.output=[]):t!=0&&e.output.push(t)},flush(e){e.output&&e.output.length>0&&(ye(Qt(e.output,0)),e.output=[])}},default_tty1_ops:{put_char(e,t){t===null||t===10?(Z(Qt(e.output,0)),e.output=[]):t!=0&&e.output.push(t)},flush(e){e.output&&e.output.length>0&&(Z(Qt(e.output,0)),e.output=[])}}};function rA(e,t){le.fill(0,e,e+t)}function gt(e,t){return M(t,"alignment argument is required"),Math.ceil(e/t)*t}function tn(e){e=gt(e,65536);let t=ca(65536,e);return t?(rA(t,e),t):0}var W={ops_table:null,mount(e){return W.createNode(null,"/",16895,0)},createNode(e,t,r,A){if(a.isBlkdev(r)||a.isFIFO(r))throw new a.ErrnoError(63);W.ops_table||(W.ops_table={dir:{node:{getattr:W.node_ops.getattr,setattr:W.node_ops.setattr,lookup:W.node_ops.lookup,mknod:W.node_ops.mknod,rename:W.node_ops.rename,unlink:W.node_ops.unlink,rmdir:W.node_ops.rmdir,readdir:W.node_ops.readdir,symlink:W.node_ops.symlink},stream:{llseek:W.stream_ops.llseek}},file:{node:{getattr:W.node_ops.getattr,setattr:W.node_ops.setattr},stream:{llseek:W.stream_ops.llseek,read:W.stream_ops.read,write:W.stream_ops.write,allocate:W.stream_ops.allocate,mmap:W.stream_ops.mmap,msync:W.stream_ops.msync}},link:{node:{getattr:W.node_ops.getattr,setattr:W.node_ops.setattr,readlink:W.node_ops.readlink},stream:{}},chrdev:{node:{getattr:W.node_ops.getattr,setattr:W.node_ops.setattr},stream:a.chrdev_stream_ops}});let i=a.createNode(e,t,r,A);return a.isDir(i.mode)?(i.node_ops=W.ops_table.dir.node,i.stream_ops=W.ops_table.dir.stream,i.contents={}):a.isFile(i.mode)?(i.node_ops=W.ops_table.file.node,i.stream_ops=W.ops_table.file.stream,i.usedBytes=0,i.contents=null):a.isLink(i.mode)?(i.node_ops=W.ops_table.link.node,i.stream_ops=W.ops_table.link.stream):a.isChrdev(i.mode)&&(i.node_ops=W.ops_table.chrdev.node,i.stream_ops=W.ops_table.chrdev.stream),i.timestamp=Date.now(),e&&(e.contents[t]=i,e.timestamp=i.timestamp),i},getFileDataAsTypedArray(e){return e.contents?e.contents.subarray?e.contents.subarray(0,e.usedBytes):new Uint8Array(e.contents):new Uint8Array(0)},expandFileStorage(e,t){let r=e.contents?e.contents.length:0;if(r>=t)return;let A=1024*1024;t=Math.max(t,r*(r<A?2:1.125)>>>0),r!=0&&(t=Math.max(t,256));let i=e.contents;e.contents=new Uint8Array(t),e.usedBytes>0&&e.contents.set(i.subarray(0,e.usedBytes),0)},resizeFileStorage(e,t){if(e.usedBytes!=t)if(t==0)e.contents=null,e.usedBytes=0;else{let r=e.contents;e.contents=new Uint8Array(t),r&&e.contents.set(r.subarray(0,Math.min(t,e.usedBytes))),e.usedBytes=t}},node_ops:{getattr(e){let t={};return t.dev=a.isChrdev(e.mode)?e.id:1,t.ino=e.id,t.mode=e.mode,t.nlink=1,t.uid=0,t.gid=0,t.rdev=e.rdev,a.isDir(e.mode)?t.size=4096:a.isFile(e.mode)?t.size=e.usedBytes:a.isLink(e.mode)?t.size=e.link.length:t.size=0,t.atime=new Date(e.timestamp),t.mtime=new Date(e.timestamp),t.ctime=new Date(e.timestamp),t.blksize=4096,t.blocks=Math.ceil(t.size/t.blksize),t},setattr(e,t){t.mode!==void 0&&(e.mode=t.mode),t.timestamp!==void 0&&(e.timestamp=t.timestamp),t.size!==void 0&&W.resizeFileStorage(e,t.size)},lookup(e,t){throw a.genericErrors[44]},mknod(e,t,r,A){return W.createNode(e,t,r,A)},rename(e,t,r){if(a.isDir(e.mode)){let A;try{A=a.lookupNode(t,r)}catch(i){}if(A)for(let i in A.contents)throw new a.ErrnoError(55)}delete e.parent.contents[e.name],e.parent.timestamp=Date.now(),e.name=r,t.contents[r]=e,t.timestamp=e.parent.timestamp,e.parent=t},unlink(e,t){delete e.contents[t],e.timestamp=Date.now()},rmdir(e,t){let r=a.lookupNode(e,t);for(let A in r.contents)throw new a.ErrnoError(55);delete e.contents[t],e.timestamp=Date.now()},readdir(e){let t=[".",".."];for(let r in e.contents)e.contents.hasOwnProperty(r)&&t.push(r);return t},symlink(e,t,r){let A=W.createNode(e,t,41471,0);return A.link=r,A},readlink(e){if(!a.isLink(e.mode))throw new a.ErrnoError(28);return e.link}},stream_ops:{read(e,t,r,A,i){let{contents:o}=e.node;if(i>=e.node.usedBytes)return 0;let s=Math.min(e.node.usedBytes-i,A);if(M(s>=0),s>8&&o.subarray)t.set(o.subarray(i,i+s),r);else for(let c=0;c<s;c
"use strict"; return body.apply(this, arguments);
};
`)(t)}let hr=[],ve=[{},{value:void 0},{value:null},{value:!0},{value:!1}];function lA(){let e=0;for(let t=5;t<ve.length;++t)ve[t]!==void 0&&++e;return e}function uA(){for(let e=5;e<ve.length;++e)if(ve[e]!==void 0)return ve[e];return null}function dA(){n.count_emval_handles=lA,n.get_first_emval=uA}function ir(e){switch(e){case void 0:return 1;case null:return 2;case!0:return 3;case!1:return 4;default:{let t=hr.length?hr.pop():ve.length;return ve[t]={refcount:1,value:e},t}}}function or(e,t){let r=Ar(t,function(A){this.name=t,this.message=A;let{stack:i}=new Error(A);i!==void 0&&(this.stack=`${this.toString()}
${i.replace(/^Error(:[^\n]*)?\n/,"")}`)});return r.prototype=Object.create(e.prototype),r.prototype.constructor=r,r.prototype.toString=function(){return this.message===void 0?this.name:`${this.name}: ${this.message}`},r}let An;function mr(){let e=new Array(256);for(let t=0;t<256;++t)e[t]=String.fromCharCode(t);Qr=e}var Qr=void 0;function ue(e){let t="",r=e;for(;le[r];)t+=Qr[le[r++]];return t}function EA(){return Object.keys(tt).length}function fA(){let e=[];for(let t in tt)tt.hasOwnProperty(t)&&e.push(tt[t]);return e}let It=[];function _r(){for(;It.length;){let e=It.pop();e.$$.deleteScheduled=!1,e.delete()}}let jt;function IA(e){jt=e,It.length&&jt&&jt(_r)}function CA(){n.getInheritedInstanceCount=EA,n.getLiveInheritedInstances=fA,n.flushPendingDeletes=_r,n.setDelayFunction=IA}var tt={};let Rt;function J(e){throw new Rt(e)}function yr(e,t){for(t===void 0&&J("ptr should not be undefined");e.baseClass;)t=e.upcast(t),e=e.baseClass;return t}function pA(e,t,r){t=yr(e,t),tt.hasOwnProperty(t)?J(`Tried to register registered instance: ${t}`):tt[t]=r}function on(e){return e||J(`Cannot use deleted val. handle = ${e}`),ve[e].value}let Ct={};function xe(e){let t=Aa(e),r=ue(t);return ut(t),r}function Dr(e,t){let r=Ct[e];return r===void 0&&J(`${t} has unknown type ${xe(e)}`),r}function wr(e,t){t=yr(e,t),tt.hasOwnProperty(t)?delete tt[t]:J(`Tried to unregister unregistered instance: ${t}`)}function Ht(e){}let Le=!1;function sn(e){e.smartPtr?e.smartPtrType.rawDestructor(e.smartPtr):e.ptrType.registeredClass.rawDestructor(e.ptr)}function BA(e){e.count.value-=1,e.count.value===0&&sn(e)}function rt(e){return typeof FinalizationGroup=="undefined"?(rt=function(t){return t},e):(Le=new FinalizationGroup(t=>{for(let r=t.next();!r.done;r=t.next()){let A=r.value;A.ptr?BA(A):console.warn(`object already deleted: ${A.ptr}`)}}),rt=function(t){return Le.register(t,t.$$,t.$$),t},Ht=function(t){Le.unregister(t.$$)},rt(e))}function an(e,t,r){e=ue(e),t=Dr(t,"wrapper"),r=on(r);let A=[].slice,{registeredClass:i}=t,o=i.instancePrototype,{baseClass:s}=i,c=s.instancePrototype,d=i.baseClass.constructor,E=Ar(e,function(){i.baseClass.pureVirtualFunctions.forEach(I=>{if(this[I]===c[I])throw new An(`Pure virtual function ${I} must be implemented in JavaScript`)}),Object.defineProperty(this,"__parent",{value:o}),this.__construct.apply(this,A.call(arguments))});o.__construct=function(){this===o&&J("Pass correct 'this' to __construct");let B=d.implement.apply(void 0,[this].concat(A.call(arguments)));Ht(B);let{$$:h}=B;B.notifyOnDestruction(),h.preservePointerOnDelete=!0,Object.defineProperties(this,{$$:{value:h}}),rt(this),pA(i,h.ptr,this)},o.__destruct=function(){this===o&&J("Pass correct 'this' to __destruct"),Ht(this),wr(i,this.$$.ptr)},E.prototype=Object.create(o);for(let I in r)E.prototype[I]=r[I];return ir(E)}let l={};function g(e){for(;e.length;){let t=e.pop();e.pop()(t)}}function f(e){return this.fromWireType(Ae[e>>2])}let p={},w={},S;function P(e){throw new S(e)}function b(e,t,r){e.forEach(c=>{w[c]=t});function A(c){let d=r(c);d.length!==e.length&&P("Mismatched type converter count");for(let E=0;E<e.length;++E)K(e[E],d[E])}let i=new Array(t.length),o=[],s=0;t.forEach((c,d)=>{Ct.hasOwnProperty(c)?i[d]=Ct[c]:(o.push(c),p.hasOwnProperty(c)||(p[c]=[]),p[c].push(()=>{i[d]=Ct[c],++s,s===o.length&&A(i)}))}),o.length===0&&A(i)}function N(e){let t=l[e];delete l[e];let{rawConstructor:r}=t,{rawDestructor:A}=t,i=t.fields,o=i.map(s=>s.getterReturnType).concat(i.map(s=>s.setterArgumentType));b([e],o,s=>{let c={};return i.forEach((d,E)=>{let{fieldName:I}=d,B=s[E],{getter:h}=d,{getterContext:_}=d,O=s[E+i.length],{setter:U}=d,{setterContext:Y}=d;c[I]={read(q){return B.fromWireType(h(_,q))},write(q,D){let F=[];U(Y,q,O.toWireType(F,D)),g(F)}}}),[{name:t.name,fromWireType(d){let E={};for(let I in c)E[I]=c[I].read(d);return A(d),E},toWireType(d,E){for(var I in c)if(!(I in E))throw new TypeError(`Missing field: "${I}"`);let B=r();for(I in c)c[I].write(B,E[I]);return d!==null&&d.push(A,B),B},argPackAdvance:8,readValueFromPointer:f,destructorFunction:A}]})}function L(e,t,r,A,i){}fu
if (arguments.length !== ${o-2}) {
throwBindingError('function ${e} called with ' + arguments.length + ' arguments, expected ${o-2} args!');
}
`;c&&(h+=`var destructors = [];
`);let _=c?"destructors":"null",O=["throwBindingError","invoker","fn","runDestructors","retType","classParam"],U=[J,A,i,g,t[0],t[1]];s&&(h+=`var thisWired = classParam.toWireType(${_}, this);
`);for(var d=0;d<o-2;++d)h+=`var arg${d}Wired = argType${d}.toWireType(${_}, arg${d}); // ${t[d+2].name}
`,O.push(`argType${d}`),U.push(t[d+2]);if(s&&(B=`thisWired${B.length>0?", ":""}${B}`),h+=`${E?"var rv = ":""}invoker(fn${B.length>0?", ":""}${B});
`,c)h+=`runDestructors(destructors);
`;else for(var d=s?1:2;d<t.length;++d){let D=d===1?"thisWired":`arg${d-2}Wired`;t[d].destructorFunction!==null&&(h+=`${D}_dtor(${D}); // ${t[d].name}
`,O.push(`${D}_dtor`),U.push(t[d].destructorFunction))}return E&&(h+=`var ret = retType.fromWireType(rv);
return ret;
`),h+=`}
`,O.push(h),UA(Function,O).apply(null,U)}function ln(e,t){let r=[];for(let A=0;A<e;A++)r.push(m[(t>>2)+A]);return r}function yi(e,t,r,A,i,o,s){let c=ln(r,A);t=ue(t),o=Ne(i,o),b([],[e],d=>{d=d[0];let E=`${d.name}.${t}`;function I(){Wt(`Cannot call ${E} due to unbound types`,c)}t.startsWith("@@")&&(t=Symbol[t.substring(2)]);let B=d.registeredClass.constructor;return B[t]===void 0?(I.argCount=r-1,B[t]=I):(sr(B,t,E),B[t].overloadTable[r-1]=I),b([],c,h=>{let _=[h[0],null].concat(h.slice(1)),O=gn(E,_,null,o,s);return B[t].overloadTable===void 0?(O.argCount=r-1,B[t]=O):B[t].overloadTable[r-1]=O,[]}),[]})}function Di(e,t,r,A,i,o){M(t>0);let s=ln(t,r);i=Ne(A,i),b([],[e],c=>{c=c[0];let d=`constructor ${c.name}`;if(c.registeredClass.constructor_body===void 0&&(c.registeredClass.constructor_body=[]),c.registeredClass.constructor_body[t-1]!==void 0)throw new Rt(`Cannot register multiple constructors with identical number of parameters (${t-1}) for class '${c.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);return c.registeredClass.constructor_body[t-1]=function(){Wt(`Cannot construct ${c.name} due to unbound types`,s)},b([],s,E=>(E.splice(1,0,null),c.registeredClass.constructor_body[t-1]=gn(d,E,null,i,o),[])),[]})}function wi(e,t,r,A,i,o,s,c){let d=ln(r,A);t=ue(t),o=Ne(i,o),b([],[e],E=>{E=E[0];let I=`${E.name}.${t}`;t.startsWith("@@")&&(t=Symbol[t.substring(2)]),c&&E.registeredClass.pureVirtualFunctions.push(t);function B(){Wt(`Cannot call ${I} due to unbound types`,d)}let h=E.registeredClass.instancePrototype,_=h[t];return _===void 0||_.overloadTable===void 0&&_.className!==E.name&&_.argCount===r-2?(B.argCount=r-2,B.className=E.name,h[t]=B):(sr(h,t,I),h[t].overloadTable[r-2]=B),b([],d,O=>{let U=gn(I,O,E,o,s);return h[t].overloadTable===void 0?(U.argCount=r-2,h[t]=U):h[t].overloadTable[r-2]=U,[]}),[]})}function xA(e,t,r){return e instanceof Object||J(`${r} with invalid "this": ${e}`),e instanceof t.registeredClass.constructor||J(`${r} incompatible with "this" of type ${e.constructor.name}`),e.$$.ptr||J(`cannot call emscripten binding method ${r} on deleted object`),Xt(e.$$.ptr,e.$$.ptrType.registeredClass,t.registeredClass)}function bi(e,t,r,A,i,o,s,c,d,E){t=ue(t),i=Ne(A,i),b([],[e],I=>{I=I[0];let B=`${I.name}.${t}`,h={get(){Wt(`Cannot access ${B} due to unbound types`,[r,s])},enumerable:!0,configurable:!0};return d?h.set=function(){Wt(`Cannot access ${B} due to unbound types`,[r,s])}:h.set=function(_){J(`${B} is a read-only property`)},Object.defineProperty(I.registeredClass.instancePrototype,t,h),b([],d?[r,s]:[r],_=>{let O=_[0],U={get(){let Y=xA(this,I,`${B} getter`);return O.fromWireType(i(o,Y))},enumerable:!0};if(d){d=Ne(c,d);let Y=_[1];U.set=function(q){let D=xA(this,I,`${B} setter`),F=[];d(E,D,Y.toWireType(F,q)),g(F)}}return Object.defineProperty(I.registeredClass.instancePrototype,t,U),[]}),[]})}function LA(e){e>4&&--ve[e].refcount===0&&(ve[e]=void 0,hr.push(e))}function Ti(e,t){t=ue(t),K(e,{name:t,fromWireType(r){let A=ve[r].value;return LA(r),A},toWireType(r,A){return ir(A)},argPackAdvance:8,readValueFromPointer:f,destructorFunction:null})}function ar(e){if(e===null)return"null";let t=typeof e;return t==="object"||t==="array"||t==="function"?e.toString():`${e}`}function Oi(e,t){switch(t){case 2:return function(r){return this.fromWireType(pe[r>>2])};case 3:return function(r){return this.fromWireType(dr[r>>3])};default:throw new TypeError(`Unknown float type: ${e}`)}}function Ri(e,t,r){let A=k(r);t=ue(t),K(e,{name:t,fromWireType(i){return i},toWireType(i,o){if(typeof o!="number"&&typeof o!="boolean")throw new TypeError(`Cannot convert "${ar(o)}" to ${this.name}`);return o},argPackAdvance:8,readValueFromPointer:Oi(t,A),destructorFunction:null})}function Si(e,t,r,A,i,o){let s=ln(t,r);e=ue(e),i=Ne(A,i),Tr(e,()=>{Wt(`Cannot call ${e} due to unbound types`,s)},t-1),b([],s,c=>{let d=[c[0],null].concat(c.slice(1));return NA(e,gn(e,d,null,i,o),t-1),[]})}function Pi(e,t,r){switch(t){case 0:return r?function(i){return oe[i]}:function(i){return le[i]};case 1:return r?function(i){
`,B=0;for(var d=0;d<e-1;++d)I+=` var arg${d} = argType${d}.readValueFromPointer(args${B?`+${B}`:""});
`,B+=r[d+1].argPackAdvance;I+=` var rv = handle[name](${c});
`;for(var d=0;d<e-1;++d)r[d+1].deleteObject&&(I+=` argType${d}.deleteObject(arg${d});
`);A.isVoid||(I+=` return retType.toWireType(destructors, rv);
`),I+=`};
`,o.push(I);let h=UA(Function,o).apply(null,s);return Hi(h)}function Wi(e){e>4&&(ve[e].refcount+=1)}function Ji(e,t){e=Dr(e,"_emval_take_value");let r=e.readValueFromPointer(t);return ir(r)}function Ki(){u()}let Vi=!0;function $i(e,t){let r;if(e===0)r=Date.now();else if((e===1||e===4)&&Vi)r=ft();else return en(28),-1;return m[t>>2]=r/1e3|0,m[t+4>>2]=r%1e3*1e3*1e3|0,0}function zi(e,t){u("To use dlopen, you need to use Emscripten's linking support, see https://github.com/emscripten-core/emscripten/wiki/Linking")}function Zi(e,t){u("To use dlopen, you need to use Emscripten's linking support, see https://github.com/emscripten-core/emscripten/wiki/Linking")}let un=[];function qi(e,t){M(Array.isArray(un)),M(t%16==0),un.length=0;let r;for(t>>=2;r=le[e++];){M(r===100||r===102||r===105);let A=r<105;A&&t&1&&t++,un.push(A?dr[t++>>1]:m[t]),++t}return un}function eo(e,t,r){let A=qi(t,r);return Ut.hasOwnProperty(e)||u(`No EM_ASM constant found at address ${e}`),Ut[e].apply(null,A)}function to(){return 2147483648}function ro(e,t,r){le.copyWithin(e,t,t+r)}function no(e){u("Cannot use emscripten_pc_get_function without -s USE_OFFSET_CONVERTER")}function Ao(e){try{return mt.grow(e-Mt.byteLength+65535>>>16),Lr(mt.buffer),1}catch(t){Z(`emscripten_realloc_buffer: Attempted to grow heap from ${Mt.byteLength} bytes to ${e} bytes, but got error: ${t}`)}}function io(e){let t=le.length;e=e>>>0,M(e>t);let r=2147483648;if(e>r)return Z(`Cannot enlarge memory, asked to go up to ${e} bytes, but the limit is ${r} bytes!`),!1;for(let i=1;i<=4;i*=2){let o=t*(1+.2/i);o=Math.min(o,e+100663296);var A=Math.min(r,Gn(Math.max(e,o),65536));if(Ao(A))return!0}return Z(`Failed to grow the heap from ${t} bytes to ${A} bytes, not enough memory!`),!1}function dn(e){u("Cannot use emscripten_generate_pc (needed by __builtin_return_address) without -s USE_OFFSET_CONVERTER")}let cr={};function GA(e){e.forEach(t=>{let r=dn(t);r&&(cr[r]=t)})}function oo(){let e=new Error().stack.split(`
`);return e[0]=="Error"&&e.shift(),GA(e),cr.last_addr=dn(e[2]),cr.last_stack=e,cr.last_addr}function so(e,t,r){let A;cr.last_addr==e?A=cr.last_stack:(A=new Error().stack.split(`
`),A[0]=="Error"&&A.shift(),GA(A));let i=2;for(;A[i]&&dn(A[i])!=e;)++i;for(var o=0;o<r&&A[o+i];++o)m[t+o*4>>2]=dn(A[o+i]);return o}function ao(e){let t=ft();for(;ft()-t<e;);}function co(e){let t=e.getExtension("ANGLE_instanced_arrays");if(t)return e.vertexAttribDivisor=function(r,A){t.vertexAttribDivisorANGLE(r,A)},e.drawArraysInstanced=function(r,A,i,o){t.drawArraysInstancedANGLE(r,A,i,o)},e.drawElementsInstanced=function(r,A,i,o,s){t.drawElementsInstancedANGLE(r,A,i,o,s)},1}function go(e){let t=e.getExtension("OES_vertex_array_object");if(t)return e.createVertexArray=function(){return t.createVertexArrayOES()},e.deleteVertexArray=function(r){t.deleteVertexArrayOES(r)},e.bindVertexArray=function(r){t.bindVertexArrayOES(r)},e.isVertexArray=function(r){return t.isVertexArrayOES(r)},1}function lo(e){let t=e.getExtension("WEBGL_draw_buffers");if(t)return e.drawBuffers=function(r,A){t.drawBuffersWEBGL(r,A)},1}function uo(e){return!!(e.dibvbi=e.getExtension("WEBGL_draw_instanced_base_vertex_base_instance"))}function Eo(e){return!!(e.mdibvbi=e.getExtension("WEBGL_multi_draw_instanced_base_vertex_base_instance"))}function fo(e){return!!(e.multiDrawWebgl=e.getExtension("WEBGL_multi_draw"))}var C={counter:1,buffers:[],mappedBuffers:{},programs:[],framebuffers:[],renderbuffers:[],textures:[],shaders:[],vaos:[],contexts:[],offscreenCanvases:{},queries:[],samplers:[],transformFeedbacks:[],syncs:[],byteSizeByTypeRoot:5120,byteSizeByType:[1,1,2,2,4,4,4,2,3,4,8],stringCache:{},stringiCache:{},unpackAlignment:4,recordError:function(t){C.lastError||(C.lastError=t)},getNewId(e){let t=C.counter++;for(let r=e.length;r<t;r++)e[r]=null;return t},MAX_TEMP_BUFFER_SIZE:2097152,numTempVertexBuffersPerSize:64,log2ceilLookup(e){return 32-Math.clz32(e===0?0:e-1)},generateTempBuffers(e,t){let r=C.log2ceilLookup(C.MAX_TEMP_BUFFER_SIZE);t.tempVertexBufferCounters1=[],t.tempVertexBufferCounters2=[],t.tempVertexBufferCounters1.length=t.tempVertexBufferCounters2.length=r+1,t.tempVertexBuffers1=[],t.tempVertexBuffers2=[],t.tempVertexBuffers1.length=t.tempVertexBuffers2.length=r+1,t.tempIndexBuffers=[],t.tempIndexBuffers.length=r+1;for(var A=0;A<=r;++A){t.tempIndexBuffers[A]=null,t.tempVertexBufferCounters1[A]=t.tempVertexBufferCounters2[A]=0;let i=C.numTempVertexBuffersPerSize;t.tempVertexBuffers1[A]=[],t.tempVertexBuffers2[A]=[];let o=t.tempVertexBuffers1[A],s=t.tempVertexBuffers2[A];o.length=s.length=i;for(let c=0;c<i;++c)o[c]=s[c]=null}if(e){t.tempQuadIndexBuffer=y.createBuffer(),t.GLctx.bindBuffer(34963,t.tempQuadIndexBuffer);let i=C.MAX_TEMP_BUFFER_SIZE>>1,o=new Uint16Array(i);var A=0;let c=0;for(;o[A++]=c,!(A>=i||(o[A++]=c+1,A>=i)||(o[A++]=c+2,A>=i)||(o[A++]=c,A>=i)||(o[A++]=c+2,A>=i)||(o[A++]=c+3,A>=i));)c+=4;t.GLctx.bufferData(34963,o,35044),t.GLctx.bindBuffer(34963,null)}},getTempVertexBuffer:function(t){let r=C.log2ceilLookup(t),A=C.currentContext.tempVertexBuffers1[r],i=C.currentContext.tempVertexBufferCounters1[r];C.currentContext.tempVertexBufferCounters1[r]=C.currentContext.tempVertexBufferCounters1[r]+1&C.numTempVertexBuffersPerSize-1;let o=A[i];if(o)return o;let s=y.getParameter(34964);return A[i]=y.createBuffer(),y.bindBuffer(34962,A[i]),y.bufferData(34962,1<<r,35048),y.bindBuffer(34962,s),A[i]},getTempIndexBuffer:function(t){let r=C.log2ceilLookup(t),A=C.currentContext.tempIndexBuffers[r];if(A)return A;let i=y.getParameter(34965);return C.currentContext.tempIndexBuffers[r]=y.createBuffer(),y.bindBuffer(34963,C.currentContext.tempIndexBuffers[r]),y.bufferData(34963,1<<r,35048),y.bindBuffer(34963,i),C.currentContext.tempIndexBuffers[r]},newRenderingFrameStarted:function(){if(!C.currentContext)return;let t=C.currentContext.tempVertexBuffers1;C.currentContext.tempVertexBuffers1=C.currentContext.tempVertexBuffers2,C.currentContext.tempVertexBuffers2=t,t=C.currentContext.tempVertexBufferCounters1,C.currentContext.tempVertexBufferCounters1=C.currentContext.tempVertexBufferCounters2,C.currentContext.tempVertexBufferCounters2=t;let r=C.log2ceilLookup(C.MAX_TEMP_BUFFER_SIZE);for(let A=0;A<=r;++A)C.currentContext.tempVertexBufferCounters1[A]=0},get
`},"%p"(D){return D.tm_hour>=0&&D.tm_hour<12?"AM":"PM"},"%S"(D){return h(D.tm_sec,2)},"%t"(){return" "},"%u"(D){return D.tm_wday||7},"%U"(D){let F=new Date(D.tm_year+1900,0,1),te=F.getDay()===0?F:_n(F,7-F.getDay()),x=new Date(D.tm_year+1900,D.tm_mon,D.tm_mday);if(_(te,x)<0){let Ie=yA(hn(x.getFullYear())?mn:Qn,x.getMonth()-1)-31,nt=31-te.getDate()+Ie+x.getDate();return h(Math.ceil(nt/7),2)}return _(te,F)===0?"01":"00"},"%V"(D){let F=new Date(D.tm_year+1900,0,4),te=new Date(D.tm_year+1901,0,4),x=O(F),Ie=O(te),we=_n(new Date(D.tm_year+1900,0,1),D.tm_yday);if(_(we,x)<0)return"53";if(_(Ie,we)<=0)return"01";let nt;return x.getFullYear()<D.tm_year+1900?nt=D.tm_yday+32-x.getDate():nt=D.tm_yday+1-x.getDate(),h(Math.ceil(nt/7),2)},"%w"(D){return D.tm_wday},"%W"(D){let F=new Date(D.tm_year,0,1),te=F.getDay()===1?F:_n(F,F.getDay()===0?1:7-F.getDay()+1),x=new Date(D.tm_year+1900,D.tm_mon,D.tm_mday);if(_(te,x)<0){let Ie=yA(hn(x.getFullYear())?mn:Qn,x.getMonth()-1)-31,nt=31-te.getDate()+Ie+x.getDate();return h(Math.ceil(nt/7),2)}return _(te,F)===0?"01":"00"},"%y"(D){return(D.tm_year+1900).toString().substring(2)},"%Y"(D){return D.tm_year+1900},"%z"(D){let F=D.tm_gmtoff,te=F>=0;return F=Math.abs(F)/60,F=F/60*100+F%60,(te?"+":"-")+`0000${F}`.slice(-4)},"%Z"(D){return D.tm_zone},"%%"(){return"%"}};for(var d in Y)s.includes(d)&&(s=s.replace(new RegExp(d,"g"),Y[d](o)));let q=wn(s,!1);return q.length>t?0:(xr(q,e),q.length-1)}function qs(e,t,r,A){return KA(e,t,r,A)}n.requestFullscreen=function(t,r){Q.requestFullscreen(t,r)},n.requestFullScreen=function(){Q.requestFullScreen()},n.requestAnimationFrame=function(t){Q.requestAnimationFrame(t)},n.setCanvasSize=function(t,r,A){Q.setCanvasSize(t,r,A)},n.pauseMainLoop=function(){Q.mainLoop.pause()},n.resumeMainLoop=function(){Q.mainLoop.resume()},n.getUserMedia=function(){Q.getUserMedia()},n.createContext=function(t,r,A,i){return Q.createContext(t,r,A,i)};let VA=function(e,t,r,A){e||(e=this),this.parent=e,this.mount=e.mount,this.mounted=null,this.id=a.nextInode++,this.name=t,this.mode=r,this.node_ops={},this.stream_ops={},this.rdev=A},yn=365,Dn=146;Object.defineProperties(VA.prototype,{read:{get(){return(this.mode&yn)===yn},set(e){e?this.mode|=yn:this.mode&=~yn}},write:{get(){return(this.mode&Dn)===Dn},set(e){e?this.mode|=Dn:this.mode&=~Dn}},isFolder:{get(){return a.isDir(this.mode)}},isDevice:{get(){return a.isChrdev(this.mode)}}}),a.FSNode=VA,a.staticInit(),n.FS_createPath=a.createPath,n.FS_createDataFile=a.createDataFile,n.FS_createPreloadedFile=a.createPreloadedFile,n.FS_createLazyFile=a.createLazyFile,n.FS_createDevice=a.createDevice,n.FS_unlink=a.unlink,dA(),An=n.PureVirtualError=or(Error,"PureVirtualError"),mr(),CA(),Rt=n.BindingError=or(Error,"BindingError"),S=n.InternalError=or(Error,"InternalError"),br(),Bi(),kA=n.UnboundTypeError=or(Error,"UnboundTypeError");let y;for(var Ge=0;Ge<32;++Ge)XA.push(new Array(Ge));let ea=new Float32Array(288);for(var Ge=0;Ge<288;++Ge)Cn[Ge]=ea.subarray(0,Ge+1);let ta=new Int32Array(288);for(var Ge=0;Ge<288;++Ge)JA[Ge]=ta.subarray(0,Ge+1);let bc=!0;function wn(e,t,r){let A=r>0?r:yt(e)+1,i=new Array(A),o=_t(e,i,0,i.length);return t&&(i.length=o),i}let ra=typeof atob=="function"?atob:function(e){let t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",r="",A,i,o,s,c,d,E,I=0;e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"");do s=t.indexOf(e.charAt(I++)),c=t.indexOf(e.charAt(I++)),d=t.indexOf(e.charAt(I++)),E=t.indexOf(e.charAt(I++)),A=s<<2|c>>4,i=(c&15)<<4|d>>2,o=(d&3)<<6|E,r=r+String.fromCharCode(A),d!==64&&(r=r+String.fromCharCode(i)),E!==64&&(r=r+String.fromCharCode(o));while(I<e.length);return r};function Tc(e){if(typeof ht=="boolean"&&ht){let t=Buffer.from(e,"base64");return new Uint8Array(t.buffer,t.byteOffset,t.byteLength)}try{let t=ra(e),r=new Uint8Array(t.length);for(let A=0;A<t.length;++A)r[A]=t.charCodeAt(A);return r}catch(t){throw new Error("Converting base64 string to bytes failed.")}}var $A={HaveOffsetConverter:Xr,__cxa_allocate_exception:tr,__cxa_atexit:Kr,__cxa_begin_catch:Vr,__cxa_end_catch:pr,__cxa_find_matching_catch_2:Zr,__cxa_find_matchi
`+w.replace(/^Error(:[^\n]*)?\n/,""))});return f.prototype=Object.create(l.prototype),f.prototype.constructor=f,f.prototype.toString=function(){return this.message===void 0?this.name:`${this.name}: ${this.message}`},f},nr,Vr=l=>{var g=Ht(l),f=me(g);return Le(g),f},ke=(l,g)=>{var f=[],p={};function w(S){if(!p[S]&&!st[S]){if(Ve[S]){Ve[S].forEach(w);return}f.push(S),p[S]=!0}}throw g.forEach(w),new nr(`${l}: `+f.map(Vr).join([", "]))},$r=(l,g,f,p,w,S,P,b,N,L,k,K,re)=>{k=me(k),S=Fe(w,S),b&&(b=Fe(P,b)),L&&(L=Fe(N,L)),re=Fe(K,re);var ne=Wr(k);Ir(ne,function(){ke(`Cannot construct ${k} due to unbound types`,[p])}),$e([l,g,f],p?[p]:[],fe=>{var sr,Tr;fe=fe[0];var De,Oe;p?(De=fe.registeredClass,Oe=De.instancePrototype):Oe=Me.prototype;var Qe=Ut(k,function(...Or){if(Object.getPrototypeOf(this)!==pt)throw new Et("Use 'new' to construct "+k);if(_e.constructor_body===void 0)throw new Et(k+" has no accessible constructor");var Xt=_e.constructor_body[Or.length];if(Xt===void 0)throw new Et(`Tried to invoke ctor of ${k} with invalid number of parameters (${Or.length}) - expected (${Object.keys(_e.constructor_body).toString()}) parameters instead!`);return Xt.apply(this,Or)}),pt=Object.create(Oe,{constructor:{value:Qe}});Qe.prototype=pt;var _e=new Wn(k,Qe,pt,re,De,S,b,L);_e.baseClass&&((Tr=(sr=_e.baseClass).__derivedClasses)!=null||(sr.__derivedClasses=[]),_e.baseClass.__derivedClasses.push(_e));var br=new xt(k,_e,!0,!1,!1),Be=new xt(k+"*",_e,!1,!1,!1),Yt=new xt(k+" const*",_e,!1,!0,!1);return ct[l]={pointerType:Be,constPointerType:Yt},Kn(ne,Qe),[br,Be,Yt]})},zr=(l,g)=>{for(var f=[],p=0;p<l;p++)f.push(ae[g+p*4>>2]);return f},pr=l=>{for(;l.length;){var g=l.pop(),f=l.pop();f(g)}};function Zn(l){for(var g=1;g<l.length;++g)if(l[g]!==null&&l[g].destructorFunction===void 0)return!0;return!1}function Zr(l,g,f,p,w,S){var P=g.length;P<2&&$("argTypes array size mismatch! Must at least get return value and 'this' types!");var b=g[1]!==null&&f!==null,N=Zn(g),L=g[0].name!=="void",k=P-2,K=new Array(k),re=[],ne=[],fe=function(...De){De.length!==k&&$(`function ${l} called with ${De.length} arguments, expected ${k}`),ne.length=0;var Oe;re.length=b?2:1,re[0]=w,b&&(Oe=g[1].toWireType(ne,this),re[1]=Oe);for(var Qe=0;Qe<k;++Qe)K[Qe]=g[Qe+2].toWireType(ne,De[Qe]),re.push(K[Qe]);var pt=p(...re);function _e(br){if(N)pr(ne);else for(var Be=b?1:2;Be<g.length;Be++){var Yt=Be===1?Oe:K[Be-2];g[Be].destructorFunction!==null&&g[Be].destructorFunction(Yt)}if(L)return g[0].fromWireType(br)}return _e(pt)};return Ut(l,fe)}var qn=(l,g,f,p,w,S)=>{var P=zr(g,f);w=Fe(p,w),$e([],[l],b=>{b=b[0];var N=`constructor ${b.name}`;if(b.registeredClass.constructor_body===void 0&&(b.registeredClass.constructor_body=[]),b.registeredClass.constructor_body[g-1]!==void 0)throw new Et(`Cannot register multiple constructors with identical number of parameters (${g-1}) for class '${b.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);return b.registeredClass.constructor_body[g-1]=()=>{ke(`Cannot construct ${b.name} due to unbound types`,P)},$e([],P,L=>(L.splice(1,0,null),b.registeredClass.constructor_body[g-1]=Zr(N,L,null,w,S),[])),[]})},eA=l=>{l=l.trim();let g=l.indexOf("(");return g!==-1?l.substr(0,g):l},tA=(l,g,f,p,w,S,P,b,N)=>{var L=zr(f,p);g=me(g),g=eA(g),S=Fe(w,S),$e([],[l],k=>{k=k[0];var K=`${k.name}.${g}`;g.startsWith("@@")&&(g=Symbol[g.substring(2)]),b&&k.registeredClass.pureVirtualFunctions.push(g);function re(){ke(`Cannot call ${K} due to unbound types`,L)}var ne=k.registeredClass.instancePrototype,fe=ne[g];return fe===void 0||fe.overloadTable===void 0&&fe.className!==k.name&&fe.argCount===f-2?(re.argCount=f-2,re.className=k.name,ne[g]=re):(Xr(ne,g,K),ne[g].overloadTable[f-2]=re),$e([],L,De=>{var Oe=Zr(K,De,k,S,P,N);return ne[g].overloadTable===void 0?(Oe.argCount=f-2,ne[g]=Oe):ne[g].overloadTable[f-2]=Oe,[]}),[]})},qr=(l,g,f)=>(l instanceof Object||$(`${f} with invalid "this": ${l}`),l instanceof g.registeredClass.constructor||$(`${f} incompatible with "this" of type ${l.constructor.name}`),l.$$.ptr||$(`cannot call emscripten bi