@cornerstonejs/dicom-image-loader 0.5.0 → 0.5.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cornerstoneDICOMImageLoader.bundle.min.js +1 -1
- package/dist/cornerstoneDICOMImageLoader.bundle.min.js.map +1 -1
- package/dist/cornerstoneDICOMImageLoaderNoWebWorkers.bundle.min.js +1 -1
- package/dist/cornerstoneDICOMImageLoaderNoWebWorkers.bundle.min.js.map +1 -1
- package/dist/dynamic-import/610.min.worker.js +1 -1
- package/dist/dynamic-import/610.min.worker.js.map +1 -1
- package/dist/dynamic-import/945.min.worker.js +1 -1
- package/dist/dynamic-import/945.min.worker.js.map +1 -1
- package/dist/dynamic-import/cornerstoneDICOMImageLoader.min.js +1 -1
- package/dist/dynamic-import/cornerstoneDICOMImageLoader.min.js.map +1 -1
- package/dist/dynamic-import/index.worker.ea71efba2ce63c499055.worker.js +2 -0
- package/dist/dynamic-import/index.worker.ea71efba2ce63c499055.worker.js.map +1 -0
- package/dist/index.worker.bundle.min.worker.js +1 -1
- package/dist/index.worker.bundle.min.worker.js.map +1 -1
- package/package.json +3 -27
- package/dist/dynamic-import/index.worker.b7a83074fe09e221e999.worker.js +0 -2
- package/dist/dynamic-import/index.worker.b7a83074fe09e221e999.worker.js.map +0 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cornerstonejs/dicom-image-loader",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.2",
|
|
4
4
|
"description": "Cornerstone Image Loader for DICOM WADO-URI and WADO-RS and Local file",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"DICOM",
|
|
@@ -62,36 +62,12 @@
|
|
|
62
62
|
"webpack:watch": "webpack --progress --watch --config .webpack",
|
|
63
63
|
"prepublishOnly": "yarn run build"
|
|
64
64
|
},
|
|
65
|
-
"devDependencies": {
|
|
66
|
-
"@babel/plugin-proposal-object-rest-spread": "^7.14.7",
|
|
67
|
-
"@babel/runtime-corejs3": "^7.15.4",
|
|
68
|
-
"@types/emscripten": "^1.39.6",
|
|
69
|
-
"@types/jasmine": "^4.3.1",
|
|
70
|
-
"@types/karma": "^6.3.3",
|
|
71
|
-
"chai": "^4.3.4",
|
|
72
|
-
"concat": "^1.0.3",
|
|
73
|
-
"core-js": "^3.26.1",
|
|
74
|
-
"coveralls": "^3.1.1",
|
|
75
|
-
"docdash": "^1.2.0",
|
|
76
|
-
"exports-loader": "^3.0.0",
|
|
77
|
-
"fs-extra": "^10.0.0",
|
|
78
|
-
"jsdoc": "^3.6.7",
|
|
79
|
-
"karma-mocha": "^2.0.1",
|
|
80
|
-
"lodash": "^4.17.21",
|
|
81
|
-
"mocha": "^9.1.1",
|
|
82
|
-
"open-cli": "^7.0.1",
|
|
83
|
-
"puppeteer": "^10.2.0",
|
|
84
|
-
"shx": "^0.3.3"
|
|
85
|
-
},
|
|
86
65
|
"dependencies": {
|
|
87
|
-
"@babel/eslint-parser": "^7.19.1",
|
|
88
66
|
"@cornerstonejs/codec-charls": "^1.2.3",
|
|
89
67
|
"@cornerstonejs/codec-libjpeg-turbo-8bit": "^1.2.2",
|
|
90
68
|
"@cornerstonejs/codec-openjpeg": "^1.2.2",
|
|
91
69
|
"@cornerstonejs/codec-openjph": "^2.4.2",
|
|
92
|
-
"@cornerstonejs/core": "^0.44.
|
|
93
|
-
"coverage-istanbul-loader": "^3.0.5",
|
|
94
|
-
"date-format": "^4.0.14",
|
|
70
|
+
"@cornerstonejs/core": "^0.44.2",
|
|
95
71
|
"dicom-parser": "^1.8.9",
|
|
96
72
|
"pako": "^2.0.4",
|
|
97
73
|
"uuid": "^9.0.0"
|
|
@@ -113,5 +89,5 @@
|
|
|
113
89
|
"path": "./node_modules/cz-conventional-changelog"
|
|
114
90
|
}
|
|
115
91
|
},
|
|
116
|
-
"gitHead": "
|
|
92
|
+
"gitHead": "45b5360196e59bfc62c1a73122dfa31a4b61b9ff"
|
|
117
93
|
}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
(()=>{var t,e,r={945:(t,e,r)=>{t.exports=r(602)},37:(t,e,r)=>{var n,o=(n=(n="undefined"!=typeof document&&document.currentScript?document.currentScript.src:void 0)||"/index.js",function(t){var e,o,i=void 0!==(t=t||{})?t:{};i.ready=new Promise((function(t,r){e=t,o=r}));var a,s,u,c=Object.assign({},i),f=[],l="object"==typeof window,p="function"==typeof importScripts,h="object"==typeof process&&"object"==typeof process.versions&&"string"==typeof process.versions.node,d="";if(h){var v=r(716),y=r(401);d=p?y.dirname(d)+"/":"//",a=(t,e)=>(t=N(t)?new URL(t):y.normalize(t),v.readFileSync(t,e?void 0:"utf8")),u=t=>{var e=a(t,!0);return e.buffer||(e=new Uint8Array(e)),e},s=(t,e,r)=>{t=N(t)?new URL(t):y.normalize(t),v.readFile(t,(function(t,n){t?r(t):e(n.buffer)}))},process.argv.length>1&&process.argv[1].replace(/\\/g,"/"),f=process.argv.slice(2),process.on("uncaughtException",(function(t){if(!(t instanceof q))throw t})),process.on("unhandledRejection",(function(t){throw t})),i.inspect=function(){return"[Emscripten Module object]"}}else(l||p)&&(p?d=self.location.href:"undefined"!=typeof document&&document.currentScript&&(d=document.currentScript.src),n&&(d=n),d=0!==d.indexOf("blob:")?d.substr(0,d.replace(/[?#].*/,"").lastIndexOf("/")+1):"",a=t=>{var e=new XMLHttpRequest;return e.open("GET",t,!1),e.send(null),e.responseText},p&&(u=t=>{var e=new XMLHttpRequest;return e.open("GET",t,!1),e.responseType="arraybuffer",e.send(null),new Uint8Array(e.response)}),s=(t,e,r)=>{var n=new XMLHttpRequest;n.open("GET",t,!0),n.responseType="arraybuffer",n.onload=()=>{200==n.status||0==n.status&&n.response?e(n.response):r()},n.onerror=r,n.send(null)});i.print||console.log.bind(console);var g,m=i.printErr||console.warn.bind(console);Object.assign(i,c),c=null,i.arguments&&(f=i.arguments),i.thisProgram&&i.thisProgram,i.quit&&i.quit,i.wasmBinary&&(g=i.wasmBinary);var w;i.noExitRuntime;"object"!=typeof WebAssembly&&V("no native wasm support detected");var b,P,T,C,_,$,A,x,O,k=!1,S="undefined"!=typeof TextDecoder?new TextDecoder("utf8"):void 0;function j(t,e){return t?function(t,e,r){for(var n=e+r,o=e;t[o]&&!(o>=n);)++o;if(o-e>16&&t.buffer&&S)return S.decode(t.subarray(e,o));for(var i="";e<o;){var a=t[e++];if(128&a){var s=63&t[e++];if(192!=(224&a)){var u=63&t[e++];if((a=224==(240&a)?(15&a)<<12|s<<6|u:(7&a)<<18|s<<12|u<<6|63&t[e++])<65536)i+=String.fromCharCode(a);else{var c=a-65536;i+=String.fromCharCode(55296|c>>10,56320|1023&c)}}else i+=String.fromCharCode((31&a)<<6|s)}else i+=String.fromCharCode(a)}return i}(T,t,e):""}function E(t,e,r){return function(t,e,r,n){if(!(n>0))return 0;for(var o=r,i=r+n-1,a=0;a<t.length;++a){var s=t.charCodeAt(a);if(s>=55296&&s<=57343&&(s=65536+((1023&s)<<10)|1023&t.charCodeAt(++a)),s<=127){if(r>=i)break;e[r++]=s}else if(s<=2047){if(r+1>=i)break;e[r++]=192|s>>6,e[r++]=128|63&s}else if(s<=65535){if(r+2>=i)break;e[r++]=224|s>>12,e[r++]=128|s>>6&63,e[r++]=128|63&s}else{if(r+3>=i)break;e[r++]=240|s>>18,e[r++]=128|s>>12&63,e[r++]=128|s>>6&63,e[r++]=128|63&s}}return e[r]=0,r-o}(t,T,e,r)}function R(t){b=t,i.HEAP8=P=new Int8Array(t),i.HEAP16=C=new Int16Array(t),i.HEAP32=$=new Int32Array(t),i.HEAPU8=T=new Uint8Array(t),i.HEAPU16=_=new Uint16Array(t),i.HEAPU32=A=new Uint32Array(t),i.HEAPF32=x=new Float32Array(t),i.HEAPF64=O=new Float64Array(t)}i.INITIAL_MEMORY;var D,F,W,I=[],U=[],L=[],H=0,B=null,M=null;function V(t){i.onAbort&&i.onAbort(t),m(t="Aborted("+t+")"),k=!0,t+=". Build with -sASSERTIONS for more info.";var e=new WebAssembly.RuntimeError(t);throw o(e),e}function z(t){return t.startsWith("data:application/octet-stream;base64,")}function N(t){return t.startsWith("file://")}function G(t){try{if(t==F&&g)return new Uint8Array(g);if(u)return u(t);throw"both async and sync fetching of the wasm failed"}catch(t){V(t)}}function q(t){this.name="ExitStatus",this.message="Program terminated with exit("+t+")",this.status=t}function J(t){for(;t.length>0;)t.shift()(i)}function X(t){this.excPtr=t,this.ptr=t-24,this.set_type=function(t){A[this.ptr+4>>2]=t},this.get_type=function(){return A[this.ptr+4>>2]},this.set_destructor=function(t){A[this.ptr+8>>2]=t},this.get_destructor=function(){return A[this.ptr+8>>2]},this.set_refcount=function(t){$[this.ptr>>2]=t},this.set_caught=function(t){t=t?1:0,P[this.ptr+12>>0]=t},this.get_caught=function(){return 0!=P[this.ptr+12>>0]},this.set_rethrown=function(t){t=t?1:0,P[this.ptr+13>>0]=t},this.get_rethrown=function(){return 0!=P[this.ptr+13>>0]},this.init=function(t,e){this.set_adjusted_ptr(0),this.set_type(t),this.set_destructor(e),this.set_refcount(0),this.set_caught(!1),this.set_rethrown(!1)},this.add_ref=function(){var t=$[this.ptr>>2];$[this.ptr>>2]=t+1},this.release_ref=function(){var t=$[this.ptr>>2];return $[this.ptr>>2]=t-1,1===t},this.set_adjusted_ptr=function(t){A[this.ptr+16>>2]=t},this.get_adjusted_ptr=function(){return A[this.ptr+16>>2]},this.get_exception_ptr=function(){if(Re(this.get_type()))return A[this.excPtr>>2];var t=this.get_adjusted_ptr();return 0!==t?t:this.excPtr}}z(F="charlswasm_decode.wasm")||(W=F,F=i.locateFile?i.locateFile(W,d):d+W);var Y={};function K(t){for(;t.length;){var e=t.pop();t.pop()(e)}}function Z(t){return this.fromWireType($[t>>2])}var Q={},tt={},et={};function rt(t){if(void 0===t)return"_unknown";var e=(t=t.replace(/[^a-zA-Z0-9_]/g,"$")).charCodeAt(0);return e>=48&&e<=57?"_"+t:t}function nt(t,e){return t=rt(t),new Function("body","return function "+t+'() {\n "use strict"; return body.apply(this, arguments);\n};\n')(e)}function ot(t,e){var r=nt(e,(function(t){this.name=e,this.message=t;var r=new Error(t).stack;void 0!==r&&(this.stack=this.toString()+"\n"+r.replace(/^Error(:[^\n]*)?\n/,""))}));return r.prototype=Object.create(t.prototype),r.prototype.constructor=r,r.prototype.toString=function(){return void 0===this.message?this.name:this.name+": "+this.message},r}var it=void 0;function at(t){throw new it(t)}function st(t,e,r){function n(e){var n=r(e);n.length!==t.length&&at("Mismatched type converter count");for(var o=0;o<t.length;++o)ht(t[o],n[o])}t.forEach((function(t){et[t]=e}));var o=new Array(e.length),i=[],a=0;e.forEach(((t,e)=>{tt.hasOwnProperty(t)?o[e]=tt[t]:(i.push(t),Q.hasOwnProperty(t)||(Q[t]=[]),Q[t].push((()=>{o[e]=tt[t],++a===i.length&&n(o)})))})),0===i.length&&n(o)}function ut(t){switch(t){case 1:return 0;case 2:return 1;case 4:return 2;case 8:return 3;default:throw new TypeError("Unknown type size: "+t)}}var ct=void 0;function ft(t){for(var e="",r=t;T[r];)e+=ct[T[r++]];return e}var lt=void 0;function pt(t){throw new lt(t)}function ht(t,e,r={}){if(!("argPackAdvance"in e))throw new TypeError("registerType registeredInstance requires argPackAdvance");var n=e.name;if(t||pt('type "'+n+'" must have a positive integer typeid pointer'),tt.hasOwnProperty(t)){if(r.ignoreDuplicateRegistrations)return;pt("Cannot register type '"+n+"' twice")}if(tt[t]=e,delete et[t],Q.hasOwnProperty(t)){var o=Q[t];delete Q[t],o.forEach((t=>t()))}}function dt(t){if(!(this instanceof Wt))return!1;if(!(t instanceof Wt))return!1;for(var e=this.$$.ptrType.registeredClass,r=this.$$.ptr,n=t.$$.ptrType.registeredClass,o=t.$$.ptr;e.baseClass;)r=e.upcast(r),e=e.baseClass;for(;n.baseClass;)o=n.upcast(o),n=n.baseClass;return e===n&&r===o}function vt(t){pt(t.$$.ptrType.registeredClass.name+" instance already deleted")}var yt=!1;function gt(t){}function mt(t){t.count.value-=1,0===t.count.value&&function(t){t.smartPtr?t.smartPtrType.rawDestructor(t.smartPtr):t.ptrType.registeredClass.rawDestructor(t.ptr)}(t)}function wt(t,e,r){if(e===r)return t;if(void 0===r.baseClass)return null;var n=wt(t,e,r.baseClass);return null===n?null:r.downcast(n)}var bt={};function Pt(){return Object.keys(xt).length}function Tt(){var t=[];for(var e in xt)xt.hasOwnProperty(e)&&t.push(xt[e]);return t}var Ct=[];function _t(){for(;Ct.length;){var t=Ct.pop();t.$$.deleteScheduled=!1,t.delete()}}var $t=void 0;function At(t){$t=t,Ct.length&&$t&&$t(_t)}var xt={};function Ot(t,e){return e=function(t,e){for(void 0===e&&pt("ptr should not be undefined");t.baseClass;)e=t.upcast(e),t=t.baseClass;return e}(t,e),xt[e]}function kt(t,e){return e.ptrType&&e.ptr||at("makeClassHandle requires ptr and ptrType"),!!e.smartPtrType!=!!e.smartPtr&&at("Both smartPtrType and smartPtr must be specified"),e.count={value:1},jt(Object.create(t,{$$:{value:e}}))}function St(t){var e=this.getPointee(t);if(!e)return this.destructor(t),null;var r=Ot(this.registeredClass,e);if(void 0!==r){if(0===r.$$.count.value)return r.$$.ptr=e,r.$$.smartPtr=t,r.clone();var n=r.clone();return this.destructor(t),n}function o(){return this.isSmartPointer?kt(this.registeredClass.instancePrototype,{ptrType:this.pointeeType,ptr:e,smartPtrType:this,smartPtr:t}):kt(this.registeredClass.instancePrototype,{ptrType:this,ptr:t})}var i,a=this.registeredClass.getActualType(e),s=bt[a];if(!s)return o.call(this);i=this.isConst?s.constPointerType:s.pointerType;var u=wt(e,this.registeredClass,i.registeredClass);return null===u?o.call(this):this.isSmartPointer?kt(i.registeredClass.instancePrototype,{ptrType:i,ptr:u,smartPtrType:this,smartPtr:t}):kt(i.registeredClass.instancePrototype,{ptrType:i,ptr:u})}function jt(t){return"undefined"==typeof FinalizationRegistry?(jt=t=>t,t):(yt=new FinalizationRegistry((t=>{mt(t.$$)})),jt=t=>{var e=t.$$;if(e.smartPtr){var r={$$:e};yt.register(t,r,t)}return t},gt=t=>yt.unregister(t),jt(t))}function Et(){if(this.$$.ptr||vt(this),this.$$.preservePointerOnDelete)return this.$$.count.value+=1,this;var t,e=jt(Object.create(Object.getPrototypeOf(this),{$$:{value:(t=this.$$,{count:t.count,deleteScheduled:t.deleteScheduled,preservePointerOnDelete:t.preservePointerOnDelete,ptr:t.ptr,ptrType:t.ptrType,smartPtr:t.smartPtr,smartPtrType:t.smartPtrType})}}));return e.$$.count.value+=1,e.$$.deleteScheduled=!1,e}function Rt(){this.$$.ptr||vt(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&pt("Object already scheduled for deletion"),gt(this),mt(this.$$),this.$$.preservePointerOnDelete||(this.$$.smartPtr=void 0,this.$$.ptr=void 0)}function Dt(){return!this.$$.ptr}function Ft(){return this.$$.ptr||vt(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&pt("Object already scheduled for deletion"),Ct.push(this),1===Ct.length&&$t&&$t(_t),this.$$.deleteScheduled=!0,this}function Wt(){}function It(t,e,r){if(void 0===t[e].overloadTable){var n=t[e];t[e]=function(){return t[e].overloadTable.hasOwnProperty(arguments.length)||pt("Function '"+r+"' called with an invalid number of arguments ("+arguments.length+") - expects one of ("+t[e].overloadTable+")!"),t[e].overloadTable[arguments.length].apply(this,arguments)},t[e].overloadTable=[],t[e].overloadTable[n.argCount]=n}}function Ut(t,e,r){i.hasOwnProperty(t)?((void 0===r||void 0!==i[t].overloadTable&&void 0!==i[t].overloadTable[r])&&pt("Cannot register public name '"+t+"' twice"),It(i,t,t),i.hasOwnProperty(r)&&pt("Cannot register multiple overloads of a function with the same number of arguments ("+r+")!"),i[t].overloadTable[r]=e):(i[t]=e,void 0!==r&&(i[t].numArguments=r))}function Lt(t,e,r,n,o,i,a,s){this.name=t,this.constructor=e,this.instancePrototype=r,this.rawDestructor=n,this.baseClass=o,this.getActualType=i,this.upcast=a,this.downcast=s,this.pureVirtualFunctions=[]}function Ht(t,e,r){for(;e!==r;)e.upcast||pt("Expected null or instance of "+r.name+", got an instance of "+e.name),t=e.upcast(t),e=e.baseClass;return t}function Bt(t,e){if(null===e)return this.isReference&&pt("null is not a valid "+this.name),0;e.$$||pt('Cannot pass "'+fe(e)+'" as a '+this.name),e.$$.ptr||pt("Cannot pass deleted object as a pointer of type "+this.name);var r=e.$$.ptrType.registeredClass;return Ht(e.$$.ptr,r,this.registeredClass)}function Mt(t,e){var r;if(null===e)return this.isReference&&pt("null is not a valid "+this.name),this.isSmartPointer?(r=this.rawConstructor(),null!==t&&t.push(this.rawDestructor,r),r):0;e.$$||pt('Cannot pass "'+fe(e)+'" as a '+this.name),e.$$.ptr||pt("Cannot pass deleted object as a pointer of type "+this.name),!this.isConst&&e.$$.ptrType.isConst&&pt("Cannot convert argument of type "+(e.$$.smartPtrType?e.$$.smartPtrType.name:e.$$.ptrType.name)+" to parameter type "+this.name);var n=e.$$.ptrType.registeredClass;if(r=Ht(e.$$.ptr,n,this.registeredClass),this.isSmartPointer)switch(void 0===e.$$.smartPtr&&pt("Passing raw pointer to smart pointer is illegal"),this.sharingPolicy){case 0:e.$$.smartPtrType===this?r=e.$$.smartPtr:pt("Cannot convert argument of type "+(e.$$.smartPtrType?e.$$.smartPtrType.name:e.$$.ptrType.name)+" to parameter type "+this.name);break;case 1:r=e.$$.smartPtr;break;case 2:if(e.$$.smartPtrType===this)r=e.$$.smartPtr;else{var o=e.clone();r=this.rawShare(r,ce.toHandle((function(){o.delete()}))),null!==t&&t.push(this.rawDestructor,r)}break;default:pt("Unsupporting sharing policy")}return r}function Vt(t,e){if(null===e)return this.isReference&&pt("null is not a valid "+this.name),0;e.$$||pt('Cannot pass "'+fe(e)+'" as a '+this.name),e.$$.ptr||pt("Cannot pass deleted object as a pointer of type "+this.name),e.$$.ptrType.isConst&&pt("Cannot convert argument of type "+e.$$.ptrType.name+" to parameter type "+this.name);var r=e.$$.ptrType.registeredClass;return Ht(e.$$.ptr,r,this.registeredClass)}function zt(t){return this.rawGetPointee&&(t=this.rawGetPointee(t)),t}function Nt(t){this.rawDestructor&&this.rawDestructor(t)}function Gt(t){null!==t&&t.delete()}function qt(t,e,r,n,o,i,a,s,u,c,f){this.name=t,this.registeredClass=e,this.isReference=r,this.isConst=n,this.isSmartPointer=o,this.pointeeType=i,this.sharingPolicy=a,this.rawGetPointee=s,this.rawConstructor=u,this.rawShare=c,this.rawDestructor=f,o||void 0!==e.baseClass?this.toWireType=Mt:n?(this.toWireType=Bt,this.destructorFunction=null):(this.toWireType=Vt,this.destructorFunction=null)}function Jt(t,e,r){i.hasOwnProperty(t)||at("Replacing nonexistant public symbol"),void 0!==i[t].overloadTable&&void 0!==r?i[t].overloadTable[r]=e:(i[t]=e,i[t].argCount=r)}var Xt=[];function Yt(t){var e=Xt[t];return e||(t>=Xt.length&&(Xt.length=t+1),Xt[t]=e=D.get(t)),e}function Kt(t,e,r){return t.includes("j")?function(t,e,r){var n=i["dynCall_"+t];return r&&r.length?n.apply(null,[e].concat(r)):n.call(null,e)}(t,e,r):Yt(e).apply(null,r)}function Zt(t,e){var r,n,o,i=(t=ft(t)).includes("j")?(r=t,n=e,o=[],function(){return o.length=0,Object.assign(o,arguments),Kt(r,n,o)}):Yt(e);return"function"!=typeof i&&pt("unknown function pointer with signature "+t+": "+e),i}var Qt=void 0;function te(t){var e=Oe(t),r=ft(e);return ke(e),r}function ee(t,e){var r=[],n={};throw e.forEach((function t(e){n[e]||tt[e]||(et[e]?et[e].forEach(t):(r.push(e),n[e]=!0))})),new Qt(t+": "+r.map(te).join([", "]))}function re(t,e){for(var r=[],n=0;n<t;n++)r.push(A[e+4*n>>2]);return r}function ne(t,e,r,n,o){var i=e.length;i<2&&pt("argTypes array size mismatch! Must at least get return value and 'this' types!");for(var a=null!==e[1]&&null!==r,s=!1,u=1;u<e.length;++u)if(null!==e[u]&&void 0===e[u].destructorFunction){s=!0;break}var c="void"!==e[0].name,f="",l="";for(u=0;u<i-2;++u)f+=(0!==u?", ":"")+"arg"+u,l+=(0!==u?", ":"")+"arg"+u+"Wired";var p="return function "+rt(t)+"("+f+") {\nif (arguments.length !== "+(i-2)+") {\nthrowBindingError('function "+t+" called with ' + arguments.length + ' arguments, expected "+(i-2)+" args!');\n}\n";s&&(p+="var destructors = [];\n");var h=s?"destructors":"null",d=["throwBindingError","invoker","fn","runDestructors","retType","classParam"],v=[pt,n,o,K,e[0],e[1]];for(a&&(p+="var thisWired = classParam.toWireType("+h+", this);\n"),u=0;u<i-2;++u)p+="var arg"+u+"Wired = argType"+u+".toWireType("+h+", arg"+u+"); // "+e[u+2].name+"\n",d.push("argType"+u),v.push(e[u+2]);if(a&&(l="thisWired"+(l.length>0?", ":"")+l),p+=(c?"var rv = ":"")+"invoker(fn"+(l.length>0?", ":"")+l+");\n",s)p+="runDestructors(destructors);\n";else for(u=a?1:2;u<e.length;++u){var y=1===u?"thisWired":"arg"+(u-2)+"Wired";null!==e[u].destructorFunction&&(p+=y+"_dtor("+y+"); // "+e[u].name+"\n",d.push(y+"_dtor"),v.push(e[u].destructorFunction))}return c&&(p+="var ret = retType.fromWireType(rv);\nreturn ret;\n"),p+="}\n",d.push(p),function(t,e){if(!(t instanceof Function))throw new TypeError("new_ called with constructor type "+typeof t+" which is not a function");var r=nt(t.name||"unknownFunctionName",(function(){}));r.prototype=t.prototype;var n=new r,o=t.apply(n,e);return o instanceof Object?o:n}(Function,d).apply(null,v)}var oe=[],ie=[{},{value:void 0},{value:null},{value:!0},{value:!1}];function ae(t){t>4&&0==--ie[t].refcount&&(ie[t]=void 0,oe.push(t))}function se(){for(var t=0,e=5;e<ie.length;++e)void 0!==ie[e]&&++t;return t}function ue(){for(var t=5;t<ie.length;++t)if(void 0!==ie[t])return ie[t];return null}var ce={toValue:t=>(t||pt("Cannot use deleted val. handle = "+t),ie[t].value),toHandle:t=>{switch(t){case void 0:return 1;case null:return 2;case!0:return 3;case!1:return 4;default:var e=oe.length?oe.pop():ie.length;return ie[e]={refcount:1,value:t},e}}};function fe(t){if(null===t)return"null";var e=typeof t;return"object"===e||"array"===e||"function"===e?t.toString():""+t}function le(t,e){switch(e){case 2:return function(t){return this.fromWireType(x[t>>2])};case 3:return function(t){return this.fromWireType(O[t>>3])};default:throw new TypeError("Unknown float type: "+t)}}function pe(t,e,r){switch(e){case 0:return r?function(t){return P[t]}:function(t){return T[t]};case 1:return r?function(t){return C[t>>1]}:function(t){return _[t>>1]};case 2:return r?function(t){return $[t>>2]}:function(t){return A[t>>2]};default:throw new TypeError("Unknown integer type: "+t)}}var he="undefined"!=typeof TextDecoder?new TextDecoder("utf-16le"):void 0;function de(t,e){for(var r=t,n=r>>1,o=n+e/2;!(n>=o)&&_[n];)++n;if((r=n<<1)-t>32&&he)return he.decode(T.subarray(t,r));for(var i="",a=0;!(a>=e/2);++a){var s=C[t+2*a>>1];if(0==s)break;i+=String.fromCharCode(s)}return i}function ve(t,e,r){if(void 0===r&&(r=2147483647),r<2)return 0;for(var n=e,o=(r-=2)<2*t.length?r/2:t.length,i=0;i<o;++i){var a=t.charCodeAt(i);C[e>>1]=a,e+=2}return C[e>>1]=0,e-n}function ye(t){return 2*t.length}function ge(t,e){for(var r=0,n="";!(r>=e/4);){var o=$[t+4*r>>2];if(0==o)break;if(++r,o>=65536){var i=o-65536;n+=String.fromCharCode(55296|i>>10,56320|1023&i)}else n+=String.fromCharCode(o)}return n}function me(t,e,r){if(void 0===r&&(r=2147483647),r<4)return 0;for(var n=e,o=n+r-4,i=0;i<t.length;++i){var a=t.charCodeAt(i);if(a>=55296&&a<=57343&&(a=65536+((1023&a)<<10)|1023&t.charCodeAt(++i)),$[e>>2]=a,(e+=4)+4>o)break}return $[e>>2]=0,e-n}function we(t){for(var e=0,r=0;r<t.length;++r){var n=t.charCodeAt(r);n>=55296&&n<=57343&&++r,e+=4}return e}var be={};function Pe(){return"object"==typeof globalThis?globalThis:Function("return this")()}function Te(t,e){var r=tt[t];return void 0===r&&pt(e+" has unknown type "+te(t)),r}var Ce={};function _e(t){try{return w.grow(t-b.byteLength+65535>>>16),R(w.buffer),1}catch(t){}}it=i.InternalError=ot(Error,"InternalError"),function(){for(var t=new Array(256),e=0;e<256;++e)t[e]=String.fromCharCode(e);ct=t}(),lt=i.BindingError=ot(Error,"BindingError"),Wt.prototype.isAliasOf=dt,Wt.prototype.clone=Et,Wt.prototype.delete=Rt,Wt.prototype.isDeleted=Dt,Wt.prototype.deleteLater=Ft,i.getInheritedInstanceCount=Pt,i.getLiveInheritedInstances=Tt,i.flushPendingDeletes=_t,i.setDelayFunction=At,qt.prototype.getPointee=zt,qt.prototype.destructor=Nt,qt.prototype.argPackAdvance=8,qt.prototype.readValueFromPointer=Z,qt.prototype.deleteObject=Gt,qt.prototype.fromWireType=St,Qt=i.UnboundTypeError=ot(Error,"UnboundTypeError"),i.count_emval_handles=se,i.get_first_emval=ue;var $e,Ae={h:function(t,e,r){throw new X(t).init(e,r),t},q:function(t){var e=Y[t];delete Y[t];var r=e.rawConstructor,n=e.rawDestructor,o=e.fields;st([t],o.map((t=>t.getterReturnType)).concat(o.map((t=>t.setterArgumentType))),(t=>{var i={};return o.forEach(((e,r)=>{var n=e.fieldName,a=t[r],s=e.getter,u=e.getterContext,c=t[r+o.length],f=e.setter,l=e.setterContext;i[n]={read:t=>a.fromWireType(s(u,t)),write:(t,e)=>{var r=[];f(l,t,c.toWireType(r,e)),K(r)}}})),[{name:e.name,fromWireType:function(t){var e={};for(var r in i)e[r]=i[r].read(t);return n(t),e},toWireType:function(t,e){for(var o in i)if(!(o in e))throw new TypeError('Missing field: "'+o+'"');var a=r();for(o in i)i[o].write(a,e[o]);return null!==t&&t.push(n,a),a},argPackAdvance:8,readValueFromPointer:Z,destructorFunction:n}]}))},r:function(t,e,r,n,o){},w:function(t,e,r,n,o){var i=ut(r);ht(t,{name:e=ft(e),fromWireType:function(t){return!!t},toWireType:function(t,e){return e?n:o},argPackAdvance:8,readValueFromPointer:function(t){var n;if(1===r)n=P;else if(2===r)n=C;else{if(4!==r)throw new TypeError("Unknown boolean type size: "+e);n=$}return this.fromWireType(n[t>>i])},destructorFunction:null})},p:function(t,e,r,n,o,i,a,s,u,c,f,l,p){f=ft(f),i=Zt(o,i),s&&(s=Zt(a,s)),c&&(c=Zt(u,c)),p=Zt(l,p);var h=rt(f);Ut(h,(function(){ee("Cannot construct "+f+" due to unbound types",[n])})),st([t,e,r],n?[n]:[],(function(e){var r,o;e=e[0],o=n?(r=e.registeredClass).instancePrototype:Wt.prototype;var a=nt(h,(function(){if(Object.getPrototypeOf(this)!==u)throw new lt("Use 'new' to construct "+f);if(void 0===l.constructor_body)throw new lt(f+" has no accessible constructor");var t=l.constructor_body[arguments.length];if(void 0===t)throw new lt("Tried to invoke ctor of "+f+" with invalid number of parameters ("+arguments.length+") - expected ("+Object.keys(l.constructor_body).toString()+") parameters instead!");return t.apply(this,arguments)})),u=Object.create(o,{constructor:{value:a}});a.prototype=u;var l=new Lt(f,a,u,p,r,i,s,c),d=new qt(f,l,!0,!1,!1),v=new qt(f+"*",l,!1,!1,!1),y=new qt(f+" const*",l,!1,!0,!1);return bt[t]={pointerType:v,constPointerType:y},Jt(h,a),[d,v,y]}))},o:function(t,e,r,n,o,i){var a;e>0||V(a);var s=re(e,r);o=Zt(n,o),st([],[t],(function(t){var r="constructor "+(t=t[0]).name;if(void 0===t.registeredClass.constructor_body&&(t.registeredClass.constructor_body=[]),void 0!==t.registeredClass.constructor_body[e-1])throw new lt("Cannot register multiple constructors with identical number of parameters ("+(e-1)+") for class '"+t.name+"'! Overload resolution is currently only performed using the parameter count, not actual type info!");return t.registeredClass.constructor_body[e-1]=()=>{ee("Cannot construct "+t.name+" due to unbound types",s)},st([],s,(function(n){return n.splice(1,0,null),t.registeredClass.constructor_body[e-1]=ne(r,n,null,o,i),[]})),[]}))},c:function(t,e,r,n,o,i,a,s){var u=re(r,n);e=ft(e),i=Zt(o,i),st([],[t],(function(t){var n=(t=t[0]).name+"."+e;function o(){ee("Cannot call "+n+" due to unbound types",u)}e.startsWith("@@")&&(e=Symbol[e.substring(2)]),s&&t.registeredClass.pureVirtualFunctions.push(e);var c=t.registeredClass.instancePrototype,f=c[e];return void 0===f||void 0===f.overloadTable&&f.className!==t.name&&f.argCount===r-2?(o.argCount=r-2,o.className=t.name,c[e]=o):(It(c,e,n),c[e].overloadTable[r-2]=o),st([],u,(function(o){var s=ne(n,o,t,i,a);return void 0===c[e].overloadTable?(s.argCount=r-2,c[e]=s):c[e].overloadTable[r-2]=s,[]})),[]}))},v:function(t,e){ht(t,{name:e=ft(e),fromWireType:function(t){var e=ce.toValue(t);return ae(t),e},toWireType:function(t,e){return ce.toHandle(e)},argPackAdvance:8,readValueFromPointer:Z,destructorFunction:null})},k:function(t,e,r){var n=ut(r);ht(t,{name:e=ft(e),fromWireType:function(t){return t},toWireType:function(t,e){return e},argPackAdvance:8,readValueFromPointer:le(e,n),destructorFunction:null})},e:function(t,e,r,n,o,i){var a=re(e,r);t=ft(t),o=Zt(n,o),Ut(t,(function(){ee("Cannot call "+t+" due to unbound types",a)}),e-1),st([],a,(function(r){var n=[r[0],null].concat(r.slice(1));return Jt(t,ne(t,n,null,o,i),e-1),[]}))},b:function(t,e,r,n,o){e=ft(e),-1===o&&(o=4294967295);var i=ut(r),a=t=>t;if(0===n){var s=32-8*r;a=t=>t<<s>>>s}var u=e.includes("unsigned");ht(t,{name:e,fromWireType:a,toWireType:u?function(t,e){return this.name,e>>>0}:function(t,e){return this.name,e},argPackAdvance:8,readValueFromPointer:pe(e,i,0!==n),destructorFunction:null})},a:function(t,e,r){var n=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array][e];function o(t){var e=A,r=e[t>>=2],o=e[t+1];return new n(b,o,r)}ht(t,{name:r=ft(r),fromWireType:o,argPackAdvance:8,readValueFromPointer:o},{ignoreDuplicateRegistrations:!0})},j:function(t,e){var r="std::string"===(e=ft(e));ht(t,{name:e,fromWireType:function(t){var e,n=A[t>>2],o=t+4;if(r)for(var i=o,a=0;a<=n;++a){var s=o+a;if(a==n||0==T[s]){var u=j(i,s-i);void 0===e?e=u:(e+=String.fromCharCode(0),e+=u),i=s+1}}else{var c=new Array(n);for(a=0;a<n;++a)c[a]=String.fromCharCode(T[o+a]);e=c.join("")}return ke(t),e},toWireType:function(t,e){var n;e instanceof ArrayBuffer&&(e=new Uint8Array(e));var o="string"==typeof e;o||e instanceof Uint8Array||e instanceof Uint8ClampedArray||e instanceof Int8Array||pt("Cannot pass non-string to std::string"),n=r&&o?function(t){for(var e=0,r=0;r<t.length;++r){var n=t.charCodeAt(r);n<=127?e++:n<=2047?e+=2:n>=55296&&n<=57343?(e+=4,++r):e+=3}return e}(e):e.length;var i=xe(4+n+1),a=i+4;if(A[i>>2]=n,r&&o)E(e,a,n+1);else if(o)for(var s=0;s<n;++s){var u=e.charCodeAt(s);u>255&&(ke(a),pt("String has UTF-16 code units that do not fit in 8 bits")),T[a+s]=u}else for(s=0;s<n;++s)T[a+s]=e[s];return null!==t&&t.push(ke,i),i},argPackAdvance:8,readValueFromPointer:Z,destructorFunction:function(t){ke(t)}})},g:function(t,e,r){var n,o,i,a,s;r=ft(r),2===e?(n=de,o=ve,a=ye,i=()=>_,s=1):4===e&&(n=ge,o=me,a=we,i=()=>A,s=2),ht(t,{name:r,fromWireType:function(t){for(var r,o=A[t>>2],a=i(),u=t+4,c=0;c<=o;++c){var f=t+4+c*e;if(c==o||0==a[f>>s]){var l=n(u,f-u);void 0===r?r=l:(r+=String.fromCharCode(0),r+=l),u=f+e}}return ke(t),r},toWireType:function(t,n){"string"!=typeof n&&pt("Cannot pass non-string to C++ string type "+r);var i=a(n),u=xe(4+i+e);return A[u>>2]=i>>s,o(n,u+4,i+e),null!==t&&t.push(ke,u),u},argPackAdvance:8,readValueFromPointer:Z,destructorFunction:function(t){ke(t)}})},u:function(t,e,r,n,o,i){Y[t]={name:ft(e),rawConstructor:Zt(r,n),rawDestructor:Zt(o,i),fields:[]}},d:function(t,e,r,n,o,i,a,s,u,c){Y[t].fields.push({fieldName:ft(e),getterReturnType:r,getter:Zt(n,o),getterContext:i,setterArgumentType:a,setter:Zt(s,u),setterContext:c})},x:function(t,e){ht(t,{isVoid:!0,name:e=ft(e),argPackAdvance:0,fromWireType:function(){},toWireType:function(t,e){}})},i:ae,m:function(t){return 0===t?ce.toHandle(Pe()):(t=void 0===(r=be[e=t])?ft(e):r,ce.toHandle(Pe()[t]));var e,r},l:function(t){t>4&&(ie[t].refcount+=1)},y:function(t,e,r,n){t=ce.toValue(t);var o=Ce[e];return o||(o=function(t){for(var e="",r=0;r<t;++r)e+=(0!==r?", ":"")+"arg"+r;var n="return function emval_allocator_"+t+"(constructor, argTypes, args) {\n var HEAPU32 = getMemory();\n";for(r=0;r<t;++r)n+="var argType"+r+" = requireRegisteredType(HEAPU32[((argTypes)>>2)], 'parameter "+r+"');\nvar arg"+r+" = argType"+r+".readValueFromPointer(args);\nargs += argType"+r+"['argPackAdvance'];\nargTypes += 4;\n";return n+="var obj = new constructor("+e+");\nreturn valueToHandle(obj);\n}\n",new Function("requireRegisteredType","Module","valueToHandle","getMemory",n)(Te,i,ce.toHandle,(()=>A))}(e),Ce[e]=o),o(t,r,n)},n:function(t,e){var r=(t=Te(t,"_emval_take_value")).readValueFromPointer(e);return ce.toHandle(r)},f:function(){V("")},t:function(t,e,r){T.copyWithin(t,e,e+r)},s:function(t){var e,r,n=T.length,o=2147483648;if((t>>>=0)>o)return!1;for(var i=1;i<=4;i*=2){var a=n*(1+.2/i);if(a=Math.min(a,t+100663296),_e(Math.min(o,(e=Math.max(t,a))+((r=65536)-e%r)%r)))return!0}return!1}},xe=(function(){var t={a:Ae};function e(t,e){var r,n=t.exports;i.asm=n,R((w=i.asm.z).buffer),D=i.asm.C,r=i.asm.A,U.unshift(r),function(t){if(H--,i.monitorRunDependencies&&i.monitorRunDependencies(H),0==H&&(null!==B&&(clearInterval(B),B=null),M)){var e=M;M=null,e()}}()}function r(t){e(t.instance)}function n(e){return function(){if(!g&&(l||p)){if("function"==typeof fetch&&!N(F))return fetch(F,{credentials:"same-origin"}).then((function(t){if(!t.ok)throw"failed to load wasm binary file at '"+F+"'";return t.arrayBuffer()})).catch((function(){return G(F)}));if(s)return new Promise((function(t,e){s(F,(function(e){t(new Uint8Array(e))}),e)}))}return Promise.resolve().then((function(){return G(F)}))}().then((function(e){return WebAssembly.instantiate(e,t)})).then((function(t){return t})).then(e,(function(t){m("failed to asynchronously prepare wasm: "+t),V(t)}))}if(H++,i.monitorRunDependencies&&i.monitorRunDependencies(H),i.instantiateWasm)try{return i.instantiateWasm(t,e)}catch(t){m("Module.instantiateWasm callback failed with error: "+t),o(t)}(g||"function"!=typeof WebAssembly.instantiateStreaming||z(F)||N(F)||h||"function"!=typeof fetch?n(r):fetch(F,{credentials:"same-origin"}).then((function(e){return WebAssembly.instantiateStreaming(e,t).then(r,(function(t){return m("wasm streaming compile failed: "+t),m("falling back to ArrayBuffer instantiation"),n(r)}))}))).catch(o)}(),i.___wasm_call_ctors=function(){return(i.___wasm_call_ctors=i.asm.A).apply(null,arguments)},i._malloc=function(){return(xe=i._malloc=i.asm.B).apply(null,arguments)}),Oe=i.___getTypeName=function(){return(Oe=i.___getTypeName=i.asm.D).apply(null,arguments)},ke=(i.__embind_initialize_bindings=function(){return(i.__embind_initialize_bindings=i.asm.E).apply(null,arguments)},i._free=function(){return(ke=i._free=i.asm.F).apply(null,arguments)}),Se=i.stackSave=function(){return(Se=i.stackSave=i.asm.G).apply(null,arguments)},je=i.stackRestore=function(){return(je=i.stackRestore=i.asm.H).apply(null,arguments)},Ee=i.stackAlloc=function(){return(Ee=i.stackAlloc=i.asm.I).apply(null,arguments)},Re=i.___cxa_is_pointer_type=function(){return(Re=i.___cxa_is_pointer_type=i.asm.J).apply(null,arguments)};function De(t){function r(){$e||($e=!0,i.calledRun=!0,k||(J(U),e(i),i.onRuntimeInitialized&&i.onRuntimeInitialized(),function(){if(i.postRun)for("function"==typeof i.postRun&&(i.postRun=[i.postRun]);i.postRun.length;)t=i.postRun.shift(),L.unshift(t);var t;J(L)}()))}t=t||f,H>0||(function(){if(i.preRun)for("function"==typeof i.preRun&&(i.preRun=[i.preRun]);i.preRun.length;)t=i.preRun.shift(),I.unshift(t);var t;J(I)}(),H>0||(i.setStatus?(i.setStatus("Running..."),setTimeout((function(){setTimeout((function(){i.setStatus("")}),1),r()}),1)):r()))}if(i.ccall=function(t,e,r,n,o){var a={string:t=>{var e=0;if(null!=t&&0!==t){var r=1+(t.length<<2);E(t,e=Ee(r),r)}return e},array:t=>{var e=Ee(t.length);return function(t,e){P.set(t,e)}(t,e),e}},s=function(t){return i["_"+t]}(t),u=[],c=0;if(n)for(var f=0;f<n.length;f++){var l=a[r[f]];l?(0===c&&(c=Se()),u[f]=l(n[f])):u[f]=n[f]}var p=s.apply(null,u);return p=function(t){return 0!==c&&je(c),function(t){return"string"===e?j(t):"boolean"===e?Boolean(t):t}(t)}(p)},M=function t(){$e||De(),$e||(M=t)},i.preInit)for("function"==typeof i.preInit&&(i.preInit=[i.preInit]);i.preInit.length>0;)i.preInit.pop()();return De(),t.ready});t.exports=o},851:(t,e,r)=>{var n,o=(n=(n="undefined"!=typeof document&&document.currentScript?document.currentScript.src:void 0)||"/index.js",function(t){var e,o,i=void 0!==(t=t||{})?t:{};i.ready=new Promise((function(t,r){e=t,o=r}));var a,s,u,c=Object.assign({},i),f=[],l="./this.program",p=(t,e)=>{throw e},h="object"==typeof window,d="function"==typeof importScripts,v="object"==typeof process&&"object"==typeof process.versions&&"string"==typeof process.versions.node,y="";if(v){var g=r(491),m=r(33);y=d?m.dirname(y)+"/":"//",a=(t,e)=>(t=K(t)?new URL(t):m.normalize(t),g.readFileSync(t,e?void 0:"utf8")),u=t=>{var e=a(t,!0);return e.buffer||(e=new Uint8Array(e)),e},s=(t,e,r)=>{t=K(t)?new URL(t):m.normalize(t),g.readFile(t,(function(t,n){t?r(t):e(n.buffer)}))},process.argv.length>1&&(l=process.argv[1].replace(/\\/g,"/")),f=process.argv.slice(2),process.on("uncaughtException",(function(t){if(!(t instanceof Q))throw t})),process.on("unhandledRejection",(function(t){throw t})),p=(t,e)=>{if(V())throw process.exitCode=t,e;var r;(r=e)instanceof Q||P("exiting due to exception: "+r),process.exit(t)},i.inspect=function(){return"[Emscripten Module object]"}}else(h||d)&&(d?y=self.location.href:"undefined"!=typeof document&&document.currentScript&&(y=document.currentScript.src),n&&(y=n),y=0!==y.indexOf("blob:")?y.substr(0,y.replace(/[?#].*/,"").lastIndexOf("/")+1):"",a=t=>{var e=new XMLHttpRequest;return e.open("GET",t,!1),e.send(null),e.responseText},d&&(u=t=>{var e=new XMLHttpRequest;return e.open("GET",t,!1),e.responseType="arraybuffer",e.send(null),new Uint8Array(e.response)}),s=(t,e,r)=>{var n=new XMLHttpRequest;n.open("GET",t,!0),n.responseType="arraybuffer",n.onload=()=>{200==n.status||0==n.status&&n.response?e(n.response):r()},n.onerror=r,n.send(null)});var w,b=i.print||console.log.bind(console),P=i.printErr||console.warn.bind(console);Object.assign(i,c),c=null,i.arguments&&(f=i.arguments),i.thisProgram&&(l=i.thisProgram),i.quit&&(p=i.quit),i.wasmBinary&&(w=i.wasmBinary);var T,C=i.noExitRuntime||!0;"object"!=typeof WebAssembly&&X("no native wasm support detected");var _,$,A,x,O,k,S,j,E,R=!1,D="undefined"!=typeof TextDecoder?new TextDecoder("utf8"):void 0;function F(t,e,r){for(var n=e+r,o=e;t[o]&&!(o>=n);)++o;if(o-e>16&&t.buffer&&D)return D.decode(t.subarray(e,o));for(var i="";e<o;){var a=t[e++];if(128&a){var s=63&t[e++];if(192!=(224&a)){var u=63&t[e++];if((a=224==(240&a)?(15&a)<<12|s<<6|u:(7&a)<<18|s<<12|u<<6|63&t[e++])<65536)i+=String.fromCharCode(a);else{var c=a-65536;i+=String.fromCharCode(55296|c>>10,56320|1023&c)}}else i+=String.fromCharCode((31&a)<<6|s)}else i+=String.fromCharCode(a)}return i}function W(t,e){return t?F(A,t,e):""}function I(t,e,r){return function(t,e,r,n){if(!(n>0))return 0;for(var o=r,i=r+n-1,a=0;a<t.length;++a){var s=t.charCodeAt(a);if(s>=55296&&s<=57343&&(s=65536+((1023&s)<<10)|1023&t.charCodeAt(++a)),s<=127){if(r>=i)break;e[r++]=s}else if(s<=2047){if(r+1>=i)break;e[r++]=192|s>>6,e[r++]=128|63&s}else if(s<=65535){if(r+2>=i)break;e[r++]=224|s>>12,e[r++]=128|s>>6&63,e[r++]=128|63&s}else{if(r+3>=i)break;e[r++]=240|s>>18,e[r++]=128|s>>12&63,e[r++]=128|s>>6&63,e[r++]=128|63&s}}return e[r]=0,r-o}(t,A,e,r)}function U(t){_=t,i.HEAP8=$=new Int8Array(t),i.HEAP16=x=new Int16Array(t),i.HEAP32=k=new Int32Array(t),i.HEAPU8=A=new Uint8Array(t),i.HEAPU16=O=new Uint16Array(t),i.HEAPU32=S=new Uint32Array(t),i.HEAPF32=j=new Float32Array(t),i.HEAPF64=E=new Float64Array(t)}i.INITIAL_MEMORY;var L,H=[],B=[],M=[];function V(){return C}var z,N,G=0,q=null,J=null;function X(t){i.onAbort&&i.onAbort(t),P(t="Aborted("+t+")"),R=!0,t+=". Build with -sASSERTIONS for more info.";var e=new WebAssembly.RuntimeError(t);throw o(e),e}function Y(t){return t.startsWith("data:application/octet-stream;base64,")}function K(t){return t.startsWith("file://")}function Z(t){try{if(t==z&&w)return new Uint8Array(w);if(u)return u(t);throw"both async and sync fetching of the wasm failed"}catch(t){X(t)}}function Q(t){this.name="ExitStatus",this.message="Program terminated with exit("+t+")",this.status=t}function tt(t){for(;t.length>0;)t.shift()(i)}function et(t){this.excPtr=t,this.ptr=t-24,this.set_type=function(t){S[this.ptr+4>>2]=t},this.get_type=function(){return S[this.ptr+4>>2]},this.set_destructor=function(t){S[this.ptr+8>>2]=t},this.get_destructor=function(){return S[this.ptr+8>>2]},this.set_refcount=function(t){k[this.ptr>>2]=t},this.set_caught=function(t){t=t?1:0,$[this.ptr+12>>0]=t},this.get_caught=function(){return 0!=$[this.ptr+12>>0]},this.set_rethrown=function(t){t=t?1:0,$[this.ptr+13>>0]=t},this.get_rethrown=function(){return 0!=$[this.ptr+13>>0]},this.init=function(t,e){this.set_adjusted_ptr(0),this.set_type(t),this.set_destructor(e),this.set_refcount(0),this.set_caught(!1),this.set_rethrown(!1)},this.add_ref=function(){var t=k[this.ptr>>2];k[this.ptr>>2]=t+1},this.release_ref=function(){var t=k[this.ptr>>2];return k[this.ptr>>2]=t-1,1===t},this.set_adjusted_ptr=function(t){S[this.ptr+16>>2]=t},this.get_adjusted_ptr=function(){return S[this.ptr+16>>2]},this.get_exception_ptr=function(){if(Ve(this.get_type()))return S[this.excPtr>>2];var t=this.get_adjusted_ptr();return 0!==t?t:this.excPtr}}Y(z="libjpegturbowasm_decode.wasm")||(N=z,z=i.locateFile?i.locateFile(N,y):y+N);var rt={};function nt(t){for(;t.length;){var e=t.pop();t.pop()(e)}}function ot(t){return this.fromWireType(k[t>>2])}var it={},at={},st={};function ut(t){if(void 0===t)return"_unknown";var e=(t=t.replace(/[^a-zA-Z0-9_]/g,"$")).charCodeAt(0);return e>=48&&e<=57?"_"+t:t}function ct(t,e){return t=ut(t),new Function("body","return function "+t+'() {\n "use strict"; return body.apply(this, arguments);\n};\n')(e)}function ft(t,e){var r=ct(e,(function(t){this.name=e,this.message=t;var r=new Error(t).stack;void 0!==r&&(this.stack=this.toString()+"\n"+r.replace(/^Error(:[^\n]*)?\n/,""))}));return r.prototype=Object.create(t.prototype),r.prototype.constructor=r,r.prototype.toString=function(){return void 0===this.message?this.name:this.name+": "+this.message},r}var lt=void 0;function pt(t){throw new lt(t)}function ht(t,e,r){function n(e){var n=r(e);n.length!==t.length&&pt("Mismatched type converter count");for(var o=0;o<t.length;++o)wt(t[o],n[o])}t.forEach((function(t){st[t]=e}));var o=new Array(e.length),i=[],a=0;e.forEach(((t,e)=>{at.hasOwnProperty(t)?o[e]=at[t]:(i.push(t),it.hasOwnProperty(t)||(it[t]=[]),it[t].push((()=>{o[e]=at[t],++a===i.length&&n(o)})))})),0===i.length&&n(o)}function dt(t){switch(t){case 1:return 0;case 2:return 1;case 4:return 2;case 8:return 3;default:throw new TypeError("Unknown type size: "+t)}}var vt=void 0;function yt(t){for(var e="",r=t;A[r];)e+=vt[A[r++]];return e}var gt=void 0;function mt(t){throw new gt(t)}function wt(t,e,r={}){if(!("argPackAdvance"in e))throw new TypeError("registerType registeredInstance requires argPackAdvance");var n=e.name;if(t||mt('type "'+n+'" must have a positive integer typeid pointer'),at.hasOwnProperty(t)){if(r.ignoreDuplicateRegistrations)return;mt("Cannot register type '"+n+"' twice")}if(at[t]=e,delete st[t],it.hasOwnProperty(t)){var o=it[t];delete it[t],o.forEach((t=>t()))}}function bt(t){if(!(this instanceof Mt))return!1;if(!(t instanceof Mt))return!1;for(var e=this.$$.ptrType.registeredClass,r=this.$$.ptr,n=t.$$.ptrType.registeredClass,o=t.$$.ptr;e.baseClass;)r=e.upcast(r),e=e.baseClass;for(;n.baseClass;)o=n.upcast(o),n=n.baseClass;return e===n&&r===o}function Pt(t){mt(t.$$.ptrType.registeredClass.name+" instance already deleted")}var Tt=!1;function Ct(t){}function _t(t){t.count.value-=1,0===t.count.value&&function(t){t.smartPtr?t.smartPtrType.rawDestructor(t.smartPtr):t.ptrType.registeredClass.rawDestructor(t.ptr)}(t)}function $t(t,e,r){if(e===r)return t;if(void 0===r.baseClass)return null;var n=$t(t,e,r.baseClass);return null===n?null:r.downcast(n)}var At={};function xt(){return Object.keys(Rt).length}function Ot(){var t=[];for(var e in Rt)Rt.hasOwnProperty(e)&&t.push(Rt[e]);return t}var kt=[];function St(){for(;kt.length;){var t=kt.pop();t.$$.deleteScheduled=!1,t.delete()}}var jt=void 0;function Et(t){jt=t,kt.length&&jt&&jt(St)}var Rt={};function Dt(t,e){return e=function(t,e){for(void 0===e&&mt("ptr should not be undefined");t.baseClass;)e=t.upcast(e),t=t.baseClass;return e}(t,e),Rt[e]}function Ft(t,e){return e.ptrType&&e.ptr||pt("makeClassHandle requires ptr and ptrType"),!!e.smartPtrType!=!!e.smartPtr&&pt("Both smartPtrType and smartPtr must be specified"),e.count={value:1},It(Object.create(t,{$$:{value:e}}))}function Wt(t){var e=this.getPointee(t);if(!e)return this.destructor(t),null;var r=Dt(this.registeredClass,e);if(void 0!==r){if(0===r.$$.count.value)return r.$$.ptr=e,r.$$.smartPtr=t,r.clone();var n=r.clone();return this.destructor(t),n}function o(){return this.isSmartPointer?Ft(this.registeredClass.instancePrototype,{ptrType:this.pointeeType,ptr:e,smartPtrType:this,smartPtr:t}):Ft(this.registeredClass.instancePrototype,{ptrType:this,ptr:t})}var i,a=this.registeredClass.getActualType(e),s=At[a];if(!s)return o.call(this);i=this.isConst?s.constPointerType:s.pointerType;var u=$t(e,this.registeredClass,i.registeredClass);return null===u?o.call(this):this.isSmartPointer?Ft(i.registeredClass.instancePrototype,{ptrType:i,ptr:u,smartPtrType:this,smartPtr:t}):Ft(i.registeredClass.instancePrototype,{ptrType:i,ptr:u})}function It(t){return"undefined"==typeof FinalizationRegistry?(It=t=>t,t):(Tt=new FinalizationRegistry((t=>{_t(t.$$)})),It=t=>{var e=t.$$;if(e.smartPtr){var r={$$:e};Tt.register(t,r,t)}return t},Ct=t=>Tt.unregister(t),It(t))}function Ut(){if(this.$$.ptr||Pt(this),this.$$.preservePointerOnDelete)return this.$$.count.value+=1,this;var t,e=It(Object.create(Object.getPrototypeOf(this),{$$:{value:(t=this.$$,{count:t.count,deleteScheduled:t.deleteScheduled,preservePointerOnDelete:t.preservePointerOnDelete,ptr:t.ptr,ptrType:t.ptrType,smartPtr:t.smartPtr,smartPtrType:t.smartPtrType})}}));return e.$$.count.value+=1,e.$$.deleteScheduled=!1,e}function Lt(){this.$$.ptr||Pt(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&mt("Object already scheduled for deletion"),Ct(this),_t(this.$$),this.$$.preservePointerOnDelete||(this.$$.smartPtr=void 0,this.$$.ptr=void 0)}function Ht(){return!this.$$.ptr}function Bt(){return this.$$.ptr||Pt(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&mt("Object already scheduled for deletion"),kt.push(this),1===kt.length&&jt&&jt(St),this.$$.deleteScheduled=!0,this}function Mt(){}function Vt(t,e,r){if(void 0===t[e].overloadTable){var n=t[e];t[e]=function(){return t[e].overloadTable.hasOwnProperty(arguments.length)||mt("Function '"+r+"' called with an invalid number of arguments ("+arguments.length+") - expects one of ("+t[e].overloadTable+")!"),t[e].overloadTable[arguments.length].apply(this,arguments)},t[e].overloadTable=[],t[e].overloadTable[n.argCount]=n}}function zt(t,e,r,n,o,i,a,s){this.name=t,this.constructor=e,this.instancePrototype=r,this.rawDestructor=n,this.baseClass=o,this.getActualType=i,this.upcast=a,this.downcast=s,this.pureVirtualFunctions=[]}function Nt(t,e,r){for(;e!==r;)e.upcast||mt("Expected null or instance of "+r.name+", got an instance of "+e.name),t=e.upcast(t),e=e.baseClass;return t}function Gt(t,e){if(null===e)return this.isReference&&mt("null is not a valid "+this.name),0;e.$$||mt('Cannot pass "'+de(e)+'" as a '+this.name),e.$$.ptr||mt("Cannot pass deleted object as a pointer of type "+this.name);var r=e.$$.ptrType.registeredClass;return Nt(e.$$.ptr,r,this.registeredClass)}function qt(t,e){var r;if(null===e)return this.isReference&&mt("null is not a valid "+this.name),this.isSmartPointer?(r=this.rawConstructor(),null!==t&&t.push(this.rawDestructor,r),r):0;e.$$||mt('Cannot pass "'+de(e)+'" as a '+this.name),e.$$.ptr||mt("Cannot pass deleted object as a pointer of type "+this.name),!this.isConst&&e.$$.ptrType.isConst&&mt("Cannot convert argument of type "+(e.$$.smartPtrType?e.$$.smartPtrType.name:e.$$.ptrType.name)+" to parameter type "+this.name);var n=e.$$.ptrType.registeredClass;if(r=Nt(e.$$.ptr,n,this.registeredClass),this.isSmartPointer)switch(void 0===e.$$.smartPtr&&mt("Passing raw pointer to smart pointer is illegal"),this.sharingPolicy){case 0:e.$$.smartPtrType===this?r=e.$$.smartPtr:mt("Cannot convert argument of type "+(e.$$.smartPtrType?e.$$.smartPtrType.name:e.$$.ptrType.name)+" to parameter type "+this.name);break;case 1:r=e.$$.smartPtr;break;case 2:if(e.$$.smartPtrType===this)r=e.$$.smartPtr;else{var o=e.clone();r=this.rawShare(r,he.toHandle((function(){o.delete()}))),null!==t&&t.push(this.rawDestructor,r)}break;default:mt("Unsupporting sharing policy")}return r}function Jt(t,e){if(null===e)return this.isReference&&mt("null is not a valid "+this.name),0;e.$$||mt('Cannot pass "'+de(e)+'" as a '+this.name),e.$$.ptr||mt("Cannot pass deleted object as a pointer of type "+this.name),e.$$.ptrType.isConst&&mt("Cannot convert argument of type "+e.$$.ptrType.name+" to parameter type "+this.name);var r=e.$$.ptrType.registeredClass;return Nt(e.$$.ptr,r,this.registeredClass)}function Xt(t){return this.rawGetPointee&&(t=this.rawGetPointee(t)),t}function Yt(t){this.rawDestructor&&this.rawDestructor(t)}function Kt(t){null!==t&&t.delete()}function Zt(t,e,r,n,o,i,a,s,u,c,f){this.name=t,this.registeredClass=e,this.isReference=r,this.isConst=n,this.isSmartPointer=o,this.pointeeType=i,this.sharingPolicy=a,this.rawGetPointee=s,this.rawConstructor=u,this.rawShare=c,this.rawDestructor=f,o||void 0!==e.baseClass?this.toWireType=qt:n?(this.toWireType=Gt,this.destructorFunction=null):(this.toWireType=Jt,this.destructorFunction=null)}var Qt=[];function te(t){var e=Qt[t];return e||(t>=Qt.length&&(Qt.length=t+1),Qt[t]=e=L.get(t)),e}function ee(t,e,r){return t.includes("j")?function(t,e,r){var n=i["dynCall_"+t];return r&&r.length?n.apply(null,[e].concat(r)):n.call(null,e)}(t,e,r):te(e).apply(null,r)}function re(t,e){var r,n,o,i=(t=yt(t)).includes("j")?(r=t,n=e,o=[],function(){return o.length=0,Object.assign(o,arguments),ee(r,n,o)}):te(e);return"function"!=typeof i&&mt("unknown function pointer with signature "+t+": "+e),i}var ne=void 0;function oe(t){var e=Ue(t),r=yt(e);return Ie(e),r}function ie(t,e){var r=[],n={};throw e.forEach((function t(e){n[e]||at[e]||(st[e]?st[e].forEach(t):(r.push(e),n[e]=!0))})),new ne(t+": "+r.map(oe).join([", "]))}function ae(t,e){for(var r=[],n=0;n<t;n++)r.push(S[e+4*n>>2]);return r}function se(t,e,r,n,o){var i=e.length;i<2&&mt("argTypes array size mismatch! Must at least get return value and 'this' types!");for(var a=null!==e[1]&&null!==r,s=!1,u=1;u<e.length;++u)if(null!==e[u]&&void 0===e[u].destructorFunction){s=!0;break}var c="void"!==e[0].name,f="",l="";for(u=0;u<i-2;++u)f+=(0!==u?", ":"")+"arg"+u,l+=(0!==u?", ":"")+"arg"+u+"Wired";var p="return function "+ut(t)+"("+f+") {\nif (arguments.length !== "+(i-2)+") {\nthrowBindingError('function "+t+" called with ' + arguments.length + ' arguments, expected "+(i-2)+" args!');\n}\n";s&&(p+="var destructors = [];\n");var h=s?"destructors":"null",d=["throwBindingError","invoker","fn","runDestructors","retType","classParam"],v=[mt,n,o,nt,e[0],e[1]];for(a&&(p+="var thisWired = classParam.toWireType("+h+", this);\n"),u=0;u<i-2;++u)p+="var arg"+u+"Wired = argType"+u+".toWireType("+h+", arg"+u+"); // "+e[u+2].name+"\n",d.push("argType"+u),v.push(e[u+2]);if(a&&(l="thisWired"+(l.length>0?", ":"")+l),p+=(c?"var rv = ":"")+"invoker(fn"+(l.length>0?", ":"")+l+");\n",s)p+="runDestructors(destructors);\n";else for(u=a?1:2;u<e.length;++u){var y=1===u?"thisWired":"arg"+(u-2)+"Wired";null!==e[u].destructorFunction&&(p+=y+"_dtor("+y+"); // "+e[u].name+"\n",d.push(y+"_dtor"),v.push(e[u].destructorFunction))}return c&&(p+="var ret = retType.fromWireType(rv);\nreturn ret;\n"),p+="}\n",d.push(p),function(t,e){if(!(t instanceof Function))throw new TypeError("new_ called with constructor type "+typeof t+" which is not a function");var r=ct(t.name||"unknownFunctionName",(function(){}));r.prototype=t.prototype;var n=new r,o=t.apply(n,e);return o instanceof Object?o:n}(Function,d).apply(null,v)}var ue=[],ce=[{},{value:void 0},{value:null},{value:!0},{value:!1}];function fe(t){t>4&&0==--ce[t].refcount&&(ce[t]=void 0,ue.push(t))}function le(){for(var t=0,e=5;e<ce.length;++e)void 0!==ce[e]&&++t;return t}function pe(){for(var t=5;t<ce.length;++t)if(void 0!==ce[t])return ce[t];return null}var he={toValue:t=>(t||mt("Cannot use deleted val. handle = "+t),ce[t].value),toHandle:t=>{switch(t){case void 0:return 1;case null:return 2;case!0:return 3;case!1:return 4;default:var e=ue.length?ue.pop():ce.length;return ce[e]={refcount:1,value:t},e}}};function de(t){if(null===t)return"null";var e=typeof t;return"object"===e||"array"===e||"function"===e?t.toString():""+t}function ve(t,e){switch(e){case 2:return function(t){return this.fromWireType(j[t>>2])};case 3:return function(t){return this.fromWireType(E[t>>3])};default:throw new TypeError("Unknown float type: "+t)}}function ye(t,e,r){switch(e){case 0:return r?function(t){return $[t]}:function(t){return A[t]};case 1:return r?function(t){return x[t>>1]}:function(t){return O[t>>1]};case 2:return r?function(t){return k[t>>2]}:function(t){return S[t>>2]};default:throw new TypeError("Unknown integer type: "+t)}}var ge="undefined"!=typeof TextDecoder?new TextDecoder("utf-16le"):void 0;function me(t,e){for(var r=t,n=r>>1,o=n+e/2;!(n>=o)&&O[n];)++n;if((r=n<<1)-t>32&&ge)return ge.decode(A.subarray(t,r));for(var i="",a=0;!(a>=e/2);++a){var s=x[t+2*a>>1];if(0==s)break;i+=String.fromCharCode(s)}return i}function we(t,e,r){if(void 0===r&&(r=2147483647),r<2)return 0;for(var n=e,o=(r-=2)<2*t.length?r/2:t.length,i=0;i<o;++i){var a=t.charCodeAt(i);x[e>>1]=a,e+=2}return x[e>>1]=0,e-n}function be(t){return 2*t.length}function Pe(t,e){for(var r=0,n="";!(r>=e/4);){var o=k[t+4*r>>2];if(0==o)break;if(++r,o>=65536){var i=o-65536;n+=String.fromCharCode(55296|i>>10,56320|1023&i)}else n+=String.fromCharCode(o)}return n}function Te(t,e,r){if(void 0===r&&(r=2147483647),r<4)return 0;for(var n=e,o=n+r-4,i=0;i<t.length;++i){var a=t.charCodeAt(i);if(a>=55296&&a<=57343&&(a=65536+((1023&a)<<10)|1023&t.charCodeAt(++i)),k[e>>2]=a,(e+=4)+4>o)break}return k[e>>2]=0,e-n}function Ce(t){for(var e=0,r=0;r<t.length;++r){var n=t.charCodeAt(r);n>=55296&&n<=57343&&++r,e+=4}return e}var _e={};function $e(){return"object"==typeof globalThis?globalThis:Function("return this")()}function Ae(t,e){var r=at[t];return void 0===r&&mt(e+" has unknown type "+oe(t)),r}var xe={};function Oe(t){try{return T.grow(t-_.byteLength+65535>>>16),U(T.buffer),1}catch(t){}}var ke={};function Se(){if(!Se.strings){var t={USER:"web_user",LOGNAME:"web_user",PATH:"/",PWD:"/",HOME:"/home/web_user",LANG:("object"==typeof navigator&&navigator.languages&&navigator.languages[0]||"C").replace("-","_")+".UTF-8",_:l||"./this.program"};for(var e in ke)void 0===ke[e]?delete t[e]:t[e]=ke[e];var r=[];for(var e in t)r.push(e+"="+t[e]);Se.strings=r}return Se.strings}var je=function(t,e){var r;r=t,V()||(i.onExit&&i.onExit(r),R=!0),p(r,new Q(r))},Ee=[null,[],[]];function Re(t,e){var r=Ee[t];0===e||10===e?((1===t?b:P)(F(r,0)),r.length=0):r.push(e)}lt=i.InternalError=ft(Error,"InternalError"),function(){for(var t=new Array(256),e=0;e<256;++e)t[e]=String.fromCharCode(e);vt=t}(),gt=i.BindingError=ft(Error,"BindingError"),Mt.prototype.isAliasOf=bt,Mt.prototype.clone=Ut,Mt.prototype.delete=Lt,Mt.prototype.isDeleted=Ht,Mt.prototype.deleteLater=Bt,i.getInheritedInstanceCount=xt,i.getLiveInheritedInstances=Ot,i.flushPendingDeletes=St,i.setDelayFunction=Et,Zt.prototype.getPointee=Xt,Zt.prototype.destructor=Yt,Zt.prototype.argPackAdvance=8,Zt.prototype.readValueFromPointer=ot,Zt.prototype.deleteObject=Kt,Zt.prototype.fromWireType=Wt,ne=i.UnboundTypeError=ft(Error,"UnboundTypeError"),i.count_emval_handles=le,i.get_first_emval=pe;var De,Fe={g:function(t,e,r){throw new et(t).init(e,r),t},A:function(t){var e=rt[t];delete rt[t];var r=e.rawConstructor,n=e.rawDestructor,o=e.fields;ht([t],o.map((t=>t.getterReturnType)).concat(o.map((t=>t.setterArgumentType))),(t=>{var i={};return o.forEach(((e,r)=>{var n=e.fieldName,a=t[r],s=e.getter,u=e.getterContext,c=t[r+o.length],f=e.setter,l=e.setterContext;i[n]={read:t=>a.fromWireType(s(u,t)),write:(t,e)=>{var r=[];f(l,t,c.toWireType(r,e)),nt(r)}}})),[{name:e.name,fromWireType:function(t){var e={};for(var r in i)e[r]=i[r].read(t);return n(t),e},toWireType:function(t,e){for(var o in i)if(!(o in e))throw new TypeError('Missing field: "'+o+'"');var a=r();for(o in i)i[o].write(a,e[o]);return null!==t&&t.push(n,a),a},argPackAdvance:8,readValueFromPointer:ot,destructorFunction:n}]}))},w:function(t,e,r,n,o){},F:function(t,e,r,n,o){var i=dt(r);wt(t,{name:e=yt(e),fromWireType:function(t){return!!t},toWireType:function(t,e){return e?n:o},argPackAdvance:8,readValueFromPointer:function(t){var n;if(1===r)n=$;else if(2===r)n=x;else{if(4!==r)throw new TypeError("Unknown boolean type size: "+e);n=k}return this.fromWireType(n[t>>i])},destructorFunction:null})},u:function(t,e,r,n,o,a,s,u,c,f,l,p,h){l=yt(l),a=re(o,a),u&&(u=re(s,u)),f&&(f=re(c,f)),h=re(p,h);var d=ut(l);!function(t,e,r){i.hasOwnProperty(t)?((void 0===r||void 0!==i[t].overloadTable&&void 0!==i[t].overloadTable[r])&&mt("Cannot register public name '"+t+"' twice"),Vt(i,t,t),i.hasOwnProperty(r)&&mt("Cannot register multiple overloads of a function with the same number of arguments ("+r+")!"),i[t].overloadTable[r]=e):(i[t]=e,void 0!==r&&(i[t].numArguments=r))}(d,(function(){ie("Cannot construct "+l+" due to unbound types",[n])})),ht([t,e,r],n?[n]:[],(function(e){var r,o;e=e[0],o=n?(r=e.registeredClass).instancePrototype:Mt.prototype;var s=ct(d,(function(){if(Object.getPrototypeOf(this)!==c)throw new gt("Use 'new' to construct "+l);if(void 0===p.constructor_body)throw new gt(l+" has no accessible constructor");var t=p.constructor_body[arguments.length];if(void 0===t)throw new gt("Tried to invoke ctor of "+l+" with invalid number of parameters ("+arguments.length+") - expected ("+Object.keys(p.constructor_body).toString()+") parameters instead!");return t.apply(this,arguments)})),c=Object.create(o,{constructor:{value:s}});s.prototype=c;var p=new zt(l,s,c,h,r,a,u,f),v=new Zt(l,p,!0,!1,!1),y=new Zt(l+"*",p,!1,!1,!1),g=new Zt(l+" const*",p,!1,!0,!1);return At[t]={pointerType:y,constPointerType:g},function(t,e,r){i.hasOwnProperty(t)||pt("Replacing nonexistant public symbol"),void 0!==i[t].overloadTable&&void 0!==r?i[t].overloadTable[r]=e:(i[t]=e,i[t].argCount=r)}(d,s),[v,y,g]}))},t:function(t,e,r,n,o,i){var a;e>0||X(a);var s=ae(e,r);o=re(n,o),ht([],[t],(function(t){var r="constructor "+(t=t[0]).name;if(void 0===t.registeredClass.constructor_body&&(t.registeredClass.constructor_body=[]),void 0!==t.registeredClass.constructor_body[e-1])throw new gt("Cannot register multiple constructors with identical number of parameters ("+(e-1)+") for class '"+t.name+"'! Overload resolution is currently only performed using the parameter count, not actual type info!");return t.registeredClass.constructor_body[e-1]=()=>{ie("Cannot construct "+t.name+" due to unbound types",s)},ht([],s,(function(n){return n.splice(1,0,null),t.registeredClass.constructor_body[e-1]=se(r,n,null,o,i),[]})),[]}))},c:function(t,e,r,n,o,i,a,s){var u=ae(r,n);e=yt(e),i=re(o,i),ht([],[t],(function(t){var n=(t=t[0]).name+"."+e;function o(){ie("Cannot call "+n+" due to unbound types",u)}e.startsWith("@@")&&(e=Symbol[e.substring(2)]),s&&t.registeredClass.pureVirtualFunctions.push(e);var c=t.registeredClass.instancePrototype,f=c[e];return void 0===f||void 0===f.overloadTable&&f.className!==t.name&&f.argCount===r-2?(o.argCount=r-2,o.className=t.name,c[e]=o):(Vt(c,e,n),c[e].overloadTable[r-2]=o),ht([],u,(function(o){var s=se(n,o,t,i,a);return void 0===c[e].overloadTable?(s.argCount=r-2,c[e]=s):c[e].overloadTable[r-2]=s,[]})),[]}))},E:function(t,e){wt(t,{name:e=yt(e),fromWireType:function(t){var e=he.toValue(t);return fe(t),e},toWireType:function(t,e){return he.toHandle(e)},argPackAdvance:8,readValueFromPointer:ot,destructorFunction:null})},m:function(t,e,r){var n=dt(r);wt(t,{name:e=yt(e),fromWireType:function(t){return t},toWireType:function(t,e){return e},argPackAdvance:8,readValueFromPointer:ve(e,n),destructorFunction:null})},b:function(t,e,r,n,o){e=yt(e),-1===o&&(o=4294967295);var i=dt(r),a=t=>t;if(0===n){var s=32-8*r;a=t=>t<<s>>>s}var u=e.includes("unsigned");wt(t,{name:e,fromWireType:a,toWireType:u?function(t,e){return this.name,e>>>0}:function(t,e){return this.name,e},argPackAdvance:8,readValueFromPointer:ye(e,i,0!==n),destructorFunction:null})},a:function(t,e,r){var n=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array][e];function o(t){var e=S,r=e[t>>=2],o=e[t+1];return new n(_,o,r)}wt(t,{name:r=yt(r),fromWireType:o,argPackAdvance:8,readValueFromPointer:o},{ignoreDuplicateRegistrations:!0})},l:function(t,e){var r="std::string"===(e=yt(e));wt(t,{name:e,fromWireType:function(t){var e,n=S[t>>2],o=t+4;if(r)for(var i=o,a=0;a<=n;++a){var s=o+a;if(a==n||0==A[s]){var u=W(i,s-i);void 0===e?e=u:(e+=String.fromCharCode(0),e+=u),i=s+1}}else{var c=new Array(n);for(a=0;a<n;++a)c[a]=String.fromCharCode(A[o+a]);e=c.join("")}return Ie(t),e},toWireType:function(t,e){var n;e instanceof ArrayBuffer&&(e=new Uint8Array(e));var o="string"==typeof e;o||e instanceof Uint8Array||e instanceof Uint8ClampedArray||e instanceof Int8Array||mt("Cannot pass non-string to std::string"),n=r&&o?function(t){for(var e=0,r=0;r<t.length;++r){var n=t.charCodeAt(r);n<=127?e++:n<=2047?e+=2:n>=55296&&n<=57343?(e+=4,++r):e+=3}return e}(e):e.length;var i=We(4+n+1),a=i+4;if(S[i>>2]=n,r&&o)I(e,a,n+1);else if(o)for(var s=0;s<n;++s){var u=e.charCodeAt(s);u>255&&(Ie(a),mt("String has UTF-16 code units that do not fit in 8 bits")),A[a+s]=u}else for(s=0;s<n;++s)A[a+s]=e[s];return null!==t&&t.push(Ie,i),i},argPackAdvance:8,readValueFromPointer:ot,destructorFunction:function(t){Ie(t)}})},h:function(t,e,r){var n,o,i,a,s;r=yt(r),2===e?(n=me,o=we,a=be,i=()=>O,s=1):4===e&&(n=Pe,o=Te,a=Ce,i=()=>S,s=2),wt(t,{name:r,fromWireType:function(t){for(var r,o=S[t>>2],a=i(),u=t+4,c=0;c<=o;++c){var f=t+4+c*e;if(c==o||0==a[f>>s]){var l=n(u,f-u);void 0===r?r=l:(r+=String.fromCharCode(0),r+=l),u=f+e}}return Ie(t),r},toWireType:function(t,n){"string"!=typeof n&&mt("Cannot pass non-string to C++ string type "+r);var i=a(n),u=We(4+i+e);return S[u>>2]=i>>s,o(n,u+4,i+e),null!==t&&t.push(Ie,u),u},argPackAdvance:8,readValueFromPointer:ot,destructorFunction:function(t){Ie(t)}})},J:function(t,e,r,n,o,i){rt[t]={name:yt(e),rawConstructor:re(r,n),rawDestructor:re(o,i),fields:[]}},d:function(t,e,r,n,o,i,a,s,u,c){rt[t].fields.push({fieldName:yt(e),getterReturnType:r,getter:re(n,o),getterContext:i,setterArgumentType:a,setter:re(s,u),setterContext:c})},G:function(t,e){wt(t,{isVoid:!0,name:e=yt(e),argPackAdvance:0,fromWireType:function(){},toWireType:function(t,e){}})},x:function(){throw 1/0},i:fe,r:function(t){return 0===t?he.toHandle($e()):(t=void 0===(r=_e[e=t])?yt(e):r,he.toHandle($e()[t]));var e,r},p:function(t){t>4&&(ce[t].refcount+=1)},q:function(t,e,r,n){t=he.toValue(t);var o=xe[e];return o||(o=function(t){for(var e="",r=0;r<t;++r)e+=(0!==r?", ":"")+"arg"+r;var n="return function emval_allocator_"+t+"(constructor, argTypes, args) {\n var HEAPU32 = getMemory();\n";for(r=0;r<t;++r)n+="var argType"+r+" = requireRegisteredType(HEAPU32[((argTypes)>>2)], 'parameter "+r+"');\nvar arg"+r+" = argType"+r+".readValueFromPointer(args);\nargs += argType"+r+"['argPackAdvance'];\nargTypes += 4;\n";return n+="var obj = new constructor("+e+");\nreturn valueToHandle(obj);\n}\n",new Function("requireRegisteredType","Module","valueToHandle","getMemory",n)(Ae,i,he.toHandle,(()=>S))}(e),xe[e]=o),o(t,r,n)},s:function(t,e){var r=(t=Ae(t,"_emval_take_value")).readValueFromPointer(e);return he.toHandle(r)},j:function(){X("")},D:function(t,e,r){A.copyWithin(t,e,e+r)},y:function(t){var e,r,n=A.length,o=2147483648;if((t>>>=0)>o)return!1;for(var i=1;i<=4;i*=2){var a=n*(1+.2/i);if(a=Math.min(a,t+100663296),Oe(Math.min(o,(e=Math.max(t,a))+((r=65536)-e%r)%r)))return!0}return!1},z:function(t,e){var r=0;return Se().forEach((function(n,o){var i=e+r;S[t+4*o>>2]=i,function(t,e,r){for(var n=0;n<t.length;++n)$[e++>>0]=t.charCodeAt(n);r||($[e>>0]=0)}(n,i),r+=n.length+1})),0},B:function(t,e){var r=Se();S[t>>2]=r.length;var n=0;return r.forEach((function(t){n+=t.length+1})),S[e>>2]=n,0},I:je,C:function(t){return 52},v:function(t,e,r,n,o){return 70},k:function(t,e,r,n){for(var o=0,i=0;i<r;i++){var a=S[e>>2],s=S[e+4>>2];e+=8;for(var u=0;u<s;u++)Re(t,A[a+u]);o+=s}return S[n>>2]=o,0},o:function(t,e){var r=He();try{return te(t)(e)}catch(t){if(Be(r),t!==t+0)throw t;Le(1,0)}},n:function(t,e,r){var n=He();try{return te(t)(e,r)}catch(t){if(Be(n),t!==t+0)throw t;Le(1,0)}},H:function(t,e,r,n){var o=He();try{return te(t)(e,r,n)}catch(t){if(Be(o),t!==t+0)throw t;Le(1,0)}},f:function(t,e){var r=He();try{te(t)(e)}catch(t){if(Be(r),t!==t+0)throw t;Le(1,0)}},e:function(t,e,r,n){var o=He();try{te(t)(e,r,n)}catch(t){if(Be(o),t!==t+0)throw t;Le(1,0)}}},We=(function(){var t={a:Fe};function e(t,e){var r,n=t.exports;i.asm=n,U((T=i.asm.K).buffer),L=i.asm.M,r=i.asm.L,B.unshift(r),function(t){if(G--,i.monitorRunDependencies&&i.monitorRunDependencies(G),0==G&&(null!==q&&(clearInterval(q),q=null),J)){var e=J;J=null,e()}}()}function r(t){e(t.instance)}function n(e){return function(){if(!w&&(h||d)){if("function"==typeof fetch&&!K(z))return fetch(z,{credentials:"same-origin"}).then((function(t){if(!t.ok)throw"failed to load wasm binary file at '"+z+"'";return t.arrayBuffer()})).catch((function(){return Z(z)}));if(s)return new Promise((function(t,e){s(z,(function(e){t(new Uint8Array(e))}),e)}))}return Promise.resolve().then((function(){return Z(z)}))}().then((function(e){return WebAssembly.instantiate(e,t)})).then((function(t){return t})).then(e,(function(t){P("failed to asynchronously prepare wasm: "+t),X(t)}))}if(G++,i.monitorRunDependencies&&i.monitorRunDependencies(G),i.instantiateWasm)try{return i.instantiateWasm(t,e)}catch(t){P("Module.instantiateWasm callback failed with error: "+t),o(t)}(w||"function"!=typeof WebAssembly.instantiateStreaming||Y(z)||K(z)||v||"function"!=typeof fetch?n(r):fetch(z,{credentials:"same-origin"}).then((function(e){return WebAssembly.instantiateStreaming(e,t).then(r,(function(t){return P("wasm streaming compile failed: "+t),P("falling back to ArrayBuffer instantiation"),n(r)}))}))).catch(o)}(),i.___wasm_call_ctors=function(){return(i.___wasm_call_ctors=i.asm.L).apply(null,arguments)},i._malloc=function(){return(We=i._malloc=i.asm.N).apply(null,arguments)}),Ie=i._free=function(){return(Ie=i._free=i.asm.O).apply(null,arguments)},Ue=i.___getTypeName=function(){return(Ue=i.___getTypeName=i.asm.P).apply(null,arguments)},Le=(i.__embind_initialize_bindings=function(){return(i.__embind_initialize_bindings=i.asm.Q).apply(null,arguments)},i._setThrew=function(){return(Le=i._setThrew=i.asm.R).apply(null,arguments)}),He=i.stackSave=function(){return(He=i.stackSave=i.asm.S).apply(null,arguments)},Be=i.stackRestore=function(){return(Be=i.stackRestore=i.asm.T).apply(null,arguments)},Me=i.stackAlloc=function(){return(Me=i.stackAlloc=i.asm.U).apply(null,arguments)},Ve=i.___cxa_is_pointer_type=function(){return(Ve=i.___cxa_is_pointer_type=i.asm.V).apply(null,arguments)};function ze(t){function r(){De||(De=!0,i.calledRun=!0,R||(tt(B),e(i),i.onRuntimeInitialized&&i.onRuntimeInitialized(),function(){if(i.postRun)for("function"==typeof i.postRun&&(i.postRun=[i.postRun]);i.postRun.length;)t=i.postRun.shift(),M.unshift(t);var t;tt(M)}()))}t=t||f,G>0||(function(){if(i.preRun)for("function"==typeof i.preRun&&(i.preRun=[i.preRun]);i.preRun.length;)t=i.preRun.shift(),H.unshift(t);var t;tt(H)}(),G>0||(i.setStatus?(i.setStatus("Running..."),setTimeout((function(){setTimeout((function(){i.setStatus("")}),1),r()}),1)):r()))}if(i.dynCall_jiji=function(){return(i.dynCall_jiji=i.asm.W).apply(null,arguments)},i.ccall=function(t,e,r,n,o){var a={string:t=>{var e=0;if(null!=t&&0!==t){var r=1+(t.length<<2);I(t,e=Me(r),r)}return e},array:t=>{var e=Me(t.length);return function(t,e){$.set(t,e)}(t,e),e}},s=function(t){return i["_"+t]}(t),u=[],c=0;if(n)for(var f=0;f<n.length;f++){var l=a[r[f]];l?(0===c&&(c=He()),u[f]=l(n[f])):u[f]=n[f]}var p=s.apply(null,u);return p=function(t){return 0!==c&&Be(c),function(t){return"string"===e?W(t):"boolean"===e?Boolean(t):t}(t)}(p)},J=function t(){De||ze(),De||(J=t)},i.preInit)for("function"==typeof i.preInit&&(i.preInit=[i.preInit]);i.preInit.length>0;)i.preInit.pop()();return ze(),t.ready});t.exports=o},272:(t,e,r)=>{var n,o=(n=(n="undefined"!=typeof document&&document.currentScript?document.currentScript.src:void 0)||"/index.js",function(t){var e,o,i=void 0!==(t=t||{})?t:{};i.ready=new Promise((function(t,r){e=t,o=r}));var a,s,u,c=Object.assign({},i),f=[],l="./this.program",p="object"==typeof window,h="function"==typeof importScripts,d="object"==typeof process&&"object"==typeof process.versions&&"string"==typeof process.versions.node,v="";if(d){var y=r(261),g=r(926);v=h?g.dirname(v)+"/":"//",a=(t,e)=>(t=J(t)?new URL(t):g.normalize(t),y.readFileSync(t,e?void 0:"utf8")),u=t=>{var e=a(t,!0);return e.buffer||(e=new Uint8Array(e)),e},s=(t,e,r)=>{t=J(t)?new URL(t):g.normalize(t),y.readFile(t,(function(t,n){t?r(t):e(n.buffer)}))},process.argv.length>1&&(l=process.argv[1].replace(/\\/g,"/")),f=process.argv.slice(2),process.on("uncaughtException",(function(t){if(!(t instanceof Y))throw t})),process.on("unhandledRejection",(function(t){throw t})),i.inspect=function(){return"[Emscripten Module object]"}}else(p||h)&&(h?v=self.location.href:"undefined"!=typeof document&&document.currentScript&&(v=document.currentScript.src),n&&(v=n),v=0!==v.indexOf("blob:")?v.substr(0,v.replace(/[?#].*/,"").lastIndexOf("/")+1):"",a=t=>{var e=new XMLHttpRequest;return e.open("GET",t,!1),e.send(null),e.responseText},h&&(u=t=>{var e=new XMLHttpRequest;return e.open("GET",t,!1),e.responseType="arraybuffer",e.send(null),new Uint8Array(e.response)}),s=(t,e,r)=>{var n=new XMLHttpRequest;n.open("GET",t,!0),n.responseType="arraybuffer",n.onload=()=>{200==n.status||0==n.status&&n.response?e(n.response):r()},n.onerror=r,n.send(null)});var m,w=i.print||console.log.bind(console),b=i.printErr||console.warn.bind(console);Object.assign(i,c),c=null,i.arguments&&(f=i.arguments),i.thisProgram&&(l=i.thisProgram),i.quit&&i.quit,i.wasmBinary&&(m=i.wasmBinary);var P;i.noExitRuntime;"object"!=typeof WebAssembly&&G("no native wasm support detected");var T,C,_,$,A,x,O,k,S,j=!1,E="undefined"!=typeof TextDecoder?new TextDecoder("utf8"):void 0;function R(t,e,r){for(var n=e+r,o=e;t[o]&&!(o>=n);)++o;if(o-e>16&&t.buffer&&E)return E.decode(t.subarray(e,o));for(var i="";e<o;){var a=t[e++];if(128&a){var s=63&t[e++];if(192!=(224&a)){var u=63&t[e++];if((a=224==(240&a)?(15&a)<<12|s<<6|u:(7&a)<<18|s<<12|u<<6|63&t[e++])<65536)i+=String.fromCharCode(a);else{var c=a-65536;i+=String.fromCharCode(55296|c>>10,56320|1023&c)}}else i+=String.fromCharCode((31&a)<<6|s)}else i+=String.fromCharCode(a)}return i}function D(t,e){return t?R(_,t,e):""}function F(t,e,r){return function(t,e,r,n){if(!(n>0))return 0;for(var o=r,i=r+n-1,a=0;a<t.length;++a){var s=t.charCodeAt(a);if(s>=55296&&s<=57343&&(s=65536+((1023&s)<<10)|1023&t.charCodeAt(++a)),s<=127){if(r>=i)break;e[r++]=s}else if(s<=2047){if(r+1>=i)break;e[r++]=192|s>>6,e[r++]=128|63&s}else if(s<=65535){if(r+2>=i)break;e[r++]=224|s>>12,e[r++]=128|s>>6&63,e[r++]=128|63&s}else{if(r+3>=i)break;e[r++]=240|s>>18,e[r++]=128|s>>12&63,e[r++]=128|s>>6&63,e[r++]=128|63&s}}return e[r]=0,r-o}(t,_,e,r)}function W(t){T=t,i.HEAP8=C=new Int8Array(t),i.HEAP16=$=new Int16Array(t),i.HEAP32=x=new Int32Array(t),i.HEAPU8=_=new Uint8Array(t),i.HEAPU16=A=new Uint16Array(t),i.HEAPU32=O=new Uint32Array(t),i.HEAPF32=k=new Float32Array(t),i.HEAPF64=S=new Float64Array(t)}i.INITIAL_MEMORY;var I,U,L,H=[],B=[],M=[],V=0,z=null,N=null;function G(t){i.onAbort&&i.onAbort(t),b(t="Aborted("+t+")"),j=!0,t+=". Build with -sASSERTIONS for more info.";var e=new WebAssembly.RuntimeError(t);throw o(e),e}function q(t){return t.startsWith("data:application/octet-stream;base64,")}function J(t){return t.startsWith("file://")}function X(t){try{if(t==U&&m)return new Uint8Array(m);if(u)return u(t);throw"both async and sync fetching of the wasm failed"}catch(t){G(t)}}function Y(t){this.name="ExitStatus",this.message="Program terminated with exit("+t+")",this.status=t}function K(t){for(;t.length>0;)t.shift()(i)}function Z(t){this.excPtr=t,this.ptr=t-24,this.set_type=function(t){O[this.ptr+4>>2]=t},this.get_type=function(){return O[this.ptr+4>>2]},this.set_destructor=function(t){O[this.ptr+8>>2]=t},this.get_destructor=function(){return O[this.ptr+8>>2]},this.set_refcount=function(t){x[this.ptr>>2]=t},this.set_caught=function(t){t=t?1:0,C[this.ptr+12>>0]=t},this.get_caught=function(){return 0!=C[this.ptr+12>>0]},this.set_rethrown=function(t){t=t?1:0,C[this.ptr+13>>0]=t},this.get_rethrown=function(){return 0!=C[this.ptr+13>>0]},this.init=function(t,e){this.set_adjusted_ptr(0),this.set_type(t),this.set_destructor(e),this.set_refcount(0),this.set_caught(!1),this.set_rethrown(!1)},this.add_ref=function(){var t=x[this.ptr>>2];x[this.ptr>>2]=t+1},this.release_ref=function(){var t=x[this.ptr>>2];return x[this.ptr>>2]=t-1,1===t},this.set_adjusted_ptr=function(t){O[this.ptr+16>>2]=t},this.get_adjusted_ptr=function(){return O[this.ptr+16>>2]},this.get_exception_ptr=function(){if(Ue(this.get_type()))return O[this.excPtr>>2];var t=this.get_adjusted_ptr();return 0!==t?t:this.excPtr}}q(U="openjpegwasm_decode.wasm")||(L=U,U=i.locateFile?i.locateFile(L,v):v+L);var Q={};function tt(t){for(;t.length;){var e=t.pop();t.pop()(e)}}function et(t){return this.fromWireType(x[t>>2])}var rt={},nt={},ot={};function it(t){if(void 0===t)return"_unknown";var e=(t=t.replace(/[^a-zA-Z0-9_]/g,"$")).charCodeAt(0);return e>=48&&e<=57?"_"+t:t}function at(t,e){return t=it(t),new Function("body","return function "+t+'() {\n "use strict"; return body.apply(this, arguments);\n};\n')(e)}function st(t,e){var r=at(e,(function(t){this.name=e,this.message=t;var r=new Error(t).stack;void 0!==r&&(this.stack=this.toString()+"\n"+r.replace(/^Error(:[^\n]*)?\n/,""))}));return r.prototype=Object.create(t.prototype),r.prototype.constructor=r,r.prototype.toString=function(){return void 0===this.message?this.name:this.name+": "+this.message},r}var ut=void 0;function ct(t){throw new ut(t)}function ft(t,e,r){function n(e){var n=r(e);n.length!==t.length&&ct("Mismatched type converter count");for(var o=0;o<t.length;++o)yt(t[o],n[o])}t.forEach((function(t){ot[t]=e}));var o=new Array(e.length),i=[],a=0;e.forEach(((t,e)=>{nt.hasOwnProperty(t)?o[e]=nt[t]:(i.push(t),rt.hasOwnProperty(t)||(rt[t]=[]),rt[t].push((()=>{o[e]=nt[t],++a===i.length&&n(o)})))})),0===i.length&&n(o)}function lt(t){switch(t){case 1:return 0;case 2:return 1;case 4:return 2;case 8:return 3;default:throw new TypeError("Unknown type size: "+t)}}var pt=void 0;function ht(t){for(var e="",r=t;_[r];)e+=pt[_[r++]];return e}var dt=void 0;function vt(t){throw new dt(t)}function yt(t,e,r={}){if(!("argPackAdvance"in e))throw new TypeError("registerType registeredInstance requires argPackAdvance");var n=e.name;if(t||vt('type "'+n+'" must have a positive integer typeid pointer'),nt.hasOwnProperty(t)){if(r.ignoreDuplicateRegistrations)return;vt("Cannot register type '"+n+"' twice")}if(nt[t]=e,delete ot[t],rt.hasOwnProperty(t)){var o=rt[t];delete rt[t],o.forEach((t=>t()))}}function gt(t){if(!(this instanceof Lt))return!1;if(!(t instanceof Lt))return!1;for(var e=this.$$.ptrType.registeredClass,r=this.$$.ptr,n=t.$$.ptrType.registeredClass,o=t.$$.ptr;e.baseClass;)r=e.upcast(r),e=e.baseClass;for(;n.baseClass;)o=n.upcast(o),n=n.baseClass;return e===n&&r===o}function mt(t){vt(t.$$.ptrType.registeredClass.name+" instance already deleted")}var wt=!1;function bt(t){}function Pt(t){t.count.value-=1,0===t.count.value&&function(t){t.smartPtr?t.smartPtrType.rawDestructor(t.smartPtr):t.ptrType.registeredClass.rawDestructor(t.ptr)}(t)}function Tt(t,e,r){if(e===r)return t;if(void 0===r.baseClass)return null;var n=Tt(t,e,r.baseClass);return null===n?null:r.downcast(n)}var Ct={};function _t(){return Object.keys(St).length}function $t(){var t=[];for(var e in St)St.hasOwnProperty(e)&&t.push(St[e]);return t}var At=[];function xt(){for(;At.length;){var t=At.pop();t.$$.deleteScheduled=!1,t.delete()}}var Ot=void 0;function kt(t){Ot=t,At.length&&Ot&&Ot(xt)}var St={};function jt(t,e){return e=function(t,e){for(void 0===e&&vt("ptr should not be undefined");t.baseClass;)e=t.upcast(e),t=t.baseClass;return e}(t,e),St[e]}function Et(t,e){return e.ptrType&&e.ptr||ct("makeClassHandle requires ptr and ptrType"),!!e.smartPtrType!=!!e.smartPtr&&ct("Both smartPtrType and smartPtr must be specified"),e.count={value:1},Dt(Object.create(t,{$$:{value:e}}))}function Rt(t){var e=this.getPointee(t);if(!e)return this.destructor(t),null;var r=jt(this.registeredClass,e);if(void 0!==r){if(0===r.$$.count.value)return r.$$.ptr=e,r.$$.smartPtr=t,r.clone();var n=r.clone();return this.destructor(t),n}function o(){return this.isSmartPointer?Et(this.registeredClass.instancePrototype,{ptrType:this.pointeeType,ptr:e,smartPtrType:this,smartPtr:t}):Et(this.registeredClass.instancePrototype,{ptrType:this,ptr:t})}var i,a=this.registeredClass.getActualType(e),s=Ct[a];if(!s)return o.call(this);i=this.isConst?s.constPointerType:s.pointerType;var u=Tt(e,this.registeredClass,i.registeredClass);return null===u?o.call(this):this.isSmartPointer?Et(i.registeredClass.instancePrototype,{ptrType:i,ptr:u,smartPtrType:this,smartPtr:t}):Et(i.registeredClass.instancePrototype,{ptrType:i,ptr:u})}function Dt(t){return"undefined"==typeof FinalizationRegistry?(Dt=t=>t,t):(wt=new FinalizationRegistry((t=>{Pt(t.$$)})),Dt=t=>{var e=t.$$;if(e.smartPtr){var r={$$:e};wt.register(t,r,t)}return t},bt=t=>wt.unregister(t),Dt(t))}function Ft(){if(this.$$.ptr||mt(this),this.$$.preservePointerOnDelete)return this.$$.count.value+=1,this;var t,e=Dt(Object.create(Object.getPrototypeOf(this),{$$:{value:(t=this.$$,{count:t.count,deleteScheduled:t.deleteScheduled,preservePointerOnDelete:t.preservePointerOnDelete,ptr:t.ptr,ptrType:t.ptrType,smartPtr:t.smartPtr,smartPtrType:t.smartPtrType})}}));return e.$$.count.value+=1,e.$$.deleteScheduled=!1,e}function Wt(){this.$$.ptr||mt(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&vt("Object already scheduled for deletion"),bt(this),Pt(this.$$),this.$$.preservePointerOnDelete||(this.$$.smartPtr=void 0,this.$$.ptr=void 0)}function It(){return!this.$$.ptr}function Ut(){return this.$$.ptr||mt(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&&vt("Object already scheduled for deletion"),At.push(this),1===At.length&&Ot&&Ot(xt),this.$$.deleteScheduled=!0,this}function Lt(){}function Ht(t,e,r){if(void 0===t[e].overloadTable){var n=t[e];t[e]=function(){return t[e].overloadTable.hasOwnProperty(arguments.length)||vt("Function '"+r+"' called with an invalid number of arguments ("+arguments.length+") - expects one of ("+t[e].overloadTable+")!"),t[e].overloadTable[arguments.length].apply(this,arguments)},t[e].overloadTable=[],t[e].overloadTable[n.argCount]=n}}function Bt(t,e,r,n,o,i,a,s){this.name=t,this.constructor=e,this.instancePrototype=r,this.rawDestructor=n,this.baseClass=o,this.getActualType=i,this.upcast=a,this.downcast=s,this.pureVirtualFunctions=[]}function Mt(t,e,r){for(;e!==r;)e.upcast||vt("Expected null or instance of "+r.name+", got an instance of "+e.name),t=e.upcast(t),e=e.baseClass;return t}function Vt(t,e){if(null===e)return this.isReference&&vt("null is not a valid "+this.name),0;e.$$||vt('Cannot pass "'+le(e)+'" as a '+this.name),e.$$.ptr||vt("Cannot pass deleted object as a pointer of type "+this.name);var r=e.$$.ptrType.registeredClass;return Mt(e.$$.ptr,r,this.registeredClass)}function zt(t,e){var r;if(null===e)return this.isReference&&vt("null is not a valid "+this.name),this.isSmartPointer?(r=this.rawConstructor(),null!==t&&t.push(this.rawDestructor,r),r):0;e.$$||vt('Cannot pass "'+le(e)+'" as a '+this.name),e.$$.ptr||vt("Cannot pass deleted object as a pointer of type "+this.name),!this.isConst&&e.$$.ptrType.isConst&&vt("Cannot convert argument of type "+(e.$$.smartPtrType?e.$$.smartPtrType.name:e.$$.ptrType.name)+" to parameter type "+this.name);var n=e.$$.ptrType.registeredClass;if(r=Mt(e.$$.ptr,n,this.registeredClass),this.isSmartPointer)switch(void 0===e.$$.smartPtr&&vt("Passing raw pointer to smart pointer is illegal"),this.sharingPolicy){case 0:e.$$.smartPtrType===this?r=e.$$.smartPtr:vt("Cannot convert argument of type "+(e.$$.smartPtrType?e.$$.smartPtrType.name:e.$$.ptrType.name)+" to parameter type "+this.name);break;case 1:r=e.$$.smartPtr;break;case 2:if(e.$$.smartPtrType===this)r=e.$$.smartPtr;else{var o=e.clone();r=this.rawShare(r,fe.toHandle((function(){o.delete()}))),null!==t&&t.push(this.rawDestructor,r)}break;default:vt("Unsupporting sharing policy")}return r}function Nt(t,e){if(null===e)return this.isReference&&vt("null is not a valid "+this.name),0;e.$$||vt('Cannot pass "'+le(e)+'" as a '+this.name),e.$$.ptr||vt("Cannot pass deleted object as a pointer of type "+this.name),e.$$.ptrType.isConst&&vt("Cannot convert argument of type "+e.$$.ptrType.name+" to parameter type "+this.name);var r=e.$$.ptrType.registeredClass;return Mt(e.$$.ptr,r,this.registeredClass)}function Gt(t){return this.rawGetPointee&&(t=this.rawGetPointee(t)),t}function qt(t){this.rawDestructor&&this.rawDestructor(t)}function Jt(t){null!==t&&t.delete()}function Xt(t,e,r,n,o,i,a,s,u,c,f){this.name=t,this.registeredClass=e,this.isReference=r,this.isConst=n,this.isSmartPointer=o,this.pointeeType=i,this.sharingPolicy=a,this.rawGetPointee=s,this.rawConstructor=u,this.rawShare=c,this.rawDestructor=f,o||void 0!==e.baseClass?this.toWireType=zt:n?(this.toWireType=Vt,this.destructorFunction=null):(this.toWireType=Nt,this.destructorFunction=null)}var Yt=[];function Kt(t){var e=Yt[t];return e||(t>=Yt.length&&(Yt.length=t+1),Yt[t]=e=I.get(t)),e}function Zt(t,e,r){return t.includes("j")?function(t,e,r){var n=i["dynCall_"+t];return r&&r.length?n.apply(null,[e].concat(r)):n.call(null,e)}(t,e,r):Kt(e).apply(null,r)}function Qt(t,e){var r,n,o,i=(t=ht(t)).includes("j")?(r=t,n=e,o=[],function(){return o.length=0,Object.assign(o,arguments),Zt(r,n,o)}):Kt(e);return"function"!=typeof i&&vt("unknown function pointer with signature "+t+": "+e),i}var te=void 0;function ee(t){var e=De(t),r=ht(e);return Re(e),r}function re(t,e){var r=[],n={};throw e.forEach((function t(e){n[e]||nt[e]||(ot[e]?ot[e].forEach(t):(r.push(e),n[e]=!0))})),new te(t+": "+r.map(ee).join([", "]))}function ne(t,e){for(var r=[],n=0;n<t;n++)r.push(O[e+4*n>>2]);return r}function oe(t,e,r,n,o){var i=e.length;i<2&&vt("argTypes array size mismatch! Must at least get return value and 'this' types!");for(var a=null!==e[1]&&null!==r,s=!1,u=1;u<e.length;++u)if(null!==e[u]&&void 0===e[u].destructorFunction){s=!0;break}var c="void"!==e[0].name,f="",l="";for(u=0;u<i-2;++u)f+=(0!==u?", ":"")+"arg"+u,l+=(0!==u?", ":"")+"arg"+u+"Wired";var p="return function "+it(t)+"("+f+") {\nif (arguments.length !== "+(i-2)+") {\nthrowBindingError('function "+t+" called with ' + arguments.length + ' arguments, expected "+(i-2)+" args!');\n}\n";s&&(p+="var destructors = [];\n");var h=s?"destructors":"null",d=["throwBindingError","invoker","fn","runDestructors","retType","classParam"],v=[vt,n,o,tt,e[0],e[1]];for(a&&(p+="var thisWired = classParam.toWireType("+h+", this);\n"),u=0;u<i-2;++u)p+="var arg"+u+"Wired = argType"+u+".toWireType("+h+", arg"+u+"); // "+e[u+2].name+"\n",d.push("argType"+u),v.push(e[u+2]);if(a&&(l="thisWired"+(l.length>0?", ":"")+l),p+=(c?"var rv = ":"")+"invoker(fn"+(l.length>0?", ":"")+l+");\n",s)p+="runDestructors(destructors);\n";else for(u=a?1:2;u<e.length;++u){var y=1===u?"thisWired":"arg"+(u-2)+"Wired";null!==e[u].destructorFunction&&(p+=y+"_dtor("+y+"); // "+e[u].name+"\n",d.push(y+"_dtor"),v.push(e[u].destructorFunction))}return c&&(p+="var ret = retType.fromWireType(rv);\nreturn ret;\n"),p+="}\n",d.push(p),function(t,e){if(!(t instanceof Function))throw new TypeError("new_ called with constructor type "+typeof t+" which is not a function");var r=at(t.name||"unknownFunctionName",(function(){}));r.prototype=t.prototype;var n=new r,o=t.apply(n,e);return o instanceof Object?o:n}(Function,d).apply(null,v)}var ie=[],ae=[{},{value:void 0},{value:null},{value:!0},{value:!1}];function se(t){t>4&&0==--ae[t].refcount&&(ae[t]=void 0,ie.push(t))}function ue(){for(var t=0,e=5;e<ae.length;++e)void 0!==ae[e]&&++t;return t}function ce(){for(var t=5;t<ae.length;++t)if(void 0!==ae[t])return ae[t];return null}var fe={toValue:t=>(t||vt("Cannot use deleted val. handle = "+t),ae[t].value),toHandle:t=>{switch(t){case void 0:return 1;case null:return 2;case!0:return 3;case!1:return 4;default:var e=ie.length?ie.pop():ae.length;return ae[e]={refcount:1,value:t},e}}};function le(t){if(null===t)return"null";var e=typeof t;return"object"===e||"array"===e||"function"===e?t.toString():""+t}function pe(t,e){switch(e){case 2:return function(t){return this.fromWireType(k[t>>2])};case 3:return function(t){return this.fromWireType(S[t>>3])};default:throw new TypeError("Unknown float type: "+t)}}function he(t,e,r){switch(e){case 0:return r?function(t){return C[t]}:function(t){return _[t]};case 1:return r?function(t){return $[t>>1]}:function(t){return A[t>>1]};case 2:return r?function(t){return x[t>>2]}:function(t){return O[t>>2]};default:throw new TypeError("Unknown integer type: "+t)}}var de="undefined"!=typeof TextDecoder?new TextDecoder("utf-16le"):void 0;function ve(t,e){for(var r=t,n=r>>1,o=n+e/2;!(n>=o)&&A[n];)++n;if((r=n<<1)-t>32&&de)return de.decode(_.subarray(t,r));for(var i="",a=0;!(a>=e/2);++a){var s=$[t+2*a>>1];if(0==s)break;i+=String.fromCharCode(s)}return i}function ye(t,e,r){if(void 0===r&&(r=2147483647),r<2)return 0;for(var n=e,o=(r-=2)<2*t.length?r/2:t.length,i=0;i<o;++i){var a=t.charCodeAt(i);$[e>>1]=a,e+=2}return $[e>>1]=0,e-n}function ge(t){return 2*t.length}function me(t,e){for(var r=0,n="";!(r>=e/4);){var o=x[t+4*r>>2];if(0==o)break;if(++r,o>=65536){var i=o-65536;n+=String.fromCharCode(55296|i>>10,56320|1023&i)}else n+=String.fromCharCode(o)}return n}function we(t,e,r){if(void 0===r&&(r=2147483647),r<4)return 0;for(var n=e,o=n+r-4,i=0;i<t.length;++i){var a=t.charCodeAt(i);if(a>=55296&&a<=57343&&(a=65536+((1023&a)<<10)|1023&t.charCodeAt(++i)),x[e>>2]=a,(e+=4)+4>o)break}return x[e>>2]=0,e-n}function be(t){for(var e=0,r=0;r<t.length;++r){var n=t.charCodeAt(r);n>=55296&&n<=57343&&++r,e+=4}return e}var Pe={};function Te(){return"object"==typeof globalThis?globalThis:Function("return this")()}function Ce(t,e){var r=nt[t];return void 0===r&&vt(e+" has unknown type "+ee(t)),r}var _e={};function $e(t){try{return P.grow(t-T.byteLength+65535>>>16),W(P.buffer),1}catch(t){}}var Ae={};function xe(){if(!xe.strings){var t={USER:"web_user",LOGNAME:"web_user",PATH:"/",PWD:"/",HOME:"/home/web_user",LANG:("object"==typeof navigator&&navigator.languages&&navigator.languages[0]||"C").replace("-","_")+".UTF-8",_:l||"./this.program"};for(var e in Ae)void 0===Ae[e]?delete t[e]:t[e]=Ae[e];var r=[];for(var e in t)r.push(e+"="+t[e]);xe.strings=r}return xe.strings}var Oe=[null,[],[]];function ke(t,e){var r=Oe[t];0===e||10===e?((1===t?w:b)(R(r,0)),r.length=0):r.push(e)}ut=i.InternalError=st(Error,"InternalError"),function(){for(var t=new Array(256),e=0;e<256;++e)t[e]=String.fromCharCode(e);pt=t}(),dt=i.BindingError=st(Error,"BindingError"),Lt.prototype.isAliasOf=gt,Lt.prototype.clone=Ft,Lt.prototype.delete=Wt,Lt.prototype.isDeleted=It,Lt.prototype.deleteLater=Ut,i.getInheritedInstanceCount=_t,i.getLiveInheritedInstances=$t,i.flushPendingDeletes=xt,i.setDelayFunction=kt,Xt.prototype.getPointee=Gt,Xt.prototype.destructor=qt,Xt.prototype.argPackAdvance=8,Xt.prototype.readValueFromPointer=et,Xt.prototype.deleteObject=Jt,Xt.prototype.fromWireType=Rt,te=i.UnboundTypeError=st(Error,"UnboundTypeError"),i.count_emval_handles=ue,i.get_first_emval=ce;var Se,je={D:function(t,e,r){throw new Z(t).init(e,r),t},e:function(t){var e=Q[t];delete Q[t];var r=e.rawConstructor,n=e.rawDestructor,o=e.fields;ft([t],o.map((t=>t.getterReturnType)).concat(o.map((t=>t.setterArgumentType))),(t=>{var i={};return o.forEach(((e,r)=>{var n=e.fieldName,a=t[r],s=e.getter,u=e.getterContext,c=t[r+o.length],f=e.setter,l=e.setterContext;i[n]={read:t=>a.fromWireType(s(u,t)),write:(t,e)=>{var r=[];f(l,t,c.toWireType(r,e)),tt(r)}}})),[{name:e.name,fromWireType:function(t){var e={};for(var r in i)e[r]=i[r].read(t);return n(t),e},toWireType:function(t,e){for(var o in i)if(!(o in e))throw new TypeError('Missing field: "'+o+'"');var a=r();for(o in i)i[o].write(a,e[o]);return null!==t&&t.push(n,a),a},argPackAdvance:8,readValueFromPointer:et,destructorFunction:n}]}))},t:function(t,e,r,n,o){},B:function(t,e,r,n,o){var i=lt(r);yt(t,{name:e=ht(e),fromWireType:function(t){return!!t},toWireType:function(t,e){return e?n:o},argPackAdvance:8,readValueFromPointer:function(t){var n;if(1===r)n=C;else if(2===r)n=$;else{if(4!==r)throw new TypeError("Unknown boolean type size: "+e);n=x}return this.fromWireType(n[t>>i])},destructorFunction:null})},r:function(t,e,r,n,o,a,s,u,c,f,l,p,h){l=ht(l),a=Qt(o,a),u&&(u=Qt(s,u)),f&&(f=Qt(c,f)),h=Qt(p,h);var d=it(l);!function(t,e,r){i.hasOwnProperty(t)?((void 0===r||void 0!==i[t].overloadTable&&void 0!==i[t].overloadTable[r])&&vt("Cannot register public name '"+t+"' twice"),Ht(i,t,t),i.hasOwnProperty(r)&&vt("Cannot register multiple overloads of a function with the same number of arguments ("+r+")!"),i[t].overloadTable[r]=e):(i[t]=e,void 0!==r&&(i[t].numArguments=r))}(d,(function(){re("Cannot construct "+l+" due to unbound types",[n])})),ft([t,e,r],n?[n]:[],(function(e){var r,o;e=e[0],o=n?(r=e.registeredClass).instancePrototype:Lt.prototype;var s=at(d,(function(){if(Object.getPrototypeOf(this)!==c)throw new dt("Use 'new' to construct "+l);if(void 0===p.constructor_body)throw new dt(l+" has no accessible constructor");var t=p.constructor_body[arguments.length];if(void 0===t)throw new dt("Tried to invoke ctor of "+l+" with invalid number of parameters ("+arguments.length+") - expected ("+Object.keys(p.constructor_body).toString()+") parameters instead!");return t.apply(this,arguments)})),c=Object.create(o,{constructor:{value:s}});s.prototype=c;var p=new Bt(l,s,c,h,r,a,u,f),v=new Xt(l,p,!0,!1,!1),y=new Xt(l+"*",p,!1,!1,!1),g=new Xt(l+" const*",p,!1,!0,!1);return Ct[t]={pointerType:y,constPointerType:g},function(t,e,r){i.hasOwnProperty(t)||ct("Replacing nonexistant public symbol"),void 0!==i[t].overloadTable&&void 0!==r?i[t].overloadTable[r]=e:(i[t]=e,i[t].argCount=r)}(d,s),[v,y,g]}))},q:function(t,e,r,n,o,i){var a;e>0||G(a);var s=ne(e,r);o=Qt(n,o),ft([],[t],(function(t){var r="constructor "+(t=t[0]).name;if(void 0===t.registeredClass.constructor_body&&(t.registeredClass.constructor_body=[]),void 0!==t.registeredClass.constructor_body[e-1])throw new dt("Cannot register multiple constructors with identical number of parameters ("+(e-1)+") for class '"+t.name+"'! Overload resolution is currently only performed using the parameter count, not actual type info!");return t.registeredClass.constructor_body[e-1]=()=>{re("Cannot construct "+t.name+" due to unbound types",s)},ft([],s,(function(n){return n.splice(1,0,null),t.registeredClass.constructor_body[e-1]=oe(r,n,null,o,i),[]})),[]}))},b:function(t,e,r,n,o,i,a,s){var u=ne(r,n);e=ht(e),i=Qt(o,i),ft([],[t],(function(t){var n=(t=t[0]).name+"."+e;function o(){re("Cannot call "+n+" due to unbound types",u)}e.startsWith("@@")&&(e=Symbol[e.substring(2)]),s&&t.registeredClass.pureVirtualFunctions.push(e);var c=t.registeredClass.instancePrototype,f=c[e];return void 0===f||void 0===f.overloadTable&&f.className!==t.name&&f.argCount===r-2?(o.argCount=r-2,o.className=t.name,c[e]=o):(Ht(c,e,n),c[e].overloadTable[r-2]=o),ft([],u,(function(o){var s=oe(n,o,t,i,a);return void 0===c[e].overloadTable?(s.argCount=r-2,c[e]=s):c[e].overloadTable[r-2]=s,[]})),[]}))},A:function(t,e){yt(t,{name:e=ht(e),fromWireType:function(t){var e=fe.toValue(t);return se(t),e},toWireType:function(t,e){return fe.toHandle(e)},argPackAdvance:8,readValueFromPointer:et,destructorFunction:null})},l:function(t,e,r){var n=lt(r);yt(t,{name:e=ht(e),fromWireType:function(t){return t},toWireType:function(t,e){return e},argPackAdvance:8,readValueFromPointer:pe(e,n),destructorFunction:null})},d:function(t,e,r,n,o){e=ht(e),-1===o&&(o=4294967295);var i=lt(r),a=t=>t;if(0===n){var s=32-8*r;a=t=>t<<s>>>s}var u=e.includes("unsigned");yt(t,{name:e,fromWireType:a,toWireType:u?function(t,e){return this.name,e>>>0}:function(t,e){return this.name,e},argPackAdvance:8,readValueFromPointer:he(e,i,0!==n),destructorFunction:null})},a:function(t,e,r){var n=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array][e];function o(t){var e=O,r=e[t>>=2],o=e[t+1];return new n(T,o,r)}yt(t,{name:r=ht(r),fromWireType:o,argPackAdvance:8,readValueFromPointer:o},{ignoreDuplicateRegistrations:!0})},k:function(t,e){var r="std::string"===(e=ht(e));yt(t,{name:e,fromWireType:function(t){var e,n=O[t>>2],o=t+4;if(r)for(var i=o,a=0;a<=n;++a){var s=o+a;if(a==n||0==_[s]){var u=D(i,s-i);void 0===e?e=u:(e+=String.fromCharCode(0),e+=u),i=s+1}}else{var c=new Array(n);for(a=0;a<n;++a)c[a]=String.fromCharCode(_[o+a]);e=c.join("")}return Re(t),e},toWireType:function(t,e){var n;e instanceof ArrayBuffer&&(e=new Uint8Array(e));var o="string"==typeof e;o||e instanceof Uint8Array||e instanceof Uint8ClampedArray||e instanceof Int8Array||vt("Cannot pass non-string to std::string"),n=r&&o?function(t){for(var e=0,r=0;r<t.length;++r){var n=t.charCodeAt(r);n<=127?e++:n<=2047?e+=2:n>=55296&&n<=57343?(e+=4,++r):e+=3}return e}(e):e.length;var i=Ee(4+n+1),a=i+4;if(O[i>>2]=n,r&&o)F(e,a,n+1);else if(o)for(var s=0;s<n;++s){var u=e.charCodeAt(s);u>255&&(Re(a),vt("String has UTF-16 code units that do not fit in 8 bits")),_[a+s]=u}else for(s=0;s<n;++s)_[a+s]=e[s];return null!==t&&t.push(Re,i),i},argPackAdvance:8,readValueFromPointer:et,destructorFunction:function(t){Re(t)}})},f:function(t,e,r){var n,o,i,a,s;r=ht(r),2===e?(n=ve,o=ye,a=ge,i=()=>A,s=1):4===e&&(n=me,o=we,a=be,i=()=>O,s=2),yt(t,{name:r,fromWireType:function(t){for(var r,o=O[t>>2],a=i(),u=t+4,c=0;c<=o;++c){var f=t+4+c*e;if(c==o||0==a[f>>s]){var l=n(u,f-u);void 0===r?r=l:(r+=String.fromCharCode(0),r+=l),u=f+e}}return Re(t),r},toWireType:function(t,n){"string"!=typeof n&&vt("Cannot pass non-string to C++ string type "+r);var i=a(n),u=Ee(4+i+e);return O[u>>2]=i>>s,o(n,u+4,i+e),null!==t&&t.push(Re,u),u},argPackAdvance:8,readValueFromPointer:et,destructorFunction:function(t){Re(t)}})},g:function(t,e,r,n,o,i){Q[t]={name:ht(e),rawConstructor:Qt(r,n),rawDestructor:Qt(o,i),fields:[]}},c:function(t,e,r,n,o,i,a,s,u,c){Q[t].fields.push({fieldName:ht(e),getterReturnType:r,getter:Qt(n,o),getterContext:i,setterArgumentType:a,setter:Qt(s,u),setterContext:c})},C:function(t,e){yt(t,{isVoid:!0,name:e=ht(e),argPackAdvance:0,fromWireType:function(){},toWireType:function(t,e){}})},h:se,o:function(t){return 0===t?fe.toHandle(Te()):(t=void 0===(r=Pe[e=t])?ht(e):r,fe.toHandle(Te()[t]));var e,r},m:function(t){t>4&&(ae[t].refcount+=1)},n:function(t,e,r,n){t=fe.toValue(t);var o=_e[e];return o||(o=function(t){for(var e="",r=0;r<t;++r)e+=(0!==r?", ":"")+"arg"+r;var n="return function emval_allocator_"+t+"(constructor, argTypes, args) {\n var HEAPU32 = getMemory();\n";for(r=0;r<t;++r)n+="var argType"+r+" = requireRegisteredType(HEAPU32[((argTypes)>>2)], 'parameter "+r+"');\nvar arg"+r+" = argType"+r+".readValueFromPointer(args);\nargs += argType"+r+"['argPackAdvance'];\nargTypes += 4;\n";return n+="var obj = new constructor("+e+");\nreturn valueToHandle(obj);\n}\n",new Function("requireRegisteredType","Module","valueToHandle","getMemory",n)(Ce,i,fe.toHandle,(()=>O))}(e),_e[e]=o),o(t,r,n)},p:function(t,e){var r=(t=Ce(t,"_emval_take_value")).readValueFromPointer(e);return fe.toHandle(r)},i:function(){G("")},v:function(){return 2147483648},z:function(t,e,r){_.copyWithin(t,e,e+r)},u:function(t){var e,r,n=_.length,o=2147483648;if((t>>>=0)>o)return!1;for(var i=1;i<=4;i*=2){var a=n*(1+.2/i);if(a=Math.min(a,t+100663296),$e(Math.min(o,(e=Math.max(t,a))+((r=65536)-e%r)%r)))return!0}return!1},w:function(t,e){var r=0;return xe().forEach((function(n,o){var i=e+r;O[t+4*o>>2]=i,function(t,e,r){for(var n=0;n<t.length;++n)C[e++>>0]=t.charCodeAt(n);r||(C[e>>0]=0)}(n,i),r+=n.length+1})),0},x:function(t,e){var r=xe();O[t>>2]=r.length;var n=0;return r.forEach((function(t){n+=t.length+1})),O[e>>2]=n,0},y:function(t){return 52},s:function(t,e,r,n,o){return 70},j:function(t,e,r,n){for(var o=0,i=0;i<r;i++){var a=O[e>>2],s=O[e+4>>2];e+=8;for(var u=0;u<s;u++)ke(t,_[a+u]);o+=s}return O[n>>2]=o,0}},Ee=(function(){var t={a:je};function e(t,e){var r,n=t.exports;i.asm=n,W((P=i.asm.E).buffer),I=i.asm.G,r=i.asm.F,B.unshift(r),function(t){if(V--,i.monitorRunDependencies&&i.monitorRunDependencies(V),0==V&&(null!==z&&(clearInterval(z),z=null),N)){var e=N;N=null,e()}}()}function r(t){e(t.instance)}function n(e){return function(){if(!m&&(p||h)){if("function"==typeof fetch&&!J(U))return fetch(U,{credentials:"same-origin"}).then((function(t){if(!t.ok)throw"failed to load wasm binary file at '"+U+"'";return t.arrayBuffer()})).catch((function(){return X(U)}));if(s)return new Promise((function(t,e){s(U,(function(e){t(new Uint8Array(e))}),e)}))}return Promise.resolve().then((function(){return X(U)}))}().then((function(e){return WebAssembly.instantiate(e,t)})).then((function(t){return t})).then(e,(function(t){b("failed to asynchronously prepare wasm: "+t),G(t)}))}if(V++,i.monitorRunDependencies&&i.monitorRunDependencies(V),i.instantiateWasm)try{return i.instantiateWasm(t,e)}catch(t){b("Module.instantiateWasm callback failed with error: "+t),o(t)}(m||"function"!=typeof WebAssembly.instantiateStreaming||q(U)||J(U)||d||"function"!=typeof fetch?n(r):fetch(U,{credentials:"same-origin"}).then((function(e){return WebAssembly.instantiateStreaming(e,t).then(r,(function(t){return b("wasm streaming compile failed: "+t),b("falling back to ArrayBuffer instantiation"),n(r)}))}))).catch(o)}(),i.___wasm_call_ctors=function(){return(i.___wasm_call_ctors=i.asm.F).apply(null,arguments)},i._malloc=function(){return(Ee=i._malloc=i.asm.H).apply(null,arguments)}),Re=i._free=function(){return(Re=i._free=i.asm.I).apply(null,arguments)},De=i.___getTypeName=function(){return(De=i.___getTypeName=i.asm.J).apply(null,arguments)},Fe=(i.__embind_initialize_bindings=function(){return(i.__embind_initialize_bindings=i.asm.K).apply(null,arguments)},i.stackSave=function(){return(Fe=i.stackSave=i.asm.L).apply(null,arguments)}),We=i.stackRestore=function(){return(We=i.stackRestore=i.asm.M).apply(null,arguments)},Ie=i.stackAlloc=function(){return(Ie=i.stackAlloc=i.asm.N).apply(null,arguments)},Ue=i.___cxa_is_pointer_type=function(){return(Ue=i.___cxa_is_pointer_type=i.asm.O).apply(null,arguments)};function Le(t){function r(){Se||(Se=!0,i.calledRun=!0,j||(K(B),e(i),i.onRuntimeInitialized&&i.onRuntimeInitialized(),function(){if(i.postRun)for("function"==typeof i.postRun&&(i.postRun=[i.postRun]);i.postRun.length;)t=i.postRun.shift(),M.unshift(t);var t;K(M)}()))}t=t||f,V>0||(function(){if(i.preRun)for("function"==typeof i.preRun&&(i.preRun=[i.preRun]);i.preRun.length;)t=i.preRun.shift(),H.unshift(t);var t;K(H)}(),V>0||(i.setStatus?(i.setStatus("Running..."),setTimeout((function(){setTimeout((function(){i.setStatus("")}),1),r()}),1)):r()))}if(i.dynCall_iji=function(){return(i.dynCall_iji=i.asm.P).apply(null,arguments)},i.dynCall_jji=function(){return(i.dynCall_jji=i.asm.Q).apply(null,arguments)},i.dynCall_iiji=function(){return(i.dynCall_iiji=i.asm.R).apply(null,arguments)},i.dynCall_jiji=function(){return(i.dynCall_jiji=i.asm.S).apply(null,arguments)},i.ccall=function(t,e,r,n,o){var a={string:t=>{var e=0;if(null!=t&&0!==t){var r=1+(t.length<<2);F(t,e=Ie(r),r)}return e},array:t=>{var e=Ie(t.length);return function(t,e){C.set(t,e)}(t,e),e}},s=function(t){return i["_"+t]}(t),u=[],c=0;if(n)for(var f=0;f<n.length;f++){var l=a[r[f]];l?(0===c&&(c=Fe()),u[f]=l(n[f])):u[f]=n[f]}var p=s.apply(null,u);return p=function(t){return 0!==c&&We(c),function(t){return"string"===e?D(t):"boolean"===e?Boolean(t):t}(t)}(p)},N=function t(){Se||Le(),Se||(N=t)},i.preInit)for("function"==typeof i.preInit&&(i.preInit=[i.preInit]);i.preInit.length>0;)i.preInit.pop()();return Le(),t.ready});t.exports=o},430:(t,e,r)=>{var n,o=(n=(n="undefined"!=typeof document&&document.currentScript?document.currentScript.src:void 0)||"/index.js",function(t){var e,o;(t=void 0!==(t=t||{})?t:{}).ready=new Promise((function(t,r){e=t,o=r}));var i,a,s,u=Object.assign({},t),c=[],f="object"==typeof window,l="function"==typeof importScripts,p="object"==typeof process&&"object"==typeof process.versions&&"string"==typeof process.versions.node,h="";if(p){var d=r(280),v=r(103);h=l?v.dirname(h)+"/":"//",i=(t,e)=>(t=G(t)?new URL(t):v.normalize(t),d.readFileSync(t,e?void 0:"utf8")),s=t=>{var e=i(t,!0);return e.buffer||(e=new Uint8Array(e)),e},a=(t,e,r)=>{t=G(t)?new URL(t):v.normalize(t),d.readFile(t,(function(t,n){t?r(t):e(n.buffer)}))},process.argv.length>1&&process.argv[1].replace(/\\/g,"/"),c=process.argv.slice(2),process.on("uncaughtException",(function(t){if(!(t instanceof J))throw t})),process.on("unhandledRejection",(function(t){throw t})),t.inspect=function(){return"[Emscripten Module object]"}}else(f||l)&&(l?h=self.location.href:"undefined"!=typeof document&&document.currentScript&&(h=document.currentScript.src),n&&(h=n),h=0!==h.indexOf("blob:")?h.substr(0,h.replace(/[?#].*/,"").lastIndexOf("/")+1):"",i=t=>{var e=new XMLHttpRequest;return e.open("GET",t,!1),e.send(null),e.responseText},l&&(s=t=>{var e=new XMLHttpRequest;return e.open("GET",t,!1),e.responseType="arraybuffer",e.send(null),new Uint8Array(e.response)}),a=(t,e,r)=>{var n=new XMLHttpRequest;n.open("GET",t,!0),n.responseType="arraybuffer",n.onload=()=>{200==n.status||0==n.status&&n.response?e(n.response):r()},n.onerror=r,n.send(null)});var y,g=t.print||console.log.bind(console),m=t.printErr||console.warn.bind(console);Object.assign(t,u),u=null,t.arguments&&(c=t.arguments),t.thisProgram&&t.thisProgram,t.quit&&t.quit,t.wasmBinary&&(y=t.wasmBinary);var w;t.noExitRuntime;"object"!=typeof WebAssembly&&z("no native wasm support detected");var b,P,T,C,_,$,A,x,O,k=!1,S="undefined"!=typeof TextDecoder?new TextDecoder("utf8"):void 0;function j(t,e,r){for(var n=e+r,o=e;t[o]&&!(o>=n);)++o;if(o-e>16&&t.buffer&&S)return S.decode(t.subarray(e,o));for(var i="";e<o;){var a=t[e++];if(128&a){var s=63&t[e++];if(192!=(224&a)){var u=63&t[e++];if((a=224==(240&a)?(15&a)<<12|s<<6|u:(7&a)<<18|s<<12|u<<6|63&t[e++])<65536)i+=String.fromCharCode(a);else{var c=a-65536;i+=String.fromCharCode(55296|c>>10,56320|1023&c)}}else i+=String.fromCharCode((31&a)<<6|s)}else i+=String.fromCharCode(a)}return i}function E(t,e){return t?j(T,t,e):""}function R(t,e,r){return function(t,e,r,n){if(!(n>0))return 0;for(var o=r,i=r+n-1,a=0;a<t.length;++a){var s=t.charCodeAt(a);if(s>=55296&&s<=57343&&(s=65536+((1023&s)<<10)|1023&t.charCodeAt(++a)),s<=127){if(r>=i)break;e[r++]=s}else if(s<=2047){if(r+1>=i)break;e[r++]=192|s>>6,e[r++]=128|63&s}else if(s<=65535){if(r+2>=i)break;e[r++]=224|s>>12,e[r++]=128|s>>6&63,e[r++]=128|63&s}else{if(r+3>=i)break;e[r++]=240|s>>18,e[r++]=128|s>>12&63,e[r++]=128|s>>6&63,e[r++]=128|63&s}}return e[r]=0,r-o}(t,T,e,r)}function D(e){b=e,t.HEAP8=P=new Int8Array(e),t.HEAP16=C=new Int16Array(e),t.HEAP32=$=new Int32Array(e),t.HEAPU8=T=new Uint8Array(e),t.HEAPU16=_=new Uint16Array(e),t.HEAPU32=A=new Uint32Array(e),t.HEAPF32=x=new Float32Array(e),t.HEAPF64=O=new Float64Array(e)}t.INITIAL_MEMORY;var F,W,I,U=[],L=[],H=[],B=0,M=null,V=null;function z(e){t.onAbort&&t.onAbort(e),m(e="Aborted("+e+")"),k=!0,e+=". Build with -sASSERTIONS for more info.";var r=new WebAssembly.RuntimeError(e);throw o(r),r}function N(t){return t.startsWith("data:application/octet-stream;base64,")}function G(t){return t.startsWith("file://")}function q(t){try{if(t==W&&y)return new Uint8Array(y);if(s)return s(t);throw"both async and sync fetching of the wasm failed"}catch(t){z(t)}}function J(t){this.name="ExitStatus",this.message="Program terminated with exit("+t+")",this.status=t}function X(e){for(;e.length>0;)e.shift()(t)}N(W="openjphjs.wasm")||(I=W,W=t.locateFile?t.locateFile(I,h):h+I);var Y=[],K=0,Z=[];function Q(t){var e=Z[t];return e||(t>=Z.length&&(Z.length=t+1),Z[t]=e=F.get(t)),e}function tt(t){this.excPtr=t,this.ptr=t-24,this.set_type=function(t){A[this.ptr+4>>2]=t},this.get_type=function(){return A[this.ptr+4>>2]},this.set_destructor=function(t){A[this.ptr+8>>2]=t},this.get_destructor=function(){return A[this.ptr+8>>2]},this.set_refcount=function(t){$[this.ptr>>2]=t},this.set_caught=function(t){t=t?1:0,P[this.ptr+12>>0]=t},this.get_caught=function(){return 0!=P[this.ptr+12>>0]},this.set_rethrown=function(t){t=t?1:0,P[this.ptr+13>>0]=t},this.get_rethrown=function(){return 0!=P[this.ptr+13>>0]},this.init=function(t,e){this.set_adjusted_ptr(0),this.set_type(t),this.set_destructor(e),this.set_refcount(0),this.set_caught(!1),this.set_rethrown(!1)},this.add_ref=function(){var t=$[this.ptr>>2];$[this.ptr>>2]=t+1},this.release_ref=function(){var t=$[this.ptr>>2];return $[this.ptr>>2]=t-1,1===t},this.set_adjusted_ptr=function(t){A[this.ptr+16>>2]=t},this.get_adjusted_ptr=function(){return A[this.ptr+16>>2]},this.get_exception_ptr=function(){if(Ie(this.get_type()))return A[this.excPtr>>2];var t=this.get_adjusted_ptr();return 0!==t?t:this.excPtr}}var et={};function rt(t){for(;t.length;){var e=t.pop();t.pop()(e)}}function nt(t){return this.fromWireType($[t>>2])}var ot={},it={},at={};function st(t){if(void 0===t)return"_unknown";var e=(t=t.replace(/[^a-zA-Z0-9_]/g,"$")).charCodeAt(0);return e>=48&&e<=57?"_"+t:t}function ut(t,e){return t=st(t),new Function("body","return function "+t+'() {\n "use strict"; return body.apply(this, arguments);\n};\n')(e)}function ct(t,e){var r=ut(e,(function(t){this.name=e,this.message=t;var r=new Error(t).stack;void 0!==r&&(this.stack=this.toString()+"\n"+r.replace(/^Error(:[^\n]*)?\n/,""))}));return r.prototype=Object.create(t.prototype),r.prototype.constructor=r,r.prototype.toString=function(){return void 0===this.message?this.name:this.name+": "+this.message},r}var ft=void 0;function lt(t){throw new ft(t)}function pt(t,e,r){function n(e){var n=r(e);n.length!==t.length&<("Mismatched type converter count");for(var o=0;o<t.length;++o)mt(t[o],n[o])}t.forEach((function(t){at[t]=e}));var o=new Array(e.length),i=[],a=0;e.forEach(((t,e)=>{it.hasOwnProperty(t)?o[e]=it[t]:(i.push(t),ot.hasOwnProperty(t)||(ot[t]=[]),ot[t].push((()=>{o[e]=it[t],++a===i.length&&n(o)})))})),0===i.length&&n(o)}function ht(t){switch(t){case 1:return 0;case 2:return 1;case 4:return 2;case 8:return 3;default:throw new TypeError("Unknown type size: "+t)}}var dt=void 0;function vt(t){for(var e="",r=t;T[r];)e+=dt[T[r++]];return e}var yt=void 0;function gt(t){throw new yt(t)}function mt(t,e,r={}){if(!("argPackAdvance"in e))throw new TypeError("registerType registeredInstance requires argPackAdvance");var n=e.name;if(t||gt('type "'+n+'" must have a positive integer typeid pointer'),it.hasOwnProperty(t)){if(r.ignoreDuplicateRegistrations)return;gt("Cannot register type '"+n+"' twice")}if(it[t]=e,delete at[t],ot.hasOwnProperty(t)){var o=ot[t];delete ot[t],o.forEach((t=>t()))}}function wt(t){if(!(this instanceof Bt))return!1;if(!(t instanceof Bt))return!1;for(var e=this.$$.ptrType.registeredClass,r=this.$$.ptr,n=t.$$.ptrType.registeredClass,o=t.$$.ptr;e.baseClass;)r=e.upcast(r),e=e.baseClass;for(;n.baseClass;)o=n.upcast(o),n=n.baseClass;return e===n&&r===o}function bt(t){gt(t.$$.ptrType.registeredClass.name+" instance already deleted")}var Pt=!1;function Tt(t){}function Ct(t){t.count.value-=1,0===t.count.value&&function(t){t.smartPtr?t.smartPtrType.rawDestructor(t.smartPtr):t.ptrType.registeredClass.rawDestructor(t.ptr)}(t)}function _t(t,e,r){if(e===r)return t;if(void 0===r.baseClass)return null;var n=_t(t,e,r.baseClass);return null===n?null:r.downcast(n)}var $t={};function At(){return Object.keys(Et).length}function xt(){var t=[];for(var e in Et)Et.hasOwnProperty(e)&&t.push(Et[e]);return t}var Ot=[];function kt(){for(;Ot.length;){var t=Ot.pop();t.$$.deleteScheduled=!1,t.delete()}}var St=void 0;function jt(t){St=t,Ot.length&&St&&St(kt)}var Et={};function Rt(t,e){return e=function(t,e){for(void 0===e&>("ptr should not be undefined");t.baseClass;)e=t.upcast(e),t=t.baseClass;return e}(t,e),Et[e]}function Dt(t,e){return e.ptrType&&e.ptr||lt("makeClassHandle requires ptr and ptrType"),!!e.smartPtrType!=!!e.smartPtr&<("Both smartPtrType and smartPtr must be specified"),e.count={value:1},Wt(Object.create(t,{$$:{value:e}}))}function Ft(t){var e=this.getPointee(t);if(!e)return this.destructor(t),null;var r=Rt(this.registeredClass,e);if(void 0!==r){if(0===r.$$.count.value)return r.$$.ptr=e,r.$$.smartPtr=t,r.clone();var n=r.clone();return this.destructor(t),n}function o(){return this.isSmartPointer?Dt(this.registeredClass.instancePrototype,{ptrType:this.pointeeType,ptr:e,smartPtrType:this,smartPtr:t}):Dt(this.registeredClass.instancePrototype,{ptrType:this,ptr:t})}var i,a=this.registeredClass.getActualType(e),s=$t[a];if(!s)return o.call(this);i=this.isConst?s.constPointerType:s.pointerType;var u=_t(e,this.registeredClass,i.registeredClass);return null===u?o.call(this):this.isSmartPointer?Dt(i.registeredClass.instancePrototype,{ptrType:i,ptr:u,smartPtrType:this,smartPtr:t}):Dt(i.registeredClass.instancePrototype,{ptrType:i,ptr:u})}function Wt(t){return"undefined"==typeof FinalizationRegistry?(Wt=t=>t,t):(Pt=new FinalizationRegistry((t=>{Ct(t.$$)})),Wt=t=>{var e=t.$$;if(e.smartPtr){var r={$$:e};Pt.register(t,r,t)}return t},Tt=t=>Pt.unregister(t),Wt(t))}function It(){if(this.$$.ptr||bt(this),this.$$.preservePointerOnDelete)return this.$$.count.value+=1,this;var t,e=Wt(Object.create(Object.getPrototypeOf(this),{$$:{value:(t=this.$$,{count:t.count,deleteScheduled:t.deleteScheduled,preservePointerOnDelete:t.preservePointerOnDelete,ptr:t.ptr,ptrType:t.ptrType,smartPtr:t.smartPtr,smartPtrType:t.smartPtrType})}}));return e.$$.count.value+=1,e.$$.deleteScheduled=!1,e}function Ut(){this.$$.ptr||bt(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&>("Object already scheduled for deletion"),Tt(this),Ct(this.$$),this.$$.preservePointerOnDelete||(this.$$.smartPtr=void 0,this.$$.ptr=void 0)}function Lt(){return!this.$$.ptr}function Ht(){return this.$$.ptr||bt(this),this.$$.deleteScheduled&&!this.$$.preservePointerOnDelete&>("Object already scheduled for deletion"),Ot.push(this),1===Ot.length&&St&&St(kt),this.$$.deleteScheduled=!0,this}function Bt(){}function Mt(t,e,r){if(void 0===t[e].overloadTable){var n=t[e];t[e]=function(){return t[e].overloadTable.hasOwnProperty(arguments.length)||gt("Function '"+r+"' called with an invalid number of arguments ("+arguments.length+") - expects one of ("+t[e].overloadTable+")!"),t[e].overloadTable[arguments.length].apply(this,arguments)},t[e].overloadTable=[],t[e].overloadTable[n.argCount]=n}}function Vt(e,r,n){t.hasOwnProperty(e)?((void 0===n||void 0!==t[e].overloadTable&&void 0!==t[e].overloadTable[n])&>("Cannot register public name '"+e+"' twice"),Mt(t,e,e),t.hasOwnProperty(n)&>("Cannot register multiple overloads of a function with the same number of arguments ("+n+")!"),t[e].overloadTable[n]=r):(t[e]=r,void 0!==n&&(t[e].numArguments=n))}function zt(t,e,r,n,o,i,a,s){this.name=t,this.constructor=e,this.instancePrototype=r,this.rawDestructor=n,this.baseClass=o,this.getActualType=i,this.upcast=a,this.downcast=s,this.pureVirtualFunctions=[]}function Nt(t,e,r){for(;e!==r;)e.upcast||gt("Expected null or instance of "+r.name+", got an instance of "+e.name),t=e.upcast(t),e=e.baseClass;return t}function Gt(t,e){if(null===e)return this.isReference&>("null is not a valid "+this.name),0;e.$$||gt('Cannot pass "'+he(e)+'" as a '+this.name),e.$$.ptr||gt("Cannot pass deleted object as a pointer of type "+this.name);var r=e.$$.ptrType.registeredClass;return Nt(e.$$.ptr,r,this.registeredClass)}function qt(t,e){var r;if(null===e)return this.isReference&>("null is not a valid "+this.name),this.isSmartPointer?(r=this.rawConstructor(),null!==t&&t.push(this.rawDestructor,r),r):0;e.$$||gt('Cannot pass "'+he(e)+'" as a '+this.name),e.$$.ptr||gt("Cannot pass deleted object as a pointer of type "+this.name),!this.isConst&&e.$$.ptrType.isConst&>("Cannot convert argument of type "+(e.$$.smartPtrType?e.$$.smartPtrType.name:e.$$.ptrType.name)+" to parameter type "+this.name);var n=e.$$.ptrType.registeredClass;if(r=Nt(e.$$.ptr,n,this.registeredClass),this.isSmartPointer)switch(void 0===e.$$.smartPtr&>("Passing raw pointer to smart pointer is illegal"),this.sharingPolicy){case 0:e.$$.smartPtrType===this?r=e.$$.smartPtr:gt("Cannot convert argument of type "+(e.$$.smartPtrType?e.$$.smartPtrType.name:e.$$.ptrType.name)+" to parameter type "+this.name);break;case 1:r=e.$$.smartPtr;break;case 2:if(e.$$.smartPtrType===this)r=e.$$.smartPtr;else{var o=e.clone();r=this.rawShare(r,pe.toHandle((function(){o.delete()}))),null!==t&&t.push(this.rawDestructor,r)}break;default:gt("Unsupporting sharing policy")}return r}function Jt(t,e){if(null===e)return this.isReference&>("null is not a valid "+this.name),0;e.$$||gt('Cannot pass "'+he(e)+'" as a '+this.name),e.$$.ptr||gt("Cannot pass deleted object as a pointer of type "+this.name),e.$$.ptrType.isConst&>("Cannot convert argument of type "+e.$$.ptrType.name+" to parameter type "+this.name);var r=e.$$.ptrType.registeredClass;return Nt(e.$$.ptr,r,this.registeredClass)}function Xt(t){return this.rawGetPointee&&(t=this.rawGetPointee(t)),t}function Yt(t){this.rawDestructor&&this.rawDestructor(t)}function Kt(t){null!==t&&t.delete()}function Zt(t,e,r,n,o,i,a,s,u,c,f){this.name=t,this.registeredClass=e,this.isReference=r,this.isConst=n,this.isSmartPointer=o,this.pointeeType=i,this.sharingPolicy=a,this.rawGetPointee=s,this.rawConstructor=u,this.rawShare=c,this.rawDestructor=f,o||void 0!==e.baseClass?this.toWireType=qt:n?(this.toWireType=Gt,this.destructorFunction=null):(this.toWireType=Jt,this.destructorFunction=null)}function Qt(e,r,n){t.hasOwnProperty(e)||lt("Replacing nonexistant public symbol"),void 0!==t[e].overloadTable&&void 0!==n?t[e].overloadTable[n]=r:(t[e]=r,t[e].argCount=n)}function te(e,r,n){return e.includes("j")?function(e,r,n){var o=t["dynCall_"+e];return n&&n.length?o.apply(null,[r].concat(n)):o.call(null,r)}(e,r,n):Q(r).apply(null,n)}function ee(t,e){var r,n,o,i=(t=vt(t)).includes("j")?(r=t,n=e,o=[],function(){return o.length=0,Object.assign(o,arguments),te(r,n,o)}):Q(e);return"function"!=typeof i&>("unknown function pointer with signature "+t+": "+e),i}var re=void 0;function ne(t){var e=je(t),r=vt(e);return Se(e),r}function oe(t,e){var r=[],n={};throw e.forEach((function t(e){n[e]||it[e]||(at[e]?at[e].forEach(t):(r.push(e),n[e]=!0))})),new re(t+": "+r.map(ne).join([", "]))}function ie(t,e){for(var r=[],n=0;n<t;n++)r.push(A[e+4*n>>2]);return r}function ae(t,e,r,n,o){var i=e.length;i<2&>("argTypes array size mismatch! Must at least get return value and 'this' types!");for(var a=null!==e[1]&&null!==r,s=!1,u=1;u<e.length;++u)if(null!==e[u]&&void 0===e[u].destructorFunction){s=!0;break}var c="void"!==e[0].name,f="",l="";for(u=0;u<i-2;++u)f+=(0!==u?", ":"")+"arg"+u,l+=(0!==u?", ":"")+"arg"+u+"Wired";var p="return function "+st(t)+"("+f+") {\nif (arguments.length !== "+(i-2)+") {\nthrowBindingError('function "+t+" called with ' + arguments.length + ' arguments, expected "+(i-2)+" args!');\n}\n";s&&(p+="var destructors = [];\n");var h=s?"destructors":"null",d=["throwBindingError","invoker","fn","runDestructors","retType","classParam"],v=[gt,n,o,rt,e[0],e[1]];for(a&&(p+="var thisWired = classParam.toWireType("+h+", this);\n"),u=0;u<i-2;++u)p+="var arg"+u+"Wired = argType"+u+".toWireType("+h+", arg"+u+"); // "+e[u+2].name+"\n",d.push("argType"+u),v.push(e[u+2]);if(a&&(l="thisWired"+(l.length>0?", ":"")+l),p+=(c?"var rv = ":"")+"invoker(fn"+(l.length>0?", ":"")+l+");\n",s)p+="runDestructors(destructors);\n";else for(u=a?1:2;u<e.length;++u){var y=1===u?"thisWired":"arg"+(u-2)+"Wired";null!==e[u].destructorFunction&&(p+=y+"_dtor("+y+"); // "+e[u].name+"\n",d.push(y+"_dtor"),v.push(e[u].destructorFunction))}return c&&(p+="var ret = retType.fromWireType(rv);\nreturn ret;\n"),p+="}\n",d.push(p),function(t,e){if(!(t instanceof Function))throw new TypeError("new_ called with constructor type "+typeof t+" which is not a function");var r=ut(t.name||"unknownFunctionName",(function(){}));r.prototype=t.prototype;var n=new r,o=t.apply(n,e);return o instanceof Object?o:n}(Function,d).apply(null,v)}var se=[],ue=[{},{value:void 0},{value:null},{value:!0},{value:!1}];function ce(t){t>4&&0==--ue[t].refcount&&(ue[t]=void 0,se.push(t))}function fe(){for(var t=0,e=5;e<ue.length;++e)void 0!==ue[e]&&++t;return t}function le(){for(var t=5;t<ue.length;++t)if(void 0!==ue[t])return ue[t];return null}var pe={toValue:t=>(t||gt("Cannot use deleted val. handle = "+t),ue[t].value),toHandle:t=>{switch(t){case void 0:return 1;case null:return 2;case!0:return 3;case!1:return 4;default:var e=se.length?se.pop():ue.length;return ue[e]={refcount:1,value:t},e}}};function he(t){if(null===t)return"null";var e=typeof t;return"object"===e||"array"===e||"function"===e?t.toString():""+t}function de(t,e){switch(e){case 2:return function(t){return this.fromWireType(x[t>>2])};case 3:return function(t){return this.fromWireType(O[t>>3])};default:throw new TypeError("Unknown float type: "+t)}}function ve(t,e,r){switch(e){case 0:return r?function(t){return P[t]}:function(t){return T[t]};case 1:return r?function(t){return C[t>>1]}:function(t){return _[t>>1]};case 2:return r?function(t){return $[t>>2]}:function(t){return A[t>>2]};default:throw new TypeError("Unknown integer type: "+t)}}var ye="undefined"!=typeof TextDecoder?new TextDecoder("utf-16le"):void 0;function ge(t,e){for(var r=t,n=r>>1,o=n+e/2;!(n>=o)&&_[n];)++n;if((r=n<<1)-t>32&&ye)return ye.decode(T.subarray(t,r));for(var i="",a=0;!(a>=e/2);++a){var s=C[t+2*a>>1];if(0==s)break;i+=String.fromCharCode(s)}return i}function me(t,e,r){if(void 0===r&&(r=2147483647),r<2)return 0;for(var n=e,o=(r-=2)<2*t.length?r/2:t.length,i=0;i<o;++i){var a=t.charCodeAt(i);C[e>>1]=a,e+=2}return C[e>>1]=0,e-n}function we(t){return 2*t.length}function be(t,e){for(var r=0,n="";!(r>=e/4);){var o=$[t+4*r>>2];if(0==o)break;if(++r,o>=65536){var i=o-65536;n+=String.fromCharCode(55296|i>>10,56320|1023&i)}else n+=String.fromCharCode(o)}return n}function Pe(t,e,r){if(void 0===r&&(r=2147483647),r<4)return 0;for(var n=e,o=n+r-4,i=0;i<t.length;++i){var a=t.charCodeAt(i);if(a>=55296&&a<=57343&&(a=65536+((1023&a)<<10)|1023&t.charCodeAt(++i)),$[e>>2]=a,(e+=4)+4>o)break}return $[e>>2]=0,e-n}function Te(t){for(var e=0,r=0;r<t.length;++r){var n=t.charCodeAt(r);n>=55296&&n<=57343&&++r,e+=4}return e}function Ce(t){try{return w.grow(t-b.byteLength+65535>>>16),D(w.buffer),1}catch(t){}}var _e=[null,[],[]];function $e(t,e){var r=_e[t];0===e||10===e?((1===t?g:m)(j(r,0)),r.length=0):r.push(e)}ft=t.InternalError=ct(Error,"InternalError"),function(){for(var t=new Array(256),e=0;e<256;++e)t[e]=String.fromCharCode(e);dt=t}(),yt=t.BindingError=ct(Error,"BindingError"),Bt.prototype.isAliasOf=wt,Bt.prototype.clone=It,Bt.prototype.delete=Ut,Bt.prototype.isDeleted=Lt,Bt.prototype.deleteLater=Ht,t.getInheritedInstanceCount=At,t.getLiveInheritedInstances=xt,t.flushPendingDeletes=kt,t.setDelayFunction=jt,Zt.prototype.getPointee=Xt,Zt.prototype.destructor=Yt,Zt.prototype.argPackAdvance=8,Zt.prototype.readValueFromPointer=nt,Zt.prototype.deleteObject=Kt,Zt.prototype.fromWireType=Ft,re=t.UnboundTypeError=ct(Error,"UnboundTypeError"),t.count_emval_handles=fe,t.get_first_emval=le;var Ae,xe={M:function(t){var e=new tt(t);return e.get_caught()||e.set_caught(!0),e.set_rethrown(!1),Y.push(e),function(t){t.add_ref()}(e),e.get_exception_ptr()},v:function(){_setThrew(0),function(t){if(t.release_ref()&&!t.get_rethrown()){var e=t.get_destructor();e&&Q(e)(t.excPtr),ke(t.excPtr)}}(Y.pop()),K=0},c:function(){var t=K;if(!t)return Ee(0),0;var e=new tt(t);e.set_adjusted_ptr(t);var r=e.get_type();if(!r)return Ee(0),t;for(var n=0;n<arguments.length;n++){var o=arguments[n];if(0===o||o===r)break;var i=e.ptr+16;if(We(o,r,i))return Ee(o),t}return Ee(r),t},j:function(){var t=K;if(!t)return Ee(0),0;var e=new tt(t);e.set_adjusted_ptr(t);var r=e.get_type();if(!r)return Ee(0),t;for(var n=0;n<arguments.length;n++){var o=arguments[n];if(0===o||o===r)break;var i=e.ptr+16;if(We(o,r,i))return Ee(o),t}return Ee(r),t},i:function(t,e,r){throw new tt(t).init(e,r),K=t,t},f:function(t){throw K||(K=t),t},B:function(t){var e=et[t];delete et[t];var r=e.rawConstructor,n=e.rawDestructor,o=e.fields;pt([t],o.map((t=>t.getterReturnType)).concat(o.map((t=>t.setterArgumentType))),(t=>{var i={};return o.forEach(((e,r)=>{var n=e.fieldName,a=t[r],s=e.getter,u=e.getterContext,c=t[r+o.length],f=e.setter,l=e.setterContext;i[n]={read:t=>a.fromWireType(s(u,t)),write:(t,e)=>{var r=[];f(l,t,c.toWireType(r,e)),rt(r)}}})),[{name:e.name,fromWireType:function(t){var e={};for(var r in i)e[r]=i[r].read(t);return n(t),e},toWireType:function(t,e){for(var o in i)if(!(o in e))throw new TypeError('Missing field: "'+o+'"');var a=r();for(o in i)i[o].write(a,e[o]);return null!==t&&t.push(n,a),a},argPackAdvance:8,readValueFromPointer:nt,destructorFunction:n}]}))},E:function(t,e,r,n,o){},J:function(t,e,r,n,o){var i=ht(r);mt(t,{name:e=vt(e),fromWireType:function(t){return!!t},toWireType:function(t,e){return e?n:o},argPackAdvance:8,readValueFromPointer:function(t){var n;if(1===r)n=P;else if(2===r)n=C;else{if(4!==r)throw new TypeError("Unknown boolean type size: "+e);n=$}return this.fromWireType(n[t>>i])},destructorFunction:null})},z:function(t,e,r,n,o,i,a,s,u,c,f,l,p){f=vt(f),i=ee(o,i),s&&(s=ee(a,s)),c&&(c=ee(u,c)),p=ee(l,p);var h=st(f);Vt(h,(function(){oe("Cannot construct "+f+" due to unbound types",[n])})),pt([t,e,r],n?[n]:[],(function(e){var r,o;e=e[0],o=n?(r=e.registeredClass).instancePrototype:Bt.prototype;var a=ut(h,(function(){if(Object.getPrototypeOf(this)!==u)throw new yt("Use 'new' to construct "+f);if(void 0===l.constructor_body)throw new yt(f+" has no accessible constructor");var t=l.constructor_body[arguments.length];if(void 0===t)throw new yt("Tried to invoke ctor of "+f+" with invalid number of parameters ("+arguments.length+") - expected ("+Object.keys(l.constructor_body).toString()+") parameters instead!");return t.apply(this,arguments)})),u=Object.create(o,{constructor:{value:a}});a.prototype=u;var l=new zt(f,a,u,p,r,i,s,c),d=new Zt(f,l,!0,!1,!1),v=new Zt(f+"*",l,!1,!1,!1),y=new Zt(f+" const*",l,!1,!0,!1);return $t[t]={pointerType:v,constPointerType:y},Qt(h,a),[d,v,y]}))},y:function(t,e,r,n,o,i){var a;e>0||z(a);var s=ie(e,r);o=ee(n,o),pt([],[t],(function(t){var r="constructor "+(t=t[0]).name;if(void 0===t.registeredClass.constructor_body&&(t.registeredClass.constructor_body=[]),void 0!==t.registeredClass.constructor_body[e-1])throw new yt("Cannot register multiple constructors with identical number of parameters ("+(e-1)+") for class '"+t.name+"'! Overload resolution is currently only performed using the parameter count, not actual type info!");return t.registeredClass.constructor_body[e-1]=()=>{oe("Cannot construct "+t.name+" due to unbound types",s)},pt([],s,(function(n){return n.splice(1,0,null),t.registeredClass.constructor_body[e-1]=ae(r,n,null,o,i),[]})),[]}))},a:function(t,e,r,n,o,i,a,s){var u=ie(r,n);e=vt(e),i=ee(o,i),pt([],[t],(function(t){var n=(t=t[0]).name+"."+e;function o(){oe("Cannot call "+n+" due to unbound types",u)}e.startsWith("@@")&&(e=Symbol[e.substring(2)]),s&&t.registeredClass.pureVirtualFunctions.push(e);var c=t.registeredClass.instancePrototype,f=c[e];return void 0===f||void 0===f.overloadTable&&f.className!==t.name&&f.argCount===r-2?(o.argCount=r-2,o.className=t.name,c[e]=o):(Mt(c,e,n),c[e].overloadTable[r-2]=o),pt([],u,(function(o){var s=ae(n,o,t,i,a);return void 0===c[e].overloadTable?(s.argCount=r-2,c[e]=s):c[e].overloadTable[r-2]=s,[]})),[]}))},I:function(t,e){mt(t,{name:e=vt(e),fromWireType:function(t){var e=pe.toValue(t);return ce(t),e},toWireType:function(t,e){return pe.toHandle(e)},argPackAdvance:8,readValueFromPointer:nt,destructorFunction:null})},u:function(t,e,r){var n=ht(r);mt(t,{name:e=vt(e),fromWireType:function(t){return t},toWireType:function(t,e){return e},argPackAdvance:8,readValueFromPointer:de(e,n),destructorFunction:null})},o:function(t,e,r,n,o,i){var a=ie(e,r);t=vt(t),o=ee(n,o),Vt(t,(function(){oe("Cannot call "+t+" due to unbound types",a)}),e-1),pt([],a,(function(r){var n=[r[0],null].concat(r.slice(1));return Qt(t,ae(t,n,null,o,i),e-1),[]}))},h:function(t,e,r,n,o){e=vt(e),-1===o&&(o=4294967295);var i=ht(r),a=t=>t;if(0===n){var s=32-8*r;a=t=>t<<s>>>s}var u=e.includes("unsigned");mt(t,{name:e,fromWireType:a,toWireType:u?function(t,e){return this.name,e>>>0}:function(t,e){return this.name,e},argPackAdvance:8,readValueFromPointer:ve(e,i,0!==n),destructorFunction:null})},d:function(t,e,r){var n=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array][e];function o(t){var e=A,r=e[t>>=2],o=e[t+1];return new n(b,o,r)}mt(t,{name:r=vt(r),fromWireType:o,argPackAdvance:8,readValueFromPointer:o},{ignoreDuplicateRegistrations:!0})},t:function(t,e){var r="std::string"===(e=vt(e));mt(t,{name:e,fromWireType:function(t){var e,n=A[t>>2],o=t+4;if(r)for(var i=o,a=0;a<=n;++a){var s=o+a;if(a==n||0==T[s]){var u=E(i,s-i);void 0===e?e=u:(e+=String.fromCharCode(0),e+=u),i=s+1}}else{var c=new Array(n);for(a=0;a<n;++a)c[a]=String.fromCharCode(T[o+a]);e=c.join("")}return Se(t),e},toWireType:function(t,e){var n;e instanceof ArrayBuffer&&(e=new Uint8Array(e));var o="string"==typeof e;o||e instanceof Uint8Array||e instanceof Uint8ClampedArray||e instanceof Int8Array||gt("Cannot pass non-string to std::string"),n=r&&o?function(t){for(var e=0,r=0;r<t.length;++r){var n=t.charCodeAt(r);n<=127?e++:n<=2047?e+=2:n>=55296&&n<=57343?(e+=4,++r):e+=3}return e}(e):e.length;var i=Oe(4+n+1),a=i+4;if(A[i>>2]=n,r&&o)R(e,a,n+1);else if(o)for(var s=0;s<n;++s){var u=e.charCodeAt(s);u>255&&(Se(a),gt("String has UTF-16 code units that do not fit in 8 bits")),T[a+s]=u}else for(s=0;s<n;++s)T[a+s]=e[s];return null!==t&&t.push(Se,i),i},argPackAdvance:8,readValueFromPointer:nt,destructorFunction:function(t){Se(t)}})},q:function(t,e,r){var n,o,i,a,s;r=vt(r),2===e?(n=ge,o=me,a=we,i=()=>_,s=1):4===e&&(n=be,o=Pe,a=Te,i=()=>A,s=2),mt(t,{name:r,fromWireType:function(t){for(var r,o=A[t>>2],a=i(),u=t+4,c=0;c<=o;++c){var f=t+4+c*e;if(c==o||0==a[f>>s]){var l=n(u,f-u);void 0===r?r=l:(r+=String.fromCharCode(0),r+=l),u=f+e}}return Se(t),r},toWireType:function(t,n){"string"!=typeof n&>("Cannot pass non-string to C++ string type "+r);var i=a(n),u=Oe(4+i+e);return A[u>>2]=i>>s,o(n,u+4,i+e),null!==t&&t.push(Se,u),u},argPackAdvance:8,readValueFromPointer:nt,destructorFunction:function(t){Se(t)}})},p:function(t,e,r,n,o,i){et[t]={name:vt(e),rawConstructor:ee(r,n),rawDestructor:ee(o,i),fields:[]}},C:function(t,e,r,n,o,i,a,s,u,c){et[t].fields.push({fieldName:vt(e),getterReturnType:r,getter:ee(n,o),getterContext:i,setterArgumentType:a,setter:ee(s,u),setterContext:c})},K:function(t,e){mt(t,{isVoid:!0,name:e=vt(e),argPackAdvance:0,fromWireType:function(){},toWireType:function(t,e){}})},O:ce,P:function(t){t>4&&(ue[t].refcount+=1)},n:function(t,e){var r,n,o;n="_emval_take_value",void 0===(o=it[r=t])&>(n+" has unknown type "+ne(r));var i=(t=o).readValueFromPointer(e);return pe.toHandle(i)},r:function(){z("")},H:function(t,e,r){T.copyWithin(t,e,e+r)},F:function(t){var e,r,n=T.length,o=2147483648;if((t>>>=0)>o)return!1;for(var i=1;i<=4;i*=2){var a=n*(1+.2/i);if(a=Math.min(a,t+100663296),Ce(Math.min(o,(e=Math.max(t,a))+((r=65536)-e%r)%r)))return!0}return!1},G:function(t){return 52},D:function(t,e,r,n,o){return 70},s:function(t,e,r,n){for(var o=0,i=0;i<r;i++){var a=A[e>>2],s=A[e+4>>2];e+=8;for(var u=0;u<s;u++)$e(t,T[a+u]);o+=s}return A[n>>2]=o,0},b:function(t,e){var r=Re();try{return Q(t)(e)}catch(t){if(De(r),t!==t+0)throw t;_setThrew(1,0)}},A:function(t,e,r){var n=Re();try{return Q(t)(e,r)}catch(t){if(De(n),t!==t+0)throw t;_setThrew(1,0)}},w:function(t,e,r,n){var o=Re();try{return Q(t)(e,r,n)}catch(t){if(De(o),t!==t+0)throw t;_setThrew(1,0)}},e:function(t,e){var r=Re();try{Q(t)(e)}catch(t){if(De(r),t!==t+0)throw t;_setThrew(1,0)}},k:function(t,e,r){var n=Re();try{Q(t)(e,r)}catch(t){if(De(n),t!==t+0)throw t;_setThrew(1,0)}},l:function(t,e,r,n){var o=Re();try{Q(t)(e,r,n)}catch(t){if(De(o),t!==t+0)throw t;_setThrew(1,0)}},x:function(t,e,r,n,o){var i=Re();try{Q(t)(e,r,n,o)}catch(t){if(De(i),t!==t+0)throw t;_setThrew(1,0)}},L:function(t,e,r,n,o,i,a){var s=Re();try{Q(t)(e,r,n,o,i,a)}catch(t){if(De(s),t!==t+0)throw t;_setThrew(1,0)}},m:function(t,e,r,n,o,i,a,s){var u=Re();try{Q(t)(e,r,n,o,i,a,s)}catch(t){if(De(u),t!==t+0)throw t;_setThrew(1,0)}},g:function(t,e,r,n,o,i,a,s,u,c,f){var l=Re();try{Q(t)(e,r,n,o,i,a,s,u,c,f)}catch(t){if(De(l),t!==t+0)throw t;_setThrew(1,0)}},N:function(t){return t}},Oe=(function(){var e={a:xe};function r(e,r){var n,o=e.exports;t.asm=o,D((w=t.asm.Q).buffer),F=t.asm.U,n=t.asm.R,L.unshift(n),function(e){if(B--,t.monitorRunDependencies&&t.monitorRunDependencies(B),0==B&&(null!==M&&(clearInterval(M),M=null),V)){var r=V;V=null,r()}}()}function n(t){r(t.instance)}function i(t){return function(){if(!y&&(f||l)){if("function"==typeof fetch&&!G(W))return fetch(W,{credentials:"same-origin"}).then((function(t){if(!t.ok)throw"failed to load wasm binary file at '"+W+"'";return t.arrayBuffer()})).catch((function(){return q(W)}));if(a)return new Promise((function(t,e){a(W,(function(e){t(new Uint8Array(e))}),e)}))}return Promise.resolve().then((function(){return q(W)}))}().then((function(t){return WebAssembly.instantiate(t,e)})).then((function(t){return t})).then(t,(function(t){m("failed to asynchronously prepare wasm: "+t),z(t)}))}if(B++,t.monitorRunDependencies&&t.monitorRunDependencies(B),t.instantiateWasm)try{return t.instantiateWasm(e,r)}catch(t){m("Module.instantiateWasm callback failed with error: "+t),o(t)}(y||"function"!=typeof WebAssembly.instantiateStreaming||N(W)||G(W)||p||"function"!=typeof fetch?i(n):fetch(W,{credentials:"same-origin"}).then((function(t){return WebAssembly.instantiateStreaming(t,e).then(n,(function(t){return m("wasm streaming compile failed: "+t),m("falling back to ArrayBuffer instantiation"),i(n)}))}))).catch(o)}(),t.___wasm_call_ctors=function(){return(t.___wasm_call_ctors=t.asm.R).apply(null,arguments)},t._malloc=function(){return(Oe=t._malloc=t.asm.S).apply(null,arguments)}),ke=t.___cxa_free_exception=function(){return(ke=t.___cxa_free_exception=t.asm.T).apply(null,arguments)},Se=t._free=function(){return(Se=t._free=t.asm.V).apply(null,arguments)},je=t.___getTypeName=function(){return(je=t.___getTypeName=t.asm.W).apply(null,arguments)},Ee=(t.__embind_initialize_bindings=function(){return(t.__embind_initialize_bindings=t.asm.X).apply(null,arguments)},t.setTempRet0=function(){return(Ee=t.setTempRet0=t.asm.Y).apply(null,arguments)}),Re=t.stackSave=function(){return(Re=t.stackSave=t.asm.Z).apply(null,arguments)},De=t.stackRestore=function(){return(De=t.stackRestore=t.asm._).apply(null,arguments)},Fe=t.stackAlloc=function(){return(Fe=t.stackAlloc=t.asm.$).apply(null,arguments)},We=t.___cxa_can_catch=function(){return(We=t.___cxa_can_catch=t.asm.aa).apply(null,arguments)},Ie=t.___cxa_is_pointer_type=function(){return(Ie=t.___cxa_is_pointer_type=t.asm.ba).apply(null,arguments)};function Ue(r){function n(){Ae||(Ae=!0,t.calledRun=!0,k||(X(L),e(t),t.onRuntimeInitialized&&t.onRuntimeInitialized(),function(){if(t.postRun)for("function"==typeof t.postRun&&(t.postRun=[t.postRun]);t.postRun.length;)e=t.postRun.shift(),H.unshift(e);var e;X(H)}()))}r=r||c,B>0||(function(){if(t.preRun)for("function"==typeof t.preRun&&(t.preRun=[t.preRun]);t.preRun.length;)e=t.preRun.shift(),U.unshift(e);var e;X(U)}(),B>0||(t.setStatus?(t.setStatus("Running..."),setTimeout((function(){setTimeout((function(){t.setStatus("")}),1),n()}),1)):n()))}if(t.dynCall_ji=function(){return(t.dynCall_ji=t.asm.ca).apply(null,arguments)},t.dynCall_iiji=function(){return(t.dynCall_iiji=t.asm.da).apply(null,arguments)},t.dynCall_jiji=function(){return(t.dynCall_jiji=t.asm.ea).apply(null,arguments)},t.ccall=function(e,r,n,o,i){var a={string:t=>{var e=0;if(null!=t&&0!==t){var r=1+(t.length<<2);R(t,e=Fe(r),r)}return e},array:t=>{var e=Fe(t.length);return function(t,e){P.set(t,e)}(t,e),e}},s=function(e){return t["_"+e]}(e),u=[],c=0;if(o)for(var f=0;f<o.length;f++){var l=a[n[f]];l?(0===c&&(c=Re()),u[f]=l(o[f])):u[f]=o[f]}var p=s.apply(null,u);return p=function(t){return 0!==c&&De(c),function(t){return"string"===r?E(t):"boolean"===r?Boolean(t):t}(t)}(p)},V=function t(){Ae||Ue(),Ae||(V=t)},t.preInit)for("function"==typeof t.preInit&&(t.preInit=[t.preInit]);t.preInit.length>0;)t.preInit.pop()();return Ue(),t.ready});t.exports=o},602:t=>{var e=function(t){"use strict";var e,r=Object.prototype,n=r.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",s=o.toStringTag||"@@toStringTag";function u(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{u({},"")}catch(t){u=function(t,e,r){return t[e]=r}}function c(t,e,r,n){var o=e&&e.prototype instanceof y?e:y,i=Object.create(o.prototype),a=new O(n||[]);return i._invoke=function(t,e,r){var n=l;return function(o,i){if(n===h)throw new Error("Generator is already running");if(n===d){if("throw"===o)throw i;return S()}for(r.method=o,r.arg=i;;){var a=r.delegate;if(a){var s=$(a,r);if(s){if(s===v)continue;return s}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(n===l)throw n=d,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n=h;var u=f(t,e,r);if("normal"===u.type){if(n=r.done?d:p,u.arg===v)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n=d,r.method="throw",r.arg=u.arg)}}}(t,r,a),i}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=c;var l="suspendedStart",p="suspendedYield",h="executing",d="completed",v={};function y(){}function g(){}function m(){}var w={};u(w,i,(function(){return this}));var b=Object.getPrototypeOf,P=b&&b(b(k([])));P&&P!==r&&n.call(P,i)&&(w=P);var T=m.prototype=y.prototype=Object.create(w);function C(t){["next","throw","return"].forEach((function(e){u(t,e,(function(t){return this._invoke(e,t)}))}))}function _(t,e){function r(o,i,a,s){var u=f(t[o],t,i);if("throw"!==u.type){var c=u.arg,l=c.value;return l&&"object"==typeof l&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,a,s)}),(function(t){r("throw",t,a,s)})):e.resolve(l).then((function(t){c.value=t,a(c)}),(function(t){return r("throw",t,a,s)}))}s(u.arg)}var o;this._invoke=function(t,n){function i(){return new e((function(e,o){r(t,n,e,o)}))}return o=o?o.then(i,i):i()}}function $(t,r){var n=t.iterator[r.method];if(n===e){if(r.delegate=null,"throw"===r.method){if(t.iterator.return&&(r.method="return",r.arg=e,$(t,r),"throw"===r.method))return v;r.method="throw",r.arg=new TypeError("The iterator does not provide a 'throw' method")}return v}var o=f(n,t.iterator,r.arg);if("throw"===o.type)return r.method="throw",r.arg=o.arg,r.delegate=null,v;var i=o.arg;return i?i.done?(r[t.resultName]=i.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,v):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,v)}function A(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function x(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function O(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(A,this),this.reset(!0)}function k(t){if(t){var r=t[i];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,a=function r(){for(;++o<t.length;)if(n.call(t,o))return r.value=t[o],r.done=!1,r;return r.value=e,r.done=!0,r};return a.next=a}}return{next:S}}function S(){return{value:e,done:!0}}return g.prototype=m,u(T,"constructor",m),u(m,"constructor",g),g.displayName=u(m,s,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===g||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,m):(t.__proto__=m,u(t,s,"GeneratorFunction")),t.prototype=Object.create(T),t},t.awrap=function(t){return{__await:t}},C(_.prototype),u(_.prototype,a,(function(){return this})),t.AsyncIterator=_,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new _(c(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},C(T),u(T,s,"Generator"),u(T,i,(function(){return this})),u(T,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=[];for(var r in t)e.push(r);return e.reverse(),function r(){for(;e.length;){var n=e.pop();if(n in t)return r.value=n,r.done=!1,r}return r.done=!0,r}},t.values=k,O.prototype={constructor:O,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(x),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function o(n,o){return s.type="throw",s.arg=t,r.next=n,o&&(r.method="next",r.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],s=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var u=n.call(a,"catchLoc"),c=n.call(a,"finallyLoc");if(u&&c){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(u){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!c)throw new Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,v):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),v},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),x(r),v}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;x(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:k(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),v}},t}(t.exports);try{regeneratorRuntime=e}catch(t){"object"==typeof globalThis?globalThis.regeneratorRuntime=e:Function("r","regeneratorRuntime = r")(e)}},69:(t,e,r)=>{"use strict";t.exports=r.p+"5004fdc02f329ce53b69.wasm"},427:(t,e,r)=>{"use strict";t.exports=r.p+"c22b37c3488e1d6c3aa4.wasm"},699:(t,e,r)=>{"use strict";t.exports=r.p+"65916ef3def695744bda.wasm"},813:(t,e,r)=>{"use strict";t.exports=r.p+"75788f12450d4c5ed494.wasm"},716:()=>{},401:()=>{},491:()=>{},33:()=>{},261:()=>{},926:()=>{},280:()=>{},103:()=>{}},n={};function o(t){var e=n[t];if(void 0!==e)return e.exports;var i=n[t]={exports:{}};return r[t].call(i.exports,i,i.exports,o),i.exports}o.m=r,o.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return o.d(e,{a:e}),e},e=Object.getPrototypeOf?t=>Object.getPrototypeOf(t):t=>t.__proto__,o.t=function(r,n){if(1&n&&(r=this(r)),8&n)return r;if("object"==typeof r&&r){if(4&n&&r.__esModule)return r;if(16&n&&"function"==typeof r.then)return r}var i=Object.create(null);o.r(i);var a={};t=t||[null,e({}),e([]),e(e)];for(var s=2&n&&r;"object"==typeof s&&!~t.indexOf(s);s=e(s))Object.getOwnPropertyNames(s).forEach((t=>a[t]=()=>r[t]));return a.default=()=>r,o.d(i,a),i},o.d=(t,e)=>{for(var r in e)o.o(e,r)&&!o.o(t,r)&&Object.defineProperty(t,r,{enumerable:!0,get:e[r]})},o.f={},o.e=t=>Promise.all(Object.keys(o.f).reduce(((e,r)=>(o.f[r](t,e),e)),[])),o.u=t=>t+".min.worker.js",o.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(t){if("object"==typeof window)return window}}(),o.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),o.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},(()=>{var t;o.g.importScripts&&(t=o.g.location+"");var e=o.g.document;if(!t&&e&&(e.currentScript&&(t=e.currentScript.src),!t)){var r=e.getElementsByTagName("script");r.length&&(t=r[r.length-1].src)}if(!t)throw new Error("Automatic publicPath is not supported in this browser");t=t.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),o.p=t})(),(()=>{var t={362:1};o.f.i=(e,r)=>{t[e]||importScripts(o.p+o.u(e))};var e=self.webpackChunk_name_=self.webpackChunk_name_||[],r=e.push.bind(e);e.push=e=>{var[n,i,a]=e;for(var s in i)o.o(i,s)&&(o.m[s]=i[s]);for(a&&a(o);n.length;)t[n.pop()]=1;r(e)}})(),(()=>{"use strict";function t(t,e,r,n,o,i,a){try{var s=t[i](a),u=s.value}catch(t){return void r(t)}s.done?e(u):Promise.resolve(u).then(n,o)}function e(e){return function(){var r=this,n=arguments;return new Promise((function(o,i){var a=e.apply(r,n);function s(e){t(a,o,i,s,u,"next",e)}function u(e){t(a,o,i,s,u,"throw",e)}s(void 0)}))}}var r,n=o(945),i=o.n(n),a={},s=!1;function u(t){if(!s){if(r=t.config,self.registerTaskHandler=c,t.config.webWorkerTaskPaths)for(var e=0;e<t.config.webWorkerTaskPaths.length;e++)self.importScripts(t.config.webWorkerTaskPaths[e]);Object.keys(a).forEach((function(t){a[t].initialize(r.taskConfiguration)})),self.postMessage({taskType:"initialize",status:"success",result:{},workerIndex:t.workerIndex}),s=!0}}function c(t){if(a[t.taskType])return console.log('attempt to register duplicate task handler "',t.taskType,'"'),!1;a[t.taskType]=t,s&&t.initialize(r.taskConfiguration)}function f(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}self.onmessage=function(){var t=e(i().mark((function t(e){return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(e.data.taskType){t.next=3;break}return console.log(e.data),t.abrupt("return");case 3:if("initialize"!==e.data.taskType){t.next=6;break}return u(e.data),t.abrupt("return");case 6:if("loadWebWorkerTask"!==e.data.taskType){t.next=9;break}return n=e.data,r=n.config,self.importScripts(n.sourcePath),t.abrupt("return");case 9:if(a[e.data.taskType])try{a[e.data.taskType].handler(e.data,(function(t,r){self.postMessage({taskType:e.data.taskType,status:"success",result:t,workerIndex:e.data.workerIndex},r)}))}catch(t){console.log("task ".concat(e.data.taskType," failed - ").concat(t.message),t),self.postMessage({taskType:e.data.taskType,status:"failed",result:t.message,workerIndex:e.data.workerIndex})}else console.log("no task handler for ",e.data.taskType),console.log(a),self.postMessage({taskType:e.data.taskType,status:"failed - no task handler registered",workerIndex:e.data.workerIndex});case 10:case"end":return t.stop()}var n}),t)})));return function(e){return t.apply(this,arguments)}}();var l=o(272),p=o.n(l),h=o(699);function d(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function v(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?d(Object(r),!0).forEach((function(e){f(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):d(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var y={codec:void 0,decoder:void 0,decodeConfig:{}};function g(t){if(y.decodeConfig=t,y.codec)return Promise.resolve();var e=p()({locateFile:function(t){return t.endsWith(".wasm")?h.toString():t}});return new Promise((function(t,r){e.then((function(e){y.codec=e,y.decoder=new e.J2KDecoder,t()}),r)}))}function m(){return(m=e(i().mark((function t(e,r){var n,o,a,s,u,c,f,l,p,h,d,m,b,P,T,C,_,$;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,g();case 2:return n=y.decoder,(o=n.getEncodedBuffer(e.length)).set(e),n.decode(),a=n.getFrameInfo(),s=n.getDecodedBuffer(),new Uint8Array(s.length).set(s),u="x: ".concat(n.getImageOffset().x,", y: ").concat(n.getImageOffset().y),c=n.getNumDecompositions(),f=n.getNumLayers(),l=["unknown","LRCP","RLCP","RPCL","PCRL","CPRL"][n.getProgressionOrder()+1],p=n.getIsReversible(),h="".concat(n.getBlockDimensions().width," x ").concat(n.getBlockDimensions().height),d="".concat(n.getTileSize().width," x ").concat(n.getTileSize().height),m="".concat(n.getTileOffset().x,", ").concat(n.getTileOffset().y),b=n.getColorSpace(),P="".concat(s.length.toLocaleString()," bytes"),T="".concat((s.length/o.length).toFixed(2),":1"),C={columns:a.width,rows:a.height,bitsPerPixel:a.bitsPerSample,signed:a.isSigned,bytesPerPixel:r.bytesPerPixel,componentsPerPixel:a.componentCount},_=w(a,s),$={imageOffset:u,numDecompositions:c,numLayers:f,progessionOrder:l,reversible:p,blockDimensions:h,tileSize:d,tileOffset:m,colorTransform:b,decodedSize:P,compressionRatio:T},t.abrupt("return",v(v(v({},r),{},{pixelData:_,imageInfo:C,encodeOptions:$},$),C));case 25:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function w(t,e){return t.bitsPerSample>8?t.isSigned?new Int16Array(e.buffer,e.byteOffset,e.byteLength/2):new Uint16Array(e.buffer,e.byteOffset,e.byteLength/2):t.isSigned?new Int8Array(e.buffer,e.byteOffset,e.byteLength):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}const b=function(t,e){return m.apply(this,arguments)};var P=o(37),T=o.n(P),C=o(69);function _(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function $(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?_(Object(r),!0).forEach((function(e){f(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):_(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var A={codec:void 0,decoder:void 0,decodeConfig:{}};function x(t){return"number"==typeof t?A.codec.getExceptionMessage(t):t}function O(t){if(A.decodeConfig=t,A.codec)return Promise.resolve();var e=T()({locateFile:function(t){return t.endsWith(".wasm")?C.toString():t}});return new Promise((function(t,r){e.then((function(e){A.codec=e,A.decoder=new e.JpegLSDecoder,t()}),r)}))}function k(){return(k=e(i().mark((function t(e,r){var n,o,a,s,u,c,f,l;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,O();case 3:return n=A.decoder,n.getEncodedBuffer(e.length).set(e),n.decode(),o=n.getFrameInfo(),a=n.getInterleaveMode(),s=n.getNearLossless(),u=n.getDecodedBuffer(),c={columns:o.width,rows:o.height,bitsPerPixel:o.bitsPerSample,signed:r.signed,bytesPerPixel:r.bytesPerPixel,componentsPerPixel:o.componentCount},f=S(o,u,r.signed),l={nearLossless:s,interleaveMode:a,frameInfo:o},t.abrupt("return",$($($({},r),{},{pixelData:f,imageInfo:c,encodeOptions:l},l),c));case 17:throw t.prev=17,t.t0=t.catch(0),x(t.t0);case 20:case"end":return t.stop()}}),t,null,[[0,17]])})))).apply(this,arguments)}function S(t,e,r){return t.bitsPerSample>8?r?new Int16Array(e.buffer,e.byteOffset,e.byteLength/2):new Uint16Array(e.buffer,e.byteOffset,e.byteLength/2):r?new Int8Array(e.buffer,e.byteOffset,e.byteLength):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}const j=function(t,e){return k.apply(this,arguments)};const E=function(t){for(var e,r=t[0],n=t[0],o=t.length,i=1;i<o;i++)e=t[i],r=Math.min(r,e),n=Math.max(n,e);return{min:r,max:n}};function R(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],r=void 0!==t.minAfterScale||void 0!==t.maxAfterScale?{min:t.minAfterScale,max:t.maxAfterScale}:E(t.pixelData),n=!(D(t.smallestPixelValue)&&D(t.largestPixelValue));!0!==e||n?(t.smallestPixelValue=r.min,t.largestPixelValue=r.max):(t.smallestPixelValue!==r.min&&console.warn("Image smallestPixelValue tag is incorrect. Rendering performance will suffer considerably."),t.largestPixelValue!==r.max&&console.warn("Image largestPixelValue tag is incorrect. Rendering performance will suffer considerably."))}function D(t){return"number"==typeof t}function F(){return(F=e(i().mark((function t(e,r){var n,o,a;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=r.buffer,o=r.byteOffset,a=r.length,16===e.bitsAllocated?(o%2&&(n=n.slice(o),o=0),0===e.pixelRepresentation?e.pixelData=new Uint16Array(n,o,a/2):e.pixelData=new Int16Array(n,o,a/2)):8===e.bitsAllocated||1===e.bitsAllocated?e.pixelData=r:32===e.bitsAllocated&&(o%2&&(n=n.slice(o),o=0),e.pixelData=new Float32Array(n,o,a/4)),t.abrupt("return",e);case 5:case"end":return t.stop()}}),t)})))).apply(this,arguments)}const W=function(t,e){return F.apply(this,arguments)};function I(t){return(255&t)<<8|t>>8&255}function U(){return(U=e(i().mark((function t(e,r){var n,o,a,s;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(16===e.bitsAllocated)for(n=r.buffer,o=r.byteOffset,a=r.length,o%2&&(n=n.slice(o),o=0),0===e.pixelRepresentation?e.pixelData=new Uint16Array(n,o,a/2):e.pixelData=new Int16Array(n,o,a/2),s=0;s<e.pixelData.length;s++)e.pixelData[s]=I(e.pixelData[s]);else 8===e.bitsAllocated&&(e.pixelData=r);return t.abrupt("return",e);case 2:case"end":return t.stop()}}),t)})))).apply(this,arguments)}const L=function(t,e){return U.apply(this,arguments)};function H(){return(H=e(i().mark((function t(e,r){return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(8!==e.bitsAllocated){t.next=6;break}if(!e.planarConfiguration){t.next=3;break}return t.abrupt("return",M(e,r));case 3:return t.abrupt("return",B(e,r));case 6:if(16!==e.bitsAllocated){t.next=8;break}return t.abrupt("return",V(e,r));case 8:throw new Error("unsupported pixel format for RLE");case 9:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function B(t,e){for(var r=e,n=t.rows*t.columns,o=new ArrayBuffer(n*t.samplesPerPixel),i=new DataView(r.buffer,r.byteOffset),a=new Int8Array(r.buffer,r.byteOffset),s=new Int8Array(o),u=0,c=i.getInt32(0,!0),f=0;f<c;++f){u=f;var l=i.getInt32(4*(f+1),!0),p=i.getInt32(4*(f+2),!0);0===p&&(p=r.length);for(var h=n*c;l<p;){var d=a[l++];if(d>=0&&d<=127)for(var v=0;v<d+1&&u<h;++v)s[u]=a[l++],u+=t.samplesPerPixel;else if(d<=-1&&d>=-127)for(var y=a[l++],g=0;g<1-d&&u<h;++g)s[u]=y,u+=t.samplesPerPixel}}return t.pixelData=new Uint8Array(o),t}function M(t,e){for(var r=e,n=t.rows*t.columns,o=new ArrayBuffer(n*t.samplesPerPixel),i=new DataView(r.buffer,r.byteOffset),a=new Int8Array(r.buffer,r.byteOffset),s=new Int8Array(o),u=0,c=i.getInt32(0,!0),f=0;f<c;++f){u=f*n;var l=i.getInt32(4*(f+1),!0),p=i.getInt32(4*(f+2),!0);0===p&&(p=r.length);for(var h=n*c;l<p;){var d=a[l++];if(d>=0&&d<=127)for(var v=0;v<d+1&&u<h;++v)s[u]=a[l++],u++;else if(d<=-1&&d>=-127)for(var y=a[l++],g=0;g<1-d&&u<h;++g)s[u]=y,u++}}return t.pixelData=new Uint8Array(o),t}function V(t,e){for(var r=e,n=t.rows*t.columns,o=new ArrayBuffer(n*t.samplesPerPixel*2),i=new DataView(r.buffer,r.byteOffset),a=new Int8Array(r.buffer,r.byteOffset),s=new Int8Array(o),u=i.getInt32(0,!0),c=0;c<u;++c){var f=0,l=0===c?1:0,p=i.getInt32(4*(c+1),!0),h=i.getInt32(4*(c+2),!0);for(0===h&&(h=r.length);p<h;){var d=a[p++];if(d>=0&&d<=127)for(var v=0;v<d+1&&f<n;++v)s[2*f+l]=a[p++],f++;else if(d<=-1&&d>=-127)for(var y=a[p++],g=0;g<1-d&&f<n;++g)s[2*f+l]=y,f++}}return 0===t.pixelRepresentation?t.pixelData=new Uint16Array(o):t.pixelData=new Int16Array(o),t}const z=function(t,e){return H.apply(this,arguments)};var N=o(851),G=o.n(N),q=o(427);function J(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function X(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?J(Object(r),!0).forEach((function(e){f(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):J(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var Y={codec:void 0,decoder:void 0};function K(){if(Y.codec)return Promise.resolve();var t=G()({locateFile:function(t){return t.endsWith(".wasm")?q.toString():t}});return new Promise((function(e,r){t.then((function(t){Y.codec=t,Y.decoder=new t.JPEGDecoder,e()}),r)}))}function Z(){return(Z=e(i().mark((function t(e,r){var n,o,a,s,u,c;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,K();case 2:return n=Y.decoder,n.getEncodedBuffer(e.length).set(e),n.decode(),o=n.getFrameInfo(),a=n.getDecodedBuffer(),s={columns:o.width,rows:o.height,bitsPerPixel:o.bitsPerSample,signed:r.signed,bytesPerPixel:r.bytesPerPixel,componentsPerPixel:o.componentCount},u=Q(o,a),c={frameInfo:o},t.abrupt("return",X(X(X({},r),{},{pixelData:u,imageInfo:s,encodeOptions:c},c),s));case 12:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function Q(t,e){return t.isSigned?new Int8Array(e.buffer,e.byteOffset,e.byteLength):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}const tt=function(t,e){return Z.apply(this,arguments)};var et={JpegImage:void 0,decodeConfig:{}};function rt(t){return et.decodeConfig=t,et.JpegImage?Promise.resolve():new Promise((function(t,e){o.e(945).then(o.t.bind(o,54,23)).then((function(e){var r=e.JpegImage;et.JpegImage=r,t()}),e)}))}function nt(){return(nt=e(i().mark((function t(e,r){var n;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,rt();case 2:if(void 0!==et.JpegImage){t.next=4;break}throw new Error("No JPEG Baseline decoder loaded");case 4:if((n=new et.JpegImage).parse(r),n.colorTransform=!1,8!==e.bitsAllocated){t.next=12;break}return e.pixelData=n.getData(e.columns,e.rows),t.abrupt("return",e);case 12:if(16!==e.bitsAllocated){t.next=15;break}return e.pixelData=n.getData16(e.columns,e.rows),t.abrupt("return",e);case 15:case"end":return t.stop()}}),t)})))).apply(this,arguments)}const ot=function(t,e){return nt.apply(this,arguments)};var it={jpeg:void 0,decodeConfig:{}};function at(t){return it.decodeConfig=t,it.jpeg?Promise.resolve():new Promise((function(t,e){o.e(610).then(o.t.bind(o,610,23)).then((function(e){it.jpeg=e,t()}),e)}))}function st(){return(st=e(i().mark((function t(e,r){var n,o,a,s;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,at();case 2:if(void 0!==it.jpeg&&void 0!==it.jpeg.lossless&&void 0!==it.jpeg.lossless.Decoder){t.next=4;break}throw new Error("No JPEG Lossless decoder loaded");case 4:if(n=e.bitsAllocated<=8?1:2,o=r.buffer,a=new it.jpeg.lossless.Decoder,s=a.decode(o,r.byteOffset,r.length,n),0!==e.pixelRepresentation){t.next=14;break}if(16!==e.bitsAllocated){t.next=12;break}return e.pixelData=new Uint16Array(s.buffer),t.abrupt("return",e);case 12:return e.pixelData=new Uint8Array(s.buffer),t.abrupt("return",e);case 14:return e.pixelData=new Int16Array(s.buffer),t.abrupt("return",e);case 16:case"end":return t.stop()}}),t)})))).apply(this,arguments)}const ut=function(t,e){return st.apply(this,arguments)};var ct=o(430),ft=o.n(ct),lt=o(813);function pt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function ht(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?pt(Object(r),!0).forEach((function(e){f(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):pt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}var dt={codec:void 0,decoder:void 0,decodeConfig:{}};function vt(t){if(dt.decodeConfig=t,dt.codec)return Promise.resolve();var e=ft()({locateFile:function(t){return t.endsWith(".wasm")?lt:t}});return new Promise((function(t,r){e.then((function(e){dt.codec=e,dt.decoder=new e.HTJ2KDecoder,t()}),r)}))}function yt(){return(yt=e(i().mark((function t(e,r){var n,o,a,s,u,c,f,l,p,h,d,v,y,g,m,w,b,P,T,C,_,$;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,vt();case 2:return n=dt.decoder,(o=n.getEncodedBuffer(e.length)).set(e),n.decode(),a=n.getFrameInfo(),s=n.getDecodedBuffer(),new Uint8Array(s.length).set(s),u="x: ".concat(n.getImageOffset().x,", y: ").concat(n.getImageOffset().y),c=n.getNumDecompositions(),f=n.getNumLayers(),l=["unknown","LRCP","RLCP","RPCL","PCRL","CPRL"][n.getProgressionOrder()+1],p=n.getIsReversible(),h="".concat(n.getBlockDimensions().width," x ").concat(n.getBlockDimensions().height),d="".concat(n.getTileSize().width," x ").concat(n.getTileSize().height),v="".concat(n.getTileOffset().x,", ").concat(n.getTileOffset().y),y="".concat(s.length.toLocaleString()," bytes"),g="".concat((s.length/o.length).toFixed(2),":1"),m={columns:a.width,rows:a.height,bitsPerPixel:a.bitsPerSample,signed:a.isSigned,bytesPerPixel:r.bytesPerPixel,componentsPerPixel:a.componentCount},w=gt(a,s),P=(b=w).buffer,T=b.byteOffset,C=b.byteLength,_=P.slice(T,T+C),w=new w.constructor(_),$={imageOffset:u,numDecompositions:c,numLayers:f,progessionOrder:l,reversible:p,blockDimensions:h,tileSize:d,tileOffset:v,decodedSize:y,compressionRatio:g},t.abrupt("return",ht(ht(ht({},r),{},{pixelData:w,imageInfo:m,encodeOptions:$},$),m));case 27:case"end":return t.stop()}}),t)})))).apply(this,arguments)}function gt(t,e){return t.bitsPerSample>8?t.isSigned?new Int16Array(e.buffer,e.byteOffset,e.byteLength/2):new Uint16Array(e.buffer,e.byteOffset,e.byteLength/2):t.isSigned?new Int8Array(e.buffer,e.byteOffset,e.byteLength):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}const mt=function(t,e){return yt.apply(this,arguments)};function wt(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function bt(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?wt(Object(r),!0).forEach((function(e){f(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):wt(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function Pt(){return Pt=e(i().mark((function t(e,r,n,o,a,s){var u,c,f,l,p;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:u=(new Date).getTime(),c=null,t.t0=r,t.next="1.2.840.10008.1.2"===t.t0||"1.2.840.10008.1.2.1"===t.t0?5:"1.2.840.10008.1.2.2"===t.t0?7:"1.2.840.10008.1.2.1.99"===t.t0?9:"1.2.840.10008.1.2.5"===t.t0?11:"1.2.840.10008.1.2.4.50"===t.t0?13:"1.2.840.10008.1.2.4.51"===t.t0?16:"1.2.840.10008.1.2.4.57"===t.t0?18:"1.2.840.10008.1.2.4.70"===t.t0?20:"1.2.840.10008.1.2.4.80"===t.t0?22:"1.2.840.10008.1.2.4.81"===t.t0?25:"1.2.840.10008.1.2.4.90"===t.t0?28:"1.2.840.10008.1.2.4.91"===t.t0?31:"3.2.840.10008.1.2.4.96"===t.t0?34:37;break;case 5:case 9:return c=W(e,n),t.abrupt("break",38);case 7:return c=L(e,n),t.abrupt("break",38);case 11:return c=z(e,n),t.abrupt("break",38);case 13:return f=bt({},e),c=tt(n,f),t.abrupt("break",38);case 16:return c=ot(e,n),t.abrupt("break",38);case 18:case 20:return c=ut(e,n),t.abrupt("break",38);case 22:case 25:return f=bt({signed:1===e.pixelRepresentation,bytesPerPixel:e.bitsAllocated<=8?1:2},e),c=j(n,f),t.abrupt("break",38);case 28:case 31:return f=bt({},e),c=b(n,f),t.abrupt("break",38);case 34:return f=bt({},e),c=mt(n,f),t.abrupt("break",38);case 37:throw new Error("no decoder for transfer syntax ".concat(r));case 38:if(c){t.next=40;break}throw new Error("decodePromise not defined");case 40:return t.next=42,c;case 42:return l=t.sent,p=Tt(l,a,u,o),null==s||s(p),t.abrupt("return",p);case 46:case"end":return t.stop()}}),t)}))),Pt.apply(this,arguments)}function Tt(t,e,r,n){var o=(n||{}).use16BitDataType,i=void 0!==t.pixelRepresentation&&1===t.pixelRepresentation,a=i&&void 0!==t.bitsStored?32-t.bitsStored:void 0;if(i&&void 0!==a)for(var s=0;s<t.pixelData.length;s++)t.pixelData[s]=t.pixelData[s]<<a>>a;var u=t.pixelData;t.pixelDataLength=t.pixelData.length;var c,f=E(t.pixelData),l=f.min,p=f.max,h={Uint8Array,Uint16Array:o?Uint16Array:void 0,Int16Array:o?Int16Array:void 0,Float32Array};u=e.targetBuffer&&e.targetBuffer.type&&("RGB"!==(c=t.photometricInterpretation)&&"PALETTE COLOR"!==c&&"YBR_FULL"!==c&&"YBR_FULL_422"!==c&&"YBR_PARTIAL_422"!==c&&"YBR_PARTIAL_420"!==c&&"YBR_RCT"!==c&&"YBR_ICT"!==c)?function(t,e,r,n){var o=t.targetBuffer,i=o.arrayBuffer,a=o.type,s=o.offset,u=void 0===s?0:s,c=o.length,f=e.pixelDataLength,l=u,p=null!=c?c:f-l,h=r[a];if(!h)throw new Error("target array ".concat(a," is not supported"));var d=e.pixelData;if(p!==d.length)throw new Error("target array for image does not have the same length (".concat(p,") as the decoded image length (").concat(d.length,")."));var v=i?new h(i,l,p):new h(p);return v.set(d,0),v}(e,t,h):e.preScale.enabled?function(t,e,r,n){var o=t.preScale.scalingParameters;_t(o);var i=o.rescaleSlope,a=o.rescaleIntercept,s=e,u=r;"number"==typeof i&&"number"==typeof a&&(s=i*e+a,u=i*r+a);return Ct(s,u,n)}(e,l,p,t):Ct(l,p,t);var d=l,v=p;if(e.preScale.enabled){var y=e.preScale.scalingParameters;_t(y);var g=y.rescaleSlope,m=y.rescaleIntercept;y.suvbw;if("number"==typeof g&&"number"==typeof m){!function(t,e){var r=t.length,n=e.rescaleSlope,o=e.rescaleIntercept,i=e.suvbw;if("PT"===e.modality&&"number"==typeof i)for(var a=0;a<r;a++)t[a]=i*(t[a]*n+o);else for(var s=0;s<r;s++)t[s]=t[s]*n+o}(u,y),t.preScale=bt(bt({},e.preScale),{},{scaled:!0});var w=y.rescaleIntercept,b=y.rescaleSlope,P=y.suvbw;d=b*l+w,v=b*p+w,P&&(d*=P,v*=P)}}var T=void 0!==e.targetBuffer,C=T&&!(e.targetBuffer.arrayBuffer instanceof SharedArrayBuffer);T&&!C||(t.pixelData=u),t.minAfterScale=d,t.maxAfterScale=v;var _=(new Date).getTime();return t.decodeTimeInMS=_-r,t}function Ct(t,e,r){var n=function(t,e){var r;return Number.isInteger(t)&&Number.isInteger(e)?t>=0?e<=255?r=Uint8Array:e<=65535&&(r=Uint16Array):t>=-128&&e<=127?r=Int8Array:t>=-32768&&e<=32767&&(r=Int16Array):r=Float32Array,r}(t,e),o=new n(r.pixelData.length);return o.set(r.pixelData,0),o}function _t(t){if(!t)throw new Error("options.preScale.scalingParameters must be defined if preScale.enabled is true, and scalingParameters cannot be derived from the metadata providers.")}const $t=function(t,e,r,n,o,i){return Pt.apply(this,arguments)};var At;function xt(t){t.decodeTask.initializeCodecsOnStartup&&(g(t.decodeTask),O(t.decodeTask))}function Ot(){return(Ot=e(i().mark((function t(e,r){var n,o,a;return i().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return xt(At),n=At&&At.decodeTask&&At.decodeTask.strict,o=new Uint8Array(e.data.pixelData),t.next=5,$t(e.data.imageFrame,e.data.transferSyntax,o,Object.assign(At.decodeTask,e.data.decodeConfig),e.data.options);case 5:if((a=t.sent).pixelData){t.next=8;break}throw new Error("decodeTask: imageFrame.pixelData is undefined after decoding");case 8:return R(a,n),a.pixelData=a.pixelData.buffer,null==r||r(a,[a.pixelData]),t.abrupt("return",{result:a,transferList:[a.pixelData]});case 12:case"end":return t.stop()}}),t)})))).apply(this,arguments)}const kt={taskType:"decodeTask",handler:function(t,e){return Ot.apply(this,arguments)},initialize:function(t){At=t,xt(t)}};c(kt)})()})();
|
|
2
|
-
//# sourceMappingURL=index.worker.b7a83074fe09e221e999.worker.js.map
|