UNPKG

cornerstone-wado-image-loader

Version:
1 lines 813 kB
(()=>{var A,I,g={4559:(A,I,g)=>{A.exports=g(9842)},7552:(A,I,g)=>{A.exports=g(5697)},7647:(A,I,g)=>{A.exports=g(3798)},6028:(A,I,g)=>{A.exports=g(671)},337:(A,I,g)=>{A.exports=g(3751)},2770:(A,I,g)=>{A.exports=g(1380)},1882:(A,I,g)=>{A.exports=g(6601)},7878:(A,I,g)=>{A.exports=g(8783)},2250:(A,I,g)=>{A.exports=g(4731)},1082:(A,I,g)=>{A.exports=g(5723)},5534:(A,I,g)=>{A.exports=g(5213)},7458:A=>{var I=function(A){"use strict";var I,g=Object.prototype,C=g.hasOwnProperty,B="function"==typeof Symbol?Symbol:{},Q=B.iterator||"@@iterator",E=B.asyncIterator||"@@asyncIterator",i=B.toStringTag||"@@toStringTag";function o(A,I,g){return Object.defineProperty(A,I,{value:g,enumerable:!0,configurable:!0,writable:!0}),A[I]}try{o({},"")}catch(A){o=function(A,I,g){return A[I]=g}}function D(A,I,g,C){var B=I&&I.prototype instanceof r?I:r,Q=Object.create(B.prototype),E=new K(C||[]);return Q._invoke=function(A,I,g){var C=t;return function(B,Q){if(C===F)throw new Error("Generator is already running");if(C===n){if("throw"===B)throw Q;return M()}for(g.method=B,g.arg=Q;;){var E=g.delegate;if(E){var i=U(E,g);if(i){if(i===w)continue;return i}}if("next"===g.method)g.sent=g._sent=g.arg;else if("throw"===g.method){if(C===t)throw C=n,g.arg;g.dispatchException(g.arg)}else"return"===g.method&&g.abrupt("return",g.arg);C=F;var o=a(A,I,g);if("normal"===o.type){if(C=g.done?n:s,o.arg===w)continue;return{value:o.arg,done:g.done}}"throw"===o.type&&(C=n,g.method="throw",g.arg=o.arg)}}}(A,g,E),Q}function a(A,I,g){try{return{type:"normal",arg:A.call(I,g)}}catch(A){return{type:"throw",arg:A}}}A.wrap=D;var t="suspendedStart",s="suspendedYield",F="executing",n="completed",w={};function r(){}function e(){}function h(){}var G={};o(G,Q,(function(){return this}));var y=Object.getPrototypeOf,c=y&&y(y(Y([])));c&&c!==g&&C.call(c,Q)&&(G=c);var N=h.prototype=r.prototype=Object.create(G);function R(A){["next","throw","return"].forEach((function(I){o(A,I,(function(A){return this._invoke(I,A)}))}))}function S(A,I){function g(B,Q,E,i){var o=a(A[B],A,Q);if("throw"!==o.type){var D=o.arg,t=D.value;return t&&"object"==typeof t&&C.call(t,"__await")?I.resolve(t.__await).then((function(A){g("next",A,E,i)}),(function(A){g("throw",A,E,i)})):I.resolve(t).then((function(A){D.value=A,E(D)}),(function(A){return g("throw",A,E,i)}))}i(o.arg)}var B;this._invoke=function(A,C){function Q(){return new I((function(I,B){g(A,C,I,B)}))}return B=B?B.then(Q,Q):Q()}}function U(A,g){var C=A.iterator[g.method];if(C===I){if(g.delegate=null,"throw"===g.method){if(A.iterator.return&&(g.method="return",g.arg=I,U(A,g),"throw"===g.method))return w;g.method="throw",g.arg=new TypeError("The iterator does not provide a 'throw' method")}return w}var B=a(C,A.iterator,g.arg);if("throw"===B.type)return g.method="throw",g.arg=B.arg,g.delegate=null,w;var Q=B.arg;return Q?Q.done?(g[A.resultName]=Q.value,g.next=A.nextLoc,"return"!==g.method&&(g.method="next",g.arg=I),g.delegate=null,w):Q:(g.method="throw",g.arg=new TypeError("iterator result is not an object"),g.delegate=null,w)}function k(A){var I={tryLoc:A[0]};1 in A&&(I.catchLoc=A[1]),2 in A&&(I.finallyLoc=A[2],I.afterLoc=A[3]),this.tryEntries.push(I)}function J(A){var I=A.completion||{};I.type="normal",delete I.arg,A.completion=I}function K(A){this.tryEntries=[{tryLoc:"root"}],A.forEach(k,this),this.reset(!0)}function Y(A){if(A){var g=A[Q];if(g)return g.call(A);if("function"==typeof A.next)return A;if(!isNaN(A.length)){var B=-1,E=function g(){for(;++B<A.length;)if(C.call(A,B))return g.value=A[B],g.done=!1,g;return g.value=I,g.done=!0,g};return E.next=E}}return{next:M}}function M(){return{value:I,done:!0}}return e.prototype=h,o(N,"constructor",h),o(h,"constructor",e),e.displayName=o(h,i,"GeneratorFunction"),A.isGeneratorFunction=function(A){var I="function"==typeof A&&A.constructor;return!!I&&(I===e||"GeneratorFunction"===(I.displayName||I.name))},A.mark=function(A){return Object.setPrototypeOf?Object.setPrototypeOf(A,h):(A.__proto__=h,o(A,i,"GeneratorFunction")),A.prototype=Object.create(N),A},A.awrap=function(A){return{__await:A}},R(S.prototype),o(S.prototype,E,(function(){return this})),A.AsyncIterator=S,A.async=function(I,g,C,B,Q){void 0===Q&&(Q=Promise);var E=new S(D(I,g,C,B),Q);return A.isGeneratorFunction(g)?E:E.next().then((function(A){return A.done?A.value:E.next()}))},R(N),o(N,i,"Generator"),o(N,Q,(function(){return this})),o(N,"toString",(function(){return"[object Generator]"})),A.keys=function(A){var I=[];for(var g in A)I.push(g);return I.reverse(),function g(){for(;I.length;){var C=I.pop();if(C in A)return g.value=C,g.done=!1,g}return g.done=!0,g}},A.values=Y,K.prototype={constructor:K,reset:function(A){if(this.prev=0,this.next=0,this.sent=this._sent=I,this.done=!1,this.delegate=null,this.method="next",this.arg=I,this.tryEntries.forEach(J),!A)for(var g in this)"t"===g.charAt(0)&&C.call(this,g)&&!isNaN(+g.slice(1))&&(this[g]=I)},stop:function(){this.done=!0;var A=this.tryEntries[0].completion;if("throw"===A.type)throw A.arg;return this.rval},dispatchException:function(A){if(this.done)throw A;var g=this;function B(C,B){return i.type="throw",i.arg=A,g.next=C,B&&(g.method="next",g.arg=I),!!B}for(var Q=this.tryEntries.length-1;Q>=0;--Q){var E=this.tryEntries[Q],i=E.completion;if("root"===E.tryLoc)return B("end");if(E.tryLoc<=this.prev){var o=C.call(E,"catchLoc"),D=C.call(E,"finallyLoc");if(o&&D){if(this.prev<E.catchLoc)return B(E.catchLoc,!0);if(this.prev<E.finallyLoc)return B(E.finallyLoc)}else if(o){if(this.prev<E.catchLoc)return B(E.catchLoc,!0)}else{if(!D)throw new Error("try statement without catch or finally");if(this.prev<E.finallyLoc)return B(E.finallyLoc)}}}},abrupt:function(A,I){for(var g=this.tryEntries.length-1;g>=0;--g){var B=this.tryEntries[g];if(B.tryLoc<=this.prev&&C.call(B,"finallyLoc")&&this.prev<B.finallyLoc){var Q=B;break}}Q&&("break"===A||"continue"===A)&&Q.tryLoc<=I&&I<=Q.finallyLoc&&(Q=null);var E=Q?Q.completion:{};return E.type=A,E.arg=I,Q?(this.method="next",this.next=Q.finallyLoc,w):this.complete(E)},complete:function(A,I){if("throw"===A.type)throw A.arg;return"break"===A.type||"continue"===A.type?this.next=A.arg:"return"===A.type?(this.rval=this.arg=A.arg,this.method="return",this.next="end"):"normal"===A.type&&I&&(this.next=I),w},finish:function(A){for(var I=this.tryEntries.length-1;I>=0;--I){var g=this.tryEntries[I];if(g.finallyLoc===A)return this.complete(g.completion,g.afterLoc),J(g),w}},catch:function(A){for(var I=this.tryEntries.length-1;I>=0;--I){var g=this.tryEntries[I];if(g.tryLoc===A){var C=g.completion;if("throw"===C.type){var B=C.arg;J(g)}return B}}throw new Error("illegal catch attempt")},delegateYield:function(A,g,C){return this.delegate={iterator:Y(A),resultName:g,nextLoc:C},"next"===this.method&&(this.arg=I),w}},A}(A.exports);try{regeneratorRuntime=I}catch(A){"object"==typeof globalThis?globalThis.regeneratorRuntime=I:Function("r","regeneratorRuntime = r")(I)}},2043:(A,I,g)=>{A.exports=g(7458)},8327:(A,I,g)=>{var C,B=(C=(C="undefined"!=typeof document&&document.currentScript?document.currentScript.src:void 0)||"/index.js",function(A){var I,B=void 0!==(A=A||{})?A:{},Q={};for(I in B)B.hasOwnProperty(I)&&(Q[I]=B[I]);var E=[],i=!1,o=!1,D=!1,a=!1;i="object"==typeof window,o="function"==typeof importScripts,D="object"==typeof process&&"object"==typeof process.versions&&"string"==typeof process.versions.node&&!i&&!o,a=!i&&!D&&!o;var t,s,F,n,w="";function r(A){return B.locateFile?B.locateFile(A,w):w+A}D?(w="//",t=function(A,I){return F||(F=g(981)),n||(n=g(1209)),A=n.normalize(A),F.readFileSync(A,I?null:"utf8")},s=function(A){var I=t(A,!0);return I.buffer||(I=new Uint8Array(I)),S(I.buffer),I},process.argv.length>1&&process.argv[1].replace(/\\/g,"/"),E=process.argv.slice(2),process.on("uncaughtException",(function(A){if(!(A instanceof xg))throw A})),process.on("unhandledRejection",sA),B.inspect=function(){return"[Emscripten Module object]"}):a?("undefined"!=typeof read&&(t=function(A){return read(A)}),s=function(A){var I;return"function"==typeof readbuffer?new Uint8Array(readbuffer(A)):(S("object"==typeof(I=read(A,"binary"))),I)},"undefined"!=typeof scriptArgs?E=scriptArgs:void 0!==arguments&&(E=arguments),"undefined"!=typeof print&&("undefined"==typeof console&&(console={}),console.log=print,console.warn=console.error="undefined"!=typeof printErr?printErr:print)):(i||o)&&(o?w=self.location.href:document.currentScript&&(w=document.currentScript.src),C&&(w=C),w=0!==w.indexOf("blob:")?w.substr(0,w.lastIndexOf("/")+1):"",t=function(A){var I=new XMLHttpRequest;return I.open("GET",A,!1),I.send(null),I.responseText},o&&(s=function(A){var I=new XMLHttpRequest;return I.open("GET",A,!1),I.responseType="arraybuffer",I.send(null),new Uint8Array(I.response)}));var e=B.print||console.log.bind(console),h=B.printErr||console.warn.bind(console);for(I in Q)Q.hasOwnProperty(I)&&(B[I]=Q[I]);Q=null,B.arguments&&(E=B.arguments),B.thisProgram&&B.thisProgram,B.quit&&B.quit;var G,y,c=function(A){};B.wasmBinary&&(G=B.wasmBinary),B.noExitRuntime&&B.noExitRuntime,"object"!=typeof WebAssembly&&h("no native wasm support detected");var N=new WebAssembly.Table({initial:181,maximum:181,element:"anyfunc"}),R=!1;function S(A,I){A||sA("Assertion failed: "+I)}function U(A){var I=B["_"+A];return S(I,"Cannot call unknown function "+A+", make sure it is exported"),I}function k(A,I,g,C,B){var Q={string:function(A){var I=0;if(null!=A&&0!==A){var g=1+(A.length<<2);L(A,I=mg(g),g)}return I},array:function(A){var I=mg(A.length);return d(A,I),I}},E=U(A),i=[],o=0;if(C)for(var D=0;D<C.length;D++){var a=Q[g[D]];a?(0===o&&(o=Wg()),i[D]=a(C[D])):i[D]=C[D]}var t=E.apply(null,i);return t=function(A){return"string"===I?Y(A):"boolean"===I?Boolean(A):A}(t),0!==o&&Xg(o),t}var J="undefined"!=typeof TextDecoder?new TextDecoder("utf8"):void 0;function K(A,I,g){for(var C=I+g,B=I;A[B]&&!(B>=C);)++B;if(B-I>16&&A.subarray&&J)return J.decode(A.subarray(I,B));for(var Q="";I<B;){var E=A[I++];if(128&E){var i=63&A[I++];if(192!=(224&E)){var o=63&A[I++];if((E=224==(240&E)?(15&E)<<12|i<<6|o:(7&E)<<18|i<<12|o<<6|63&A[I++])<65536)Q+=String.fromCharCode(E);else{var D=E-65536;Q+=String.fromCharCode(55296|D>>10,56320|1023&D)}}else Q+=String.fromCharCode((31&E)<<6|i)}else Q+=String.fromCharCode(E)}return Q}function Y(A,I){return A?K(u,A,I):""}function M(A,I,g,C){if(!(C>0))return 0;for(var B=g,Q=g+C-1,E=0;E<A.length;++E){var i=A.charCodeAt(E);if(i>=55296&&i<=57343&&(i=65536+((1023&i)<<10)|1023&A.charCodeAt(++E)),i<=127){if(g>=Q)break;I[g++]=i}else if(i<=2047){if(g+1>=Q)break;I[g++]=192|i>>6,I[g++]=128|63&i}else if(i<=65535){if(g+2>=Q)break;I[g++]=224|i>>12,I[g++]=128|i>>6&63,I[g++]=128|63&i}else{if(g+3>=Q)break;I[g++]=240|i>>18,I[g++]=128|i>>12&63,I[g++]=128|i>>6&63,I[g++]=128|63&i}}return I[g]=0,g-B}function L(A,I,g){return M(A,u,I,g)}function l(A){for(var I=0,g=0;g<A.length;++g){var C=A.charCodeAt(g);C>=55296&&C<=57343&&(C=65536+((1023&C)<<10)|1023&A.charCodeAt(++g)),C<=127?++I:I+=C<=2047?2:C<=65535?3:4}return I}function d(A,I){f.set(A,I)}"undefined"!=typeof TextDecoder&&new TextDecoder("utf-16le");var H,f,u,q,p,b,Z,W,m,X=65536;function x(A,I){return A%I>0&&(A+=I-A%I),A}function V(A){H=A,B.HEAP8=f=new Int8Array(A),B.HEAP16=q=new Int16Array(A),B.HEAP32=b=new Int32Array(A),B.HEAPU8=u=new Uint8Array(A),B.HEAPU16=p=new Uint16Array(A),B.HEAPU32=Z=new Uint32Array(A),B.HEAPF32=W=new Float32Array(A),B.HEAPF64=m=new Float64Array(A)}var v=5289088,T=46048,j=B.TOTAL_MEMORY||1073741824;function P(A){for(;A.length>0;){var I=A.shift();if("function"!=typeof I){var g=I.func;"number"==typeof g?void 0===I.arg?B.dynCall_v(g):B.dynCall_vi(g,I.arg):g(void 0===I.arg?null:I.arg)}else I()}}(y=B.wasmMemory?B.wasmMemory:new WebAssembly.Memory({initial:j/X}))&&(H=y.buffer),j=H.byteLength,V(H),b[T>>2]=v;var O=[],z=[],_=[],$=[],AA=[];function IA(){if(B.preRun)for("function"==typeof B.preRun&&(B.preRun=[B.preRun]);B.preRun.length;)QA(B.preRun.shift());P(O)}function gA(){P(z)}function CA(){P(_)}function BA(){if(B.postRun)for("function"==typeof B.postRun&&(B.postRun=[B.postRun]);B.postRun.length;)EA(B.postRun.shift());P(AA)}function QA(A){O.unshift(A)}function EA(A){AA.unshift(A)}Math.abs,Math.ceil,Math.floor,Math.min;var iA=0,oA=null,DA=null;function aA(A){iA++,B.monitorRunDependencies&&B.monitorRunDependencies(iA)}function tA(A){if(iA--,B.monitorRunDependencies&&B.monitorRunDependencies(iA),0==iA&&(null!==oA&&(clearInterval(oA),oA=null),DA)){var I=DA;DA=null,I()}}function sA(A){throw B.onAbort&&B.onAbort(A),e(A+=""),h(A),R=!0,A="abort("+A+"). Build with -s ASSERTIONS=1 for more info.",new WebAssembly.RuntimeError(A)}B.preloadedImages={},B.preloadedAudios={};var FA="data:application/octet-stream;base64,";function nA(A){return String.prototype.startsWith?A.startsWith(FA):0===A.indexOf(FA)}var wA="charlswasm_decode.wasm";function rA(){try{if(G)return new Uint8Array(G);if(s)return s(wA);throw"both async and sync fetching of the wasm failed"}catch(A){sA(A)}}function eA(){return G||!i&&!o||"function"!=typeof fetch?new Promise((function(A,I){A(rA())})):fetch(wA,{credentials:"same-origin"}).then((function(A){if(!A.ok)throw"failed to load wasm binary file at '"+wA+"'";return A.arrayBuffer()})).catch((function(){return rA()}))}function hA(){var A={env:dg,wasi_snapshot_preview1:dg};function I(A,I){var g=A.exports;B.asm=g,tA()}function g(A){I(A.instance)}function C(I){return eA().then((function(I){return WebAssembly.instantiate(I,A)})).then(I,(function(A){h("failed to asynchronously prepare wasm: "+A),sA(A)}))}if(aA(),B.instantiateWasm)try{return B.instantiateWasm(A,I)}catch(A){return h("Module.instantiateWasm callback failed with error: "+A),!1}return function(){if(G||"function"!=typeof WebAssembly.instantiateStreaming||nA(wA)||"function"!=typeof fetch)return C(g);fetch(wA,{credentials:"same-origin"}).then((function(I){return WebAssembly.instantiateStreaming(I,A).then(g,(function(A){h("wasm streaming compile failed: "+A),h("falling back to ArrayBuffer instantiation"),C(g)}))}))}(),{}}function GA(A){return qg(A)}function yA(A,I){$.unshift({func:A,arg:I})}function cA(){return yA.apply(null,arguments)}function NA(){return yA.apply(null,arguments)}nA(wA)||(wA=r(wA)),z.push({func:function(){ug()}});var RA={};function SA(A,I,g){throw RA[A]={ptr:A,adjusted:[A],type:I,destructor:g,refcount:0,caught:!1,rethrown:!1},"uncaught_exception"in pg?pg.uncaught_exceptions++:pg.uncaught_exceptions=1,A}var UA={};function kA(A){for(;A.length;){var I=A.pop();A.pop()(I)}}function JA(A){return this.fromWireType(Z[A>>2])}var KA={},YA={},MA={},LA=48,lA=57;function dA(A){if(void 0===A)return"_unknown";var I=(A=A.replace(/[^a-zA-Z0-9_]/g,"$")).charCodeAt(0);return I>=LA&&I<=lA?"_"+A:A}function HA(A,I){return A=dA(A),new Function("body","return function "+A+'() {\n "use strict"; return body.apply(this, arguments);\n};\n')(I)}function fA(A,I){var g=HA(I,(function(A){this.name=I,this.message=A;var g=new Error(A).stack;void 0!==g&&(this.stack=this.toString()+"\n"+g.replace(/^Error(:[^\n]*)?\n/,""))}));return g.prototype=Object.create(A.prototype),g.prototype.constructor=g,g.prototype.toString=function(){return void 0===this.message?this.name:this.name+": "+this.message},g}var uA=void 0;function qA(A){throw new uA(A)}function pA(A,I,g){function C(I){var C=g(I);C.length!==A.length&&qA("Mismatched type converter count");for(var B=0;B<A.length;++B)vA(A[B],C[B])}A.forEach((function(A){MA[A]=I}));var B=new Array(I.length),Q=[],E=0;I.forEach((function(A,I){YA.hasOwnProperty(A)?B[I]=YA[A]:(Q.push(A),KA.hasOwnProperty(A)||(KA[A]=[]),KA[A].push((function(){B[I]=YA[A],++E===Q.length&&C(B)})))})),0===Q.length&&C(B)}function bA(A){var I=UA[A];delete UA[A];var g=I.rawConstructor,C=I.rawDestructor,B=I.fields;pA([A],B.map((function(A){return A.getterReturnType})).concat(B.map((function(A){return A.setterArgumentType}))),(function(A){var Q={};return B.forEach((function(I,g){var C=I.fieldName,E=A[g],i=I.getter,o=I.getterContext,D=A[g+B.length],a=I.setter,t=I.setterContext;Q[C]={read:function(A){return E.fromWireType(i(o,A))},write:function(A,I){var g=[];a(t,A,D.toWireType(g,I)),kA(g)}}})),[{name:I.name,fromWireType:function(A){var I={};for(var g in Q)I[g]=Q[g].read(A);return C(A),I},toWireType:function(A,I){for(var B in Q)if(!(B in I))throw new TypeError("Missing field");var E=g();for(B in Q)Q[B].write(E,I[B]);return null!==A&&A.push(C,E),E},argPackAdvance:8,readValueFromPointer:JA,destructorFunction:C}]}))}function ZA(A){switch(A){case 1:return 0;case 2:return 1;case 4:return 2;case 8:return 3;default:throw new TypeError("Unknown type size: "+A)}}function WA(){for(var A=new Array(256),I=0;I<256;++I)A[I]=String.fromCharCode(I);mA=A}var mA=void 0;function XA(A){for(var I="",g=A;u[g];)I+=mA[u[g++]];return I}var xA=void 0;function VA(A){throw new xA(A)}function vA(A,I,g){if(g=g||{},!("argPackAdvance"in I))throw new TypeError("registerType registeredInstance requires argPackAdvance");var C=I.name;if(A||VA('type "'+C+'" must have a positive integer typeid pointer'),YA.hasOwnProperty(A)){if(g.ignoreDuplicateRegistrations)return;VA("Cannot register type '"+C+"' twice")}if(YA[A]=I,delete MA[A],KA.hasOwnProperty(A)){var B=KA[A];delete KA[A],B.forEach((function(A){A()}))}}function TA(A,I,g,C,B){var Q=ZA(g);vA(A,{name:I=XA(I),fromWireType:function(A){return!!A},toWireType:function(A,I){return I?C:B},argPackAdvance:8,readValueFromPointer:function(A){var C;if(1===g)C=f;else if(2===g)C=q;else{if(4!==g)throw new TypeError("Unknown boolean type size: "+I);C=b}return this.fromWireType(C[A>>Q])},destructorFunction:null})}function jA(A){if(!(this instanceof aI))return!1;if(!(A instanceof aI))return!1;for(var I=this.$$.ptrType.registeredClass,g=this.$$.ptr,C=A.$$.ptrType.registeredClass,B=A.$$.ptr;I.baseClass;)g=I.upcast(g),I=I.baseClass;for(;C.baseClass;)B=C.upcast(B),C=C.baseClass;return I===C&&g===B}function PA(A){return{count:A.count,deleteScheduled:A.deleteScheduled,preservePointerOnDelete:A.preservePointerOnDelete,ptr:A.ptr,ptrType:A.ptrType,smartPtr:A.smartPtr,smartPtrType:A.smartPtrType}}function OA(A){VA(A.$$.ptrType.registeredClass.name+" instance already deleted")}var zA=!1;function _A(A){}function $A(A){A.smartPtr?A.smartPtrType.rawDestructor(A.smartPtr):A.ptrType.registeredClass.rawDestructor(A.ptr)}function AI(A){A.count.value-=1,0===A.count.value&&$A(A)}function II(A){return"undefined"==typeof FinalizationGroup?(II=function(A){return A},A):(zA=new FinalizationGroup((function(A){for(var I=A.next();!I.done;I=A.next()){var g=I.value;g.ptr?AI(g):console.warn("object already deleted: "+g.ptr)}})),_A=function(A){zA.unregister(A.$$)},(II=function(A){return zA.register(A,A.$$,A.$$),A})(A))}function gI(){if(this.$$.ptr||OA(this),this.$$.preservePointerOnDelete)return this.$$.count.value+=1,this;var A=II(Object.create(Object.getPrototypeOf(this),{$$:{value:PA(this.$$)}}));return A.$$.count.value+=1,A.$$.deleteScheduled=!1,A}function CI(){this.$$.ptr||OA(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&VA("Object already scheduled for deletion"),_A(this),AI(this.$$),this.$$.preservePointerOnDelete||(this.$$.smartPtr=void 0,this.$$.ptr=void 0)}function BI(){return!this.$$.ptr}var QI=void 0,EI=[];function iI(){for(;EI.length;){var A=EI.pop();A.$$.deleteScheduled=!1,A.delete()}}function oI(){return this.$$.ptr||OA(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&VA("Object already scheduled for deletion"),EI.push(this),1===EI.length&&QI&&QI(iI),this.$$.deleteScheduled=!0,this}function DI(){aI.prototype.isAliasOf=jA,aI.prototype.clone=gI,aI.prototype.delete=CI,aI.prototype.isDeleted=BI,aI.prototype.deleteLater=oI}function aI(){}var tI={};function sI(A,I,g){if(void 0===A[I].overloadTable){var C=A[I];A[I]=function(){return A[I].overloadTable.hasOwnProperty(arguments.length)||VA("Function '"+g+"' called with an invalid number of arguments ("+arguments.length+") - expects one of ("+A[I].overloadTable+")!"),A[I].overloadTable[arguments.length].apply(this,arguments)},A[I].overloadTable=[],A[I].overloadTable[C.argCount]=C}}function FI(A,I,g){B.hasOwnProperty(A)?((void 0===g||void 0!==B[A].overloadTable&&void 0!==B[A].overloadTable[g])&&VA("Cannot register public name '"+A+"' twice"),sI(B,A,A),B.hasOwnProperty(g)&&VA("Cannot register multiple overloads of a function with the same number of arguments ("+g+")!"),B[A].overloadTable[g]=I):(B[A]=I,void 0!==g&&(B[A].numArguments=g))}function nI(A,I,g,C,B,Q,E,i){this.name=A,this.constructor=I,this.instancePrototype=g,this.rawDestructor=C,this.baseClass=B,this.getActualType=Q,this.upcast=E,this.downcast=i,this.pureVirtualFunctions=[]}function wI(A,I,g){for(;I!==g;)I.upcast||VA("Expected null or instance of "+g.name+", got an instance of "+I.name),A=I.upcast(A),I=I.baseClass;return A}function rI(A,I){if(null===I)return this.isReference&&VA("null is not a valid "+this.name),0;I.$$||VA('Cannot pass "'+$I(I)+'" as a '+this.name),I.$$.ptr||VA("Cannot pass deleted object as a pointer of type "+this.name);var g=I.$$.ptrType.registeredClass;return wI(I.$$.ptr,g,this.registeredClass)}function eI(A,I){var g;if(null===I)return this.isReference&&VA("null is not a valid "+this.name),this.isSmartPointer?(g=this.rawConstructor(),null!==A&&A.push(this.rawDestructor,g),g):0;I.$$||VA('Cannot pass "'+$I(I)+'" as a '+this.name),I.$$.ptr||VA("Cannot pass deleted object as a pointer of type "+this.name),!this.isConst&&I.$$.ptrType.isConst&&VA("Cannot convert argument of type "+(I.$$.smartPtrType?I.$$.smartPtrType.name:I.$$.ptrType.name)+" to parameter type "+this.name);var C=I.$$.ptrType.registeredClass;if(g=wI(I.$$.ptr,C,this.registeredClass),this.isSmartPointer)switch(void 0===I.$$.smartPtr&&VA("Passing raw pointer to smart pointer is illegal"),this.sharingPolicy){case 0:I.$$.smartPtrType===this?g=I.$$.smartPtr:VA("Cannot convert argument of type "+(I.$$.smartPtrType?I.$$.smartPtrType.name:I.$$.ptrType.name)+" to parameter type "+this.name);break;case 1:g=I.$$.smartPtr;break;case 2:if(I.$$.smartPtrType===this)g=I.$$.smartPtr;else{var B=I.clone();g=this.rawShare(g,zI((function(){B.delete()}))),null!==A&&A.push(this.rawDestructor,g)}break;default:VA("Unsupporting sharing policy")}return g}function hI(A,I){if(null===I)return this.isReference&&VA("null is not a valid "+this.name),0;I.$$||VA('Cannot pass "'+$I(I)+'" as a '+this.name),I.$$.ptr||VA("Cannot pass deleted object as a pointer of type "+this.name),I.$$.ptrType.isConst&&VA("Cannot convert argument of type "+I.$$.ptrType.name+" to parameter type "+this.name);var g=I.$$.ptrType.registeredClass;return wI(I.$$.ptr,g,this.registeredClass)}function GI(A){return this.rawGetPointee&&(A=this.rawGetPointee(A)),A}function yI(A){this.rawDestructor&&this.rawDestructor(A)}function cI(A){null!==A&&A.delete()}function NI(A,I,g){if(I===g)return A;if(void 0===g.baseClass)return null;var C=NI(A,I,g.baseClass);return null===C?null:g.downcast(C)}function RI(){return Object.keys(JI).length}function SI(){var A=[];for(var I in JI)JI.hasOwnProperty(I)&&A.push(JI[I]);return A}function UI(A){QI=A,EI.length&&QI&&QI(iI)}function kI(){B.getInheritedInstanceCount=RI,B.getLiveInheritedInstances=SI,B.flushPendingDeletes=iI,B.setDelayFunction=UI}var JI={};function KI(A,I){for(void 0===I&&VA("ptr should not be undefined");A.baseClass;)I=A.upcast(I),A=A.baseClass;return I}function YI(A,I){return I=KI(A,I),JI[I]}function MI(A,I){return I.ptrType&&I.ptr||qA("makeClassHandle requires ptr and ptrType"),!!I.smartPtrType!=!!I.smartPtr&&qA("Both smartPtrType and smartPtr must be specified"),I.count={value:1},II(Object.create(A,{$$:{value:I}}))}function LI(A){var I=this.getPointee(A);if(!I)return this.destructor(A),null;var g=YI(this.registeredClass,I);if(void 0!==g){if(0===g.$$.count.value)return g.$$.ptr=I,g.$$.smartPtr=A,g.clone();var C=g.clone();return this.destructor(A),C}function B(){return this.isSmartPointer?MI(this.registeredClass.instancePrototype,{ptrType:this.pointeeType,ptr:I,smartPtrType:this,smartPtr:A}):MI(this.registeredClass.instancePrototype,{ptrType:this,ptr:A})}var Q,E=this.registeredClass.getActualType(I),i=tI[E];if(!i)return B.call(this);Q=this.isConst?i.constPointerType:i.pointerType;var o=NI(I,this.registeredClass,Q.registeredClass);return null===o?B.call(this):this.isSmartPointer?MI(Q.registeredClass.instancePrototype,{ptrType:Q,ptr:o,smartPtrType:this,smartPtr:A}):MI(Q.registeredClass.instancePrototype,{ptrType:Q,ptr:o})}function lI(){dI.prototype.getPointee=GI,dI.prototype.destructor=yI,dI.prototype.argPackAdvance=8,dI.prototype.readValueFromPointer=JA,dI.prototype.deleteObject=cI,dI.prototype.fromWireType=LI}function dI(A,I,g,C,B,Q,E,i,o,D,a){this.name=A,this.registeredClass=I,this.isReference=g,this.isConst=C,this.isSmartPointer=B,this.pointeeType=Q,this.sharingPolicy=E,this.rawGetPointee=i,this.rawConstructor=o,this.rawShare=D,this.rawDestructor=a,B||void 0!==I.baseClass?this.toWireType=eI:C?(this.toWireType=rI,this.destructorFunction=null):(this.toWireType=hI,this.destructorFunction=null)}function HI(A,I,g){B.hasOwnProperty(A)||qA("Replacing nonexistant public symbol"),void 0!==B[A].overloadTable&&void 0!==g?B[A].overloadTable[g]=I:(B[A]=I,B[A].argCount=g)}function fI(A,I){var g;if(A=XA(A),void 0!==B["FUNCTION_TABLE_"+A])g=B["FUNCTION_TABLE_"+A][I];else if("undefined"!=typeof FUNCTION_TABLE)g=FUNCTION_TABLE[I];else{var C=B["dynCall_"+A];void 0===C&&void 0===(C=B["dynCall_"+A.replace(/f/g,"d")])&&VA("No dynCall invoker for signature: "+A),g=function(g){for(var C=[],B=1;B<A.length;++B)C.push("a"+B);var Q="return function dynCall_"+A+"_"+I+"("+C.join(", ")+") {\n";return Q+=" return dynCall(rawFunction"+(C.length?", ":"")+C.join(", ")+");\n",Q+="};\n",new Function("dynCall","rawFunction",Q)(g,I)}(C)}return"function"!=typeof g&&VA("unknown function pointer with signature "+A+": "+I),g}var uI=void 0;function qI(A){var I=Zg(A),g=XA(I);return bg(I),g}function pI(A,I){var g=[],C={};throw I.forEach((function A(I){C[I]||YA[I]||(MA[I]?MA[I].forEach(A):(g.push(I),C[I]=!0))})),new uI(A+": "+g.map(qI).join([", "]))}function bI(A,I,g,C,B,Q,E,i,o,D,a,t,s){a=XA(a),Q=fI(B,Q),i&&(i=fI(E,i)),D&&(D=fI(o,D)),s=fI(t,s);var F=dA(a);FI(F,(function(){pI("Cannot construct "+a+" due to unbound types",[C])})),pA([A,I,g],C?[C]:[],(function(I){var g,B;I=I[0],B=C?(g=I.registeredClass).instancePrototype:aI.prototype;var E=HA(F,(function(){if(Object.getPrototypeOf(this)!==o)throw new xA("Use 'new' to construct "+a);if(void 0===t.constructor_body)throw new xA(a+" has no accessible constructor");var A=t.constructor_body[arguments.length];if(void 0===A)throw new xA("Tried to invoke ctor of "+a+" with invalid number of parameters ("+arguments.length+") - expected ("+Object.keys(t.constructor_body).toString()+") parameters instead!");return A.apply(this,arguments)})),o=Object.create(B,{constructor:{value:E}});E.prototype=o;var t=new nI(a,E,o,s,g,Q,i,D),n=new dI(a,t,!0,!1,!1),w=new dI(a+"*",t,!1,!1,!1),r=new dI(a+" const*",t,!1,!0,!1);return tI[A]={pointerType:w,constPointerType:r},HI(F,E),[n,w,r]}))}function ZI(A,I){for(var g=[],C=0;C<A;C++)g.push(b[(I>>2)+C]);return g}function WI(A,I,g,C,B,Q){S(I>0);var E=ZI(I,g);B=fI(C,B);var i=[Q],o=[];pA([],[A],(function(A){var g="constructor "+(A=A[0]).name;if(void 0===A.registeredClass.constructor_body&&(A.registeredClass.constructor_body=[]),void 0!==A.registeredClass.constructor_body[I-1])throw new xA("Cannot register multiple constructors with identical number of parameters ("+(I-1)+") for class '"+A.name+"'! Overload resolution is currently only performed using the parameter count, not actual type info!");return A.registeredClass.constructor_body[I-1]=function(){pI("Cannot construct "+A.name+" due to unbound types",E)},pA([],E,(function(C){return A.registeredClass.constructor_body[I-1]=function(){arguments.length!==I-1&&VA(g+" called with "+arguments.length+" arguments, expected "+(I-1)),o.length=0,i.length=I;for(var A=1;A<I;++A)i[A]=C[A].toWireType(o,arguments[A-1]);var Q=B.apply(null,i);return kA(o),C[0].fromWireType(Q)},[]})),[]}))}function mI(A,I){if(!(A instanceof Function))throw new TypeError("new_ called with constructor type "+typeof A+" which is not a function");var g=HA(A.name||"unknownFunctionName",(function(){}));g.prototype=A.prototype;var C=new g,B=A.apply(C,I);return B instanceof Object?B:C}function XI(A,I,g,C,B){var Q=I.length;Q<2&&VA("argTypes array size mismatch! Must at least get return value and 'this' types!");for(var E=null!==I[1]&&null!==g,i=!1,o=1;o<I.length;++o)if(null!==I[o]&&void 0===I[o].destructorFunction){i=!0;break}var D="void"!==I[0].name,a="",t="";for(o=0;o<Q-2;++o)a+=(0!==o?", ":"")+"arg"+o,t+=(0!==o?", ":"")+"arg"+o+"Wired";var s="return function "+dA(A)+"("+a+") {\nif (arguments.length !== "+(Q-2)+") {\nthrowBindingError('function "+A+" called with ' + arguments.length + ' arguments, expected "+(Q-2)+" args!');\n}\n";i&&(s+="var destructors = [];\n");var F=i?"destructors":"null",n=["throwBindingError","invoker","fn","runDestructors","retType","classParam"],w=[VA,C,B,kA,I[0],I[1]];for(E&&(s+="var thisWired = classParam.toWireType("+F+", this);\n"),o=0;o<Q-2;++o)s+="var arg"+o+"Wired = argType"+o+".toWireType("+F+", arg"+o+"); // "+I[o+2].name+"\n",n.push("argType"+o),w.push(I[o+2]);if(E&&(t="thisWired"+(t.length>0?", ":"")+t),s+=(D?"var rv = ":"")+"invoker(fn"+(t.length>0?", ":"")+t+");\n",i)s+="runDestructors(destructors);\n";else for(o=E?1:2;o<I.length;++o){var r=1===o?"thisWired":"arg"+(o-2)+"Wired";null!==I[o].destructorFunction&&(s+=r+"_dtor("+r+"); // "+I[o].name+"\n",n.push(r+"_dtor"),w.push(I[o].destructorFunction))}return D&&(s+="var ret = retType.fromWireType(rv);\nreturn ret;\n"),s+="}\n",n.push(s),mI(Function,n).apply(null,w)}function xI(A,I,g,C,B,Q,E,i){var o=ZI(g,C);I=XA(I),Q=fI(B,Q),pA([],[A],(function(A){var C=(A=A[0]).name+"."+I;function B(){pI("Cannot call "+C+" due to unbound types",o)}i&&A.registeredClass.pureVirtualFunctions.push(I);var D=A.registeredClass.instancePrototype,a=D[I];return void 0===a||void 0===a.overloadTable&&a.className!==A.name&&a.argCount===g-2?(B.argCount=g-2,B.className=A.name,D[I]=B):(sI(D,I,C),D[I].overloadTable[g-2]=B),pA([],o,(function(B){var i=XI(C,B,A,Q,E);return void 0===D[I].overloadTable?(i.argCount=g-2,D[I]=i):D[I].overloadTable[g-2]=i,[]})),[]}))}var VI=[],vI=[{},{value:void 0},{value:null},{value:!0},{value:!1}];function TI(A){A>4&&0==--vI[A].refcount&&(vI[A]=void 0,VI.push(A))}function jI(){for(var A=0,I=5;I<vI.length;++I)void 0!==vI[I]&&++A;return A}function PI(){for(var A=5;A<vI.length;++A)if(void 0!==vI[A])return vI[A];return null}function OI(){B.count_emval_handles=jI,B.get_first_emval=PI}function zI(A){switch(A){case void 0:return 1;case null:return 2;case!0:return 3;case!1:return 4;default:var I=VI.length?VI.pop():vI.length;return vI[I]={refcount:1,value:A},I}}function _I(A,I){vA(A,{name:I=XA(I),fromWireType:function(A){var I=vI[A].value;return TI(A),I},toWireType:function(A,I){return zI(I)},argPackAdvance:8,readValueFromPointer:JA,destructorFunction:null})}function $I(A){if(null===A)return"null";var I=typeof A;return"object"===I||"array"===I||"function"===I?A.toString():""+A}function Ag(A,I){switch(I){case 2:return function(A){return this.fromWireType(W[A>>2])};case 3:return function(A){return this.fromWireType(m[A>>3])};default:throw new TypeError("Unknown float type: "+A)}}function Ig(A,I,g){var C=ZA(g);vA(A,{name:I=XA(I),fromWireType:function(A){return A},toWireType:function(A,I){if("number"!=typeof I&&"boolean"!=typeof I)throw new TypeError('Cannot convert "'+$I(I)+'" to '+this.name);return I},argPackAdvance:8,readValueFromPointer:Ag(I,C),destructorFunction:null})}function gg(A,I,g,C,B,Q){var E=ZI(I,g);A=XA(A),B=fI(C,B),FI(A,(function(){pI("Cannot call "+A+" due to unbound types",E)}),I-1),pA([],E,(function(g){var C=[g[0],null].concat(g.slice(1));return HI(A,XI(A,C,null,B,Q),I-1),[]}))}function Cg(A,I,g){switch(I){case 0:return g?function(A){return f[A]}:function(A){return u[A]};case 1:return g?function(A){return q[A>>1]}:function(A){return p[A>>1]};case 2:return g?function(A){return b[A>>2]}:function(A){return Z[A>>2]};default:throw new TypeError("Unknown integer type: "+A)}}function Bg(A,I,g,C,B){I=XA(I),-1===B&&(B=4294967295);var Q=ZA(g),E=function(A){return A};if(0===C){var i=32-8*g;E=function(A){return A<<i>>>i}}var o=-1!=I.indexOf("unsigned");vA(A,{name:I,fromWireType:E,toWireType:function(A,g){if("number"!=typeof g&&"boolean"!=typeof g)throw new TypeError('Cannot convert "'+$I(g)+'" to '+this.name);if(g<C||g>B)throw new TypeError('Passing a number "'+$I(g)+'" from JS side to C/C++ side to an argument of type "'+I+'", which is outside the valid range ['+C+", "+B+"]!");return o?g>>>0:0|g},argPackAdvance:8,readValueFromPointer:Cg(I,Q,0!==C),destructorFunction:null})}function Qg(A,I,g){var C=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array][I];function B(A){var I=Z,g=I[A>>=2],B=I[A+1];return new C(I.buffer,B,g)}vA(A,{name:g=XA(g),fromWireType:B,argPackAdvance:8,readValueFromPointer:B},{ignoreDuplicateRegistrations:!0})}function Eg(A,I){var g="std::string"===(I=XA(I));vA(A,{name:I,fromWireType:function(A){var I,C=Z[A>>2];if(g){var B=u[A+4+C],Q=0;0!=B&&(Q=B,u[A+4+C]=0);for(var E=A+4,i=0;i<=C;++i){var o=A+4+i;if(0==u[o]){var D=Y(E);void 0===I?I=D:(I+=String.fromCharCode(0),I+=D),E=o+1}}0!=Q&&(u[A+4+C]=Q)}else{var a=new Array(C);for(i=0;i<C;++i)a[i]=String.fromCharCode(u[A+4+i]);I=a.join("")}return bg(A),I},toWireType:function(A,I){I instanceof ArrayBuffer&&(I=new Uint8Array(I));var C="string"==typeof I;C||I instanceof Uint8Array||I instanceof Uint8ClampedArray||I instanceof Int8Array||VA("Cannot pass non-string to std::string");var B=(g&&C?function(){return l(I)}:function(){return I.length})(),Q=qg(4+B+1);if(Z[Q>>2]=B,g&&C)L(I,Q+4,B+1);else if(C)for(var E=0;E<B;++E){var i=I.charCodeAt(E);i>255&&(bg(Q),VA("String has UTF-16 code units that do not fit in 8 bits")),u[Q+4+E]=i}else for(E=0;E<B;++E)u[Q+4+E]=I[E];return null!==A&&A.push(bg,Q),Q},argPackAdvance:8,readValueFromPointer:JA,destructorFunction:function(A){bg(A)}})}function ig(A,I,g){var C,B;g=XA(g),2===I?(C=function(){return p},B=1):4===I&&(C=function(){return Z},B=2),vA(A,{name:g,fromWireType:function(A){for(var I=C(),g=Z[A>>2],Q=new Array(g),E=A+4>>B,i=0;i<g;++i)Q[i]=String.fromCharCode(I[E+i]);return bg(A),Q.join("")},toWireType:function(A,g){var Q=g.length,E=qg(4+Q*I),i=C();Z[E>>2]=Q;for(var o=E+4>>B,D=0;D<Q;++D)i[o+D]=g.charCodeAt(D);return null!==A&&A.push(bg,E),E},argPackAdvance:8,readValueFromPointer:JA,destructorFunction:function(A){bg(A)}})}function og(A,I,g,C,B,Q){UA[A]={name:XA(I),rawConstructor:fI(g,C),rawDestructor:fI(B,Q),fields:[]}}function Dg(A,I,g,C,B,Q,E,i,o,D){UA[A].fields.push({fieldName:XA(I),getterReturnType:g,getter:fI(C,B),getterContext:Q,setterArgumentType:E,setter:fI(i,o),setterContext:D})}function ag(A,I){vA(A,{isVoid:!0,name:I=XA(I),argPackAdvance:0,fromWireType:function(){},toWireType:function(A,I){}})}var tg={};function sg(A){var I=tg[A];return void 0===I?XA(A):I}function Fg(){return"object"==typeof globalThis?globalThis:Function("return this")()}function ng(A){return 0===A?zI(Fg()):(A=sg(A),zI(Fg()[A]))}function wg(A){A>4&&(vI[A].refcount+=1)}function rg(A,I){var g=YA[A];return void 0===g&&VA(I+" has unknown type "+qI(A)),g}function eg(A){for(var I="",g=0;g<A;++g)I+=(0!==g?", ":"")+"arg"+g;var C="return function emval_allocator_"+A+"(constructor, argTypes, args) {\n";for(g=0;g<A;++g)C+="var argType"+g+" = requireRegisteredType(Module['HEAP32'][(argTypes >> 2) + "+g+'], "parameter '+g+'");\nvar arg'+g+" = argType"+g+".readValueFromPointer(args);\nargs += argType"+g+"['argPackAdvance'];\n";return C+="var obj = new constructor("+I+");\nreturn __emval_register(obj);\n}\n",new Function("requireRegisteredType","Module","__emval_register",C)(rg,B,zI)}var hg={};function Gg(A){return A||VA("Cannot use deleted val. handle = "+A),vI[A].value}function yg(A,I,g,C){A=Gg(A);var B=hg[I];return B||(B=eg(I),hg[I]=B),B(A,g,C)}function cg(A,I){return zI((A=rg(A,"_emval_take_value")).readValueFromPointer(I))}function Ng(){sA()}function Rg(){return f.length}function Sg(){return 46048}function Ug(A,I,g){u.set(u.subarray(I,I+g),A)}function kg(A){try{return y.grow(A-H.byteLength+65535>>16),V(y.buffer),1}catch(A){}}function Jg(A){var I=Rg(),g=65536,C=2147418112;if(A>C)return!1;for(var B=Math.max(I,16777216);B<A;)B=B<=536870912?x(2*B,g):Math.min(x((3*B+2147483648)/4,g),C);return!!kg(B)}var Kg={buffers:[null,[],[]],printChar:function(A,I){var g=Kg.buffers[A];0===I||10===I?((1===A?e:h)(K(g,0)),g.length=0):g.push(I)},varargs:0,get:function(A){return Kg.varargs+=4,b[Kg.varargs-4>>2]},getStr:function(){return Y(Kg.get())},get64:function(){var A=Kg.get();return Kg.get(),A},getZero:function(){Kg.get()}};function Yg(A){try{return 0}catch(A){return"undefined"!=typeof FS&&A instanceof FS.ErrnoError||sA(A),A.errno}}function Mg(A,I,g,C,B){try{return 0}catch(A){return"undefined"!=typeof FS&&A instanceof FS.ErrnoError||sA(A),A.errno}}function Lg(A,I,g,C){try{for(var B=0,Q=0;Q<g;Q++){for(var E=b[I+8*Q>>2],i=b[I+(8*Q+4)>>2],o=0;o<i;o++)Kg.printChar(A,u[E+o]);B+=i}return b[C>>2]=B,0}catch(A){return"undefined"!=typeof FS&&A instanceof FS.ErrnoError||sA(A),A.errno}}function lg(A){c(0|A)}uA=B.InternalError=fA(Error,"InternalError"),WA(),xA=B.BindingError=fA(Error,"BindingError"),DI(),lI(),kI(),uI=B.UnboundTypeError=fA(Error,"UnboundTypeError"),OI();var dg={__cxa_allocate_exception:GA,__cxa_atexit:cA,__cxa_thread_atexit:NA,__cxa_throw:SA,_embind_finalize_value_object:bA,_embind_register_bool:TA,_embind_register_class:bI,_embind_register_class_constructor:WI,_embind_register_class_function:xI,_embind_register_emval:_I,_embind_register_float:Ig,_embind_register_function:gg,_embind_register_integer:Bg,_embind_register_memory_view:Qg,_embind_register_std_string:Eg,_embind_register_std_wstring:ig,_embind_register_value_object:og,_embind_register_value_object_field:Dg,_embind_register_void:ag,_emval_decref:TI,_emval_get_global:ng,_emval_incref:wg,_emval_new:yg,_emval_take_value:cg,abort:Ng,emscripten_get_sbrk_ptr:Sg,emscripten_memcpy_big:Ug,emscripten_resize_heap:Jg,fd_close:Yg,fd_seek:Mg,fd_write:Lg,memory:y,setTempRet0:lg,table:N},Hg=hA();B.asm=Hg;var fg,ug=B.___wasm_call_ctors=function(){return B.asm.__wasm_call_ctors.apply(null,arguments)},qg=B._malloc=function(){return B.asm.malloc.apply(null,arguments)},pg=(B._setThrew=function(){return B.asm.setThrew.apply(null,arguments)},B.__ZSt18uncaught_exceptionv=function(){return B.asm._ZSt18uncaught_exceptionv.apply(null,arguments)}),bg=B._free=function(){return B.asm.free.apply(null,arguments)},Zg=B.___getTypeName=function(){return B.asm.__getTypeName.apply(null,arguments)},Wg=(B.___embind_register_native_and_builtin_types=function(){return B.asm.__embind_register_native_and_builtin_types.apply(null,arguments)},B.stackSave=function(){return B.asm.stackSave.apply(null,arguments)}),mg=B.stackAlloc=function(){return B.asm.stackAlloc.apply(null,arguments)},Xg=B.stackRestore=function(){return B.asm.stackRestore.apply(null,arguments)};function xg(A){this.name="ExitStatus",this.message="Program terminated with exit("+A+")",this.status=A}function Vg(A){function I(){fg||(fg=!0,R||(gA(),CA(),B.onRuntimeInitialized&&B.onRuntimeInitialized(),BA()))}A=A||E,iA>0||(IA(),iA>0||(B.setStatus?(B.setStatus("Running..."),setTimeout((function(){setTimeout((function(){B.setStatus("")}),1),I()}),1)):I()))}if(B.__growWasmMemory=function(){return B.asm.__growWasmMemory.apply(null,arguments)},B.dynCall_i=function(){return B.asm.dynCall_i.apply(null,arguments)},B.dynCall_vi=function(){return B.asm.dynCall_vi.apply(null,arguments)},B.dynCall_iii=function(){return B.asm.dynCall_iii.apply(null,arguments)},B.dynCall_viii=function(){return B.asm.dynCall_viii.apply(null,arguments)},B.dynCall_ii=function(){return B.asm.dynCall_ii.apply(null,arguments)},B.dynCall_iiii=function(){return B.asm.dynCall_iiii.apply(null,arguments)},B.dynCall_vii=function(){return B.asm.dynCall_vii.apply(null,arguments)},B.dynCall_viiii=function(){return B.asm.dynCall_viiii.apply(null,arguments)},B.dynCall_v=function(){return B.asm.dynCall_v.apply(null,arguments)},B.dynCall_iidiiii=function(){return B.asm.dynCall_iidiiii.apply(null,arguments)},B.dynCall_jiji=function(){return B.asm.dynCall_jiji.apply(null,arguments)},B.dynCall_viiiiii=function(){return B.asm.dynCall_viiiiii.apply(null,arguments)},B.dynCall_viiiii=function(){return B.asm.dynCall_viiiii.apply(null,arguments)},B.asm=Hg,B.ccall=k,B.then=function(A){if(fg)A(B);else{var I=B.onRuntimeInitialized;B.onRuntimeInitialized=function(){I&&I(),A(B)}}return B},DA=function A(){fg||Vg(),fg||(DA=A)},B.run=Vg,B.preInit)for("function"==typeof B.preInit&&(B.preInit=[B.preInit]);B.preInit.length>0;)B.preInit.pop()();return Vg(),A});A.exports=B},9400:(A,I,g)=>{var C,B=(C=(C="undefined"!=typeof document&&document.currentScript?document.currentScript.src:void 0)||"/index.js",function(A){var I,B=void 0!==(A=A||{})?A:{},Q={};for(I in B)B.hasOwnProperty(I)&&(Q[I]=B[I]);var E=[],i="./this.program",o=function(A,I){throw I},D=!1,a=!1,t=!1,s=!1;D="object"==typeof window,a="function"==typeof importScripts,t="object"==typeof process&&"object"==typeof process.versions&&"string"==typeof process.versions.node&&!D&&!a,s=!D&&!t&&!a;var F,n,w,r,e="";function h(A){return B.locateFile?B.locateFile(A,e):e+A}t?(e="//",F=function(A,I){return w||(w=g(1973)),r||(r=g(378)),A=r.normalize(A),w.readFileSync(A,I?null:"utf8")},n=function(A){var I=F(A,!0);return I.buffer||(I=new Uint8Array(I)),Y(I.buffer),I},process.argv.length>1&&(i=process.argv[1].replace(/\\/g,"/")),E=process.argv.slice(2),process.on("uncaughtException",(function(A){if(!(A instanceof hC))throw A})),process.on("unhandledRejection",GA),o=function(A){process.exit(A)},B.inspect=function(){return"[Emscripten Module object]"}):s?("undefined"!=typeof read&&(F=function(A){return read(A)}),n=function(A){var I;return"function"==typeof readbuffer?new Uint8Array(readbuffer(A)):(Y("object"==typeof(I=read(A,"binary"))),I)},"undefined"!=typeof scriptArgs?E=scriptArgs:void 0!==arguments&&(E=arguments),"function"==typeof quit&&(o=function(A){quit(A)}),"undefined"!=typeof print&&("undefined"==typeof console&&(console={}),console.log=print,console.warn=console.error="undefined"!=typeof printErr?printErr:print)):(D||a)&&(a?e=self.location.href:document.currentScript&&(e=document.currentScript.src),C&&(e=C),e=0!==e.indexOf("blob:")?e.substr(0,e.lastIndexOf("/")+1):"",F=function(A){var I=new XMLHttpRequest;return I.open("GET",A,!1),I.send(null),I.responseText},a&&(n=function(A){var I=new XMLHttpRequest;return I.open("GET",A,!1),I.responseType="arraybuffer",I.send(null),new Uint8Array(I.response)}));var G=B.print||console.log.bind(console),y=B.printErr||console.warn.bind(console);for(I in Q)Q.hasOwnProperty(I)&&(B[I]=Q[I]);Q=null,B.arguments&&(E=B.arguments),B.thisProgram&&(i=B.thisProgram),B.quit&&(o=B.quit);var c,N,R,S=0,U=function(A){S=A},k=function(){return S};B.wasmBinary&&(c=B.wasmBinary),B.noExitRuntime&&(N=B.noExitRuntime),"object"!=typeof WebAssembly&&y("no native wasm support detected");var J=new WebAssembly.Table({initial:204,maximum:204,element:"anyfunc"}),K=!1;function Y(A,I){A||GA("Assertion failed: "+I)}function M(A){var I=B["_"+A];return Y(I,"Cannot call unknown function "+A+", make sure it is exported"),I}function L(A,I,g,C,B){var Q={string:function(A){var I=0;if(null!=A&&0!==A){var g=1+(A.length<<2);u(A,I=tC(g),g)}return I},array:function(A){var I=tC(A.length);return p(A,I),I}},E=M(A),i=[],o=0;if(C)for(var D=0;D<C.length;D++){var a=Q[g[D]];a?(0===o&&(o=aC()),i[D]=a(C[D])):i[D]=C[D]}var t=E.apply(null,i);return t=function(A){return"string"===I?H(A):"boolean"===I?Boolean(A):A}(t),0!==o&&sC(o),t}var l="undefined"!=typeof TextDecoder?new TextDecoder("utf8"):void 0;function d(A,I,g){for(var C=I+g,B=I;A[B]&&!(B>=C);)++B;if(B-I>16&&A.subarray&&l)return l.decode(A.subarray(I,B));for(var Q="";I<B;){var E=A[I++];if(128&E){var i=63&A[I++];if(192!=(224&E)){var o=63&A[I++];if((E=224==(240&E)?(15&E)<<12|i<<6|o:(7&E)<<18|i<<12|o<<6|63&A[I++])<65536)Q+=String.fromCharCode(E);else{var D=E-65536;Q+=String.fromCharCode(55296|D>>10,56320|1023&D)}}else Q+=String.fromCharCode((31&E)<<6|i)}else Q+=String.fromCharCode(E)}return Q}function H(A,I){return A?d(m,A,I):""}function f(A,I,g,C){if(!(C>0))return 0;for(var B=g,Q=g+C-1,E=0;E<A.length;++E){var i=A.charCodeAt(E);if(i>=55296&&i<=57343&&(i=65536+((1023&i)<<10)|1023&A.charCodeAt(++E)),i<=127){if(g>=Q)break;I[g++]=i}else if(i<=2047){if(g+1>=Q)break;I[g++]=192|i>>6,I[g++]=128|63&i}else if(i<=65535){if(g+2>=Q)break;I[g++]=224|i>>12,I[g++]=128|i>>6&63,I[g++]=128|63&i}else{if(g+3>=Q)break;I[g++]=240|i>>18,I[g++]=128|i>>12&63,I[g++]=128|i>>6&63,I[g++]=128|63&i}}return I[g]=0,g-B}function u(A,I,g){return f(A,m,I,g)}function q(A){for(var I=0,g=0;g<A.length;++g){var C=A.charCodeAt(g);C>=55296&&C<=57343&&(C=65536+((1023&C)<<10)|1023&A.charCodeAt(++g)),C<=127?++I:I+=C<=2047?2:C<=65535?3:4}return I}function p(A,I){W.set(A,I)}function b(A,I,g){for(var C=0;C<A.length;++C)W[I++>>0]=A.charCodeAt(C);g||(W[I>>0]=0)}"undefined"!=typeof TextDecoder&&new TextDecoder("utf-16le");var Z,W,m,X,x,V,v,T,j,P=65536;function O(A,I){return A%I>0&&(A+=I-A%I),A}function z(A){Z=A,B.HEAP8=W=new Int8Array(A),B.HEAP16=X=new Int16Array(A),B.HEAP32=V=new Int32Array(A),B.HEAPU8=m=new Uint8Array(A),B.HEAPU16=x=new Uint16Array(A),B.HEAPU32=v=new Uint32Array(A),B.HEAPF32=T=new Float32Array(A),B.HEAPF64=j=new Float64Array(A)}var _=5258768,$=15728,AA=B.TOTAL_MEMORY||1073741824;function IA(A){for(;A.length>0;){var I=A.shift();if("function"!=typeof I){var g=I.func;"number"==typeof g?void 0===I.arg?B.dynCall_v(g):B.dynCall_vi(g,I.arg):g(void 0===I.arg?null:I.arg)}else I()}}(R=B.wasmMemory?B.wasmMemory:new WebAssembly.Memory({initial:AA/P}))&&(Z=R.buffer),AA=Z.byteLength,z(Z),V[$>>2]=_;var gA=[],CA=[],BA=[],QA=[],EA=[];function iA(){if(B.preRun)for("function"==typeof B.preRun&&(B.preRun=[B.preRun]);B.preRun.length;)sA(B.preRun.shift());IA(gA)}function oA(){IA(CA)}function DA(){IA(BA)}function aA(){}function tA(){if(B.postRun)for("function"==typeof B.postRun&&(B.postRun=[B.postRun]);B.postRun.length;)FA(B.postRun.shift());IA(EA)}function sA(A){gA.unshift(A)}function FA(A){EA.unshift(A)}Math.abs,Math.ceil,Math.floor,Math.min;var nA=0,wA=null,rA=null;function eA(A){nA++,B.monitorRunDependencies&&B.monitorRunDependencies(nA)}function hA(A){if(nA--,B.monitorRunDependencies&&B.monitorRunDependencies(nA),0==nA&&(null!==wA&&(clearInterval(wA),wA=null),rA)){var I=rA;rA=null,I()}}function GA(A){throw B.onAbort&&B.onAbort(A),G(A+=""),y(A),K=!0,A="abort("+A+"). Build with -s ASSERTIONS=1 for more info.",new WebAssembly.RuntimeError(A)}B.preloadedImages={},B.preloadedAudios={};var yA="data:application/octet-stream;base64,";function cA(A){return String.prototype.startsWith?A.startsWith(yA):0===A.indexOf(yA)}var NA="libjpegturbowasm_decode.wasm";function RA(){try{if(c)return new Uint8Array(c);if(n)return n(NA);throw"both async and sync fetching of the wasm failed"}catch(A){GA(A)}}function SA(){return c||!D&&!a||"function"!=typeof fetch?new Promise((function(A,I){A(RA())})):fetch(NA,{credentials:"same-origin"}).then((function(A){if(!A.ok)throw"failed to load wasm binary file at '"+NA+"'";return A.arrayBuffer()})).catch((function(){return RA()}))}function UA(){var A={env:Pg,wasi_snapshot_preview1:Pg};function I(A,I){var g=A.exports;B.asm=g,hA()}function g(A){I(A.instance)}function C(I){return SA().then((function(I){return WebAssembly.instantiate(I,A)})).then(I,(function(A){y("failed to asynchronously prepare wasm: "+A),GA(A)}))}if(eA(),B.instantiateWasm)try{return B.instantiateWasm(A,I)}catch(A){return y("Module.instantiateWasm callback failed with error: "+A),!1}return function(){if(c||"function"!=typeof WebAssembly.instantiateStreaming||cA(NA)||"function"!=typeof fetch)return C(g);fetch(NA,{credentials:"same-origin"}).then((function(I){return WebAssembly.instantiateStreaming(I,A).then(g,(function(A){y("wasm streaming compile failed: "+A),y("falling back to ArrayBuffer instantiation"),C(g)}))}))}(),{}}function kA(A){return $g(A)}function JA(A,I){QA.unshift({func:A,arg:I})}function KA(){return JA.apply(null,arguments)}cA(NA)||(NA=h(NA)),CA.push({func:function(){_g()}});var YA={};function MA(A,I,g){throw YA[A]={ptr:A,adjusted:[A],type:I,destructor:g,refcount:0,caught:!1,rethrown:!1},"uncaught_exception"in CC?CC.uncaught_exceptions++:CC.uncaught_exceptions=1,A}var LA={};function lA(A){for(;A.length;){var I=A.pop();A.pop()(I)}}function dA(A){return this.fromWireType(v[A>>2])}var HA={},fA={},uA={},qA=48,pA=57;function bA(A){if(void 0===A)return"_unknown";var I=(A=A.replace(/[^a-zA-Z0-9_]/g,"$")).charCodeAt(0);return I>=qA&&I<=pA?"_"+A:A}function ZA(A,I){return A=bA(A),new Function("body","return function "+A+'() {\n "use strict"; return body.apply(this, arguments);\n};\n')(I)}function WA(A,I){var g=ZA(I,(function(A){this.name=I,this.message=A;var g=new Error(A).stack;void 0!==g&&(this.stack=this.toString()+"\n"+g.replace(/^Error(:[^\n]*)?\n/,""))}));return g.prototype=Object.create(A.prototype),g.prototype.constructor=g,g.prototype.toString=function(){return void 0===this.message?this.name:this.name+": "+this.message},g}var mA=void 0;function XA(A){throw new mA(A)}function xA(A,I,g){function C(I){var C=g(I);C.length!==A.length&&XA("Mismatched type converter count");for(var B=0;B<A.length;++B)_A(A[B],C[B])}A.forEach((function(A){uA[A]=I}));var B=new Array(I.length),Q=[],E=0;I.forEach((function(A,I){fA.hasOwnProperty(A)?B[I]=fA[A]:(Q.push(A),HA.hasOwnProperty(A)||(HA[A]=[]),HA[A].push((function(){B[I]=fA[A],++E===Q.length&&C(B)})))})),0===Q.length&&C(B)}function VA(A){var I=LA[A];delete LA[A];var g=I.rawConstructor,C=I.rawDestructor,B=I.fields;xA([A],B.map((function(A){return A.getterReturnType})).concat(B.map((function(A){return A.setterArgumentType}))),(function(A){var Q={};return B.forEach((function(I,g){var C=I.fieldName,E=A[g],i=I.getter,o=I.getterContext,D=A[g+B.length],a=I.setter,t=I.setterContext;Q[C]={read:function(A){return E.fromWireType(i(o,A))},write:function(A,I){var g=[];a(t,A,D.toWireType(g,I)),l