@rive-app/webgl2 2.44.1 → 2.44.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rive-app/webgl2",
3
- "version": "2.44.1",
3
+ "version": "2.44.2",
4
4
  "description": "Rive's webgl2 based web api.",
5
5
  "main": "rive.js",
6
6
  "homepage": "https://rive.app",
package/rive.js CHANGED
@@ -349,14 +349,14 @@ __webpack_require__.r(__webpack_exports__);
349
349
  /* harmony export */ __webpack_require__.d(__webpack_exports__, {
350
350
  /* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
351
351
  /* harmony export */ });
352
- var Rive=(()=>{var _scriptName=globalThis.document?.currentScript?.src;return async function(moduleArg={}){var moduleRtn;var C=moduleArg,aa=!!globalThis.window,ca=!!globalThis.WorkerGlobalScope;
353
- function da(){function c(z){const A=q;l=e=0;q=new Map;A.forEach(D=>{try{D(z)}catch(G){console.error(G)}});this.Ra();x&&x.ub()}let e=0,l=0,q=new Map,x=null,y=null;this.requestAnimationFrame=function(z){e||=requestAnimationFrame(c.bind(this));const A=++l;q.set(A,z);return A};this.cancelAnimationFrame=function(z){q.delete(z);e&&0==q.size&&(cancelAnimationFrame(e),e=0)};this.qb=function(z){y&&(document.body.remove(y),y=null);z||(y=document.createElement("div"),y.style.backgroundColor="black",y.style.position=
354
- "fixed",y.style.right=0,y.style.top=0,y.style.color="white",y.style.padding="4px",y.innerHTML="RIVE FPS",z=function(A){y.innerHTML="RIVE FPS "+A.toFixed(1)},document.body.appendChild(y));x=new function(){let A=0,D=0;this.ub=function(){var G=performance.now();D?(++A,G-=D,1E3<G&&(z(1E3*A/G),A=D=0)):(D=G,A=0)}}};this.Ra=function(){}}
355
- function ea(){console.assert(!0);const c=new Map;let e=-Infinity;this.push=function(l){l=l+255>>8;c.has(l)&&clearTimeout(c.get(l));c.set(l,setTimeout(function(){c.delete(l);0==c.length?e=-Infinity:l==e&&(e=Math.max(...c.keys()),console.assert(e<l))},1E3));e=Math.max(l,e);return e<<8}}const fa=C.onRuntimeInitialized;
356
- C.onRuntimeInitialized=function(){fa&&fa();C.startFileScripts=function(z){const A=C.riveScripting;return z&&A&&z.startScripts?A.prepare().then(function(){z.startScripts();return z}):Promise.resolve(z)};let c=C.decodeAudio;C.decodeAudio=function(z,A,D=null){z=c(z,D??null);A(z)};let e=C.decodeFont;C.decodeFont=function(z,A,D=null){z=e(z,D??null);A(z)};const l=C.FileAsset.prototype.decode;C.FileAsset.prototype.decode=function(z,A){return l.call(this,z,A??null)};let q=C.setFallbackFontCb;C.setFallbackFontCallback=
357
- "function"===typeof q?function(z){q(z)}:function(){console.warn("Module.setFallbackFontCallback called, but text support is not enabled in this build.")};const x=C.FileAssetLoader;C.ptrToAsset=z=>{let A=C.ptrToFileAsset(z);return A.isImage?C.ptrToImageAsset(z):A.isFont?C.ptrToFontAsset(z):A.isAudio?C.ptrToAudioAsset(z):A};C.CustomFileAssetLoader=x.extend("CustomFileAssetLoader",{__construct:function({loadContents:z}){this.__parent.__construct.call(this);this.eb=z},loadContents:function(z,A){z=C.ptrToAsset(z);
358
- return this.eb(z,A)}});C.CDNFileAssetLoader=x.extend("CDNFileAssetLoader",{__construct:function(z){this.__parent.__construct.call(this);this.gb=z??null},loadContents:function(z){let A=C.ptrToAsset(z);z=A.cdnUuid;if(""===z)return!1;const D=this.gb??null;(function(G,u){var a=new XMLHttpRequest;a.responseType="arraybuffer";a.onreadystatechange=function(){4==a.readyState&&200==a.status&&u(a)};a.open("GET",G,!0);a.send(null)})(A.cdnBaseUrl+"/"+z,G=>{A.decode(new Uint8Array(G.response),D)});return!0}});
359
- C.FallbackFileAssetLoader=x.extend("FallbackFileAssetLoader",{__construct:function(){this.__parent.__construct.call(this);this.Qa=[]},addLoader:function(z){this.Qa.push(z)},loadContents:function(z,A){for(let D of this.Qa)if(D.loadContents(z,A))return!0;return!1}});let y=C.computeAlignment;C.computeAlignment=function(z,A,D,G,u=1){return y.call(this,z,A,D,G,u)}};
352
+ var Rive=(()=>{var _scriptName=globalThis.document?.currentScript?.src;return async function(moduleArg={}){var moduleRtn;var D=moduleArg,aa=!!globalThis.window,ca=!!globalThis.WorkerGlobalScope;
353
+ function da(){function c(z){const A=q;l=e=0;q=new Map;A.forEach(C=>{try{C(z)}catch(G){console.error(G)}});this.Ra();x&&x.ub()}let e=0,l=0,q=new Map,x=null,y=null;this.requestAnimationFrame=function(z){e||=requestAnimationFrame(c.bind(this));const A=++l;q.set(A,z);return A};this.cancelAnimationFrame=function(z){q.delete(z);e&&0==q.size&&(cancelAnimationFrame(e),e=0)};this.qb=function(z){y&&(document.body.remove(y),y=null);z||(y=document.createElement("div"),y.style.backgroundColor="black",y.style.position=
354
+ "fixed",y.style.right=0,y.style.top=0,y.style.color="white",y.style.padding="4px",y.innerHTML="RIVE FPS",z=function(A){y.innerHTML="RIVE FPS "+A.toFixed(1)},document.body.appendChild(y));x=new function(){let A=0,C=0;this.ub=function(){var G=performance.now();C?(++A,G-=C,1E3<G&&(z(1E3*A/G),A=C=0)):(C=G,A=0)}}};this.Ra=function(){}}
355
+ function ea(){console.assert(!0);const c=new Map;let e=-Infinity;this.push=function(l){l=l+255>>8;c.has(l)&&clearTimeout(c.get(l));c.set(l,setTimeout(function(){c.delete(l);0==c.length?e=-Infinity:l==e&&(e=Math.max(...c.keys()),console.assert(e<l))},1E3));e=Math.max(l,e);return e<<8}}const fa=D.onRuntimeInitialized;
356
+ D.onRuntimeInitialized=function(){fa&&fa();D.startFileScripts=function(z){const A=D.riveScripting;return z&&A&&z.startScripts?A.prepare().then(function(){z.startScripts();return z}):Promise.resolve(z)};let c=D.decodeAudio;D.decodeAudio=function(z,A,C=null){z=c(z,C??null);A(z)};let e=D.decodeFont;D.decodeFont=function(z,A,C=null){z=e(z,C??null);A(z)};const l=D.FileAsset.prototype.decode;D.FileAsset.prototype.decode=function(z,A){return l.call(this,z,A??null)};let q=D.setFallbackFontCb;D.setFallbackFontCallback=
357
+ "function"===typeof q?function(z){q(z)}:function(){console.warn("Module.setFallbackFontCallback called, but text support is not enabled in this build.")};const x=D.FileAssetLoader;D.ptrToAsset=z=>{let A=D.ptrToFileAsset(z);return A.isImage?D.ptrToImageAsset(z):A.isFont?D.ptrToFontAsset(z):A.isAudio?D.ptrToAudioAsset(z):A};D.CustomFileAssetLoader=x.extend("CustomFileAssetLoader",{__construct:function({loadContents:z}){this.__parent.__construct.call(this);this.eb=z},loadContents:function(z,A){z=D.ptrToAsset(z);
358
+ return this.eb(z,A)}});D.CDNFileAssetLoader=x.extend("CDNFileAssetLoader",{__construct:function(z){this.__parent.__construct.call(this);this.gb=z??null},loadContents:function(z){let A=D.ptrToAsset(z);z=A.cdnUuid;if(""===z)return!1;const C=this.gb??null;(function(G,u){var a=new XMLHttpRequest;a.responseType="arraybuffer";a.onreadystatechange=function(){4==a.readyState&&200==a.status&&u(a)};a.open("GET",G,!0);a.send(null)})(A.cdnBaseUrl+"/"+z,G=>{A.decode(new Uint8Array(G.response),C)});return!0}});
359
+ D.FallbackFileAssetLoader=x.extend("FallbackFileAssetLoader",{__construct:function(){this.__parent.__construct.call(this);this.Qa=[]},addLoader:function(z){this.Qa.push(z)},loadContents:function(z,A){for(let C of this.Qa)if(C.loadContents(z,A))return!0;return!1}});let y=D.computeAlignment;D.computeAlignment=function(z,A,C,G,u=1){return y.call(this,z,A,C,G,u)}};
360
360
  (function(){function c(u,a){const d=u.kb,r=u.da,p=u.ca,v=u.Ba??{i:!1},f=(k,h)=>{k=new Uint8Array(a().buffer,k,h);const m=4096<h?u.Ga(h):u.ua(h);if(0===m)throw Error(`could not stage ${h} bytes for the host`);u.Z().set(k,m);v.i&&(v.la+=h);return m},b=(k,h)=>{0!==k&&4096<h&&u.Da(k)},g=(k,h,m)=>{(new Uint8Array(a().buffer,h,m)).set(u.Z().subarray(k,k+m));v.i&&(v.ja+=m)},n=k=>h=>{const m=(new Uint32Array(a().buffer,h-4,1))[0],w=r();let t=0;try{t=f(h,m),d.md(k,t,m)}finally{b(t,m),p(w)}};return{env:{seed:()=>
361
361
  Date.now()*Math.random(),emscripten_get_now:()=>performance.now(),emscripten_date_now:()=>Date.now(),trace:(k,h,m,w,t,B,F)=>{var H=console,K=H.log;const P=a().buffer,ba=(new Uint32Array(P,k-4,1))[0];k=(new TextDecoder("utf-16le")).decode(new Uint8Array(P,k,ba));return K.call(H,"trace: "+k,...[m,w,t,B,F].slice(0,h))},"console.log":n(0),"console.debug":n(0),"console.info":n(0),"console.warn":n(0),"console.error":n(0),"console.time":n(1),"console.timeLog":n(2),"console.timeEnd":n(3)},rive_rt_v1:{log:(k,
362
362
  h,m)=>{const w=r();let t=0;try{t=f(h,m),d.Zg(k,t,m)}finally{b(t,m),p(w)}},mark_needs_update:d.$g,budget_exceeded:d.Tg,error:(k,h)=>{const m=r();let w=0;try{w=f(k,h),d.Xg(w,h)}finally{b(w,h),p(m)}},now:()=>performance.now(),date_now:()=>Date.now(),debug_enter:d.Ug,debug_line:d.Wg,debug_leave:d.Vg,utc_offset:d.ah,is_dst:d.Yg,zone_name:(k,h,m)=>{const w=r();let t=0;try{t=f(h,m);const B=d.bh(k,t,m);g(t,h,m);return B}finally{b(t,m),p(w)}}},rive_data_v1:{view_model:d.ie,root_view_model:d.ce,global_view_model:(k,
@@ -468,46 +468,46 @@ b=>{0===a.g&&v();d.i&&d.l++;try{f(a.g,b)}catch(g){throw b=g,a.h=!0,b;}a.h&&p();n
468
468
  n,k)=>{0===a.g&&v();d.i&&d.l++;let h;try{h=f(a.g,b,g,n,k)}catch(m){throw b=m,a.h=!0,b;}a.h&&p();null!==a.j&&r();return h})(u(291)),Fe:(f=>(b,g,n,k)=>{0===a.g&&v();d.i&&d.l++;let h;try{h=f(a.g,b,g,n,k)}catch(m){throw b=m,a.h=!0,b;}a.h&&p();null!==a.j&&r();return h})(u(292)),Je:(f=>b=>{0===a.g&&v();d.i&&d.l++;try{f(a.g,b)}catch(g){throw b=g,a.h=!0,b;}a.h&&p();null!==a.j&&r()})(u(293)),Ie:(f=>(b,g,n)=>{0===a.g&&v();d.i&&d.l++;let k;try{k=f(a.g,b,g,n)}catch(h){throw b=h,a.h=!0,b;}a.h&&p();null!==a.j&&
469
469
  r();return k})(u(294)),Ge:(f=>b=>{0===a.g&&v();d.i&&d.l++;let g;try{g=f(a.g,b)}catch(n){throw b=n,a.h=!0,b;}a.h&&p();null!==a.j&&r();return g})(u(295)),He:(f=>(b,g)=>{0===a.g&&v();d.i&&d.l++;let n;try{n=f(a.g,b,g)}catch(k){throw b=k,a.h=!0,b;}a.h&&p();null!==a.j&&r();return n})(u(296)),md:(f=>(b,g,n)=>{0===a.g&&v();d.i&&d.l++;try{f(a.g,b,g,n)}catch(k){throw b=k,a.h=!0,b;}a.h&&p();null!==a.j&&r()})(u(297))}}function l(u,a){return()=>{throw Error("failed to call unlinked import function "+u+"."+a);
470
470
  }}function q(u){u=[0,...u,11];return new Uint8Array([0,97,115,109,1,0,0,0,1,5,1,96,0,1,123,3,2,1,0,10,u.length+2,1,u.length,...u])}function x(u,a){let d=0,r=0,p;do p=u[a++],d|=(p&127)<<r,r+=7;while(p&128);return[d>>>0,a]}function y(u){const a=[];do{const d=u&127;u>>>=7;a.push(u?d|128:d)}while(u);return a}function z(u){var a=[],d=-1;for(var r=8;r<u.length;){const [p,v]=x(u,r+1);8===u[r]?d=x(u,v)[0]:a.push({id:u[r],at:r,body:v,end:v+p});r=v+p}if(0>d||!a.some(p=>7===p.id))return u;r=[u.subarray(0,8)];
471
- for(const p of a){if(7!==p.id){r.push(u.subarray(p.at,p.end));continue}const [v,f]=x(u,p.body);a=Array.from("__riveLiftedStart",n=>n.charCodeAt(0));a=[...y(a.length),...a,0,...y(d)];const b=y(v+1),g=u.subarray(f,p.end);r.push(Uint8Array.from([7,...y(b.length+g.length+a.length),...b]),g,Uint8Array.from(a))}u=new Uint8Array(r.reduce((p,v)=>p+v.length,0));d=0;for(const p of r)u.set(p,d),d+=p.length;return u}const A=[253,12,...Array(16).fill(0)],D=q([...A]),G=q([...A,...A,253,128,2]);(function(u){function a(h,
471
+ for(const p of a){if(7!==p.id){r.push(u.subarray(p.at,p.end));continue}const [v,f]=x(u,p.body);a=Array.from("__riveLiftedStart",n=>n.charCodeAt(0));a=[...y(a.length),...a,0,...y(d)];const b=y(v+1),g=u.subarray(f,p.end);r.push(Uint8Array.from([7,...y(b.length+g.length+a.length),...b]),g,Uint8Array.from(a))}u=new Uint8Array(r.reduce((p,v)=>p+v.length,0));d=0;for(const p of r)u.set(p,d),d+=p.length;return u}const A=[253,12,...Array(16).fill(0)],C=q([...A]),G=q([...A,...A,253,128,2]);(function(u){function a(h,
472
472
  m){const w=c({kb:e(v.Bb,h.L),Z:v.Z,da:v.da,ua:v.ua,ca:v.ca,Ga:v.Ga,Da:v.Da,Ba:b},()=>{if(null===h.memory)throw Error("script passed memory to the host while its module was still starting");return h.memory});for(const t of WebAssembly.Module.imports(m))if("function"===t.kind){let B,F,H,K;(H=(B=w)[F=t.module]??(B[F]={}))[K=t.name]??(H[K]=l(t.module,t.name))}return w}function d(h,m){const w=v.da();for(const {name:t}of WebAssembly.Module.exports(m)){if(!t.startsWith("__rive"))continue;m=3*t.length+1;
473
473
  const B=v.ua(m);v.ab(t,B,m);v.exports._rive_web_vm_module_export(h.L.g,B)}v.ca(w)}function r(h,m){h.memory=m.exports.memory;h.Aa=null;const w=v.exports._rive_web_vm_booting;w(h.L.g);const t=v.da();try{m.exports.__riveLiftedStart?.()}catch(B){throw v.ca(t),h.L.j=null,B;}finally{w(0)}h.instance=m}async function p(h){try{const w=await WebAssembly.compile(z(h.Aa));if(0!==h.L.g){d(h,w);var m=await WebAssembly.instantiate(w,a(h,w));0!==h.L.g&&r(h,m)}}catch(w){h.error=String(w?.message??w)}}let v=null;const f=
474
- new Map,b={i:!1,l:0,la:0,ja:0,ka:0,ma:0},g=u.riveScriptingValidate??(h=>WebAssembly.validate(h));let n=null;const k={ib(h){v??=h},register(h,m){m=m.slice();var w=f.set;n??={Xa:g(D),Mb:g(G)};var t=n.Xa&&n.Mb||g(m)?null:n.Xa?"this browser lacks WebAssembly relaxed SIMD, so this file's scripts are off; bake with wasmSimd: on to support it":"this browser lacks WebAssembly SIMD, so this file's scripts are off; bake with wasmSimd: off to support it";w.call(f,h,{L:{g:h,j:null,h:!1,Ba:b},Aa:m,instance:null,
474
+ new Map,b={i:!1,l:0,la:0,ja:0,ka:0,ma:0},g=u.riveScriptingValidate??(h=>WebAssembly.validate(h));let n=null;const k={ib(h){v??=h},register(h,m){m=m.slice();var w=f.set;n??={Xa:g(C),Mb:g(G)};var t=n.Xa&&n.Mb||g(m)?null:n.Xa?"this browser lacks WebAssembly relaxed SIMD, so this file's scripts are off; bake with wasmSimd: on to support it":"this browser lacks WebAssembly SIMD, so this file's scripts are off; bake with wasmSimd: off to support it";w.call(f,h,{L:{g:h,j:null,h:!1,Ba:b},Aa:m,instance:null,
475
475
  memory:null,V:null,error:t,names:new Map})},release(h){const m=f.get(h);m&&(m.L.g=0,f.delete(h))},Jb(){const h=[];for(const m of f.values())if(null===m.instance&&null===m.error){let w;(w=m).V??(w.V=p(m));h.push(m.V)}return Promise.all(h)},start(h){h=f.get(h);if(!h)return"script module was never registered";if(null===h.instance&&null===h.error){if(null!==h.V)return"script module is still being prepared";try{const m=new WebAssembly.Module(z(h.Aa));d(h,m);r(h,new WebAssembly.Instance(m,a(h,m)))}catch(m){h.error=
476
476
  String(m?.message??m)}}return h.error},V(h){h=f.get(h);return null===h?.instance&&null===h.error&&null!==h.V?1:0},Ab(h,m){return"function"===typeof f.get(h)?.instance?.exports[v.Ja(m)]?1:0},call(h,m,w,t,B,F,H){h=f.get(h);if(!h||null===h.instance)return 1;let K=h.names.get(m);void 0===K&&(K=h.instance.exports[v.Ja(m)]??null,h.names.set(m,K));if("function"!==typeof K)return 1;try{m=t>>3;const P=K(...v.Pa().subarray(m,m+w));v.Pa()[B>>3]="number"===typeof P?P:0;return 0}catch(P){return h.L.j=null,v.ab(String(P?.message??
477
477
  P),F,H),h.L.h?3:2}},Kb(h,m){if(h=f.get(h))h.L.j=v.Ja(m)},read(h,m,w,t){h=f.get(h)?.memory;if(!h||m+t>h.buffer.byteLength)return 0;v.Z().set(new Uint8Array(h.buffer,m,t),w);b.i&&(b.ka+=t);return 1},write(h,m,w,t){h=f.get(h)?.memory;if(!h||m+t>h.buffer.byteLength)return 0;(new Uint8Array(h.buffer,m,t)).set(v.Z().subarray(w,w+t));b.i&&(b.ma+=t);return 1},Ch(h,m){h=f.get(h)?.memory;if(!h||m>=h.buffer.byteLength)return-1;h=(new Uint8Array(h.buffer)).indexOf(0,m);return 0>h?-1:h-m},Hb(h){return(h=f.get(h)?.memory)?
478
- h.buffer.byteLength>>>16:0},mb(h){b.i=!!h;b.l=0;b.la=0;b.ja=0;b.ka=0;b.ma=0},Cb(){return{hostCalls:b.l,bytesStaged:b.la,bytesCopiedOut:b.ja,bytesRead:b.ka,bytesWritten:b.ma}}};k.prepare=k.Jb;k.countHostCalls=k.mb;k.hostCallCounts=k.Cb;return u.riveScripting=k})(C)})();const ha=C.onRuntimeInitialized;
479
- C.onRuntimeInitialized=function(){function c(p){this.G=p;this.cb=p.getContext("2d");this.La=q;this.O=[];this.aa=0;this.clear=function(){console.assert(0==this.aa);this.O=[];x.delete(this)};this.save=function(){++this.aa;this.O.push(q.save.bind(q))};this.restore=function(){0<this.aa&&(this.O.push(q.restore.bind(q)),--this.aa)};this.transform=function(v){this.O.push(q.transform.bind(q,v))};this.align=function(v,f,b,g,n=1){this.O.push(q.align.bind(q,v,f,b,g,n))};this.flush=function(){console.assert(0==
478
+ h.buffer.byteLength>>>16:0},mb(h){b.i=!!h;b.l=0;b.la=0;b.ja=0;b.ka=0;b.ma=0},Cb(){return{hostCalls:b.l,bytesStaged:b.la,bytesCopiedOut:b.ja,bytesRead:b.ka,bytesWritten:b.ma}}};k.prepare=k.Jb;k.countHostCalls=k.mb;k.hostCallCounts=k.Cb;return u.riveScripting=k})(D)})();const ha=D.onRuntimeInitialized;
479
+ D.onRuntimeInitialized=function(){function c(p){this.G=p;this.cb=p.getContext("2d");this.La=q;this.O=[];this.aa=0;this.clear=function(){console.assert(0==this.aa);this.O=[];x.delete(this)};this.save=function(){++this.aa;this.O.push(q.save.bind(q))};this.restore=function(){0<this.aa&&(this.O.push(q.restore.bind(q)),--this.aa)};this.transform=function(v){this.O.push(q.transform.bind(q,v))};this.align=function(v,f,b,g,n=1){this.O.push(q.align.bind(q,v,f,b,g,n))};this.flush=function(){console.assert(0==
480
480
  this.aa);x.add(this);q.Ka||l()};this.bindContext=function(){const v=this.La;v&&v.T&&ia(v.T)};this["delete"]=function(){}}function e(p,v=!1){var f={alpha:!0,depth:v,stencil:v,antialias:v,premultipliedAlpha:!0,preserveDrawingBuffer:0,powerPreference:"high-performance",failIfMajorPerformanceCaveat:0,enableExtensionsByDefault:!1,explicitSwapControl:0,renderViaOffscreenBackBuffer:0};v=p.getContext("webgl2",f);if(!v)return null;f=ja(v,f);ia(f);const b=y(p.width,p.height);b.T=f;b.G=p;b.za=p.width;b.ya=p.height;
481
481
  b.P=v;b.jb=function(){this.T&&ia(this.T)};var g=b.delete;b.delete=function(){this.jb();g.call(this);var n=this.T;E===I[n]&&(E=null);"object"==typeof JSEvents&&JSEvents.Hh(I[n].F.canvas);I[n]?.F.canvas&&(I[n].F.canvas.bb=void 0);this.T=this.G=this.za=this.ya=this.P=I[n]=null};return b}function l(){if(q){var p=q.fb,v=0,f=0,b=0,g=Array(x.size),n=0;for(var k of x)k.X=Math.min(k.G.width,p),k.W=Math.min(k.G.height,p),k.wa=k.W*k.X,v=Math.max(v,k.X),f=Math.max(f,k.W),b+=k.wa,g[n++]=k;x.clear();if(!(0>=b)){v=
482
- 1<<(0>=v?0:32-Math.clz32(v-1));for(f=1<<(0>=f?0:32-Math.clz32(f-1));f*v<b;)v<=f?v*=2:f*=2;v=Math.min(v,p);v=Math.min(f,p);g.sort((w,t)=>t.wa-w.wa);b=new C.DynamicRectanizer(p);for(k=0;k<g.length;){b.reset(v,f);for(n=k;n<g.length;++n){var h=g[n],m=b.addRect(h.X,h.W);if(0>m){console.assert(n>k);break}h.ha=m&65535;h.ia=m>>16}h=D.push(b.drawWidth());m=G.push(b.drawHeight());console.assert(h>=b.drawWidth());console.assert(m>=b.drawHeight());console.assert(h<=p);console.assert(m<=p);q.G.width!=h&&(q.G.width=
483
- h);q.G.height!=m&&(q.G.height=m);q.clear();for(h=k;h<n;++h){m=g[h];q.saveClipRect(m.ha,m.ia,m.ha+m.X,m.ia+m.W);let w=new C.Mat2D;w.xx=m.X/m.G.width;w.yy=m.W/m.G.height;w.xy=w.yx=0;w.tx=m.ha;w.ty=m.ia;q.transform(w);for(const t of m.O)t();q.restoreClipRect();m.O=[]}for(q.flush();k<n;++k)h=g[k],m=h.cb,m.globalCompositeOperation="copy",m.drawImage(q.G,h.ha,h.ia,h.X,h.W,0,0,h.G.width,h.G.height);k=n}}}}ha&&ha();let q=null;const x=new Set,y=C.makeRenderer;C.makeRenderer=function(p,v){if(!q){function f(b){var g=
482
+ 1<<(0>=v?0:32-Math.clz32(v-1));for(f=1<<(0>=f?0:32-Math.clz32(f-1));f*v<b;)v<=f?v*=2:f*=2;v=Math.min(v,p);v=Math.min(f,p);g.sort((w,t)=>t.wa-w.wa);b=new D.DynamicRectanizer(p);for(k=0;k<g.length;){b.reset(v,f);for(n=k;n<g.length;++n){var h=g[n],m=b.addRect(h.X,h.W);if(0>m){console.assert(n>k);break}h.ha=m&65535;h.ia=m>>16}h=C.push(b.drawWidth());m=G.push(b.drawHeight());console.assert(h>=b.drawWidth());console.assert(m>=b.drawHeight());console.assert(h<=p);console.assert(m<=p);q.G.width!=h&&(q.G.width=
483
+ h);q.G.height!=m&&(q.G.height=m);q.clear();for(h=k;h<n;++h){m=g[h];q.saveClipRect(m.ha,m.ia,m.ha+m.X,m.ia+m.W);let w=new D.Mat2D;w.xx=m.X/m.G.width;w.yy=m.W/m.G.height;w.xy=w.yx=0;w.tx=m.ha;w.ty=m.ia;q.transform(w);for(const t of m.O)t();q.restoreClipRect();m.O=[]}for(q.flush();k<n;++k)h=g[k],m=h.cb,m.globalCompositeOperation="copy",m.drawImage(q.G,h.ha,h.ia,h.X,h.W,0,0,h.G.width,h.G.height);k=n}}}}ha&&ha();let q=null;const x=new Set,y=D.makeRenderer;D.makeRenderer=function(p,v){if(!q){function f(b){var g=
484
484
  document.createElement("canvas");g.width=1;g.height=1;q=e(g,b);if(!q)return null;q.Ka=!!q.P.getExtension("WEBGL_shader_pixel_local_storage");q.fb=Math.min(q.P.getParameter(q.P.MAX_RENDERBUFFER_SIZE),q.P.getParameter(q.P.MAX_TEXTURE_SIZE));q.xa=!q.Ka;if(b=q.P.getExtension("WEBGL_debug_renderer_info"))g=q.P.getParameter(b.UNMASKED_RENDERER_WEBGL),q.P.getParameter(b.UNMASKED_VENDOR_WEBGL).includes("Google")&&g.includes("ANGLE Metal Renderer")&&(q.xa=!1);return q}q=f(!0);if(!q)throw"Unable to create WebGL context, your environment may not support WebGL. Try out @rive-app/canvas as an alternative.";
485
- q.xa||(q=f(!1))}return v?new c(p):e(p,q.xa)};const z=C.Artboard.prototype["delete"];C.Artboard.prototype["delete"]=function(){this.hb=!0;z.call(this)};const A=C.Artboard.prototype.draw;C.Artboard.prototype.draw=function(p){p.O?p.O.push(()=>{this.hb||A.call(this,p.La)}):A.call(this,p)};const D=new ea,G=new ea,u=new da;C.requestAnimationFrame=u.requestAnimationFrame.bind(u);C.cancelAnimationFrame=u.cancelAnimationFrame.bind(u);C.enableFPSCounter=u.qb.bind(u);u.Ra=l;C.resolveAnimationFrame=l;let a=C.load;
486
- C.load=function(p,v,f=!0,b=null){const g=new C.FallbackFileAssetLoader;void 0!==v&&g.addLoader(v);f&&(v=new C.CDNFileAssetLoader(b),g.addLoader(v));return C.startFileScripts(a(p,g,b??null))};const d=C.WebGL2Renderer.prototype.clear;C.WebGL2Renderer.prototype.clear=function(){ia(this.T);const p=this.G;if(this.za!=p.width||this.ya!=p.height)this.resize(p.width,p.height),this.za=p.width,this.ya=p.height;d.call(this)};C.decodeImage=function(p,v,f=null){p=C.decodeWebGL2Image(p,f??null);v(p)};let r=C.Renderer.prototype.align;
487
- C.Renderer.prototype.align=function(p,v,f,b,g=1){r.call(this,p,v,f,b,g)}};var ka="./this.program";ca&&(_scriptName=self.location.href);var la="",ma,na;
485
+ q.xa||(q=f(!1))}return v?new c(p):e(p,q.xa)};const z=D.Artboard.prototype["delete"];D.Artboard.prototype["delete"]=function(){this.hb=!0;z.call(this)};const A=D.Artboard.prototype.draw;D.Artboard.prototype.draw=function(p){p.O?p.O.push(()=>{this.hb||A.call(this,p.La)}):A.call(this,p)};const C=new ea,G=new ea,u=new da;D.requestAnimationFrame=u.requestAnimationFrame.bind(u);D.cancelAnimationFrame=u.cancelAnimationFrame.bind(u);D.enableFPSCounter=u.qb.bind(u);u.Ra=l;D.resolveAnimationFrame=l;let a=D.load;
486
+ D.load=function(p,v,f=!0,b=null){const g=new D.FallbackFileAssetLoader;void 0!==v&&g.addLoader(v);f&&(v=new D.CDNFileAssetLoader(b),g.addLoader(v));return D.startFileScripts(a(p,g,b??null))};const d=D.WebGL2Renderer.prototype.clear;D.WebGL2Renderer.prototype.clear=function(){ia(this.T);const p=this.G;if(this.za!=p.width||this.ya!=p.height)this.resize(p.width,p.height),this.za=p.width,this.ya=p.height;d.call(this)};D.decodeImage=function(p,v,f=null){p=D.decodeWebGL2Image(p,f??null);v(p)};let r=D.Renderer.prototype.align;
487
+ D.Renderer.prototype.align=function(p,v,f,b,g=1){r.call(this,p,v,f,b,g)}};var ka="./this.program";ca&&(_scriptName=self.location.href);var la="",ma,na;
488
488
  if(aa||ca){try{la=(new URL(".",_scriptName)).href}catch{}ca&&(na=c=>{var e=new XMLHttpRequest;e.open("GET",c,!1);e.responseType="arraybuffer";e.send(null);return new Uint8Array(e.response)});ma=async c=>{if(oa(c))return new Promise((l,q)=>{var x=new XMLHttpRequest;x.open("GET",c,!0);x.responseType="arraybuffer";x.onload=()=>{200==x.status||0==x.status&&x.response?l(x.response):q(x.status)};x.onerror=q;x.send(null)});var e=await fetch(c,{credentials:"same-origin"});if(e.ok)return e.arrayBuffer();throw Error(e.status+
489
- " : "+e.url);}}var pa=console.log.bind(console),qa=console.error.bind(console),ra,sa=!1,oa=c=>c.startsWith("file://"),ta,ua,va,J,wa,xa,L,M,ya,za,Aa=!1;function Ba(){var c=Ca.buffer;C.HEAP8=va=new Int8Array(c);wa=new Int16Array(c);C.HEAPU8=J=new Uint8Array(c);C.HEAPU16=xa=new Uint16Array(c);C.HEAP32=L=new Int32Array(c);C.HEAPU32=M=new Uint32Array(c);C.HEAPF32=ya=new Float32Array(c);za=new Float64Array(c)}
490
- function Da(c){C.onAbort?.(c);c="Aborted("+c+")";qa(c);sa=!0;c=new WebAssembly.RuntimeError(c+". Build with -sASSERTIONS for more info.");ua?.(c);throw c;}var Ea;async function Fa(c){if(!ra)try{var e=await ma(c);return new Uint8Array(e)}catch{}if(c==Ea&&ra)c=new Uint8Array(ra);else if(na)c=na(c);else throw"both async and sync fetching of the wasm failed";return c}
489
+ " : "+e.url);}}var pa=console.log.bind(console),qa=console.error.bind(console),ra,sa=!1,oa=c=>c.startsWith("file://"),ta,ua,va,J,wa,xa,L,M,ya,za,Aa=!1;function Ba(){var c=Ca.buffer;D.HEAP8=va=new Int8Array(c);wa=new Int16Array(c);D.HEAPU8=J=new Uint8Array(c);D.HEAPU16=xa=new Uint16Array(c);D.HEAP32=L=new Int32Array(c);D.HEAPU32=M=new Uint32Array(c);D.HEAPF32=ya=new Float32Array(c);za=new Float64Array(c)}
490
+ function Da(c){D.onAbort?.(c);c="Aborted("+c+")";qa(c);sa=!0;c=new WebAssembly.RuntimeError(c+". Build with -sASSERTIONS for more info.");ua?.(c);throw c;}var Ea;async function Fa(c){if(!ra)try{var e=await ma(c);return new Uint8Array(e)}catch{}if(c==Ea&&ra)c=new Uint8Array(ra);else if(na)c=na(c);else throw"both async and sync fetching of the wasm failed";return c}
491
491
  async function Ga(c,e){try{var l=await Fa(c);return await WebAssembly.instantiate(l,e)}catch(q){qa(`failed to asynchronously prepare wasm: ${q}`),Da(q)}}async function Ha(c){var e=Ea;if(!ra&&!oa(e))try{var l=fetch(e,{credentials:"same-origin"});return await WebAssembly.instantiateStreaming(l,c)}catch(q){qa(`wasm streaming compile failed: ${q}`),qa("falling back to ArrayBuffer instantiation")}return Ga(e,c)}
492
- var N,Ia,Ja=c=>{for(;0<c.length;)c.shift()(C)},Ka=[],La=[],Ma=()=>{var c=C.preRun.shift();La.push(c)},Oa=c=>Na(c),Qa=()=>Pa(),Ra=globalThis.TextDecoder&&new TextDecoder,Sa=(c,e,l,q)=>{l=e+l;if(q)return l;for(;c[e]&&!(e>=l);)++e;return e},Ta=(c,e=0,l,q)=>{l=Sa(c,e,l,q);if(16<l-e&&c.buffer&&Ra)return Ra.decode(c.subarray(e,l));for(q="";e<l;){var x=c[e++];if(x&128){var y=c[e++]&63;if(192==(x&224))q+=String.fromCharCode((x&31)<<6|y);else{var z=c[e++]&63;x=224==(x&240)?(x&15)<<12|y<<6|z:(x&7)<<18|y<<12|
492
+ var N,Ia,Ja=c=>{for(;0<c.length;)c.shift()(D)},Ka=[],La=[],Ma=()=>{var c=D.preRun.shift();La.push(c)},Oa=c=>Na(c),Qa=()=>Pa(),Ra=globalThis.TextDecoder&&new TextDecoder,Sa=(c,e,l,q)=>{l=e+l;if(q)return l;for(;c[e]&&!(e>=l);)++e;return e},Ta=(c,e=0,l,q)=>{l=Sa(c,e,l,q);if(16<l-e&&c.buffer&&Ra)return Ra.decode(c.subarray(e,l));for(q="";e<l;){var x=c[e++];if(x&128){var y=c[e++]&63;if(192==(x&224))q+=String.fromCharCode((x&31)<<6|y);else{var z=c[e++]&63;x=224==(x&240)?(x&15)<<12|y<<6|z:(x&7)<<18|y<<12|
493
493
  z<<6|c[e++]&63;65536>x?q+=String.fromCharCode(x):(x-=65536,q+=String.fromCharCode(55296|x>>10,56320|x&1023))}}else q+=String.fromCharCode(x)}return q},Ua=(c,e)=>Object.defineProperty(e,"name",{value:c}),Va=[],Wa=[0,1,,1,null,1,!0,1,!1,1],O=class extends Error{constructor(c){super(c);this.name="BindingError"}},Q=c=>{if(!c)throw new O(`Cannot use deleted val. handle = ${c}`);return Wa[c]},Xa=c=>{switch(c){case void 0:return 2;case null:return 4;case !0:return 6;case !1:return 8;default:const e=Va.pop()||
494
494
  Wa.length;Wa[e]=c;Wa[e+1]=1;return e}};class Ya extends Error{}
495
495
  var R=c=>{for(var e="";;){var l=J[c++];if(!l)return e;e+=String.fromCharCode(l)}},Za={},$a=(c,e)=>{if(void 0===e)throw new O("ptr should not be undefined");for(;c.C;)e=c.fa(e),c=c.C;return e},ab={},db=c=>{c=bb(c);var e=R(c);cb(c);return e},eb=(c,e)=>{var l=ab[c];if(void 0===l)throw c=`${e} has unknown type ${db(c)}`,new O(c);return l},fb=()=>{},gb=!1,hb=c=>{if(!globalThis.FinalizationRegistry)return hb=e=>e,c;gb=new FinalizationRegistry(e=>{e=e.m;--e.count.value;0===e.count.value&&(e.D?e.J.N(e.D):
496
496
  e.v.o.N(e.u))});hb=e=>{var l=e.m;l.D&&gb.register(e,{m:l},e);return e};fb=e=>{gb.unregister(e)};return hb(c)},ib={},jb=c=>{for(;c.length;){var e=c.pop();c.pop()(e)}};function kb(c){return this.s(M[c>>2])}
497
- var lb={},mb={},nb=class extends Error{constructor(c){super(c);this.name="InternalError"}},T=(c,e,l)=>{function q(A){A=l(A);if(A.length!==c.length)throw new nb("Mismatched type converter count");for(var D=0;D<c.length;++D)S(c[D],A[D])}c.forEach(A=>mb[A]=e);var x=Array(e.length),y=[],z=0;for(let [A,D]of e.entries())ab.hasOwnProperty(D)?x[A]=ab[D]:(y.push(D),lb.hasOwnProperty(D)||(lb[D]=[]),lb[D].push(()=>{x[A]=ab[D];++z;z===y.length&&q(x)}));0===y.length&&q(x)};
497
+ var lb={},mb={},nb=class extends Error{constructor(c){super(c);this.name="InternalError"}},T=(c,e,l)=>{function q(A){A=l(A);if(A.length!==c.length)throw new nb("Mismatched type converter count");for(var C=0;C<c.length;++C)S(c[C],A[C])}c.forEach(A=>mb[A]=e);var x=Array(e.length),y=[],z=0;for(let [A,C]of e.entries())ab.hasOwnProperty(C)?x[A]=ab[C]:(y.push(C),lb.hasOwnProperty(C)||(lb[C]=[]),lb[C].push(()=>{x[A]=ab[C];++z;z===y.length&&q(x)}));0===y.length&&q(x)};
498
498
  function ob(c,e,l={}){var q=e.name;if(!c)throw new O(`type "${q}" must have a positive integer typeid pointer`);if(ab.hasOwnProperty(c)){if(l.Db)return;throw new O(`Cannot register type '${q}' twice`);}ab[c]=e;delete mb[c];lb.hasOwnProperty(c)&&(e=lb[c],delete lb[c],e.forEach(x=>x()))}function S(c,e,l={}){return ob(c,e,l)}var pb=c=>{throw new O(c.m.v.o.name+" instance already deleted");},qb=[];function rb(){}
499
- var sb={},tb=(c,e,l)=>{if(void 0===c[e].A){var q=c[e];c[e]=function(...x){if(!c[e].A.hasOwnProperty(x.length))throw new O(`Function '${l}' called with an invalid number of arguments (${x.length}) - expects one of (${c[e].A})!`);return c[e].A[x.length].apply(this,x)};c[e].A=[];c[e].A[q.R]=q}},ub=(c,e,l)=>{if(C.hasOwnProperty(c)){if(void 0===l||void 0!==C[c].A&&void 0!==C[c].A[l])throw new O(`Cannot register public name '${c}' twice`);tb(C,c,c);if(C[c].A.hasOwnProperty(l))throw new O(`Cannot register multiple overloads of a function with the same number of arguments (${l})!`);
500
- C[c].A[l]=e}else C[c]=e,C[c].R=l},vb=c=>{c=c.replace(/[^a-zA-Z0-9_]/g,"$");var e=c.charCodeAt(0);return 48<=e&&57>=e?`_${c}`:c};function wb(c,e,l,q,x,y,z,A){this.name=c;this.constructor=e;this.M=l;this.N=q;this.C=x;this.vb=y;this.fa=z;this.ob=A;this.Ta=[]}
499
+ var sb={},tb=(c,e,l)=>{if(void 0===c[e].A){var q=c[e];c[e]=function(...x){if(!c[e].A.hasOwnProperty(x.length))throw new O(`Function '${l}' called with an invalid number of arguments (${x.length}) - expects one of (${c[e].A})!`);return c[e].A[x.length].apply(this,x)};c[e].A=[];c[e].A[q.R]=q}},ub=(c,e,l)=>{if(D.hasOwnProperty(c)){if(void 0===l||void 0!==D[c].A&&void 0!==D[c].A[l])throw new O(`Cannot register public name '${c}' twice`);tb(D,c,c);if(D[c].A.hasOwnProperty(l))throw new O(`Cannot register multiple overloads of a function with the same number of arguments (${l})!`);
500
+ D[c].A[l]=e}else D[c]=e,D[c].R=l},vb=c=>{c=c.replace(/[^a-zA-Z0-9_]/g,"$");var e=c.charCodeAt(0);return 48<=e&&57>=e?`_${c}`:c};function wb(c,e,l,q,x,y,z,A){this.name=c;this.constructor=e;this.M=l;this.N=q;this.C=x;this.vb=y;this.fa=z;this.ob=A;this.Ta=[]}
501
501
  var xb=(c,e,l)=>{for(;e!==l;){if(!e.fa)throw new O(`Expected null or instance of ${l.name}, got an instance of ${e.name}`);c=e.fa(c);e=e.C}return c},yb=c=>{if(null===c)return"null";var e=typeof c;return"object"===e||"array"===e||"function"===e?c.toString():""+c};
502
502
  function zb(c,e){if(null===e){if(this.Ea)throw new O(`null is not a valid ${this.name}`);return 0}if(!e.m)throw new O(`Cannot pass "${yb(e)}" as a ${this.name}`);if(!e.m.u)throw new O(`Cannot pass deleted object as a pointer of type ${this.name}`);return xb(e.m.u,e.m.v.o,this.o)}
503
503
  function Ab(c,e){if(null===e){if(this.Ea)throw new O(`null is not a valid ${this.name}`);if(this.pa){var l=this.Ha();null!==c&&c.push(this.N,l);return l}return 0}if(!e||!e.m)throw new O(`Cannot pass "${yb(e)}" as a ${this.name}`);if(!e.m.u)throw new O(`Cannot pass deleted object as a pointer of type ${this.name}`);if(!this.oa&&e.m.v.oa)throw new O(`Cannot convert argument of type ${e.m.J?e.m.J.name:e.m.v.name} to parameter type ${this.name}`);l=xb(e.m.u,e.m.v.o,this.o);if(this.pa){if(void 0===e.m.D)throw new O("Passing raw pointer to smart pointer is illegal");
504
504
  switch(this.Bh){case 0:if(e.m.J===this)l=e.m.D;else throw new O(`Cannot convert argument of type ${e.m.J?e.m.J.name:e.m.v.name} to parameter type ${this.name}`);break;case 1:l=e.m.D;break;case 2:if(e.m.J===this)l=e.m.D;else{var q=e.clone();l=this.Lb(l,Xa(()=>q["delete"]()));null!==c&&c.push(this.N,l)}break;default:throw new O("Unsupported sharing policy");}}return l}
505
505
  function Bb(c,e){if(null===e){if(this.Ea)throw new O(`null is not a valid ${this.name}`);return 0}if(!e.m)throw new O(`Cannot pass "${yb(e)}" as a ${this.name}`);if(!e.m.u)throw new O(`Cannot pass deleted object as a pointer of type ${this.name}`);if(e.m.v.oa)throw new O(`Cannot convert argument of type ${e.m.v.name} to parameter type ${this.name}`);return xb(e.m.u,e.m.v.o,this.o)}
506
506
  var Cb=(c,e,l)=>{if(e===l)return c;if(void 0===l.C)return null;c=Cb(c,e,l.C);return null===c?null:l.ob(c)},Db=(c,e)=>{e=$a(c,e);return Za[e]},Eb=(c,e)=>{if(!e.v||!e.u)throw new nb("makeClassHandle requires ptr and ptrType");if(!!e.J!==!!e.D)throw new nb("Both smartPtrType and smartPtr must be specified");e.count={value:1};return hb(Object.create(c,{m:{value:e,writable:!0}}))};
507
- function Fb(c,e,l,q,x,y,z,A,D,G,u){this.name=c;this.o=e;this.Ea=l;this.oa=q;this.pa=x;this.Ib=y;this.Bh=z;this.Va=A;this.Ha=D;this.Lb=G;this.N=u;x||void 0!==e.C?this.B=Ab:(this.B=q?zb:Bb,this.H=null)}
508
- var Gb=(c,e,l)=>{if(!C.hasOwnProperty(c))throw new nb("Replacing nonexistent public symbol");void 0!==C[c].A&&void 0!==l?C[c].A[l]=e:(C[c]=e,C[c].R=l)},U={},Ib=(c,e,l=[])=>{c.includes("j")?(c=c.replace(/p/g,"i"),e=(0,U[c])(e,...l)):e=Hb.get(e)(...l);return e},Jb=(c,e)=>(...l)=>Ib(c,e,l),V=(c,e)=>{c=R(c);var l=c.includes("j")?Jb(c,e):Hb.get(e);if("function"!=typeof l)throw new O(`unknown function pointer with signature ${c}: ${e}`);return l};class Kb extends Error{}
507
+ function Fb(c,e,l,q,x,y,z,A,C,G,u){this.name=c;this.o=e;this.Ea=l;this.oa=q;this.pa=x;this.Ib=y;this.Bh=z;this.Va=A;this.Ha=C;this.Lb=G;this.N=u;x||void 0!==e.C?this.B=Ab:(this.B=q?zb:Bb,this.H=null)}
508
+ var Gb=(c,e,l)=>{if(!D.hasOwnProperty(c))throw new nb("Replacing nonexistent public symbol");void 0!==D[c].A&&void 0!==l?D[c].A[l]=e:(D[c]=e,D[c].R=l)},U={},Ib=(c,e,l=[])=>{c.includes("j")?(c=c.replace(/p/g,"i"),e=(0,U[c])(e,...l)):e=Hb.get(e)(...l);return e},Jb=(c,e)=>(...l)=>Ib(c,e,l),V=(c,e)=>{c=R(c);var l=c.includes("j")?Jb(c,e):Hb.get(e);if("function"!=typeof l)throw new O(`unknown function pointer with signature ${c}: ${e}`);return l};class Kb extends Error{}
509
509
  var Lb=(c,e)=>{function l(y){x[y]||ab[y]||(mb[y]?mb[y].forEach(l):(q.push(y),x[y]=!0))}var q=[],x={};e.forEach(l);throw new Kb(`${c}: `+q.map(db).join([", "]));};function Mb(c){for(var e=1;e<c.length;++e)if(null!==c[e]&&void 0===c[e].H)return!0;return!1}
510
- function Nb(c,e,l,q,x){var y=e.length;if(2>y)throw new O("argTypes array size mismatch! Must at least get return value and 'this' types!");var z=null!==e[1]&&null!==l,A=Mb(e),D=!e[0].Fb,G=y-2,u=Array(G),a=[],d=[];return Ua(c,function(...r){d.length=0;a.length=z?2:1;a[0]=x;if(z){var p=e[1].B(d,this);a[1]=p}for(var v=0;v<G;++v)u[v]=e[v+2].B(d,r[v]),a.push(u[v]);r=q(...a);if(A)jb(d);else for(v=z?1:2;v<e.length;v++){var f=1===v?p:u[v-2];null!==e[v].H&&e[v].H(f)}p=D?e[0].s(r):void 0;return p})}
510
+ function Nb(c,e,l,q,x){var y=e.length;if(2>y)throw new O("argTypes array size mismatch! Must at least get return value and 'this' types!");var z=null!==e[1]&&null!==l,A=Mb(e),C=!e[0].Fb,G=y-2,u=Array(G),a=[],d=[];return Ua(c,function(...r){d.length=0;a.length=z?2:1;a[0]=x;if(z){var p=e[1].B(d,this);a[1]=p}for(var v=0;v<G;++v)u[v]=e[v+2].B(d,r[v]),a.push(u[v]);r=q(...a);if(A)jb(d);else for(v=z?1:2;v<e.length;v++){var f=1===v?p:u[v-2];null!==e[v].H&&e[v].H(f)}p=C?e[0].s(r):void 0;return p})}
511
511
  var Ob=(c,e)=>{for(var l=[],q=0;q<c;q++)l.push(M[e+4*q>>2]);return l},Pb=c=>{c=c.trim();const e=c.indexOf("(");return-1===e?c:c.slice(0,e)},Qb=(c,e,l)=>{if(!(c instanceof Object))throw new O(`${l} with invalid "this": ${c}`);if(!(c instanceof e.o.constructor))throw new O(`${l} incompatible with "this" of type ${c.constructor.name}`);if(!c.m.u)throw new O(`cannot call emscripten binding method ${l} on deleted object`);return xb(c.m.u,c.m.v.o,e.o)},Rb=c=>{9<c&&0===--Wa[c+1]&&(Wa[c]=void 0,Va.push(c))},
512
512
  Sb={name:"emscripten::val",s:c=>{var e=Q(c);Rb(c);return e},B:(c,e)=>Xa(e),I:kb,H:null},Tb=(c,e,l)=>{switch(e){case 1:return l?function(q){return this.s(va[q])}:function(q){return this.s(J[q])};case 2:return l?function(q){return this.s(wa[q>>1])}:function(q){return this.s(xa[q>>1])};case 4:return l?function(q){return this.s(L[q>>2])}:function(q){return this.s(M[q>>2])};default:throw new TypeError(`invalid integer width (${e}): ${c}`);}},Ub=(c,e)=>{switch(e){case 4:return function(l){return this.s(ya[l>>
513
513
  2])};case 8:return function(l){return this.s(za[l>>3])};default:throw new TypeError(`invalid float width (${e}): ${c}`);}},Vb=(c,e,l)=>{switch(e){case 1:return l?q=>va[q]:q=>J[q];case 2:return l?q=>wa[q>>1]:q=>xa[q>>1];case 4:return l?q=>L[q>>2]:q=>M[q>>2];default:throw new TypeError(`invalid integer width (${e}): ${c}`);}},Wb=(c,e,l)=>{var q=J;if(!(0<l))return 0;var x=e;l=e+l-1;for(var y=0;y<c.length;++y){var z=c.codePointAt(y);if(127>=z){if(e>=l)break;q[e++]=z}else if(2047>=z){if(e+1>=l)break;q[e++]=
@@ -516,7 +516,7 @@ for(l="";c<e;++c)l+=String.fromCharCode(xa[c]);return l},$b=(c,e,l)=>{l??=214748
516
516
  2]=0;return e-q},dc=c=>{for(var e=0,l=0;l<c.length;++l)65535<c.codePointAt(l)&&l++,e+=4;return e},ec=[],fc=c=>{var e=ec.length;ec.push(c);return e},gc=(c,e)=>{for(var l=Array(c),q=0;q<c;++q)l[q]=eb(M[e+4*q>>2],`parameter ${q}`);return l},hc={},ic=c=>{var e=hc[c];return void 0===e?R(c):e},jc=[0,31,60,91,121,152,182,213,244,274,305,335],kc=[0,31,59,90,120,151,181,212,243,273,304,334],lc=[],mc=c=>{c.Eh=c.getExtension("WEBGL_draw_instanced_base_vertex_base_instance")},nc=c=>{c.Gh=c.getExtension("WEBGL_multi_draw_instanced_base_vertex_base_instance")},
517
517
  W,oc=c=>{var e="EXT_color_buffer_float EXT_conservative_depth EXT_disjoint_timer_query_webgl2 EXT_texture_norm16 NV_shader_noperspective_interpolation WEBGL_clip_cull_distance EXT_clip_control EXT_color_buffer_half_float EXT_depth_clamp EXT_float_blend EXT_polygon_offset_clamp EXT_texture_compression_bptc EXT_texture_compression_rgtc EXT_texture_filter_anisotropic KHR_parallel_shader_compile OES_texture_float_linear WEBGL_blend_func_extended WEBGL_compressed_texture_astc WEBGL_compressed_texture_etc WEBGL_compressed_texture_etc1 WEBGL_compressed_texture_s3tc WEBGL_compressed_texture_s3tc_srgb WEBGL_debug_renderer_info WEBGL_debug_shaders WEBGL_lose_context WEBGL_multi_draw WEBGL_polygon_mode".split(" ");
518
518
  return(c.getSupportedExtensions()||[]).filter(l=>e.includes(l))},pc=1,qc=[],X=[],rc=[],sc=[],tc=[],Y=[],uc=[],I=[],vc=[],wc={},xc={},yc=4,zc=0,Ac=c=>{for(var e=pc++,l=c.length;l<e;l++)c[l]=null;return e},Bc=(c,e,l,q)=>{for(var x=0;x<c;x++){var y=W[l](),z=y&&Ac(q);y?(y.name=z,q[z]=y):Z||=1282;L[e+4*x>>2]=z}},ja=(c,e)=>{var l=Ac(I),q={handle:l,attributes:e,version:e.Fh,F:c};c.canvas&&(c.canvas.bb=q);I[l]=q;if("undefined"==typeof e.pb||e.pb)if((c=q)||(c=E),!c.Eb){c.Eb=!0;e=c.F;e.Gb=e.getExtension("WEBGL_multi_draw");
519
- e.sb=e.getExtension("EXT_polygon_offset_clamp");e.rb=e.getExtension("EXT_clip_control");e.Dh=e.getExtension("WEBGL_polygon_mode");mc(e);nc(e);2<=c.version&&(e.Na=e.getExtension("EXT_disjoint_timer_query_webgl2"));if(2>c.version||!e.Na)e.Na=e.getExtension("EXT_disjoint_timer_query");for(var x of oc(e))x.includes("lose_context")||x.includes("debug")||e.getExtension(x)}return l},ia=c=>{E=I[c];C.ctx=W=E?.F;return!(c&&!W)},Z,E,Cc={},Ec=()=>{if(!Dc){var c={USER:"web_user",LOGNAME:"web_user",PATH:"/",PWD:"/",
519
+ e.sb=e.getExtension("EXT_polygon_offset_clamp");e.rb=e.getExtension("EXT_clip_control");e.Dh=e.getExtension("WEBGL_polygon_mode");mc(e);nc(e);2<=c.version&&(e.Na=e.getExtension("EXT_disjoint_timer_query_webgl2"));if(2>c.version||!e.Na)e.Na=e.getExtension("EXT_disjoint_timer_query");for(var x of oc(e))x.includes("lose_context")||x.includes("debug")||e.getExtension(x)}return l},ia=c=>{E=I[c];D.ctx=W=E?.F;return!(c&&!W)},Z,E,Cc={},Ec=()=>{if(!Dc){var c={USER:"web_user",LOGNAME:"web_user",PATH:"/",PWD:"/",
520
520
  HOME:"/home/web_user",LANG:(globalThis.navigator?.language??"C").replace("-","_")+".UTF-8",_:ka||"./this.program"},e;for(e in Cc)void 0===Cc[e]?delete c[e]:c[e]=Cc[e];var l=[];for(e in c)l.push(`${e}=${c[e]}`);Dc=l}return Dc},Dc,Fc=[null,[],[]],Gc=[],Hc=()=>{var c=oc(W);return c=c.concat(c.map(e=>"GL_"+e))},Ic=(c,e,l)=>{if(e){var q=void 0;switch(c){case 36346:q=1;break;case 36344:0!=l&&1!=l&&(Z||=1280);return;case 34814:case 36345:q=0;break;case 34466:var x=W.getParameter(34467);q=x?x.length:0;break;
521
521
  case 33309:if(2>E.version){Z||=1282;return}q=Hc().length;break;case 33307:case 33308:if(2>E.version){Z||=1280;return}q=33307==c?3:0}if(void 0===q)switch(x=W.getParameter(c),typeof x){case "number":q=x;break;case "boolean":q=x?1:0;break;case "string":Z||=1280;return;case "object":if(null===x)switch(c){case 34964:case 35725:case 34965:case 36006:case 36007:case 32873:case 34229:case 36662:case 36663:case 35053:case 35055:case 36010:case 35097:case 35869:case 32874:case 36389:case 35983:case 35368:case 34068:q=
522
522
  0;break;default:Z||=1280;return}else{if(x instanceof Float32Array||x instanceof Uint32Array||x instanceof Int32Array||x instanceof Array){for(c=0;c<x.length;++c)switch(l){case 0:L[e+4*c>>2]=x[c];break;case 2:ya[e+4*c>>2]=x[c];break;case 4:va[e+c]=x[c]?1:0}return}try{q=x.name|0}catch(y){Z||=1280;qa(`GL_INVALID_ENUM in glGet${l}v: Unknown object returned from WebGL getParameter(${c})! (error: ${y})`);return}}break;default:Z||=1280;qa(`GL_INVALID_ENUM in glGet${l}v: Native code calling glGet${l}v(${c}) and it returns ${x} of type ${typeof x}!`);
@@ -524,69 +524,68 @@ return}switch(l){case 1:l=q;M[e>>2]=l;M[e+4>>2]=(l-M[e>>2])/4294967296;break;cas
524
524
  (()=>{let c=rb.prototype;Object.assign(c,{isAliasOf:function(l){if(!(this instanceof rb&&l instanceof rb))return!1;var q=this.m.v.o,x=this.m.u;l.m=l.m;var y=l.m.v.o;for(l=l.m.u;q.C;)x=q.fa(x),q=q.C;for(;y.C;)l=y.fa(l),y=y.C;return q===y&&x===l},clone:function(){this.m.u||pb(this);if(this.m.$)return this.m.count.value+=1,this;var l=hb,q=Object,x=q.create,y=Object.getPrototypeOf(this),z=this.m;l=l(x.call(q,y,{m:{value:{count:z.count,ba:z.ba,$:z.$,u:z.u,v:z.v,D:z.D,J:z.J}}}));l.m.count.value+=1;l.m.ba=
525
525
  !1;return l},["delete"](){this.m.u||pb(this);if(this.m.ba&&!this.m.$)throw new O("Object already scheduled for deletion");fb(this);var l=this.m;--l.count.value;0===l.count.value&&(l.D?l.J.N(l.D):l.v.o.N(l.u));this.m.$||(this.m.D=void 0,this.m.u=void 0)},isDeleted:function(){return!this.m.u},deleteLater:function(){this.m.u||pb(this);if(this.m.ba&&!this.m.$)throw new O("Object already scheduled for deletion");qb.push(this);this.m.ba=!0;return this}});const e=Symbol.dispose;e&&(c[e]=c["delete"])})();
526
526
  Object.assign(Fb.prototype,{wb(c){this.Va&&(c=this.Va(c));return c},Ma(c){this.N?.(c)},I:kb,s:function(c){function e(){return this.pa?Eb(this.o.M,{v:this.Ib,u:l,J:this,D:c}):Eb(this.o.M,{v:this,u:c})}var l=this.wb(c);if(!l)return this.Ma(c),null;var q=Db(this.o,l);if(void 0!==q){if(0===q.m.count.value)return q.m.u=l,q.m.D=c,q.clone();q=q.clone();this.Ma(c);return q}q=this.o.vb(l);q=sb[q];if(!q)return e.call(this);q=this.oa?q.lb:q.pointerType;var x=Cb(l,this.o,q.o);return null===x?e.call(this):this.pa?
527
- Eb(q.o.M,{v:q,u:x,J:this,D:c}):Eb(q.o.M,{v:q,u:x})}});for(let c=0;32>c;++c)Gc.push(Array(c));C.print&&(pa=C.print);C.printErr&&(qa=C.printErr);C.wasmBinary&&(ra=C.wasmBinary);C.thisProgram&&(ka=C.thisProgram);if(C.preInit)for("function"==typeof C.preInit&&(C.preInit=[C.preInit]);0<C.preInit.length;)C.preInit.shift()();
528
- var Sc={343395:(c,e,l,q,x)=>{if("undefined"===typeof window||void 0===(window.AudioContext||window.webkitAudioContext))return 0;if("undefined"===typeof window.miniaudio){window.miniaudio={referenceCount:0};window.miniaudio.device_type={};window.miniaudio.device_type.playback=c;window.miniaudio.device_type.capture=e;window.miniaudio.device_type.duplex=l;window.miniaudio.device_state={};window.miniaudio.device_state.stopped=q;window.miniaudio.device_state.started=x;let y=window.miniaudio;y.devices=
527
+ Eb(q.o.M,{v:q,u:x,J:this,D:c}):Eb(q.o.M,{v:q,u:x})}});for(let c=0;32>c;++c)Gc.push(Array(c));D.print&&(pa=D.print);D.printErr&&(qa=D.printErr);D.wasmBinary&&(ra=D.wasmBinary);D.thisProgram&&(ka=D.thisProgram);if(D.preInit)for("function"==typeof D.preInit&&(D.preInit=[D.preInit]);0<D.preInit.length;)D.preInit.shift()();
528
+ var Sc={346227:(c,e,l,q,x)=>{if("undefined"===typeof window||void 0===(window.AudioContext||window.webkitAudioContext))return 0;if("undefined"===typeof window.miniaudio){window.miniaudio={referenceCount:0};window.miniaudio.device_type={};window.miniaudio.device_type.playback=c;window.miniaudio.device_type.capture=e;window.miniaudio.device_type.duplex=l;window.miniaudio.device_state={};window.miniaudio.device_state.stopped=q;window.miniaudio.device_state.started=x;let y=window.miniaudio;y.devices=
529
529
  [];y.track_device=function(z){for(var A=0;A<y.devices.length;++A)if(null==y.devices[A])return y.devices[A]=z,A;y.devices.push(z);return y.devices.length-1};y.untrack_device_by_index=function(z){for(y.devices[z]=null;0<y.devices.length;)if(null==y.devices[y.devices.length-1])y.devices.pop();else break};y.untrack_device=function(z){for(var A=0;A<y.devices.length;++A)if(y.devices[A]==z)return y.untrack_device_by_index(A)};y.get_device_by_index=function(z){return y.devices[z]};y.unlock_event_types=["touchend",
530
- "click"];y.unlock=function(){for(var z=0;z<y.devices.length;++z){var A=y.devices[z];null!=A&&null!=A.K&&A.state===y.device_state.started&&A.K.resume().then(()=>{Pc(A.Sa)},D=>{console.error("Failed to resume audiocontext",D)})}y.unlock_event_types.map(function(D){document.removeEventListener(D,y.unlock,!0)})};y.unlock_event_types.map(function(z){document.addEventListener(z,y.unlock,!0)})}window.miniaudio.referenceCount+=1;return 1},345573:()=>{"undefined"!==typeof window.miniaudio&&(window.miniaudio.unlock_event_types.map(function(c){document.removeEventListener(c,
531
- window.miniaudio.unlock,!0)}),--window.miniaudio.referenceCount,0===window.miniaudio.referenceCount&&delete window.miniaudio)},345877:()=>void 0!==navigator.mediaDevices&&void 0!==navigator.mediaDevices.getUserMedia,345981:()=>{try{var c=new (window.AudioContext||window.webkitAudioContext),e=c.sampleRate;c.close();return e}catch(l){return 0}},346152:(c,e,l,q,x,y)=>{if("undefined"===typeof window.miniaudio)return-1;var z={},A={};c==window.miniaudio.device_type.playback&&0!=l&&(A.sampleRate=l);z.K=
532
- new (window.AudioContext||window.webkitAudioContext)(A);z.K.suspend();z.state=window.miniaudio.device_state.stopped;l=0;c!=window.miniaudio.device_type.playback&&(l=e);z.S=z.K.createScriptProcessor(q,l,e);z.S.onaudioprocess=function(D){if(null==z.na||0==z.na.length)z.na=new Float32Array(ya.buffer,x,q*e);if(c==window.miniaudio.device_type.capture||c==window.miniaudio.device_type.duplex){for(var G=0;G<e;G+=1)for(var u=D.inputBuffer.getChannelData(G),a=z.na,d=0;d<q;d+=1)a[d*e+G]=u[d];Qc(y,q,x)}if(c==
533
- window.miniaudio.device_type.playback||c==window.miniaudio.device_type.duplex)for(Rc(y,q,x),G=0;G<D.outputBuffer.numberOfChannels;++G)for(u=D.outputBuffer.getChannelData(G),a=z.na,d=0;d<q;d+=1)u[d]=a[d*e+G];else for(G=0;G<D.outputBuffer.numberOfChannels;++G)D.outputBuffer.getChannelData(G).fill(0)};c!=window.miniaudio.device_type.capture&&c!=window.miniaudio.device_type.duplex||navigator.mediaDevices.getUserMedia({audio:!0,video:!1}).then(function(D){z.va=z.K.createMediaStreamSource(D);z.va.connect(z.S);
534
- z.S.connect(z.K.destination)}).catch(function(D){console.log("Failed to get user media: "+D)});c==window.miniaudio.device_type.playback&&z.S.connect(z.K.destination);z.Sa=y;return window.miniaudio.track_device(z)},349029:c=>window.miniaudio.get_device_by_index(c).K.sampleRate,349102:c=>{c=window.miniaudio.get_device_by_index(c);void 0!==c.S&&(c.S.onaudioprocess=function(){},c.S.disconnect(),c.S=void 0);void 0!==c.va&&(c.va.disconnect(),c.va=void 0);c.K.close();c.K=void 0;c.Sa=void 0},349502:c=>{window.miniaudio.untrack_device_by_index(c)},
535
- 349552:c=>{c=window.miniaudio.get_device_by_index(c);c.K.resume();c.state=window.miniaudio.device_state.started},349691:c=>{c=window.miniaudio.get_device_by_index(c);c.K.suspend();c.state=window.miniaudio.device_state.stopped}},cb,Jc,bb,Tc,Uc,Vc,Wc,Pc,Qc,Rc,Xc,Yc,Na,Nc,Pa,Ca,Hb,$c={__syscall_fcntl64:function(){return 0},__syscall_ioctl:function(){return 0},__syscall_openat:function(){},_abort_js:()=>Da(""),_embind_create_inheriting_constructor:(c,e,l)=>{c=R(c);e=eb(e,"wrapper");l=Q(l);var q=e.o,x=
536
- q.M,y=q.C.M,z=q.C.constructor;c=Ua(c,function(...A){for(var D of q.C.Ta)if(this[D]===y[D])throw new Ya(`Pure virtual function ${D} must be implemented in JavaScript`);Object.defineProperty(this,"__parent",{value:x});this.__construct(...A)});x.__construct=function(...A){if(this===x)throw new O("Pass correct 'this' to __construct");A=z.implement(this,...A);fb(A);var D=A.m;A.notifyOnDestruction();D.$=!0;Object.defineProperties(this,{m:{value:D}});hb(this);A=D.u;A=$a(q,A);if(Za.hasOwnProperty(A))throw new O(`Tried to register registered instance: ${A}`);
537
- Za[A]=this};x.__destruct=function(){if(this===x)throw new O("Pass correct 'this' to __destruct");fb(this);var A=this.m.u;A=$a(q,A);if(Za.hasOwnProperty(A))delete Za[A];else throw new O(`Tried to unregister unregistered instance: ${A}`);};c.prototype=Object.create(x);Object.assign(c.prototype,l);return Xa(c)},_embind_finalize_value_object:c=>{var e=ib[c];delete ib[c];var l=e.Ha,q=e.N,x=e.Oa,y=x.map(z=>z.zb).concat(x.map(z=>z.zh));T([c],y,z=>{var A={},D,G;for([D,G]of x.entries()){const u=z[D],a=G.xb,
538
- d=G.yb,r=z[D+x.length],p=G.yh,v=G.Ah;A[G.tb]={read:f=>u.s(a(d,f)),write:(f,b)=>{var g=[];p(v,f,r.B(g,b));jb(g)},optional:u.optional}}return[{name:e.name,s:u=>{var a={},d;for(d in A)a[d]=A[d].read(u);q(u);return a},B:(u,a)=>{for(var d in A)if(!(d in a||A[d].optional))throw new TypeError(`Missing field: "${d}"`);var r=l();for(d in A)A[d].write(r,a[d]);null!==u&&u.push(q,r);return r},I:kb,H:q}]})},_embind_register_bigint:()=>{},_embind_register_bool:(c,e,l,q)=>{e=R(e);S(c,{name:e,s:function(x){return!!x},
539
- B:function(x,y){return y?l:q},I:function(x){return this.s(J[x])},H:null})},_embind_register_class:(c,e,l,q,x,y,z,A,D,G,u,a,d)=>{u=R(u);y=V(x,y);A&&=V(z,A);G&&=V(D,G);d=V(a,d);var r=vb(u);ub(r,function(){Lb(`Cannot construct ${u} due to unbound types`,[q])});T([c,e,l],q?[q]:[],p=>{p=p[0];if(q){var v=p.o;var f=v.M}else f=rb.prototype;p=Ua(u,function(...k){if(Object.getPrototypeOf(this)!==b)throw new O(`Use 'new' to construct ${u}`);if(void 0===g.U)throw new O(`${u} has no accessible constructor`);var h=
530
+ "click"];y.unlock=function(){for(var z=0;z<y.devices.length;++z){var A=y.devices[z];null!=A&&null!=A.K&&A.state===y.device_state.started&&A.K.resume().then(()=>{Pc(A.Sa)},C=>{console.error("Failed to resume audiocontext",C)})}y.unlock_event_types.map(function(C){document.removeEventListener(C,y.unlock,!0)})};y.unlock_event_types.map(function(z){document.addEventListener(z,y.unlock,!0)})}window.miniaudio.referenceCount+=1;return 1},348405:()=>{"undefined"!==typeof window.miniaudio&&(window.miniaudio.unlock_event_types.map(function(c){document.removeEventListener(c,
531
+ window.miniaudio.unlock,!0)}),--window.miniaudio.referenceCount,0===window.miniaudio.referenceCount&&delete window.miniaudio)},348709:()=>void 0!==navigator.mediaDevices&&void 0!==navigator.mediaDevices.getUserMedia,348813:()=>{try{var c=new (window.AudioContext||window.webkitAudioContext),e=c.sampleRate;c.close();return e}catch(l){return 0}},348984:(c,e,l,q,x,y)=>{if("undefined"===typeof window.miniaudio)return-1;var z={},A={};c==window.miniaudio.device_type.playback&&0!=l&&(A.sampleRate=l);z.K=
532
+ new (window.AudioContext||window.webkitAudioContext)(A);z.K.suspend();z.state=window.miniaudio.device_state.stopped;l=0;c!=window.miniaudio.device_type.playback&&(l=e);z.S=z.K.createScriptProcessor(q,l,e);z.S.onaudioprocess=function(C){if(null==z.na||0==z.na.length)z.na=new Float32Array(ya.buffer,x,q*e);if(c==window.miniaudio.device_type.capture||c==window.miniaudio.device_type.duplex){for(var G=0;G<e;G+=1)for(var u=C.inputBuffer.getChannelData(G),a=z.na,d=0;d<q;d+=1)a[d*e+G]=u[d];Qc(y,q,x)}if(c==
533
+ window.miniaudio.device_type.playback||c==window.miniaudio.device_type.duplex)for(Rc(y,q,x),G=0;G<C.outputBuffer.numberOfChannels;++G)for(u=C.outputBuffer.getChannelData(G),a=z.na,d=0;d<q;d+=1)u[d]=a[d*e+G];else for(G=0;G<C.outputBuffer.numberOfChannels;++G)C.outputBuffer.getChannelData(G).fill(0)};c!=window.miniaudio.device_type.capture&&c!=window.miniaudio.device_type.duplex||navigator.mediaDevices.getUserMedia({audio:!0,video:!1}).then(function(C){z.va=z.K.createMediaStreamSource(C);z.va.connect(z.S);
534
+ z.S.connect(z.K.destination)}).catch(function(C){console.log("Failed to get user media: "+C)});c==window.miniaudio.device_type.playback&&z.S.connect(z.K.destination);z.Sa=y;return window.miniaudio.track_device(z)},351861:c=>window.miniaudio.get_device_by_index(c).K.sampleRate,351934:c=>{c=window.miniaudio.get_device_by_index(c);void 0!==c.S&&(c.S.onaudioprocess=function(){},c.S.disconnect(),c.S=void 0);void 0!==c.va&&(c.va.disconnect(),c.va=void 0);c.K.close();c.K=void 0;c.Sa=void 0},352334:c=>{window.miniaudio.untrack_device_by_index(c)},
535
+ 352384:c=>{c=window.miniaudio.get_device_by_index(c);c.K.resume();c.state=window.miniaudio.device_state.started},352523:c=>{c=window.miniaudio.get_device_by_index(c);c.K.suspend();c.state=window.miniaudio.device_state.stopped}},cb,Jc,bb,Tc,Uc,Vc,Wc,Pc,Qc,Rc,Xc,Yc,Na,Nc,Pa,Ca,Hb,$c={__syscall_fcntl64:function(){return 0},__syscall_ioctl:function(){return 0},__syscall_openat:function(){},_abort_js:()=>Da(""),_embind_create_inheriting_constructor:(c,e,l)=>{c=R(c);e=eb(e,"wrapper");l=Q(l);var q=e.o,x=
536
+ q.M,y=q.C.M,z=q.C.constructor;c=Ua(c,function(...A){for(var C of q.C.Ta)if(this[C]===y[C])throw new Ya(`Pure virtual function ${C} must be implemented in JavaScript`);Object.defineProperty(this,"__parent",{value:x});this.__construct(...A)});x.__construct=function(...A){if(this===x)throw new O("Pass correct 'this' to __construct");A=z.implement(this,...A);fb(A);var C=A.m;A.notifyOnDestruction();C.$=!0;Object.defineProperties(this,{m:{value:C}});hb(this);A=C.u;A=$a(q,A);if(Za.hasOwnProperty(A))throw new O(`Tried to register registered instance: ${A}`);
537
+ Za[A]=this};x.__destruct=function(){if(this===x)throw new O("Pass correct 'this' to __destruct");fb(this);var A=this.m.u;A=$a(q,A);if(Za.hasOwnProperty(A))delete Za[A];else throw new O(`Tried to unregister unregistered instance: ${A}`);};c.prototype=Object.create(x);Object.assign(c.prototype,l);return Xa(c)},_embind_finalize_value_object:c=>{var e=ib[c];delete ib[c];var l=e.Ha,q=e.N,x=e.Oa,y=x.map(z=>z.zb).concat(x.map(z=>z.zh));T([c],y,z=>{var A={},C,G;for([C,G]of x.entries()){const u=z[C],a=G.xb,
538
+ d=G.yb,r=z[C+x.length],p=G.yh,v=G.Ah;A[G.tb]={read:f=>u.s(a(d,f)),write:(f,b)=>{var g=[];p(v,f,r.B(g,b));jb(g)},optional:u.optional}}return[{name:e.name,s:u=>{var a={},d;for(d in A)a[d]=A[d].read(u);q(u);return a},B:(u,a)=>{for(var d in A)if(!(d in a||A[d].optional))throw new TypeError(`Missing field: "${d}"`);var r=l();for(d in A)A[d].write(r,a[d]);null!==u&&u.push(q,r);return r},I:kb,H:q}]})},_embind_register_bigint:()=>{},_embind_register_bool:(c,e,l,q)=>{e=R(e);S(c,{name:e,s:function(x){return!!x},
539
+ B:function(x,y){return y?l:q},I:function(x){return this.s(J[x])},H:null})},_embind_register_class:(c,e,l,q,x,y,z,A,C,G,u,a,d)=>{u=R(u);y=V(x,y);A&&=V(z,A);G&&=V(C,G);d=V(a,d);var r=vb(u);ub(r,function(){Lb(`Cannot construct ${u} due to unbound types`,[q])});T([c,e,l],q?[q]:[],p=>{p=p[0];if(q){var v=p.o;var f=v.M}else f=rb.prototype;p=Ua(u,function(...k){if(Object.getPrototypeOf(this)!==b)throw new O(`Use 'new' to construct ${u}`);if(void 0===g.U)throw new O(`${u} has no accessible constructor`);var h=
540
540
  g.U[k.length];if(void 0===h)throw new O(`Tried to invoke ctor of ${u} with invalid number of parameters (${k.length}) - expected (${Object.keys(g.U).toString()}) parameters instead!`);return h.apply(this,k)});var b=Object.create(f,{constructor:{value:p}});p.prototype=b;var g=new wb(u,p,b,d,v,y,A,G);if(g.C){var n;(n=g.C).ga??(n.ga=[]);g.C.ga.push(g)}v=new Fb(u,g,!0,!1,!1);n=new Fb(u+"*",g,!1,!1,!1);f=new Fb(u+" const*",g,!1,!0,!1);sb[c]={pointerType:n,lb:f};Gb(r,p);return[v,n,f]})},_embind_register_class_class_function:(c,
541
- e,l,q,x,y,z)=>{var A=Ob(l,q);e=R(e);e=Pb(e);y=V(x,y);T([],[c],D=>{function G(){Lb(`Cannot call ${u} due to unbound types`,A)}D=D[0];var u=`${D.name}.${e}`;e.startsWith("@@")&&(e=Symbol[e.substring(2)]);var a=D.o.constructor;void 0===a[e]?(G.R=l-1,a[e]=G):(tb(a,e,u),a[e].A[l-1]=G);T([],A,d=>{d=Nb(u,[d[0],null].concat(d.slice(1)),null,y,z);void 0===a[e].A?(d.R=l-1,a[e]=d):a[e].A[l-1]=d;if(D.o.ga)for(const r of D.o.ga)r.constructor.hasOwnProperty(e)||(r.constructor[e]=d);return[]});return[]})},_embind_register_class_class_property:(c,
542
- e,l,q,x,y,z,A)=>{e=R(e);y=V(x,y);T([],[c],D=>{D=D[0];var G=`${D.name}.${e}`,u={get(){Lb(`Cannot access ${G} due to unbound types`,[l])},enumerable:!0,configurable:!0};u.set=A?()=>{Lb(`Cannot access ${G} due to unbound types`,[l])}:()=>{throw new O(`${G} is a read-only property`);};Object.defineProperty(D.o.constructor,e,u);T([],[l],a=>{a=a[0];var d={get(){return a.s(y(q))},enumerable:!0};A&&(A=V(z,A),d.set=r=>{var p=[];A(q,a.B(p,r));jb(p)});Object.defineProperty(D.o.constructor,e,d);return[]});return[]})},
543
- _embind_register_class_constructor:(c,e,l,q,x,y)=>{var z=Ob(e,l);x=V(q,x);T([],[c],A=>{A=A[0];var D=`constructor ${A.name}`;void 0===A.o.U&&(A.o.U=[]);if(void 0!==A.o.U[e-1])throw new O(`Cannot register multiple constructors with identical number of parameters (${e-1}) for class '${A.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);A.o.U[e-1]=()=>{Lb(`Cannot construct ${A.name} due to unbound types`,z)};T([],z,G=>{G.splice(1,0,null);A.o.U[e-
544
- 1]=Nb(D,G,null,x,y);return[]});return[]})},_embind_register_class_function:(c,e,l,q,x,y,z,A)=>{var D=Ob(l,q);e=R(e);e=Pb(e);y=V(x,y);T([],[c],G=>{function u(){Lb(`Cannot call ${a} due to unbound types`,D)}G=G[0];var a=`${G.name}.${e}`;e.startsWith("@@")&&(e=Symbol[e.substring(2)]);A&&G.o.Ta.push(e);var d=G.o.M,r=d[e];void 0===r||void 0===r.A&&r.className!==G.name&&r.R===l-2?(u.R=l-2,u.className=G.name,d[e]=u):(tb(d,e,a),d[e].A[l-2]=u);T([],D,p=>{p=Nb(a,p,G,y,z);void 0===d[e].A?(p.R=l-2,d[e]=p):d[e].A[l-
545
- 2]=p;return[]});return[]})},_embind_register_class_property:(c,e,l,q,x,y,z,A,D,G)=>{e=R(e);x=V(q,x);T([],[c],u=>{u=u[0];var a=`${u.name}.${e}`,d={get(){Lb(`Cannot access ${a} due to unbound types`,[l,z])},enumerable:!0,configurable:!0};d.set=D?()=>Lb(`Cannot access ${a} due to unbound types`,[l,z]):()=>{throw new O(a+" is a read-only property");};Object.defineProperty(u.o.M,e,d);T([],D?[l,z]:[l],r=>{var p=r[0],v={get(){var b=Qb(this,u,a+" getter");return p.s(x(y,b))},enumerable:!0};if(D){D=V(A,D);
546
- var f=r[1];v.set=function(b){var g=Qb(this,u,a+" setter"),n=[];D(G,g,f.B(n,b));jb(n)}}Object.defineProperty(u.o.M,e,v);return[]});return[]})},_embind_register_emval:c=>S(c,Sb),_embind_register_enum:(c,e,l,q,x)=>{e=R(e);x=0===x?"object":1===x?"number":"string";switch(x){case "object":function z(){}z.values={};S(c,{name:e,constructor:z,valueType:x,s:function(A){return this.constructor.values[A]},B:(A,D)=>D.value,I:Tb(e,l,q),H:null});ub(e,z);break;case "number":var y={};S(c,{name:e,Fa:y,valueType:x,
547
- s:A=>A,B:(A,D)=>D,I:Tb(e,l,q),H:null});ub(e,y);delete C[e].R;break;case "string":y={},S(c,{name:e,$a:{},Wa:{},Fa:y,valueType:x,s:function(A){return this.Wa[A]},B:function(A,D){return this.$a[D]},I:Tb(e,l,q),H:null}),ub(e,y),delete C[e].R}},_embind_register_enum_value:(c,e,l)=>{var q=eb(c,"enum");e=R(e);switch(q.valueType){case "object":c=q.constructor;q=Object.create(q.constructor.prototype,{value:{value:l},constructor:{value:Ua(`${q.name}_${e}`,function(){})}});c.values[l]=q;c[e]=q;break;case "number":q.Fa[e]=
548
- l;break;case "string":q.$a[e]=l,q.Wa[l]=e,q.Fa[e]=e}},_embind_register_float:(c,e,l)=>{e=R(e);S(c,{name:e,s:q=>q,B:(q,x)=>x,I:Ub(e,l),H:null})},_embind_register_function:(c,e,l,q,x,y)=>{var z=Ob(e,l);c=R(c);c=Pb(c);x=V(q,x);ub(c,function(){Lb(`Cannot call ${c} due to unbound types`,z)},e-1);T([],z,A=>{Gb(c,Nb(c,[A[0],null].concat(A.slice(1)),null,x,y),e-1);return[]})},_embind_register_integer:(c,e,l,q,x)=>{e=R(e);let y=A=>A;if(0===q){var z=32-8*l;y=A=>A<<z>>>z;x=y(x)}S(c,{name:e,s:y,B:(A,D)=>D,I:Vb(e,
541
+ e,l,q,x,y,z)=>{var A=Ob(l,q);e=R(e);e=Pb(e);y=V(x,y);T([],[c],C=>{function G(){Lb(`Cannot call ${u} due to unbound types`,A)}C=C[0];var u=`${C.name}.${e}`;e.startsWith("@@")&&(e=Symbol[e.substring(2)]);var a=C.o.constructor;void 0===a[e]?(G.R=l-1,a[e]=G):(tb(a,e,u),a[e].A[l-1]=G);T([],A,d=>{d=Nb(u,[d[0],null].concat(d.slice(1)),null,y,z);void 0===a[e].A?(d.R=l-1,a[e]=d):a[e].A[l-1]=d;if(C.o.ga)for(const r of C.o.ga)r.constructor.hasOwnProperty(e)||(r.constructor[e]=d);return[]});return[]})},_embind_register_class_class_property:(c,
542
+ e,l,q,x,y,z,A)=>{e=R(e);y=V(x,y);T([],[c],C=>{C=C[0];var G=`${C.name}.${e}`,u={get(){Lb(`Cannot access ${G} due to unbound types`,[l])},enumerable:!0,configurable:!0};u.set=A?()=>{Lb(`Cannot access ${G} due to unbound types`,[l])}:()=>{throw new O(`${G} is a read-only property`);};Object.defineProperty(C.o.constructor,e,u);T([],[l],a=>{a=a[0];var d={get(){return a.s(y(q))},enumerable:!0};A&&(A=V(z,A),d.set=r=>{var p=[];A(q,a.B(p,r));jb(p)});Object.defineProperty(C.o.constructor,e,d);return[]});return[]})},
543
+ _embind_register_class_constructor:(c,e,l,q,x,y)=>{var z=Ob(e,l);x=V(q,x);T([],[c],A=>{A=A[0];var C=`constructor ${A.name}`;void 0===A.o.U&&(A.o.U=[]);if(void 0!==A.o.U[e-1])throw new O(`Cannot register multiple constructors with identical number of parameters (${e-1}) for class '${A.name}'! Overload resolution is currently only performed using the parameter count, not actual type info!`);A.o.U[e-1]=()=>{Lb(`Cannot construct ${A.name} due to unbound types`,z)};T([],z,G=>{G.splice(1,0,null);A.o.U[e-
544
+ 1]=Nb(C,G,null,x,y);return[]});return[]})},_embind_register_class_function:(c,e,l,q,x,y,z,A)=>{var C=Ob(l,q);e=R(e);e=Pb(e);y=V(x,y);T([],[c],G=>{function u(){Lb(`Cannot call ${a} due to unbound types`,C)}G=G[0];var a=`${G.name}.${e}`;e.startsWith("@@")&&(e=Symbol[e.substring(2)]);A&&G.o.Ta.push(e);var d=G.o.M,r=d[e];void 0===r||void 0===r.A&&r.className!==G.name&&r.R===l-2?(u.R=l-2,u.className=G.name,d[e]=u):(tb(d,e,a),d[e].A[l-2]=u);T([],C,p=>{p=Nb(a,p,G,y,z);void 0===d[e].A?(p.R=l-2,d[e]=p):d[e].A[l-
545
+ 2]=p;return[]});return[]})},_embind_register_class_property:(c,e,l,q,x,y,z,A,C,G)=>{e=R(e);x=V(q,x);T([],[c],u=>{u=u[0];var a=`${u.name}.${e}`,d={get(){Lb(`Cannot access ${a} due to unbound types`,[l,z])},enumerable:!0,configurable:!0};d.set=C?()=>Lb(`Cannot access ${a} due to unbound types`,[l,z]):()=>{throw new O(a+" is a read-only property");};Object.defineProperty(u.o.M,e,d);T([],C?[l,z]:[l],r=>{var p=r[0],v={get(){var b=Qb(this,u,a+" getter");return p.s(x(y,b))},enumerable:!0};if(C){C=V(A,C);
546
+ var f=r[1];v.set=function(b){var g=Qb(this,u,a+" setter"),n=[];C(G,g,f.B(n,b));jb(n)}}Object.defineProperty(u.o.M,e,v);return[]});return[]})},_embind_register_emval:c=>S(c,Sb),_embind_register_enum:(c,e,l,q,x)=>{e=R(e);x=0===x?"object":1===x?"number":"string";switch(x){case "object":function z(){}z.values={};S(c,{name:e,constructor:z,valueType:x,s:function(A){return this.constructor.values[A]},B:(A,C)=>C.value,I:Tb(e,l,q),H:null});ub(e,z);break;case "number":var y={};S(c,{name:e,Fa:y,valueType:x,
547
+ s:A=>A,B:(A,C)=>C,I:Tb(e,l,q),H:null});ub(e,y);delete D[e].R;break;case "string":y={},S(c,{name:e,$a:{},Wa:{},Fa:y,valueType:x,s:function(A){return this.Wa[A]},B:function(A,C){return this.$a[C]},I:Tb(e,l,q),H:null}),ub(e,y),delete D[e].R}},_embind_register_enum_value:(c,e,l)=>{var q=eb(c,"enum");e=R(e);switch(q.valueType){case "object":c=q.constructor;q=Object.create(q.constructor.prototype,{value:{value:l},constructor:{value:Ua(`${q.name}_${e}`,function(){})}});c.values[l]=q;c[e]=q;break;case "number":q.Fa[e]=
548
+ l;break;case "string":q.$a[e]=l,q.Wa[l]=e,q.Fa[e]=e}},_embind_register_float:(c,e,l)=>{e=R(e);S(c,{name:e,s:q=>q,B:(q,x)=>x,I:Ub(e,l),H:null})},_embind_register_function:(c,e,l,q,x,y)=>{var z=Ob(e,l);c=R(c);c=Pb(c);x=V(q,x);ub(c,function(){Lb(`Cannot call ${c} due to unbound types`,z)},e-1);T([],z,A=>{Gb(c,Nb(c,[A[0],null].concat(A.slice(1)),null,x,y),e-1);return[]})},_embind_register_integer:(c,e,l,q,x)=>{e=R(e);let y=A=>A;if(0===q){var z=32-8*l;y=A=>A<<z>>>z;x=y(x)}S(c,{name:e,s:y,B:(A,C)=>C,I:Vb(e,
549
549
  l,0!==q),H:null})},_embind_register_memory_view:(c,e,l)=>{function q(y){return new x(va.buffer,M[y+4>>2],M[y>>2])}var x=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array][e];l=R(l);S(c,{name:l,s:q,I:q},{Db:!0})},_embind_register_std_string:(c,e)=>{e=R(e);S(c,{name:e,s(l){var q=(q=l+4)?Ta(J,q,M[l>>2],!0):"";cb(l);return q},B(l,q){q instanceof ArrayBuffer&&(q=new Uint8Array(q));var x="string"==typeof q;if(!(x||ArrayBuffer.isView(q)&&1==q.BYTES_PER_ELEMENT))throw new O("Cannot pass non-string to std::string");
550
- var y=x?Xb(q):q.length;var z=Jc(4+y+1),A=z+4;M[z>>2]=y;x?Wb(q,A,y+1):J.set(q,A);null!==l&&l.push(cb,z);return z},I:kb,H(l){cb(l)}})},_embind_register_std_wstring:(c,e,l)=>{l=R(l);if(2===e){var q=Zb;var x=$b;var y=ac}else q=bc,x=cc,y=dc;S(c,{name:l,s:z=>{var A=q(z+4,M[z>>2]*e,!0);cb(z);return A},B:(z,A)=>{if("string"!=typeof A)throw new O(`Cannot pass non-string to C++ string type ${l}`);var D=y(A),G=Jc(4+D+e);M[G>>2]=D/e;x(A,G+4,D+e);null!==z&&z.push(cb,G);return G},I:kb,H(z){cb(z)}})},_embind_register_value_object:(c,
551
- e,l,q,x,y)=>{ib[c]={name:R(e),Ha:V(l,q),N:V(x,y),Oa:[]}},_embind_register_value_object_field:(c,e,l,q,x,y,z,A,D,G)=>{ib[c].Oa.push({tb:R(e),zb:l,xb:V(q,x),yb:y,zh:z,yh:V(A,D),Ah:G})},_embind_register_void:(c,e)=>{e=R(e);S(c,{Fb:!0,name:e,s:()=>{},B:()=>{}})},_emscripten_throw_longjmp:()=>{throw Infinity;},_emval_create_invoker:(c,e,l)=>{var [q,...x]=gc(c,e),y=q.B.bind(q),z=x.map(D=>D.I.bind(D));c--;var A=Array(c);e=`methodCaller<(${x.map(D=>D.name)}) => ${q.name}>`;return fc(Ua(e,(D,G,u,a)=>{for(var d=
552
- 0,r=0;r<c;++r)A[r]=z[r](a+d),d+=8;switch(l){case 0:var p=Q(D).apply(null,A);break;case 2:p=Reflect.construct(Q(D),A);break;case 3:p=A[0];break;case 1:p=Q(D)[ic(G)](...A)}D=[];p=y(D,p);D.length&&(M[u>>2]=Xa(D));return p}))},_emval_decref:Rb,_emval_get_property:(c,e)=>{c=Q(c);e=Q(e);return Xa(c[e])},_emval_incref:c=>{9<c&&(Wa[c+1]+=1)},_emval_invoke:(c,e,l,q,x)=>ec[c](e,l,q,x),_emval_new_array:()=>Xa([]),_emval_new_cstring:c=>Xa(ic(c)),_emval_new_object:()=>Xa({}),_emval_run_destructors:c=>{var e=Q(c);
550
+ var y=x?Xb(q):q.length;var z=Jc(4+y+1),A=z+4;M[z>>2]=y;x?Wb(q,A,y+1):J.set(q,A);null!==l&&l.push(cb,z);return z},I:kb,H(l){cb(l)}})},_embind_register_std_wstring:(c,e,l)=>{l=R(l);if(2===e){var q=Zb;var x=$b;var y=ac}else q=bc,x=cc,y=dc;S(c,{name:l,s:z=>{var A=q(z+4,M[z>>2]*e,!0);cb(z);return A},B:(z,A)=>{if("string"!=typeof A)throw new O(`Cannot pass non-string to C++ string type ${l}`);var C=y(A),G=Jc(4+C+e);M[G>>2]=C/e;x(A,G+4,C+e);null!==z&&z.push(cb,G);return G},I:kb,H(z){cb(z)}})},_embind_register_value_object:(c,
551
+ e,l,q,x,y)=>{ib[c]={name:R(e),Ha:V(l,q),N:V(x,y),Oa:[]}},_embind_register_value_object_field:(c,e,l,q,x,y,z,A,C,G)=>{ib[c].Oa.push({tb:R(e),zb:l,xb:V(q,x),yb:y,zh:z,yh:V(A,C),Ah:G})},_embind_register_void:(c,e)=>{e=R(e);S(c,{Fb:!0,name:e,s:()=>{},B:()=>{}})},_emscripten_throw_longjmp:()=>{throw Infinity;},_emval_create_invoker:(c,e,l)=>{var [q,...x]=gc(c,e),y=q.B.bind(q),z=x.map(C=>C.I.bind(C));c--;var A=Array(c);e=`methodCaller<(${x.map(C=>C.name)}) => ${q.name}>`;return fc(Ua(e,(C,G,u,a)=>{for(var d=
552
+ 0,r=0;r<c;++r)A[r]=z[r](a+d),d+=8;switch(l){case 0:var p=Q(C).apply(null,A);break;case 2:p=Reflect.construct(Q(C),A);break;case 3:p=A[0];break;case 1:p=Q(C)[ic(G)](...A)}C=[];p=y(C,p);C.length&&(M[u>>2]=Xa(C));return p}))},_emval_decref:Rb,_emval_get_property:(c,e)=>{c=Q(c);e=Q(e);return Xa(c[e])},_emval_incref:c=>{9<c&&(Wa[c+1]+=1)},_emval_invoke:(c,e,l,q,x)=>ec[c](e,l,q,x),_emval_new_array:()=>Xa([]),_emval_new_cstring:c=>Xa(ic(c)),_emval_new_object:()=>Xa({}),_emval_run_destructors:c=>{var e=Q(c);
553
553
  jb(e);Rb(c)},_emval_set_property:(c,e,l)=>{c=Q(c);e=Q(e);l=Q(l);c[e]=l},_gmtime_js:function(c,e,l){c=new Date(1E3*(e+2097152>>>0<4194305-!!c?(c>>>0)+4294967296*e:NaN));L[l>>2]=c.getUTCSeconds();L[l+4>>2]=c.getUTCMinutes();L[l+8>>2]=c.getUTCHours();L[l+12>>2]=c.getUTCDate();L[l+16>>2]=c.getUTCMonth();L[l+20>>2]=c.getUTCFullYear()-1900;L[l+24>>2]=c.getUTCDay();L[l+28>>2]=(c.getTime()-Date.UTC(c.getUTCFullYear(),0,1,0,0,0,0))/864E5|0},_localtime_js:function(c,e,l){c=new Date(1E3*(e+2097152>>>0<4194305-
554
554
  !!c?(c>>>0)+4294967296*e:NaN));L[l>>2]=c.getSeconds();L[l+4>>2]=c.getMinutes();L[l+8>>2]=c.getHours();L[l+12>>2]=c.getDate();L[l+16>>2]=c.getMonth();L[l+20>>2]=c.getFullYear()-1900;L[l+24>>2]=c.getDay();e=c.getFullYear();L[l+28>>2]=(0!==e%4||0===e%100&&0!==e%400?kc:jc)[c.getMonth()]+c.getDate()-1|0;L[l+36>>2]=-(60*c.getTimezoneOffset());e=(new Date(c.getFullYear(),6,1)).getTimezoneOffset();var q=(new Date(c.getFullYear(),0,1)).getTimezoneOffset();L[l+32>>2]=(e!=q&&c.getTimezoneOffset()==Math.min(q,
555
555
  e))|0},_timegm_js:function(c){var e=new Date(Date.UTC(L[c+20>>2]+1900,L[c+16>>2],L[c+12>>2],L[c+8>>2],L[c+4>>2],L[c>>2],0));L[c+24>>2]=e.getUTCDay();L[c+28>>2]=(e.getTime()-Date.UTC(e.getUTCFullYear(),0,1,0,0,0,0))/864E5|0;c=e.getTime()/1E3;Yc((N=c,1<=+Math.abs(N)?0<N?+Math.floor(N/4294967296)>>>0:~~+Math.ceil((N-+(~~N>>>0))/4294967296)>>>0:0));return c>>>0},_tzset_js:(c,e,l,q)=>{var x=(new Date).getFullYear(),y=(new Date(x,0,1)).getTimezoneOffset();x=(new Date(x,6,1)).getTimezoneOffset();M[c>>2]=
556
556
  60*Math.max(y,x);L[e>>2]=Number(y!=x);e=z=>{var A=Math.abs(z);return`UTC${0<=z?"-":"+"}${String(Math.floor(A/60)).padStart(2,"0")}${String(A%60).padStart(2,"0")}`};c=e(y);e=e(x);x<y?(Wb(c,l,17),Wb(e,q,17)):(Wb(c,q,17),Wb(e,l,17))},beginPixelLocalStorageWEBGL:function(c,e,l){(c=I[c].F.ta)&&c.beginPixelLocalStorageWEBGL(new Uint32Array(Ca.buffer,4*l,e))},clock_time_get:function(c,e,l,q){if(!(0<=c&&3>=c))return 28;c=Math.round(1E6*(0===c?Date.now():performance.now()));Ia=[c>>>0,(N=c,1<=+Math.abs(N)?
557
- 0<N?+Math.floor(N/4294967296)>>>0:~~+Math.ceil((N-+(~~N>>>0))/4294967296)>>>0:0)];L[q>>2]=Ia[0];L[q+4>>2]=Ia[1];return 0},decode_image:function(c,e,l){var q=C.images;q||(q=new Map,C.images=q);var x=new Image;q.set(c,x);e=C.HEAP8.subarray(e,e+l);l=new Uint8Array(l);l.set(e);x.src=URL.createObjectURL(new Blob([l],{type:"image/png"}));x.onload=function(){C._setWebImage(c,x.width,x.height)}},delete_image:function(c){var e=C.images;e&&e.get(c)&&e.delete(c)},emscripten_asm_const_int:(c,e,l)=>{lc.length=
557
+ 0<N?+Math.floor(N/4294967296)>>>0:~~+Math.ceil((N-+(~~N>>>0))/4294967296)>>>0:0)];L[q>>2]=Ia[0];L[q+4>>2]=Ia[1];return 0},decode_image:function(c,e,l){var q=D.images;q||(q=new Map,D.images=q);var x=new Image;q.set(c,x);e=D.HEAP8.subarray(e,e+l);l=new Uint8Array(l);l.set(e);x.src=URL.createObjectURL(new Blob([l],{type:"image/png"}));x.onload=function(){D._setWebImage(c,x.width,x.height)}},delete_image:function(c){var e=D.images;e&&e.get(c)&&e.delete(c)},emscripten_asm_const_int:(c,e,l)=>{lc.length=
558
558
  0;for(var q;q=J[e++];){var x=105!=q;x&=112!=q;l+=x&&l%8?4:0;lc.push(112==q?M[l>>2]:105==q?L[l>>2]:za[l>>3]);l+=x?8:4}return Sc[c](...lc)},emscripten_date_now:()=>Date.now(),emscripten_get_now:()=>performance.now(),emscripten_resize_heap:c=>{var e=J.length;c>>>=0;if(2147483648<c)return!1;for(var l=1;4>=l;l*=2){var q=e*(1+.2/l);q=Math.min(q,c+100663296);a:{q=(Math.min(2147483648,65536*Math.ceil(Math.max(c,q)/65536))-Ca.buffer.byteLength+65535)/65536|0;try{Ca.grow(q);Ba();var x=1;break a}catch(y){}x=
559
559
  void 0}if(x)return!0}return!1},emscripten_webgl_enable_extension:(c,e)=>{c=I[c];e=e?Ta(J,e):"";e.startsWith("GL_")&&(e=e.slice(3));"WEBGL_draw_instanced_base_vertex_base_instance"==e&&mc(W);"WEBGL_multi_draw_instanced_base_vertex_base_instance"==e&&nc(W);"WEBGL_multi_draw"==e&&(W.Gb=W.getExtension("WEBGL_multi_draw"));"EXT_polygon_offset_clamp"==e&&(W.sb=W.getExtension("EXT_polygon_offset_clamp"));"EXT_clip_control"==e&&(W.rb=W.getExtension("EXT_clip_control"));"WEBGL_polygon_mode"==e&&(W.Dh=W.getExtension("WEBGL_polygon_mode"));
560
560
  return!!c.F.getExtension(e)},emscripten_webgl_get_current_context:()=>E?E.handle:0,emscripten_webgl_make_context_current:c=>ia(c)?0:-5,enable_WEBGL_provoking_vertex:function(c){c=I[c].F;c.Ua=c.getExtension("WEBGL_provoking_vertex");return!!c.Ua},enable_WEBGL_shader_pixel_local_storage_coherent:function(c){c=I[c].F;const e=c.getExtension("WEBGL_shader_pixel_local_storage");if(e&&e.isCoherent()){if(5==e.framebufferTexturePixelLocalStorageWEBGL.length)return c.ta=e,!0;console.warn("WEBGL_shader_pixel_local_storage is advertised, but a deprecated version has been detected. Disabling.")}return!1},
561
- endPixelLocalStorageWEBGL:function(c,e,l){(c=I[c].F.ta)&&c.endPixelLocalStorageWEBGL(new Uint32Array(Ca.buffer,4*l,e))},environ_get:(c,e)=>{var l=0,q=0,x;for(x of Ec()){var y=e+l;M[c+q>>2]=y;l+=Wb(x,y,Infinity)+1;q+=4}return 0},environ_sizes_get:(c,e)=>{var l=Ec();M[c>>2]=l.length;c=0;for(var q of l)c+=Xb(q)+1;M[e>>2]=c;return 0},fd_close:()=>52,fd_read:()=>52,fd_seek:function(){return 70},fd_write:(c,e,l,q)=>{for(var x=0,y=0;y<l;y++){var z=M[e>>2],A=M[e+4>>2];e+=8;for(var D=0;D<A;D++){var G=c,u=
562
- J[z+D],a=Fc[G];0===u||10===u?((1===G?pa:qa)(Ta(a)),a.length=0):a.push(u)}x+=A}M[q>>2]=x;return 0},framebufferPixelLocalClearValuefvWEBGL:function(c,e,l,q,x,y){(c=I[c].F.ta)&&c.framebufferPixelLocalClearValuefvWEBGL(e,[l,q,x,y])},framebufferTexturePixelLocalStorageWEBGL:function(c,e,l,q,x,y){(c=I[c].F.ta)&&c.framebufferTexturePixelLocalStorageWEBGL(e,tc[l],q,x,y)},glActiveTexture:c=>W.activeTexture(c),glAttachShader:(c,e)=>{W.attachShader(X[c],Y[e])},glBindAttribLocation:(c,e,l)=>{W.bindAttribLocation(X[c],
561
+ endPixelLocalStorageWEBGL:function(c,e,l){(c=I[c].F.ta)&&c.endPixelLocalStorageWEBGL(new Uint32Array(Ca.buffer,4*l,e))},environ_get:(c,e)=>{var l=0,q=0,x;for(x of Ec()){var y=e+l;M[c+q>>2]=y;l+=Wb(x,y,Infinity)+1;q+=4}return 0},environ_sizes_get:(c,e)=>{var l=Ec();M[c>>2]=l.length;c=0;for(var q of l)c+=Xb(q)+1;M[e>>2]=c;return 0},fd_close:()=>52,fd_read:()=>52,fd_seek:function(){return 70},fd_write:(c,e,l,q)=>{for(var x=0,y=0;y<l;y++){var z=M[e>>2],A=M[e+4>>2];e+=8;for(var C=0;C<A;C++){var G=c,u=
562
+ J[z+C],a=Fc[G];0===u||10===u?((1===G?pa:qa)(Ta(a)),a.length=0):a.push(u)}x+=A}M[q>>2]=x;return 0},framebufferPixelLocalClearValuefvWEBGL:function(c,e,l,q,x,y){(c=I[c].F.ta)&&c.framebufferPixelLocalClearValuefvWEBGL(e,[l,q,x,y])},framebufferTexturePixelLocalStorageWEBGL:function(c,e,l,q,x,y){(c=I[c].F.ta)&&c.framebufferTexturePixelLocalStorageWEBGL(e,tc[l],q,x,y)},glActiveTexture:c=>W.activeTexture(c),glAttachShader:(c,e)=>{W.attachShader(X[c],Y[e])},glBindAttribLocation:(c,e,l)=>{W.bindAttribLocation(X[c],
563
563
  e,l?Ta(J,l):"")},glBindBuffer:(c,e)=>{35051==c?W.Ca=e:35052==c&&(W.Y=e);W.bindBuffer(c,qc[e])},glBindBufferRange:(c,e,l,q,x)=>{W.bindBufferRange(c,e,qc[l],q,x)},glBindFramebuffer:(c,e)=>{W.bindFramebuffer(c,rc[e])},glBindRenderbuffer:(c,e)=>{W.bindRenderbuffer(c,sc[e])},glBindSampler:(c,e)=>{W.bindSampler(c,vc[e])},glBindTexture:(c,e)=>{W.bindTexture(c,tc[e])},glBindVertexArray:c=>{W.bindVertexArray(uc[c])},glBlendColor:(c,e,l,q)=>W.blendColor(c,e,l,q),glBlendEquation:c=>W.blendEquation(c),glBlendEquationSeparate:(c,
564
- e)=>W.blendEquationSeparate(c,e),glBlendFunc:(c,e)=>W.blendFunc(c,e),glBlendFuncSeparate:(c,e,l,q)=>W.blendFuncSeparate(c,e,l,q),glBlitFramebuffer:(c,e,l,q,x,y,z,A,D,G)=>W.blitFramebuffer(c,e,l,q,x,y,z,A,D,G),glBufferData:(c,e,l,q)=>{l&&e?W.bufferData(c,J,q,l,e):W.bufferData(c,e,q)},glBufferSubData:(c,e,l,q)=>{l&&W.bufferSubData(c,e,J,q,l)},glCheckFramebufferStatus:c=>W.checkFramebufferStatus(c),glClear:c=>W.clear(c),glClearBufferfi:(c,e,l,q)=>W.clearBufferfi(c,e,l,q),glClearBufferfv:(c,e,l)=>{W.clearBufferfv(c,
565
- e,ya,l>>2)},glClearBufferiv:(c,e,l)=>{W.clearBufferiv(c,e,L,l>>2)},glClearBufferuiv:(c,e,l)=>{W.clearBufferuiv(c,e,M,l>>2)},glClearColor:(c,e,l,q)=>W.clearColor(c,e,l,q),glClearDepthf:c=>W.clearDepth(c),glClearStencil:c=>W.clearStencil(c),glColorMask:(c,e,l,q)=>{W.colorMask(!!c,!!e,!!l,!!q)},glCompileShader:c=>{W.compileShader(Y[c])},glCompressedTexSubImage2D:(c,e,l,q,x,y,z,A,D)=>{W.Y||!A?W.compressedTexSubImage2D(c,e,l,q,x,y,z,A,D):W.compressedTexSubImage2D(c,e,l,q,x,y,z,J,D,A)},glCompressedTexSubImage3D:(c,
566
- e,l,q,x,y,z,A,D,G,u)=>{W.Y?W.compressedTexSubImage3D(c,e,l,q,x,y,z,A,D,G,u):W.compressedTexSubImage3D(c,e,l,q,x,y,z,A,D,J,u,G)},glCreateProgram:()=>{var c=Ac(X),e=W.createProgram();e.name=c;e.sa=e.qa=e.ra=0;e.Ia=1;X[c]=e;return c},glCreateShader:c=>{var e=Ac(Y);Y[e]=W.createShader(c);return e},glCullFace:c=>W.cullFace(c),glDeleteBuffers:(c,e)=>{for(var l=0;l<c;l++){var q=L[e+4*l>>2],x=qc[q];x&&(W.deleteBuffer(x),x.name=0,qc[q]=null,q==W.Ca&&(W.Ca=0),q==W.Y&&(W.Y=0))}},glDeleteFramebuffers:(c,e)=>
564
+ e)=>W.blendEquationSeparate(c,e),glBlendFunc:(c,e)=>W.blendFunc(c,e),glBlendFuncSeparate:(c,e,l,q)=>W.blendFuncSeparate(c,e,l,q),glBlitFramebuffer:(c,e,l,q,x,y,z,A,C,G)=>W.blitFramebuffer(c,e,l,q,x,y,z,A,C,G),glBufferData:(c,e,l,q)=>{l&&e?W.bufferData(c,J,q,l,e):W.bufferData(c,e,q)},glBufferSubData:(c,e,l,q)=>{l&&W.bufferSubData(c,e,J,q,l)},glCheckFramebufferStatus:c=>W.checkFramebufferStatus(c),glClear:c=>W.clear(c),glClearBufferfi:(c,e,l,q)=>W.clearBufferfi(c,e,l,q),glClearBufferfv:(c,e,l)=>{W.clearBufferfv(c,
565
+ e,ya,l>>2)},glClearBufferiv:(c,e,l)=>{W.clearBufferiv(c,e,L,l>>2)},glClearBufferuiv:(c,e,l)=>{W.clearBufferuiv(c,e,M,l>>2)},glClearColor:(c,e,l,q)=>W.clearColor(c,e,l,q),glClearDepthf:c=>W.clearDepth(c),glClearStencil:c=>W.clearStencil(c),glColorMask:(c,e,l,q)=>{W.colorMask(!!c,!!e,!!l,!!q)},glCompileShader:c=>{W.compileShader(Y[c])},glCompressedTexSubImage2D:(c,e,l,q,x,y,z,A,C)=>{W.Y||!A?W.compressedTexSubImage2D(c,e,l,q,x,y,z,A,C):W.compressedTexSubImage2D(c,e,l,q,x,y,z,J,C,A)},glCompressedTexSubImage3D:(c,
566
+ e,l,q,x,y,z,A,C,G,u)=>{W.Y?W.compressedTexSubImage3D(c,e,l,q,x,y,z,A,C,G,u):W.compressedTexSubImage3D(c,e,l,q,x,y,z,A,C,J,u,G)},glCreateProgram:()=>{var c=Ac(X),e=W.createProgram();e.name=c;e.sa=e.qa=e.ra=0;e.Ia=1;X[c]=e;return c},glCreateShader:c=>{var e=Ac(Y);Y[e]=W.createShader(c);return e},glCullFace:c=>W.cullFace(c),glDeleteBuffers:(c,e)=>{for(var l=0;l<c;l++){var q=L[e+4*l>>2],x=qc[q];x&&(W.deleteBuffer(x),x.name=0,qc[q]=null,q==W.Ca&&(W.Ca=0),q==W.Y&&(W.Y=0))}},glDeleteFramebuffers:(c,e)=>
567
567
  {for(var l=0;l<c;++l){var q=L[e+4*l>>2],x=rc[q];x&&(W.deleteFramebuffer(x),x.name=0,rc[q]=null)}},glDeleteProgram:c=>{if(c){var e=X[c];e?(W.deleteProgram(e),e.name=0,X[c]=null):Z||=1281}},glDeleteRenderbuffers:(c,e)=>{for(var l=0;l<c;l++){var q=L[e+4*l>>2],x=sc[q];x&&(W.deleteRenderbuffer(x),x.name=0,sc[q]=null)}},glDeleteSamplers:(c,e)=>{for(var l=0;l<c;l++){var q=L[e+4*l>>2],x=vc[q];x&&(W.deleteSampler(x),x.name=0,vc[q]=null)}},glDeleteShader:c=>{if(c){var e=Y[c];e?(W.deleteShader(e),Y[c]=null):
568
568
  Z||=1281}},glDeleteTextures:(c,e)=>{for(var l=0;l<c;l++){var q=L[e+4*l>>2],x=tc[q];x&&(W.deleteTexture(x),x.name=0,tc[q]=null)}},glDeleteVertexArrays:(c,e)=>{for(var l=0;l<c;l++){var q=L[e+4*l>>2];W.deleteVertexArray(uc[q]);uc[q]=null}},glDepthFunc:c=>W.depthFunc(c),glDepthMask:c=>{W.depthMask(!!c)},glDepthRangef:(c,e)=>W.depthRange(c,e),glDisable:c=>W.disable(c),glDisableVertexAttribArray:c=>{W.disableVertexAttribArray(c)},glDrawArrays:(c,e,l)=>{W.drawArrays(c,e,l)},glDrawArraysInstanced:(c,e,l,
569
- q)=>{W.drawArraysInstanced(c,e,l,q)},glDrawBuffers:(c,e)=>{for(var l=Gc[c],q=0;q<c;q++)l[q]=L[e+4*q>>2];W.drawBuffers(l)},glDrawElements:(c,e,l,q)=>{W.drawElements(c,e,l,q)},glDrawElementsInstanced:(c,e,l,q,x)=>{W.drawElementsInstanced(c,e,l,q,x)},glEnable:c=>W.enable(c),glEnableVertexAttribArray:c=>{W.enableVertexAttribArray(c)},glFinish:()=>W.finish(),glFlush:()=>W.flush(),glFramebufferRenderbuffer:(c,e,l,q)=>{W.framebufferRenderbuffer(c,e,l,sc[q])},glFramebufferTexture2D:(c,e,l,q,x)=>{W.framebufferTexture2D(c,
570
- e,l,tc[q],x)},glFramebufferTextureLayer:(c,e,l,q,x)=>{W.framebufferTextureLayer(c,e,tc[l],q,x)},glFrontFace:c=>W.frontFace(c),glGenBuffers:(c,e)=>{Bc(c,e,"createBuffer",qc)},glGenFramebuffers:(c,e)=>{Bc(c,e,"createFramebuffer",rc)},glGenRenderbuffers:(c,e)=>{Bc(c,e,"createRenderbuffer",sc)},glGenSamplers:(c,e)=>{Bc(c,e,"createSampler",vc)},glGenTextures:(c,e)=>{Bc(c,e,"createTexture",tc)},glGenVertexArrays:(c,e)=>{Bc(c,e,"createVertexArray",uc)},glGenerateMipmap:c=>W.generateMipmap(c),glGetFloatv:(c,
571
- e)=>Ic(c,e,2),glGetFramebufferAttachmentParameteriv:(c,e,l,q)=>{c=W.getFramebufferAttachmentParameter(c,e,l);if(c instanceof WebGLRenderbuffer||c instanceof WebGLTexture)c=c.name|0;L[q>>2]=c},glGetIntegerv:(c,e)=>Ic(c,e,0),glGetProgramInfoLog:(c,e,l,q)=>{c=W.getProgramInfoLog(X[c]);null===c&&(c="(unknown error)");e=0<e&&q?Wb(c,q,e):0;l&&(L[l>>2]=e)},glGetProgramiv:(c,e,l)=>{if(l)if(c>=pc)Z||=1281;else if(c=X[c],35716==e)c=W.getProgramInfoLog(c),null===c&&(c="(unknown error)"),L[l>>2]=c.length+1;else if(35719==
569
+ q)=>{W.drawArraysInstanced(c,e,l,q)},glDrawBuffers:(c,e)=>{for(var l=Gc[c],q=0;q<c;q++)l[q]=L[e+4*q>>2];W.drawBuffers(l)},glDrawElements:(c,e,l,q)=>{W.drawElements(c,e,l,q)},glDrawElementsInstanced:(c,e,l,q,x)=>{W.drawElementsInstanced(c,e,l,q,x)},glEnable:c=>W.enable(c),glEnableVertexAttribArray:c=>{W.enableVertexAttribArray(c)},glFlush:()=>W.flush(),glFramebufferRenderbuffer:(c,e,l,q)=>{W.framebufferRenderbuffer(c,e,l,sc[q])},glFramebufferTexture2D:(c,e,l,q,x)=>{W.framebufferTexture2D(c,e,l,tc[q],
570
+ x)},glFramebufferTextureLayer:(c,e,l,q,x)=>{W.framebufferTextureLayer(c,e,tc[l],q,x)},glFrontFace:c=>W.frontFace(c),glGenBuffers:(c,e)=>{Bc(c,e,"createBuffer",qc)},glGenFramebuffers:(c,e)=>{Bc(c,e,"createFramebuffer",rc)},glGenRenderbuffers:(c,e)=>{Bc(c,e,"createRenderbuffer",sc)},glGenSamplers:(c,e)=>{Bc(c,e,"createSampler",vc)},glGenTextures:(c,e)=>{Bc(c,e,"createTexture",tc)},glGenVertexArrays:(c,e)=>{Bc(c,e,"createVertexArray",uc)},glGenerateMipmap:c=>W.generateMipmap(c),glGetFloatv:(c,e)=>Ic(c,
571
+ e,2),glGetFramebufferAttachmentParameteriv:(c,e,l,q)=>{c=W.getFramebufferAttachmentParameter(c,e,l);if(c instanceof WebGLRenderbuffer||c instanceof WebGLTexture)c=c.name|0;L[q>>2]=c},glGetIntegerv:(c,e)=>Ic(c,e,0),glGetProgramInfoLog:(c,e,l,q)=>{c=W.getProgramInfoLog(X[c]);null===c&&(c="(unknown error)");e=0<e&&q?Wb(c,q,e):0;l&&(L[l>>2]=e)},glGetProgramiv:(c,e,l)=>{if(l)if(c>=pc)Z||=1281;else if(c=X[c],35716==e)c=W.getProgramInfoLog(c),null===c&&(c="(unknown error)"),L[l>>2]=c.length+1;else if(35719==
572
572
  e){if(!c.sa){var q=W.getProgramParameter(c,35718);for(e=0;e<q;++e)c.sa=Math.max(c.sa,W.getActiveUniform(c,e).name.length+1)}L[l>>2]=c.sa}else if(35722==e){if(!c.qa)for(q=W.getProgramParameter(c,35721),e=0;e<q;++e)c.qa=Math.max(c.qa,W.getActiveAttrib(c,e).name.length+1);L[l>>2]=c.qa}else if(35381==e){if(!c.ra)for(q=W.getProgramParameter(c,35382),e=0;e<q;++e)c.ra=Math.max(c.ra,W.getActiveUniformBlockName(c,e).length+1);L[l>>2]=c.ra}else L[l>>2]=W.getProgramParameter(c,e);else Z||=1281},glGetShaderInfoLog:(c,
573
573
  e,l,q)=>{c=W.getShaderInfoLog(Y[c]);null===c&&(c="(unknown error)");e=0<e&&q?Wb(c,q,e):0;l&&(L[l>>2]=e)},glGetShaderiv:(c,e,l)=>{l?35716==e?(c=W.getShaderInfoLog(Y[c]),null===c&&(c="(unknown error)"),L[l>>2]=c?c.length+1:0):35720==e?(c=W.getShaderSource(Y[c]),L[l>>2]=c?c.length+1:0):L[l>>2]=W.getShaderParameter(Y[c],e):Z||=1281},glGetString:c=>{var e=wc[c];if(!e){switch(c){case 7939:e=Kc(Hc().join(" "));break;case 7936:case 7937:case 37445:case 37446:(e=W.getParameter(c))||(Z||=1280);e=e?Kc(e):0;
574
574
  break;case 7938:e=Kc(`OpenGL ES 3.0 (${W.getParameter(7938)})`);break;case 35724:e=W.getParameter(35724);var l=e.match(/^WebGL GLSL ES ([0-9]\.[0-9][0-9]?)(?:$| .*)/);null!==l&&(3==l[1].length&&(l[1]+="0"),e=`OpenGL ES GLSL ES ${l[1]} (${e})`);e=Kc(e);break;default:Z||=1280}wc[c]=e}return e},glGetStringi:(c,e)=>{if(2>E.version)return Z||=1282,0;var l=xc[c];if(l)return 0>e||e>=l.length?(Z||=1281,0):l[e];switch(c){case 7939:return l=Hc().map(Kc),l=xc[c]=l,0>e||e>=l.length?(Z||=1281,0):l[e];default:return Z||=
575
- 1280,0}},glGetUniformBlockIndex:(c,e)=>W.getUniformBlockIndex(X[c],e?Ta(J,e):""),glGetUniformLocation:(c,e)=>{e=e?Ta(J,e):"";if(c=X[c]){var l=c,q=l.ea,x=l.Za,y;if(!q){l.ea=q={};l.Ya={};var z=W.getProgramParameter(l,35718);for(y=0;y<z;++y){var A=W.getActiveUniform(l,y);var D=A.name;A=A.size;var G=Lc(D);G=0<G?D.slice(0,G):D;var u=l.Ia;l.Ia+=A;x[G]=[A,u];for(D=0;D<A;++D)q[u]=D,l.Ya[u++]=G}}l=c.ea;q=0;x=e;y=Lc(e);0<y&&(q=parseInt(e.slice(y+1))>>>0,x=e.slice(0,y));if((x=c.Za[x])&&q<x[0]&&(q+=x[1],l[q]=
576
- l[q]||W.getUniformLocation(c,e)))return q}else Z||=1281;return-1},glInvalidateFramebuffer:(c,e,l)=>{for(var q=Gc[e],x=0;x<e;x++)q[x]=L[l+4*x>>2];W.invalidateFramebuffer(c,q)},glIsBuffer:c=>(c=qc[c])?W.isBuffer(c):0,glIsFramebuffer:c=>(c=rc[c])?W.isFramebuffer(c):0,glIsProgram:c=>(c=X[c])?W.isProgram(c):0,glIsVertexArray:c=>(c=uc[c])?W.isVertexArray(c):0,glLinkProgram:c=>{c=X[c];W.linkProgram(c);c.ea=0;c.Za={}},glPixelStorei:(c,e)=>{3317==c?yc=e:3314==c&&(zc=e);W.pixelStorei(c,e)},glPolygonOffset:(c,
577
- e)=>W.polygonOffset(c,e),glReadBuffer:c=>W.readBuffer(c),glReadPixels:(c,e,l,q,x,y,z)=>{if(W.Ca)W.readPixels(c,e,l,q,x,y,z);else{var A=Mc(y);z>>>=31-Math.clz32(A.BYTES_PER_ELEMENT);W.readPixels(c,e,l,q,x,y,A,z)}},glRenderbufferStorage:(c,e,l,q)=>W.renderbufferStorage(c,e,l,q),glRenderbufferStorageMultisample:(c,e,l,q,x)=>W.renderbufferStorageMultisample(c,e,l,q,x),glSamplerParameterf:(c,e,l)=>{W.samplerParameterf(vc[c],e,l)},glSamplerParameteri:(c,e,l)=>{W.samplerParameteri(vc[c],e,l)},glScissor:(c,
578
- e,l,q)=>W.scissor(c,e,l,q),glShaderSource:(c,e,l,q)=>{for(var x="",y=0;y<e;++y){var z=(z=M[l+4*y>>2])?Ta(J,z,q?M[q+4*y>>2]:void 0):"";x+=z}W.shaderSource(Y[c],x)},glStencilFunc:(c,e,l)=>W.stencilFunc(c,e,l),glStencilFuncSeparate:(c,e,l,q)=>W.stencilFuncSeparate(c,e,l,q),glStencilMask:c=>W.stencilMask(c),glStencilMaskSeparate:(c,e)=>W.stencilMaskSeparate(c,e),glStencilOp:(c,e,l)=>W.stencilOp(c,e,l),glStencilOpSeparate:(c,e,l,q)=>W.stencilOpSeparate(c,e,l,q),glTexParameteri:(c,e,l)=>W.texParameteri(c,
579
- e,l),glTexStorage2D:(c,e,l,q,x)=>W.texStorage2D(c,e,l,q,x),glTexStorage3D:(c,e,l,q,x,y)=>W.texStorage3D(c,e,l,q,x,y),glTexSubImage2D:(c,e,l,q,x,y,z,A,D)=>{if(W.Y)W.texSubImage2D(c,e,l,q,x,y,z,A,D);else if(D){var G=Mc(A);W.texSubImage2D(c,e,l,q,x,y,z,A,G,D>>>31-Math.clz32(G.BYTES_PER_ELEMENT))}else{if(D){G=Mc(A);var u=y*((zc||x)*({5:3,6:4,8:2,29502:3,29504:4,26917:2,26918:2,29846:3,29847:4}[z-6402]||1)*G.BYTES_PER_ELEMENT+yc-1&-yc);D=G.subarray(D>>>31-Math.clz32(G.BYTES_PER_ELEMENT),D+u>>>31-Math.clz32(G.BYTES_PER_ELEMENT))}else D=
580
- null;W.texSubImage2D(c,e,l,q,x,y,z,A,D)}},glTexSubImage3D:(c,e,l,q,x,y,z,A,D,G,u)=>{if(W.Y)W.texSubImage3D(c,e,l,q,x,y,z,A,D,G,u);else if(u){var a=Mc(G);W.texSubImage3D(c,e,l,q,x,y,z,A,D,G,a,u>>>31-Math.clz32(a.BYTES_PER_ELEMENT))}else W.texSubImage3D(c,e,l,q,x,y,z,A,D,G,null)},glUniform1i:(c,e)=>{var l=W,q=l.uniform1i;var x=W.nb;if(x){var y=x.ea[c];"number"==typeof y&&(x.ea[c]=y=W.getUniformLocation(x,x.Ya[c]+(0<y?`[${y}]`:"")));c=y}else Z||=1282,c=void 0;q.call(l,c,e)},glUniformBlockBinding:(c,
581
- e,l)=>{c=X[c];W.uniformBlockBinding(c,e,l)},glUseProgram:c=>{c=X[c];W.useProgram(c);W.nb=c},glVertexAttribDivisor:(c,e)=>{W.vertexAttribDivisor(c,e)},glVertexAttribIPointer:(c,e,l,q,x)=>{W.vertexAttribIPointer(c,e,l,q,x)},glVertexAttribPointer:(c,e,l,q,x,y)=>{W.vertexAttribPointer(c,e,l,!!q,x,y)},glViewport:(c,e,l,q)=>W.viewport(c,e,l,q),invoke_vii:Zc,isWindowsBrowser:function(){return-1<navigator.platform.indexOf("Win")},provokingVertexWEBGL:function(c,e){(c=I[c].F.Ua)&&c.provokingVertexWEBGL(e)},
582
- riveWebCall:function(c,e,l,q,x,y,z){return C.riveScripting.call(c,e,l,q,x,y,z)},riveWebHasExport:function(c,e){return C.riveScripting.Ab(c,e)},riveWebMemoryPages:function(c){return C.riveScripting.Hb(c)},riveWebPreparing:function(c){return C.riveScripting.V(c)},riveWebRaise:function(c,e){C.riveScripting.Kb(c,e)},riveWebReadMemory:function(c,e,l,q){return C.riveScripting.read(c,e,l,q)},riveWebRegister:function(c,e,l){const q=C.riveScripting;if(!q)return 0;q.ib({exports:C,Bb:x=>{x=M[(Wc()>>2)+x];return 0===
583
- x?void 0:Hb.get(x)},Z:()=>J,Pa:()=>za,da:Qa,ua:Oc,ca:Oa,Ga:Jc,Da:cb,Ja:x=>x?Ta(J,x):"",ab:(x,y,z)=>Wb(x,y,z)});q.register(c,J.subarray(e,e+l));return 1},riveWebRelease:function(c){C.riveScripting?.release(c)},riveWebStart:function(c){c=C.riveScripting.start(c);return null===c?0:Kc(c)},riveWebStringLength:function(c,e){return C.riveScripting.Ch(c,e)},riveWebWriteMemory:function(c,e,l,q){return C.riveScripting.write(c,e,l,q)},upload_image:function(c,e){var l=C.images;l&&(e=l.get(e))&&(c=I[c].F,c.pixelStorei(c.UNPACK_PREMULTIPLY_ALPHA_WEBGL,
584
- !0),c.texImage2D(c.TEXTURE_2D,0,c.RGBA,c.RGBA,c.UNSIGNED_BYTE,e),c.pixelStorei(c.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!1))},wasm_start_image_decode:function(c,e,l){e=new Uint8Array(Ca.buffer,e,l);var q=new Uint8Array(l);q.set(e);Promise.resolve().then(function(){return createImageBitmap(new Blob([q]))}).then(function(x){var y=(new OffscreenCanvas(x.width,x.height)).getContext("2d");y.drawImage(x,0,0);y=y.getImageData(0,0,x.width,x.height);var z=y.data.length,A=Tc(z);A?((new Uint8Array(Ca.buffer,A,z)).set(y.data),
585
- Uc(c,x.width,x.height,A,z)):Vc(c)}).catch(function(){Vc(c)})}};function Zc(c,e,l){var q=Pa();try{Hb.get(c)(e,l)}catch(x){Na(q);if(x!==x+0)throw x;Xc(1,0)}}var ad;
586
- ad=await (async function(){function c(l){l=ad=l.exports;cb=l.free;Jc=l.malloc;C._setWebImage=l.setWebImage;bb=l.__getTypeName;Tc=C._wasm_image_decode_alloc=l.wasm_image_decode_alloc;Uc=C._wasm_image_decode_complete=l.wasm_image_decode_complete;Vc=C._wasm_image_decode_error=l.wasm_image_decode_error;C._rive_web_vm_module_export=l.rive_web_vm_module_export;C._rive_web_vm_booting=l.rive_web_vm_booting;Wc=C._rive_web_calls=l.rive_web_calls;Pc=C._ma_device__on_notification_unlocked=l.ma_device__on_notification_unlocked;
587
- C._ma_malloc_emscripten=l.ma_malloc_emscripten;C._ma_free_emscripten=l.ma_free_emscripten;Qc=C._ma_device_process_pcm_frames_capture__webaudio=l.ma_device_process_pcm_frames_capture__webaudio;Rc=C._ma_device_process_pcm_frames_playback__webaudio=l.ma_device_process_pcm_frames_playback__webaudio;Xc=l.setThrew;Yc=l._emscripten_tempret_set;Na=l._emscripten_stack_restore;Nc=l._emscripten_stack_alloc;Pa=l.emscripten_stack_get_current;U.vij=l.dynCall_vij;U.iij=l.dynCall_iij;U.ji=l.dynCall_ji;U.iijii=l.dynCall_iijii;
588
- U.iiiji=l.dynCall_iiiji;U.iiji=l.dynCall_iiji;U.jii=l.dynCall_jii;U.vijj=l.dynCall_vijj;U.jiji=l.dynCall_jiji;Ca=l.memory;Hb=l.__indirect_function_table;Ba();return ad}var e={env:$c,wasi_snapshot_preview1:$c};if(C.instantiateWasm)return new Promise(l=>{C.instantiateWasm(e,(q,x)=>{l(c(q,x))})});Ea??=C.locateFile?C.locateFile("webgl2_advanced.wasm",la):la+"webgl2_advanced.wasm";return c((await Ha(e)).instance)}());
589
- (function(){function c(){C.calledRun=!0;if(!sa){Aa=!0;ad.__wasm_call_ctors();ta?.(C);C.onRuntimeInitialized?.();if(C.postRun)for("function"==typeof C.postRun&&(C.postRun=[C.postRun]);C.postRun.length;){var e=C.postRun.shift();Ka.push(e)}Ja(Ka)}}if(C.preRun)for("function"==typeof C.preRun&&(C.preRun=[C.preRun]);C.preRun.length;)Ma();Ja(La);C.setStatus?(C.setStatus("Running..."),setTimeout(()=>{setTimeout(()=>C.setStatus(""),1);c()},1)):c()})();Aa?moduleRtn=C:moduleRtn=new Promise((c,e)=>{ta=c;ua=e});
575
+ 1280,0}},glGetUniformBlockIndex:(c,e)=>W.getUniformBlockIndex(X[c],e?Ta(J,e):""),glGetUniformLocation:(c,e)=>{e=e?Ta(J,e):"";if(c=X[c]){var l=c,q=l.ea,x=l.Za,y;if(!q){l.ea=q={};l.Ya={};var z=W.getProgramParameter(l,35718);for(y=0;y<z;++y){var A=W.getActiveUniform(l,y);var C=A.name;A=A.size;var G=Lc(C);G=0<G?C.slice(0,G):C;var u=l.Ia;l.Ia+=A;x[G]=[A,u];for(C=0;C<A;++C)q[u]=C,l.Ya[u++]=G}}l=c.ea;q=0;x=e;y=Lc(e);0<y&&(q=parseInt(e.slice(y+1))>>>0,x=e.slice(0,y));if((x=c.Za[x])&&q<x[0]&&(q+=x[1],l[q]=
576
+ l[q]||W.getUniformLocation(c,e)))return q}else Z||=1281;return-1},glInvalidateFramebuffer:(c,e,l)=>{for(var q=Gc[e],x=0;x<e;x++)q[x]=L[l+4*x>>2];W.invalidateFramebuffer(c,q)},glLinkProgram:c=>{c=X[c];W.linkProgram(c);c.ea=0;c.Za={}},glPixelStorei:(c,e)=>{3317==c?yc=e:3314==c&&(zc=e);W.pixelStorei(c,e)},glPolygonOffset:(c,e)=>W.polygonOffset(c,e),glReadBuffer:c=>W.readBuffer(c),glReadPixels:(c,e,l,q,x,y,z)=>{if(W.Ca)W.readPixels(c,e,l,q,x,y,z);else{var A=Mc(y);z>>>=31-Math.clz32(A.BYTES_PER_ELEMENT);
577
+ W.readPixels(c,e,l,q,x,y,A,z)}},glRenderbufferStorage:(c,e,l,q)=>W.renderbufferStorage(c,e,l,q),glRenderbufferStorageMultisample:(c,e,l,q,x)=>W.renderbufferStorageMultisample(c,e,l,q,x),glSamplerParameterf:(c,e,l)=>{W.samplerParameterf(vc[c],e,l)},glSamplerParameteri:(c,e,l)=>{W.samplerParameteri(vc[c],e,l)},glScissor:(c,e,l,q)=>W.scissor(c,e,l,q),glShaderSource:(c,e,l,q)=>{for(var x="",y=0;y<e;++y){var z=(z=M[l+4*y>>2])?Ta(J,z,q?M[q+4*y>>2]:void 0):"";x+=z}W.shaderSource(Y[c],x)},glStencilFunc:(c,
578
+ e,l)=>W.stencilFunc(c,e,l),glStencilFuncSeparate:(c,e,l,q)=>W.stencilFuncSeparate(c,e,l,q),glStencilMask:c=>W.stencilMask(c),glStencilMaskSeparate:(c,e)=>W.stencilMaskSeparate(c,e),glStencilOp:(c,e,l)=>W.stencilOp(c,e,l),glStencilOpSeparate:(c,e,l,q)=>W.stencilOpSeparate(c,e,l,q),glTexParameteri:(c,e,l)=>W.texParameteri(c,e,l),glTexStorage2D:(c,e,l,q,x)=>W.texStorage2D(c,e,l,q,x),glTexStorage3D:(c,e,l,q,x,y)=>W.texStorage3D(c,e,l,q,x,y),glTexSubImage2D:(c,e,l,q,x,y,z,A,C)=>{if(W.Y)W.texSubImage2D(c,
579
+ e,l,q,x,y,z,A,C);else if(C){var G=Mc(A);W.texSubImage2D(c,e,l,q,x,y,z,A,G,C>>>31-Math.clz32(G.BYTES_PER_ELEMENT))}else{if(C){G=Mc(A);var u=y*((zc||x)*({5:3,6:4,8:2,29502:3,29504:4,26917:2,26918:2,29846:3,29847:4}[z-6402]||1)*G.BYTES_PER_ELEMENT+yc-1&-yc);C=G.subarray(C>>>31-Math.clz32(G.BYTES_PER_ELEMENT),C+u>>>31-Math.clz32(G.BYTES_PER_ELEMENT))}else C=null;W.texSubImage2D(c,e,l,q,x,y,z,A,C)}},glTexSubImage3D:(c,e,l,q,x,y,z,A,C,G,u)=>{if(W.Y)W.texSubImage3D(c,e,l,q,x,y,z,A,C,G,u);else if(u){var a=
580
+ Mc(G);W.texSubImage3D(c,e,l,q,x,y,z,A,C,G,a,u>>>31-Math.clz32(a.BYTES_PER_ELEMENT))}else W.texSubImage3D(c,e,l,q,x,y,z,A,C,G,null)},glUniform1i:(c,e)=>{var l=W,q=l.uniform1i;var x=W.nb;if(x){var y=x.ea[c];"number"==typeof y&&(x.ea[c]=y=W.getUniformLocation(x,x.Ya[c]+(0<y?`[${y}]`:"")));c=y}else Z||=1282,c=void 0;q.call(l,c,e)},glUniformBlockBinding:(c,e,l)=>{c=X[c];W.uniformBlockBinding(c,e,l)},glUseProgram:c=>{c=X[c];W.useProgram(c);W.nb=c},glVertexAttribDivisor:(c,e)=>{W.vertexAttribDivisor(c,e)},
581
+ glVertexAttribIPointer:(c,e,l,q,x)=>{W.vertexAttribIPointer(c,e,l,q,x)},glVertexAttribPointer:(c,e,l,q,x,y)=>{W.vertexAttribPointer(c,e,l,!!q,x,y)},glViewport:(c,e,l,q)=>W.viewport(c,e,l,q),invoke_vii:Zc,isWindowsBrowser:function(){return-1<navigator.platform.indexOf("Win")},provokingVertexWEBGL:function(c,e){(c=I[c].F.Ua)&&c.provokingVertexWEBGL(e)},riveWebCall:function(c,e,l,q,x,y,z){return D.riveScripting.call(c,e,l,q,x,y,z)},riveWebHasExport:function(c,e){return D.riveScripting.Ab(c,e)},riveWebMemoryPages:function(c){return D.riveScripting.Hb(c)},
582
+ riveWebPreparing:function(c){return D.riveScripting.V(c)},riveWebRaise:function(c,e){D.riveScripting.Kb(c,e)},riveWebReadMemory:function(c,e,l,q){return D.riveScripting.read(c,e,l,q)},riveWebRegister:function(c,e,l){const q=D.riveScripting;if(!q)return 0;q.ib({exports:D,Bb:x=>{x=M[(Wc()>>2)+x];return 0===x?void 0:Hb.get(x)},Z:()=>J,Pa:()=>za,da:Qa,ua:Oc,ca:Oa,Ga:Jc,Da:cb,Ja:x=>x?Ta(J,x):"",ab:(x,y,z)=>Wb(x,y,z)});q.register(c,J.subarray(e,e+l));return 1},riveWebRelease:function(c){D.riveScripting?.release(c)},
583
+ riveWebStart:function(c){c=D.riveScripting.start(c);return null===c?0:Kc(c)},riveWebStringLength:function(c,e){return D.riveScripting.Ch(c,e)},riveWebWriteMemory:function(c,e,l,q){return D.riveScripting.write(c,e,l,q)},upload_image:function(c,e){var l=D.images;l&&(e=l.get(e))&&(c=I[c].F,c.pixelStorei(c.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!0),c.texImage2D(c.TEXTURE_2D,0,c.RGBA,c.RGBA,c.UNSIGNED_BYTE,e),c.pixelStorei(c.UNPACK_PREMULTIPLY_ALPHA_WEBGL,!1))},wasm_start_image_decode:function(c,e,l){e=new Uint8Array(Ca.buffer,
584
+ e,l);var q=new Uint8Array(l);q.set(e);Promise.resolve().then(function(){return createImageBitmap(new Blob([q]))}).then(function(x){var y=(new OffscreenCanvas(x.width,x.height)).getContext("2d");y.drawImage(x,0,0);y=y.getImageData(0,0,x.width,x.height);var z=y.data.length,A=Tc(z);A?((new Uint8Array(Ca.buffer,A,z)).set(y.data),Uc(c,x.width,x.height,A,z)):Vc(c)}).catch(function(){Vc(c)})}};function Zc(c,e,l){var q=Pa();try{Hb.get(c)(e,l)}catch(x){Na(q);if(x!==x+0)throw x;Xc(1,0)}}var ad;
585
+ ad=await (async function(){function c(l){l=ad=l.exports;cb=l.free;Jc=l.malloc;D._setWebImage=l.setWebImage;bb=l.__getTypeName;Tc=D._wasm_image_decode_alloc=l.wasm_image_decode_alloc;Uc=D._wasm_image_decode_complete=l.wasm_image_decode_complete;Vc=D._wasm_image_decode_error=l.wasm_image_decode_error;D._rive_web_vm_module_export=l.rive_web_vm_module_export;D._rive_web_vm_booting=l.rive_web_vm_booting;Wc=D._rive_web_calls=l.rive_web_calls;Pc=D._ma_device__on_notification_unlocked=l.ma_device__on_notification_unlocked;
586
+ D._ma_malloc_emscripten=l.ma_malloc_emscripten;D._ma_free_emscripten=l.ma_free_emscripten;Qc=D._ma_device_process_pcm_frames_capture__webaudio=l.ma_device_process_pcm_frames_capture__webaudio;Rc=D._ma_device_process_pcm_frames_playback__webaudio=l.ma_device_process_pcm_frames_playback__webaudio;Xc=l.setThrew;Yc=l._emscripten_tempret_set;Na=l._emscripten_stack_restore;Nc=l._emscripten_stack_alloc;Pa=l.emscripten_stack_get_current;U.vij=l.dynCall_vij;U.iij=l.dynCall_iij;U.ji=l.dynCall_ji;U.iijii=l.dynCall_iijii;
587
+ U.iiiji=l.dynCall_iiiji;U.iiji=l.dynCall_iiji;U.jii=l.dynCall_jii;U.vijj=l.dynCall_vijj;U.jiji=l.dynCall_jiji;Ca=l.memory;Hb=l.__indirect_function_table;Ba();return ad}var e={env:$c,wasi_snapshot_preview1:$c};if(D.instantiateWasm)return new Promise(l=>{D.instantiateWasm(e,(q,x)=>{l(c(q,x))})});Ea??=D.locateFile?D.locateFile("webgl2_advanced.wasm",la):la+"webgl2_advanced.wasm";return c((await Ha(e)).instance)}());
588
+ (function(){function c(){D.calledRun=!0;if(!sa){Aa=!0;ad.__wasm_call_ctors();ta?.(D);D.onRuntimeInitialized?.();if(D.postRun)for("function"==typeof D.postRun&&(D.postRun=[D.postRun]);D.postRun.length;){var e=D.postRun.shift();Ka.push(e)}Ja(Ka)}}if(D.preRun)for("function"==typeof D.preRun&&(D.preRun=[D.preRun]);D.preRun.length;)Ma();Ja(La);D.setStatus?(D.setStatus("Running..."),setTimeout(()=>{setTimeout(()=>D.setStatus(""),1);c()},1)):c()})();Aa?moduleRtn=D:moduleRtn=new Promise((c,e)=>{ta=c;ua=e});
590
589
  ;return moduleRtn}})();
591
590
  /* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (Rive);
592
591
 
@@ -595,7 +594,7 @@ U.iiiji=l.dynCall_iiiji;U.iiji=l.dynCall_iiji;U.jii=l.dynCall_jii;U.vijj=l.dynCa
595
594
  /* 5 */
596
595
  /***/ ((module) => {
597
596
 
598
- module.exports = /*#__PURE__*/JSON.parse('{"name":"@rive-app/webgl2","version":"2.44.1","description":"Rive\'s webgl2 based web api.","main":"rive.js","homepage":"https://rive.app","repository":{"type":"git","url":"https://github.com/rive-app/rive-wasm/tree/master/js"},"keywords":["rive","animation"],"author":"Rive","contributors":["Luigi Rosso <luigi@rive.app> (https://rive.app)","Maxwell Talbot <max@rive.app> (https://rive.app)","Arthur Vivian <arthur@rive.app> (https://rive.app)","Umberto Sonnino <umberto@rive.app> (https://rive.app)","Matthew Sullivan <matt.j.sullivan@gmail.com> (mailto:matt.j.sullivan@gmail.com)","Chris Dalton <chris@rive.app> (https://rive.app)"],"license":"MIT","files":["rive.js","rive.wasm","rive_fallback.wasm","rive.js.map","rive.d.ts","rive_advanced.mjs.d.ts","runtimeLoader.d.ts","utils","semantics"],"typings":"rive.d.ts","dependencies":{},"browser":{"fs":false,"path":false}}');
597
+ module.exports = /*#__PURE__*/JSON.parse('{"name":"@rive-app/webgl2","version":"2.44.2","description":"Rive\'s webgl2 based web api.","main":"rive.js","homepage":"https://rive.app","repository":{"type":"git","url":"https://github.com/rive-app/rive-wasm/tree/master/js"},"keywords":["rive","animation"],"author":"Rive","contributors":["Luigi Rosso <luigi@rive.app> (https://rive.app)","Maxwell Talbot <max@rive.app> (https://rive.app)","Arthur Vivian <arthur@rive.app> (https://rive.app)","Umberto Sonnino <umberto@rive.app> (https://rive.app)","Matthew Sullivan <matt.j.sullivan@gmail.com> (mailto:matt.j.sullivan@gmail.com)","Chris Dalton <chris@rive.app> (https://rive.app)"],"license":"MIT","files":["rive.js","rive.wasm","rive_fallback.wasm","rive.js.map","rive.d.ts","rive_advanced.mjs.d.ts","runtimeLoader.d.ts","utils","semantics"],"typings":"rive.d.ts","dependencies":{},"browser":{"fs":false,"path":false}}');
599
598
 
600
599
  /***/ }),
601
600
  /* 6 */