@uptimizr/dashboard 0.1.2 → 0.2.0
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/out/404.html +1 -1
- package/out/__next.__PAGE__.txt +4 -4
- package/out/__next._full.txt +11 -11
- package/out/__next._head.txt +4 -4
- package/out/__next._index.txt +4 -4
- package/out/__next._tree.txt +2 -2
- package/out/_next/static/chunks/002cjeoit6-up.js +1 -0
- package/out/_next/static/chunks/02n1uiltexy3w.js +1 -0
- package/out/_next/static/chunks/03ab2khhe8-x5.js +1 -0
- package/out/_next/static/chunks/04_yytpc2paxy.js +1 -0
- package/out/_next/static/chunks/06qot1qvlsqaz.js +1 -0
- package/out/_next/static/chunks/07eeopuufsqp-.js +1501 -0
- package/out/_next/static/chunks/08a5xek662n8n.js +1 -0
- package/out/_next/static/chunks/08wuc9--s8zn_.js +1 -0
- package/out/_next/static/chunks/0927l-ygd5c8d.js +1 -0
- package/out/_next/static/chunks/09510356f0lad.js +1 -0
- package/out/_next/static/chunks/0_eu72k69lxj7.js +1 -0
- package/out/_next/static/chunks/0beajlqy8p8b5.js +1 -0
- package/out/_next/static/chunks/0c83pe1mpx456.js +1 -0
- package/out/_next/static/chunks/0echnagbkyx79.js +1198 -0
- package/out/_next/static/chunks/0eh1ml86u8dh7.js +1 -0
- package/out/_next/static/chunks/0fh-9h9ylxskr.js +674 -0
- package/out/_next/static/chunks/0fzmc1up21g1i.js +1 -0
- package/out/_next/static/chunks/0g_v2zswo4l6f.js +1 -0
- package/out/_next/static/chunks/0grlb9lo8e502.js +1 -0
- package/out/_next/static/chunks/0h22pg-0xrxnm.js +1 -0
- package/out/_next/static/chunks/0j6p1pmc14t96.js +1 -0
- package/out/_next/static/chunks/0j_6dx-sttgsy.js +1 -0
- package/out/_next/static/chunks/0j__xaq_8_di1.js +1 -0
- package/out/_next/static/chunks/0kfd-cvj5fvtz.js +1 -0
- package/out/_next/static/chunks/0o_mp98xzqfyf.js +1 -0
- package/out/_next/static/chunks/0otsec99kdkt7.js +213 -0
- package/out/_next/static/chunks/0ql-s-tsmel_u.js +151 -0
- package/out/_next/static/chunks/0r47gs_e93cka.js +1 -0
- package/out/_next/static/chunks/0sqys6o2pbe1q.js +1328 -0
- package/out/_next/static/chunks/0titqrn1qmcsv.js +1 -0
- package/out/_next/static/chunks/0tnlbw78tgaxp.js +4 -0
- package/out/_next/static/chunks/0tw4dyl-cp-hd.js +1 -0
- package/out/_next/static/chunks/0vbce-8omgurc.js +1 -0
- package/out/_next/static/chunks/0vfsg5byzep_0.js +1 -0
- package/out/_next/static/chunks/{0gv7mblzv3dl3.js → 0w8_1yjvol1f0.js} +20 -20
- package/out/_next/static/chunks/0xh144a5fz58h.js +1 -0
- package/out/_next/static/chunks/0xjltg_pph0c8.js +1 -0
- package/out/_next/static/chunks/0yeqgh0dnas8d.js +1 -0
- package/out/_next/static/chunks/101-7e_7up7rk.js +1 -0
- package/out/_next/static/chunks/128e51hj_04r0.js +1 -0
- package/out/_next/static/chunks/{10fnxpln_5xfd.js → 12kv810lohbsx.js} +2 -2
- package/out/_next/static/chunks/137xbvd4nd41j.js +3 -0
- package/out/_next/static/chunks/14bws-suyy5zu.js +1 -0
- package/out/_next/static/chunks/14ggsmqwej_tt.js +1656 -0
- package/out/_next/static/chunks/17genz6pkmty_.js +1 -0
- package/out/_next/static/chunks/17xd8hnazzr0g.js +1454 -0
- package/out/_next/static/chunks/18dczy9ylt2s_.js +1 -0
- package/out/_next/static/chunks/18xs_kvsaolb0.js +1 -0
- package/out/_next/static/chunks/19016f8-ry0z6.js +1 -0
- package/out/_next/static/chunks/1_6oejyxj39li.js +1 -0
- package/out/_next/static/chunks/1_aon8nz9p1fr.js +1 -0
- package/out/_next/static/chunks/1_qzlkuxukhpq.js +779 -0
- package/out/_next/static/chunks/1akaj5rhgitn3.js +1 -0
- package/out/_next/static/chunks/1bvl1ws7b_3gn.js +1 -0
- package/out/_next/static/chunks/1cdbk6kxyr1c9.js +1 -0
- package/out/_next/static/chunks/1fbjkk55uu4_g.js +1 -0
- package/out/_next/static/chunks/1furcfsgrw_3g.js +1 -0
- package/out/_next/static/chunks/1g0-f1g3gn_rs.js +1 -0
- package/out/_next/static/chunks/1g7emwu85bifo.js +557 -0
- package/out/_next/static/chunks/{37vzwr3ciejf1.js → 1gs-5722l4u59.js} +1 -1
- package/out/_next/static/chunks/1gt4kh0_xmigy.js +1 -0
- package/out/_next/static/chunks/1h8xzuuhhglu9.js +1 -0
- package/out/_next/static/chunks/1hatz-jlztrn0.js +1 -0
- package/out/_next/static/chunks/1iioifo7i0t0_.js +1 -0
- package/out/_next/static/chunks/{0impkpmxx3ttp.js → 1iiz7jqgj20z0.js} +1 -1
- package/out/_next/static/chunks/1kujmd5n0j9nk.js +1 -0
- package/out/_next/static/chunks/{2kazjq29jeamx.js → 1ltux4lwz7muf.js} +160 -372
- package/out/_next/static/chunks/1m_buecgcq67j.js +740 -0
- package/out/_next/static/chunks/1n9sy0yt5d2vq.js +1 -0
- package/out/_next/static/chunks/1p1gz6dseck--.js +1 -0
- package/out/_next/static/chunks/1p1xtsfwvpuqo.js +1 -0
- package/out/_next/static/chunks/1p8f6okk2ewbz.js +1 -0
- package/out/_next/static/chunks/1qg_etglhvp9h.js +740 -0
- package/out/_next/static/chunks/1th_t5ujeqlkf.js +1 -0
- package/out/_next/static/chunks/1thr-mdzbu96v.js +1 -0
- package/out/_next/static/chunks/1tta1a064979p.js +1 -0
- package/out/_next/static/chunks/1u_riwm0nfww7.js +1 -0
- package/out/_next/static/chunks/1ua15kzid0_8p.js +2560 -0
- package/out/_next/static/chunks/1uu-rt_8p1edp.js +2712 -0
- package/out/_next/static/chunks/1uu93wuxigx4k.js +1 -0
- package/out/_next/static/chunks/{1flb8adpj6_2o.js → 1xpwp4m1tqugp.js} +1 -1
- package/out/_next/static/chunks/1ynju1jqfrcv0.js +1 -0
- package/out/_next/static/chunks/1zfojlgb15okk.js +1 -0
- package/out/_next/static/chunks/1zj8x5wbgnzz-.js +1 -0
- package/out/_next/static/chunks/1zl6t15gh34nn.js +1 -0
- package/out/_next/static/chunks/{1thjncpj7u6pq.js → 223vrr_4sfhsj.js} +1 -1
- package/out/_next/static/chunks/22cr2b04btguf.js +1 -0
- package/out/_next/static/chunks/242xhzxxetctz.js +1 -0
- package/out/_next/static/chunks/24essz5mmvx-6.js +1 -0
- package/out/_next/static/chunks/256k1jw1m--l7.js +146 -0
- package/out/_next/static/chunks/259obyrpxcv6r.js +1 -0
- package/out/_next/static/chunks/26v9yqicofqba.js +1 -0
- package/out/_next/static/chunks/290d93hmm_e8b.js +1 -0
- package/out/_next/static/chunks/2_2fk7iddrs43.js +1 -0
- package/out/_next/static/chunks/{00k_j_r7bv_eb.js → 2bjlls8-qe05r.js} +9 -9
- package/out/_next/static/chunks/2ckd7f1wbfod-.js +1 -0
- package/out/_next/static/chunks/{163fa70v4mgxj.js → 2d6hru4qo23tt.js} +1 -1
- package/out/_next/static/chunks/2ejvntxtvf5o9.js +1 -0
- package/out/_next/static/chunks/2f7_3tzf7xhps.js +1 -0
- package/out/_next/static/chunks/2gxd_o1g89_bv.js +1 -0
- package/out/_next/static/chunks/2hd2txb4-m9k1.js +1 -0
- package/out/_next/static/chunks/2hpxou_cnp4f_.js +1 -0
- package/out/_next/static/chunks/2izioctrfc0s5.js +1 -0
- package/out/_next/static/chunks/2jhnk4h4n0udv.js +1 -0
- package/out/_next/static/chunks/2jpkhkk9zi8-f.js +1 -0
- package/out/_next/static/chunks/2kpet_l1kq2sx.js +1 -0
- package/out/_next/static/chunks/2mdbvf1b5h00_.css +3 -0
- package/out/_next/static/chunks/2nck5w4c7leb7.js +1 -0
- package/out/_next/static/chunks/2our10fwtj87e.js +1 -0
- package/out/_next/static/chunks/2qq3uzsbiicw3.js +1194 -0
- package/out/_next/static/chunks/2qqqpu0ahfdda.js +1 -0
- package/out/_next/static/chunks/2u-f7mmxvk8wj.js +1 -0
- package/out/_next/static/chunks/2ue1wo4ryk87z.js +1 -0
- package/out/_next/static/chunks/2uk-vwlxe9-xr.js +1 -0
- package/out/_next/static/chunks/2ur5-lxdvv1jm.js +1 -0
- package/out/_next/static/chunks/2veqsohwfhfqc.js +1 -0
- package/out/_next/static/chunks/2vqlv9wnewhu9.js +1 -0
- package/out/_next/static/chunks/{1zvc1tv--w8nn.js → 2wzshintp5lf8.js} +1 -1
- package/out/_next/static/chunks/2x-00glogc485.js +1 -0
- package/out/_next/static/chunks/2yfxy0f5fqs4o.js +1 -0
- package/out/_next/static/chunks/2z88mt3ixktu3.js +1 -0
- package/out/_next/static/chunks/2z_jn9ud28fk7.js +1 -0
- package/out/_next/static/chunks/3-eswqjobiqk1.js +1 -0
- package/out/_next/static/chunks/30-tbi7pys6fp.js +4 -0
- package/out/_next/static/chunks/30c-nsedy_ce0.js +1 -0
- package/out/_next/static/chunks/31u5lbu1vxznh.js +1 -0
- package/out/_next/static/chunks/{2feca0xcipcyt.js → 32ahba5ezp467.js} +156 -156
- package/out/_next/static/chunks/337hn35kts7ud.js +1 -0
- package/out/_next/static/chunks/33dgpebv-tf73.js +1 -0
- package/out/_next/static/chunks/36jkdhq6kb-cf.js +1 -0
- package/out/_next/static/chunks/37epa8fz59vba.js +1166 -0
- package/out/_next/static/chunks/3833xfnz0a-ub.js +1 -0
- package/out/_next/static/chunks/38awrh_qxn22k.js +1 -0
- package/out/_next/static/chunks/{0wrm9jr-9bw0e.js → 38x3c1ra5slhe.js} +383 -913
- package/out/_next/static/chunks/39idqlqlcp5b9.js +1 -0
- package/out/_next/static/chunks/{2a3spdq-m8drh.js → 3_gku1pwluoo0.js} +1 -1
- package/out/_next/static/chunks/3_mu-4rdjajna.js +1450 -0
- package/out/_next/static/chunks/3coacc4-g-g5c.js +1 -0
- package/out/_next/static/chunks/3e00fzdfkclzq.js +1 -0
- package/out/_next/static/chunks/3e8fmlq0k5wkg.js +1 -0
- package/out/_next/static/chunks/3e9tzyrt4_98z.js +1 -0
- package/out/_next/static/chunks/3edelqkq92pil.js +1 -0
- package/out/_next/static/chunks/3figbil1t4ssj.js +593 -0
- package/out/_next/static/chunks/3gimb3z_mteou.js +1 -0
- package/out/_next/static/chunks/{2p2vv6cc9i-3q.js → 3idaz_s77e-j_.js} +9 -9
- package/out/_next/static/chunks/3j-4wuhs5weba.js +1 -0
- package/out/_next/static/chunks/3jjfnwvybayy7.js +1 -0
- package/out/_next/static/chunks/3jwm5dfk_78gc.js +1 -0
- package/out/_next/static/chunks/3k9d4ylc3li2t.js +1352 -0
- package/out/_next/static/chunks/3l3_0ack3gy4k.js +1 -0
- package/out/_next/static/chunks/3lwhs5ja7tun3.js +1 -0
- package/out/_next/static/chunks/3m6nmp2dca6un.js +1342 -0
- package/out/_next/static/chunks/3mbnfpufs2-7e.js +7 -0
- package/out/_next/static/chunks/3mcd08gmt038z.js +1 -0
- package/out/_next/static/chunks/3mt5th7b1i_u9.js +1 -0
- package/out/_next/static/chunks/3ne77mjdz2y7o.js +1 -0
- package/out/_next/static/chunks/3puhrqtujktyv.js +1 -0
- package/out/_next/static/chunks/3rdifucupcgkg.js +1 -0
- package/out/_next/static/chunks/3riekaxl3uxfb.js +1195 -0
- package/out/_next/static/chunks/3sdoskq_buttj.js +1 -0
- package/out/_next/static/chunks/3tg-ma9tv9xu4.js +1 -0
- package/out/_next/static/chunks/3tm-pqpmq_ppw.js +1 -0
- package/out/_next/static/chunks/3w9go565cjhq3.js +1636 -0
- package/out/_next/static/chunks/3wi9gzq2mtr_q.js +8 -0
- package/out/_next/static/chunks/3xagd_2_9zft2.js +1 -0
- package/out/_next/static/chunks/3xsq_anpad-fb.js +1 -0
- package/out/_next/static/chunks/3ycv2qq7vpbua.js +1 -0
- package/out/_next/static/chunks/3z84au-mitjjw.js +1 -0
- package/out/_next/static/chunks/4030dhur2h70-.js +1 -0
- package/out/_next/static/chunks/40ffffml4h_3r.js +4 -0
- package/out/_next/static/chunks/{3-shckrcpvbxu.js → 41wt50z9tx9cx.js} +108 -711
- package/out/_next/static/chunks/431slrqh0wa0g.js +1 -0
- package/out/_next/static/chunks/43s_lbd1i2krj.js +1 -0
- package/out/_next/static/chunks/{0-2y-_oomza2l.js → 44nxswtahaq4w.js} +18 -18
- package/out/_next/static/chunks/45bwefvdpztfs.js +1 -0
- package/out/_next/static/chunks/{turbopack-0sgd6pfbe1fy6.js → turbopack-19105pdhzxp1x.js} +1 -1
- package/out/_not-found/__next._full.txt +9 -9
- package/out/_not-found/__next._head.txt +4 -4
- package/out/_not-found/__next._index.txt +4 -4
- package/out/_not-found/__next._not-found.__PAGE__.txt +2 -2
- package/out/_not-found/__next._not-found.txt +3 -3
- package/out/_not-found/__next._tree.txt +2 -2
- package/out/_not-found.html +1 -1
- package/out/_not-found.txt +9 -9
- package/out/index.html +1 -1
- package/out/index.txt +11 -11
- package/package.json +5 -4
- package/out/_next/static/chunks/068j6934u8j16.js +0 -1
- package/out/_next/static/chunks/09e4adtr6w0xe.js +0 -1
- package/out/_next/static/chunks/0_rf76jneiwal.js +0 -176
- package/out/_next/static/chunks/0aznt7717miff.js +0 -1
- package/out/_next/static/chunks/0cu-q5q3a7uf3.js +0 -1
- package/out/_next/static/chunks/0fskcfh9vbhtv.js +0 -1
- package/out/_next/static/chunks/0gg-ii7i6d_p6.js +0 -1
- package/out/_next/static/chunks/0tx1j_ghpz7rc.css +0 -3
- package/out/_next/static/chunks/0ufbyo1x3qkmo.js +0 -1
- package/out/_next/static/chunks/0wwcfw8i3j_zx.js +0 -1
- package/out/_next/static/chunks/0wwkrsvxwi57d.js +0 -1
- package/out/_next/static/chunks/0ys9-ozuluawt.js +0 -1
- package/out/_next/static/chunks/1-61zh4waha61.js +0 -1
- package/out/_next/static/chunks/10r_824wzt8hj.js +0 -1
- package/out/_next/static/chunks/123xxske5c9na.js +0 -1
- package/out/_next/static/chunks/13isnf0--pmx1.js +0 -1
- package/out/_next/static/chunks/157d9euci08yu.js +0 -1
- package/out/_next/static/chunks/18u58lorfahxi.js +0 -4
- package/out/_next/static/chunks/1_aahautsz2v_.js +0 -1
- package/out/_next/static/chunks/1o1d0p-v1z8ty.js +0 -1
- package/out/_next/static/chunks/1vdjn0pkoyypn.js +0 -1
- package/out/_next/static/chunks/1yehxf-fmeicg.js +0 -1
- package/out/_next/static/chunks/1zx2q-r32thv1.js +0 -4
- package/out/_next/static/chunks/2-sjjedfr0kfq.js +0 -1
- package/out/_next/static/chunks/25b9x-li-tvk2.js +0 -1
- package/out/_next/static/chunks/2aelw3far6rii.js +0 -1
- package/out/_next/static/chunks/2aor7m-wbis85.js +0 -1
- package/out/_next/static/chunks/2clzipqap01hp.js +0 -1
- package/out/_next/static/chunks/2fh-_9b6tqhvb.js +0 -1
- package/out/_next/static/chunks/2g5gecypj0rqe.js +0 -1
- package/out/_next/static/chunks/2szdcpl41-kzv.js +0 -1
- package/out/_next/static/chunks/2u6shh3oeycm-.js +0 -1
- package/out/_next/static/chunks/2unhhuv0arlcv.js +0 -1
- package/out/_next/static/chunks/2z5eqx5do5std.js +0 -1
- package/out/_next/static/chunks/310uz81hnnzsu.js +0 -1
- package/out/_next/static/chunks/3aqbf_wkg2sih.js +0 -3
- package/out/_next/static/chunks/3i3gbhccmhu7j.js +0 -210
- package/out/_next/static/chunks/3mqy-84_ul3t2.js +0 -1
- package/out/_next/static/chunks/3nz-dh9d7cehk.js +0 -1
- package/out/_next/static/chunks/3pufs8g4ui943.js +0 -1
- package/out/_next/static/chunks/3t06schbtqonl.js +0 -1
- package/out/_next/static/chunks/3v3-7fio3nw_t.js +0 -1
- package/out/_next/static/chunks/3v5ha25nxo43j.js +0 -1
- package/out/_next/static/chunks/3zskk1hxu3-_o.js +0 -1
- /package/out/_next/static/{vHD3x58R_2B6QWAhZXCg7 → M9ZSIaKJeBgkjz1qktYio}/_buildManifest.js +0 -0
- /package/out/_next/static/{vHD3x58R_2B6QWAhZXCg7 → M9ZSIaKJeBgkjz1qktYio}/_clientMiddlewareManifest.js +0 -0
- /package/out/_next/static/{vHD3x58R_2B6QWAhZXCg7 → M9ZSIaKJeBgkjz1qktYio}/_ssgManifest.js +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,63132,471,e=>{"use strict";var t=e.i(35407),s=e.i(99267);e.s(["PostProcessManager",0,class{constructor(e){this._vertexBuffers={},this._activePostProcesses=[],this.onBeforeRenderObservable=new s.Observable,this._scene=e}_prepareBuffers(){if(this._vertexBuffers[t.VertexBuffer.PositionKind])return;let e=[];e.push(1,1),e.push(-1,1),e.push(-1,-1),e.push(1,-1),this._vertexBuffers[t.VertexBuffer.PositionKind]=new t.VertexBuffer(this._scene.getEngine(),e,t.VertexBuffer.PositionKind,!1,!1,2),this._buildIndexBuffer()}_buildIndexBuffer(){let e=[];e.push(0),e.push(1),e.push(2),e.push(0),e.push(2),e.push(3),this._indexBuffer=this._scene.getEngine().createIndexBuffer(e)}_getActivePostProcesses(e){let t=this._activePostProcesses;t.length=0;for(let s=0;s<e.length;s++){let r=e[s];r&&t.push(r)}return t}_rebuild(){let e=this._vertexBuffers[t.VertexBuffer.PositionKind];e&&(e._rebuild(),this._buildIndexBuffer())}_prepareFrame(e=null,t=null){let s=this._scene.activeCamera;return!!s&&!!(t=t||this._getActivePostProcesses(s._postProcesses))&&0!==t.length&&!!this._scene.postProcessesEnabled&&(t[0].activate(s,e,null!=t),!0)}directRender(e,t=null,s=!1,r=0,i=0,n=!1,a=e.length){let h=this._scene.getEngine();for(let o=0;o<a;o++){o<e.length-1?e[o+1].activate(this._scene.activeCamera||this._scene,t?.texture):(t?h.bindFramebuffer(t,r,void 0,void 0,s,i):n||h.restoreDefaultFramebuffer(),h._debugInsertMarker?.(`post process ${e[o].name} output`));let a=e[o],l=a.apply();l&&(a.onBeforeRenderObservable.notifyObservers(l),this._prepareBuffers(),h.bindBuffers(this._vertexBuffers,this._indexBuffer,l),h.drawElementsType(0,0,6),a.onAfterRenderObservable.notifyObservers(l))}h.setDepthBuffer(!0),h.setDepthWrite(!0)}_finalizeFrame(e,t,s,r,i=!1){let n=this._scene.activeCamera;if(!n||(this.onBeforeRenderObservable.notifyObservers(this),0===(r=r||this._getActivePostProcesses(n._postProcesses)).length||!this._scene.postProcessesEnabled))return;let a=this._scene.getEngine();for(let h=0,o=r.length;h<o;h++){let l=r[h];if(h<o-1?l._outputTexture=r[h+1].activate(n,t?.texture):(t?(a.bindFramebuffer(t,s,void 0,void 0,i),l._outputTexture=t):(a.restoreDefaultFramebuffer(),l._outputTexture=null),a._debugInsertMarker?.(`post process ${r[h].name} output`)),e)break;let c=l.apply();c&&(l.onBeforeRenderObservable.notifyObservers(c),this._prepareBuffers(),a.bindBuffers(this._vertexBuffers,this._indexBuffer,c),a.drawElementsType(0,0,6),l.onAfterRenderObservable.notifyObservers(c))}a.setDepthBuffer(!0),a.setDepthWrite(!0),a.setAlphaMode(0)}dispose(){let e=this._vertexBuffers[t.VertexBuffer.PositionKind];e&&(e.dispose(),this._vertexBuffers[t.VertexBuffer.PositionKind]=null),this._indexBuffer&&(this._scene.getEngine()._releaseBuffer(this._indexBuffer),this._indexBuffer=null)}}],63132);var r=e.i(45707),i=e.i(96265);class n{set opaqueSortCompareFn(e){e?this._opaqueSortCompareFn=e:this._opaqueSortCompareFn=n.PainterSortCompare,this._renderOpaque=this._renderOpaqueSorted}set alphaTestSortCompareFn(e){e?this._alphaTestSortCompareFn=e:this._alphaTestSortCompareFn=n.PainterSortCompare,this._renderAlphaTest=this._renderAlphaTestSorted}set transparentSortCompareFn(e){e?this._transparentSortCompareFn=e:this._transparentSortCompareFn=n.defaultTransparentSortCompare,this._renderTransparent=this._renderTransparentSorted}constructor(e,t,s=null,i=null,n=null){this.index=e,this._opaqueSubMeshes=new r.SmartArray(256),this._transparentSubMeshes=new r.SmartArray(256),this._alphaTestSubMeshes=new r.SmartArray(256),this._depthOnlySubMeshes=new r.SmartArray(256),this._particleSystems=new r.SmartArray(256),this._spriteManagers=new r.SmartArray(256),this._empty=!0,this._edgesRenderers=new r.SmartArrayNoDuplicate(16),this.disableDepthPrePass=!1,this._scene=t,this.opaqueSortCompareFn=s,this.alphaTestSortCompareFn=i,this.transparentSortCompareFn=n}render(e,t,s,r,i=!0,n=!0,a=!0,h=!0,o){if(e)return void e(this._opaqueSubMeshes,this._alphaTestSubMeshes,this._transparentSubMeshes,this._depthOnlySubMeshes);let l=this._scene.getEngine();i&&0!==this._depthOnlySubMeshes.length&&(l.setColorWrite(!1),this._renderAlphaTest(this._depthOnlySubMeshes),l.setColorWrite(!0)),n&&0!==this._opaqueSubMeshes.length&&this._renderOpaque(this._opaqueSubMeshes),a&&0!==this._alphaTestSubMeshes.length&&this._renderAlphaTest(this._alphaTestSubMeshes);let c=l.getStencilBuffer();if(l.setStencilBuffer(!1),t&&this._renderSprites(),s&&this._renderParticles(r),this.onBeforeTransparentRendering&&this.onBeforeTransparentRendering(),h&&(o||0!==this._transparentSubMeshes.length||this._scene.useOrderIndependentTransparency)){if(l.setStencilBuffer(c),o)o(this._transparentSubMeshes,this);else if(this._scene.useOrderIndependentTransparency){let e=this._scene.depthPeelingRenderer.render(this._transparentSubMeshes);e.length&&this._renderTransparent(e)}else this._renderTransparent(this._transparentSubMeshes);l.setAlphaMode(0)}if(l.setStencilBuffer(!1),n&&this._edgesRenderers.length){for(let e=0;e<this._edgesRenderers.length;e++)this._edgesRenderers.data[e].render();l.setAlphaMode(0)}l.setStencilBuffer(c)}_renderOpaqueSorted(e){n._RenderSorted(e,this._opaqueSortCompareFn,this._scene.activeCamera,!1,this.disableDepthPrePass)}_renderAlphaTestSorted(e){n._RenderSorted(e,this._alphaTestSortCompareFn,this._scene.activeCamera,!1,this.disableDepthPrePass)}_renderTransparentSorted(e){n._RenderSorted(e,this._transparentSortCompareFn,this._scene.activeCamera,!0,this.disableDepthPrePass)}static _RenderSorted(e,t,s,r,a){let h,o=0,l=s?s.globalPosition:n._ZeroVector;if(r)for(;o<e.length;o++)(h=e.data[o])._alphaIndex=h.getMesh().alphaIndex,h._distanceToCamera=i.Vector3.Distance(h.getBoundingInfo().boundingSphere.centerWorld,l);let c=e.length===e.data.length?e.data:e.data.slice(0,e.length);t&&c.sort(t);let u=c[0].getMesh().getScene();for(o=0;o<c.length;o++)if(h=c[o],!u._activeMeshesFrozenButKeepClipping||h.isInFrustum(u._frustumPlanes)){if(r){let e=h.getMaterial();if(e&&e.needDepthPrePass&&!a){let t=e.getScene().getEngine();t.setColorWrite(!1),t.setAlphaMode(0),h.render(!1),t.setColorWrite(!0)}}h.render(r)}}static defaultTransparentSortCompare(e,t){return e._alphaIndex>t._alphaIndex?1:e._alphaIndex<t._alphaIndex?-1:n.backToFrontSortCompare(e,t)}static backToFrontSortCompare(e,t){return e._distanceToCamera<t._distanceToCamera?1:e._distanceToCamera>t._distanceToCamera?-1:0}static frontToBackSortCompare(e,t){return e._distanceToCamera<t._distanceToCamera?-1:+(e._distanceToCamera>t._distanceToCamera)}static PainterSortCompare(e,t){let s=e.getMesh(),r=t.getMesh();return s.material&&r.material?s.material.uniqueId-r.material.uniqueId:s.uniqueId-r.uniqueId}prepare(){this._opaqueSubMeshes.reset(),this._transparentSubMeshes.reset(),this._alphaTestSubMeshes.reset(),this._depthOnlySubMeshes.reset(),this._particleSystems.reset(),this.prepareSprites(),this._edgesRenderers.reset(),this._empty=!0}prepareSprites(){this._spriteManagers.reset()}dispose(){this._opaqueSubMeshes.dispose(),this._transparentSubMeshes.dispose(),this._alphaTestSubMeshes.dispose(),this._depthOnlySubMeshes.dispose(),this._particleSystems.dispose(),this._spriteManagers.dispose(),this._edgesRenderers.dispose()}dispatch(e,t,s){void 0===t&&(t=e.getMesh()),void 0===s&&(s=e.getMaterial()),null!=s&&(s.needAlphaBlendingForMesh(t)?this._transparentSubMeshes.push(e):s.needAlphaTestingForMesh(t)?(s.needDepthPrePass&&!this.disableDepthPrePass&&this._depthOnlySubMeshes.push(e),this._alphaTestSubMeshes.push(e)):(s.needDepthPrePass&&!this.disableDepthPrePass&&this._depthOnlySubMeshes.push(e),this._opaqueSubMeshes.push(e)),t._renderingGroup=this,t._edgesRenderer&&t.isEnabled()&&t.isVisible&&t._edgesRenderer.isEnabled&&this._edgesRenderers.pushNoDuplicate(t._edgesRenderer),this._empty=!1)}dispatchSprites(e){this._spriteManagers.push(e),this._empty=!1}dispatchParticles(e){this._particleSystems.push(e),this._empty=!1}_renderParticles(e){if(0===this._particleSystems.length)return;let t=this._scene.activeCamera;this._scene.onBeforeParticlesRenderingObservable.notifyObservers(this._scene);for(let s=0;s<this._particleSystems.length;s++){let r=this._particleSystems.data[s];if(0===(t&&t.layerMask&r.layerMask))continue;let i=r.emitter;i.position&&e&&-1===e.indexOf(i)||this._scene._activeParticles.addCount(r.render(),!1)}this._scene.onAfterParticlesRenderingObservable.notifyObservers(this._scene)}_renderSprites(){if(!this._scene.spritesEnabled||0===this._spriteManagers.length)return;let e=this._scene.activeCamera;this._scene.onBeforeSpritesRenderingObservable.notifyObservers(this._scene);for(let t=0;t<this._spriteManagers.length;t++){let s=this._spriteManagers.data[t];0!==(e&&e.layerMask&s.layerMask)&&s.render()}this._scene.onAfterSpritesRenderingObservable.notifyObservers(this._scene)}}n._ZeroVector=i.Vector3.Zero();class a{}class h{get disableDepthPrePass(){return this._disableDepthPrePass}set disableDepthPrePass(e){for(let t of(this._disableDepthPrePass=e,this._renderingGroups))t.disableDepthPrePass=e}get maintainStateBetweenFrames(){return this._maintainStateBetweenFrames}set maintainStateBetweenFrames(e){e!==this._maintainStateBetweenFrames&&(this._maintainStateBetweenFrames=e,this._maintainStateBetweenFrames||this.restoreDispachedFlags())}restoreDispachedFlags(){for(let e of this._scene.meshes)if(e.subMeshes)for(let t of e.subMeshes)t._wasDispatched=!1;if(this._scene.spriteManagers)for(let e of this._scene.spriteManagers)e._wasDispatched=!1;for(let e of this._scene.particleSystems)e._wasDispatched=!1}constructor(e){this._useSceneAutoClearSetup=!1,this._disableDepthPrePass=!1,this._renderingGroups=[],this._autoClearDepthStencil={},this._customOpaqueSortCompareFn={},this._customAlphaTestSortCompareFn={},this._customTransparentSortCompareFn={},this._renderingGroupInfo=new a,this._maintainStateBetweenFrames=!1,this._scene=e;for(let e=h.MIN_RENDERINGGROUPS;e<h.MAX_RENDERINGGROUPS;e++)this._autoClearDepthStencil[e]={autoClear:!0,depth:!0,stencil:!0}}get renderingGroups(){return this._renderingGroups}getRenderingGroup(e){let t=e||0;return this._prepareRenderingGroup(t),this._renderingGroups[t]}_clearDepthStencilBuffer(e=!0,t=!0){this._depthStencilBufferAlreadyCleaned||(this._scene.getEngine().clear(null,!1,e,t),this._depthStencilBufferAlreadyCleaned=!0)}render(e,t,s,r,i=!0,n=!0,a=!0,o=!0,l){let c=this._renderingGroupInfo;if(c.scene=this._scene,c.camera=this._scene.activeCamera,c.renderingManager=this,this._scene.spriteManagers&&r)for(let e=0;e<this._scene.spriteManagers.length;e++){let t=this._scene.spriteManagers[e];this.dispatchSprites(t)}for(let u=h.MIN_RENDERINGGROUPS;u<h.MAX_RENDERINGGROUPS;u++){this._depthStencilBufferAlreadyCleaned=u===h.MIN_RENDERINGGROUPS;let p=this._renderingGroups[u];if(!p||p._empty)continue;let d=1<<u;if(c.renderingGroupId=u,this._scene.onBeforeRenderingGroupObservable.notifyObservers(c,d),h.AUTOCLEAR){let e=this._useSceneAutoClearSetup?this._scene.getAutoClearDepthStencilSetup(u):this._autoClearDepthStencil[u];e&&e.autoClear&&this._clearDepthStencilBuffer(e.depth,e.stencil)}for(let e of this._scene._beforeRenderingGroupDrawStage)e.action(u);for(let h of(p.render(e,r,s,t,i,n,a,o,l),this._scene._afterRenderingGroupDrawStage))h.action(u);this._scene.onAfterRenderingGroupObservable.notifyObservers(c,d)}}reset(){if(!this.maintainStateBetweenFrames)for(let e=h.MIN_RENDERINGGROUPS;e<h.MAX_RENDERINGGROUPS;e++){let t=this._renderingGroups[e];t&&t.prepare()}}resetSprites(){if(!this.maintainStateBetweenFrames)for(let e=h.MIN_RENDERINGGROUPS;e<h.MAX_RENDERINGGROUPS;e++){let t=this._renderingGroups[e];t&&t.prepareSprites()}}dispose(){this.freeRenderingGroups(),this._renderingGroups.length=0,this._renderingGroupInfo=null}freeRenderingGroups(){for(let e=h.MIN_RENDERINGGROUPS;e<h.MAX_RENDERINGGROUPS;e++){let t=this._renderingGroups[e];t&&t.dispose()}}_prepareRenderingGroup(e){void 0===this._renderingGroups[e]&&(this._renderingGroups[e]=new n(e,this._scene,this._customOpaqueSortCompareFn[e],this._customAlphaTestSortCompareFn[e],this._customTransparentSortCompareFn[e]),this._renderingGroups[e].disableDepthPrePass=this._disableDepthPrePass)}dispatchSprites(e){this.maintainStateBetweenFrames&&e._wasDispatched||(e._wasDispatched=!0,this.getRenderingGroup(e.renderingGroupId).dispatchSprites(e))}dispatchParticles(e){this.maintainStateBetweenFrames&&e._wasDispatched||(e._wasDispatched=!0,this.getRenderingGroup(e.renderingGroupId).dispatchParticles(e))}dispatch(e,t,s){void 0===t&&(t=e.getMesh()),this.maintainStateBetweenFrames&&e._wasDispatched||(e._wasDispatched=!0,this.getRenderingGroup(t.renderingGroupId).dispatch(e,t,s))}setRenderingOrder(e,t=null,s=null,r=null){if(this._customOpaqueSortCompareFn[e]=t,this._customAlphaTestSortCompareFn[e]=s,this._customTransparentSortCompareFn[e]=r,this._renderingGroups[e]){let t=this._renderingGroups[e];t.opaqueSortCompareFn=this._customOpaqueSortCompareFn[e],t.alphaTestSortCompareFn=this._customAlphaTestSortCompareFn[e],t.transparentSortCompareFn=this._customTransparentSortCompareFn[e]}}setRenderingAutoClearDepthStencil(e,t,s=!0,r=!0){this._autoClearDepthStencil[e]={autoClear:t,depth:s,stencil:r}}getAutoClearDepthStencilSetup(e){return this._autoClearDepthStencil[e]}}h.MAX_RENDERINGGROUPS=4,h.MIN_RENDERINGGROUPS=0,h.AUTOCLEAR=!0,e.s(["RenderingManager",0,h],471)},67359,e=>{"use strict";var t=e.i(36395);class s{get min(){return this._min}get max(){return this._max}get average(){return this._average}get lastSecAverage(){return this._lastSecAverage}get current(){return this._current}get total(){return this._totalAccumulated}get count(){return this._totalValueCount}constructor(){this._startMonitoringTime=0,this._min=0,this._max=0,this._average=0,this._lastSecAverage=0,this._current=0,this._totalValueCount=0,this._totalAccumulated=0,this._lastSecAccumulated=0,this._lastSecTime=0,this._lastSecValueCount=0}fetchNewFrame(){this._totalValueCount++,this._current=0,this._lastSecValueCount++}addCount(e,t){s.Enabled&&(this._current+=e,t&&this._fetchResult())}beginMonitoring(){s.Enabled&&(this._startMonitoringTime=t.PrecisionDate.Now)}endMonitoring(e=!0){if(!s.Enabled)return;e&&this.fetchNewFrame();let r=t.PrecisionDate.Now;this._current=r-this._startMonitoringTime,e&&this._fetchResult()}endFrame(){this._fetchResult()}_fetchResult(){this._totalAccumulated+=this._current,this._lastSecAccumulated+=this._current,this._min=Math.min(this._min,this._current),this._max=Math.max(this._max,this._current),this._average=this._totalAccumulated/this._totalValueCount;let e=t.PrecisionDate.Now;e-this._lastSecTime>1e3&&(this._lastSecAverage=this._lastSecAccumulated/this._lastSecValueCount,this._lastSecTime=e,this._lastSecAccumulated=0,this._lastSecValueCount=0)}}s.Enabled=!0,e.s(["PerfCounter",0,s])},85531,e=>{"use strict";var t=e.i(65002);class s{static GetPlanes(e){let r=[];for(let e=0;e<6;e++)r.push(new t.Plane(0,0,0,0));return s.GetPlanesToRef(e,r),r}static GetNearPlaneToRef(e,t){let s=e.m;t.normal.x=s[3]+s[2],t.normal.y=s[7]+s[6],t.normal.z=s[11]+s[10],t.d=s[15]+s[14],t.normalize()}static GetFarPlaneToRef(e,t){let s=e.m;t.normal.x=s[3]-s[2],t.normal.y=s[7]-s[6],t.normal.z=s[11]-s[10],t.d=s[15]-s[14],t.normalize()}static GetLeftPlaneToRef(e,t){let s=e.m;t.normal.x=s[3]+s[0],t.normal.y=s[7]+s[4],t.normal.z=s[11]+s[8],t.d=s[15]+s[12],t.normalize()}static GetRightPlaneToRef(e,t){let s=e.m;t.normal.x=s[3]-s[0],t.normal.y=s[7]-s[4],t.normal.z=s[11]-s[8],t.d=s[15]-s[12],t.normalize()}static GetTopPlaneToRef(e,t){let s=e.m;t.normal.x=s[3]-s[1],t.normal.y=s[7]-s[5],t.normal.z=s[11]-s[9],t.d=s[15]-s[13],t.normalize()}static GetBottomPlaneToRef(e,t){let s=e.m;t.normal.x=s[3]+s[1],t.normal.y=s[7]+s[5],t.normal.z=s[11]+s[9],t.d=s[15]+s[13],t.normalize()}static GetPlanesToRef(e,t){s.GetNearPlaneToRef(e,t[0]),s.GetFarPlaneToRef(e,t[1]),s.GetLeftPlaneToRef(e,t[2]),s.GetRightPlaneToRef(e,t[3]),s.GetTopPlaneToRef(e,t[4]),s.GetBottomPlaneToRef(e,t[5])}static IsPointInFrustum(e,t){for(let s=0;s<6;s++)if(0>t[s].dotCoordinate(e))return!1;return!0}}e.s(["Frustum",0,s])},50107,e=>{"use strict";var t=e.i(96265),s=e.i(35407);e.s(["PickingInfo",0,class{constructor(){this.hit=!1,this.distance=0,this.pickedPoint=null,this.pickedMesh=null,this.bu=0,this.bv=0,this.faceId=-1,this.subMeshFaceId=-1,this.subMeshId=0,this.pickedSprite=null,this.thinInstanceIndex=-1,this.ray=null,this.originMesh=null,this.aimTransform=null,this.gripTransform=null}getNormal(e=!1,r=!0){let i;if(!this.pickedMesh||r&&!this.pickedMesh.isVerticesDataPresent(s.VertexBuffer.NormalKind))return null;let n=this.pickedMesh.getIndices();n?.length===0&&(n=null);let a=t.TmpVectors.Vector3[0],h=t.TmpVectors.Vector3[1],o=t.TmpVectors.Vector3[2];if(r){let e=this.pickedMesh.getVerticesData(s.VertexBuffer.NormalKind),r=n?t.Vector3.FromArrayToRef(e,3*n[3*this.faceId],a):a.copyFromFloats(e[3*this.faceId*3],e[3*this.faceId*3+1],e[3*this.faceId*3+2]),l=n?t.Vector3.FromArrayToRef(e,3*n[3*this.faceId+1],h):h.copyFromFloats(e[(3*this.faceId+1)*3],e[(3*this.faceId+1)*3+1],e[(3*this.faceId+1)*3+2]),c=n?t.Vector3.FromArrayToRef(e,3*n[3*this.faceId+2],o):o.copyFromFloats(e[(3*this.faceId+2)*3],e[(3*this.faceId+2)*3+1],e[(3*this.faceId+2)*3+2]);r=r.scale(this.bu),l=l.scale(this.bv),c=c.scale(1-this.bu-this.bv),i=new t.Vector3(r.x+l.x+c.x,r.y+l.y+c.y,r.z+l.z+c.z)}else{let e=this.pickedMesh.getVerticesData(s.VertexBuffer.PositionKind),r=n?t.Vector3.FromArrayToRef(e,3*n[3*this.faceId],a):a.copyFromFloats(e[3*this.faceId*3],e[3*this.faceId*3+1],e[3*this.faceId*3+2]),l=n?t.Vector3.FromArrayToRef(e,3*n[3*this.faceId+1],h):h.copyFromFloats(e[(3*this.faceId+1)*3],e[(3*this.faceId+1)*3+1],e[(3*this.faceId+1)*3+2]),c=n?t.Vector3.FromArrayToRef(e,3*n[3*this.faceId+2],o):o.copyFromFloats(e[(3*this.faceId+2)*3],e[(3*this.faceId+2)*3+1],e[(3*this.faceId+2)*3+2]),u=r.subtract(l),p=c.subtract(l);i=t.Vector3.Cross(u,p)}let l=(e,s)=>{if(-1!==this.thinInstanceIndex){let r=e._thinInstanceDataStorage.matrixData,i=this.thinInstanceIndex<<4;if(r&&r.length>i){let e=t.TmpVectors.Matrix[0];t.Matrix.FromArrayToRef(r,i,e),t.Vector3.TransformNormalToRef(s,e,s)}}let r=e.getWorldMatrix();e.nonUniformScaling&&(t.TmpVectors.Matrix[0].copyFrom(r),(r=t.TmpVectors.Matrix[0]).setTranslationFromFloats(0,0,0),r.invert(),r.transposeToRef(t.TmpVectors.Matrix[1]),r=t.TmpVectors.Matrix[1]),t.Vector3.TransformNormalToRef(s,r,s)};if(e&&l(this.pickedMesh,i),this.ray){let s=t.TmpVectors.Vector3[0].copyFrom(i);e||l(this.pickedMesh,s),t.Vector3.Dot(s,this.ray.direction)>0&&i.negateInPlace()}return i.normalize(),i}getTextureCoordinates(e=s.VertexBuffer.UVKind){if(!this.pickedMesh||!this.pickedMesh.isVerticesDataPresent(e))return null;let r=this.pickedMesh.getIndices();if(!r)return null;let i=this.pickedMesh.getVerticesData(e);if(!i)return null;let n=t.Vector2.FromArray(i,2*r[3*this.faceId]),a=t.Vector2.FromArray(i,2*r[3*this.faceId+1]),h=t.Vector2.FromArray(i,2*r[3*this.faceId+2]);return n=n.scale(this.bu),a=a.scale(this.bv),h=h.scale(1-this.bu-this.bv),new t.Vector2(n.x+a.x+h.x,n.y+a.y+h.y)}}])},21222,e=>{"use strict";var t=e.i(96265);class s{}s.POINTERDOWN=1,s.POINTERUP=2,s.POINTERMOVE=4,s.POINTERWHEEL=8,s.POINTERPICK=16,s.POINTERTAP=32,s.POINTERDOUBLETAP=64;class r{constructor(e,t){this.type=e,this.event=t}}e.s(["PointerEventTypes",0,s,"PointerInfo",0,class extends r{get pickInfo(){return this._pickInfo||this._generatePickInfo(),this._pickInfo}constructor(e,t,s,r=null){super(e,t),this._pickInfo=s,this._inputManager=r}_generatePickInfo(){this._inputManager&&(this._pickInfo=this._inputManager._pickMove(this.event),this._inputManager._setRayOnPointerInfo(this._pickInfo,this.event),this._inputManager=null)}},"PointerInfoPre",0,class extends r{constructor(e,s,r,i){super(e,s),this.ray=null,this.originalPickingInfo=null,this.skipOnPointerObservable=!1,this.localPosition=new t.Vector2(r,i)}}])},36365,e=>{"use strict";class t{}t.KEYDOWN=1,t.KEYUP=2;class s{constructor(e,t){this.type=e,this.event=t}}e.s(["KeyboardEventTypes",0,t,"KeyboardInfo",0,s,"KeyboardInfoPre",0,class extends s{get skipOnPointerObservable(){return this.skipOnKeyboardObservable}set skipOnPointerObservable(e){this.skipOnKeyboardObservable=e}constructor(e,t){super(e,t),this.type=e,this.event=t,this.skipOnKeyboardObservable=!1}}])},76696,e=>{"use strict";var t,s;(s=t||(t={}))[s.PointerMove=0]="PointerMove",s[s.PointerDown=1]="PointerDown",s[s.PointerUp=2]="PointerUp";class r{}r.DOM_DELTA_PIXEL=0,r.DOM_DELTA_LINE=1,r.DOM_DELTA_PAGE=2,e.s(["EventConstants",0,r])},31278,e=>{"use strict";e.s(["EffectFallbacks",0,class{constructor(){this._defines={},this._currentRank=32,this._maxRank=-1,this._mesh=null}unBindMesh(){this._mesh=null}addFallback(e,t){this._defines[e]||(e<this._currentRank&&(this._currentRank=e),e>this._maxRank&&(this._maxRank=e),this._defines[e]=[]),this._defines[e].push(t)}addCPUSkinningFallback(e,t){this._mesh=t,e<this._currentRank&&(this._currentRank=e),e>this._maxRank&&(this._maxRank=e)}get hasMoreFallbacks(){return this._currentRank<=this._maxRank}reduce(e,t){if(this._mesh&&this._mesh.computeBonesUsingShaders&&this._mesh.numBoneInfluencers>0){this._mesh.computeBonesUsingShaders=!1,e=e.replace("#define NUM_BONE_INFLUENCERS "+this._mesh.numBoneInfluencers,"#define NUM_BONE_INFLUENCERS 0"),t._bonesComputationForcedToCPU=!0;let s=this._mesh.getScene();for(let e=0;e<s.meshes.length;e++){let r=s.meshes[e];if(!r.material){!this._mesh.material&&r.computeBonesUsingShaders&&r.numBoneInfluencers>0&&(r.computeBonesUsingShaders=!1);continue}if(r.computeBonesUsingShaders&&0!==r.numBoneInfluencers){if(r.material.getEffect()===t)r.computeBonesUsingShaders=!1;else if(r.subMeshes){for(let e of r.subMeshes)if(e.effect===t){r.computeBonesUsingShaders=!1;break}}}}}else{let t=this._defines[this._currentRank];if(t)for(let s=0;s<t.length;s++)e=e.replace("#define "+t[s],"");this._currentRank++}return e}}])},22369,e=>{"use strict";var t=e.i(96265),s=e.i(23507);class r extends s.Material{constructor(e,s,r=!0,i=!1){super(e,s,void 0,i),this._normalMatrix=new t.Matrix,this._storeEffectOnSubMeshes=r}getEffect(){return this._storeEffectOnSubMeshes?this._activeEffect:super.getEffect()}isReady(e,t){return!!e&&(!this._storeEffectOnSubMeshes||!e.subMeshes||0===e.subMeshes.length||this.isReadyForSubMesh(e,e.subMeshes[0],t))}_isReadyForSubMesh(e){let t=e.materialDefines;return!this.checkReadyOnEveryCall&&!!e.effect&&!!t&&t._renderId===this.getScene().getRenderId()}bindOnlyWorldMatrix(e){this._activeEffect.setMatrix("world",e)}bindOnlyNormalMatrix(e){this._activeEffect.setMatrix("normalMatrix",e)}bind(e,t){t&&this.bindForSubMesh(e,t,t.subMeshes[0])}_afterBind(e,t=null,s){super._afterBind(e,t,s),this.getScene()._cachedEffect=t,s?s._drawWrapper._forceRebindOnNextCall=!1:this._drawWrapper._forceRebindOnNextCall=!1}_mustRebind(e,t,s,r=1){return s._drawWrapper._forceRebindOnNextCall||e.isCachedMaterialInvalid(this,t,r)}dispose(e,t,s){this._activeEffect=void 0,super.dispose(e,t,s)}}e.s(["PushMaterial",0,r])},12033,e=>{"use strict";let t=new WeakMap;e.s(["BindVertexPullingUniforms",0,function(e,t){t.forEach((t,s)=>{let r=`vp_${s}_info`;e.setFloat4(r,t.offset,t.stride,t.type,+!!t.normalized)})},"PrepareVertexPullingUniforms",0,function(e){let s=e.getVertexBuffers();if(!s)return null;let r=t.get(e);if(r){let e=!1;for(let t in s)if(!r.has(t)){e=!0;break}if(!e)return r}else r=new Map,t.set(e,r);for(let e in s){let t=s[e];if(t){let s=t.byteOffset,i=t.byteStride,n=t.type,a=t.normalized;r.set(e,{offset:s,stride:i,type:n,normalized:a})}}return r}])}]);
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,12423,e=>{"use strict";class t{static GetShadersRepository(e=0){return 0===e?t.ShadersRepository:t.ShadersRepositoryWGSL}static GetShadersStore(e=0){return 0===e?t.ShadersStore:t.ShadersStoreWGSL}static GetIncludesShadersStore(e=0){return 0===e?t.IncludesShadersStore:t.IncludesShadersStoreWGSL}}t.ShadersRepository="src/Shaders/",t.ShadersStore={},t.IncludesShadersStore={},t.ShadersRepositoryWGSL="src/ShadersWGSL/",t.ShadersStoreWGSL={},t.IncludesShadersStoreWGSL={},e.s(["ShaderStore",0,t])},18131,e=>{"use strict";e.s(["PrePassConfiguration",0,class{constructor(){this.previousWorldMatrices={},this.previousBones={}}static AddUniforms(e){e.push("previousWorld","previousViewProjection","mPreviousBones")}static AddSamplers(e){}bindForSubMesh(e,t,i,s,r){if(t.prePassRenderer&&t.prePassRenderer.enabled&&t.prePassRenderer.currentRTisSceneRT&&(-1!==t.prePassRenderer.getIndex(2)||-1!==t.prePassRenderer.getIndex(11))){this.previousWorldMatrices[i.uniqueId]||(this.previousWorldMatrices[i.uniqueId]=s.clone()),this.previousViewProjection||(this.previousViewProjection=t.getTransformMatrix().clone(),this.currentViewProjection=t.getTransformMatrix().clone());let r=t.getEngine();this.currentViewProjection.updateFlag!==t.getTransformMatrix().updateFlag?(this._lastUpdateFrameId=r.frameId,this.previousViewProjection.copyFrom(this.currentViewProjection),this.currentViewProjection.copyFrom(t.getTransformMatrix())):this._lastUpdateFrameId!==r.frameId&&(this._lastUpdateFrameId=r.frameId,this.previousViewProjection.copyFrom(this.currentViewProjection)),e.setMatrix("previousWorld",this.previousWorldMatrices[i.uniqueId]),e.setMatrix("previousViewProjection",this.previousViewProjection),this.previousWorldMatrices[i.uniqueId]=s.clone()}}}])},44702,e=>{"use strict";e.s(["MaterialDefines",0,class{constructor(e){if(this.VERTEXOUTPUT_INVARIANT=!1,this._keys=[],this._isDirty=!0,this._areLightsDirty=!0,this._areLightsDisposed=!1,this._areAttributesDirty=!0,this._areTexturesDirty=!0,this._areFresnelDirty=!0,this._areMiscDirty=!0,this._arePrePassDirty=!0,this._areImageProcessingDirty=!0,this._normals=!1,this._uvs=!1,this._needNormals=!1,this._needUVs=!1,this._externalProperties=e,e)for(const t in e)Object.prototype.hasOwnProperty.call(e,t)&&this._setDefaultValue(t)}get isDirty(){return this._isDirty}markAsProcessed(){this._isDirty=!1,this._areAttributesDirty=!1,this._areTexturesDirty=!1,this._areFresnelDirty=!1,this._areLightsDirty=!1,this._areLightsDisposed=!1,this._areMiscDirty=!1,this._arePrePassDirty=!1,this._areImageProcessingDirty=!1}markAsUnprocessed(){this._isDirty=!0}markAllAsDirty(){this._areTexturesDirty=!0,this._areAttributesDirty=!0,this._areLightsDirty=!0,this._areFresnelDirty=!0,this._areMiscDirty=!0,this._arePrePassDirty=!0,this._areImageProcessingDirty=!0,this._isDirty=!0}markAsImageProcessingDirty(){this._areImageProcessingDirty=!0,this._isDirty=!0}markAsLightDirty(e=!1){this._areLightsDirty=!0,this._areLightsDisposed=this._areLightsDisposed||e,this._isDirty=!0}markAsAttributesDirty(){this._areAttributesDirty=!0,this._isDirty=!0}markAsTexturesDirty(){this._areTexturesDirty=!0,this._isDirty=!0}markAsFresnelDirty(){this._areFresnelDirty=!0,this._isDirty=!0}markAsMiscDirty(){this._areMiscDirty=!0,this._isDirty=!0}markAsPrePassDirty(){this._arePrePassDirty=!0,this._isDirty=!0}rebuild(){for(let e of(this._keys.length=0,Object.keys(this)))"_"!==e[0]&&this._keys.push(e);if(this._externalProperties)for(let e in this._externalProperties)-1===this._keys.indexOf(e)&&this._keys.push(e)}isEqual(e){if(this._keys.length!==e._keys.length)return!1;for(let t=0;t<this._keys.length;t++){let i=this._keys[t];if(this[i]!==e[i])return!1}return!0}cloneTo(e){this._keys.length!==e._keys.length&&(e._keys=this._keys.slice(0));for(let t=0;t<this._keys.length;t++){let i=this._keys[t];e[i]=this[i]}}reset(){for(let e of this._keys)this._setDefaultValue(e)}_setDefaultValue(e){let t=this._externalProperties?.[e]?.type??typeof this[e],i=this._externalProperties?.[e]?.default;switch(t){case"number":this[e]=i??0;break;case"string":this[e]=i??"";break;default:this[e]=i??!1}}toString(){let e="";for(let t=0;t<this._keys.length;t++){let i=this._keys[t],s=this[i];switch(typeof s){case"number":case"string":e+="#define "+i+" "+s+"\n";break;default:s&&(e+="#define "+i+"\n")}}return e}}])},89748,44451,e=>{"use strict";e.i(44702).MaterialDefines,e.s(["ImageProcessingDefinesMixin",0,function(e){return class extends e{constructor(){super(...arguments),this.IMAGEPROCESSING=!1,this.VIGNETTE=!1,this.VIGNETTEBLENDMODEMULTIPLY=!1,this.VIGNETTEBLENDMODEOPAQUE=!1,this.TONEMAPPING=0,this.CONTRAST=!1,this.COLORCURVES=!1,this.COLORGRADING=!1,this.COLORGRADING3D=!1,this.SAMPLER3DGREENDEPTH=!1,this.SAMPLER3DBGRMAP=!1,this.DITHER=!1,this.IMAGEPROCESSINGPOSTPROCESS=!1,this.SKIPFINALCOLORCLAMP=!1,this.EXPOSURE=!1}}}],89748);var t,i,s=e.i(96265);(t=i||(i={}))[t.Zero=0]="Zero",t[t.One=1]="One",t[t.MaxViewZ=2]="MaxViewZ",t[t.NoClear=3]="NoClear";class r{static CreateConfiguration(e){return r._Configurations[e]={defines:{},previousWorldMatrices:{},previousViewProjection:s.Matrix.Zero(),currentViewProjection:s.Matrix.Zero(),previousBones:{},lastUpdateFrameId:-1,excludedSkinnedMesh:[],reverseCulling:!1},r._Configurations[e]}static DeleteConfiguration(e){delete r._Configurations[e]}static GetConfiguration(e){return r._Configurations[e]}static AddUniformsAndSamplers(e,t){e.push("previousWorld","previousViewProjection","mPreviousBones")}static MarkAsDirty(e,t){for(let i of t)if(i.subMeshes)for(let t of i.subMeshes)t._removeDrawWrapper(e)}static PrepareDefines(e,t,i){if(!i._arePrePassDirty)return;let s=r._Configurations[e];if(!s)return;i.PREPASS=!0;let a=0;for(let e=0;e<r.GeometryTextureDescriptions.length;e++){let t=r.GeometryTextureDescriptions[e],n=t.define,o=t.defineIndex,l=s.defines[o];void 0!==l?(i[n]=!0,i[o]=l,a++):(i[n]=!1,delete i[o])}i.SCENE_MRT_COUNT=a,i.BONES_VELOCITY_ENABLED=t.useBones&&t.computeBonesUsingShaders&&t.skeleton&&!t.skeleton.isUsingTextureForMatrices&&-1===s.excludedSkinnedMesh.indexOf(t)}static Bind(e,t,i,s,a){let n=r._Configurations[e];if(!n)return;let o=i.getScene(),l=o.getEngine();if(n.reverseCulling&&l.setStateCullFaceType(o._mirroredCameraPosition?a.cullBackFaces:!a.cullBackFaces),(void 0!==n.defines.PREPASS_VELOCITY_INDEX||void 0!==n.defines.PREPASS_VELOCITY_LINEAR_INDEX)&&(n.previousWorldMatrices[i.uniqueId]||(n.previousWorldMatrices[i.uniqueId]=s.clone()),n.previousViewProjection||(n.previousViewProjection=o.getTransformMatrix().clone(),n.currentViewProjection=o.getTransformMatrix().clone()),n.currentViewProjection.updateFlag!==o.getTransformMatrix().updateFlag?(n.lastUpdateFrameId=l.frameId,n.previousViewProjection.copyFrom(n.currentViewProjection),n.currentViewProjection.copyFrom(o.getTransformMatrix())):n.lastUpdateFrameId!==l.frameId&&(n.lastUpdateFrameId=l.frameId,n.previousViewProjection.copyFrom(n.currentViewProjection)),t.setMatrix("previousWorld",n.previousWorldMatrices[i.uniqueId]),t.setMatrix("previousViewProjection",n.previousViewProjection),n.previousWorldMatrices[i.uniqueId]=s.clone(),i.useBones&&i.computeBonesUsingShaders&&i.skeleton)){let e=i.skeleton;if(!e.isUsingTextureForMatrices||-1===t.getUniformIndex("boneTextureInfo")){let s=e.getTransformMatrices(i);s&&(n.previousBones[i.uniqueId]||(n.previousBones[i.uniqueId]=s.slice()),t.setMatrices("mPreviousBones",n.previousBones[i.uniqueId]),n.previousBones[i.uniqueId].set(s))}}}}r.GeometryTextureDescriptions=[{type:0,name:"IrradianceLegacy",clearType:0,define:"PREPASS_IRRADIANCE_LEGACY",defineIndex:"PREPASS_IRRADIANCE_LEGACY_INDEX"},{type:1,name:"WorldPosition",clearType:0,define:"PREPASS_POSITION",defineIndex:"PREPASS_POSITION_INDEX"},{type:2,name:"Velocity",clearType:0,define:"PREPASS_VELOCITY",defineIndex:"PREPASS_VELOCITY_INDEX"},{type:3,name:"Reflectivity",clearType:0,define:"PREPASS_REFLECTIVITY",defineIndex:"PREPASS_REFLECTIVITY_INDEX"},{type:5,name:"ViewDepth",clearType:2,define:"PREPASS_DEPTH",defineIndex:"PREPASS_DEPTH_INDEX"},{type:6,name:"ViewNormal",clearType:0,define:"PREPASS_NORMAL",defineIndex:"PREPASS_NORMAL_INDEX"},{type:7,name:"AlbedoSqrt",clearType:0,define:"PREPASS_ALBEDO_SQRT",defineIndex:"PREPASS_ALBEDO_SQRT_INDEX"},{type:8,name:"WorldNormal",clearType:0,define:"PREPASS_WORLD_NORMAL",defineIndex:"PREPASS_WORLD_NORMAL_INDEX"},{type:9,name:"LocalPosition",clearType:0,define:"PREPASS_LOCAL_POSITION",defineIndex:"PREPASS_LOCAL_POSITION_INDEX"},{type:10,name:"ScreenDepth",clearType:1,define:"PREPASS_SCREENSPACE_DEPTH",defineIndex:"PREPASS_SCREENSPACE_DEPTH_INDEX"},{type:11,name:"LinearVelocity",clearType:0,define:"PREPASS_VELOCITY_LINEAR",defineIndex:"PREPASS_VELOCITY_LINEAR_INDEX"},{type:12,name:"Albedo",clearType:0,define:"PREPASS_ALBEDO",defineIndex:"PREPASS_ALBEDO_INDEX"},{type:13,name:"NormalizedViewDepth",clearType:1,define:"PREPASS_NORMALIZED_VIEW_DEPTH",defineIndex:"PREPASS_NORMALIZED_VIEW_DEPTH_INDEX"},{type:4,name:"Color",clearType:3,define:"PREPASS_COLOR",defineIndex:"PREPASS_COLOR_INDEX"},{type:14,name:"Irradiance",clearType:0,define:"PREPASS_IRRADIANCE",defineIndex:"PREPASS_IRRADIANCE_INDEX"}],r._Configurations={},e.s(["MaterialHelperGeometryRendering",0,r],44451)},80737,37882,5436,e=>{"use strict";e.s(["UVDefinesMixin",0,function(e){return class extends e{constructor(){super(...arguments),this.MAINUV1=!1,this.MAINUV2=!1,this.MAINUV3=!1,this.MAINUV4=!1,this.MAINUV5=!1,this.MAINUV6=!1,this.UV1=!1,this.UV2=!1,this.UV3=!1,this.UV4=!1,this.UV5=!1,this.UV6=!1}}}],80737),e.s(["PrepassDefinesMixin",0,function(e){return class extends e{constructor(){super(...arguments),this.PREPASS=!1,this.PREPASS_COLOR=!1,this.PREPASS_COLOR_INDEX=-1,this.PREPASS_IRRADIANCE_LEGACY=!1,this.PREPASS_IRRADIANCE_LEGACY_INDEX=-1,this.PREPASS_IRRADIANCE=!1,this.PREPASS_IRRADIANCE_INDEX=-1,this.PREPASS_ALBEDO=!1,this.PREPASS_ALBEDO_INDEX=-1,this.PREPASS_ALBEDO_SQRT=!1,this.PREPASS_ALBEDO_SQRT_INDEX=-1,this.PREPASS_DEPTH=!1,this.PREPASS_DEPTH_INDEX=-1,this.PREPASS_SCREENSPACE_DEPTH=!1,this.PREPASS_SCREENSPACE_DEPTH_INDEX=-1,this.PREPASS_NORMALIZED_VIEW_DEPTH=!1,this.PREPASS_NORMALIZED_VIEW_DEPTH_INDEX=-1,this.PREPASS_NORMAL=!1,this.PREPASS_NORMAL_INDEX=-1,this.PREPASS_NORMAL_WORLDSPACE=!1,this.PREPASS_WORLD_NORMAL=!1,this.PREPASS_WORLD_NORMAL_INDEX=-1,this.PREPASS_POSITION=!1,this.PREPASS_POSITION_INDEX=-1,this.PREPASS_LOCAL_POSITION=!1,this.PREPASS_LOCAL_POSITION_INDEX=-1,this.PREPASS_VELOCITY=!1,this.PREPASS_VELOCITY_INDEX=-1,this.PREPASS_VELOCITY_LINEAR=!1,this.PREPASS_VELOCITY_LINEAR_INDEX=-1,this.PREPASS_REFLECTIVITY=!1,this.PREPASS_REFLECTIVITY_INDEX=-1,this.SCENE_MRT_COUNT=0}}}],37882);var t=e.i(37143);e.s(["ImageProcessingMixin",0,function(e){return class extends e{constructor(...e){super(...e),(0,t.serializeAsImageProcessingConfiguration)()(this,"_imageProcessingConfiguration")}get imageProcessingConfiguration(){return this._imageProcessingConfiguration}set imageProcessingConfiguration(e){this._attachImageProcessingConfiguration(e),this._markAllSubMeshesAsImageProcessingDirty&&this._markAllSubMeshesAsImageProcessingDirty()}_attachImageProcessingConfiguration(e){e!==this._imageProcessingConfiguration&&(this._imageProcessingConfiguration&&this._imageProcessingObserver&&this._imageProcessingConfiguration.onUpdateParameters.remove(this._imageProcessingObserver),!e&&this.getScene?this._imageProcessingConfiguration=this.getScene().imageProcessingConfiguration:e&&(this._imageProcessingConfiguration=e),this._imageProcessingConfiguration&&(this._imageProcessingObserver=this._imageProcessingConfiguration.onUpdateParameters.add(()=>{this._markAllSubMeshesAsImageProcessingDirty&&this._markAllSubMeshesAsImageProcessingDirty()})))}get cameraColorCurvesEnabled(){return this.imageProcessingConfiguration.colorCurvesEnabled}set cameraColorCurvesEnabled(e){this.imageProcessingConfiguration.colorCurvesEnabled=e}get cameraColorGradingEnabled(){return this.imageProcessingConfiguration.colorGradingEnabled}set cameraColorGradingEnabled(e){this.imageProcessingConfiguration.colorGradingEnabled=e}get cameraToneMappingEnabled(){return this._imageProcessingConfiguration.toneMappingEnabled}set cameraToneMappingEnabled(e){this._imageProcessingConfiguration.toneMappingEnabled=e}get cameraExposure(){return this._imageProcessingConfiguration.exposure}set cameraExposure(e){this._imageProcessingConfiguration.exposure=e}get cameraContrast(){return this._imageProcessingConfiguration.contrast}set cameraContrast(e){this._imageProcessingConfiguration.contrast=e}get cameraColorGradingTexture(){return this._imageProcessingConfiguration.colorGradingTexture}set cameraColorGradingTexture(e){this._imageProcessingConfiguration.colorGradingTexture=e}get cameraColorCurves(){return this._imageProcessingConfiguration.colorCurves}set cameraColorCurves(e){this._imageProcessingConfiguration.colorCurves=e}}}],5436)},86206,78831,e=>{"use strict";var t=e.i(10272),i=e.i(23507),s=e.i(37143),r=e.i(33457),a=e.i(44702),n=e.i(74596),o=e.i(12423);let l=RegExp("^([gimus]+)!");class h{constructor(e){this._plugins=[],this._activePlugins=[],this._activePluginsForExtraEvents=[],this._material=e,this._scene=e.getScene(),this._engine=this._scene.getEngine()}_addPlugin(e){for(let t=0;t<this._plugins.length;++t)if(this._plugins[t].name===e.name)return!1;if(this._material._uniformBufferLayoutBuilt&&(this._material.resetDrawCache(),this._material._createUniformBuffer()),!e.isCompatible(this._material.shaderLanguage))throw`The plugin "${e.name}" can't be added to the material "${this._material.name}" because the plugin is not compatible with the shader language of the material.`;let t=e.getClassName();h._MaterialPluginClassToMainDefine[t]||(h._MaterialPluginClassToMainDefine[t]="MATERIALPLUGIN_"+ ++h._MaterialPluginCounter),this._material._callbackPluginEventGeneric=(e,t)=>this._handlePluginEvent(e,t),this._plugins.push(e),this._plugins.sort((e,t)=>e.priority-t.priority),this._codeInjectionPoints={};let i={};for(let e of(i[h._MaterialPluginClassToMainDefine[t]]={type:"boolean",default:!0},this._plugins))e.collectDefines(i),this._collectPointNames("vertex",e.getCustomCode("vertex",this._material.shaderLanguage)),this._collectPointNames("fragment",e.getCustomCode("fragment",this._material.shaderLanguage));return this._defineNamesFromPlugins=i,!0}_activatePlugin(e){-1===this._activePlugins.indexOf(e)&&(this._activePlugins.push(e),this._activePlugins.sort((e,t)=>e.priority-t.priority),this._material._callbackPluginEventIsReadyForSubMesh=this._handlePluginEventIsReadyForSubMesh.bind(this),this._material._callbackPluginEventPrepareDefinesBeforeAttributes=this._handlePluginEventPrepareDefinesBeforeAttributes.bind(this),this._material._callbackPluginEventPrepareDefines=this._handlePluginEventPrepareDefines.bind(this),this._material._callbackPluginEventBindForSubMesh=this._handlePluginEventBindForSubMesh.bind(this),e.registerForExtraEvents&&(this._activePluginsForExtraEvents.push(e),this._activePluginsForExtraEvents.sort((e,t)=>e.priority-t.priority),this._material._callbackPluginEventHasRenderTargetTextures=this._handlePluginEventHasRenderTargetTextures.bind(this),this._material._callbackPluginEventFillRenderTargetTextures=this._handlePluginEventFillRenderTargetTextures.bind(this),this._material._callbackPluginEventHardBindForSubMesh=this._handlePluginEventHardBindForSubMesh.bind(this)))}getPlugin(e){for(let t=0;t<this._plugins.length;++t)if(this._plugins[t].name===e)return this._plugins[t];return null}_handlePluginEventIsReadyForSubMesh(e){let t=!0;for(let i of this._activePlugins)t=t&&i.isReadyForSubMesh(e.defines,this._scene,this._engine,e.subMesh);e.isReadyForSubMesh=t}_handlePluginEventPrepareDefinesBeforeAttributes(e){for(let t of this._activePlugins)t.prepareDefinesBeforeAttributes(e.defines,this._scene,e.mesh)}_handlePluginEventPrepareDefines(e){for(let t of this._activePlugins)t.prepareDefines(e.defines,this._scene,e.mesh)}_handlePluginEventHardBindForSubMesh(e){for(let t of this._activePluginsForExtraEvents)t.hardBindForSubMesh(this._material._uniformBuffer,this._scene,this._engine,e.subMesh)}_handlePluginEventBindForSubMesh(e){for(let t of this._activePlugins)t.bindForSubMesh(this._material._uniformBuffer,this._scene,this._engine,e.subMesh)}_handlePluginEventHasRenderTargetTextures(e){let t=!1;for(let e of this._activePluginsForExtraEvents)if(t=e.hasRenderTargetTextures())break;e.hasRenderTargetTextures=t}_handlePluginEventFillRenderTargetTextures(e){for(let t of this._activePluginsForExtraEvents)t.fillRenderTargetTextures(e.renderTargets)}_handlePluginEvent(e,t){switch(e){case 512:for(let e of this._activePlugins)e.getActiveTextures(t.activeTextures);break;case 256:for(let e of this._activePlugins)e.getAnimatables(t.animatables);break;case 1024:{let e=!1;for(let i of this._activePlugins)if(e=i.hasTexture(t.texture))break;t.hasTexture=e;break}case 2:for(let e of this._plugins)e.dispose(t.forceDisposeTextures);break;case 4:t.defineNames=this._defineNamesFromPlugins;break;case 128:for(let e of this._activePlugins)t.fallbackRank=e.addFallbacks(t.defines,t.fallbacks,t.fallbackRank),e.getAttributes(t.attributes,this._scene,t.mesh);this._uniformList.length>0&&t.uniforms.push(...this._uniformList),this._samplerList.length>0&&t.samplers.push(...this._samplerList),this._uboList.length>0&&t.uniformBuffersNames.push(...this._uboList),t.customCode=this._injectCustomCode(t,t.customCode);break;case 8:{this._uboDeclaration="",this._vertexDeclaration="",this._fragmentDeclaration="",this._uniformList=[],this._samplerList=[],this._uboList=[];let e=1===this._material.shaderLanguage;for(let i of this._plugins){let s=i.getUniforms(this._material.shaderLanguage);if(s){if(s.ubo)for(let i of s.ubo){if(i.size&&i.type){let s=i.arraySize??0;if(t.ubo.addUniform(i.name,i.size,s),e){let e;switch(i.type){case"mat4":e="mat4x4f";break;case"float":e="f32";break;default:e=`${i.type}f`}s>0?this._uboDeclaration+=`uniform ${i.name}: array<${e}, ${s}>;
|
|
2
|
+
`:this._uboDeclaration+=`uniform ${i.name}: ${e};
|
|
3
|
+
`}else this._uboDeclaration+=`${i.type} ${i.name}${s>0?`[${s}]`:""};
|
|
4
|
+
`}this._uniformList.push(i.name)}s.vertex&&(this._vertexDeclaration+=s.vertex+"\n"),s.fragment&&(this._fragmentDeclaration+=s.fragment+"\n"),s.externalUniforms&&this._uniformList.push(...s.externalUniforms)}i.getSamplers(this._samplerList),i.getUniformBuffersNames(this._uboList)}}}}_collectPointNames(e,t){if(t)for(let i in t)this._codeInjectionPoints[e]||(this._codeInjectionPoints[e]={}),this._codeInjectionPoints[e][i]=!0}_injectCustomCode(e,t){return(i,s)=>{t&&(s=t(i,s)),this._uboDeclaration&&(s=s.replace("#define ADDITIONAL_UBO_DECLARATION",this._uboDeclaration)),this._vertexDeclaration&&(s=s.replace("#define ADDITIONAL_VERTEX_DECLARATION",this._vertexDeclaration)),this._fragmentDeclaration&&(s=s.replace("#define ADDITIONAL_FRAGMENT_DECLARATION",this._fragmentDeclaration));let r=this._codeInjectionPoints?.[i];if(!r)return s;let a=null;for(let t in r){let r="";for(let s of this._activePlugins){let l=this._material.shaderLanguage,h=s.getCustomCode(i,l)?.[t];h&&(s.resolveIncludes&&(null===a&&(a={defines:[],indexParameters:e.indexParameters,isFragment:!1,shouldUseHighPrecisionShader:this._engine._shouldUseHighPrecisionShader,processor:void 0,supportsUniformBuffers:this._engine.supportsUniformBuffers,shadersRepository:o.ShaderStore.GetShadersRepository(l),includesShadersStore:o.ShaderStore.GetIncludesShadersStore(l),version:void 0,platformName:this._engine.shaderPlatformName,processingContext:void 0,isNDCHalfZRange:this._engine.isNDCHalfZRange,useReverseDepthBuffer:this._engine.useReverseDepthBuffer,processCodeAfterIncludes:void 0}),a.isFragment="fragment"===i,(0,n.ProcessIncludes)(h,a,e=>h=e)),r+=h+"\n")}if(r.length>0)if("!"===t.charAt(0)){t=t.substring(1);let e="g";if("!"===t.charAt(0))e="",t=t.substring(1);else{let i=l.exec(t);i&&i.length>=2&&(e=i[1],t=t.substring(e.length+1))}0>e.indexOf("g")&&(e+="g");let i=s,a=new RegExp(t,e),n=a.exec(i);for(;null!==n;){let e=r;for(let t=0;t<n.length;++t)e=e.replace("$"+t,n[t]);s=s.replace(n[0],e),n=a.exec(i)}}else{let e="#define "+t;s=s.replace(e,"\n"+r+"\n"+e)}}return s}}}h._MaterialPluginClassToMainDefine={},h._MaterialPluginCounter=0;var u=e.i(80871);class _{isCompatible(e){return 0===e}_enable(e){e&&this._pluginManager._activatePlugin(this)}constructor(e,t,i,s,r=!0,a=!1,n=!1){this.priority=500,this.resolveIncludes=!1,this.registerForExtraEvents=!1,this.doNotSerialize=!1,this._material=e,this.name=t,this.priority=i,this.resolveIncludes=n,e.pluginManager||(e.pluginManager=new h(e),e.onDisposeObservable.add(()=>{e.pluginManager=void 0})),this._pluginDefineNames=s,this._pluginManager=e.pluginManager,r&&this._pluginManager._addPlugin(this),a&&this._enable(!0),this.markAllDefinesAsDirty=e._dirtyCallbacks[127]}getClassName(){return"MaterialPluginBase"}isReadyForSubMesh(e,t,i,s){return!0}hardBindForSubMesh(e,t,i,s){}bindForSubMesh(e,t,i,s){}dispose(e){}getCustomCode(e,t=0){return null}collectDefines(e){if(this._pluginDefineNames)for(let t of Object.keys(this._pluginDefineNames)){if("_"===t[0])continue;let i=typeof this._pluginDefineNames[t];e[t]={type:"number"===i?"number":"string"===i?"string":"boolean"===i?"boolean":"object",default:this._pluginDefineNames[t]}}}prepareDefinesBeforeAttributes(e,t,i){}prepareDefines(e,t,i){}hasTexture(e){return!1}hasRenderTargetTextures(){return!1}fillRenderTargetTextures(e){}getActiveTextures(e){}getAnimatables(e){}addFallbacks(e,t,i){return i}getSamplers(e){}getAttributes(e,t,i){}getUniformBuffersNames(e){}getUniforms(e=0){return{}}copyTo(e){u.SerializationHelper.Clone(()=>e,this)}serialize(){return u.SerializationHelper.Serialize(this)}parse(e,t,i){u.SerializationHelper.Parse(()=>this,e,t,i)}}(0,t.__decorate)([(0,s.serialize)()],_.prototype,"name",void 0),(0,t.__decorate)([(0,s.serialize)()],_.prototype,"priority",void 0),(0,t.__decorate)([(0,s.serialize)()],_.prototype,"resolveIncludes",void 0),(0,t.__decorate)([(0,s.serialize)()],_.prototype,"registerForExtraEvents",void 0),e.s(["MaterialPluginBase",0,_],78831);var d=e.i(97001);class c extends a.MaterialDefines{constructor(){super(...arguments),this.DETAIL=!1,this.DETAILDIRECTUV=0,this.DETAIL_NORMALBLENDMETHOD=0}}class g extends _{_markAllSubMeshesAsTexturesDirty(){this._enable(this._isEnabled),this._internalMarkAllSubMeshesAsTexturesDirty()}isCompatible(){return!0}constructor(e,t=!0){super(e,"DetailMap",140,new c,t),this._texture=null,this.diffuseBlendLevel=1,this.roughnessBlendLevel=1,this.bumpLevel=1,this._normalBlendMethod=i.Material.MATERIAL_NORMALBLENDMETHOD_WHITEOUT,this._isEnabled=!1,this.isEnabled=!1,this._internalMarkAllSubMeshesAsTexturesDirty=e._dirtyCallbacks[1]}isReadyForSubMesh(e,t,i){return!this._isEnabled||!e._areTexturesDirty||!t.texturesEnabled||!i.getCaps().standardDerivatives||!this._texture||!r.MaterialFlags.DetailTextureEnabled||!!this._texture.isReady()}prepareDefines(e,t){if(this._isEnabled){e.DETAIL_NORMALBLENDMETHOD=this._normalBlendMethod;let i=t.getEngine();e._areTexturesDirty&&(i.getCaps().standardDerivatives&&this._texture&&r.MaterialFlags.DetailTextureEnabled&&this._isEnabled?((0,d.PrepareDefinesForMergedUV)(this._texture,e,"DETAIL"),e.DETAIL_NORMALBLENDMETHOD=this._normalBlendMethod):e.DETAIL=!1)}else e.DETAIL=!1}bindForSubMesh(e,t){if(!this._isEnabled)return;let i=this._material.isFrozen;e.useUbo&&i&&e.isSync||!this._texture||!r.MaterialFlags.DetailTextureEnabled||(e.updateFloat4("vDetailInfos",this._texture.coordinatesIndex,this.diffuseBlendLevel,this.bumpLevel,this.roughnessBlendLevel),(0,d.BindTextureMatrix)(this._texture,e,"detail")),t.texturesEnabled&&this._texture&&r.MaterialFlags.DetailTextureEnabled&&e.setTexture("detailSampler",this._texture)}hasTexture(e){return this._texture===e}getActiveTextures(e){this._texture&&e.push(this._texture)}getAnimatables(e){this._texture&&this._texture.animations&&this._texture.animations.length>0&&e.push(this._texture)}dispose(e){e&&this._texture?.dispose()}getClassName(){return"DetailMapConfiguration"}getSamplers(e){e.push("detailSampler")}getUniforms(){return{ubo:[{name:"vDetailInfos",size:4,type:"vec4"},{name:"detailMatrix",size:16,type:"mat4"}]}}}(0,t.__decorate)([(0,s.serializeAsTexture)("detailTexture"),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],g.prototype,"texture",void 0),(0,t.__decorate)([(0,s.serialize)()],g.prototype,"diffuseBlendLevel",void 0),(0,t.__decorate)([(0,s.serialize)()],g.prototype,"roughnessBlendLevel",void 0),(0,t.__decorate)([(0,s.serialize)()],g.prototype,"bumpLevel",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],g.prototype,"normalBlendMethod",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],g.prototype,"isEnabled",void 0),e.s(["DetailMapConfiguration",0,g],86206)},32550,e=>{"use strict";e.i(9866);var t=e.i(23015);e.s(["RegisterStandardMaterial",()=>t.RegisterStandardMaterial,"StandardMaterial",()=>t.StandardMaterial,"StandardMaterialDefines",()=>t.StandardMaterialDefines])},60020,e=>{e.v(t=>Promise.all(["static/chunks/32ahba5ezp467.js"].map(t=>e.l(t))).then(()=>t(44237)))},66183,e=>{e.v(t=>Promise.all(["static/chunks/1qg_etglhvp9h.js","static/chunks/38x3c1ra5slhe.js"].map(t=>e.l(t))).then(()=>t(40042)))},22649,e=>{e.v(t=>Promise.all(["static/chunks/0otsec99kdkt7.js","static/chunks/1ltux4lwz7muf.js"].map(t=>e.l(t))).then(()=>t(14610)))},39487,e=>{e.v(t=>Promise.all(["static/chunks/41wt50z9tx9cx.js","static/chunks/1_qzlkuxukhpq.js"].map(t=>e.l(t))).then(()=>t(26022)))}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,21143,e=>{"use strict";class t{constructor(e){this._pendingActions=[],this._workerInfos=e.map(e=>({workerPromise:Promise.resolve(e),idle:!0}))}dispose(){for(let e of this._workerInfos)e.workerPromise.then(e=>{e.terminate()});this._workerInfos.length=0,this._pendingActions.length=0}push(e){this._executeOnIdleWorker(e)||this._pendingActions.push(e)}_executeOnIdleWorker(e){for(let t of this._workerInfos)if(t.idle)return this._execute(t,e),!0;return!1}_execute(e,t){e.idle=!1,e.workerPromise.then(r=>{t(r,()=>{let t=this._pendingActions.shift();t?this._execute(e,t):e.idle=!0})})}}class r extends t{constructor(e,t,s=r.DefaultOptions){super([]),this._maxWorkers=e,this._createWorkerAsync=t,this._options=s}push(e){if(!this._executeOnIdleWorker(e))if(this._workerInfos.length<this._maxWorkers){let t={workerPromise:this._createWorkerAsync(),idle:!1};this._workerInfos.push(t),this._execute(t,e)}else this._pendingActions.push(e)}_execute(e,t){e.timeoutId&&(clearTimeout(e.timeoutId),delete e.timeoutId),super._execute(e,(r,s)=>{t(r,()=>{s(),e.idle&&(e.timeoutId=setTimeout(()=>{e.workerPromise.then(e=>{e.terminate()});let t=this._workerInfos.indexOf(e);-1!==t&&this._workerInfos.splice(t,1)},this._options.idleTimeElapsedBeforeRelease))})})}}r.DefaultOptions={idleTimeElapsedBeforeRelease:1e3},e.s(["AutoReleaseWorkerPool",0,r])},58046,e=>{"use strict";var t,r,s,o,a,i,n=e.i(13379);class c{constructor(e,t){if(this.data=e,this.isInvalid=!1,!c.IsValid(e)){this.isInvalid=!0,n.Logger.Error("texture missing KTX identifier");return}const r=Uint32Array.BYTES_PER_ELEMENT,s=new DataView(this.data.buffer,this.data.byteOffset+12,13*r),o=0x4030201===s.getUint32(0,!0);if(this.glType=s.getUint32(+r,o),this.glTypeSize=s.getUint32(2*r,o),this.glFormat=s.getUint32(3*r,o),this.glInternalFormat=s.getUint32(4*r,o),this.glBaseInternalFormat=s.getUint32(5*r,o),this.pixelWidth=s.getUint32(6*r,o),this.pixelHeight=s.getUint32(7*r,o),this.pixelDepth=s.getUint32(8*r,o),this.numberOfArrayElements=s.getUint32(9*r,o),this.numberOfFaces=s.getUint32(10*r,o),this.numberOfMipmapLevels=s.getUint32(11*r,o),this.bytesOfKeyValueData=s.getUint32(12*r,o),0!==this.glType){n.Logger.Error("only compressed formats currently supported"),this.isInvalid=!0;return}if(this.numberOfMipmapLevels=Math.max(1,this.numberOfMipmapLevels),0===this.pixelHeight||0!==this.pixelDepth){n.Logger.Error("only 2D textures currently supported"),this.isInvalid=!0;return}if(0!==this.numberOfArrayElements){n.Logger.Error("texture arrays not currently supported"),this.isInvalid=!0;return}if(this.numberOfFaces!==t){n.Logger.Error("number of faces expected"+t+", but found "+this.numberOfFaces),this.isInvalid=!0;return}this.loadType=c.COMPRESSED_2D}uploadLevels(e,t){switch(this.loadType){case c.COMPRESSED_2D:this._upload2DCompressedLevels(e,t);case c.TEX_2D:case c.COMPRESSED_3D:case c.TEX_3D:}}_upload2DCompressedLevels(e,t){let r=c.HEADER_LEN+this.bytesOfKeyValueData,s=this.pixelWidth,o=this.pixelHeight,a=t?this.numberOfMipmapLevels:1;for(let t=0;t<a;t++){let a=new Int32Array(this.data.buffer,this.data.byteOffset+r,1)[0];r+=4;for(let i=0;i<this.numberOfFaces;i++){let n=new Uint8Array(this.data.buffer,this.data.byteOffset+r,a);e.getEngine()._uploadCompressedDataToTextureDirectly(e,e.format,s,o,n,i,t),r+=a,r+=3-(a+3)%4}s=Math.max(1,.5*s),o=Math.max(1,.5*o)}}static IsValid(e){if(e.byteLength>=12){let t=new Uint8Array(e.buffer,e.byteOffset,12);if(171===t[0]&&75===t[1]&&84===t[2]&&88===t[3]&&32===t[4]&&49===t[5]&&49===t[6]&&187===t[7]&&13===t[8]&&10===t[9]&&26===t[10]&&10===t[11])return!0}return!1}}c.HEADER_LEN=64,c.COMPRESSED_2D=0,c.COMPRESSED_3D=1,c.TEX_2D=2,c.TEX_3D=3;var l=e.i(21143),d=e.i(65740);function T(e,t){let r=t?.jsDecoderModule||KTX2DECODER;e&&(e.wasmBaseUrl&&(r.Transcoder.WasmBaseUrl=e.wasmBaseUrl),e.wasmUASTCToASTC&&(r.LiteTranscoder_UASTC_ASTC.WasmModuleURL=e.wasmUASTCToASTC),e.wasmUASTCToBC7&&(r.LiteTranscoder_UASTC_BC7.WasmModuleURL=e.wasmUASTCToBC7),e.wasmUASTCToRGBA_UNORM&&(r.LiteTranscoder_UASTC_RGBA_UNORM.WasmModuleURL=e.wasmUASTCToRGBA_UNORM),e.wasmUASTCToRGBA_SRGB&&(r.LiteTranscoder_UASTC_RGBA_SRGB.WasmModuleURL=e.wasmUASTCToRGBA_SRGB),e.wasmUASTCToR8_UNORM&&(r.LiteTranscoder_UASTC_R8_UNORM.WasmModuleURL=e.wasmUASTCToR8_UNORM),e.wasmUASTCToRG8_UNORM&&(r.LiteTranscoder_UASTC_RG8_UNORM.WasmModuleURL=e.wasmUASTCToRG8_UNORM),e.jsMSCTranscoder&&(r.MSCTranscoder.JSModuleURL=e.jsMSCTranscoder),e.wasmMSCTranscoder&&(r.MSCTranscoder.WasmModuleURL=e.wasmMSCTranscoder),e.wasmZSTDDecoder&&(r.ZSTDDecoder.WasmModuleURL=e.wasmZSTDDecoder)),t&&(t.wasmUASTCToASTC&&(r.LiteTranscoder_UASTC_ASTC.WasmBinary=t.wasmUASTCToASTC),t.wasmUASTCToBC7&&(r.LiteTranscoder_UASTC_BC7.WasmBinary=t.wasmUASTCToBC7),t.wasmUASTCToRGBA_UNORM&&(r.LiteTranscoder_UASTC_RGBA_UNORM.WasmBinary=t.wasmUASTCToRGBA_UNORM),t.wasmUASTCToRGBA_SRGB&&(r.LiteTranscoder_UASTC_RGBA_SRGB.WasmBinary=t.wasmUASTCToRGBA_SRGB),t.wasmUASTCToR8_UNORM&&(r.LiteTranscoder_UASTC_R8_UNORM.WasmBinary=t.wasmUASTCToR8_UNORM),t.wasmUASTCToRG8_UNORM&&(r.LiteTranscoder_UASTC_RG8_UNORM.WasmBinary=t.wasmUASTCToRG8_UNORM),t.jsMSCTranscoder&&(r.MSCTranscoder.JSModule=t.jsMSCTranscoder),t.wasmMSCTranscoder&&(r.MSCTranscoder.WasmBinary=t.wasmMSCTranscoder),t.wasmZSTDDecoder&&(r.ZSTDDecoder.WasmBinary=t.wasmZSTDDecoder))}function _(e){let t;void 0===e&&"u">typeof KTX2DECODER&&(e=KTX2DECODER),onmessage=r=>{if(r.data)switch(r.data.action){case"init":{let s=r.data.urls;s&&(s.jsDecoderModule&&void 0===e&&(importScripts(s.jsDecoderModule),e=KTX2DECODER),T(s)),r.data.wasmBinaries&&T(void 0,{...r.data.wasmBinaries,jsDecoderModule:e}),t=new e.KTX2Decoder,postMessage({action:"init"});break}case"setDefaultDecoderOptions":e.KTX2Decoder.DefaultDecoderOptions=r.data.options;break;case"decode":t.decode(r.data.data,r.data.caps,r.data.options).then(e=>{let t=[];for(let r=0;r<e.mipmaps.length;++r){let s=e.mipmaps[r];s&&s.data&&t.push(s.data.buffer)}postMessage({action:"decoded",success:!0,decodedData:e},t)}).catch(e=>{postMessage({action:"decoded",success:!1,msg:e})})}}}async function u(e,t,r){return await new Promise((s,o)=>{let a=t=>{e.removeEventListener("error",a),e.removeEventListener("message",i),o(t)},i=t=>{"init"===t.data.action&&(e.removeEventListener("error",a),e.removeEventListener("message",i),s(e))};e.addEventListener("error",a),e.addEventListener("message",i),e.postMessage({action:"init",urls:r,wasmBinaries:t})})}(t=o||(o={}))[t.ETC1S=0]="ETC1S",t[t.UASTC4x4=1]="UASTC4x4",(r=a||(a={}))[r.ASTC_4X4_RGBA=0]="ASTC_4X4_RGBA",r[r.ASTC_4x4_RGBA=0]="ASTC_4x4_RGBA",r[r.BC7_RGBA=1]="BC7_RGBA",r[r.BC3_RGBA=2]="BC3_RGBA",r[r.BC1_RGB=3]="BC1_RGB",r[r.PVRTC1_4_RGBA=4]="PVRTC1_4_RGBA",r[r.PVRTC1_4_RGB=5]="PVRTC1_4_RGB",r[r.ETC2_RGBA=6]="ETC2_RGBA",r[r.ETC1_RGB=7]="ETC1_RGB",r[r.RGBA32=8]="RGBA32",r[r.R8=9]="R8",r[r.RG8=10]="RG8",(s=i||(i={}))[s.COMPRESSED_RGBA_BPTC_UNORM_EXT=36492]="COMPRESSED_RGBA_BPTC_UNORM_EXT",s[s.COMPRESSED_RGBA_ASTC_4X4_KHR=37808]="COMPRESSED_RGBA_ASTC_4X4_KHR",s[s.COMPRESSED_RGB_S3TC_DXT1_EXT=33776]="COMPRESSED_RGB_S3TC_DXT1_EXT",s[s.COMPRESSED_RGBA_S3TC_DXT5_EXT=33779]="COMPRESSED_RGBA_S3TC_DXT5_EXT",s[s.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG=35842]="COMPRESSED_RGBA_PVRTC_4BPPV1_IMG",s[s.COMPRESSED_RGB_PVRTC_4BPPV1_IMG=35840]="COMPRESSED_RGB_PVRTC_4BPPV1_IMG",s[s.COMPRESSED_RGBA8_ETC2_EAC=37496]="COMPRESSED_RGBA8_ETC2_EAC",s[s.COMPRESSED_RGB8_ETC2=37492]="COMPRESSED_RGB8_ETC2",s[s.COMPRESSED_RGB_ETC1_WEBGL=36196]="COMPRESSED_RGB_ETC1_WEBGL",s[s.RGBA8Format=32856]="RGBA8Format",s[s.R8Format=33321]="R8Format",s[s.RG8Format=33323]="RG8Format";class R{static GetDefaultNumWorkers(){return"object"==typeof navigator&&navigator.hardwareConcurrency?Math.min(Math.floor(.5*navigator.hardwareConcurrency),4):1}static _Initialize(e){if(R._WorkerPoolPromise||R._DecoderModulePromise)return;let t={wasmBaseUrl:d.Tools.ScriptBaseUrl,jsDecoderModule:d.Tools.GetBabylonScriptURL(this.URLConfig.jsDecoderModule,!0),wasmUASTCToASTC:d.Tools.GetBabylonScriptURL(this.URLConfig.wasmUASTCToASTC,!0),wasmUASTCToBC7:d.Tools.GetBabylonScriptURL(this.URLConfig.wasmUASTCToBC7,!0),wasmUASTCToRGBA_UNORM:d.Tools.GetBabylonScriptURL(this.URLConfig.wasmUASTCToRGBA_UNORM,!0),wasmUASTCToRGBA_SRGB:d.Tools.GetBabylonScriptURL(this.URLConfig.wasmUASTCToRGBA_SRGB,!0),wasmUASTCToR8_UNORM:d.Tools.GetBabylonScriptURL(this.URLConfig.wasmUASTCToR8_UNORM,!0),wasmUASTCToRG8_UNORM:d.Tools.GetBabylonScriptURL(this.URLConfig.wasmUASTCToRG8_UNORM,!0),jsMSCTranscoder:d.Tools.GetBabylonScriptURL(this.URLConfig.jsMSCTranscoder,!0),wasmMSCTranscoder:d.Tools.GetBabylonScriptURL(this.URLConfig.wasmMSCTranscoder,!0),wasmZSTDDecoder:d.Tools.GetBabylonScriptURL(this.URLConfig.wasmZSTDDecoder,!0)};e&&"function"==typeof Worker&&"u">typeof URL?R._WorkerPoolPromise=new Promise(r=>{let s=`${T}(${_})()`,o=URL.createObjectURL(new Blob([s],{type:"application/javascript"}));r(new l.AutoReleaseWorkerPool(e,async()=>await u(new Worker(o),void 0,t)))}):void 0===R._KTX2DecoderModule?R._DecoderModulePromise=d.Tools.LoadBabylonScriptAsync(t.jsDecoderModule).then(()=>(R._KTX2DecoderModule=KTX2DECODER,R._KTX2DecoderModule.MSCTranscoder.UseFromWorkerThread=!1,R._KTX2DecoderModule.WASMMemoryManager.LoadBinariesFromCurrentThread=!0,T(t,R._KTX2DecoderModule),new R._KTX2DecoderModule.KTX2Decoder)):(R._KTX2DecoderModule.MSCTranscoder.UseFromWorkerThread=!1,R._KTX2DecoderModule.WASMMemoryManager.LoadBinariesFromCurrentThread=!0,R._DecoderModulePromise=Promise.resolve(new R._KTX2DecoderModule.KTX2Decoder))}constructor(e,t=R.DefaultNumWorkers){this._engine=e;const r="object"==typeof t&&t.workerPool||R.WorkerPool;if(r)R._WorkerPoolPromise=Promise.resolve(r);else{"object"==typeof t?R._KTX2DecoderModule=t?.binariesAndModulesContainer?.jsDecoderModule:"u">typeof KTX2DECODER&&(R._KTX2DecoderModule=KTX2DECODER);const e="number"==typeof t?t:t.numWorkers??R.DefaultNumWorkers;R._Initialize(e)}}async _uploadAsync(e,t,r){let s=this._engine.getCaps(),o={astc:!!s.astc,bptc:!!s.bptc,s3tc:!!s.s3tc,pvrtc:!!s.pvrtc,etc2:!!s.etc2,etc1:!!s.etc1};if(R._WorkerPoolPromise){let s=await R._WorkerPoolPromise;return await new Promise((a,i)=>{s.push((s,n)=>{let c=e=>{s.removeEventListener("error",c),s.removeEventListener("message",l),i(e),n()},l=e=>{if("decoded"===e.data.action){if(s.removeEventListener("error",c),s.removeEventListener("message",l),e.data.success)try{this._createTexture(e.data.decodedData,t,r),a()}catch(e){i({message:e})}else i({message:e.data.msg});n()}};s.addEventListener("error",c),s.addEventListener("message",l),s.postMessage({action:"setDefaultDecoderOptions",options:R.DefaultDecoderOptions._getKTX2DecoderOptions()});let d=new Uint8Array(e.byteLength);d.set(new Uint8Array(e.buffer,e.byteOffset,e.byteLength)),s.postMessage({action:"decode",data:d,caps:o,options:r},[d.buffer])})})}if(R._DecoderModulePromise){let r=await R._DecoderModulePromise;return R.DefaultDecoderOptions.isDirty&&(R._KTX2DecoderModule.KTX2Decoder.DefaultDecoderOptions=R.DefaultDecoderOptions._getKTX2DecoderOptions()),await new Promise((o,a)=>{r.decode(e,s).then(e=>{this._createTexture(e,t),o()}).catch(e=>{a({message:e})})})}throw Error("KTX2 decoder module is not available")}_createTexture(e,t,r){this._engine._bindTextureDirectly(3553,t),r&&(r.transcodedFormat=e.transcodedFormat,r.isInGammaSpace=e.isInGammaSpace,r.hasAlpha=e.hasAlpha,r.transcoderName=e.transcoderName);let s=!0;switch(e.transcodedFormat){case 32856:t.type=0,t.format=5;break;case 33321:t.type=0,t.format=6;break;case 33323:t.type=0,t.format=7;break;default:t.format=e.transcodedFormat,s=!1}if(t._gammaSpace=e.isInGammaSpace,t.generateMipMaps=e.mipmaps.length>1,t.width=e.mipmaps[0].width,t.height=e.mipmaps[0].height,e.errors)throw Error("KTX2 container - could not transcode the data. "+e.errors);for(let r=0;r<e.mipmaps.length;++r){let o=e.mipmaps[r];if(!o||!o.data)throw Error("KTX2 container - could not transcode one of the image");s?(t.width=o.width,t.height=o.height,this._engine._uploadDataToTextureDirectly(t,o.data,0,r,void 0,!0)):this._engine._uploadCompressedDataToTextureDirectly(t,e.transcodedFormat,o.width,o.height,o.data,0,r)}t._extension=".ktx2",t.isReady=!0,this._engine._bindTextureDirectly(3553,null)}static IsValid(e){if(e.byteLength>=12){let t=new Uint8Array(e.buffer,e.byteOffset,12);if(171===t[0]&&75===t[1]&&84===t[2]&&88===t[3]&&32===t[4]&&50===t[5]&&48===t[6]&&187===t[7]&&13===t[8]&&10===t[9]&&26===t[10]&&10===t[11])return!0}return!1}}function m(e){switch(e){case 35916:return 33776;case 35918:return 33778;case 35919:return 33779;case 37493:return 37492;case 37497:return 37496;case 37495:return 37494;case 37840:return 37808;case 37841:return 37809;case 37842:return 37810;case 37843:return 37811;case 37844:return 37812;case 37845:return 37813;case 37846:return 37814;case 37847:return 37815;case 37848:return 37816;case 37849:return 37817;case 37850:return 37818;case 37851:return 37819;case 37852:return 37820;case 37853:return 37821;case 36493:return 36492}return null}R.URLConfig={jsDecoderModule:"https://cdn.babylonjs.com/babylon.ktx2Decoder.js",wasmUASTCToASTC:null,wasmUASTCToBC7:null,wasmUASTCToRGBA_UNORM:null,wasmUASTCToRGBA_SRGB:null,wasmUASTCToR8_UNORM:null,wasmUASTCToRG8_UNORM:null,jsMSCTranscoder:null,wasmMSCTranscoder:null,wasmZSTDDecoder:null},R.DefaultNumWorkers=R.GetDefaultNumWorkers(),R.DefaultDecoderOptions=new class{constructor(){this._isDirty=!0,this._useRGBAIfOnlyBC1BC3AvailableWhenUASTC=!0,this._ktx2DecoderOptions={}}get isDirty(){return this._isDirty}get useRGBAIfASTCBC7NotAvailableWhenUASTC(){return this._useRGBAIfASTCBC7NotAvailableWhenUASTC}set useRGBAIfASTCBC7NotAvailableWhenUASTC(e){this._useRGBAIfASTCBC7NotAvailableWhenUASTC!==e&&(this._useRGBAIfASTCBC7NotAvailableWhenUASTC=e,this._isDirty=!0)}get useRGBAIfOnlyBC1BC3AvailableWhenUASTC(){return this._useRGBAIfOnlyBC1BC3AvailableWhenUASTC}set useRGBAIfOnlyBC1BC3AvailableWhenUASTC(e){this._useRGBAIfOnlyBC1BC3AvailableWhenUASTC!==e&&(this._useRGBAIfOnlyBC1BC3AvailableWhenUASTC=e,this._isDirty=!0)}get forceRGBA(){return this._forceRGBA}set forceRGBA(e){this._forceRGBA!==e&&(this._forceRGBA=e,this._isDirty=!0)}get forceR8(){return this._forceR8}set forceR8(e){this._forceR8!==e&&(this._forceR8=e,this._isDirty=!0)}get forceRG8(){return this._forceRG8}set forceRG8(e){this._forceRG8!==e&&(this._forceRG8=e,this._isDirty=!0)}get bypassTranscoders(){return this._bypassTranscoders}set bypassTranscoders(e){this._bypassTranscoders!==e&&(this._bypassTranscoders=e,this._isDirty=!0)}_getKTX2DecoderOptions(){if(!this._isDirty)return this._ktx2DecoderOptions;this._isDirty=!1;let e={};return void 0!==this._useRGBAIfASTCBC7NotAvailableWhenUASTC&&(e.useRGBAIfASTCBC7NotAvailableWhenUASTC=this._useRGBAIfASTCBC7NotAvailableWhenUASTC),void 0!==this._forceRGBA&&(e.forceRGBA=this._forceRGBA),void 0!==this._forceR8&&(e.forceR8=this._forceR8),void 0!==this._forceRG8&&(e.forceRG8=this._forceRG8),void 0!==this._bypassTranscoders&&(e.bypassTranscoders=this._bypassTranscoders),this.useRGBAIfOnlyBC1BC3AvailableWhenUASTC&&(e.transcodeFormatDecisionTree={UASTC:{transcodeFormat:[a.BC1_RGB,a.BC3_RGBA],yes:{transcodeFormat:a.RGBA32,engineFormat:32856,roundToMultiple4:!1}}}),this._ktx2DecoderOptions=e,e}},e.s(["_KTXTextureLoader",0,class{constructor(){this.supportCascades=!1}loadCubeData(e,t,r,s){if(Array.isArray(e))return;t._invertVScale=!t.invertY;let o=t.getEngine(),a=new c(e,6),i=m(a.glInternalFormat);null!==i?(t.format=i,t._useSRGBBuffer=o._getUseSRGBBuffer(!0,!t.generateMipMaps),t._gammaSpace=!0):t.format=a.glInternalFormat;let n=a.numberOfMipmapLevels>1&&t.generateMipMaps;o._unpackFlipY(!0),a.uploadLevels(t,t.generateMipMaps),t.width=a.pixelWidth,t.height=a.pixelHeight,o._setCubeMapTextureParams(t,n,a.numberOfMipmapLevels-1),t.isReady=!0,t.onLoadedObservable.notifyObservers(t),t.onLoadedObservable.clear(),s&&s()}loadData(e,t,r,s){if(c.IsValid(e)){t._invertVScale=!t.invertY;let s=new c(e,1),o=m(s.glInternalFormat);null!==o?(t.format=o,t._useSRGBBuffer=t.getEngine()._getUseSRGBBuffer(!0,!t.generateMipMaps),t._gammaSpace=!0):t.format=s.glInternalFormat,r(s.pixelWidth,s.pixelHeight,t.generateMipMaps,!0,()=>{s.uploadLevels(t,t.generateMipMaps)},s.isInvalid)}else R.IsValid(e)?new R(t.getEngine())._uploadAsync(e,t,s).then(()=>{r(t.width,t.height,t.generateMipMaps,!0,()=>{},!1)},e=>{n.Logger.Warn(`Failed to load KTX2 texture data: ${e.message}`),r(0,0,!1,!1,()=>{},!0)}):(n.Logger.Error("texture missing KTX identifier"),r(0,0,!1,!1,()=>{},!0))}}],58046)}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,58703,e=>{"use strict";var t=e.i(44023),o=e.i(5110),u=e.i(77052);class i extends t.FlowGraphExecutionBlockWithOutSignal{constructor(e){super(e),this.sound=this.registerDataInput("sound",o.RichTypeAny),this.volume=this.registerDataInput("volume",o.RichTypeNumber,1)}_execute(e,t){let o=this.sound.getValue(e);if(!o){this._reportError(e,"No sound provided"),this.out._activateSignal(e);return}o.volume=this.volume.getValue(e),this.out._activateSignal(e)}getClassName(){return"FlowGraphSetSoundVolumeBlock"}}let l=!1;function s(){l||(l=!0,(0,u.RegisterClass)("FlowGraphSetSoundVolumeBlock",i))}e.s(["FlowGraphSetSoundVolumeBlock",0,i,"RegisterFlowGraphSetSoundVolumeBlock",0,s],51860),s(),e.s([],8166),e.i(8166),e.i(51860),e.s(["FlowGraphSetSoundVolumeBlock",0,i],58703)}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,883,e=>{"use strict";var t=e.i(10272),s=e.i(37143),r=e.i(72976),i=e.i(70653),a=e.i(46862),n=e.i(58720),o=e.i(23507),l=e.i(80871),u=e.i(44702),h=e.i(89748),_=e.i(31278),T=e.i(92040),c=e.i(12033),d=e.i(97001),p=e.i(35407),m=e.i(44451),g=e.i(18131),f=e.i(33457),R=e.i(13379),A=e.i(80737),E=e.i(37882);function x(e){return class extends e{constructor(){super(...arguments),this.REFLECTION=!1,this.REFLECTIONMAP_3D=!1,this.REFLECTIONMAP_SPHERICAL=!1,this.REFLECTIONMAP_PLANAR=!1,this.REFLECTIONMAP_CUBIC=!1,this.USE_LOCAL_REFLECTIONMAP_CUBIC=!1,this.REFLECTIONMAP_PROJECTION=!1,this.REFLECTIONMAP_SKYBOX=!1,this.REFLECTIONMAP_EXPLICIT=!1,this.REFLECTIONMAP_EQUIRECTANGULAR=!1,this.REFLECTIONMAP_EQUIRECTANGULAR_FIXED=!1,this.REFLECTIONMAP_MIRROREDEQUIRECTANGULAR_FIXED=!1,this.INVERTCUBICMAP=!1,this.USESPHERICALFROMREFLECTIONMAP=!1,this.USEIRRADIANCEMAP=!1,this.USE_IRRADIANCE_DOMINANT_DIRECTION=!1,this.USESPHERICALINVERTEX=!1,this.REFLECTIONMAP_OPPOSITEZ=!1,this.LODINREFLECTIONALPHA=!1,this.GAMMAREFLECTION=!1,this.RGBDREFLECTION=!1}}}var S=e.i(96265),y=e.i(5436),M=e.i(22369),I=e.i(45707),C=e.i(65740),F=e.i(36516);class b extends F.RenderTargetTexture{get isSupported(){return this._engine?.getCaps().drawBuffersExtension??!1}get textures(){return this._textures}get count(){return this._count}get depthTexture(){return this._textures[this._textures.length-1]}set wrapU(e){if(this._textures)for(let t=0;t<this._textures.length;t++)this._textures[t].wrapU=e}set wrapV(e){if(this._textures)for(let t=0;t<this._textures.length;t++)this._textures[t].wrapV=e}constructor(e,t,s,r,i,a){const n=!!i&&!!i.generateMipMaps&&i.generateMipMaps,o=!!i&&!!i.generateDepthTexture&&i.generateDepthTexture,l=i&&i.depthTextureFormat?i.depthTextureFormat:15,u=!i||void 0===i.doNotChangeAspectRatio||i.doNotChangeAspectRatio,h=!!i&&!!i.drawOnlyOnFirstAttachmentByDefault&&i.drawOnlyOnFirstAttachmentByDefault;if(super(e,t,r,n,u,void 0,void 0,void 0,void 0,void 0,void 0,void 0,!0),!this.isSupported)return void this.dispose();this._textureNames=a;const _=[],T=[],c=[],d=[],p=[],m=[],g=[],f=[];this._initTypes(s,_,T,c,d,p,m,g,f,i);const R=!i||void 0===i.generateDepthBuffer||i.generateDepthBuffer,A=!!i&&void 0!==i.generateStencilBuffer&&i.generateStencilBuffer,E=i&&i.samples?i.samples:1;this._multiRenderTargetOptions={samplingModes:T,generateMipMaps:n,generateDepthBuffer:R,generateStencilBuffer:A,generateDepthTexture:o,depthTextureFormat:l,types:_,textureCount:s,useSRGBBuffers:c,samples:E,formats:d,targetTypes:p,faceIndex:m,layerIndex:g,layerCounts:f,labels:a,label:e},this._count=s,this._drawOnlyOnFirstAttachmentByDefault=h,s>0&&(this._createInternalTextures(),this._createTextures(a))}_initTypes(e,t,s,r,i,a,o,l,u,h){for(let _=0;_<e;_++)h&&h.types&&void 0!==h.types[_]?t.push(h.types[_]):t.push(h&&h.defaultType?h.defaultType:0),h&&h.samplingModes&&void 0!==h.samplingModes[_]?s.push(h.samplingModes[_]):s.push(n.Texture.BILINEAR_SAMPLINGMODE),h&&h.useSRGBBuffers&&void 0!==h.useSRGBBuffers[_]?r.push(h.useSRGBBuffers[_]):r.push(!1),h&&h.formats&&void 0!==h.formats[_]?i.push(h.formats[_]):i.push(5),h&&h.targetTypes&&void 0!==h.targetTypes[_]?a.push(h.targetTypes[_]):a.push(3553),h&&h.faceIndex&&void 0!==h.faceIndex[_]?o.push(h.faceIndex[_]):o.push(0),h&&h.layerIndex&&void 0!==h.layerIndex[_]?l.push(h.layerIndex[_]):l.push(0),h&&h.layerCounts&&void 0!==h.layerCounts[_]?u.push(h.layerCounts[_]):u.push(1)}_createInternaTextureIndexMapping(){let e={},t=[];if(!this._renderTarget)return t;let s=this._renderTarget.textures;for(let r=0;r<s.length;r++){let i=s[r];if(!i)continue;let a=e[i.uniqueId];void 0!==a?t[r]=a:e[i.uniqueId]=r}return t}_rebuild(e=!1,t=!1,s){if(this._count<1||e)return;let r=this._createInternaTextureIndexMapping();this.releaseInternalTextures(),this._createInternalTextures(),t&&(this._releaseTextures(),this._createTextures(s));let i=this._renderTarget.textures;for(let e=0;e<i.length;e++){let t=this._textures[e];void 0!==r[e]&&this._renderTarget.setTexture(i[r[e]],e),t._texture=i[e],t._texture&&(t._noMipmap=!t._texture.useMipMaps,t._useSRGBBuffer=t._texture._useSRGBBuffer)}1!==this.samples&&this._renderTarget.setSamples(this.samples,!this._drawOnlyOnFirstAttachmentByDefault,!0)}_createInternalTextures(){this._renderTarget=this._getEngine().createMultipleRenderTarget(this._size,this._multiRenderTargetOptions,!this._drawOnlyOnFirstAttachmentByDefault),this._texture=this._renderTarget.texture}_releaseTextures(){if(this._textures)for(let e=0;e<this._textures.length;e++)this._textures[e]._texture=null,this._textures[e].dispose()}_createTextures(e){let t=this._renderTarget.textures;this._textures=[];for(let s=0;s<t.length;s++){let r=new n.Texture(null,this.getScene());e?.[s]&&(r.name=e[s]),r._texture=t[s],r._texture&&(r._noMipmap=!r._texture.useMipMaps,r._useSRGBBuffer=r._texture._useSRGBBuffer),this._textures.push(r)}}setInternalTexture(e,t,s=!0){if(this.renderTarget&&(0===t&&(this._texture=e),this.renderTarget.setTexture(e,t,s),this.textures[t]||(this.textures[t]=new n.Texture(null,this.getScene()),this.textures[t].name=this._textureNames?.[t]??this.textures[t].name),this.textures[t]._texture=e,this.textures[t]._noMipmap=!e.useMipMaps,this.textures[t]._useSRGBBuffer=e._useSRGBBuffer,this._count=this.renderTarget.textures?this.renderTarget.textures.length:0,this._multiRenderTargetOptions.types&&(this._multiRenderTargetOptions.types[t]=e.type),this._multiRenderTargetOptions.samplingModes&&(this._multiRenderTargetOptions.samplingModes[t]=e.samplingMode),this._multiRenderTargetOptions.useSRGBBuffers&&(this._multiRenderTargetOptions.useSRGBBuffers[t]=e._useSRGBBuffer),this._multiRenderTargetOptions.targetTypes&&-1!==this._multiRenderTargetOptions.targetTypes[t])){let s;s=e.is2DArray?35866:e.isCube?34067:e.is3D?32879:3553,this._multiRenderTargetOptions.targetTypes[t]=s}}setLayerAndFaceIndex(e,t=-1,s=-1){this.textures[e]&&this.renderTarget&&(this._multiRenderTargetOptions.layerIndex&&(this._multiRenderTargetOptions.layerIndex[e]=t),this._multiRenderTargetOptions.faceIndex&&(this._multiRenderTargetOptions.faceIndex[e]=s),this.renderTarget.setLayerAndFaceIndex(e,t,s))}setLayerAndFaceIndices(e,t){this.renderTarget&&(this._multiRenderTargetOptions.layerIndex=e,this._multiRenderTargetOptions.faceIndex=t,this.renderTarget.setLayerAndFaceIndices(e,t))}get samples(){return this._samples}set samples(e){this._renderTarget?this._samples=this._renderTarget.setSamples(e):this._samples=e}resize(e){this._processSizeParameter(e),this._rebuild(!1,void 0,this._textureNames)}updateCount(e,t,s){this._multiRenderTargetOptions.textureCount=e,this._count=e;let r=[],i=[],a=[],n=[],o=[],l=[],u=[],h=[];this._textureNames=s,this._initTypes(e,r,i,a,n,o,l,u,h,t),this._multiRenderTargetOptions.types=r,this._multiRenderTargetOptions.samplingModes=i,this._multiRenderTargetOptions.useSRGBBuffers=a,this._multiRenderTargetOptions.formats=n,this._multiRenderTargetOptions.targetTypes=o,this._multiRenderTargetOptions.faceIndex=l,this._multiRenderTargetOptions.layerIndex=u,this._multiRenderTargetOptions.layerCounts=h,this._multiRenderTargetOptions.labels=s,this._rebuild(!1,!0,s)}_unbindFrameBuffer(e,t){this._renderTarget&&e.unBindMultiColorAttachmentFramebuffer(this._renderTarget,this.isCube,()=>{this.onAfterRenderObservable.notifyObservers(t)})}dispose(e=!1){this._releaseTextures(),e?this._texture=null:this.releaseInternalTextures(),super.dispose()}releaseInternalTextures(){let e=this._renderTarget?.textures;if(e){for(let t=e.length-1;t>=0;t--)this._textures[t]._texture=null;this._renderTarget?.dispose(),this._renderTarget=null}}}var L=e.i(75405),P=e.i(66749),O=e.i(19905);class N{constructor(e){this.name=O.SceneComponentConstants.NAME_GEOMETRYBUFFERRENDERER,this.scene=e}register(){this.scene._gatherRenderTargetsStage.registerStep(O.SceneComponentConstants.STEP_GATHERRENDERTARGETS_GEOMETRYBUFFERRENDERER,this,this._gatherRenderTargets)}rebuild(){}dispose(){}_gatherRenderTargets(e){this.scene._geometryBufferRenderer&&e.push(this.scene._geometryBufferRenderer.getGBuffer())}}let D=!1,v=["diffuseSampler","bumpSampler","reflectivitySampler","albedoSampler","morphTargets","boneSampler","transmissionWeightSampler","subsurfaceWeightSampler","iblShadowSampler"],U=["world","mBones","viewProjection","diffuseMatrix","view","previousWorld","previousViewProjection","mPreviousBones","bumpMatrix","reflectivityMatrix","albedoMatrix","reflectivityColor","albedoColor","reflectionMatrix","vTransmissionWeight","vSubsurfaceWeight","vEyePosition","vTransmissionScatterAnisotropy","vSubsurfaceScatterAnisotropy","shadowTextureSize","metallic","glossiness","vTangentSpaceParams","vBumpInfos","morphTargetInfluences","morphTargetCount","morphTargetTextureInfo","morphTargetTextureIndices","boneTextureInfo"];class B{get normalsAreUnsigned(){return this._normalsAreUnsigned}_linkPrePassRenderer(e){this._linkedWithPrePass=!0,this._prePassRenderer=e,this._multiRenderTarget&&(this._multiRenderTarget.onClearObservable.clear(),this._multiRenderTarget.onClearObservable.add(()=>{}))}_unlinkPrePassRenderer(){this._linkedWithPrePass=!1,this._createRenderTargets()}_resetLayout(){this._enableDepth=!0,this._enableNormal=!0,this._enablePosition=!1,this._enableReflectivity=!1,this._enableVelocity=!1,this._enableVelocityLinear=!1,this._enableScreenspaceDepth=!1,this._enableIrradiance=!1,this._attachmentsFromPrePass=[]}_forceTextureType(e,t){e===B.POSITION_TEXTURE_TYPE?(this._positionIndex=t,this._enablePosition=!0):e===B.VELOCITY_TEXTURE_TYPE?(this._velocityIndex=t,this._enableVelocity=!0):e===B.VELOCITY_LINEAR_TEXTURE_TYPE?(this._velocityLinearIndex=t,this._enableVelocityLinear=!0):e===B.REFLECTIVITY_TEXTURE_TYPE?(this._reflectivityIndex=t,this._enableReflectivity=!0):e===B.DEPTH_TEXTURE_TYPE?(this._depthIndex=t,this._enableDepth=!0):e===B.NORMAL_TEXTURE_TYPE?(this._normalIndex=t,this._enableNormal=!0):e===B.SCREENSPACE_DEPTH_TEXTURE_TYPE?(this._screenspaceDepthIndex=t,this._enableScreenspaceDepth=!0):e===B.IRRADIANCE_TEXTURE_TYPE&&(this._irradianceIndex=t,this._enableIrradiance=!0)}_setAttachments(e){this._attachmentsFromPrePass=e}_linkInternalTexture(e){this._multiRenderTarget.setInternalTexture(e,0,!1)}get renderList(){return this._multiRenderTarget.renderList}set renderList(e){this._multiRenderTarget.renderList=e}get isSupported(){return this._multiRenderTarget.isSupported}getTextureIndex(e){switch(e){case B.POSITION_TEXTURE_TYPE:return this._positionIndex;case B.VELOCITY_TEXTURE_TYPE:return this._velocityIndex;case B.VELOCITY_LINEAR_TEXTURE_TYPE:return this._velocityLinearIndex;case B.REFLECTIVITY_TEXTURE_TYPE:return this._reflectivityIndex;case B.DEPTH_TEXTURE_TYPE:return this._depthIndex;case B.NORMAL_TEXTURE_TYPE:return this._normalIndex;case B.SCREENSPACE_DEPTH_TEXTURE_TYPE:return this._screenspaceDepthIndex;case B.IRRADIANCE_TEXTURE_TYPE:return this._irradianceIndex;default:return -1}}get enableDepth(){return this._enableDepth}set enableDepth(e){this._enableDepth=e,this._linkedWithPrePass||(this.dispose(),this._createRenderTargets())}get enableNormal(){return this._enableNormal}set enableNormal(e){this._enableNormal=e,this._linkedWithPrePass||(this.dispose(),this._createRenderTargets())}get enablePosition(){return this._enablePosition}set enablePosition(e){this._enablePosition=e,this._linkedWithPrePass||(this.dispose(),this._createRenderTargets())}get enableVelocity(){return this._enableVelocity}set enableVelocity(e){this._enableVelocity=e,e||(this._previousTransformationMatrices={}),this._linkedWithPrePass||(this.dispose(),this._createRenderTargets()),this._scene.needsPreviousWorldMatrices=e}get enableVelocityLinear(){return this._enableVelocityLinear}set enableVelocityLinear(e){this._enableVelocityLinear=e,this._linkedWithPrePass||(this.dispose(),this._createRenderTargets())}get enableReflectivity(){return this._enableReflectivity}set enableReflectivity(e){this._enableReflectivity=e,this._linkedWithPrePass||(this.dispose(),this._createRenderTargets())}get enableScreenspaceDepth(){return this._enableScreenspaceDepth}set enableScreenspaceDepth(e){this._enableScreenspaceDepth=e,this._linkedWithPrePass||(this.dispose(),this._createRenderTargets())}get enableIrradiance(){return this._enableIrradiance}set enableIrradiance(e){this._enableIrradiance=e,this._linkedWithPrePass||(this.dispose(),this._createRenderTargets())}get scene(){return this._scene}get ratio(){return"object"==typeof this._ratioOrDimensions?1:this._ratioOrDimensions}get shaderLanguage(){return this._shaderLanguage}constructor(e,t=1,s=15,r){this._previousTransformationMatrices={},this._previousBonesTransformationMatrices={},this.excludedSkinnedMeshesFromVelocity=[],this.renderTransparentMeshes=!0,this.generateNormalsInWorldSpace=!1,this._normalsAreUnsigned=!1,this._resizeObserver=null,this._enableDepth=!0,this._enableNormal=!0,this._enablePosition=!1,this._enableVelocity=!1,this._enableVelocityLinear=!1,this._enableReflectivity=!1,this._enableScreenspaceDepth=!1,this._enableIrradiance=!1,this._clearColor=new i.Color4(0,0,0,0),this._clearDepthColor=new i.Color4(0,0,0,1),this._positionIndex=-1,this._velocityIndex=-1,this._velocityLinearIndex=-1,this._reflectivityIndex=-1,this._depthIndex=-1,this._normalIndex=-1,this._screenspaceDepthIndex=-1,this._irradianceIndex=-1,this._linkedWithPrePass=!1,this.generateIrradianceWithScatterMask=!1,this.useSpecificClearForDepthTexture=!1,this._shaderLanguage=0,this._shadersLoaded=!1,this._scene=e,this._ratioOrDimensions=t,this._useUbo=e.getEngine().supportsUniformBuffers,this._depthFormat=s,this._textureTypesAndFormats=r||{},this._initShaderSourceAsync(),function(e){D||(D=!0,Object.defineProperty(P.Scene.prototype,"geometryBufferRenderer",{get:function(){return this._geometryBufferRenderer},set:function(e){e&&e.isSupported&&(this._geometryBufferRenderer=e)},enumerable:!0,configurable:!0}),P.Scene.prototype.enableGeometryBufferRenderer=function(t=1,s=15,r){return this._geometryBufferRenderer||(this._geometryBufferRenderer=new e(this,t,s,r),this._geometryBufferRenderer.isSupported||(this._geometryBufferRenderer=null)),this._geometryBufferRenderer},P.Scene.prototype.disableGeometryBufferRenderer=function(){this._geometryBufferRenderer&&(this._geometryBufferRenderer.dispose(),this._geometryBufferRenderer=null)},e._SceneComponentInitialization=e=>{let t=e._getComponent(O.SceneComponentConstants.NAME_GEOMETRYBUFFERRENDERER);t||(t=new N(e),e._addComponent(t))})}(B),B._SceneComponentInitialization(this._scene),this._createRenderTargets()}async _initShaderSourceAsync(){this._scene.getEngine().isWebGPU&&!B.ForceGLSL?(this._shaderLanguage=1,await Promise.all([e.A(89527),e.A(2793)])):await Promise.all([e.A(36650),e.A(8047)]),this._shadersLoaded=!0}isReady(e,t){if(!this._shadersLoaded)return!1;let s=e.getMaterial();if(s&&s.disableDepthWrite||"GaussianSplattingMesh"===e.getMesh().getClassName())return!1;let r=[],i=[p.VertexBuffer.PositionKind],a=e.getMesh();a.isVerticesDataPresent(p.VertexBuffer.NormalKind)&&(r.push("#define HAS_NORMAL_ATTRIBUTE"),i.push(p.VertexBuffer.NormalKind));let n=!1,o=!1;if(s){let e=!1;if(s.needAlphaTestingForMesh(a)&&s.getAlphaTestTexture()&&(r.push("#define ALPHATEST"),r.push(`#define ALPHATEST_UV${s.getAlphaTestTexture().coordinatesIndex+1}`),e=!0),(s.bumpTexture||s.normalTexture||s.geometryNormalTexture)&&f.MaterialFlags.BumpTextureEnabled){let t=s.bumpTexture||s.normalTexture||s.geometryNormalTexture;r.push("#define BUMP"),r.push(`#define BUMP_UV${t.coordinatesIndex+1}`),e=!0}if(this._enableReflectivity){let t=!1;"PBRMetallicRoughnessMaterial"===s.getClassName()?(s.metallicRoughnessTexture&&(r.push("#define ORMTEXTURE"),r.push(`#define REFLECTIVITY_UV${s.metallicRoughnessTexture.coordinatesIndex+1}`),r.push("#define METALLICWORKFLOW"),e=!0,t=!0),null!=s.metallic&&(r.push("#define METALLIC"),r.push("#define METALLICWORKFLOW"),t=!0),null!=s.roughness&&(r.push("#define ROUGHNESS"),r.push("#define METALLICWORKFLOW"),t=!0),t&&(s.baseTexture&&(r.push("#define ALBEDOTEXTURE"),r.push(`#define ALBEDO_UV${s.baseTexture.coordinatesIndex+1}`),s.baseTexture.gammaSpace&&r.push("#define GAMMAALBEDO"),e=!0),s.baseColor&&r.push("#define ALBEDOCOLOR"))):"PBRSpecularGlossinessMaterial"===s.getClassName()?(s.specularGlossinessTexture?(r.push("#define SPECULARGLOSSINESSTEXTURE"),r.push(`#define REFLECTIVITY_UV${s.specularGlossinessTexture.coordinatesIndex+1}`),e=!0,s.specularGlossinessTexture.gammaSpace&&r.push("#define GAMMAREFLECTIVITYTEXTURE")):s.specularColor&&r.push("#define REFLECTIVITYCOLOR"),null!=s.glossiness&&r.push("#define GLOSSINESS")):"PBRMaterial"===s.getClassName()?(s.metallicTexture&&(r.push("#define ORMTEXTURE"),r.push(`#define REFLECTIVITY_UV${s.metallicTexture.coordinatesIndex+1}`),r.push("#define METALLICWORKFLOW"),e=!0,t=!0),null!=s.metallic&&(r.push("#define METALLIC"),r.push("#define METALLICWORKFLOW"),t=!0),null!=s.roughness&&(r.push("#define ROUGHNESS"),r.push("#define METALLICWORKFLOW"),t=!0),t?(s.albedoTexture&&(r.push("#define ALBEDOTEXTURE"),r.push(`#define ALBEDO_UV${s.albedoTexture.coordinatesIndex+1}`),s.albedoTexture.gammaSpace&&r.push("#define GAMMAALBEDO"),e=!0),s.albedoColor&&r.push("#define ALBEDOCOLOR")):(s.reflectivityTexture?(r.push("#define SPECULARGLOSSINESSTEXTURE"),r.push(`#define REFLECTIVITY_UV${s.reflectivityTexture.coordinatesIndex+1}`),s.reflectivityTexture.gammaSpace&&r.push("#define GAMMAREFLECTIVITYTEXTURE"),e=!0):s.reflectivityColor&&r.push("#define REFLECTIVITYCOLOR"),null!=s.microSurface&&r.push("#define GLOSSINESS"))):"StandardMaterial"===s.getClassName()?(s.specularTexture&&(r.push("#define REFLECTIVITYTEXTURE"),r.push(`#define REFLECTIVITY_UV${s.specularTexture.coordinatesIndex+1}`),s.specularTexture.gammaSpace&&r.push("#define GAMMAREFLECTIVITYTEXTURE"),e=!0),s.specularColor&&r.push("#define REFLECTIVITYCOLOR")):"OpenPBRMaterial"===s.getClassName()&&(r.push("#define METALLIC"),r.push("#define ROUGHNESS"),s._useRoughnessFromMetallicTextureGreen&&s.baseMetalnessTexture?(r.push("#define ORMTEXTURE"),r.push(`#define REFLECTIVITY_UV${s.baseMetalnessTexture.coordinatesIndex+1}`),e=!0):s.baseMetalnessTexture?(r.push("#define METALLIC_TEXTURE"),r.push(`#define METALLIC_UV${s.baseMetalnessTexture.coordinatesIndex+1}`),e=!0):s.specularRoughnessTexture&&(r.push("#define ROUGHNESS_TEXTURE"),r.push(`#define ROUGHNESS_UV${s.specularRoughnessTexture.coordinatesIndex+1}`),e=!0),s.baseColorTexture&&(r.push("#define ALBEDOTEXTURE"),r.push(`#define ALBEDO_UV${s.baseColorTexture.coordinatesIndex+1}`),s.baseColorTexture.gammaSpace&&r.push("#define GAMMAALBEDO"),e=!0),s.baseColor&&r.push("#define ALBEDOCOLOR"))}this._enableIrradiance&&this.generateIrradianceWithScatterMask&&(r.push("#define IRRADIANCE_SCATTER_MASK"),"OpenPBRMaterial"===s.getClassName()&&(s.subsurfaceWeight>0&&s.subsurfaceWeightTexture&&(r.push("#define SUBSURFACE_WEIGHT"),r.push(`#define SUBSURFACEWEIGHT_UV${s.subsurfaceWeightTexture.coordinatesIndex+1}`),e=!0),s.transmissionWeight>0&&s.transmissionWeightTexture&&(r.push("#define TRANSMISSION_WEIGHT"),r.push(`#define TRANSMISSIONWEIGHT_UV${s.transmissionWeightTexture.coordinatesIndex+1}`),e=!0))),e&&(r.push("#define NEED_UV"),a.isVerticesDataPresent(p.VertexBuffer.UVKind)&&(i.push(p.VertexBuffer.UVKind),r.push("#define UV1"),n=!0),a.isVerticesDataPresent(p.VertexBuffer.UV2Kind)&&(i.push(p.VertexBuffer.UV2Kind),r.push("#define UV2"),o=!0))}if(this._enableDepth&&(r.push("#define DEPTH"),r.push("#define DEPTH_INDEX "+this._depthIndex)),this._enableNormal&&(r.push("#define NORMAL"),r.push("#define NORMAL_INDEX "+this._normalIndex)),this._enablePosition&&(r.push("#define POSITION"),r.push("#define POSITION_INDEX "+this._positionIndex)),this._enableVelocity&&(r.push("#define VELOCITY"),r.push("#define VELOCITY_INDEX "+this._velocityIndex),-1===this.excludedSkinnedMeshesFromVelocity.indexOf(a)&&r.push("#define BONES_VELOCITY_ENABLED")),this._enableVelocityLinear&&(r.push("#define VELOCITY_LINEAR"),r.push("#define VELOCITY_LINEAR_INDEX "+this._velocityLinearIndex),-1===this.excludedSkinnedMeshesFromVelocity.indexOf(a)&&r.push("#define BONES_VELOCITY_ENABLED")),this._enableReflectivity&&(r.push("#define REFLECTIVITY"),r.push("#define REFLECTIVITY_INDEX "+this._reflectivityIndex)),this._enableScreenspaceDepth&&-1!==this._screenspaceDepthIndex&&(r.push("#define SCREENSPACE_DEPTH_INDEX "+this._screenspaceDepthIndex),r.push("#define SCREENSPACE_DEPTH")),this._enableIrradiance&&-1!==this._irradianceIndex){r.push("#define IRRADIANCE_INDEX "+this._irradianceIndex),r.push("#define IRRADIANCE");let e=this._scene;if(e.environmentTexture){let t={},i=!1,a=0;for(let n in("OpenPBRMaterial"===s.getClassName()||"StandardMaterial"===s.getClassName()||"PBRMetallicRoughnessMaterial"===s.getClassName()||"PBRSpecularGlossinessMaterial"===s.getClassName()||"PBRMaterial"===s.getClassName())&&(i=!!s.realtimeFiltering,a=s.realtimeFilteringQuality||0),(0,d.PrepareDefinesForIBL)(e,e.environmentTexture,t,i,a,!0),t)t[n]&&r.push("#define "+n);t.USEIRRADIANCEMAP||r.push("#define SPHERICAL_HARMONICS");let n=e.postProcessRenderPipelineManager.supportedPipelines.find(e=>"IBLShadowsRenderPipeline"===e.getClassName());n&&n._getAccumulatedTexture()&&(r.push("#define IBL_SHADOW_TEXTURE"),n.coloredShadows&&r.push("#define COLORED_IBL_SHADOWS"))}}this.generateNormalsInWorldSpace&&r.push("#define NORMAL_WORLDSPACE"),this._normalsAreUnsigned&&r.push("#define ENCODE_NORMAL"),a.useBones&&a.computeBonesUsingShaders&&a.skeleton?(i.push(p.VertexBuffer.MatricesIndicesKind),i.push(p.VertexBuffer.MatricesWeightsKind),a.numBoneInfluencers>4&&(i.push(p.VertexBuffer.MatricesIndicesExtraKind),i.push(p.VertexBuffer.MatricesWeightsExtraKind)),r.push("#define NUM_BONE_INFLUENCERS "+a.numBoneInfluencers),r.push("#define BONETEXTURE "+a.skeleton.isUsingTextureForMatrices),r.push("#define BonesPerMesh "+(a.skeleton.bones.length+1))):(r.push("#define NUM_BONE_INFLUENCERS 0"),r.push("#define BONETEXTURE false"),r.push("#define BonesPerMesh 0"));let l=a.morphTargetManager?(0,d.PrepareDefinesAndAttributesForMorphTargets)(a.morphTargetManager,r,i,a,!0,!0,!1,n,o,!1):0;t&&(r.push("#define INSTANCES"),(0,d.PushAttributesForInstances)(i,this._enableVelocity||this._enableVelocityLinear),e.getRenderingMesh().hasThinInstances&&r.push("#define THIN_INSTANCES")),this._linkedWithPrePass?r.push("#define SCENE_MRT_COUNT "+this._attachmentsFromPrePass.length):r.push("#define SCENE_MRT_COUNT "+this._multiRenderTarget.textures.length),(0,T.PrepareStringDefinesForClipPlanes)(s,this._scene,r);let u=this._scene.getEngine(),h=e._getDrawWrapper(void 0,!0),_=h.defines,c=r.join("\n");return _!==c&&h.setEffect(u.createEffect("geometry",{attributes:i,uniformsNames:U,samplers:v,defines:c,onCompiled:null,fallbacks:null,onError:null,uniformBuffersNames:["Scene"],indexParameters:{buffersCount:this._multiRenderTarget.textures.length-1,maxSimultaneousMorphTargets:l},shaderLanguage:this.shaderLanguage},u),c),h.effect.isReady()}getGBuffer(){return this._multiRenderTarget}get samples(){return this._multiRenderTarget.samples}set samples(e){this._multiRenderTarget.samples=e}dispose(){this._resizeObserver&&(this._scene.getEngine().onResizeObservable.remove(this._resizeObserver),this._resizeObserver=null),this._multiRenderTarget?.renderTarget&&this.scene.getEngine()._currentRenderTarget===this._multiRenderTarget.renderTarget&&this.scene.getEngine().unBindFramebuffer(this._multiRenderTarget?.renderTarget),this.getGBuffer().dispose()}_assignRenderTargetIndices(){let e=[],t=[],s=0;return this._enableDepth&&(this._depthIndex=s,s++,e.push("gBuffer_Depth"),t.push(this._textureTypesAndFormats[B.DEPTH_TEXTURE_TYPE])),this._enableNormal&&(this._normalIndex=s,s++,e.push("gBuffer_Normal"),t.push(this._textureTypesAndFormats[B.NORMAL_TEXTURE_TYPE])),this._enablePosition&&(this._positionIndex=s,s++,e.push("gBuffer_Position"),t.push(this._textureTypesAndFormats[B.POSITION_TEXTURE_TYPE])),this._enableVelocity&&(this._velocityIndex=s,s++,e.push("gBuffer_Velocity"),t.push(this._textureTypesAndFormats[B.VELOCITY_TEXTURE_TYPE])),this._enableVelocityLinear&&(this._velocityLinearIndex=s,s++,e.push("gBuffer_VelocityLinear"),t.push(this._textureTypesAndFormats[B.VELOCITY_LINEAR_TEXTURE_TYPE])),this._enableReflectivity&&(this._reflectivityIndex=s,s++,e.push("gBuffer_Reflectivity"),t.push(this._textureTypesAndFormats[B.REFLECTIVITY_TEXTURE_TYPE])),this._enableScreenspaceDepth&&(this._screenspaceDepthIndex=s,s++,e.push("gBuffer_ScreenspaceDepth"),t.push(this._textureTypesAndFormats[B.SCREENSPACE_DEPTH_TEXTURE_TYPE])),this._enableIrradiance&&(this._irradianceIndex=s,s++,e.push("gBuffer_Irradiance"),t.push(this._textureTypesAndFormats[B.IRRADIANCE_TEXTURE_TYPE])),[s,e,t]}_createRenderTargets(){let e=this._scene.getEngine(),[t,s,r]=this._assignRenderTargetIndices(),i=0;e._caps.textureFloat&&e._caps.textureFloatLinearFiltering?i=1:e._caps.textureHalfFloat&&e._caps.textureHalfFloatLinearFiltering&&(i=2);let a=void 0!==this._ratioOrDimensions.width?this._ratioOrDimensions:{width:e.getRenderWidth()*this._ratioOrDimensions,height:e.getRenderHeight()*this._ratioOrDimensions},l=[],u=[],h=[];for(let e of r)e?(l.push(e.textureType),u.push(e.textureFormat),h.push(e.samplingMode??2)):(l.push(i),u.push(5),h.push(2));if(this._normalsAreUnsigned=11===l[B.NORMAL_TEXTURE_TYPE]||13===l[B.NORMAL_TEXTURE_TYPE],this._multiRenderTarget=new b("gBuffer",a,t,this._scene,{generateMipMaps:!1,generateDepthTexture:!0,types:l,formats:u,samplingModes:h,depthTextureFormat:this._depthFormat},s.concat("gBuffer_DepthBuffer")),!this.isSupported)return;this._multiRenderTarget.wrapU=n.Texture.CLAMP_ADDRESSMODE,this._multiRenderTarget.wrapV=n.Texture.CLAMP_ADDRESSMODE,this._multiRenderTarget.refreshRate=1,this._multiRenderTarget.renderParticles=!1,this._multiRenderTarget.renderList=null;let _=[!0],c=[!1],p=[!0];for(let e=1;e<t;++e)_.push(!0),p.push(!1),c.push(!0);let m=e.buildTextureLayout(_),g=e.buildTextureLayout(c),R=e.buildTextureLayout(p);this._multiRenderTarget.onClearObservable.add(e=>{e.bindAttachments(this.useSpecificClearForDepthTexture?g:m),e.clear(this._clearColor,!0,!0,!0),this.useSpecificClearForDepthTexture&&(e.bindAttachments(R),e.clear(this._clearDepthColor,!0,!0,!0)),e.bindAttachments(m)}),this._resizeObserver=e.onResizeObservable.add(()=>{if(this._multiRenderTarget){let t=void 0!==this._ratioOrDimensions.width?this._ratioOrDimensions:{width:e.getRenderWidth()*this._ratioOrDimensions,height:e.getRenderHeight()*this._ratioOrDimensions};this._multiRenderTarget.resize(t)}});let A=e=>{let t=e.getRenderingMesh(),s=e.getEffectiveMesh(),r=this._scene,i=r.getEngine(),a=e.getMaterial();if(!a)return;if(s._internalAbstractMeshDataInfo._isActiveIntermediate=!1,(this._enableVelocity||this._enableVelocityLinear)&&!this._previousTransformationMatrices[s.uniqueId]&&(this._previousTransformationMatrices[s.uniqueId]={world:S.Matrix.Identity(),viewProjection:r.getTransformMatrix()},t.skeleton)){let e=t.skeleton.getTransformMatrices(t);this._previousBonesTransformationMatrices[t.uniqueId]=this._copyBonesTransformationMatrices(e,new Float32Array(e.length))}let n=t._getInstancesRenderList(e._id,!!e.getReplacementMesh());if(n.mustReturn)return;let l=i.getCaps().instancedArrays&&(null!==n.visibleInstances[e._id]||t.hasThinInstances),u=s.getWorldMatrix();if(this.isReady(e,l)){let h,_=e._getDrawWrapper();if(!_)return;let c=_.effect;if(i.enableEffect(_),l||t._bind(e,c,a.fillMode),this._useUbo?((0,d.BindSceneUniformBuffer)(c,this._scene.getSceneUniformBuffer()),this._scene.finalizeSceneUbo()):(c.setMatrix("viewProjection",r.getTransformMatrix()),c.setMatrix("view",r.getViewMatrix()),this._scene.bindEyePosition(c,"vEyePosition")),!t._instanceDataStorage.isFrozen&&(a.backFaceCulling||null!==a.sideOrientation)){let e=s._getWorldMatrixDeterminant();h=a._getEffectiveOrientation(t),e<0&&(h=h===o.Material.ClockWiseSideOrientation?o.Material.CounterClockWiseSideOrientation:o.Material.ClockWiseSideOrientation)}else h=t._effectiveSideOrientation;if(a._preBind(_,h),a.needAlphaTestingForMesh(s)){let e=a.getAlphaTestTexture();e&&(c.setTexture("diffuseSampler",e),c.setMatrix("diffuseMatrix",e.getTextureMatrix()))}if((a.bumpTexture||a.normalTexture||a.geometryNormalTexture)&&r.getEngine().getCaps().standardDerivatives&&f.MaterialFlags.BumpTextureEnabled){let e=a.bumpTexture||a.normalTexture||a.geometryNormalTexture;c.setFloat3("vBumpInfos",e.coordinatesIndex,1/e.level,a.parallaxScaleBias),c.setMatrix("bumpMatrix",e.getTextureMatrix()),c.setTexture("bumpSampler",e),c.setFloat2("vTangentSpaceParams",a.invertNormalMapX?-1:1,a.invertNormalMapY?-1:1)}if(this._enableReflectivity&&("PBRMetallicRoughnessMaterial"===a.getClassName()?(null!==a.metallicRoughnessTexture&&(c.setTexture("reflectivitySampler",a.metallicRoughnessTexture),c.setMatrix("reflectivityMatrix",a.metallicRoughnessTexture.getTextureMatrix())),null!==a.metallic&&c.setFloat("metallic",a.metallic),null!==a.roughness&&c.setFloat("glossiness",1-a.roughness),null!==a.baseTexture&&(c.setTexture("albedoSampler",a.baseTexture),c.setMatrix("albedoMatrix",a.baseTexture.getTextureMatrix())),null!==a.baseColor&&c.setColor3("albedoColor",a.baseColor)):"PBRSpecularGlossinessMaterial"===a.getClassName()?(null!==a.specularGlossinessTexture?(c.setTexture("reflectivitySampler",a.specularGlossinessTexture),c.setMatrix("reflectivityMatrix",a.specularGlossinessTexture.getTextureMatrix())):null!==a.specularColor&&c.setColor3("reflectivityColor",a.specularColor),null!==a.glossiness&&c.setFloat("glossiness",a.glossiness)):"PBRMaterial"===a.getClassName()?(null!==a.metallicTexture&&(c.setTexture("reflectivitySampler",a.metallicTexture),c.setMatrix("reflectivityMatrix",a.metallicTexture.getTextureMatrix())),null!==a.metallic&&c.setFloat("metallic",a.metallic),null!==a.roughness&&c.setFloat("glossiness",1-a.roughness),null!==a.roughness||null!==a.metallic||null!==a.metallicTexture?(null!==a.albedoTexture&&(c.setTexture("albedoSampler",a.albedoTexture),c.setMatrix("albedoMatrix",a.albedoTexture.getTextureMatrix())),null!==a.albedoColor&&c.setColor3("albedoColor",a.albedoColor)):(null!==a.reflectivityTexture?(c.setTexture("reflectivitySampler",a.reflectivityTexture),c.setMatrix("reflectivityMatrix",a.reflectivityTexture.getTextureMatrix())):null!==a.reflectivityColor&&c.setColor3("reflectivityColor",a.reflectivityColor),null!==a.microSurface&&c.setFloat("glossiness",a.microSurface))):"StandardMaterial"===a.getClassName()?(null!==a.specularTexture&&(c.setTexture("reflectivitySampler",a.specularTexture),c.setMatrix("reflectivityMatrix",a.specularTexture.getTextureMatrix())),null!==a.specularColor&&c.setColor3("reflectivityColor",a.specularColor)):"OpenPBRMaterial"===a.getClassName()&&(a._useRoughnessFromMetallicTextureGreen&&a.baseMetalnessTexture?(c.setTexture("reflectivitySampler",a.baseMetalnessTexture),c.setMatrix("reflectivityMatrix",a.baseMetalnessTexture.getTextureMatrix())):a.baseMetalnessTexture?(c.setTexture("metallicSampler",a.baseMetalnessTexture),c.setMatrix("metallicMatrix",a.baseMetalnessTexture.getTextureMatrix())):a.specularRoughnessTexture&&(c.setTexture("roughnessSampler",a.specularRoughnessTexture),c.setMatrix("roughnessMatrix",a.specularRoughnessTexture.getTextureMatrix())),c.setFloat("metallic",a.baseMetalness),c.setFloat("glossiness",1-a.specularRoughness),null!==a.baseColorTexture&&(c.setTexture("albedoSampler",a.baseColorTexture),c.setMatrix("albedoMatrix",a.baseColorTexture.getTextureMatrix())),null!==a.baseColor&&c.setColor3("albedoColor",a.baseColor))),this._enableIrradiance&&r.environmentTexture){let e=r.environmentTexture,t=r.postProcessRenderPipelineManager.supportedPipelines.find(e=>"IBLShadowsRenderPipeline"===e.getClassName());if(t){let e=t._getAccumulatedTexture();e&&(c.setTexture("iblShadowSampler",e),c.setFloat2("shadowTextureSize",e.getSize().width,e.getSize().height))}if(c.setMatrix("reflectionMatrix",e.getReflectionTextureMatrix()),c.setFloat2("vReflectionInfos",e.level*r.iblIntensity,0),c.setTexture("reflectionSampler",e),e.irradianceTexture&&(c.setTexture("irradianceSampler",e.irradianceTexture),e.irradianceTexture._dominantDirection&&c.setVector3("vReflectionDominantDirection",e.irradianceTexture._dominantDirection)),e.sphericalPolynomial){let t=e.sphericalPolynomial;if(t.preScaledHarmonics){let e=t.preScaledHarmonics;c.setVector3("vSphericalL00",e.l00),c.setVector3("vSphericalL1_1",e.l1_1),c.setVector3("vSphericalL10",e.l10),c.setVector3("vSphericalL11",e.l11),c.setVector3("vSphericalL2_2",e.l2_2),c.setVector3("vSphericalL2_1",e.l2_1),c.setVector3("vSphericalL20",e.l20),c.setVector3("vSphericalL21",e.l21),c.setVector3("vSphericalL22",e.l22)}else c.setFloat3("vSphericalX",t.x.x,t.x.y,t.x.z),c.setFloat3("vSphericalY",t.y.x,t.y.y,t.y.z),c.setFloat3("vSphericalZ",t.z.x,t.z.y,t.z.z),c.setFloat3("vSphericalXX_ZZ",t.xx.x-t.zz.x,t.xx.y-t.zz.y,t.xx.z-t.zz.z),c.setFloat3("vSphericalYY_ZZ",t.yy.x-t.zz.x,t.yy.y-t.zz.y,t.yy.z-t.zz.z),c.setFloat3("vSphericalZZ",t.zz.x,t.zz.y,t.zz.z),c.setFloat3("vSphericalXY",t.xy.x,t.xy.y,t.xy.z),c.setFloat3("vSphericalYZ",t.yz.x,t.yz.y,t.yz.z),c.setFloat3("vSphericalZX",t.zx.x,t.zx.y,t.zx.z)}this.generateIrradianceWithScatterMask&&"OpenPBRMaterial"===a.getClassName()&&(c.setFloat("vSubsurfaceWeight",a.subsurfaceWeight),a.subsurfaceWeightTexture&&(c.setTexture("subsurfaceWeightSampler",a.subsurfaceWeightTexture),c.setMatrix("subsurfaceWeightMatrix",a.subsurfaceWeightTexture.getTextureMatrix())),c.setFloat("vTransmissionWeight",a.transmissionWeight),a.transmissionWeightTexture&&(c.setTexture("transmissionWeightSampler",a.transmissionWeightTexture),c.setMatrix("transmissionWeightMatrix",a.transmissionWeightTexture.getTextureMatrix())),c.setFloat("vTransmissionScatterAnisotropy",a.transmissionScatterAnisotropy),c.setFloat("vSubsurfaceScatterAnisotropy",a.subsurfaceScatterAnisotropy))}if((0,T.BindClipPlane)(c,a,this._scene),t.useBones&&t.computeBonesUsingShaders&&t.skeleton){let e=t.skeleton;if(e.isUsingTextureForMatrices&&c.getUniformIndex("boneTextureInfo")>-1){let s=e.getTransformMatrixTexture(t);c.setTexture("boneSampler",s),c.setFloat2("boneTextureInfo",e._textureWidth,e._textureHeight)}else c.setMatrices("mBones",t.skeleton.getTransformMatrices(t));(this._enableVelocity||this._enableVelocityLinear)&&c.setMatrices("mPreviousBones",this._previousBonesTransformationMatrices[t.uniqueId])}(0,d.BindMorphTargetParameters)(t,c),t.morphTargetManager&&t.morphTargetManager.isUsingTextureForTargets&&t.morphTargetManager._bind(c),(this._enableVelocity||this._enableVelocityLinear)&&(c.setMatrix("previousWorld",this._previousTransformationMatrices[s.uniqueId].world),c.setMatrix("previousViewProjection",this._previousTransformationMatrices[s.uniqueId].viewProjection)),l&&t.hasThinInstances&&c.setMatrix("world",u),t._processRendering(s,e,c,a.fillMode,n,l,(e,t)=>{e||c.setMatrix("world",t)})}(this._enableVelocity||this._enableVelocityLinear)&&(this._previousTransformationMatrices[s.uniqueId].world=u.clone(),this._previousTransformationMatrices[s.uniqueId].viewProjection=this._scene.getTransformMatrix().clone(),t.skeleton&&this._copyBonesTransformationMatrices(t.skeleton.getTransformMatrices(t),this._previousBonesTransformationMatrices[s.uniqueId]))};this._multiRenderTarget.customIsReadyFunction=(t,s,r)=>{if((r||0===s)&&t.subMeshes)for(let s=0;s<t.subMeshes.length;++s){let r=t.subMeshes[s],i=r.getMaterial(),a=r.getRenderingMesh();if(!i)continue;let n=a._getInstancesRenderList(r._id,!!r.getReplacementMesh()),o=e.getCaps().instancedArrays&&(null!==n.visibleInstances[r._id]||a.hasThinInstances);if(!this.isReady(r,o))return!1}return!0},this._multiRenderTarget.customRenderFunction=(t,s,r,i)=>{let a;if(this._linkedWithPrePass){if(!this._prePassRenderer.enabled)return;this._scene.getEngine().bindAttachments(this._attachmentsFromPrePass)}if(i.length){for(e.setColorWrite(!1),a=0;a<i.length;a++)A(i.data[a]);e.setColorWrite(!0)}for(a=0;a<t.length;a++)A(t.data[a]);for(e.setDepthWrite(!1),a=0;a<s.length;a++)A(s.data[a]);if(this.renderTransparentMeshes)for(a=0;a<r.length;a++)A(r.data[a]);e.setDepthWrite(!0)}}_copyBonesTransformationMatrices(e,t){for(let s=0;s<e.length;s++)t[s]=e[s];return t}}B.ForceGLSL=!1,B.DEPTH_TEXTURE_TYPE=0,B.NORMAL_TEXTURE_TYPE=1,B.POSITION_TEXTURE_TYPE=2,B.VELOCITY_TEXTURE_TYPE=3,B.REFLECTIVITY_TEXTURE_TYPE=4,B.SCREENSPACE_DEPTH_TEXTURE_TYPE=5,B.VELOCITY_LINEAR_TEXTURE_TYPE=6,B.IRRADIANCE_TEXTURE_TYPE=7,B._SceneComponentInitialization=e=>{throw(0,L._WarnImport)("GeometryBufferRendererSceneComponent")};var k=e.i(77052);let G={effect:null,subMesh:null};function V(e){if("number"==typeof e)return 1;if(e instanceof S.Vector2)return 2;if(e instanceof S.Vector3||e instanceof i.Color3)return 3;if(e instanceof S.Vector4||e instanceof i.Color4)return 4;throw Error("Unsupported OpenPBR property type.")}class z{populateVectorFromLinkedProperties(e){let t=V(e);for(let e in this.linkedProperties){let s=this.linkedProperties[e],r=s.numComponents;if(t<r||s.targetUniformComponentOffset>t-r)return void(1==r?R.Logger.Error(`Float property ${s.name} has an offset that is too large.`):R.Logger.Error(`Vector${r} property ${s.name} won't fit in Vector${t} or has an offset that is too large.`));"number"==typeof s.value?z._tmpArray[s.targetUniformComponentOffset]=s.value:s.value.toArray(z._tmpArray,s.targetUniformComponentOffset)}e.fromArray(z._tmpArray)}constructor(e,t){this.linkedProperties={},this.firstLinkedKey="",this.name=e,this.numComponents=t}}z._tmpArray=[0,0,0,0];class H{constructor(e,t,s,r,i=0,a){this.targetUniformComponentNum=4,this.targetUniformComponentOffset=0,this.name=e,this.targetUniformName=s,this.defaultValue=t,this.value=t,this.targetUniformComponentNum=r,this.targetUniformComponentOffset=i,this.requiredDefine=a}get numComponents(){return"number"==typeof this.defaultValue?1:V(this.defaultValue)}}class W{get samplerName(){return this.samplerPrefix+"Sampler"}get samplerInfoName(){return"v"+this.samplerPrefix.charAt(0).toUpperCase()+this.samplerPrefix.slice(1)+"Infos"}get samplerMatrixName(){return this.samplerPrefix+"Matrix"}constructor(e,t,s){this.value=null,this.samplerPrefix="",this.textureDefine="",this.name=e,this.samplerPrefix=t,this.textureDefine=s}}class w extends(0,E.PrepassDefinesMixin)((0,A.UVDefinesMixin)(u.MaterialDefines)){}class X extends x(w){}class Y extends(0,h.ImageProcessingDefinesMixin)(X){constructor(e){super(e),this.NUM_SAMPLES="0",this.REALTIME_FILTERING=!1,this.IBL_CDF_FILTERING=!1,this.LIGHTCOUNT=0,this.VERTEXCOLOR=!1,this.BAKED_VERTEX_ANIMATION_TEXTURE=!1,this.VERTEXALPHA=!1,this.ALPHATEST=!1,this.DEPTHPREPASS=!1,this.ALPHABLEND=!1,this.ALPHA_FROM_BASE_COLOR_TEXTURE=!1,this.ALPHATESTVALUE="0.5",this.PREMULTIPLYALPHA=!1,this.REFLECTIVITY_GAMMA=!1,this.REFLECTIVITYDIRECTUV=0,this.SPECULARTERM=!1,this.LODBASEDMICROSFURACE=!0,this.SPECULAR_ROUGHNESS_FROM_METALNESS_TEXTURE_GREEN=!1,this.BASE_METALNESS_FROM_METALNESS_TEXTURE_BLUE=!1,this.AOSTOREINMETALMAPRED=!1,this.SPECULAR_WEIGHT_IN_ALPHA=!1,this.SPECULAR_WEIGHT_FROM_SPECULAR_COLOR_TEXTURE=!1,this.SPECULAR_ROUGHNESS_ANISOTROPY_FROM_TANGENT_TEXTURE=!1,this.COAT_ROUGHNESS_FROM_GREEN_CHANNEL=!1,this.COAT_ROUGHNESS_ANISOTROPY_FROM_TANGENT_TEXTURE=!1,this.USE_GLTF_STYLE_ANISOTROPY=!1,this.THIN_FILM_THICKNESS_FROM_THIN_FILM_TEXTURE=!1,this.FUZZ_ROUGHNESS_FROM_TEXTURE_ALPHA=!1,this.SUBSURFACE_WEIGHT_FROM_TEXTURE_ALPHA=!1,this.GEOMETRY_THICKNESS_FROM_GREEN_CHANNEL=!1,this.ENVIRONMENTBRDF=!1,this.ENVIRONMENTBRDF_RGBD=!1,this.FUZZENVIRONMENTBRDF=!1,this.NORMAL=!1,this.TANGENT=!1,this.OBJECTSPACE_NORMALMAP=!1,this.PARALLAX=!1,this.PARALLAX_RHS=!1,this.PARALLAXOCCLUSION=!1,this.NORMALXYSCALE=!0,this.ANISOTROPIC=!1,this.ANISOTROPIC_OPENPBR=!0,this.ANISOTROPIC_BASE=!1,this.ANISOTROPIC_COAT=!1,this.FUZZ_IBL_SAMPLES=6,this.REFRACTION_HIGH_QUALITY_BLUR=!1,this.FUZZ=!1,this.THIN_FILM=!1,this.IRIDESCENCE=!1,this.DISPERSION=!1,this.SCATTERING=!1,this.USE_IRRADIANCE_TEXTURE_FOR_SCATTERING=!1,this.SSS_SAMPLE_COUNT=16,this.USE_IRRADIANCE_TEXTURE_FOR_SCATTERING_GBUFFER=!1,this.TRANSMISSION_SLAB=!1,this.TRANSMISSION_SLAB_VOLUME=!1,this.SUBSURFACE_SLAB=!1,this.GEOMETRY_THIN_WALLED=!1,this.REFRACTED_BACKGROUND=!1,this.REFRACTED_LIGHTS=!1,this.REFRACTED_ENVIRONMENT=!1,this.REFRACTED_ENVIRONMENT_OPPOSITEZ=!1,this.REFRACTED_ENVIRONMENT_LOCAL_CUBE=!1,this.RADIANCEOCCLUSION=!1,this.HORIZONOCCLUSION=!1,this.INSTANCES=!1,this.THIN_INSTANCES=!1,this.INSTANCESCOLOR=!1,this.NUM_BONE_INFLUENCERS=0,this.BonesPerMesh=0,this.BONETEXTURE=!1,this.BONES_VELOCITY_ENABLED=!1,this.NONUNIFORMSCALING=!1,this.MORPHTARGETS=!1,this.MORPHTARGETS_POSITION=!1,this.MORPHTARGETS_NORMAL=!1,this.MORPHTARGETS_TANGENT=!1,this.MORPHTARGETS_UV=!1,this.MORPHTARGETS_UV2=!1,this.MORPHTARGETS_COLOR=!1,this.MORPHTARGETTEXTURE_HASPOSITIONS=!1,this.MORPHTARGETTEXTURE_HASNORMALS=!1,this.MORPHTARGETTEXTURE_HASTANGENTS=!1,this.MORPHTARGETTEXTURE_HASUVS=!1,this.MORPHTARGETTEXTURE_HASUV2S=!1,this.MORPHTARGETTEXTURE_HASCOLORS=!1,this.NUM_MORPH_INFLUENCERS=0,this.MORPHTARGETS_TEXTURE=!1,this.USEPHYSICALLIGHTFALLOFF=!1,this.USEGLTFLIGHTFALLOFF=!1,this.TWOSIDEDLIGHTING=!1,this.MIRRORED=!1,this.SHADOWFLOAT=!1,this.CLIPPLANE=!1,this.CLIPPLANE2=!1,this.CLIPPLANE3=!1,this.CLIPPLANE4=!1,this.CLIPPLANE5=!1,this.CLIPPLANE6=!1,this.POINTSIZE=!1,this.FOG=!1,this.LOGARITHMICDEPTH=!1,this.CAMERA_ORTHOGRAPHIC=!1,this.CAMERA_PERSPECTIVE=!1,this.AREALIGHTSUPPORTED=!0,this.FORCENORMALFORWARD=!1,this.SPECULARAA=!1,this.UNLIT=!1,this.DECAL_AFTER_DETAIL=!1,this.TEXTURE_REPETITION_MODE=0,this.DEBUGMODE=0,this.USE_VERTEX_PULLING=!1,this.VERTEX_PULLING_USE_INDEX_BUFFER=!1,this.VERTEX_PULLING_INDEX_BUFFER_32BITS=!1,this.RIGHT_HANDED=!1,this.CLUSTLIGHT_SLICES=0,this.CLUSTLIGHT_BATCH=0,this.BRDF_V_HEIGHT_CORRELATED=!0,this.MS_BRDF_ENERGY_CONSERVATION=!0,this.SPHERICAL_HARMONICS=!0,this.SPECULAR_GLOSSINESS_ENERGY_CONSERVATION=!0,this.MIX_IBL_RADIANCE_WITH_IRRADIANCE=!0,this.LEGACY_SPECULAR_ENERGY_CONSERVATION=!1,this.BASE_DIFFUSE_MODEL=0,this.DIELECTRIC_SPECULAR_MODEL=1,this.CONDUCTOR_SPECULAR_MODEL=1,this.rebuild()}reset(){super.reset(),this.ALPHATESTVALUE="0.5",this.NORMALXYSCALE=!0}}class Z extends(0,y.ImageProcessingMixin)(M.PushMaterial){}class K extends Z{get geometryTangentAngle(){return Math.atan2(this.geometryTangent.y,this.geometryTangent.x)}set geometryTangentAngle(e){this.geometryTangent=new S.Vector2(Math.cos(e),Math.sin(e))}get geometryCoatTangentAngle(){return Math.atan2(this.geometryCoatTangent.y,this.geometryCoatTangent.x)}set geometryCoatTangentAngle(e){this.geometryCoatTangent=new S.Vector2(Math.cos(e),Math.sin(e))}get sssQuality(){return this._sssQuality}set sssQuality(e){this._sssQuality!==e&&(this._sssQuality=e,this.markAsDirty(1))}get sssIrradianceTexture(){return this._sssIrradianceTexture}set sssIrradianceTexture(e){this._sssIrradianceTexture!==e&&(this._sssIrradianceTexture=e,this._markAllSubMeshesAsTexturesDirty())}get sssDepthTexture(){return this._sssDepthTexture}set sssDepthTexture(e){this._sssDepthTexture!==e&&(this._sssDepthTexture=e,this._markAllSubMeshesAsTexturesDirty())}get hasTransparency(){return this.subsurfaceWeight>0||this.transmissionWeight>0}get hasScattering(){return this.transmissionWeight>0&&this.transmissionDepth>0&&!this.transmissionScatter.equals(i.Color3.BlackReadOnly)||this.subsurfaceWeight>0}get usePhysicalLightFalloff(){return this._lightFalloff===o.Material.LIGHTFALLOFF_PHYSICAL}set usePhysicalLightFalloff(e){e!==this.usePhysicalLightFalloff&&(this._markAllSubMeshesAsTexturesDirty(),e?this._lightFalloff=o.Material.LIGHTFALLOFF_PHYSICAL:this._lightFalloff=o.Material.LIGHTFALLOFF_STANDARD)}get useGLTFLightFalloff(){return this._lightFalloff===o.Material.LIGHTFALLOFF_GLTF}set useGLTFLightFalloff(e){e!==this.useGLTFLightFalloff&&(this._markAllSubMeshesAsTexturesDirty(),e?this._lightFalloff=o.Material.LIGHTFALLOFF_GLTF:this._lightFalloff=o.Material.LIGHTFALLOFF_STANDARD)}get backgroundRefractionTexture(){return this._backgroundRefractionTexture}set backgroundRefractionTexture(e){this._backgroundRefractionTexture=e,this._markAllSubMeshesAsTexturesDirty()}get refractionHighQualityBlur(){return this._refractionHighQualityBlur}set refractionHighQualityBlur(e){this._refractionHighQualityBlur!==e&&(this._refractionHighQualityBlur=e,this.markAsDirty(1))}get realTimeFiltering(){return this._realTimeFiltering}set realTimeFiltering(e){this._realTimeFiltering=e,this.markAsDirty(1)}get realTimeFilteringQuality(){return this._realTimeFilteringQuality}set realTimeFilteringQuality(e){this._realTimeFilteringQuality=e,this.markAsDirty(1)}get fuzzSampleNumber(){return this._fuzzSampleNumber}set fuzzSampleNumber(e){this._fuzzSampleNumber=e,this.markAsDirty(1)}get canRenderToMRT(){return!0}constructor(e,t,s=!1){for(const a of(super(e,t,void 0,s||K.ForceGLSL),this._baseWeight=new H("base_weight",1,"vBaseWeight",1),this._baseWeightTexture=new W("base_weight","baseWeight","BASE_WEIGHT"),this._baseColor=new H("base_color",i.Color3.White(),"vBaseColor",4),this._baseColorTexture=new W("base_color","baseColor","BASE_COLOR"),this._baseDiffuseRoughness=new H("base_diffuse_roughness",0,"vBaseDiffuseRoughness",1),this._baseDiffuseRoughnessTexture=new W("base_diffuse_roughness","baseDiffuseRoughness","BASE_DIFFUSE_ROUGHNESS"),this._baseMetalness=new H("base_metalness",0,"vReflectanceInfo",4,0),this._baseMetalnessTexture=new W("base_metalness","baseMetalness","BASE_METALNESS"),this._specularWeight=new H("specular_weight",1,"vReflectanceInfo",4,3),this._specularWeightTexture=new W("specular_weight","specularWeight","SPECULAR_WEIGHT"),this._specularColor=new H("specular_color",i.Color3.White(),"vSpecularColor",4),this._specularColorTexture=new W("specular_color","specularColor","SPECULAR_COLOR"),this._specularRoughness=new H("specular_roughness",.3,"vReflectanceInfo",4,1),this._specularRoughnessTexture=new W("specular_roughness","specularRoughness","SPECULAR_ROUGHNESS"),this._specularRoughnessAnisotropy=new H("specular_roughness_anisotropy",0,"vSpecularAnisotropy",3,2),this._specularRoughnessAnisotropyTexture=new W("specular_roughness_anisotropy","specularRoughnessAnisotropy","SPECULAR_ROUGHNESS_ANISOTROPY"),this._specularIor=new H("specular_ior",1.5,"vReflectanceInfo",4,2),this._transmissionWeight=new H("transmission_weight",0,"vTransmissionWeight",1),this._transmissionWeightTexture=new W("transmission_weight","transmissionWeight","TRANSMISSION_WEIGHT"),this._transmissionColor=new H("transmission_color",i.Color3.White(),"vTransmissionColor",3,0),this._transmissionColorTexture=new W("transmission_color","transmissionColor","TRANSMISSION_COLOR"),this._transmissionDepth=new H("transmission_depth",0,"vTransmissionDepth",1,0),this._transmissionDepthTexture=new W("transmission_depth","transmissionDepth","TRANSMISSION_DEPTH"),this._transmissionScatter=new H("transmission_scatter",i.Color3.Black(),"vTransmissionScatter",3,0),this._transmissionScatterTexture=new W("transmission_scatter","transmissionScatter","TRANSMISSION_SCATTER"),this._transmissionScatterAnisotropy=new H("transmission_scatter_anisotropy",0,"vTransmissionScatterAnisotropy",1,0),this._transmissionDispersionScale=new H("transmission_dispersion_scale",0,"vTransmissionDispersionScale",1,0),this._transmissionDispersionScaleTexture=new W("transmission_dispersion_scale","transmissionDispersionScale","TRANSMISSION_DISPERSION_SCALE"),this._transmissionDispersionAbbeNumber=new H("transmission_dispersion_abbe_number",20,"vTransmissionDispersionAbbeNumber",1,0),this._subsurfaceWeight=new H("subsurface_weight",0,"vSubsurfaceWeight",1,0,"SUBSURFACE_SLAB"),this._subsurfaceWeightTexture=new W("subsurface_weight","subsurfaceWeight","SUBSURFACE_WEIGHT"),this._subsurfaceColor=new H("subsurface_color",new i.Color3(.8,.8,.8),"vSubsurfaceColor",3,0,"SUBSURFACE_SLAB"),this._subsurfaceColorTexture=new W("subsurface_color","subsurfaceColor","SUBSURFACE_COLOR"),this._subsurfaceRadius=new H("subsurface_radius",.1,"vSubsurfaceRadius",1,0,"SUBSURFACE_SLAB"),this._subsurfaceRadiusScale=new H("subsurface_radius_scale",new i.Color3(1,.5,.25),"vSubsurfaceRadiusScale",3,0,"SUBSURFACE_SLAB"),this._subsurfaceRadiusScaleTexture=new W("subsurface_radius_scale","subsurfaceRadiusScale","SUBSURFACE_RADIUS_SCALE"),this._subsurfaceScatterAnisotropy=new H("subsurface_scatter_anisotropy",0,"vSubsurfaceScatterAnisotropy",1,0,"SUBSURFACE_SLAB"),this._coatWeight=new H("coat_weight",0,"vCoatWeight",1,0),this._coatWeightTexture=new W("coat_weight","coatWeight","COAT_WEIGHT"),this._coatColor=new H("coat_color",i.Color3.White(),"vCoatColor",3,0),this._coatColorTexture=new W("coat_color","coatColor","COAT_COLOR"),this._coatRoughness=new H("coat_roughness",0,"vCoatRoughness",1,0),this._coatRoughnessTexture=new W("coat_roughness","coatRoughness","COAT_ROUGHNESS"),this._coatRoughnessAnisotropy=new H("coat_roughness_anisotropy",0,"vCoatRoughnessAnisotropy",1),this._coatRoughnessAnisotropyTexture=new W("coat_roughness_anisotropy","coatRoughnessAnisotropy","COAT_ROUGHNESS_ANISOTROPY"),this._coatIor=new H("coat_ior",1.5,"vCoatIor",1,0),this._coatDarkening=new H("coat_darkening",1,"vCoatDarkening",1,0),this._coatDarkeningTexture=new W("coat_darkening","coatDarkening","COAT_DARKENING"),this.useCoatRoughnessFromWeightTexture=!1,this._fuzzWeight=new H("fuzz_weight",0,"vFuzzWeight",1,0),this._fuzzWeightTexture=new W("fuzz_weight","fuzzWeight","FUZZ_WEIGHT"),this._fuzzColor=new H("fuzz_color",i.Color3.White(),"vFuzzColor",3,0),this._fuzzColorTexture=new W("fuzz_color","fuzzColor","FUZZ_COLOR"),this._fuzzRoughness=new H("fuzz_roughness",.5,"vFuzzRoughness",1,0),this._fuzzRoughnessTexture=new W("fuzz_roughness","fuzzRoughness","FUZZ_ROUGHNESS"),this._geometryThinWalled=new H("geometry_thin_walled",0,"vGeometryThinWalled",1,0),this._geometryNormalTexture=new W("geometry_normal","geometryNormal","GEOMETRY_NORMAL"),this._geometryTangent=new H("geometry_tangent",new S.Vector2(1,0),"vSpecularAnisotropy",3,0),this._geometryTangentTexture=new W("geometry_tangent","geometryTangent","GEOMETRY_TANGENT"),this._geometryCoatNormalTexture=new W("geometry_coat_normal","geometryCoatNormal","GEOMETRY_COAT_NORMAL"),this._geometryCoatTangent=new H("geometry_coat_tangent",new S.Vector2(1,0),"vGeometryCoatTangent",2,0),this._geometryCoatTangentTexture=new W("geometry_coat_tangent","geometryCoatTangent","GEOMETRY_COAT_TANGENT"),this._geometryOpacity=new H("geometry_opacity",1,"vBaseColor",4,3),this._geometryOpacityTexture=new W("geometry_opacity","geometryOpacity","GEOMETRY_OPACITY"),this._geometryThickness=new H("geometry_thickness",0,"vGeometryThickness",1,0),this._geometryThicknessTexture=new W("geometry_thickness","geometryThickness","GEOMETRY_THICKNESS"),this._emissionLuminance=new H("emission_luminance",1,"vLightingIntensity",4,1),this._emissionColor=new H("emission_color",i.Color3.Black(),"vEmissionColor",3),this._emissionColorTexture=new W("emission_color","emissionColor","EMISSION_COLOR"),this._thinFilmWeight=new H("thin_film_weight",0,"vThinFilmWeight",1,0),this._thinFilmWeightTexture=new W("thin_film_weight","thinFilmWeight","THIN_FILM_WEIGHT"),this._thinFilmThickness=new H("thin_film_thickness",.5,"vThinFilmThickness",2,0),this._thinFilmThicknessMin=new H("thin_film_thickness_min",0,"vThinFilmThickness",2,1),this._thinFilmThicknessTexture=new W("thin_film_thickness","thinFilmThickness","THIN_FILM_THICKNESS"),this._thinFilmIor=new H("thin_film_ior",1.4,"vThinFilmIor",1,0),this._ambientOcclusionTexture=new W("ambient_occlusion","ambientOcclusion","AMBIENT_OCCLUSION"),this._sssQuality=K.SSS_QUALITY_MEDIUM,this._sssIrradianceTexture=null,this._sssDepthTexture=null,this._uniformsList={},this._uniformsArray=[],this._samplersList={},this._samplerDefines={},this.directIntensity=1,this.environmentIntensity=1,this.useSpecularWeightFromTextureAlpha=!1,this.forceAlphaTest=!1,this.alphaCutOff=.4,this.useAmbientOcclusionFromMetallicTextureRed=!1,this.useAmbientInGrayScale=!1,this.useObjectSpaceNormalMap=!1,this.useParallax=!1,this.useParallaxOcclusion=!1,this.parallaxScaleBias=.05,this.disableLighting=!1,this.forceIrradianceInFragment=!1,this.maxSimultaneousLights=4,this.invertNormalMapX=!1,this.invertNormalMapY=!1,this.twoSidedLighting=!1,this.useAlphaFresnel=!1,this.useLinearAlphaFresnel=!1,this.environmentBRDFTexture=null,this.forceNormalForward=!1,this.enableSpecularAntiAliasing=!1,this.useHorizonOcclusion=!0,this.useRadianceOcclusion=!0,this.unlit=!1,this.applyDecalMapAfterDetailMap=!1,this._lightingInfos=new S.Vector4(this.directIntensity,1,this.environmentIntensity,1),this._radianceTexture=null,this._useSpecularWeightFromAlpha=!1,this._useSpecularWeightFromSpecularColorTexture=!1,this._useSpecularRoughnessAnisotropyFromTangentTexture=!1,this._useCoatRoughnessAnisotropyFromTangentTexture=!1,this._useCoatRoughnessFromGreenChannel=!1,this._useGltfStyleAnisotropy=!1,this._useFuzzRoughnessFromTextureAlpha=!1,this._useSubsurfaceWeightFromTextureAlpha=!1,this._useHorizonOcclusion=!0,this._useRadianceOcclusion=!0,this._useAlphaFromBaseColorTexture=!1,this._useAmbientOcclusionFromMetallicTextureRed=!1,this._useRoughnessFromMetallicTextureGreen=!1,this._useMetallicFromMetallicTextureBlue=!1,this._useThinFilmThicknessFromTextureGreen=!1,this._useGeometryThicknessFromGreenChannel=!1,this._lightFalloff=o.Material.LIGHTFALLOFF_PHYSICAL,this._useObjectSpaceNormalMap=!1,this._useParallax=!1,this._useParallaxOcclusion=!1,this._parallaxScaleBias=.05,this._disableLighting=!1,this._maxSimultaneousLights=4,this._invertNormalMapX=!1,this._invertNormalMapY=!1,this._twoSidedLighting=!1,this._alphaCutOff=.4,this._useAlphaFresnel=!1,this._useLinearAlphaFresnel=!1,this._environmentBRDFTexture=null,this._environmentFuzzBRDFTexture=null,this._backgroundRefractionTexture=null,this._refractionHighQualityBlur=!0,this._forceIrradianceInFragment=!1,this._realTimeFiltering=!1,this._realTimeFilteringQuality=8,this._fuzzSampleNumber=4,this._forceNormalForward=!1,this._enableSpecularAntiAliasing=!1,this._renderTargets=new I.SmartArray(16),this._unlit=!1,this._applyDecalMapAfterDetailMap=!1,this._debugMode=0,this._shadersLoaded=!1,this._breakShaderLoadedCheck=!1,this._vertexPullingMetadata=null,this.debugMode=0,this.debugLimit=-1,this.debugFactor=1,this._cacheHasRenderTargetTextures=!1,this._transparencyMode=o.Material.MATERIAL_OPAQUE,this.getScene()&&!this.getScene()?.getEngine().isWebGPU&&this.getScene().getEngine().webGLVersion<2&&R.Logger.Error("OpenPBRMaterial: WebGL 2.0 or above is required for this material."),K._noiseTextures[this.getScene().uniqueId]||(K._noiseTextures[this.getScene().uniqueId]=new n.Texture(C.Tools.GetAssetUrl("https://assets.babylonjs.com/core/blue_noise/blue_noise_rgb.png"),this.getScene(),!1,!0,1),this.getScene().onDisposeObservable.addOnce(()=>{K._noiseTextures[this.getScene().uniqueId]?.dispose(),delete K._noiseTextures[this.getScene().uniqueId]})),this._attachImageProcessingConfiguration(null),this.getRenderTargetTextures=()=>(this._renderTargets.reset(),f.MaterialFlags.ReflectionTextureEnabled&&this._radianceTexture&&this._radianceTexture.isRenderTarget&&this._renderTargets.push(this._radianceTexture),f.MaterialFlags.RefractionTextureEnabled&&this._backgroundRefractionTexture&&this._backgroundRefractionTexture.isRenderTarget&&this._renderTargets.push(this._backgroundRefractionTexture),this._eventInfo.renderTargets=this._renderTargets,this._callbackPluginEventFillRenderTargetTextures(this._eventInfo),this._renderTargets),this._environmentBRDFTexture=(0,r.GetOpenPBREnvironmentBRDFTexture)(this.getScene()),this._environmentFuzzBRDFTexture=(0,r.GetEnvironmentFuzzBRDFTexture)(this.getScene()),this.prePassConfiguration=new g.PrePassConfiguration,this._propertyList={},Object.getOwnPropertyNames(this))){const e=this[a];e instanceof H&&(this._propertyList[a]=e)}for(const e of(Object.keys(this._propertyList).forEach(e=>{let t=this._propertyList[e],s=this._uniformsList[t.targetUniformName];s?s.numComponents!==t.targetUniformComponentNum?R.Logger.Error(`Uniform ${t.targetUniformName} already exists of size ${s.numComponents}, but trying to set it to ${t.targetUniformComponentNum}.`):s.requiredDefine!==t.requiredDefine&&(s.requiredDefine=void 0):((s=new z(t.targetUniformName,t.targetUniformComponentNum)).requiredDefine=t.requiredDefine,this._uniformsList[t.targetUniformName]=s),""===s.firstLinkedKey&&(s.firstLinkedKey=t.name),s.linkedProperties[t.name]=t}),this._uniformsArray=Object.values(this._uniformsList),this._samplersList={},Object.getOwnPropertyNames(this))){const t=this[e];t instanceof W&&(this._samplersList[e]=t)}for(const e in this._samplersList){const t=this._samplersList[e].textureDefine;this._samplerDefines[t]={type:"boolean",default:!1},this._samplerDefines[t+"DIRECTUV"]={type:"number",default:0},this._samplerDefines[t+"_GAMMA"]={type:"boolean",default:!1}}this._baseWeight,this._baseWeightTexture,this._baseColor,this._baseColorTexture,this._baseDiffuseRoughness,this._baseDiffuseRoughnessTexture,this._baseMetalness,this._baseMetalnessTexture,this._specularWeight,this._specularWeightTexture,this._specularColor,this._specularColorTexture,this._specularRoughness,this._specularIor,this._specularRoughnessTexture,this._specularRoughnessAnisotropy,this._specularRoughnessAnisotropyTexture,this._transmissionWeight,this._transmissionWeightTexture,this._transmissionColor,this._transmissionColorTexture,this._transmissionDepth,this._transmissionDepthTexture,this._transmissionScatter,this._transmissionScatterTexture,this._transmissionScatterAnisotropy,this._transmissionDispersionScale,this._transmissionDispersionScaleTexture,this._transmissionDispersionAbbeNumber,this._subsurfaceWeight,this._subsurfaceWeightTexture,this._subsurfaceColor,this._subsurfaceColorTexture,this._subsurfaceRadius,this._subsurfaceRadiusScale,this._subsurfaceRadiusScaleTexture,this._subsurfaceScatterAnisotropy,this._coatWeight,this._coatWeightTexture,this._coatColor,this._coatColorTexture,this._coatRoughness,this._coatRoughnessTexture,this._coatRoughnessAnisotropy,this._coatRoughnessAnisotropyTexture,this._coatIor,this._coatDarkening,this._coatDarkeningTexture,this._fuzzWeight,this._fuzzWeightTexture,this._fuzzColor,this._fuzzColorTexture,this._fuzzRoughness,this._fuzzRoughnessTexture,this._geometryThinWalled,this._geometryNormalTexture,this._geometryTangent,this._geometryTangentTexture,this._geometryCoatNormalTexture,this._geometryCoatTangent,this._geometryCoatTangentTexture,this._geometryOpacity,this._geometryOpacityTexture,this._geometryThickness,this._geometryThicknessTexture,this._thinFilmWeight,this._thinFilmWeightTexture,this._thinFilmThickness,this._thinFilmThicknessMin,this._thinFilmThicknessTexture,this._thinFilmIor,this._emissionLuminance,this._emissionColor,this._emissionColorTexture,this._ambientOcclusionTexture}get hasRenderTargetTextures(){return!!f.MaterialFlags.ReflectionTextureEnabled&&!!this._radianceTexture&&!!this._radianceTexture.isRenderTarget||!!f.MaterialFlags.RefractionTextureEnabled&&!!this._backgroundRefractionTexture&&!!this._backgroundRefractionTexture.isRenderTarget||this._cacheHasRenderTargetTextures}get isPrePassCapable(){return!this.disableDepthWrite}getClassName(){return"OpenPBRMaterial"}get transparencyMode(){return this._transparencyMode}set transparencyMode(e){this._transparencyMode!==e&&(this._transparencyMode=e,this._markAllSubMeshesAsTexturesAndMiscDirty())}_shouldUseAlphaFromBaseColorTexture(){return this._hasAlphaChannel()&&this._transparencyMode!==o.Material.MATERIAL_OPAQUE&&!this.geometryOpacityTexture}_hasAlphaChannel(){return null!=this.baseColorTexture&&this.baseColorTexture.hasAlpha&&this._useAlphaFromBaseColorTexture||null!=this.geometryOpacityTexture}needAlphaBlending(){return this.geometryOpacity<1||null!=this.geometryOpacityTexture}needAlphaBlendingForMesh(e){return this.geometryOpacity<1||null!=this.geometryOpacityTexture||super.needAlphaBlendingForMesh(e)}clone(e,t=!0,s=""){let r=l.SerializationHelper.Clone(()=>new K(e,this.getScene()),this,{cloneTexturesOnlyOnce:t});return r.id=e,r.name=e,this.stencil.copyTo(r.stencil),this._clonePlugins(r,s),r}serialize(){let e=super.serialize();return e.customType="BABYLON.OpenPBRMaterial",e}static Parse(e,t,s){let r=l.SerializationHelper.Parse(()=>new K(e.name,t),e,t,s);return e.stencil&&r.stencil.parse(e.stencil,t,s),o.Material._ParsePlugins(e,r,t,s),r}forceCompilation(e,t,s){let r={clipPlane:!1,useInstances:!1,...s};this._uniformBufferLayoutBuilt||this.buildUniformLayout(),this._callbackPluginEventGeneric(4,this._eventInfo),(()=>{if(this._breakShaderLoadedCheck)return;let s=new Y({...this._eventInfo.defineNames||{},...this._samplerDefines||{}}),i=this._prepareEffect(e,e,s,void 0,void 0,r.useInstances,r.clipPlane);this._onEffectCreatedObservable&&(G.effect=i,G.subMesh=null,this._onEffectCreatedObservable.notifyObservers(G)),i.isReady()?t&&t(this):i.onCompileObservable.add(()=>{t&&t(this)})})()}isReadyForSubMesh(e,t,s){this._uniformBufferLayoutBuilt||this.buildUniformLayout();let r=t._drawWrapper;if(r.effect&&this.isFrozen&&r._wasPreviouslyReady&&r._wasPreviouslyUsingInstances===s)return!0;t.materialDefines||(this._callbackPluginEventGeneric(4,this._eventInfo),t.materialDefines=new Y({...this._eventInfo.defineNames||{},...this._samplerDefines||{}}));let i=t.materialDefines;if(this._isReadyForSubMesh(t))return!0;let a=this.getScene(),n=a.getEngine();if(i._areTexturesDirty&&(this._eventInfo.hasRenderTargetTextures=!1,this._callbackPluginEventHasRenderTargetTextures(this._eventInfo),this._cacheHasRenderTargetTextures=this._eventInfo.hasRenderTargetTextures,a.texturesEnabled)){for(let e in this._samplersList){let t=this._samplersList[e];if(t.value&&!t.value.isReadyOrNotBlocking())return!1}let e=this._getRadianceTexture();if(e&&f.MaterialFlags.ReflectionTextureEnabled){if(!e.isReadyOrNotBlocking())return!1;if(e.irradianceTexture){if(!e.irradianceTexture.isReadyOrNotBlocking())return!1}else if(!e.sphericalPolynomial&&e.getInternalTexture()?._sphericalPolynomialPromise)return!1}if(this._environmentBRDFTexture&&f.MaterialFlags.ReflectionTextureEnabled&&!this._environmentBRDFTexture.isReady()||this._environmentFuzzBRDFTexture&&f.MaterialFlags.ReflectionTextureEnabled&&!this._environmentFuzzBRDFTexture.isReady()||this._backgroundRefractionTexture&&f.MaterialFlags.RefractionTextureEnabled&&!this._backgroundRefractionTexture.isReadyOrNotBlocking()||K._noiseTextures[a.uniqueId]&&!K._noiseTextures[a.uniqueId].isReady()||this._sssIrradianceTexture&&this._sssDepthTexture&&(!this._sssIrradianceTexture.isReady()||!this._sssDepthTexture.isReady()))return!1}if(this._eventInfo.isReadyForSubMesh=!0,this._eventInfo.defines=i,this._eventInfo.subMesh=t,this._callbackPluginEventIsReadyForSubMesh(this._eventInfo),!this._eventInfo.isReadyForSubMesh||i._areImageProcessingDirty&&this._imageProcessingConfiguration&&!this._imageProcessingConfiguration.isReady())return!1;if(i.AREALIGHTUSED){for(let t=0;t<e.lightSources.length;t++)if(!e.lightSources[t]._isReady())return!1}if(n.getCaps().standardDerivatives||e.isVerticesDataPresent(p.VertexBuffer.NormalKind)||(e.createNormals(!0),R.Logger.Warn("OpenPBRMaterial: Normals have been created for the mesh: "+e.name)),!(0,d.AreLightsTexturesReady)(a,e,this._maxSimultaneousLights,this._disableLighting))return!1;let o=t.effect,l=i._areLightsDisposed,u=this._prepareEffect(e,t.getRenderingMesh(),i,this.onCompiled,this.onError,s,null),h=!1;if(u)if(this._onEffectCreatedObservable&&(G.effect=u,G.subMesh=t,this._onEffectCreatedObservable.notifyObservers(G)),this.allowShaderHotSwapping&&o&&!u.isReady()){if(i.markAsUnprocessed(),h=this.isFrozen,l)return i._areLightsDisposed=!0,!1}else a.resetCachedMaterial(),t.setEffect(u,i,this._materialContext);return!!t.effect&&!!t.effect.isReady()&&(i._renderId=a.getRenderId(),r._wasPreviouslyReady=!h,r._wasPreviouslyUsingInstances=!!s,this._checkScenePerformancePriority(),!0)}buildUniformLayout(){let e=this._uniformBuffer;e.addUniform("vTangentSpaceParams",2),e.addUniform("vLightingIntensity",4),e.addUniform("pointSize",1),e.addUniform("vDebugMode",2),e.addUniform("renderTargetSize",2),e.addUniform("cameraInfo",4),e.addUniform("vTextureRepetitionHexTilingParams",4),e.addUniform("backgroundRefractionMatrix",16),e.addUniform("vBackgroundRefractionInfos",3),(0,d.PrepareUniformLayoutForIBL)(e,!0,!0,!0,!0,!0),Object.values(this._uniformsList).forEach(t=>{e.addUniform(t.name,t.numComponents)}),Object.values(this._samplersList).forEach(t=>{e.addUniform(t.samplerInfoName,2),e.addUniform(t.samplerMatrixName,16)}),super.buildUniformLayout()}bindPropertiesForSubMesh(e,t,s,r){if(0===this.geometryThickness)e.updateFloat("vGeometryThickness",0);else{r.getRenderingMesh().getWorldMatrix().decompose(S.TmpVectors.Vector3[0]);let t=Math.max(Math.abs(S.TmpVectors.Vector3[0].x),Math.abs(S.TmpVectors.Vector3[0].y),Math.abs(S.TmpVectors.Vector3[0].z));e.updateFloat("vGeometryThickness",this.geometryThickness*t)}}bindForSubMesh(e,t,s){let r=this.getScene(),a=s.materialDefines;if(!a)return;let n=s.effect;if(!n)return;this._activeEffect=n,t.getMeshUniformBuffer().bindToEffect(n,"Mesh"),t.transferToEffect(e);let o=r.getEngine();this._uniformBuffer.bindToEffect(n,"Material"),this.prePassConfiguration.bindForSubMesh(this._activeEffect,r,t,e,this.isFrozen),m.MaterialHelperGeometryRendering.Bind(o.currentRenderPassId,this._activeEffect,t,e,this);let l=r.activeCamera;l?this._uniformBuffer.updateFloat4("cameraInfo",l.minZ,l.maxZ,0,0):this._uniformBuffer.updateFloat4("cameraInfo",0,0,0,0);let u=this.textureRepetitionHexTilingParams;this._uniformBuffer.updateFloat4("vTextureRepetitionHexTilingParams",u[0],u[1],u[2],u[3]),this._eventInfo.subMesh=s,this._callbackPluginEventHardBindForSubMesh(this._eventInfo),a.OBJECTSPACE_NORMALMAP&&(e.toNormalMatrix(this._normalMatrix),this.bindOnlyNormalMatrix(this._normalMatrix));let h=this._mustRebind(r,n,s,t.visibility),_=o._features.needToAlwaysBindUniformBuffers;(0,d.BindBonesParameters)(t,this._activeEffect,this.prePassConfiguration),this._vertexPullingMetadata&&(0,c.BindVertexPullingUniforms)(this._activeEffect,this._vertexPullingMetadata);let p=this._uniformBuffer;if(h){this.bindViewProjection(n);let e=this._getRadianceTexture();if(!p.useUbo||!this.isFrozen||!p.isSync||s._drawWrapper._forceRebindOnNextCall){if(r.texturesEnabled){for(let e in this._samplersList){let t=this._samplersList[e];t.value&&(p.updateFloat2(t.samplerInfoName,t.value.coordinatesIndex,t.value.level),(0,d.BindTextureMatrix)(t.value,p,t.samplerPrefix))}(this.geometryNormalTexture||this.geometryCoatNormalTexture)&&(r._mirroredCameraPosition?p.updateFloat2("vTangentSpaceParams",this._invertNormalMapX?1:-1,this._invertNormalMapY?1:-1):p.updateFloat2("vTangentSpaceParams",this._invertNormalMapX?-1:1,this._invertNormalMapY?-1:1)),(0,d.BindIBLParameters)(r,a,p,i.Color3.White(),e,this.realTimeFiltering,!0,!0,!0,!0,!0)}this.pointsCloud&&p.updateFloat("pointSize",this.pointSize);let t=this._uniformsArray;for(let e=0,s=t.length;e<s;e++){let s=t[e];(void 0===s.requiredDefine||a[s.requiredDefine])&&(4===s.numComponents?(s.populateVectorFromLinkedProperties(S.TmpVectors.Vector4[0]),p.updateVector4(s.name,S.TmpVectors.Vector4[0])):3===s.numComponents?(s.populateVectorFromLinkedProperties(S.TmpVectors.Vector3[0]),p.updateVector3(s.name,S.TmpVectors.Vector3[0])):2===s.numComponents?(s.populateVectorFromLinkedProperties(S.TmpVectors.Vector2[0]),p.updateFloat2(s.name,S.TmpVectors.Vector2[0].x,S.TmpVectors.Vector2[0].y)):1===s.numComponents&&p.updateFloat(s.name,s.linkedProperties[s.firstLinkedKey].value))}this._lightingInfos.x=this.directIntensity,this._lightingInfos.y=this.emissionLuminance,this._lightingInfos.z=this.environmentIntensity*r.environmentIntensity,this._lightingInfos.w=1,p.updateVector4("vLightingIntensity",this._lightingInfos),p.updateFloat2("vDebugMode",this.debugLimit,this.debugFactor)}if(r.texturesEnabled){for(let e in this._samplersList){let t=this._samplersList[e];t.value&&p.setTexture(t.samplerName,t.value)}if((0,d.BindIBLSamplers)(r,a,p,e,this.realTimeFiltering),a.ENVIRONMENTBRDF&&p.setTexture("environmentBrdfSampler",this._environmentBRDFTexture),a.FUZZENVIRONMENTBRDF&&p.setTexture("environmentFuzzBrdfSampler",this._environmentFuzzBRDFTexture),a.REFRACTED_BACKGROUND&&(p.setTexture("backgroundRefractionSampler",this._backgroundRefractionTexture),p.updateMatrix("backgroundRefractionMatrix",this._backgroundRefractionTexture.getReflectionTextureMatrix()),S.TmpVectors.Vector3[1].set(Math.log2(this._backgroundRefractionTexture.getSize().width),0,0),p.updateVector3("vBackgroundRefractionInfos",S.TmpVectors.Vector3[1])),(a.ANISOTROPIC||a.FUZZ||a.REFRACTED_BACKGROUND||a.USE_IRRADIANCE_TEXTURE_FOR_SCATTERING)&&p.setTexture("blueNoiseSampler",K._noiseTextures[this.getScene().uniqueId]),a.USE_IRRADIANCE_TEXTURE_FOR_SCATTERING&&this.sssIrradianceTexture&&this.sssDepthTexture){let e=this.sssIrradianceTexture.getSize().width,t=this.sssIrradianceTexture.getSize().height;p.setTexture("sceneIrradianceSampler",this.sssIrradianceTexture),p.setTexture("sceneDepthSampler",this.sssDepthTexture),p.updateFloat2("renderTargetSize",e,t)}}this.getScene().useOrderIndependentTransparency&&this.needAlphaBlendingForMesh(t)&&this.getScene().depthPeelingRenderer.bind(n),this._eventInfo.subMesh=s,this._callbackPluginEventBindForSubMesh(this._eventInfo),(0,T.BindClipPlane)(this._activeEffect,this,r),this.bindEyePosition(n)}else _&&(this._needToBindSceneUbo=!0);this.bindPropertiesForSubMesh(this._uniformBuffer,r,r.getEngine(),s),(h||!this.isFrozen||_)&&r.lightsEnabled&&!this._disableLighting&&(0,d.BindLights)(r,t,this._activeEffect,a,this._maxSimultaneousLights),(h||!this.isFrozen)&&(this.bindView(n),(0,d.BindFogParameters)(r,t,this._activeEffect,!0),a.NUM_MORPH_INFLUENCERS&&(0,d.BindMorphTargetParameters)(t,this._activeEffect),a.BAKED_VERTEX_ANIMATION_TEXTURE&&t.bakedVertexAnimationManager?.bind(n,a.INSTANCES),this._imageProcessingConfiguration.bind(this._activeEffect),(0,d.BindLogDepth)(a,this._activeEffect,r)),this._afterBind(t,this._activeEffect,s),p.update()}getAnimatables(){let e=super.getAnimatables();for(let t in this._samplersList){let s=this._samplersList[t];s.value&&s.value.animations&&s.value.animations.length>0&&e.push(s.value)}return this._radianceTexture&&this._radianceTexture.animations&&this._radianceTexture.animations.length>0&&e.push(this._radianceTexture),e}getActiveTextures(){let e=super.getActiveTextures();for(let t in this._samplersList){let s=this._samplersList[t];s.value&&e.push(s.value)}return this._radianceTexture&&e.push(this._radianceTexture),e}hasTexture(e){if(super.hasTexture(e))return!0;for(let t in this._samplersList)if(this._samplersList[t].value===e)return!0;return this._radianceTexture===e}setPrePassRenderer(){return!1}dispose(e,t){if(this._breakShaderLoadedCheck=!0,t){for(let e in this._environmentBRDFTexture&&this.getScene().openPBREnvironmentBRDFTexture!==this._environmentBRDFTexture&&this._environmentBRDFTexture.dispose(),this._environmentFuzzBRDFTexture&&this.getScene().environmentFuzzBRDFTexture!==this._environmentFuzzBRDFTexture&&this._environmentFuzzBRDFTexture.dispose(),this._backgroundRefractionTexture=null,this._samplersList){let t=this._samplersList[e];t.value?.dispose()}this._radianceTexture?.dispose()}this._renderTargets.dispose(),this._imageProcessingConfiguration&&this._imageProcessingObserver&&this._imageProcessingConfiguration.onUpdateParameters.remove(this._imageProcessingObserver),super.dispose(e,t)}_getRadianceTexture(){return this._radianceTexture?this._radianceTexture:this.getScene().environmentTexture}_prepareEffect(t,s,r,i=null,n=null,o=null,l=null){if(this._prepareDefines(t,s,r,o,l),!r.isDirty)return null;r.markAsProcessed();let u=this.getScene().getEngine(),h=new _.EffectFallbacks,f=0;r.USESPHERICALINVERTEX&&h.addFallback(f++,"USESPHERICALINVERTEX"),r.FOG&&h.addFallback(f,"FOG"),r.SPECULARAA&&h.addFallback(f,"SPECULARAA"),r.POINTSIZE&&h.addFallback(f,"POINTSIZE"),r.LOGARITHMICDEPTH&&h.addFallback(f,"LOGARITHMICDEPTH"),r.PARALLAX&&h.addFallback(f,"PARALLAX"),r.PARALLAX_RHS&&h.addFallback(f,"PARALLAX_RHS"),r.PARALLAXOCCLUSION&&h.addFallback(f++,"PARALLAXOCCLUSION"),r.ENVIRONMENTBRDF&&h.addFallback(f++,"ENVIRONMENTBRDF"),r.TANGENT&&h.addFallback(f++,"TANGENT"),f=(0,d.HandleFallbacksForShadows)(r,h,this._maxSimultaneousLights,f),r.SPECULARTERM&&h.addFallback(f++,"SPECULARTERM"),r.USESPHERICALFROMREFLECTIONMAP&&h.addFallback(f++,"USESPHERICALFROMREFLECTIONMAP"),r.USEIRRADIANCEMAP&&h.addFallback(f++,"USEIRRADIANCEMAP"),r.NORMAL&&h.addFallback(f++,"NORMAL"),r.VERTEXCOLOR&&h.addFallback(f++,"VERTEXCOLOR"),r.MORPHTARGETS&&h.addFallback(f++,"MORPHTARGETS"),r.MULTIVIEW&&h.addFallback(0,"MULTIVIEW");let R=[p.VertexBuffer.PositionKind];r.NORMAL&&R.push(p.VertexBuffer.NormalKind),r.TANGENT&&R.push(p.VertexBuffer.TangentKind);for(let e=1;e<=6;++e)r["UV"+e]&&R.push(`uv${1===e?"":e}`);r.VERTEXCOLOR&&R.push(p.VertexBuffer.ColorKind),(0,d.PrepareAttributesForBones)(R,t,r,h),(0,d.PrepareAttributesForInstances)(R,r),(0,d.PrepareAttributesForMorphTargets)(R,t,r),(0,d.PrepareAttributesForBakedVertexAnimation)(R,t,r);let A="openpbr",E=["world","view","viewProjection","projection","vEyePosition","inverseProjection","renderTargetSize","vLightsType","visibility","vFogInfos","vFogColor","pointSize","mBones","normalMatrix","vLightingIntensity","logarithmicDepthConstant","vTangentSpaceParams","boneTextureInfo","vDebugMode","morphTargetTextureInfo","morphTargetTextureIndices","cameraInfo","vTextureRepetitionHexTilingParams","backgroundRefractionMatrix","vBackgroundRefractionInfos"];for(let e in this._uniformsList)E.push(e);let x=["environmentBrdfSampler","boneSampler","morphTargets","oitDepthSampler","oitFrontColorSampler","areaLightsLTC1Sampler","areaLightsLTC2Sampler"];for(let e in r.FUZZENVIRONMENTBRDF&&x.push("environmentFuzzBrdfSampler"),r.REFRACTED_BACKGROUND&&x.push("backgroundRefractionSampler"),(r.ANISOTROPIC||r.FUZZ||r.REFRACTED_BACKGROUND||r.USE_IRRADIANCE_TEXTURE_FOR_SCATTERING)&&x.push("blueNoiseSampler"),r.USE_IRRADIANCE_TEXTURE_FOR_SCATTERING&&(x.push("sceneIrradianceSampler"),x.push("sceneDepthSampler")),this._samplersList){let t=this._samplersList[e];x.push(t.samplerName),E.push(t.samplerInfoName),E.push(t.samplerMatrixName)}(0,d.PrepareUniformsAndSamplersForIBL)(E,x,!0);let S=["Material","Scene","Mesh"],y={maxSimultaneousLights:this._maxSimultaneousLights,maxSimultaneousMorphTargets:r.NUM_MORPH_INFLUENCERS};if(this._eventInfo.fallbacks=h,this._eventInfo.fallbackRank=f,this._eventInfo.defines=r,this._eventInfo.uniforms=E,this._eventInfo.attributes=R,this._eventInfo.samplers=x,this._eventInfo.uniformBuffersNames=S,this._eventInfo.customCode=void 0,this._eventInfo.mesh=t,this._eventInfo.indexParameters=y,this._callbackPluginEventGeneric(128,this._eventInfo),m.MaterialHelperGeometryRendering.AddUniformsAndSamplers(E,x),g.PrePassConfiguration.AddUniforms(E),g.PrePassConfiguration.AddSamplers(x),(0,T.AddClipPlaneUniforms)(E),this._useVertexPulling){let e=s?.geometry;e&&(this._vertexPullingMetadata=(0,c.PrepareVertexPullingUniforms)(e),this._vertexPullingMetadata&&this._vertexPullingMetadata.forEach((e,t)=>{E.push(`vp_${t}_info`)}))}else this._vertexPullingMetadata=null;a.ImageProcessingConfiguration&&(a.ImageProcessingConfiguration.PrepareUniforms(E,r),a.ImageProcessingConfiguration.PrepareSamplers(x,r)),(0,d.PrepareUniformsAndSamplersList)({uniformsNames:E,uniformBuffersNames:S,samplers:x,defines:r,maxSimultaneousLights:this._maxSimultaneousLights,shaderLanguage:this._shaderLanguage});let M={};this.customShaderNameResolve&&(A=this.customShaderNameResolve(A,E,S,x,r,R,M));let I=r.toString(),C=u.createEffect(A,{attributes:R,uniformsNames:E,uniformBuffersNames:S,samplers:x,defines:I,fallbacks:h,onCompiled:i,onError:n,indexParameters:y,processFinalCode:M.processFinalCode,processCodeAfterIncludes:this._eventInfo.customCode,multiTarget:r.PREPASS,shaderLanguage:this._shaderLanguage,extraInitializationsAsync:this._shadersLoaded?void 0:async()=>{1===this.shaderLanguage?await Promise.all([e.A(22496),e.A(20734)]):await Promise.all([e.A(82285),e.A(52747)]),this._shadersLoaded=!0}},u);return this._eventInfo.customCode=void 0,C}_prepareDefines(e,t,s,i=null,a=null){let n=t.hasThinInstances,l=this.getScene(),u=l.getEngine();(0,d.PrepareDefinesForLights)(l,e,s,!0,this._maxSimultaneousLights,this._disableLighting),s._needNormals=!0,(0,d.PrepareDefinesForMultiview)(l,s);let h=this.needAlphaBlendingForMesh(e)&&this.getScene().useOrderIndependentTransparency;if((0,d.PrepareDefinesForPrePass)(l,s,this.canRenderToMRT&&!h),(0,d.PrepareDefinesForOIT)(l,s,h),m.MaterialHelperGeometryRendering.PrepareDefines(u.currentRenderPassId,e,s),s._areTexturesDirty){s._needUVs=!1;for(let e=1;e<=6;++e)s["MAINUV"+e]=!1;if(l.texturesEnabled){for(let e in this._samplersList){let t=this._samplersList[e];t.value?((0,d.PrepareDefinesForMergedUV)(t.value,s,t.textureDefine),s[t.textureDefine+"_GAMMA"]=t.value.gammaSpace):s[t.textureDefine]=!1}let e=this._getRadianceTexture(),t=this._forceIrradianceInFragment||this.realTimeFiltering||this._twoSidedLighting||u.getCaps().maxVaryingVectors<=8||null!=this._baseDiffuseRoughnessTexture;if((0,d.PrepareDefinesForIBL)(l,e,s,this.realTimeFiltering,this.realTimeFilteringQuality,!t),this._baseMetalnessTexture&&(s.AOSTOREINMETALMAPRED=this._useAmbientOcclusionFromMetallicTextureRed),s.SPECULAR_WEIGHT_IN_ALPHA=this._useSpecularWeightFromAlpha,s.SPECULAR_WEIGHT_FROM_SPECULAR_COLOR_TEXTURE=this._useSpecularWeightFromSpecularColorTexture,s.SPECULAR_ROUGHNESS_ANISOTROPY_FROM_TANGENT_TEXTURE=this._useSpecularRoughnessAnisotropyFromTangentTexture,s.COAT_ROUGHNESS_ANISOTROPY_FROM_TANGENT_TEXTURE=this._useCoatRoughnessAnisotropyFromTangentTexture,s.COAT_ROUGHNESS_FROM_GREEN_CHANNEL=this._useCoatRoughnessFromGreenChannel,s.SPECULAR_ROUGHNESS_FROM_METALNESS_TEXTURE_GREEN=this._useRoughnessFromMetallicTextureGreen,s.FUZZ_ROUGHNESS_FROM_TEXTURE_ALPHA=this._useFuzzRoughnessFromTextureAlpha,s.SUBSURFACE_WEIGHT_FROM_TEXTURE_ALPHA=this._useSubsurfaceWeightFromTextureAlpha,s.BASE_METALNESS_FROM_METALNESS_TEXTURE_BLUE=this._useMetallicFromMetallicTextureBlue,s.THIN_FILM_THICKNESS_FROM_THIN_FILM_TEXTURE=this._useThinFilmThicknessFromTextureGreen,s.GEOMETRY_THICKNESS_FROM_GREEN_CHANNEL=this._useGeometryThicknessFromGreenChannel,this.geometryNormalTexture?(this._useParallax&&this.baseColorTexture&&f.MaterialFlags.DiffuseTextureEnabled?(s.PARALLAX=!0,s.PARALLAX_RHS=l.useRightHandedSystem,s.PARALLAXOCCLUSION=!!this._useParallaxOcclusion):s.PARALLAX=!1,s.OBJECTSPACE_NORMALMAP=this._useObjectSpaceNormalMap):(s.PARALLAX=!1,s.PARALLAX_RHS=!1,s.PARALLAXOCCLUSION=!1,s.OBJECTSPACE_NORMALMAP=!1),this._environmentBRDFTexture&&f.MaterialFlags.ReflectionTextureEnabled?(s.ENVIRONMENTBRDF=!0,s.ENVIRONMENTBRDF_RGBD=this._environmentBRDFTexture.isRGBD):(s.ENVIRONMENTBRDF=!1,s.ENVIRONMENTBRDF_RGBD=!1),this._environmentFuzzBRDFTexture?s.FUZZENVIRONMENTBRDF=!0:s.FUZZENVIRONMENTBRDF=!1,this.hasTransparency){s.REFRACTED_BACKGROUND=!!this._backgroundRefractionTexture&&f.MaterialFlags.RefractionTextureEnabled,s.REFRACTION_HIGH_QUALITY_BLUR=this._refractionHighQualityBlur,s.REFRACTED_LIGHTS=!0;let e=this._getRadianceTexture();e?(s.REFRACTED_ENVIRONMENT=f.MaterialFlags.RefractionTextureEnabled,s.REFRACTED_ENVIRONMENT_OPPOSITEZ=this.getScene().useRightHandedSystem?!e.invertZ:e.invertZ,s.REFRACTED_ENVIRONMENT_LOCAL_CUBE=e.isCube&&e.boundingBoxSize):s.REFRACTED_ENVIRONMENT=!1}else s.REFRACTED_BACKGROUND=!1,s.REFRACTED_LIGHTS=!1,s.REFRACTED_ENVIRONMENT=!1;this._shouldUseAlphaFromBaseColorTexture()?s.ALPHA_FROM_BASE_COLOR_TEXTURE=!0:s.ALPHA_FROM_BASE_COLOR_TEXTURE=!1}this._lightFalloff===o.Material.LIGHTFALLOFF_STANDARD?(s.USEPHYSICALLIGHTFALLOFF=!1,s.USEGLTFLIGHTFALLOFF=!1):this._lightFalloff===o.Material.LIGHTFALLOFF_GLTF?(s.USEPHYSICALLIGHTFALLOFF=!1,s.USEGLTFLIGHTFALLOFF=!0):(s.USEPHYSICALLIGHTFALLOFF=!0,s.USEGLTFLIGHTFALLOFF=!1),!this.backFaceCulling&&this._twoSidedLighting?s.TWOSIDEDLIGHTING=!0:s.TWOSIDEDLIGHTING=!1,s.MIRRORED=!!l._mirroredCameraPosition,s.SPECULARAA=u.getCaps().standardDerivatives&&this._enableSpecularAntiAliasing}if((s._areTexturesDirty||s._areMiscDirty)&&(s.ALPHATESTVALUE=`${this._alphaCutOff}${this._alphaCutOff%1==0?".":""}`,s.PREMULTIPLYALPHA=7===this.alphaMode||8===this.alphaMode,s.ALPHABLEND=this.needAlphaBlendingForMesh(e)),s._areTexturesDirty&&(s.TEXTURE_REPETITION_MODE=u.version>1||u.isWebGPU?this.textureRepetitionMode:0),s._areImageProcessingDirty&&this._imageProcessingConfiguration&&this._imageProcessingConfiguration.prepareDefines(s),s.FORCENORMALFORWARD=this._forceNormalForward,s.RADIANCEOCCLUSION=this._useRadianceOcclusion,s.HORIZONOCCLUSION=this._useHorizonOcclusion,(this.specularRoughnessAnisotropy>0||this.coatRoughnessAnisotropy>0)&&K._noiseTextures[l.uniqueId]&&f.MaterialFlags.ReflectionTextureEnabled?(s.ANISOTROPIC=!0,e.isVerticesDataPresent(p.VertexBuffer.TangentKind)||(s._needUVs=!0,s.MAINUV1=!0),this._useGltfStyleAnisotropy&&(s.USE_GLTF_STYLE_ANISOTROPY=!0),s.ANISOTROPIC_BASE=this.specularRoughnessAnisotropy>0,s.ANISOTROPIC_COAT=this.coatRoughnessAnisotropy>0):(s.ANISOTROPIC=!1,s.USE_GLTF_STYLE_ANISOTROPY=!1,s.ANISOTROPIC_BASE=!1,s.ANISOTROPIC_COAT=!1),s.THIN_FILM=this.thinFilmWeight>0,s.IRIDESCENCE=this.thinFilmWeight>0,s.DISPERSION=this.transmissionDispersionScale>0,s.SCATTERING=this.hasScattering,s.SSS_SAMPLE_COUNT=[8,16,32][this._sssQuality]??16,s.TRANSMISSION_SLAB=this.transmissionWeight>0,s.TRANSMISSION_SLAB_VOLUME=this.transmissionWeight>0&&this.transmissionDepth>0,s.SUBSURFACE_SLAB=this.subsurfaceWeight>0,!s.PREPASS&&(s.SUBSURFACE_SLAB||s.TRANSMISSION_SLAB_VOLUME)){let e=!1;if(!this.sssIrradianceTexture&&l.geometryBufferRenderer){let t=l.geometryBufferRenderer.getTextureIndex(B.IRRADIANCE_TEXTURE_TYPE);this.sssIrradianceTexture=l.geometryBufferRenderer.getGBuffer().textures[t],e=!0}if(!this.sssDepthTexture&&l.geometryBufferRenderer){let t=l.geometryBufferRenderer.getTextureIndex(B.SCREENSPACE_DEPTH_TEXTURE_TYPE);this.sssDepthTexture=l.geometryBufferRenderer.getGBuffer().textures[t],e=!0}this.sssIrradianceTexture&&this.sssDepthTexture&&(s.USE_IRRADIANCE_TEXTURE_FOR_SCATTERING=!0,e&&(s.USE_IRRADIANCE_TEXTURE_FOR_SCATTERING_GBUFFER=!0))}s.FUZZ=this.fuzzWeight>0&&f.MaterialFlags.ReflectionTextureEnabled,s.GEOMETRY_THIN_WALLED=0!=this.geometryThinWalled,s.FUZZ?(e.isVerticesDataPresent(p.VertexBuffer.TangentKind)||(s._needUVs=!0,s.MAINUV1=!0),this._environmentFuzzBRDFTexture=(0,r.GetEnvironmentFuzzBRDFTexture)(this.getScene()),s.FUZZ_IBL_SAMPLES=this.fuzzSampleNumber):(this._environmentFuzzBRDFTexture=null,s.FUZZENVIRONMENTBRDF=!1,s.FUZZ_IBL_SAMPLES=0),s._areMiscDirty&&((0,d.PrepareDefinesForMisc)(e,l,this._useLogarithmicDepth,this.pointsCloud,this.fogEnabled,this.needAlphaTestingForMesh(e),s,this._applyDecalMapAfterDetailMap,this._useVertexPulling,t,this._isVertexOutputInvariant),s.UNLIT=this._unlit||(this.pointsCloud||this.wireframe)&&!e.isVerticesDataPresent(p.VertexBuffer.NormalKind),s.DEBUGMODE=this._debugMode),(0,d.PrepareDefinesForFrameBoundValues)(l,u,this,s,!!i,a,n),this._eventInfo.defines=s,this._eventInfo.mesh=e,this._callbackPluginEventPrepareDefinesBeforeAttributes(this._eventInfo),(0,d.PrepareDefinesForAttributes)(e,s,!0,!0,!0,this._transparencyMode!==o.Material.MATERIAL_OPAQUE),this._callbackPluginEventPrepareDefines(this._eventInfo)}}K.SSS_QUALITY_LOW=0,K.SSS_QUALITY_MEDIUM=1,K.SSS_QUALITY_HIGH=2,K._noiseTextures={},K.ForceGLSL=!1,(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","baseWeight")],K.prototype,"_baseWeight",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","baseWeightTexture")],K.prototype,"_baseWeightTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","baseColor")],K.prototype,"_baseColor",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","baseColorTexture")],K.prototype,"_baseColorTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","baseDiffuseRoughness")],K.prototype,"_baseDiffuseRoughness",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","baseDiffuseRoughnessTexture")],K.prototype,"_baseDiffuseRoughnessTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","baseMetalness")],K.prototype,"_baseMetalness",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","baseMetalnessTexture")],K.prototype,"_baseMetalnessTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","specularWeight")],K.prototype,"_specularWeight",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","specularWeightTexture")],K.prototype,"_specularWeightTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","specularColor")],K.prototype,"_specularColor",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","specularColorTexture")],K.prototype,"_specularColorTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","specularRoughness")],K.prototype,"_specularRoughness",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","specularRoughnessTexture")],K.prototype,"_specularRoughnessTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","specularRoughnessAnisotropy")],K.prototype,"_specularRoughnessAnisotropy",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","specularRoughnessAnisotropyTexture")],K.prototype,"_specularRoughnessAnisotropyTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","specularIor")],K.prototype,"_specularIor",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","transmissionWeight")],K.prototype,"_transmissionWeight",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","transmissionWeightTexture")],K.prototype,"_transmissionWeightTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","transmissionColor")],K.prototype,"_transmissionColor",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","transmissionColorTexture")],K.prototype,"_transmissionColorTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","transmissionDepth")],K.prototype,"_transmissionDepth",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","transmissionDepthTexture")],K.prototype,"_transmissionDepthTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","transmissionScatter")],K.prototype,"_transmissionScatter",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","transmissionScatterTexture")],K.prototype,"_transmissionScatterTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","transmissionScatterAnisotropy")],K.prototype,"_transmissionScatterAnisotropy",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","transmissionDispersionScale")],K.prototype,"_transmissionDispersionScale",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","transmissionDispersionScaleTexture")],K.prototype,"_transmissionDispersionScaleTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","transmissionDispersionAbbeNumber")],K.prototype,"_transmissionDispersionAbbeNumber",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","subsurfaceWeight")],K.prototype,"_subsurfaceWeight",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","subsurfaceWeightTexture")],K.prototype,"_subsurfaceWeightTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","subsurfaceColor")],K.prototype,"_subsurfaceColor",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","subsurfaceColorTexture")],K.prototype,"_subsurfaceColorTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","subsurfaceRadius")],K.prototype,"_subsurfaceRadius",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","subsurfaceRadiusScale")],K.prototype,"_subsurfaceRadiusScale",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","subsurfaceRadiusScaleTexture")],K.prototype,"_subsurfaceRadiusScaleTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","subsurfaceScatterAnisotropy")],K.prototype,"_subsurfaceScatterAnisotropy",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","coatWeight")],K.prototype,"_coatWeight",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","coatWeightTexture")],K.prototype,"_coatWeightTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","coatColor")],K.prototype,"_coatColor",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","coatColorTexture")],K.prototype,"_coatColorTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","coatRoughness")],K.prototype,"_coatRoughness",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","coatRoughnessTexture")],K.prototype,"_coatRoughnessTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","coatRoughnessAnisotropy")],K.prototype,"_coatRoughnessAnisotropy",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","coatRoughnessAnisotropyTexture")],K.prototype,"_coatRoughnessAnisotropyTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","coatIor")],K.prototype,"_coatIor",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","coatDarkening")],K.prototype,"_coatDarkening",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","coatDarkeningTexture")],K.prototype,"_coatDarkeningTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","fuzzWeight")],K.prototype,"_fuzzWeight",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","fuzzWeightTexture")],K.prototype,"_fuzzWeightTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","fuzzColor")],K.prototype,"_fuzzColor",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","fuzzColorTexture")],K.prototype,"_fuzzColorTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","fuzzRoughness")],K.prototype,"_fuzzRoughness",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","fuzzRoughnessTexture")],K.prototype,"_fuzzRoughnessTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","geometryThinWalled")],K.prototype,"_geometryThinWalled",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","geometryNormalTexture")],K.prototype,"_geometryNormalTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","geometryTangent")],K.prototype,"_geometryTangent",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","geometryTangentTexture")],K.prototype,"_geometryTangentTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","geometryCoatNormalTexture")],K.prototype,"_geometryCoatNormalTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","geometryCoatTangent")],K.prototype,"_geometryCoatTangent",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","geometryCoatTangentTexture")],K.prototype,"_geometryCoatTangentTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","geometryOpacity")],K.prototype,"_geometryOpacity",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","geometryOpacityTexture")],K.prototype,"_geometryOpacityTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","geometryThickness")],K.prototype,"_geometryThickness",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","geometryThicknessTexture")],K.prototype,"_geometryThicknessTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","emissionLuminance")],K.prototype,"_emissionLuminance",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","emissionColor")],K.prototype,"_emissionColor",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","emissionColorTexture")],K.prototype,"_emissionColorTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","thinFilmWeight")],K.prototype,"_thinFilmWeight",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","thinFilmWeightTexture")],K.prototype,"_thinFilmWeightTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","thinFilmThickness")],K.prototype,"_thinFilmThickness",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","thinFilmThicknessMin")],K.prototype,"_thinFilmThicknessMin",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","thinFilmThicknessTexture")],K.prototype,"_thinFilmThicknessTexture",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","thinFilmIor")],K.prototype,"_thinFilmIor",void 0),(0,t.__decorate)([(0,s.addAccessorsForMaterialProperty)("_markAllSubMeshesAsTexturesDirty","ambientOcclusionTexture")],K.prototype,"_ambientOcclusionTexture",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"directIntensity",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"environmentIntensity",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"useSpecularWeightFromTextureAlpha",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesAndMiscDirty")],K.prototype,"forceAlphaTest",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesAndMiscDirty")],K.prototype,"alphaCutOff",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"useAmbientOcclusionFromMetallicTextureRed",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"useAmbientInGrayScale",void 0),(0,t.__decorate)([(0,s.serialize)()],K.prototype,"usePhysicalLightFalloff",null),(0,t.__decorate)([(0,s.serialize)()],K.prototype,"useGLTFLightFalloff",null),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"useObjectSpaceNormalMap",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"useParallax",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"useParallaxOcclusion",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"parallaxScaleBias",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsLightsDirty")],K.prototype,"disableLighting",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"forceIrradianceInFragment",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsLightsDirty")],K.prototype,"maxSimultaneousLights",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"invertNormalMapX",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"invertNormalMapY",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"twoSidedLighting",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"useAlphaFresnel",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"useLinearAlphaFresnel",void 0),(0,t.__decorate)([(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"environmentBRDFTexture",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"forceNormalForward",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"enableSpecularAntiAliasing",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"useHorizonOcclusion",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],K.prototype,"useRadianceOcclusion",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsMiscDirty")],K.prototype,"unlit",void 0),(0,t.__decorate)([(0,s.serialize)(),(0,s.expandToProperty)("_markAllSubMeshesAsMiscDirty")],K.prototype,"applyDecalMapAfterDetailMap",void 0),(0,t.__decorate)([(0,s.expandToProperty)("_markAllSubMeshesAsMiscDirty")],K.prototype,"debugMode",void 0),(0,t.__decorate)([(0,s.serialize)()],K.prototype,"transparencyMode",null);let Q=!1;function q(){Q||(Q=!0,(0,k.RegisterClass)("BABYLON.OpenPBRMaterial",K))}e.s(["OpenPBRMaterial",0,K,"OpenPBRMaterialDefines",0,Y,"RegisterOpenpbrMaterial",0,q],68465),q(),e.s([],45916),e.i(45916),e.i(68465),e.s(["OpenPBRMaterial",0,K,"OpenPBRMaterialDefines",0,Y,"RegisterOpenpbrMaterial",0,q],883)}]);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,29981,
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,29981,69838,e=>{"use strict";var f=e.i(12423);let i="clipPlaneFragmentDeclaration",o=`#ifdef CLIPPLANE
|
|
2
2
|
varying float fClipDistance;
|
|
3
3
|
#endif
|
|
4
4
|
#ifdef CLIPPLANE2
|
|
@@ -16,22 +16,7 @@ varying float fClipDistance5;
|
|
|
16
16
|
#ifdef CLIPPLANE6
|
|
17
17
|
varying float fClipDistance6;
|
|
18
18
|
#endif
|
|
19
|
-
`;f.ShaderStore.IncludesShadersStore[i]||(f.ShaderStore.IncludesShadersStore[i]=o),e.s(["clipPlaneFragmentDeclaration",0,{name:i,shader:o}],29981);let n="
|
|
20
|
-
#define FOGMODE_NONE 0.
|
|
21
|
-
#define FOGMODE_EXP 1.
|
|
22
|
-
#define FOGMODE_EXP2 2.
|
|
23
|
-
#define FOGMODE_LINEAR 3.
|
|
24
|
-
#define E 2.71828
|
|
25
|
-
uniform vec4 vFogInfos;uniform vec3 vFogColor;varying vec3 vFogDistance;float CalcFogFactor()
|
|
26
|
-
{float fogCoeff=1.0;float fogStart=vFogInfos.y;float fogEnd=vFogInfos.z;float fogDensity=vFogInfos.w;float fogDistance=length(vFogDistance);if (FOGMODE_LINEAR==vFogInfos.x)
|
|
27
|
-
{fogCoeff=(fogEnd-fogDistance)/(fogEnd-fogStart);}
|
|
28
|
-
else if (FOGMODE_EXP==vFogInfos.x)
|
|
29
|
-
{fogCoeff=1.0/pow(E,fogDistance*fogDensity);}
|
|
30
|
-
else if (FOGMODE_EXP2==vFogInfos.x)
|
|
31
|
-
{fogCoeff=1.0/pow(E,fogDistance*fogDistance*fogDensity*fogDensity);}
|
|
32
|
-
return clamp(fogCoeff,0.0,1.0);}
|
|
33
|
-
#endif
|
|
34
|
-
`;f.ShaderStore.IncludesShadersStore[n]||(f.ShaderStore.IncludesShadersStore[n]=a),e.s(["fogFragmentDeclaration",0,{name:n,shader:a}],56770);let d="clipPlaneFragment",r=`#if defined(CLIPPLANE) || defined(CLIPPLANE2) || defined(CLIPPLANE3) || defined(CLIPPLANE4) || defined(CLIPPLANE5) || defined(CLIPPLANE6)
|
|
19
|
+
`;f.ShaderStore.IncludesShadersStore[i]||(f.ShaderStore.IncludesShadersStore[i]=o),e.s(["clipPlaneFragmentDeclaration",0,{name:i,shader:o}],29981);let n="clipPlaneFragment",a=`#if defined(CLIPPLANE) || defined(CLIPPLANE2) || defined(CLIPPLANE3) || defined(CLIPPLANE4) || defined(CLIPPLANE5) || defined(CLIPPLANE6)
|
|
35
20
|
if (false) {}
|
|
36
21
|
#endif
|
|
37
22
|
#ifdef CLIPPLANE
|
|
@@ -58,14 +43,29 @@ else if (fClipDistance5>0.0)
|
|
|
58
43
|
else if (fClipDistance6>0.0)
|
|
59
44
|
{discard;}
|
|
60
45
|
#endif
|
|
61
|
-
`;f.ShaderStore.IncludesShadersStore[
|
|
46
|
+
`;f.ShaderStore.IncludesShadersStore[n]||(f.ShaderStore.IncludesShadersStore[n]=a),e.s(["clipPlaneFragment",0,{name:n,shader:a}],69838)},56770,40671,e=>{"use strict";var f=e.i(12423);let i="fogFragmentDeclaration",o=`#ifdef FOG
|
|
47
|
+
#define FOGMODE_NONE 0.
|
|
48
|
+
#define FOGMODE_EXP 1.
|
|
49
|
+
#define FOGMODE_EXP2 2.
|
|
50
|
+
#define FOGMODE_LINEAR 3.
|
|
51
|
+
#define E 2.71828
|
|
52
|
+
uniform vec4 vFogInfos;uniform vec3 vFogColor;varying vec3 vFogDistance;float CalcFogFactor()
|
|
53
|
+
{float fogCoeff=1.0;float fogStart=vFogInfos.y;float fogEnd=vFogInfos.z;float fogDensity=vFogInfos.w;float fogDistance=length(vFogDistance);if (FOGMODE_LINEAR==vFogInfos.x)
|
|
54
|
+
{fogCoeff=(fogEnd-fogDistance)/(fogEnd-fogStart);}
|
|
55
|
+
else if (FOGMODE_EXP==vFogInfos.x)
|
|
56
|
+
{fogCoeff=1.0/pow(E,fogDistance*fogDensity);}
|
|
57
|
+
else if (FOGMODE_EXP2==vFogInfos.x)
|
|
58
|
+
{fogCoeff=1.0/pow(E,fogDistance*fogDistance*fogDensity*fogDensity);}
|
|
59
|
+
return clamp(fogCoeff,0.0,1.0);}
|
|
60
|
+
#endif
|
|
61
|
+
`;f.ShaderStore.IncludesShadersStore[i]||(f.ShaderStore.IncludesShadersStore[i]=o),e.s(["fogFragmentDeclaration",0,{name:i,shader:o}],56770);let n="fogFragment",a=`#ifdef FOG
|
|
62
62
|
float fog=CalcFogFactor();
|
|
63
63
|
#ifdef PBR
|
|
64
64
|
fog=toLinearSpace(fog);
|
|
65
65
|
#endif
|
|
66
66
|
color.rgb=mix(vFogColor,color.rgb,fog);
|
|
67
67
|
#endif
|
|
68
|
-
`;f.ShaderStore.IncludesShadersStore[
|
|
68
|
+
`;f.ShaderStore.IncludesShadersStore[n]||(f.ShaderStore.IncludesShadersStore[n]=a),e.s(["fogFragment",0,{name:n,shader:a}],40671)},24445,e=>{"use strict";var f=e.i(12423),i=e.i(29981),o=e.i(56770),n=e.i(69838),a=e.i(40671);let r="colorPixelShader",d=`#if defined(VERTEXCOLOR) || defined(INSTANCESCOLOR) && defined(INSTANCES)
|
|
69
69
|
#define VERTEXCOLOR
|
|
70
70
|
varying vec4 vColor;
|
|
71
71
|
#else
|
|
@@ -84,4 +84,4 @@ gl_FragColor=color;
|
|
|
84
84
|
#endif
|
|
85
85
|
#include<fogFragment>(color,gl_FragColor)
|
|
86
86
|
#define CUSTOM_FRAGMENT_MAIN_END
|
|
87
|
-
}`;for(let e of(f.ShaderStore.ShadersStore[
|
|
87
|
+
}`;for(let e of(f.ShaderStore.ShadersStore[r]||(f.ShaderStore.ShadersStore[r]=d),[i.clipPlaneFragmentDeclaration,o.fogFragmentDeclaration,n.clipPlaneFragment,a.fogFragment]))f.ShaderStore.IncludesShadersStore[e.name]||(f.ShaderStore.IncludesShadersStore[e.name]=e.shader);e.s(["colorPixelShader",0,{name:r,shader:d}])}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,98105,e=>{"use strict";var o=e.i(13379),t=e.i(77052);class r{static Instantiate(e){if(this.RegisteredExternalClasses&&this.RegisteredExternalClasses[e])return this.RegisteredExternalClasses[e];let r=(0,t.GetClass)(e);if(r)return r;o.Logger.Warn(e+" not found, you may have missed an import.");let i=e.split("."),a="u">typeof window?window:"u">typeof globalThis?globalThis:this;for(let e=0,o=i.length;e<o;e++)a=a[i[e]];return"function"!=typeof a?null:a}}r.RegisteredExternalClasses={},e.s(["InstantiationTools",0,r])},65740,71265,e=>{"use strict";var o,t=e.i(99267),r=e.i(64545),i=e.i(13379);let a=(e,o,t)=>!e||e.getClassName&&"Mesh"===e.getClassName()?null:e.getClassName&&("SubMesh"===e.getClassName()||"PhysicsBody"===e.getClassName())?e.clone(o):e.clone?e.clone():Array.isArray(e)?e.slice():t&&"object"==typeof e?{...e}:null;class n{static DeepCopy(e,o,t,r,n=!1){for(let s of function(e){let o=[];do for(let t of Object.getOwnPropertyNames(e))-1===o.indexOf(t)&&o.push(t);while(e=Object.getPrototypeOf(e))return o}(e)){if("_"===s[0]&&(!r||-1===r.indexOf(s))||s.endsWith("Observable")||t&&-1!==t.indexOf(s))continue;let l=e[s],c=typeof l;if("function"!==c)try{if("object"===c)if(l instanceof Uint8Array)o[s]=Uint8Array.from(l);else if(l instanceof Array){if(o[s]=[],l.length>0)if("object"==typeof l[0])for(let e=0;e<l.length;e++){let t=a(l[e],o,n);-1===o[s].indexOf(t)&&o[s].push(t)}else o[s]=l.slice(0)}else o[s]=a(l,o,n);else o[s]=l}catch(e){i.Logger.Warn(e.message)}}}}e.s(["DeepCopier",0,n],71265);var s=e.i(36395),l=e.i(75405),c=e.i(65295),K=e.i(81623),g=e.i(46712),u=e.i(23240),P=e.i(98105),f=e.i(84768),d=e.i(68179);class v{static get BaseUrl(){return g.FileToolsOptions.BaseUrl}static set BaseUrl(e){g.FileToolsOptions.BaseUrl=e}static get CleanUrl(){return g.FileToolsOptions.CleanUrl}static set CleanUrl(e){g.FileToolsOptions.CleanUrl=e}static IsAbsoluteUrl(e){return 0===e.indexOf("//")||!(-1===e.indexOf("://")||-1===e.indexOf(".")||-1===e.indexOf("/")||e.indexOf(":")>e.indexOf("/"))&&(!!(e.indexOf("://")<e.indexOf("."))||0===e.indexOf("data:")||0===e.indexOf("blob:"))}static set ScriptBaseUrl(e){g.FileToolsOptions.ScriptBaseUrl=e}static get ScriptBaseUrl(){return g.FileToolsOptions.ScriptBaseUrl}static set CDNBaseUrl(e){o.ScriptBaseUrl=e,o.AssetBaseUrl=e}static set ScriptPreprocessUrl(e){g.FileToolsOptions.ScriptPreprocessUrl=e}static get ScriptPreprocessUrl(){return g.FileToolsOptions.ScriptPreprocessUrl}static get DefaultRetryStrategy(){return g.FileToolsOptions.DefaultRetryStrategy}static set DefaultRetryStrategy(e){g.FileToolsOptions.DefaultRetryStrategy=e}static get CorsBehavior(){return g.FileToolsOptions.CorsBehavior}static set CorsBehavior(e){g.FileToolsOptions.CorsBehavior=e}static get UseFallbackTexture(){return K.EngineStore.UseFallbackTexture}static set UseFallbackTexture(e){K.EngineStore.UseFallbackTexture=e}static get RegisteredExternalClasses(){return P.InstantiationTools.RegisteredExternalClasses}static set RegisteredExternalClasses(e){P.InstantiationTools.RegisteredExternalClasses=e}static get fallbackTexture(){return K.EngineStore.FallbackTexture}static set fallbackTexture(e){K.EngineStore.FallbackTexture=e}static FetchToRef(e,o,t,r,i,a){let n=((Math.abs(e)*t%t|0)+(Math.abs(o)*r%r|0)*t)*4;a.r=i[n]/255,a.g=i[n+1]/255,a.b=i[n+2]/255,a.a=i[n+3]/255}static Mix(e,o,t){return 0}static Instantiate(e){return P.InstantiationTools.Instantiate(e)}static SetImmediate(e){u.TimingTools.SetImmediate(e)}static IsExponentOfTwo(e){return!0}static FloatRound(e){return Math.fround(e)}static GetFilename(e){let o=e.lastIndexOf("/");return o<0?e:e.substring(o+1)}static GetFolderPath(e,o=!1){let t=e.lastIndexOf("/");return t<0?o?e:"":e.substring(0,t+1)}static ToDegrees(e){return 180*e/Math.PI}static ToRadians(e){return e*Math.PI/180}static SmoothAngleChange(e,o,t=.9){let r=this.ToRadians(e),i=this.ToRadians(o);return this.ToDegrees(Math.atan2((1-t)*Math.sin(i)+t*Math.sin(r),(1-t)*Math.cos(i)+t*Math.cos(r)))}static MakeArray(e,o){return!0!==o&&(void 0===e||null==e)?null:Array.isArray(e)?e:[e]}static GetPointerPrefix(e){return(0,r.IsWindowObjectExist)()&&!window.PointerEvent?"mouse":"pointer"}static SetCorsBehavior(e,o){(0,g.SetCorsBehavior)(e,o)}static SetReferrerPolicyBehavior(e,o){o.referrerPolicy=e}static get PreprocessUrl(){return g.FileToolsOptions.PreprocessUrl}static set PreprocessUrl(e){g.FileToolsOptions.PreprocessUrl=e}static LoadImage(e,o,t,r,i,a){return(0,g.LoadImage)(e,o,t,r,i,a)}static LoadFile(e,o,t,r,i,a){return(0,g.LoadFile)(e,o,t,r,i,a)}static async LoadFileAsync(e,o=!0){return await new Promise((t,r)=>{(0,g.LoadFile)(e,e=>{t(e)},void 0,void 0,o,(e,o)=>{r(o)})})}static GetAssetUrl(e){if(!e)return"";if(o.AssetBaseUrl&&e.startsWith(o._DefaultAssetsUrl)){let t=o.AssetBaseUrl.endsWith("/")?o.AssetBaseUrl.slice(0,-1):o.AssetBaseUrl;return e.replace(o._DefaultAssetsUrl,t)}return e}static GetBabylonScriptURL(e,t){if(!e)return"";if(e.startsWith(o._DefaultCdnUrl)){if(o.ScriptBaseUrl){let t=o.ScriptBaseUrl.endsWith("/")?o.ScriptBaseUrl.slice(0,-1):o.ScriptBaseUrl;e=e.replace(o._DefaultCdnUrl,t)}else if(o._CdnVersion){let t=`${o._DefaultCdnUrl}/v${o._CdnVersion}`;e.startsWith(t)||(e=e.replace(o._DefaultCdnUrl,t))}}return e=o.ScriptPreprocessUrl(e),t&&!o.IsAbsoluteUrl(e)&&(e=o.GetAbsoluteUrl(e)),e}static LoadBabylonScript(e,t,r,i){e=o.GetBabylonScriptURL(e),o.LoadScript(e,t,r)}static async LoadBabylonScriptAsync(e){return e=o.GetBabylonScriptURL(e),await o.LoadScriptAsync(e)}static _LoadScriptNative(e,t,r){_native&&o.LoadFile(e,e=>{try{Function(e).apply(null),t&&t()}catch(e){r&&r("LoadScript Error",e)}},void 0,void 0,!1,(e,o)=>{r&&r("LoadScript Error",o)})}static _LoadScriptWeb(e,o,t,i,a=!1){if("function"==typeof importScripts){try{importScripts(e),o&&o()}catch(o){t?.(`Unable to load script '${e}' in worker`,o)}return}if(!(0,r.IsWindowObjectExist)())return void t?.(`Cannot load script '${e}' outside of a window or a worker`);let n=document.getElementsByTagName("head")[0],s=document.createElement("script");a?(s.setAttribute("type","module"),s.innerText=e):(s.setAttribute("type","text/javascript"),s.setAttribute("src",e)),i&&(s.id=i),s.onload=()=>{o&&o()},s.onerror=o=>{t&&t(`Unable to load script '${e}'`,o)},n.appendChild(s)}static async LoadScriptAsync(e,o){return await new Promise((t,r)=>{this.LoadScript(e,()=>{t()},(e,o)=>{r(o||Error(e))},o)})}static ReadFileAsDataURL(e,o,r){let i=new FileReader,a={onCompleteObservable:new t.Observable,abort:()=>i.abort()};return i.onloadend=()=>{a.onCompleteObservable.notifyObservers(a)},i.onload=e=>{o(e.target.result)},i.onprogress=r,i.readAsDataURL(e),a}static ReadFile(e,o,t,r,i){return(0,g.ReadFile)(e,o,t,r,i)}static FileAsURL(e){let o=new Blob([e]);return window.URL.createObjectURL(o)}static Format(e,o=2){return e.toFixed(o)}static DeepCopy(e,o,t,r){n.DeepCopy(e,o,t,r)}static IsEmpty(e){for(let o in e)if(Object.prototype.hasOwnProperty.call(e,o))return!1;return!0}static RegisterTopRootEvents(e,o){for(let t=0;t<o.length;t++){let r=o[t];e.addEventListener(r.name,r.handler,!1);try{window.parent&&window.parent.addEventListener(r.name,r.handler,!1)}catch(e){}}}static UnregisterTopRootEvents(e,o){for(let t=0;t<o.length;t++){let r=o[t];e.removeEventListener(r.name,r.handler);try{e.parent&&e.parent.removeEventListener(r.name,r.handler)}catch(e){}}}static async DumpFramebuffer(e,o,t,r,i="image/png",a,n){throw(0,l._WarnImport)("DumpTools")}static DumpData(e,o,t,r,i="image/png",a,n=!1,s=!1,c){throw(0,l._WarnImport)("DumpTools")}static async DumpDataAsync(e,o,t,r="image/png",i,a=!1,n=!1,s){throw(0,l._WarnImport)("DumpTools")}static _IsOffScreenCanvas(e){return void 0!==e.convertToBlob}static ToBlob(e,t,r="image/png",i){o._IsOffScreenCanvas(e)||e.toBlob||(e.toBlob=function(e,o,t){setTimeout(()=>{let r=atob(this.toDataURL(o,t).split(",")[1]),i=r.length,a=new Uint8Array(i);for(let e=0;e<i;e++)a[e]=r.charCodeAt(e);e(new Blob([a]))})}),o._IsOffScreenCanvas(e)?e.convertToBlob({type:r,quality:i}).then(e=>t(e)):e.toBlob(function(e){t(e)},r,i)}static DownloadBlob(e,t){if("download"in document.createElement("a")){if(!t){let e=new Date;t="screenshot_"+((e.getFullYear()+"-"+(e.getMonth()+1)).slice(2)+"-"+e.getDate()+"_"+e.getHours()+"-")+("0"+e.getMinutes()).slice(-2)+".png"}o.Download(e,t)}else if(e&&"u">typeof URL){let o=URL.createObjectURL(e),t=window.open("");if(!t)return;let r=t.document.createElement("img");r.onload=function(){URL.revokeObjectURL(o)},r.src=o,t.document.body.appendChild(r)}}static EncodeScreenshotCanvasData(e,t,r="image/png",i,a){if("string"!=typeof i&&t){if(t){if(o._IsOffScreenCanvas(e))return void e.convertToBlob({type:r,quality:a}).then(e=>{let o=new FileReader;o.readAsDataURL(e),o.onloadend=()=>{t(o.result)}});t(e.toDataURL(r,a))}}else this.ToBlob(e,function(e){e&&o.DownloadBlob(e,i),t&&t("")},r,a)}static Download(e,o){if("u"<typeof URL)return;let t=window.URL.createObjectURL(e),r=document.createElement("a");document.body.appendChild(r),r.style.display="none",r.href=t,r.download=o,r.addEventListener("click",()=>{r.parentElement&&r.parentElement.removeChild(r)}),r.click(),window.URL.revokeObjectURL(t)}static BackCompatCameraNoPreventDefault(e){return"boolean"==typeof e[0]?e[0]:"boolean"==typeof e[1]&&e[1]}static CreateScreenshot(e,o,t,r,i="image/png",a=!1,n){throw(0,l._WarnImport)("ScreenshotTools")}static async CreateScreenshotAsync(e,o,t,r="image/png",i){throw(0,l._WarnImport)("ScreenshotTools")}static CreateScreenshotUsingRenderTarget(e,o,t,r,i="image/png",a=1,n=!1,s,c=!1,K=!1,g=!0,u,P){throw(0,l._WarnImport)("ScreenshotTools")}static async CreateScreenshotUsingRenderTargetAsync(e,o,t,r="image/png",i=1,a=!1,n,s=!1,c=!1,K=!0,g,u){throw(0,l._WarnImport)("ScreenshotTools")}static RandomId(){return(0,f.RandomGUID)()}static IsBase64(e){return(0,g.IsBase64DataUrl)(e)}static DecodeBase64(e){return(0,g.DecodeBase64UrlToBinary)(e)}static get errorsCount(){return i.Logger.errorsCount}static Log(e){i.Logger.Log(e)}static Warn(e){i.Logger.Warn(e)}static Error(e){i.Logger.Error(e)}static get LogCache(){return i.Logger.LogCache}static ClearLogCache(){i.Logger.ClearLogCache()}static set LogLevels(e){i.Logger.LogLevels=e}static set PerformanceLogLevel(e){(e&o.PerformanceUserMarkLogLevel)===o.PerformanceUserMarkLogLevel?_native?.enablePerformanceLogging?(_native.enablePerformanceLogging(1),o.StartPerformanceCounter=o._StartMarkNative,o.EndPerformanceCounter=o._EndMarkNative):(o.StartPerformanceCounter=o._StartUserMark,o.EndPerformanceCounter=o._EndUserMark):(e&o.PerformanceConsoleLogLevel)===o.PerformanceConsoleLogLevel?_native?.enablePerformanceLogging?(_native.enablePerformanceLogging(2),o.StartPerformanceCounter=o._StartMarkNative,o.EndPerformanceCounter=o._EndMarkNative):(o.StartPerformanceCounter=o._StartPerformanceConsole,o.EndPerformanceCounter=o._EndPerformanceConsole):(o.StartPerformanceCounter=o._StartPerformanceCounterDisabled,o.EndPerformanceCounter=o._EndPerformanceCounterDisabled,_native?.disablePerformanceLogging?.())}static _StartPerformanceCounterDisabled(e,o){}static _EndPerformanceCounterDisabled(e,o){}static _StartUserMark(e,t=!0){if(!o._Performance){if(!(0,r.IsWindowObjectExist)())return;o._Performance=window.performance}t&&o._Performance.mark&&o._Performance.mark(e+"-Begin")}static _EndUserMark(e,t=!0){t&&o._Performance.mark&&(o._Performance.mark(e+"-End"),o._Performance.measure(e,e+"-Begin",e+"-End"))}static _StartPerformanceConsole(e,t=!0){t&&(o._StartUserMark(e,t),console.time&&console.time(e))}static _EndPerformanceConsole(e,t=!0){t&&(o._EndUserMark(e,t),console.timeEnd(e))}static _StartMarkNative(e,t=!0){if(t&&_native?.startPerformanceCounter)if(o._NativePerformanceCounterHandles.has(e))o.Warn(`Performance counter with name ${e} is already started.`);else{let t=_native.startPerformanceCounter(e);o._NativePerformanceCounterHandles.set(e,t)}}static _EndMarkNative(e,t=!0){if(t&&_native?.endPerformanceCounter){let t=o._NativePerformanceCounterHandles.get(e);t?(_native.endPerformanceCounter(t),o._NativePerformanceCounterHandles.delete(e)):o.Warn(`Performance counter with name ${e} was not started.`)}}static get Now(){return s.PrecisionDate.Now}static GetClassName(e,o=!1){let t=null;return!o&&e.getClassName?t=e.getClassName():(e instanceof Object&&(t=(o?e:Object.getPrototypeOf(e)).constructor.__bjsclassName__),t||(t=typeof e)),t}static First(e,o){for(let t of e)if(o(t))return t;return null}static getFullClassName(e,o=!1){let t=null,r=null;if(!o&&e.getClassName)t=e.getClassName();else{if(e instanceof Object){let i=o?e:Object.getPrototypeOf(e);t=i.constructor.__bjsclassName__,r=i.constructor.__bjsmoduleName__}t||(t=typeof e)}return t?(null!=r?r+".":"")+t:null}static async DelayAsync(e){await new Promise(o=>{setTimeout(()=>{o()},e)})}static IsSafari(){return!!(0,r.IsNavigatorAvailable)()&&/^((?!chrome|android).)*safari/i.test(navigator.userAgent)}}o=v,v.AssetBaseUrl="",v.UseCustomRequestHeaders=!1,v.CustomRequestHeaders=c.WebRequest.CustomRequestHeaders,v.GetDOMTextContent=r.GetDOMTextContent,v._DefaultCdnUrl="https://cdn.babylonjs.com",v._CdnVersion="9.13.0",v._DefaultAssetsUrl="https://assets.babylonjs.com/core",v.LoadScript="u"<typeof _native?o._LoadScriptWeb:o._LoadScriptNative,v.GetAbsoluteUrl="object"==typeof document?e=>{let o=document.createElement("a");return o.href=e,o.href}:"function"==typeof URL&&"object"==typeof location?e=>new URL(e,location.origin).href:()=>{throw Error("Unable to get absolute URL. Override BABYLON.Tools.GetAbsoluteUrl to a custom implementation for the current context.")},v.NoneLogLevel=i.Logger.NoneLogLevel,v.MessageLogLevel=i.Logger.MessageLogLevel,v.WarningLogLevel=i.Logger.WarningLogLevel,v.ErrorLogLevel=i.Logger.ErrorLogLevel,v.AllLogLevel=i.Logger.AllLogLevel,v.IsWindowObjectExist=r.IsWindowObjectExist,v.PerformanceNoneLogLevel=0,v.PerformanceUserMarkLogLevel=1,v.PerformanceConsoleLogLevel=2,v._NativePerformanceCounterHandles=new Map,v.StartPerformanceCounter=o._StartPerformanceCounterDisabled,v.EndPerformanceCounter=o._EndPerformanceCounterDisabled;class A{constructor(e,o,t,r=0){this.iterations=e,this.index=r-1,this._done=!1,this._fn=o,this._successCallback=t}executeNext(){this._done||(this.index+1<this.iterations?(++this.index,this._fn(this)):this.breakLoop())}breakLoop(){this._done=!0,this._successCallback()}static Run(e,o,t,r=0){let i=new A(e,o,t,r);return i.executeNext(),i}static SyncAsyncForLoop(e,o,t,r,i,a=0){return A.Run(Math.ceil(e/o),r=>{i&&i()?r.breakLoop():setTimeout(()=>{for(let a=0;a<o;++a){let n=r.index*o+a;if(n>=e)break;if(t(n),i&&i()){r.breakLoop();break}}r.executeNext()},a)},r)}}let U=!1;e.s(["AsyncLoop",0,A,"RegisterTools",0,function(){U||(U=!0,v.Mix=d.Mix,v.IsExponentOfTwo=d.IsExponentOfTwo,K.EngineStore.FallbackTexture="data:image/jpg;base64,/9j/4AAQSkZJRgABAQEAYABgAAD/4QBmRXhpZgAATU0AKgAAAAgABAEaAAUAAAABAAAAPgEbAAUAAAABAAAARgEoAAMAAAABAAIAAAExAAIAAAAQAAAATgAAAAAAAABgAAAAAQAAAGAAAAABcGFpbnQubmV0IDQuMC41AP/bAEMABAIDAwMCBAMDAwQEBAQFCQYFBQUFCwgIBgkNCw0NDQsMDA4QFBEODxMPDAwSGBITFRYXFxcOERkbGRYaFBYXFv/bAEMBBAQEBQUFCgYGChYPDA8WFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFhYWFv/AABEIAQABAAMBIgACEQEDEQH/xAAfAAABBQEBAQEBAQAAAAAAAAAAAQIDBAUGBwgJCgv/xAC1EAACAQMDAgQDBQUEBAAAAX0BAgMABBEFEiExQQYTUWEHInEUMoGRoQgjQrHBFVLR8CQzYnKCCQoWFxgZGiUmJygpKjQ1Njc4OTpDREVGR0hJSlNUVVZXWFlaY2RlZmdoaWpzdHV2d3h5eoOEhYaHiImKkpOUlZaXmJmaoqOkpaanqKmqsrO0tba3uLm6wsPExcbHyMnK0tPU1dbX2Nna4eLj5OXm5+jp6vHy8/T19vf4+fr/xAAfAQADAQEBAQEBAQEBAAAAAAAAAQIDBAUGBwgJCgv/xAC1EQACAQIEBAMEBwUEBAABAncAAQIDEQQFITEGEkFRB2FxEyIygQgUQpGhscEJIzNS8BVictEKFiQ04SXxFxgZGiYnKCkqNTY3ODk6Q0RFRkdISUpTVFVWV1hZWmNkZWZnaGlqc3R1dnd4eXqCg4SFhoeIiYqSk5SVlpeYmZqio6Slpqeoqaqys7S1tre4ubrCw8TFxsfIycrS09TV1tfY2dri4+Tl5ufo6ery8/T19vf4+fr/2gAMAwEAAhEDEQA/APH6KKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FCiiigD6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++gooooA+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gUKKKKAPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76CiiigD5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BQooooA+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/voKKKKAPl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FCiiigD6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++gooooA+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gUKKKKAPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76CiiigD5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BQooooA+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/voKKKKAPl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FCiiigD6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++gooooA+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gUKKKKAPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76Pl+iiivuj+BT6gooor4U/vo+X6KKK+6P4FPqCiiivhT++j5fooor7o/gU+oKKKK+FP76P//Z")},"Tools",0,v],65740)}]);
|