@uptimizr/dashboard 0.3.4 → 0.3.6
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 +10 -10
- package/out/__next._head.txt +4 -4
- package/out/__next._index.txt +3 -3
- package/out/__next._tree.txt +1 -1
- package/out/_next/static/chunks/{2h051-1hu4co_.js → 0-0hui1_v3h8b.js} +9 -9
- package/out/_next/static/chunks/{2dqg85hsevk3c.js → 0-tzsd_n-ywom.js} +4 -4
- package/out/_next/static/chunks/00g5suuoa-_wn.js +1 -0
- package/out/_next/static/chunks/00o9hr_3hd0r8.js +1 -0
- package/out/_next/static/chunks/{0jxklh_ayjd4b.js → 00xc-0pj7on2s.js} +12 -12
- package/out/_next/static/chunks/01fh3_bncbe5u.js +1 -0
- package/out/_next/static/chunks/01urdkl1j8o6l.js +1 -0
- package/out/_next/static/chunks/{2j-sax2xfdv7l.js → 026vw95s88gsy.js} +1 -1
- package/out/_next/static/chunks/02eui3ctddbd2.js +1 -0
- package/out/_next/static/chunks/{3kr1polwvt6o_.js → 03zip1uidm6x9.js} +1 -1
- package/out/_next/static/chunks/{3gi0f1kg72xsf.js → 04_3ri5emyfcu.js} +1 -1
- package/out/_next/static/chunks/04c4nksb5y9r-.js +1 -0
- package/out/_next/static/chunks/04g-l-_b4payc.js +1 -0
- package/out/_next/static/chunks/04j9pexbmysdy.js +1 -0
- package/out/_next/static/chunks/{1rcfy_gzean3n.js → 055baac5e-c2o.js} +1 -1
- package/out/_next/static/chunks/05bdni_jrobq1.js +1 -0
- package/out/_next/static/chunks/05o0tb8l_htmw.js +1 -0
- package/out/_next/static/chunks/{3d5yb9ybkz7hx.js → 05uqfgf-hh-p5.js} +1 -1
- package/out/_next/static/chunks/06f-0kw8s0mqo.js +3 -0
- package/out/_next/static/chunks/{18r387bj9iv0j.js → 077eo-0dhbxz-.js} +1 -1
- package/out/_next/static/chunks/{18k-0jn63_5ie.js → 07z6p262h5hgl.js} +1 -1
- package/out/_next/static/chunks/{08bm3ye5govev.js → 08m_4cihfmik8.js} +1 -1
- package/out/_next/static/chunks/08obqw64faj8j.js +1 -0
- package/out/_next/static/chunks/{2k4s5rt7-l8jr.js → 099ilz3dmm1jw.js} +1 -1
- package/out/_next/static/chunks/09ppu_k464q-n.js +1 -0
- package/out/_next/static/chunks/{1rne-b-ktit5c.js → 0av6n_6q6kzo3.js} +2 -2
- package/out/_next/static/chunks/0bgcaf2x51kms.js +1 -0
- package/out/_next/static/chunks/{0ptp4ne7j6yg6.js → 0bj_310rugcn1.js} +11 -11
- package/out/_next/static/chunks/0c5d3qn2mb3ew.js +1 -0
- package/out/_next/static/chunks/{2gtebfttq1v0o.js → 0dck67in84de0.js} +1 -1
- package/out/_next/static/chunks/0dg4wxz-6u5lo.js +1 -0
- package/out/_next/static/chunks/{2apt1vh-7rl2l.js → 0dva036n8ab62.js} +1 -1
- package/out/_next/static/chunks/{159u-hx80yfaw.js → 0erga_bzezbza.js} +1 -1
- package/out/_next/static/chunks/0f0-i105odxqd.js +1 -0
- package/out/_next/static/chunks/{1fvlbwp6r93wo.js → 0g2wngc6oe7fd.js} +24 -24
- package/out/_next/static/chunks/0gyeqz9pagssf.js +1 -0
- package/out/_next/static/chunks/0i82k-t0fbn8f.js +1 -0
- package/out/_next/static/chunks/0kzw45f61wm3j.js +1 -0
- package/out/_next/static/chunks/0l8bfa2xewq69.js +1 -0
- package/out/_next/static/chunks/{390fogn9oz13i.js → 0n-zml1gn0o1u.js} +1 -1
- package/out/_next/static/chunks/{44gsjajjdhf51.js → 0n92hec_jb_-_.js} +1 -1
- package/out/_next/static/chunks/{2s0dwzg7kq36n.js → 0okbyggxe6mx5.js} +1 -1
- package/out/_next/static/chunks/{0h-ohf4gntwtj.js → 0pv2wirx45e1m.js} +1 -1
- package/out/_next/static/chunks/0qxd_8t3nca36.js +1 -0
- package/out/_next/static/chunks/0s1jghzw8jufz.js +1 -0
- package/out/_next/static/chunks/{0ngai1_zxwsk8.js → 0s84ekz_f9ngx.js} +1 -1
- package/out/_next/static/chunks/{16d4a4iopj2if.js → 0t89-lfct-7m6.js} +5 -5
- package/out/_next/static/chunks/0ti58h622yo-_.js +2 -0
- package/out/_next/static/chunks/{29v8falcmjvev.js → 0tn-9w46cwydp.js} +32 -32
- package/out/_next/static/chunks/0u8yr4k1y6m2t.js +1 -0
- package/out/_next/static/chunks/0ubxyut5rr600.js +1 -0
- package/out/_next/static/chunks/{3_bzxvqtk1t53.js → 0uxdbfa8gv6tk.js} +12 -12
- package/out/_next/static/chunks/0vso09vdz38sr.js +1 -0
- package/out/_next/static/chunks/{0_tqu60oxaj7q.js → 0w-hm7g7trtjg.js} +1 -1
- package/out/_next/static/chunks/0wbw9h7rsis2r.js +1 -0
- package/out/_next/static/chunks/{3sbm1ak54_2ep.js → 0wq_9f98weoe3.js} +1 -1
- package/out/_next/static/chunks/0y4e49hpuucdi.js +1 -0
- package/out/_next/static/chunks/{0ioyy42h35hnd.js → 0yvevihll7sz-.js} +1 -1
- package/out/_next/static/chunks/{0zcdc17ie6lmh.js → 0zf26k6juhlzo.js} +50 -18
- package/out/_next/static/chunks/{3sg4zff4-h3t1.js → 1-b44873bjsdw.js} +1 -1
- package/out/_next/static/chunks/1-c3a1vnl8v1q.js +1 -0
- package/out/_next/static/chunks/1-xf86jgea22y.js +1 -0
- package/out/_next/static/chunks/10b0qqdnb_nox.js +1 -0
- package/out/_next/static/chunks/{2ib62lnqqaf4p.js → 11p92pnn5el0v.js} +1 -1
- package/out/_next/static/chunks/{06ljadw2-i91-.js → 12kdmh0h_mboy.js} +1 -1
- package/out/_next/static/chunks/141tngxsk32hq.js +1 -0
- package/out/_next/static/chunks/14ijcpo72av4r.js +1 -0
- package/out/_next/static/chunks/16hdip1drt8o-.js +1 -0
- package/out/_next/static/chunks/{3g5ae-38cepwm.js → 17aahvhpls1l7.js} +199 -199
- package/out/_next/static/chunks/{17d1isrw8gtnb.js → 18txc1wwwu9f9.js} +1 -1
- package/out/_next/static/chunks/{2716si10ouwu-.js → 18wa83g0qfh-b.js} +1 -1
- package/out/_next/static/chunks/19dp8nr4uygg2.js +5 -0
- package/out/_next/static/chunks/1_8acnu6_-qe-.js +1 -0
- package/out/_next/static/chunks/1__nujzr9e352.js +3 -0
- package/out/_next/static/chunks/1bmyq1b0by7ug.js +1 -0
- package/out/_next/static/chunks/{1wyr4at61q29n.js → 1ccn725by19i1.js} +1 -1
- package/out/_next/static/chunks/{0f_nv15a8q415.js → 1d1tpj9nm1nhf.js} +1 -1
- package/out/_next/static/chunks/1dfwa563iciz3.js +1 -0
- package/out/_next/static/chunks/1di5enkavl9vx.js +4 -0
- package/out/_next/static/chunks/{006nix8mv66z_.js → 1e_-_7biavwmb.js} +1 -1
- package/out/_next/static/chunks/{1y12bjsbq18_t.js → 1ephzzweysylq.js} +34 -34
- package/out/_next/static/chunks/1fwsjnd1y-lx_.js +1 -0
- package/out/_next/static/chunks/{2z9ot-w1x60fv.js → 1fyh50hjt7hi_.js} +1 -1
- package/out/_next/static/chunks/1gaexq_suxai0.js +1 -0
- package/out/_next/static/chunks/1gtj_l5ame5mw.js +1 -0
- package/out/_next/static/chunks/{1--aypw9o8yng.js → 1gvdmbr65lpud.js} +39 -39
- package/out/_next/static/chunks/{02tc9r3sc7fgc.js → 1ho02fc091nj2.js} +1 -1
- package/out/_next/static/chunks/{3v0td-ziuai2i.js → 1hsvckd0sgdgr.js} +1 -1
- package/out/_next/static/chunks/1i4f3n_2_3ery.js +1 -0
- package/out/_next/static/chunks/1j7e3qpjuj89a.js +1 -0
- package/out/_next/static/chunks/{2btqzk0tj0gz6.js → 1mrvp94tietcv.js} +1 -1
- package/out/_next/static/chunks/{3vxkkhs0vi_xa.js → 1mvadj46owrck.js} +1 -1
- package/out/_next/static/chunks/{1b2tkk7e_2o0k.js → 1n_gxvu31aofy.js} +2 -2
- package/out/_next/static/chunks/{0gblbgw7w7r9w.js → 1nasz7q3tvb53.js} +1 -1
- package/out/_next/static/chunks/{2_7dp91937mqi.js → 1ng-fqh2_n984.js} +1 -1
- package/out/_next/static/chunks/{0x4-zyy8pzmlq.js → 1nqojcig-0m3c.js} +1 -1
- package/out/_next/static/chunks/1o3ggu95lfu6i.js +1 -0
- package/out/_next/static/chunks/{2dolerz81xb52.js → 1og49_atcksim.js} +1 -1
- package/out/_next/static/chunks/{0c2k-gvwph4qs.js → 1oljzgz5jistn.js} +1 -1
- package/out/_next/static/chunks/1ozi46t8jajqh.js +1 -0
- package/out/_next/static/chunks/{1w9xu1qa9-wmv.js → 1ph0tfo-4hl-f.js} +1 -1
- package/out/_next/static/chunks/{17dmbt396_tyq.js → 1qjsgebn9m-0l.js} +1 -1
- package/out/_next/static/chunks/{168r9r65o9jnc.js → 1qsut_e3msg0l.js} +1 -1
- package/out/_next/static/chunks/{3efuvh_35yhes.js → 1qxhgauuomthl.js} +39 -39
- package/out/_next/static/chunks/{2w7yf7ouyrlkb.js → 1rb8wewjbdisv.js} +1 -1
- package/out/_next/static/chunks/1rr74xxjtckyv.js +1 -0
- package/out/_next/static/chunks/{1kl5xxohpr6-4.js → 1solqr18og2ot.js} +1 -1
- package/out/_next/static/chunks/{2rjc8yn50ducj.js → 1t2exh89lnazc.js} +34 -34
- package/out/_next/static/chunks/{0_ux41xcoea3u.js → 1t7nl8rx7mabd.js} +40 -40
- package/out/_next/static/chunks/{3fx3sriw1w3sa.js → 1tt1bbry-4f-6.js} +1 -1
- package/out/_next/static/chunks/{0ufakw529sr9d.js → 1upkv4ltuh3s5.js} +40 -40
- package/out/_next/static/chunks/{2npk7tr63h7rl.js → 1uu55ejvi7q5u.js} +1 -1
- package/out/_next/static/chunks/{2cvvxifoedn6j.js → 1ux1rpe-n1mai.js} +1 -1
- package/out/_next/static/chunks/{091ll-lp6spu3.js → 1vmpltnr0cyos.js} +1 -1
- package/out/_next/static/chunks/1x99m91nt1m3b.js +1 -0
- package/out/_next/static/chunks/1xbzxfeq9789f.js +1 -0
- package/out/_next/static/chunks/1ybiu-rkt50_1.js +1 -0
- package/out/_next/static/chunks/{3y9c26fv1poq_.js → 2-hdejef-mpka.js} +199 -199
- package/out/_next/static/chunks/{22qzld31fbhbv.js → 2-p206i_ihx09.js} +1 -1
- package/out/_next/static/chunks/{340pg0qkv5tqq.js → 20qelrstvz9_n.js} +1 -1
- package/out/_next/static/chunks/21at65obnoo8z.js +1 -0
- package/out/_next/static/chunks/21ko5mxfderw0.js +1 -0
- package/out/_next/static/chunks/21muzwu43o8xg.js +1 -0
- package/out/_next/static/chunks/{3he9bxsc67ivq.js → 22ja7c3gk0_ko.js} +1 -1
- package/out/_next/static/chunks/{0mqi0xn_c010j.js → 22rl_arnzs-ve.js} +1 -1
- package/out/_next/static/chunks/23d-hvrwpixpm.js +1 -0
- package/out/_next/static/chunks/{2yzui3v-besdu.js → 255knovck7pv2.js} +4 -4
- package/out/_next/static/chunks/2569rrrffvm2w.js +31 -0
- package/out/_next/static/chunks/{229mkx-mtfcgf.js → 25gf6xn9u1c57.js} +1 -1
- package/out/_next/static/chunks/{2vmybybb3dvia.js → 267q_eg-c6f6m.js} +1 -1
- package/out/_next/static/chunks/{0e7xuupmrw4-e.js → 28ndw4nsw2t_4.js} +1 -1
- package/out/_next/static/chunks/{0m3yjobjg36ce.js → 29gv2swsp7tzu.js} +1 -1
- package/out/_next/static/chunks/29o74k0d6hkdf.js +1 -0
- package/out/_next/static/chunks/{0kr-bd6fuqc2s.js → 2bm95r0011asw.js} +1 -1
- package/out/_next/static/chunks/2btabnibkm0db.js +1 -0
- package/out/_next/static/chunks/2c--awgkdcikq.js +1 -0
- package/out/_next/static/chunks/{2ab-99frxpah-.js → 2c2dspoukng-5.js} +1 -1
- package/out/_next/static/chunks/{0zo4x1j8ug-kb.js → 2e46-2ubc90do.js} +5 -5
- package/out/_next/static/chunks/2ep7mjbaoeou0.js +1 -0
- package/out/_next/static/chunks/{1kq86iv41cet4.js → 2ezgqm7atphi6.js} +1 -1
- package/out/_next/static/chunks/{1bv97vf67p_ri.js → 2ftp5xmq_w23j.js} +35 -35
- package/out/_next/static/chunks/{38g9jpxjoxn2x.js → 2g_1ov-0j2kwd.js} +1 -1
- package/out/_next/static/chunks/2gfjzq_vjea4w.js +1 -0
- package/out/_next/static/chunks/{1tdg_eolxlcdl.js → 2h5hase6ewoyc.js} +1 -1
- package/out/_next/static/chunks/{0m0n7kjzscx0y.js → 2h5nvlgky7fpa.js} +1 -1
- package/out/_next/static/chunks/{17dabmbnkkplu.js → 2i82rmjta9ijs.js} +1 -1
- package/out/_next/static/chunks/2ies66gmou203.js +1 -0
- package/out/_next/static/chunks/2jenu2eek9viz.js +1 -0
- package/out/_next/static/chunks/{3043pprgv9ors.js → 2khh_pmm224k5.js} +23 -23
- package/out/_next/static/chunks/2kv9_bt15v83g.js +1 -0
- package/out/_next/static/chunks/{0msckddycfy76.js → 2luaj_cf5f19-.js} +1 -1
- package/out/_next/static/chunks/2mgmvz66gh5ub.js +1 -0
- package/out/_next/static/chunks/2nwlqtv3vrzcv.js +1 -0
- package/out/_next/static/chunks/{18ss4ls60s31e.js → 2o8k8x5zcepfy.js} +1 -1
- package/out/_next/static/chunks/{1e1zozntzsx42.js → 2pbgsq7vvtk8_.js} +1 -1
- package/out/_next/static/chunks/{0b7-mrrg7ryj2.js → 2pcdnd4nzcw4c.js} +1 -1
- package/out/_next/static/chunks/2q0rz76kj6h5z.js +1 -0
- package/out/_next/static/chunks/{3w1a2o8nevap8.js → 2rjfrjhp4kjev.js} +18 -18
- package/out/_next/static/chunks/2si5cg3hl5dtf.js +4 -0
- package/out/_next/static/chunks/2uhrhq35bki6u.js +1 -0
- package/out/_next/static/chunks/{1l12hkz1g7uhf.js → 2ymtumj-hfrjo.js} +1 -1
- package/out/_next/static/chunks/{2yr9wt421xdjr.js → 2z9mdtudj8crz.js} +17 -17
- package/out/_next/static/chunks/{1iaxzjly2pap1.js → 2zdzgmacaoor9.js} +1 -1
- package/out/_next/static/chunks/{0mk8tangq9equ.js → 2zpn7010iqgsy.js} +1 -1
- package/out/_next/static/chunks/2zyjw8g4tiu51.js +1 -0
- package/out/_next/static/chunks/{2kn_dqzbyabtn.js → 3-_08i4_7yhno.js} +1 -1
- package/out/_next/static/chunks/3-irhmtm1q5qw.js +1 -0
- package/out/_next/static/chunks/3-k74vn9exnb6.js +1 -0
- package/out/_next/static/chunks/{18avgwx9nlxp9.js → 3-x7522okdy-7.js} +1 -1
- package/out/_next/static/chunks/{1ll0ta8a2qx1p.js → 309f81l5ucsb_.js} +16 -16
- package/out/_next/static/chunks/{1f1vq3goue1w4.js → 31ei992g8gqz9.js} +1 -1
- package/out/_next/static/chunks/{0i9oqg-xbq-a9.js → 32vaw89wdwv5_.js} +1 -1
- package/out/_next/static/chunks/34y7nx6qmat06.js +1 -0
- package/out/_next/static/chunks/{1f92k-xa0pl-3.js → 35aagg46wp139.js} +1 -1
- package/out/_next/static/chunks/36rqw8h6ildpl.js +1 -0
- package/out/_next/static/chunks/{0zwkmsojeuekb.js → 380ivzcfb4o_3.js} +4 -4
- package/out/_next/static/chunks/{01aeari2x_tlz.js → 3a_khw6q6pyh1.js} +1 -1
- package/out/_next/static/chunks/3c_31f20z4jrl.js +1 -0
- package/out/_next/static/chunks/3ckp70rgr63u9.js +1 -0
- package/out/_next/static/chunks/{08rk1dp1wb-gm.js → 3d76e_yd8l_0x.js} +38 -38
- package/out/_next/static/chunks/{2p8dbh81chhon.js → 3ed24zmt8qfys.js} +1 -1
- package/out/_next/static/chunks/3ez20hi1mxw0w.js +1 -0
- package/out/_next/static/chunks/3fdx-rnos5ft-.js +1 -0
- package/out/_next/static/chunks/3fgfbxxb-j_bn.js +4 -0
- package/out/_next/static/chunks/{03st_hmor6qju.js → 3go-mst7n3udd.js} +1 -1
- package/out/_next/static/chunks/{3d0ejsnhbzi-j.js → 3gyyjsot8mdav.js} +1 -1
- package/out/_next/static/chunks/{2t9zu9v_g9kr9.js → 3iwf5yeurp57i.js} +3 -3
- package/out/_next/static/chunks/{0rruvj1cyflrh.js → 3k-gz8qf-mj-p.js} +1 -1
- package/out/_next/static/chunks/{2enlv4yy0t-9j.js → 3kalvwsf11-ss.js} +12 -12
- package/out/_next/static/chunks/3lehc5pujwhsz.js +1 -0
- package/out/_next/static/chunks/{05l3dluxivcor.js → 3m0ytnc241yfz.js} +1 -1
- package/out/_next/static/chunks/3mpe7c3iyxn5h.js +1 -0
- package/out/_next/static/chunks/{0tl8j9f8lt0yf.js → 3mvaub8qjdyuc.js} +1 -1
- package/out/_next/static/chunks/{0k79ryqehst0b.js → 3n-7bcmfbh299.js} +48 -18
- package/out/_next/static/chunks/{38ea9kqlbxt86.js → 3nw7u4bie0-g6.js} +1 -1
- package/out/_next/static/chunks/3qatb38-tk_gd.js +1 -0
- package/out/_next/static/chunks/3tdcdi_utmoy_.js +1 -0
- package/out/_next/static/chunks/{3x6wpv_z5m6rz.js → 3tdzweqszru4y.js} +1 -1
- package/out/_next/static/chunks/3tt_ir_va6262.js +1 -0
- package/out/_next/static/chunks/{39lxb7c--3_2u.js → 3w4qettzp7khe.js} +32 -32
- package/out/_next/static/chunks/{2op88btas-hl8.js → 3w_umk1xtj6to.js} +1 -1
- package/out/_next/static/chunks/{1kmsg9ef5djl3.js → 3y_51bmdnc0ey.js} +1 -1
- package/out/_next/static/chunks/{1ajmblsp0wj0_.js → 3yr66ufoli71t.js} +1 -1
- package/out/_next/static/chunks/{348hdbpkkcq_2.js → 3z4suna4kq4j5.js} +20 -20
- package/out/_next/static/chunks/{1y20bv6vl4ylk.js → 41qxc142snm22.js} +1 -1
- package/out/_next/static/chunks/{404f_93w2e8ty.js → 41yy4p3-rtyz1.js} +1 -1
- package/out/_next/static/chunks/{3fz7tc-4j13uv.js → 425epvuw3yy-n.js} +21 -21
- package/out/_next/static/chunks/{1t60cososq7b0.js → 43hwl25uke0l_.js} +1 -1
- package/out/_next/static/chunks/43qmngblcab8f.js +1 -0
- package/out/_next/static/chunks/{2bn9u9r0rfhvc.js → 442e2l3jzxd-_.js} +1 -1
- package/out/_next/static/chunks/{turbopack-16ab30_1p4vhq.js → turbopack-3r8yn0j92tqw_.js} +1 -1
- package/out/_not-found/__next._full.txt +8 -8
- package/out/_not-found/__next._head.txt +4 -4
- package/out/_not-found/__next._index.txt +3 -3
- 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 +1 -1
- package/out/_not-found.html +1 -1
- package/out/_not-found.txt +8 -8
- package/out/index.html +1 -1
- package/out/index.txt +10 -10
- package/package.json +10 -10
- package/out/_next/static/chunks/0-29qf-q72olu.js +0 -1
- package/out/_next/static/chunks/0-tk5ptli--r0.js +0 -1
- package/out/_next/static/chunks/0296l8lzd69ns.js +0 -1
- package/out/_next/static/chunks/04pk6n3z75dcy.js +0 -1
- package/out/_next/static/chunks/06m_64ysu9kn0.js +0 -1
- package/out/_next/static/chunks/09p5fltt7o3to.js +0 -1
- package/out/_next/static/chunks/0fxfsshoxnnh6.js +0 -4
- package/out/_next/static/chunks/0g6u34xkzrpjn.js +0 -1
- package/out/_next/static/chunks/0g7p8zp2kxve5.js +0 -1
- package/out/_next/static/chunks/0gwa154w_0wuh.js +0 -1
- package/out/_next/static/chunks/0h1o0cr3327tt.js +0 -1
- package/out/_next/static/chunks/0jf3n5n5yrr4o.js +0 -1
- package/out/_next/static/chunks/0k9-8s-jof_gw.js +0 -1
- package/out/_next/static/chunks/0kcbdjbdxu_wa.js +0 -1
- package/out/_next/static/chunks/0l3wwyl93sqh9.js +0 -1
- package/out/_next/static/chunks/0ngiuj5k-or6g.js +0 -1
- package/out/_next/static/chunks/0nx_t8iq-324h.js +0 -1
- package/out/_next/static/chunks/0oap0o8a8a_cl.js +0 -1
- package/out/_next/static/chunks/0ostjlqtwkhqr.js +0 -1
- package/out/_next/static/chunks/0vddljjnmozzx.js +0 -1
- package/out/_next/static/chunks/0w0sx062qmcsh.js +0 -1
- package/out/_next/static/chunks/0x6i6e6863tir.js +0 -1
- package/out/_next/static/chunks/1--kelnig7pxx.js +0 -1
- package/out/_next/static/chunks/1-ud6hztxiazp.js +0 -1
- package/out/_next/static/chunks/10v4rskkrjgd_.js +0 -1
- package/out/_next/static/chunks/117ys3lltfmcu.js +0 -1
- package/out/_next/static/chunks/13oqt2aoms4f6.js +0 -1
- package/out/_next/static/chunks/14klj_i6-l-10.js +0 -1
- package/out/_next/static/chunks/17ev44x54_jrd.js +0 -1
- package/out/_next/static/chunks/17svumd4o0qnc.js +0 -1
- package/out/_next/static/chunks/17v12p4sfraa0.js +0 -1
- package/out/_next/static/chunks/1a7cup181rjod.js +0 -1
- package/out/_next/static/chunks/1ek5rtpo6rxev.js +0 -1
- package/out/_next/static/chunks/1evp209qbr4cr.js +0 -5
- package/out/_next/static/chunks/1fa265388524p.js +0 -1
- package/out/_next/static/chunks/1g3z43o3h-024.js +0 -31
- package/out/_next/static/chunks/1g_27texazqcj.js +0 -1
- package/out/_next/static/chunks/1j--a56ji33_x.js +0 -1
- package/out/_next/static/chunks/1oara6fkfvgs3.js +0 -1
- package/out/_next/static/chunks/1par9m038tiov.js +0 -1
- package/out/_next/static/chunks/1vkww9l6lgqag.js +0 -1
- package/out/_next/static/chunks/1vpcaaf-0dn7q.js +0 -1
- package/out/_next/static/chunks/1vzmzrjhlm1q5.js +0 -1
- package/out/_next/static/chunks/1zcrrq1fx8g2y.js +0 -4
- package/out/_next/static/chunks/245h82k-g1nxr.js +0 -1
- package/out/_next/static/chunks/24cqjhy669845.js +0 -1
- package/out/_next/static/chunks/259xlbe69b9tc.js +0 -1
- package/out/_next/static/chunks/25ctnyh7njp-d.js +0 -4
- package/out/_next/static/chunks/286ggpetqnwyo.js +0 -3
- package/out/_next/static/chunks/28f1onw3nywbz.js +0 -1
- package/out/_next/static/chunks/28ycc-1519hl2.js +0 -1
- package/out/_next/static/chunks/2dhv35o59yzao.js +0 -1
- package/out/_next/static/chunks/2ey30qeaob985.js +0 -1
- package/out/_next/static/chunks/2f0r-df7tb3pu.js +0 -1
- package/out/_next/static/chunks/2gh4z57fem0_v.js +0 -1
- package/out/_next/static/chunks/2h1uw3cluvmmo.js +0 -1
- package/out/_next/static/chunks/2kje_jvmwsvwo.js +0 -1
- package/out/_next/static/chunks/2l_oqx9idxcs8.js +0 -1
- package/out/_next/static/chunks/2reukv9c7cq_9.js +0 -1
- package/out/_next/static/chunks/2vaoftqgc44cg.js +0 -1
- package/out/_next/static/chunks/2y75diyxqlhzl.js +0 -1
- package/out/_next/static/chunks/2zljunurdji0q.js +0 -1
- package/out/_next/static/chunks/34gp3hvr3j6um.js +0 -1
- package/out/_next/static/chunks/34rcp8qrbp522.js +0 -3
- package/out/_next/static/chunks/38wksra3d_k-4.js +0 -1
- package/out/_next/static/chunks/3ajhvedcs_lzb.js +0 -1
- package/out/_next/static/chunks/3bsvp8qhjqdu0.js +0 -1
- package/out/_next/static/chunks/3g4e2txsrb2p2.js +0 -1
- package/out/_next/static/chunks/3g_h_00xs9u59.js +0 -1
- package/out/_next/static/chunks/3hr-mlwi78nov.js +0 -1
- package/out/_next/static/chunks/3l6t8b3addlw7.js +0 -1
- package/out/_next/static/chunks/3mwoauxszd3mn.js +0 -1
- package/out/_next/static/chunks/3ovd8o_usay7j.js +0 -1
- package/out/_next/static/chunks/3pdpaqzwhhijn.js +0 -1
- package/out/_next/static/chunks/3pyggl13glbdc.js +0 -1
- package/out/_next/static/chunks/3rl45k759wfi1.js +0 -1
- package/out/_next/static/chunks/3urd7r018nel4.js +0 -1
- package/out/_next/static/chunks/3vaho-xrtuchd.js +0 -2
- package/out/_next/static/chunks/3wqs57qehored.js +0 -1
- package/out/_next/static/chunks/40acif2eh_unv.js +0 -1
- package/out/_next/static/chunks/413o2v11bygt5.js +0 -1
- package/out/_next/static/chunks/4227p7752rnny.js +0 -1
- package/out/_next/static/chunks/42oyfkhdvb-u3.js +0 -1
- /package/out/_next/static/{M5esRfAVlWSeBcfLV_jVr → yF_tmb8VExvESewet-_To}/_buildManifest.js +0 -0
- /package/out/_next/static/{M5esRfAVlWSeBcfLV_jVr → yF_tmb8VExvESewet-_To}/_clientMiddlewareManifest.js +0 -0
- /package/out/_next/static/{M5esRfAVlWSeBcfLV_jVr → yF_tmb8VExvESewet-_To}/_ssgManifest.js +0 -0
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,95180,e=>{"use strict";class t{constructor(e,t){this.width=e,this.height=t}toString(){return`{W: ${this.width}, H: ${this.height}}`}getClassName(){return"Size"}getHashCode(){let e=0|this.width;return 397*e^this.height}copyFrom(e){this.width=e.width,this.height=e.height}copyFromFloats(e,t){return this.width=e,this.height=t,this}set(e,t){return this.copyFromFloats(e,t)}multiplyByFloats(e,i){return new t(this.width*e,this.height*i)}clone(){return new t(this.width,this.height)}equals(e){return!!e&&this.width===e.width&&this.height===e.height}get surface(){return this.width*this.height}static Zero(){return new t(0,0)}add(e){return new t(this.width+e.width,this.height+e.height)}subtract(e){return new t(this.width-e.width,this.height-e.height)}scale(e){return new t(this.width*e,this.height*e)}static Lerp(e,i,r){return new t(e.width+(i.width-e.width)*r,e.height+(i.height-e.height)*r)}}e.s(["Size",0,t])},68061,e=>{"use strict";var t,i=e.i(16147),r=e.i(40220),s=e.i(57554),a=e.i(10534),n=e.i(47867),h=e.i(53477),o=e.i(95180);class l{get wrapU(){return this._wrapU}set wrapU(e){this._wrapU=e}get wrapV(){return this._wrapV}set wrapV(e){this._wrapV=e}get coordinatesMode(){return 0}get isCube(){return!!this._texture&&this._texture.isCube}set isCube(e){this._texture&&(this._texture.isCube=e)}get is3D(){return!!this._texture&&this._texture.is3D}set is3D(e){this._texture&&(this._texture.is3D=e)}get is2DArray(){return!!this._texture&&this._texture.is2DArray}set is2DArray(e){this._texture&&(this._texture.is2DArray=e)}getClassName(){return"ThinTexture"}static _IsRenderTargetWrapper(e){return e?.shareDepth!==void 0}constructor(e){this._wrapU=1,this._wrapV=1,this.wrapR=1,this.anisotropicFilteringLevel=4,this.delayLoadState=0,this._texture=null,this._engine=null,this._cachedSize=o.Size.Zero(),this._cachedBaseSize=o.Size.Zero(),this._initialSamplingMode=2,this._texture=l._IsRenderTargetWrapper(e)?e.texture:e,this._texture&&(this._engine=this._texture.getEngine(),this.wrapU=this._texture._cachedWrapU??this.wrapU,this.wrapV=this._texture._cachedWrapV??this.wrapV,this.wrapR=this._texture._cachedWrapR??this.wrapR)}isReady(){return 4===this.delayLoadState?(this.delayLoad(),!1):!!this._texture&&this._texture.isReady}delayLoad(){}getInternalTexture(){return this._texture}getSize(){if(this._texture){if(this._texture.width)return this._cachedSize.width=this._texture.width,this._cachedSize.height=this._texture.height,this._cachedSize;this._texture._size&&(this._cachedSize.width=this._texture._size,this._cachedSize.height=this._texture._size)}return this._cachedSize}getBaseSize(){return this.isReady()&&this._texture?this._texture._size?(this._cachedBaseSize.width=this._texture._size,this._cachedBaseSize.height=this._texture._size):(this._cachedBaseSize.width=this._texture.baseWidth,this._cachedBaseSize.height=this._texture.baseHeight):(this._cachedBaseSize.width=0,this._cachedBaseSize.height=0),this._cachedBaseSize}get samplingMode(){return this._texture?this._texture.samplingMode:this._initialSamplingMode}updateSamplingMode(e,t=!1){this._texture&&this._engine&&this._engine.updateTextureSamplingMode(e,this._texture,this._texture.generateMipMaps&&t)}releaseInternalTexture(){this._texture&&(this._texture.dispose(),this._texture=null)}dispose(){this._texture&&(this.releaseInternalTexture(),this._engine=null)}}var u=e.i(95397),_=e.i(54670);class c extends l{set hasAlpha(e){this._hasAlpha!==e&&(this._hasAlpha=e,this._scene&&this._scene.markAllMaterialsAsDirty(1,e=>e.hasTexture(this)))}get hasAlpha(){return this._hasAlpha}set getAlphaFromRGB(e){this._getAlphaFromRGB!==e&&(this._getAlphaFromRGB=e,this._scene&&this._scene.markAllMaterialsAsDirty(1,e=>e.hasTexture(this)))}get getAlphaFromRGB(){return this._getAlphaFromRGB}set coordinatesIndex(e){this._coordinatesIndex!==e&&(this._coordinatesIndex=e,this._scene&&this._scene.markAllMaterialsAsDirty(1,e=>e.hasTexture(this)))}get coordinatesIndex(){return this._coordinatesIndex}set coordinatesMode(e){this._coordinatesMode!==e&&(this._coordinatesMode=e,this._scene&&this._scene.markAllMaterialsAsDirty(1,e=>e.hasTexture(this)))}get coordinatesMode(){return this._coordinatesMode}get wrapU(){return this._wrapU}set wrapU(e){this._wrapU=e}get wrapV(){return this._wrapV}set wrapV(e){this._wrapV=e}get isCube(){return this._texture?this._texture.isCube:this._isCube}set isCube(e){this._texture?this._texture.isCube=e:this._isCube=e}get is3D(){return!!this._texture&&this._texture.is3D}set is3D(e){this._texture&&(this._texture.is3D=e)}get is2DArray(){return!!this._texture&&this._texture.is2DArray}set is2DArray(e){this._texture&&(this._texture.is2DArray=e)}get gammaSpace(){return this._texture?(null===this._texture._gammaSpace&&(this._texture._gammaSpace=this._gammaSpace),this._texture._gammaSpace&&!this._texture._useSRGBBuffer):this._gammaSpace}set gammaSpace(e){if(this._texture){if(this._texture._gammaSpace===e)return;this._texture._gammaSpace=e}else{if(this._gammaSpace===e)return;this._gammaSpace=e}this.getScene()?.markAllMaterialsAsDirty(1,e=>e.hasTexture(this))}get isRGBD(){return null!=this._texture&&this._texture._isRGBD}set isRGBD(e){e!==this.isRGBD&&(this._texture&&(this._texture._isRGBD=e),this.getScene()?.markAllMaterialsAsDirty(1,e=>e.hasTexture(this)))}get noMipmap(){return!1}get lodGenerationOffset(){return this._texture?this._texture._lodGenerationOffset:0}set lodGenerationOffset(e){this._texture&&(this._texture._lodGenerationOffset=e)}get lodGenerationScale(){return this._texture?this._texture._lodGenerationScale:0}set lodGenerationScale(e){this._texture&&(this._texture._lodGenerationScale=e)}get linearSpecularLOD(){return!!this._texture&&this._texture._linearSpecularLOD}set linearSpecularLOD(e){this._texture&&(this._texture._linearSpecularLOD=e)}get irradianceTexture(){return this._texture?this._texture._irradianceTexture:null}set irradianceTexture(e){this._texture&&(this._texture._irradianceTexture=e)}get uid(){return this._uid||(this._uid=(0,h.RandomGUID)()),this._uid}toString(){return this.name}getClassName(){return"BaseTexture"}set onDispose(e){this._onDisposeObserver&&this.onDisposeObservable.remove(this._onDisposeObserver),this._onDisposeObserver=this.onDisposeObservable.add(e)}get isBlocking(){return!0}get loadingError(){return this._loadingError}get errorObject(){return this._errorObject}constructor(e,t=null){super(null),this.metadata=null,this.reservedDataStore=null,this._hasAlpha=!1,this._getAlphaFromRGB=!1,this.level=1,this._coordinatesIndex=0,this.optimizeUVAllocation=!0,this._coordinatesMode=0,this.wrapR=1,this.anisotropicFilteringLevel=c.DEFAULT_ANISOTROPIC_FILTERING_LEVEL,this._isCube=!1,this._gammaSpace=!0,this.invertZ=!1,this.lodLevelInAlpha=!1,this._dominantDirection=null,this.isRenderTarget=!1,this._prefiltered=!1,this._forceSerialize=!1,this.animations=[],this.onDisposeObservable=new s.Observable,this._onDisposeObserver=null,this._scene=null,this._uid=null,this._parentContainer=null,this._loadingError=!1,e?c._IsScene(e)?this._scene=e:this._engine=e:this._scene=n.EngineStore.LastCreatedScene,this._scene&&(this.uniqueId=this._scene.getUniqueId(),this._scene.addTexture(this),this._engine=this._scene.getEngine()),this._texture=t,this._uid=null}getScene(){return this._scene}_getEngine(){return this._engine}getTextureMatrix(){return a.Matrix.IdentityReadOnly}getReflectionTextureMatrix(){return a.Matrix.IdentityReadOnly}getRefractionTextureMatrix(){return this.getReflectionTextureMatrix()}isReadyOrNotBlocking(){return!this.isBlocking||this.isReady()||this.loadingError}scale(e){}get canRescale(){return!1}_getFromCache(e,t,i,r,s,a){let n=this._getEngine();if(!n)return null;let h=n._getUseSRGBBuffer(!!s,t),o=n.getLoadedTexturesCache();for(let n=0;n<o.length;n++){let l=o[n];if((void 0===s||h===l._useSRGBBuffer)&&(void 0===r||r===l.invertY)&&l.url===e&&!t===l.generateMipMaps&&(!i||i===l.samplingMode)&&(void 0===a||a===l.isCube))return l.incrementReferences(),l}return null}_rebuild(e=!1){}clone(){return null}get textureType(){return this._texture&&void 0!==this._texture.type?this._texture.type:0}get textureFormat(){return this._texture&&void 0!==this._texture.format?this._texture.format:5}_markAllSubMeshesAsTexturesDirty(){let e=this.getScene();e&&e.markAllMaterialsAsDirty(1)}readPixels(e=0,t=0,i=null,r=!0,s=!1,a=0,n=0,h=Number.MAX_VALUE,o=Number.MAX_VALUE){if(!this._texture)return null;let l=this._getEngine();if(!l)return null;let u=this.getSize(),_=u.width,c=u.height;0!==t&&(_/=Math.pow(2,t),c/=Math.pow(2,t),_=Math.round(_),c=Math.round(c)),h=Math.min(_,h),o=Math.min(c,o);try{if(this._texture.isCube||this._texture.is2DArray)return l._readTexturePixels(this._texture,h,o,e,t,i,r,s,a,n);return l._readTexturePixels(this._texture,h,o,-1,t,i,r,s,a,n)}catch(e){return null}}_readPixelsSync(e=0,t=0,i=null,r=!0,s=!1){if(!this._texture)return null;let a=this.getSize(),n=a.width,h=a.height,o=this._getEngine();if(!o)return null;0!=t&&(n/=Math.pow(2,t),h/=Math.pow(2,t),n=Math.round(n),h=Math.round(h));try{if(this._texture.isCube)return o._readTexturePixelsSync(this._texture,n,h,e,t,i,r,s);return o._readTexturePixelsSync(this._texture,n,h,-1,t,i,r,s)}catch(e){return null}}get _lodTextureHigh(){return this._texture?this._texture._lodTextureHigh:null}get _lodTextureMid(){return this._texture?this._texture._lodTextureMid:null}get _lodTextureLow(){return this._texture?this._texture._lodTextureLow:null}dispose(){if(this._scene){this._scene.stopAnimation&&this._scene.stopAnimation(this),this._scene.removePendingData(this);let e=this._scene.textures.indexOf(this);if(e>=0&&this._scene.textures.splice(e,1),this._scene.onTextureRemovedObservable.notifyObservers(this),this._scene=null,this._parentContainer){let e=this._parentContainer.textures.indexOf(this);e>-1&&this._parentContainer.textures.splice(e,1),this._parentContainer=null}}this.onDisposeObservable.notifyObservers(this),this.onDisposeObservable.clear(),this.metadata=null,super.dispose()}serialize(e=!1){if(!this.name&&!e)return null;let t=u.SerializationHelper.Serialize(this);return u.SerializationHelper.AppendSerializedAnimations(this,t),t}static WhenAllReady(e,t){let i=e.length;if(0===i)return void t();for(let r=0;r<e.length;r++){let s=e[r];if(s.isReady())0==--i&&t();else{let e=s.onLoadObservable;e?e.addOnce(()=>{0==--i&&t()}):0==--i&&t()}}}static _IsScene(e){return"Scene"===e.getClassName()}}c.DEFAULT_ANISOTROPIC_FILTERING_LEVEL=4,(0,i.__decorate)([(0,r.serialize)()],c.prototype,"uniqueId",void 0),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"name",void 0),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"displayName",void 0),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"metadata",void 0),(0,i.__decorate)([(0,r.serialize)("hasAlpha")],c.prototype,"_hasAlpha",void 0),(0,i.__decorate)([(0,r.serialize)("getAlphaFromRGB")],c.prototype,"_getAlphaFromRGB",void 0),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"level",void 0),(0,i.__decorate)([(0,r.serialize)("coordinatesIndex")],c.prototype,"_coordinatesIndex",void 0),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"optimizeUVAllocation",void 0),(0,i.__decorate)([(0,r.serialize)("coordinatesMode")],c.prototype,"_coordinatesMode",void 0),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"wrapU",null),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"wrapV",null),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"wrapR",void 0),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"anisotropicFilteringLevel",void 0),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"isCube",null),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"is3D",null),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"is2DArray",null),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"gammaSpace",null),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"invertZ",void 0),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"lodLevelInAlpha",void 0),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"lodGenerationOffset",null),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"lodGenerationScale",null),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"linearSpecularLOD",null),(0,i.__decorate)([(0,r.serializeAsTexture)()],c.prototype,"irradianceTexture",null),(0,i.__decorate)([(0,r.serialize)()],c.prototype,"isRenderTarget",void 0),(t=c.prototype).forceSphericalPolynomialsRecompute??(t.forceSphericalPolynomialsRecompute=(0,_._MissingSideEffect)("BaseTexture","forceSphericalPolynomialsRecompute")),Object.getOwnPropertyDescriptor(c.prototype,"sphericalPolynomial")||Object.defineProperty(c.prototype,"sphericalPolynomial",(0,_._MissingSideEffectProperty)("BaseTexture","sphericalPolynomial")),e.s(["BaseTexture",0,c],68061)},67374,30649,e=>{"use strict";var t=e.i(16147),i=e.i(40220),r=e.i(57554),s=e.i(10534),a=e.i(68061),n=e.i(48477),h=e.i(54670),o=e.i(4775),l=e.i(58279),u=e.i(38677),_=e.i(61023);function c(e,t,i=!1){let r=t.width,s=t.height;if(e instanceof Float32Array){let t=e.byteLength/e.BYTES_PER_ELEMENT,i=new Uint8Array(t);for(;--t>=0;){let r=e[t];r<0?r=0:r>1&&(r=1),i[t]=255*r}e=i}let a=document.createElement("canvas");a.width=r,a.height=s;let n=a.getContext("2d");if(!n)return null;let h=n.createImageData(r,s);if(h.data.set(e),n.putImageData(h,0,0),i){let e=document.createElement("canvas");e.width=r,e.height=s;let t=e.getContext("2d");return t?(t.translate(0,s),t.scale(1,-1),t.drawImage(a,0,0),e.toDataURL("image/png")):null}return a.toDataURL("image/png")}function d(e,t=0,i=0){let r=e.getInternalTexture();if(!r)return null;let s=e._readPixelsSync(t,i);return s?c(s,e.getSize(),r.invertY):null}async function x(e,t=0,i=0){let r=e.getInternalTexture();if(!r)return null;let s=await e.readPixels(t,i);return s?c(s,e.getSize(),r.invertY):null}e.s(["GenerateBase64StringFromTexture",0,d,"GenerateBase64StringFromTextureAsync",0,x],30649);var p=e.i(21834),f=e.i(95397);class g extends a.BaseTexture{static _CreateVideoTexture(e,t,i,r=!1,s=!1,a=g.TRILINEAR_SAMPLINGMODE,n={},o,l=5){throw(0,h._WarnImport)("VideoTexture")}get noMipmap(){return this._noMipmap}get mimeType(){return this._mimeType}set isBlocking(e){this._isBlocking=e}get isBlocking(){return this._isBlocking}get invertY(){return this._invertY}constructor(e,t,i,s,a=g.TRILINEAR_SAMPLINGMODE,n=null,h=null,l=null,u=!1,_,c,d,x,f){let m;super(t),this.url=null,this.uOffset=0,this.vOffset=0,this.uScale=1,this.vScale=1,this.uAng=0,this.vAng=0,this.wAng=0,this.uRotationCenter=.5,this.vRotationCenter=.5,this.wRotationCenter=.5,this.homogeneousRotationInUVTransform=!1,this.inspectableCustomProperties=null,this._noMipmap=!1,this._invertY=!1,this._rowGenerationMatrix=null,this._cachedTextureMatrix=null,this._projectionModeMatrix=null,this._t0=null,this._t1=null,this._t2=null,this._cachedUOffset=-1,this._cachedVOffset=-1,this._cachedUScale=0,this._cachedVScale=0,this._cachedUAng=-1,this._cachedVAng=-1,this._cachedWAng=-1,this._cachedReflectionProjectionMatrixId=-1,this._cachedURotationCenter=-1,this._cachedVRotationCenter=-1,this._cachedWRotationCenter=-1,this._cachedHomogeneousRotationInUVTransform=!1,this._cachedIdentity3x2=!0,this._cachedReflectionTextureMatrix=null,this._cachedReflectionUOffset=-1,this._cachedReflectionVOffset=-1,this._cachedReflectionUScale=0,this._cachedReflectionVScale=0,this._cachedReflectionCoordinatesMode=-1,this._buffer=null,this._deleteBuffer=!1,this._format=null,this._delayedOnLoad=null,this._delayedOnError=null,this.onLoadObservable=new r.Observable,this._isBlocking=!0,this.name=e||"",this.url=e;let R=!1,T=null,M=!0;"object"==typeof i&&null!==i?(m=i.noMipmap??!1,s=i.invertY??!p.useOpenGLOrientationForUV,a=i.samplingMode??g.TRILINEAR_SAMPLINGMODE,n=i.onLoad??null,h=i.onError??null,l=i.buffer??null,u=i.deleteBuffer??!1,_=i.format,c=i.mimeType,d=i.loaderOptions,x=i.creationFlags,R=i.useSRGBBuffer??!1,T=i.internalTexture??null,M=i.gammaSpace??M,f=i.forcedExtension??f):m=!!i,this._gammaSpace=M,this._noMipmap=m,this._invertY=void 0===s?!p.useOpenGLOrientationForUV:s,this._initialSamplingMode=a,this._buffer=l,this._deleteBuffer=u,this._mimeType=c,this._loaderOptions=d,this._creationFlags=x,this._useSRGBBuffer=R,this._forcedExtension=f,void 0!==_&&(this._format=_);const S=this.getScene(),y=this._getEngine();if(!y)return;y.onBeforeTextureInitObservable.notifyObservers(this);const A=()=>{this._texture&&(this._texture._invertVScale&&(this.vScale*=-1,this.vOffset+=1),null!==this._texture._cachedWrapU&&(this.wrapU=this._texture._cachedWrapU,this._texture._cachedWrapU=null),null!==this._texture._cachedWrapV&&(this.wrapV=this._texture._cachedWrapV,this._texture._cachedWrapV=null),null!==this._texture._cachedWrapR&&(this.wrapR=this._texture._cachedWrapR,this._texture._cachedWrapR=null)),this.onLoadObservable.hasObservers()&&this.onLoadObservable.notifyObservers(this),n&&n(),!this.isBlocking&&S&&S.resetCachedMaterial()},O=(e,t)=>{this._loadingError=!0,this._errorObject={message:e,exception:t},h&&h(e,t),g.OnTextureLoadErrorObservable.notifyObservers(this)};if(!this.url&&!T){this._delayedOnLoad=A,this._delayedOnError=O;return}if(this._texture=T??this._getFromCache(this.url,m,a,this._invertY,R,this.isCube),this._texture)if(this._texture.isReady)o.TimingTools.SetImmediate(()=>A());else{const e=this._texture.onLoadedObservable.add(A);this._texture.onErrorObservable.add(t=>{O(t.message,t.exception),this._texture?.onLoadedObservable.remove(e)})}else if(S&&S.useDelayedTextureLoading)this.delayLoadState=4,this._delayedOnLoad=A,this._delayedOnError=O;else{try{this._texture=y.createTexture(this.url,m,this._invertY,S,a,A,O,this._buffer,void 0,this._format,this._forcedExtension,c,d,x,R)}catch(e){throw O("error loading",e),e}u&&(this._buffer=null)}}updateURL(e,t=null,i,r){this.url&&(this.releaseInternalTexture(),this.getScene().markAllMaterialsAsDirty(1,e=>e.hasTexture(this))),(!this.name||this.name.startsWith("data:"))&&(this.name=e),this.url=e,this._buffer=t,this._forcedExtension=r,this.delayLoadState=4;let s=this._delayedOnLoad,a=()=>{s?s():this.onLoadObservable.hasObservers()&&this.onLoadObservable.notifyObservers(this),i&&i()};this._delayedOnLoad=a,this.delayLoad()}delayLoad(){if(4!==this.delayLoadState)return;let e=this.getScene();if(!e)return;let t=this.url;!t&&(this.name.indexOf("://")>0||this.name.startsWith("data:"))&&(t=this.name),this.delayLoadState=1,this._texture=this._getFromCache(t,this._noMipmap,this.samplingMode,this._invertY,this._useSRGBBuffer,this.isCube),this._texture?this._delayedOnLoad&&(this._texture.isReady?o.TimingTools.SetImmediate(this._delayedOnLoad):this._texture.onLoadedObservable.add(this._delayedOnLoad)):(this._texture=e.getEngine().createTexture(t,this._noMipmap,this._invertY,e,this.samplingMode,this._delayedOnLoad,this._delayedOnError,this._buffer,null,this._format,this._forcedExtension,this._mimeType,this._loaderOptions,this._creationFlags,this._useSRGBBuffer),this._deleteBuffer&&(this._buffer=null)),this._delayedOnLoad=null,this._delayedOnError=null}_prepareRowForTextureGeneration(e,t,i,r){e*=this._cachedUScale,t*=this._cachedVScale,e-=this.uRotationCenter*this._cachedUScale,t-=this.vRotationCenter*this._cachedVScale,i-=this.wRotationCenter,s.Vector3.TransformCoordinatesFromFloatsToRef(e,t,i,this._rowGenerationMatrix,r),r.x+=this.uRotationCenter*this._cachedUScale+this._cachedUOffset,r.y+=this.vRotationCenter*this._cachedVScale+this._cachedVOffset,r.z+=this.wRotationCenter}getTextureMatrix(e=1){if(this.uOffset===this._cachedUOffset&&this.vOffset===this._cachedVOffset&&this.uScale*e===this._cachedUScale&&this.vScale===this._cachedVScale&&this.uAng===this._cachedUAng&&this.vAng===this._cachedVAng&&this.wAng===this._cachedWAng&&this.uRotationCenter===this._cachedURotationCenter&&this.vRotationCenter===this._cachedVRotationCenter&&this.wRotationCenter===this._cachedWRotationCenter&&this.homogeneousRotationInUVTransform===this._cachedHomogeneousRotationInUVTransform)return this._cachedTextureMatrix;this._cachedUOffset=this.uOffset,this._cachedVOffset=this.vOffset,this._cachedUScale=this.uScale*e,this._cachedVScale=this.vScale,this._cachedUAng=this.uAng,this._cachedVAng=this.vAng,this._cachedWAng=this.wAng,this._cachedURotationCenter=this.uRotationCenter,this._cachedVRotationCenter=this.vRotationCenter,this._cachedWRotationCenter=this.wRotationCenter,this._cachedHomogeneousRotationInUVTransform=this.homogeneousRotationInUVTransform,this._cachedTextureMatrix&&this._rowGenerationMatrix||(this._cachedTextureMatrix=s.Matrix.Zero(),this._rowGenerationMatrix=new s.Matrix,this._t0=s.Vector3.Zero(),this._t1=s.Vector3.Zero(),this._t2=s.Vector3.Zero()),s.Matrix.RotationYawPitchRollToRef(this.vAng,this.uAng,this.wAng,this._rowGenerationMatrix),this.homogeneousRotationInUVTransform?(s.Matrix.TranslationToRef(-this._cachedURotationCenter,-this._cachedVRotationCenter,-this._cachedWRotationCenter,s.TmpVectors.Matrix[0]),s.Matrix.TranslationToRef(this._cachedURotationCenter,this._cachedVRotationCenter,this._cachedWRotationCenter,s.TmpVectors.Matrix[1]),s.Matrix.ScalingToRef(this._cachedUScale,this._cachedVScale,0,s.TmpVectors.Matrix[2]),s.Matrix.TranslationToRef(this._cachedUOffset,this._cachedVOffset,0,s.TmpVectors.Matrix[3]),s.TmpVectors.Matrix[0].multiplyToRef(this._rowGenerationMatrix,this._cachedTextureMatrix),this._cachedTextureMatrix.multiplyToRef(s.TmpVectors.Matrix[1],this._cachedTextureMatrix),this._cachedTextureMatrix.multiplyToRef(s.TmpVectors.Matrix[2],this._cachedTextureMatrix),this._cachedTextureMatrix.multiplyToRef(s.TmpVectors.Matrix[3],this._cachedTextureMatrix),this._cachedTextureMatrix.setRowFromFloats(2,this._cachedTextureMatrix.m[12],this._cachedTextureMatrix.m[13],this._cachedTextureMatrix.m[14],1)):(this._prepareRowForTextureGeneration(0,0,0,this._t0),this._prepareRowForTextureGeneration(1,0,0,this._t1),this._prepareRowForTextureGeneration(0,1,0,this._t2),this._t1.subtractInPlace(this._t0),this._t2.subtractInPlace(this._t0),s.Matrix.FromValuesToRef(this._t1.x,this._t1.y,this._t1.z,0,this._t2.x,this._t2.y,this._t2.z,0,this._t0.x,this._t0.y,this._t0.z,0,0,0,0,1,this._cachedTextureMatrix));let t=this.getScene();if(!t)return this._cachedTextureMatrix;let i=this._cachedIdentity3x2;return this._cachedIdentity3x2=this._cachedTextureMatrix.isIdentityAs3x2(),this.optimizeUVAllocation&&i!==this._cachedIdentity3x2&&t.markAllMaterialsAsDirty(1,e=>e.hasTexture(this)),this._cachedTextureMatrix}getReflectionTextureMatrix(){let e=this.getScene();if(!e)return this._cachedReflectionTextureMatrix;if(this.uOffset===this._cachedReflectionUOffset&&this.vOffset===this._cachedReflectionVOffset&&this.uScale===this._cachedReflectionUScale&&this.vScale===this._cachedReflectionVScale&&this.coordinatesMode===this._cachedReflectionCoordinatesMode){if(this.coordinatesMode!==g.PROJECTION_MODE)return this._cachedReflectionTextureMatrix;else if(this._cachedReflectionProjectionMatrixId===e.getProjectionMatrix().updateFlag)return this._cachedReflectionTextureMatrix}this._cachedReflectionTextureMatrix||(this._cachedReflectionTextureMatrix=s.Matrix.Zero()),this._projectionModeMatrix||(this._projectionModeMatrix=s.Matrix.Zero());let t=this._cachedReflectionCoordinatesMode!==this.coordinatesMode;switch(this._cachedReflectionUOffset=this.uOffset,this._cachedReflectionVOffset=this.vOffset,this._cachedReflectionUScale=this.uScale,this._cachedReflectionVScale=this.vScale,this._cachedReflectionCoordinatesMode=this.coordinatesMode,this.coordinatesMode){case g.PLANAR_MODE:s.Matrix.IdentityToRef(this._cachedReflectionTextureMatrix),this._cachedReflectionTextureMatrix[0]=this.uScale,this._cachedReflectionTextureMatrix[5]=this.vScale,this._cachedReflectionTextureMatrix[12]=this.uOffset,this._cachedReflectionTextureMatrix[13]=this.vOffset;break;case g.PROJECTION_MODE:{s.Matrix.FromValuesToRef(.5,0,0,0,0,-.5,0,0,0,0,0,0,.5,.5,1,1,this._projectionModeMatrix);let t=e.getProjectionMatrix();this._cachedReflectionProjectionMatrixId=t.updateFlag,t.multiplyToRef(this._projectionModeMatrix,this._cachedReflectionTextureMatrix);break}default:s.Matrix.IdentityToRef(this._cachedReflectionTextureMatrix)}return t&&e.markAllMaterialsAsDirty(1,e=>e.hasTexture(this)),this._cachedReflectionTextureMatrix}clone(){let e={noMipmap:this._noMipmap,invertY:this._invertY,samplingMode:this.samplingMode,onLoad:void 0,onError:void 0,buffer:this._texture?this._texture._buffer:void 0,deleteBuffer:this._deleteBuffer,format:this.textureFormat,mimeType:this.mimeType,loaderOptions:this._loaderOptions,creationFlags:this._creationFlags,useSRGBBuffer:this._useSRGBBuffer};return f.SerializationHelper.Clone(()=>new g(this._texture?this._texture.url:null,this.getScene(),e),this)}serialize(){let e=this.name;!g.SerializeBuffers&&this.name.startsWith("data:")&&(this.name=""),this.name.startsWith("data:")&&this.url===this.name&&(this.url="");let t=super.serialize(g._SerializeInternalTextureUniqueId);if(!t)return null;if(g.SerializeBuffers||g.ForceSerializeBuffers)if("string"==typeof this._buffer&&this._buffer.startsWith("data:"))t.base64String=this._buffer,t.name=t.name.replace("data:","");else if(this.url&&this.url.startsWith("data:")&&this._buffer instanceof Uint8Array){let e=this.mimeType||"image/png";t.base64String=`data:${e};base64,${(0,_.EncodeArrayBufferToBase64)(this._buffer)}`}else(g.ForceSerializeBuffers||this.url&&this.url.startsWith("blob:")||this._forceSerialize)&&(t.base64String=!this._engine||this._engine._features.supportSyncTextureRead?d(this):x(this));return t.invertY=this._invertY,t.samplingMode=this.samplingMode,t._creationFlags=this._creationFlags,t._useSRGBBuffer=this._useSRGBBuffer,g._SerializeInternalTextureUniqueId&&(t.internalTextureUniqueId=this._texture?.uniqueId),t.internalTextureLabel=this._texture?.label,t.noMipmap=this._noMipmap,this.name=e,t}getClassName(){return"Texture"}dispose(){super.dispose(),this.onLoadObservable.clear(),this._delayedOnLoad=null,this._delayedOnError=null,this._buffer=null}static Parse(e,t,i){let r;if(e.customType){let r=l.InstantiationTools.Instantiate(e.customType).Parse(e,t,i);return e.samplingMode&&r.updateSamplingMode&&r._samplingMode&&r._samplingMode!==e.samplingMode&&r.updateSamplingMode(e.samplingMode),r}if(e.isCube&&!e.isRenderTarget)return g._CubeTextureParser(e,t,i);let s=void 0!==e.internalTextureUniqueId;if(!e.name&&!e.isRenderTarget&&!s)return null;if(s){for(let i of t.getEngine().getLoadedTexturesCache())if(i.uniqueId===e.internalTextureUniqueId){r=i;break}}let a=t=>{if(t&&t._texture&&(t._texture._cachedWrapU=null,t._texture._cachedWrapV=null,t._texture._cachedWrapR=null),e.samplingMode){let i=e.samplingMode;t&&t.samplingMode!==i&&t.updateSamplingMode(i)}if(t&&e.animations)for(let i=0;i<e.animations.length;i++){let r=e.animations[i],s=(0,n.GetClass)("BABYLON.Animation");s&&t.animations.push(s.Parse(r))}t&&t._texture&&(s&&!r&&t._texture._setUniqueId(e.internalTextureUniqueId),t._texture.label=e.internalTextureLabel)};return f.SerializationHelper.Parse(()=>{let s=!0;if(e.noMipmap&&(s=!1),e.mirrorPlane){let i=g._CreateMirror(e.name,e.renderTargetSize,t,s);return i._waitingRenderList=e.renderList,i.mirrorPlane=u.Plane.FromArray(e.mirrorPlane),a(i),i}if(e.isRenderTarget&&!e.base64String){let i=null;if(e.isCube){if(t.reflectionProbes)for(let i=0;i<t.reflectionProbes.length;i++){let r=t.reflectionProbes[i];if(r.name===e.name)return r.cubeTexture}}else(i=g._CreateRenderTargetTexture(e.name,e.renderTargetSize,t,s,e._creationFlags??0))._waitingRenderList=e.renderList;return a(i),i}if(e.isVideo){let r=g._CreateVideoTexture(i+(e.url||e.name),i+(e.src||e.url),t,s,e.invertY,e.samplingMode,e.settings||{});return a(r),r}{let n;if("string"==typeof e.base64String&&e.base64String&&!r){let i={buffer:e.base64String,noMipmap:!s,invertY:e.invertY,samplingMode:e.samplingMode,useSRGBBuffer:e._useSRGBBuffer??!1,creationFlags:e._creationFlags??0,onLoad:()=>{a(n)}},r=e.base64String,h=r.startsWith("data:")?r.substring(5):r;(n=g.CreateFromBase64String("",h,t,i)).name=e.name}else{let h;h=e.name&&(e.name.indexOf("://")>0||e.name.startsWith("data:"))?e.name:i+e.name,e.url&&(e.url.startsWith("data:")||g.UseSerializedUrlIfAny)&&(h=e.url),n=new g(h,t,{noMipmap:!s,invertY:e.invertY,samplingMode:e.samplingMode,useSRGBBuffer:e._useSRGBBuffer??!1,creationFlags:e._creationFlags??0,onLoad:()=>{a(n)},internalTexture:r})}return n}},e,t)}static CreateFromBase64String(e,t,i,r,s,a=g.TRILINEAR_SAMPLINGMODE,n=null,h=null,o=5,l,u){return new g("data:"+t,i,r,s,a,n,h,e,!1,o,void 0,void 0,l,u)}static LoadFromDataString(e,t,i,r=!1,s,a=!0,n=g.TRILINEAR_SAMPLINGMODE,h=null,o=null,l=5,u,_){return"data:"!==e.substring(0,5)&&(e="data:"+e),new g(e,i,s,a,n,h,o,t,r,l,void 0,void 0,u,_)}}g.SerializeBuffers=!0,g.ForceSerializeBuffers=!1,g.OnTextureLoadErrorObservable=new r.Observable,g._SerializeInternalTextureUniqueId=!1,g._CubeTextureParser=(e,t,i)=>{throw(0,h._WarnImport)("CubeTexture")},g._CreateMirror=(e,t,i,r)=>{throw(0,h._WarnImport)("MirrorTexture")},g._CreateRenderTargetTexture=(e,t,i,r,s)=>{throw(0,h._WarnImport)("RenderTargetTexture")},g.NEAREST_SAMPLINGMODE=1,g.NEAREST_NEAREST_MIPLINEAR=8,g.BILINEAR_SAMPLINGMODE=2,g.LINEAR_LINEAR_MIPNEAREST=11,g.TRILINEAR_SAMPLINGMODE=3,g.LINEAR_LINEAR_MIPLINEAR=3,g.NEAREST_NEAREST_MIPNEAREST=4,g.NEAREST_LINEAR_MIPNEAREST=5,g.NEAREST_LINEAR_MIPLINEAR=6,g.NEAREST_LINEAR=7,g.NEAREST_NEAREST=1,g.LINEAR_NEAREST_MIPNEAREST=9,g.LINEAR_NEAREST_MIPLINEAR=10,g.LINEAR_LINEAR=2,g.LINEAR_NEAREST=12,g.EXPLICIT_MODE=0,g.SPHERICAL_MODE=1,g.PLANAR_MODE=2,g.CUBIC_MODE=3,g.PROJECTION_MODE=4,g.SKYBOX_MODE=5,g.INVCUBIC_MODE=6,g.EQUIRECTANGULAR_MODE=7,g.FIXED_EQUIRECTANGULAR_MODE=8,g.FIXED_EQUIRECTANGULAR_MIRRORED_MODE=9,g.CLAMP_ADDRESSMODE=0,g.WRAP_ADDRESSMODE=1,g.MIRROR_ADDRESSMODE=2,g.UseSerializedUrlIfAny=!1,(0,t.__decorate)([(0,i.serialize)()],g.prototype,"url",void 0),(0,t.__decorate)([(0,i.serialize)()],g.prototype,"uOffset",void 0),(0,t.__decorate)([(0,i.serialize)()],g.prototype,"vOffset",void 0),(0,t.__decorate)([(0,i.serialize)()],g.prototype,"uScale",void 0),(0,t.__decorate)([(0,i.serialize)()],g.prototype,"vScale",void 0),(0,t.__decorate)([(0,i.serialize)()],g.prototype,"uAng",void 0),(0,t.__decorate)([(0,i.serialize)()],g.prototype,"vAng",void 0),(0,t.__decorate)([(0,i.serialize)()],g.prototype,"wAng",void 0),(0,t.__decorate)([(0,i.serialize)()],g.prototype,"uRotationCenter",void 0),(0,t.__decorate)([(0,i.serialize)()],g.prototype,"vRotationCenter",void 0),(0,t.__decorate)([(0,i.serialize)()],g.prototype,"wRotationCenter",void 0),(0,t.__decorate)([(0,i.serialize)()],g.prototype,"homogeneousRotationInUVTransform",void 0),(0,t.__decorate)([(0,i.serialize)()],g.prototype,"isBlocking",null);let m=!1;e.s(["RegisterTexture",0,function(){m||(m=!0,(0,n.RegisterClass)("BABYLON.Texture",g),f.SerializationHelper._TextureParser=g.Parse)},"Texture",0,g],67374)}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,16475,e=>{"use strict";var t=e.i(38677);class r{static GetPlanes(e){let s=[];for(let e=0;e<6;e++)s.push(new t.Plane(0,0,0,0));return r.GetPlanesToRef(e,s),s}static GetNearPlaneToRef(e,t){let r=e.m;t.normal.x=r[3]+r[2],t.normal.y=r[7]+r[6],t.normal.z=r[11]+r[10],t.d=r[15]+r[14],t.normalize()}static GetFarPlaneToRef(e,t){let r=e.m;t.normal.x=r[3]-r[2],t.normal.y=r[7]-r[6],t.normal.z=r[11]-r[10],t.d=r[15]-r[14],t.normalize()}static GetLeftPlaneToRef(e,t){let r=e.m;t.normal.x=r[3]+r[0],t.normal.y=r[7]+r[4],t.normal.z=r[11]+r[8],t.d=r[15]+r[12],t.normalize()}static GetRightPlaneToRef(e,t){let r=e.m;t.normal.x=r[3]-r[0],t.normal.y=r[7]-r[4],t.normal.z=r[11]-r[8],t.d=r[15]-r[12],t.normalize()}static GetTopPlaneToRef(e,t){let r=e.m;t.normal.x=r[3]-r[1],t.normal.y=r[7]-r[5],t.normal.z=r[11]-r[9],t.d=r[15]-r[13],t.normalize()}static GetBottomPlaneToRef(e,t){let r=e.m;t.normal.x=r[3]+r[1],t.normal.y=r[7]+r[5],t.normal.z=r[11]+r[9],t.d=r[15]+r[13],t.normalize()}static GetPlanesToRef(e,t){r.GetNearPlaneToRef(e,t[0]),r.GetFarPlaneToRef(e,t[1]),r.GetLeftPlaneToRef(e,t[2]),r.GetRightPlaneToRef(e,t[3]),r.GetTopPlaneToRef(e,t[4]),r.GetBottomPlaneToRef(e,t[5])}static IsPointInFrustum(e,t){for(let r=0;r<6;r++)if(0>t[r].dotCoordinate(e))return!1;return!0}}e.s(["Frustum",0,r])},66476,e=>{"use strict";var t=e.i(10534),r=e.i(65703);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,s=!0){let a;if(!this.pickedMesh||s&&!this.pickedMesh.isVerticesDataPresent(r.VertexBuffer.NormalKind))return null;let i=this.pickedMesh.getIndices();i?.length===0&&(i=null);let n=t.TmpVectors.Vector3[0],o=t.TmpVectors.Vector3[1],l=t.TmpVectors.Vector3[2];if(s){let e=this.pickedMesh.getVerticesData(r.VertexBuffer.NormalKind),s=i?t.Vector3.FromArrayToRef(e,3*i[3*this.faceId],n):n.copyFromFloats(e[3*this.faceId*3],e[3*this.faceId*3+1],e[3*this.faceId*3+2]),h=i?t.Vector3.FromArrayToRef(e,3*i[3*this.faceId+1],o):o.copyFromFloats(e[(3*this.faceId+1)*3],e[(3*this.faceId+1)*3+1],e[(3*this.faceId+1)*3+2]),p=i?t.Vector3.FromArrayToRef(e,3*i[3*this.faceId+2],l):l.copyFromFloats(e[(3*this.faceId+2)*3],e[(3*this.faceId+2)*3+1],e[(3*this.faceId+2)*3+2]);s=s.scale(this.bu),h=h.scale(this.bv),p=p.scale(1-this.bu-this.bv),a=new t.Vector3(s.x+h.x+p.x,s.y+h.y+p.y,s.z+h.z+p.z)}else{let e=this.pickedMesh.getVerticesData(r.VertexBuffer.PositionKind),s=i?t.Vector3.FromArrayToRef(e,3*i[3*this.faceId],n):n.copyFromFloats(e[3*this.faceId*3],e[3*this.faceId*3+1],e[3*this.faceId*3+2]),h=i?t.Vector3.FromArrayToRef(e,3*i[3*this.faceId+1],o):o.copyFromFloats(e[(3*this.faceId+1)*3],e[(3*this.faceId+1)*3+1],e[(3*this.faceId+1)*3+2]),p=i?t.Vector3.FromArrayToRef(e,3*i[3*this.faceId+2],l):l.copyFromFloats(e[(3*this.faceId+2)*3],e[(3*this.faceId+2)*3+1],e[(3*this.faceId+2)*3+2]),c=s.subtract(h),u=p.subtract(h);a=t.Vector3.Cross(c,u)}let h=(e,r)=>{if(-1!==this.thinInstanceIndex){let s=e._thinInstanceDataStorage.matrixData,a=this.thinInstanceIndex<<4;if(s&&s.length>a){let e=t.TmpVectors.Matrix[0];t.Matrix.FromArrayToRef(s,a,e),t.Vector3.TransformNormalToRef(r,e,r)}}let s=e.getWorldMatrix();e.nonUniformScaling&&(t.TmpVectors.Matrix[0].copyFrom(s),(s=t.TmpVectors.Matrix[0]).setTranslationFromFloats(0,0,0),s.invert(),s.transposeToRef(t.TmpVectors.Matrix[1]),s=t.TmpVectors.Matrix[1]),t.Vector3.TransformNormalToRef(r,s,r)};if(e&&h(this.pickedMesh,a),this.ray){let r=t.TmpVectors.Vector3[0].copyFrom(a);e||h(this.pickedMesh,r),t.Vector3.Dot(r,this.ray.direction)>0&&a.negateInPlace()}return a.normalize(),a}getTextureCoordinates(e=r.VertexBuffer.UVKind){if(!this.pickedMesh||!this.pickedMesh.isVerticesDataPresent(e))return null;let s=this.pickedMesh.getIndices();if(!s)return null;let a=this.pickedMesh.getVerticesData(e);if(!a)return null;let i=t.Vector2.FromArray(a,2*s[3*this.faceId]),n=t.Vector2.FromArray(a,2*s[3*this.faceId+1]),o=t.Vector2.FromArray(a,2*s[3*this.faceId+2]);return i=i.scale(this.bu),n=n.scale(this.bv),o=o.scale(1-this.bu-this.bv),new t.Vector2(i.x+n.x+o.x,i.y+n.y+o.y)}}])},11437,e=>{"use strict";var t=e.i(10534);class r{}r.POINTERDOWN=1,r.POINTERUP=2,r.POINTERMOVE=4,r.POINTERWHEEL=8,r.POINTERPICK=16,r.POINTERTAP=32,r.POINTERDOUBLETAP=64;class s{constructor(e,t){this.type=e,this.event=t}}e.s(["PointerEventTypes",0,r,"PointerInfo",0,class extends s{get pickInfo(){return this._pickInfo||this._generatePickInfo(),this._pickInfo}constructor(e,t,r,s=null){super(e,t),this._pickInfo=r,this._inputManager=s}_generatePickInfo(){this._inputManager&&(this._pickInfo=this._inputManager._pickMove(this.event),this._inputManager._setRayOnPointerInfo(this._pickInfo,this.event),this._inputManager=null)}},"PointerInfoPre",0,class extends s{constructor(e,r,s,a){super(e,r),this.ray=null,this.originalPickingInfo=null,this.skipOnPointerObservable=!1,this.localPosition=new t.Vector2(s,a)}}])},70463,e=>{"use strict";class t{}t.KEYDOWN=1,t.KEYUP=2;class r{constructor(e,t){this.type=e,this.event=t}}e.s(["KeyboardEventTypes",0,t,"KeyboardInfo",0,r,"KeyboardInfoPre",0,class extends r{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}}])},24423,e=>{"use strict";var t,r;(r=t||(t={}))[r.PointerMove=0]="PointerMove",r[r.PointerDown=1]="PointerDown",r[r.PointerUp=2]="PointerUp";class s{}s.DOM_DELTA_PIXEL=0,s.DOM_DELTA_LINE=1,s.DOM_DELTA_PAGE=2,e.s(["EventConstants",0,s])},93357,29665,e=>{"use strict";var t=e.i(65703),r=e.i(57554);e.s(["PostProcessManager",0,class{constructor(e){this._vertexBuffers={},this._activePostProcesses=[],this.onBeforeRenderObservable=new r.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 r=0;r<e.length;r++){let s=e[r];s&&t.push(s)}return t}_rebuild(){let e=this._vertexBuffers[t.VertexBuffer.PositionKind];e&&(e._rebuild(),this._buildIndexBuffer())}_prepareFrame(e=null,t=null){let r=this._scene.activeCamera;return!!r&&!!(t=t||this._getActivePostProcesses(r._postProcesses))&&0!==t.length&&!!this._scene.postProcessesEnabled&&(t[0].activate(r,e,null!=t),!0)}directRender(e,t=null,r=!1,s=0,a=0,i=!1,n=e.length){let o=this._scene.getEngine();for(let l=0;l<n;l++){l<e.length-1?e[l+1].activate(this._scene.activeCamera||this._scene,t?.texture):(t?o.bindFramebuffer(t,s,void 0,void 0,r,a):i||o.restoreDefaultFramebuffer(),o._debugInsertMarker?.(`post process ${e[l].name} output`));let n=e[l],h=n.apply();h&&(n.onBeforeRenderObservable.notifyObservers(h),this._prepareBuffers(),o.bindBuffers(this._vertexBuffers,this._indexBuffer,h),o.drawElementsType(0,0,6),n.onAfterRenderObservable.notifyObservers(h))}o.setDepthBuffer(!0),o.setDepthWrite(!0)}_finalizeFrame(e,t,r,s,a=!1){let i=this._scene.activeCamera;if(!i||(this.onBeforeRenderObservable.notifyObservers(this),0===(s=s||this._getActivePostProcesses(i._postProcesses)).length||!this._scene.postProcessesEnabled))return;let n=this._scene.getEngine();for(let o=0,l=s.length;o<l;o++){let h=s[o];if(o<l-1?h._outputTexture=s[o+1].activate(i,t?.texture):(t?(n.bindFramebuffer(t,r,void 0,void 0,a),h._outputTexture=t):(n.restoreDefaultFramebuffer(),h._outputTexture=null),n._debugInsertMarker?.(`post process ${s[o].name} output`)),e)break;let p=h.apply();p&&(h.onBeforeRenderObservable.notifyObservers(p),this._prepareBuffers(),n.bindBuffers(this._vertexBuffers,this._indexBuffer,p),n.drawElementsType(0,0,6),h.onAfterRenderObservable.notifyObservers(p))}n.setDepthBuffer(!0),n.setDepthWrite(!0),n.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)}}],93357);var s=e.i(95294),a=e.i(10534);class i{set opaqueSortCompareFn(e){e?this._opaqueSortCompareFn=e:this._opaqueSortCompareFn=i.PainterSortCompare,this._renderOpaque=this._renderOpaqueSorted}set alphaTestSortCompareFn(e){e?this._alphaTestSortCompareFn=e:this._alphaTestSortCompareFn=i.PainterSortCompare,this._renderAlphaTest=this._renderAlphaTestSorted}set transparentSortCompareFn(e){e?this._transparentSortCompareFn=e:this._transparentSortCompareFn=i.defaultTransparentSortCompare,this._renderTransparent=this._renderTransparentSorted}constructor(e,t,r=null,a=null,i=null){this.index=e,this._opaqueSubMeshes=new s.SmartArray(256),this._transparentSubMeshes=new s.SmartArray(256),this._alphaTestSubMeshes=new s.SmartArray(256),this._depthOnlySubMeshes=new s.SmartArray(256),this._particleSystems=new s.SmartArray(256),this._spriteManagers=new s.SmartArray(256),this._empty=!0,this._edgesRenderers=new s.SmartArrayNoDuplicate(16),this.disableDepthPrePass=!1,this._scene=t,this.opaqueSortCompareFn=r,this.alphaTestSortCompareFn=a,this.transparentSortCompareFn=i}render(e,t,r,s,a=!0,i=!0,n=!0,o=!0,l){if(e)return void e(this._opaqueSubMeshes,this._alphaTestSubMeshes,this._transparentSubMeshes,this._depthOnlySubMeshes);let h=this._scene.getEngine();a&&0!==this._depthOnlySubMeshes.length&&(h.setColorWrite(!1),this._renderAlphaTest(this._depthOnlySubMeshes),h.setColorWrite(!0)),i&&0!==this._opaqueSubMeshes.length&&this._renderOpaque(this._opaqueSubMeshes),n&&0!==this._alphaTestSubMeshes.length&&this._renderAlphaTest(this._alphaTestSubMeshes);let p=h.getStencilBuffer();if(h.setStencilBuffer(!1),t&&this._renderSprites(),r&&this._renderParticles(s),this.onBeforeTransparentRendering&&this.onBeforeTransparentRendering(),o&&(l||0!==this._transparentSubMeshes.length||this._scene.useOrderIndependentTransparency)){if(h.setStencilBuffer(p),l)l(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);h.setAlphaMode(0)}if(h.setStencilBuffer(!1),i&&this._edgesRenderers.length){for(let e=0;e<this._edgesRenderers.length;e++)this._edgesRenderers.data[e].render();h.setAlphaMode(0)}h.setStencilBuffer(p)}_renderOpaqueSorted(e){i._RenderSorted(e,this._opaqueSortCompareFn,this._scene.activeCamera,!1,this.disableDepthPrePass)}_renderAlphaTestSorted(e){i._RenderSorted(e,this._alphaTestSortCompareFn,this._scene.activeCamera,!1,this.disableDepthPrePass)}_renderTransparentSorted(e){i._RenderSorted(e,this._transparentSortCompareFn,this._scene.activeCamera,!0,this.disableDepthPrePass)}static _RenderSorted(e,t,r,s,n){let o,l=0,h=r?r.globalPosition:i._ZeroVector;if(s)for(;l<e.length;l++)(o=e.data[l])._alphaIndex=o.getMesh().alphaIndex,o._distanceToCamera=a.Vector3.Distance(o.getBoundingInfo().boundingSphere.centerWorld,h);let p=e.length===e.data.length?e.data:e.data.slice(0,e.length);t&&p.sort(t);let c=p[0].getMesh().getScene();for(l=0;l<p.length;l++)if(o=p[l],!c._activeMeshesFrozenButKeepClipping||o.isInFrustum(c._frustumPlanes)){if(s){let e=o.getMaterial();if(e&&e.needDepthPrePass&&!n){let t=e.getScene().getEngine();t.setColorWrite(!1),t.setAlphaMode(0),o.render(!1),t.setColorWrite(!0)}}o.render(s)}}static defaultTransparentSortCompare(e,t){return e._alphaIndex>t._alphaIndex?1:e._alphaIndex<t._alphaIndex?-1:i.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 r=e.getMesh(),s=t.getMesh();return r.material&&s.material?r.material.uniqueId-s.material.uniqueId:r.uniqueId-s.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,r){void 0===t&&(t=e.getMesh()),void 0===r&&(r=e.getMaterial()),null!=r&&(r.needAlphaBlendingForMesh(t)?this._transparentSubMeshes.push(e):r.needAlphaTestingForMesh(t)?(r.needDepthPrePass&&!this.disableDepthPrePass&&this._depthOnlySubMeshes.push(e),this._alphaTestSubMeshes.push(e)):(r.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 r=0;r<this._particleSystems.length;r++){let s=this._particleSystems.data[r];if(0===(t&&t.layerMask&s.layerMask))continue;let a=s.emitter;a.position&&e&&-1===e.indexOf(a)||this._scene._activeParticles.addCount(s.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 r=this._spriteManagers.data[t];0!==(e&&e.layerMask&r.layerMask)&&r.render()}this._scene.onAfterSpritesRenderingObservable.notifyObservers(this._scene)}}i._ZeroVector=a.Vector3.Zero();class n{}class o{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 n,this._maintainStateBetweenFrames=!1,this._scene=e;for(let e=o.MIN_RENDERINGGROUPS;e<o.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,r,s,a=!0,i=!0,n=!0,l=!0,h){let p=this._renderingGroupInfo;if(p.scene=this._scene,p.camera=this._scene.activeCamera,p.renderingManager=this,this._scene.spriteManagers&&s)for(let e=0;e<this._scene.spriteManagers.length;e++){let t=this._scene.spriteManagers[e];this.dispatchSprites(t)}for(let c=o.MIN_RENDERINGGROUPS;c<o.MAX_RENDERINGGROUPS;c++){this._depthStencilBufferAlreadyCleaned=c===o.MIN_RENDERINGGROUPS;let u=this._renderingGroups[c];if(!u||u._empty)continue;let d=1<<c;if(p.renderingGroupId=c,this._scene.onBeforeRenderingGroupObservable.notifyObservers(p,d),o.AUTOCLEAR){let e=this._useSceneAutoClearSetup?this._scene.getAutoClearDepthStencilSetup(c):this._autoClearDepthStencil[c];e&&e.autoClear&&this._clearDepthStencilBuffer(e.depth,e.stencil)}for(let e of this._scene._beforeRenderingGroupDrawStage)e.action(c);for(let o of(u.render(e,s,r,t,a,i,n,l,h),this._scene._afterRenderingGroupDrawStage))o.action(c);this._scene.onAfterRenderingGroupObservable.notifyObservers(p,d)}}reset(){if(!this.maintainStateBetweenFrames)for(let e=o.MIN_RENDERINGGROUPS;e<o.MAX_RENDERINGGROUPS;e++){let t=this._renderingGroups[e];t&&t.prepare()}}resetSprites(){if(!this.maintainStateBetweenFrames)for(let e=o.MIN_RENDERINGGROUPS;e<o.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=o.MIN_RENDERINGGROUPS;e<o.MAX_RENDERINGGROUPS;e++){let t=this._renderingGroups[e];t&&t.dispose()}}_prepareRenderingGroup(e){void 0===this._renderingGroups[e]&&(this._renderingGroups[e]=new i(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,r){void 0===t&&(t=e.getMesh()),this.maintainStateBetweenFrames&&e._wasDispatched||(e._wasDispatched=!0,this.getRenderingGroup(t.renderingGroupId).dispatch(e,t,r))}setRenderingOrder(e,t=null,r=null,s=null){if(this._customOpaqueSortCompareFn[e]=t,this._customAlphaTestSortCompareFn[e]=r,this._customTransparentSortCompareFn[e]=s,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,r=!0,s=!0){this._autoClearDepthStencil[e]={autoClear:t,depth:r,stencil:s}}getAutoClearDepthStencilSetup(e){return this._autoClearDepthStencil[e]}}o.MAX_RENDERINGGROUPS=4,o.MIN_RENDERINGGROUPS=0,o.AUTOCLEAR=!0,e.s(["RenderingManager",0,o],29665)},89102,e=>{"use strict";var t=e.i(10534),r=e.i(35270),s=e.i(12247),a=e.i(26722),i=e.i(75053);class n{constructor(e,t,r,s){this.name=e,this.worldAxisForNormal=t,this.worldAxisForFileX=r,this.worldAxisForFileY=s}}class o{static _NearestPow2Floor(e){return e<=1?1:1<<Math.floor(Math.log2(e))}static ConvertCubeMapTextureToSphericalPolynomial(e){let t,r;if(!e.isCube)return null;e.getScene()?.getEngine().flushFramebuffer();let s=e.getSize().width,a=e._sphericalPolynomialTargetSize,i=a>0?this._NearestPow2Floor(a):0,n=!e.noMipmap&&e._texture?.generateMipMaps===!0,o=i>0&&i<s&&n,l=o?Math.max(0,Math.round(Math.log2(s/i))):0,h=o?Math.max(1,Math.floor(s/Math.pow(2,l))):s,p=e.readPixels(0,l,void 0,!1),c=e.readPixels(1,l,void 0,!1);e.isRenderTarget?(t=e.readPixels(3,l,void 0,!1),r=e.readPixels(2,l,void 0,!1)):(t=e.readPixels(2,l,void 0,!1),r=e.readPixels(3,l,void 0,!1));let u=e.readPixels(4,l,void 0,!1),d=e.readPixels(5,l,void 0,!1),f=e.gammaSpace,m=i>0&&i<s&&!o;return new Promise(e=>{Promise.all([c,p,t,r,u,d]).then(([t,r,a,n,o,l])=>{let p=h;m&&(t=this._DownsampleFace(t,s,i,4),r=this._DownsampleFace(r,s,i,4),a=this._DownsampleFace(a,s,i,4),n=this._DownsampleFace(n,s,i,4),o=this._DownsampleFace(o,s,i,4),l=this._DownsampleFace(l,s,i,4),p=i);let c={size:p,right:r,left:t,up:a,down:n,front:o,back:l,format:5,type:+(t instanceof Float32Array),gammaSpace:f};e(this.ConvertCubeMapToSphericalPolynomial(c))})})}static _AreaElement(e,t){return Math.atan2(e*t,Math.sqrt(e*e+t*t+1))}static _DownsampleFace(e,t,r,s){let a=e instanceof Float32Array?e:Float32Array.from(e),i=r*r*s,n=new Float32Array(i),o=t/r,l=1/(o*o);for(let e=0;e<r;e++){let i=Math.floor(e*o),h=Math.floor((e+1)*o);for(let p=0;p<r;p++){let c=Math.floor(p*o),u=Math.floor((p+1)*o),d=(e*r+p)*s;for(let e=0;e<s;e++){let r=0;for(let n=i;n<h;n++)for(let i=c;i<u;i++)r+=a[(n*t+i)*s+e];n[d+e]=r*l}}}if(e instanceof Float32Array)return n;let h=new e.constructor(i);for(let e=0;e<i;e++)h[e]=n[e]+.5|0;return h}static ConvertCubeMapToSphericalPolynomial(e,t=0){let n=t>0?this._NearestPow2Floor(t):0;if(n>0&&e.size>n){let t=5===e.format?4:3,r={};for(let s of["right","left","up","down","front","back"])r[s]=this._DownsampleFace(e[s],e.size,n,t);e={...e,...r,size:n}}let o=new s.SphericalHarmonics,l=0,h=2/e.size,p=.5*h,c=p-1;for(let t=0;t<6;t++){let s=this._FileFaces[t],n=e[s.name],u=c,d=5===e.format?4:3;for(let t=0;t<e.size;t++){let f=c;for(let c=0;c<e.size;c++){let m=s.worldAxisForFileX.scale(f).add(s.worldAxisForFileY.scale(u)).add(s.worldAxisForNormal);m.normalize();let _=this._AreaElement(f-p,u-p)-this._AreaElement(f-p,u+p)-this._AreaElement(f+p,u-p)+this._AreaElement(f+p,u+p),g=n[t*e.size*d+c*d+0],y=n[t*e.size*d+c*d+1],b=n[t*e.size*d+c*d+2];isNaN(g)&&(g=0),isNaN(y)&&(y=0),isNaN(b)&&(b=0),0===e.type&&(g/=255,y/=255,b/=255),e.gammaSpace&&(g=Math.pow((0,r.Clamp)(g),a.ToLinearSpace),y=Math.pow((0,r.Clamp)(y),a.ToLinearSpace),b=Math.pow((0,r.Clamp)(b),a.ToLinearSpace));let P=this.MAX_HDRI_VALUE;if(this.PRESERVE_CLAMPED_COLORS){let e=Math.max(g,y,b);if(e>P){let t=P/e;g*=t,y*=t,b*=t}}else g=(0,r.Clamp)(g,0,P),y=(0,r.Clamp)(y,0,P),b=(0,r.Clamp)(b,0,P);let S=new i.Color3(g,y,b);o.addLight(m,S,_),l+=_,f+=h}u+=h}}let u=4*Math.PI*6/6/l;return o.scaleInPlace(u),o.convertIncidentRadianceToIrradiance(),o.convertIrradianceToLambertianRadiance(),s.SphericalPolynomial.FromHarmonics(o)}}o._FileFaces=[new n("right",new t.Vector3(1,0,0),new t.Vector3(0,0,-1),new t.Vector3(0,-1,0)),new n("left",new t.Vector3(-1,0,0),new t.Vector3(0,0,1),new t.Vector3(0,-1,0)),new n("up",new t.Vector3(0,1,0),new t.Vector3(1,0,0),new t.Vector3(0,0,1)),new n("down",new t.Vector3(0,-1,0),new t.Vector3(1,0,0),new t.Vector3(0,0,-1)),new n("front",new t.Vector3(0,0,1),new t.Vector3(1,0,0),new t.Vector3(0,-1,0)),new n("back",new t.Vector3(0,0,-1),new t.Vector3(-1,0,0),new t.Vector3(0,-1,0))],o.MAX_HDRI_VALUE=4096,o.PRESERVE_CLAMPED_COLORS=!1,e.s(["CubeMapToSphericalPolynomialTools",0,o])},93701,e=>{"use strict";var t=e.i(16147),r=e.i(44988),s=e.i(29711),a=e.i(35270),i=e.i(47867),n=e.i(83464),o=e.i(61023),l=e.i(40220);let h=null;async function p(){let t=i.EngineStore.LastCreatedEngine?.createCanvas(100,100)??new OffscreenCanvas(100,100);t instanceof OffscreenCanvas&&n.Logger.Warn("DumpData: OffscreenCanvas will be used for dumping data. This may result in lossy alpha values.");let{ThinEngine:s}=await e.A(14235);if(!s.IsSupported)throw Error("DumpData: No WebGL context available. Cannot dump data.");let a=new s(t,!1,{preserveDrawingBuffer:!0,depth:!1,stencil:!1,alpha:!0,premultipliedAlpha:!1,antialias:!1,failIfMajorPerformanceCaveat:!1});i.EngineStore.Instances.pop(),i.EngineStore.OnEnginesDisposedObservable.add(e=>{a&&e!==a&&!a.isDisposed&&0===i.EngineStore.Instances.length&&g()}),a.getCaps().parallelShaderCompile=void 0;let o=new r.EffectRenderer(a),{passPixelShader:l}=await e.A(23899),h=new r.EffectWrapper({engine:a,name:l.name,fragmentShader:l.shader,samplerNames:["textureSampler"]});return{canvas:t,dumpEngine:{engine:a,renderer:o,wrapper:h}}}async function c(){return h||(h=p()),await h}class u{static async EncodeImageAsync(e,t,r,a,i,n){let o=await c(),l=o.dumpEngine;l.engine.setSize(t,r,!0);let h=l.engine.createRawTexture(e,t,r,5,!1,!i,1);return l.renderer.setViewport(),l.renderer.applyEffectWrapper(l.wrapper),l.wrapper.effect._bindTexture("textureSampler",h),l.renderer.draw(),h.dispose(),await new Promise((e,t)=>{s.Tools.ToBlob(o.canvas,r=>{r?e(r):t(Error("EncodeImageAsync: Failed to convert canvas to blob."))},a,n)})}}(0,t.__decorate)([l.nativeOverride],u,"EncodeImageAsync",null);let d=u.EncodeImageAsync;async function f(e,t,r,s,a="image/png",i,n){let o=new Uint8Array((await r.readPixels(0,0,e,t)).buffer);_(e,t,o,s,a,i,!0,void 0,n)}async function m(e,t,r,i="image/png",l,h=!1,p=!1,c){if(r instanceof Float32Array){let e=new Uint8Array(r.length),t=r.length;for(;t--;){let s=r[t];e[t]=Math.round(255*(0,a.Clamp)(s))}r=e}let d=await u.EncodeImageAsync(r,e,t,i,h,c);void 0!==l&&s.Tools.DownloadBlob(d,l),d.type!==i&&n.Logger.Warn(`DumpData: The requested mimeType '${i}' is not supported. The result has mimeType '${d.type}' instead.`);let f=await d.arrayBuffer();return p?f:`data:${i};base64,${(0,o.EncodeArrayBufferToBase64)(f)}`}function _(e,t,r,s,a="image/png",i,n=!1,o=!1,l){void 0!==i||s||(i=""),m(e,t,r,a,i,n,o,l).then(e=>{s&&s(e)})}function g(){h&&(h?.then(e=>{e.canvas instanceof HTMLCanvasElement&&e.canvas.remove(),e.dumpEngine&&(e.dumpEngine.engine.dispose(),e.dumpEngine.renderer.dispose(),e.dumpEngine.wrapper.dispose())}),h=null)}let y=!1;e.s(["Dispose",0,g,"DumpData",0,_,"DumpDataAsync",0,m,"DumpFramebuffer",0,f,"DumpTools",0,{DumpData:_,DumpDataAsync:m,DumpFramebuffer:f,Dispose:g},"EncodeImageAsync",0,d,"RegisterDumpTools",0,function(){y||(y=!0,s.Tools.DumpData=_,s.Tools.DumpDataAsync=m,s.Tools.DumpFramebuffer=f)}])},84658,e=>{"use strict";var t=e.i(65679),r=e.i(10534),s=e.i(35270),a=e.i(12247),i=e.i(58727),n=e.i(68061),o=(e.i(56770),e.i(41190)),l=e.i(83464),h=e.i(13456),p=e.i(93701),c=e.i(5512);let u="image/png",d=[134,22,135,150,246,214,150,54];function f(e){if(e.version>2)throw Error(`Unsupported babylon environment map version "${e.version}". Latest supported version is "2".`);return 2===e.version?e:e={...e,version:2,imageType:u}}async function m(e,t,r,s,a,i,n,o,l,h,p){return await new Promise((c,u)=>{if(r){let r=t.createTexture(null,!0,!0,null,1,null,e=>{u(e)},e);s?.onEffectCreatedObservable.addOnce(o=>{o.executeWhenCompiled(()=>{s.externalTextureSamplerBinding=!0,s.onApply=s=>{s._bindTexture("textureSampler",r),s.setFloat2("scale",1,t._features.needsInvertingBitmap&&e instanceof ImageBitmap?-1:1)},t.scenes.length&&(t.scenes[0].postProcessManager.directRender([s],h,!0,i,n),t.restoreDefaultFramebuffer(),r.dispose(),URL.revokeObjectURL(a),c())})})}else{if(t._uploadImageToTexture(p,e,i,n),o){let r=l[n];r&&t._uploadImageToTexture(r._texture,e,i,0)}c()}})}async function _(e,t,r=u){let s=e.getEngine();e.format=5,e.type=0,e.generateMipMaps=!0,e._cachedAnisotropicFilteringLevel=null,s.updateTextureSamplingMode(3,e),await y(e,t,!0,r),e.isReady=!0}async function g(e,t,r,s=u,a=null){let o=e.getEngine(),l=new i.InternalTexture(o,5),h=new n.BaseTexture(o,l);e._irradianceTexture=h,h._dominantDirection=a,l.isCube=!0,l.format=5,l.type=0,l.generateMipMaps=!0,l._cachedAnisotropicFilteringLevel=null,l.generateMipMaps=!0,l.width=r,l.height=r,o.updateTextureSamplingMode(3,l),await y(l,[t],!1,s),o.generateMipMapsForCubemap(l),l.isReady=!0}async function y(r,a,l,h=u){if(!(0,t.IsExponentOfTwo)(r.width))throw Error("Texture size must be a power of two");let p=(0,s.ILog2)(r.width)+1,d=r.getEngine(),f=!1,_=!1,g=null,b=null,P=null,S=d.getCaps();S.textureLOD?d._features.supportRenderAndCopyToLodForFloatTextures?S.textureHalfFloatRender&&S.textureHalfFloatLinearFiltering?(f=!0,r.type=2):S.textureFloatRender&&S.textureFloatLinearFiltering&&(f=!0,r.type=1):f=!1:(f=!1,_=l);let T=0;if(f)d.isWebGPU?(T=1,await e.A(40343)):await e.A(50570),g=new o.PostProcess("rgbdDecode","rgbdDecode",null,null,1,null,3,d,!1,void 0,r.type,void 0,null,!1,void 0,T),r._isRGBD=!1,r.invertY=!1,b=d.createRenderTargetCubeTexture(r.width,{generateDepthBuffer:!1,generateMipMaps:!0,generateStencilBuffer:!1,samplingMode:3,type:r.type,format:5});else if(r._isRGBD=!0,r.invertY=!0,_){P={};let e=r._lodGenerationScale,t=r._lodGenerationOffset;for(let s=0;s<3;s++){let a=(p-1)*e+t,o=Math.round(Math.min(Math.max(t+(a-t)*(1-s/2),0),a)),l=new i.InternalTexture(d,2);l.isCube=!0,l.invertY=!0,l.generateMipMaps=!1,d.updateTextureSamplingMode(2,l);let h=new n.BaseTexture(null);switch(h._isCube=!0,h._texture=l,P[o]=h,s){case 0:r._lodTextureLow=h;break;case 1:r._lodTextureMid=h;break;case 2:r._lodTextureHigh=h}}}let v=[];for(let e=0;e<a.length;e++)for(let t=0;t<6;t++){let s,i=a[e][t],n=new Blob([(0,c.GetBlobBufferSource)(i)],{type:h}),o=URL.createObjectURL(n);if(d._features.forceBitmapOverHTMLImageElement)s=d.createImageBitmap(n,{premultiplyAlpha:"none",colorSpaceConversion:"none"}).then(async s=>await m(s,d,f,g,o,t,e,_,P,b,r));else{let a=new Image;a.src=o,s=new Promise((s,i)=>{a.onload=()=>{m(a,d,f,g,o,t,e,_,P,b,r).then(()=>s()).catch(e=>{i(e)})},a.onerror=e=>{i(e)}})}v.push(s)}if(await Promise.all(v),a.length<p){let e,t=Math.pow(2,p-1-a.length),s=t*t*4;switch(r.type){case 0:e=new Uint8Array(s);break;case 2:e=new Uint16Array(s);break;case 1:e=new Float32Array(s)}for(let t=a.length;t<p;t++)for(let s=0;s<6;s++)d._uploadArrayBufferViewToTexture(b?.texture||r,e,s,t)}if(b){let e=r._irradianceTexture;r._irradianceTexture=null,d._releaseTexture(r),b._swapAndDie(r),r._irradianceTexture=e}g&&g.dispose(),_&&(r._lodTextureHigh&&r._lodTextureHigh._texture&&(r._lodTextureHigh._texture.isReady=!0),r._lodTextureMid&&r._lodTextureMid._texture&&(r._lodTextureMid._texture.isReady=!0),r._lodTextureLow&&r._lodTextureLow._texture&&(r._lodTextureLow._texture.isReady=!0))}e.s(["GetEnvInfo",0,function(e){let t,r=new DataView(e.buffer,e.byteOffset,e.byteLength),s=0;for(let e=0;e<d.length;e++)if(r.getUint8(s++)!==d[e])return l.Logger.Error("Not a babylon environment map"),null;let a="";for(;t=r.getUint8(s++);)a+=String.fromCharCode(t);let i=JSON.parse(a);return(i=f(i)).binaryDataPosition=s,i.specular&&(i.specular.lodGenerationScale=i.specular.lodGenerationScale||.8),i},"UploadEnvLevelsAsync",0,function(e,t,s){let a=(s=f(s)).specular;if(!a)return Promise.resolve([]);e._lodGenerationScale=a.lodGenerationScale;let i=[],n=function(e,t){let r=(t=f(t)).specular,s=Math.log2(t.width);if(s=Math.round(s)+1,r.mipmaps.length!==6*s)throw Error(`Unsupported specular mipmaps number "${r.mipmaps.length}"`);let a=Array(s);for(let i=0;i<s;i++){a[i]=Array(6);for(let s=0;s<6;s++){let n=r.mipmaps[6*i+s];a[i][s]=new Uint8Array(e.buffer,e.byteOffset+t.binaryDataPosition+n.position,n.length)}}return a}(t,s);i.push(_(e,n,s.imageType));let o=s.irradiance?.irradianceTexture;if(o){let a=function(e,t){t=f(t);let r=Array(6),s=t.irradiance?.irradianceTexture;if(s){if(6!==s.faces.length)throw Error(`Incorrect irradiance texture faces number "${s.faces.length}"`);for(let a=0;a<6;a++){let i=s.faces[a];r[a]=new Uint8Array(e.buffer,e.byteOffset+t.binaryDataPosition+i.position,i.length)}}return r}(t,s),n=null;s.irradiance?.irradianceTexture?.dominantDirection&&(n=r.Vector3.FromArray(s.irradiance.irradianceTexture.dominantDirection)),i.push(g(e,a,o.size,s.imageType,n))}return Promise.all(i)},"UploadEnvSpherical",0,function(e,t){let s=(t=f(t)).irradiance;if(!s)return;let i=new a.SphericalPolynomial;r.Vector3.FromArrayToRef(s.x,0,i.x),r.Vector3.FromArrayToRef(s.y,0,i.y),r.Vector3.FromArrayToRef(s.z,0,i.z),r.Vector3.FromArrayToRef(s.xx,0,i.xx),r.Vector3.FromArrayToRef(s.yy,0,i.yy),r.Vector3.FromArrayToRef(s.zz,0,i.zz),r.Vector3.FromArrayToRef(s.yz,0,i.yz),r.Vector3.FromArrayToRef(s.zx,0,i.zx),r.Vector3.FromArrayToRef(s.xy,0,i.xy),e._sphericalPolynomial=i},"_UpdateRGBDAsync",0,function(e,t,r,s,a){let i=_(e.getEngine().createRawCubeTexture(null,e.width,e.format,e.type,e.generateMipMaps,e.invertY,e.samplingMode,e._compression),t).then(()=>e);return e.onRebuildCallback=e=>({proxy:i,isReady:!0,isAsync:!0}),e._source=13,e._bufferViewArrayArray=t,e._lodGenerationScale=s,e._lodGenerationOffset=a,e._sphericalPolynomial=r,_(e,t).then(()=>(e.isReady=!0,e))}])},69384,e=>{"use strict";var t=e.i(84658),r=e.i(89102),s=e.i(68061);let a=!1;e.s(["_ENVTextureLoader",0,class{constructor(){this.supportCascades=!1}loadCubeData(e,i,n,o,l){if(Array.isArray(e))return;let h=(0,t.GetEnvInfo)(e);if(h){i.width=h.width,i.height=h.width;try{a||(a=!0,s.BaseTexture.prototype._sphericalPolynomialTargetSize=0,s.BaseTexture.prototype.forceSphericalPolynomialsRecompute=function(){this._texture&&(this._texture._sphericalPolynomial=null,this._texture._sphericalPolynomialPromise=null,this._texture._sphericalPolynomialComputed=!1)},Object.defineProperty(s.BaseTexture.prototype,"sphericalPolynomial",{get:function(){if(this._texture){if(this._texture._sphericalPolynomial||this._texture._sphericalPolynomialComputed)return this._texture._sphericalPolynomial;this._texture.isReady&&(this._texture._sphericalPolynomialPromise||(this._texture._sphericalPolynomialPromise=r.CubeMapToSphericalPolynomialTools.ConvertCubeMapTextureToSphericalPolynomial(this),null===this._texture._sphericalPolynomialPromise?this._texture._sphericalPolynomialComputed=!0:this._texture._sphericalPolynomialPromise.then(e=>{this._texture._sphericalPolynomial=e,this._texture._sphericalPolynomialComputed=!0})))}return null},set:function(e){this._texture&&(this._texture._sphericalPolynomial=e)},enumerable:!0,configurable:!0})),(0,t.UploadEnvSpherical)(i,h),(0,t.UploadEnvLevelsAsync)(i,e,h).then(()=>{i.isReady=!0,i.onLoadedObservable.notifyObservers(i),i.onLoadedObservable.clear(),o&&o()},e=>{l?.("Can not upload environment levels",e)})}catch(e){l?.("Can not upload environment file",e)}}else l&&l("Can not parse the environment file",null)}loadData(){throw".env not supported in 2d."}}],69384)},88484,e=>{e.v(t=>Promise.all(["static/chunks/1kl5xxohpr6-4.js"].map(t=>e.l(t))).then(()=>t(99916)))},13831,e=>{e.v(t=>Promise.all(["static/chunks/1f92k-xa0pl-3.js"].map(t=>e.l(t))).then(()=>t(86742)))},16301,e=>{e.v(t=>Promise.all(["static/chunks/1-ud6hztxiazp.js"].map(t=>e.l(t))).then(()=>t(57348)))},23899,e=>{e.v(t=>Promise.all(["static/chunks/2dolerz81xb52.js"].map(t=>e.l(t))).then(()=>t(36090)))},17030,e=>{e.v(t=>Promise.all(["static/chunks/2kn_dqzbyabtn.js"].map(t=>e.l(t))).then(()=>t(67861)))},94467,e=>{e.v(t=>Promise.all(["static/chunks/0c2k-gvwph4qs.js"].map(t=>e.l(t))).then(()=>t(31151)))},28636,e=>{e.v(t=>Promise.all(["static/chunks/0mk8tangq9equ.js"].map(t=>e.l(t))).then(()=>t(86828)))},38938,e=>{e.v(t=>Promise.all(["static/chunks/3he9bxsc67ivq.js"].map(t=>e.l(t))).then(()=>t(76530)))},11,e=>{e.v(t=>Promise.all(["static/chunks/22qzld31fbhbv.js"].map(t=>e.l(t))).then(()=>t(82014)))},11326,e=>{e.v(t=>Promise.all(["static/chunks/3sbm1ak54_2ep.js"].map(t=>e.l(t))).then(()=>t(20009)))},79994,e=>{e.v(t=>Promise.all(["static/chunks/2vmybybb3dvia.js"].map(t=>e.l(t))).then(()=>t(16388)))},28348,e=>{e.v(t=>Promise.all(["static/chunks/0x4-zyy8pzmlq.js"].map(t=>e.l(t))).then(()=>t(78529)))},26797,e=>{e.v(t=>Promise.all(["static/chunks/286ggpetqnwyo.js"].map(t=>e.l(t))).then(()=>t(43682)))},50570,e=>{e.v(t=>Promise.all(["static/chunks/1b2tkk7e_2o0k.js"].map(t=>e.l(t))).then(()=>t(93822)))},40343,e=>{e.v(t=>Promise.all(["static/chunks/2dqg85hsevk3c.js"].map(t=>e.l(t))).then(()=>t(7058)))},55967,e=>{e.v(t=>Promise.all(["static/chunks/0zwkmsojeuekb.js"].map(t=>e.l(t))).then(()=>t(79789)))},82777,e=>{e.v(t=>Promise.all(["static/chunks/1rne-b-ktit5c.js"].map(t=>e.l(t))).then(()=>t(60512)))},14235,e=>{e.v(t=>Promise.all(["static/chunks/2f0r-df7tb3pu.js"].map(t=>e.l(t))).then(()=>t(93891)))}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,78619,e=>{"use strict";var t=e.i(16147),i=e.i(40220),s=e.i(816),r=e.i(75053),a=e.i(83464),n=e.i(95294),l=e.i(56770),o=e.i(10534),u=e.i(65703),h=e.i(90551),T=e.i(17619);class _ extends h.MaterialDefines{constructor(){super(...arguments),this.BRDF_V_HEIGHT_CORRELATED=!1,this.MS_BRDF_ENERGY_CONSERVATION=!1,this.SPHERICAL_HARMONICS=!1,this.SPECULAR_GLOSSINESS_ENERGY_CONSERVATION=!1,this.MIX_IBL_RADIANCE_WITH_IRRADIANCE=!0,this.LEGACY_SPECULAR_ENERGY_CONSERVATION=!1,this.BASE_DIFFUSE_MODEL=0,this.DIELECTRIC_SPECULAR_MODEL=0,this.CONDUCTOR_SPECULAR_MODEL=0}}class c extends T.MaterialPluginBase{_markAllSubMeshesAsMiscDirty(){this._internalMarkAllSubMeshesAsMiscDirty()}isCompatible(){return!0}constructor(e,t=!0){super(e,"PBRBRDF",90,new _,t),this._useEnergyConservation=c.DEFAULT_USE_ENERGY_CONSERVATION,this.useEnergyConservation=c.DEFAULT_USE_ENERGY_CONSERVATION,this._useSmithVisibilityHeightCorrelated=c.DEFAULT_USE_SMITH_VISIBILITY_HEIGHT_CORRELATED,this.useSmithVisibilityHeightCorrelated=c.DEFAULT_USE_SMITH_VISIBILITY_HEIGHT_CORRELATED,this._useSphericalHarmonics=c.DEFAULT_USE_SPHERICAL_HARMONICS,this.useSphericalHarmonics=c.DEFAULT_USE_SPHERICAL_HARMONICS,this._useSpecularGlossinessInputEnergyConservation=c.DEFAULT_USE_SPECULAR_GLOSSINESS_INPUT_ENERGY_CONSERVATION,this.useSpecularGlossinessInputEnergyConservation=c.DEFAULT_USE_SPECULAR_GLOSSINESS_INPUT_ENERGY_CONSERVATION,this._mixIblRadianceWithIrradiance=c.DEFAULT_MIX_IBL_RADIANCE_WITH_IRRADIANCE,this.mixIblRadianceWithIrradiance=c.DEFAULT_MIX_IBL_RADIANCE_WITH_IRRADIANCE,this._useLegacySpecularEnergyConservation=c.DEFAULT_USE_LEGACY_SPECULAR_ENERGY_CONSERVATION,this.useLegacySpecularEnergyConservation=c.DEFAULT_USE_LEGACY_SPECULAR_ENERGY_CONSERVATION,this._baseDiffuseModel=c.DEFAULT_DIFFUSE_MODEL,this.baseDiffuseModel=c.DEFAULT_DIFFUSE_MODEL,this._dielectricSpecularModel=c.DEFAULT_DIELECTRIC_SPECULAR_MODEL,this.dielectricSpecularModel=c.DEFAULT_DIELECTRIC_SPECULAR_MODEL,this._conductorSpecularModel=c.DEFAULT_CONDUCTOR_SPECULAR_MODEL,this.conductorSpecularModel=c.DEFAULT_CONDUCTOR_SPECULAR_MODEL,this._internalMarkAllSubMeshesAsMiscDirty=e._dirtyCallbacks[16],this._enable(!0)}prepareDefines(e){e.BRDF_V_HEIGHT_CORRELATED=this._useSmithVisibilityHeightCorrelated,e.MS_BRDF_ENERGY_CONSERVATION=this._useEnergyConservation&&this._useSmithVisibilityHeightCorrelated,e.SPHERICAL_HARMONICS=this._useSphericalHarmonics,e.SPECULAR_GLOSSINESS_ENERGY_CONSERVATION=this._useSpecularGlossinessInputEnergyConservation,e.MIX_IBL_RADIANCE_WITH_IRRADIANCE=this._mixIblRadianceWithIrradiance&&!this._material._disableLighting,e.LEGACY_SPECULAR_ENERGY_CONSERVATION=this._useLegacySpecularEnergyConservation,e.BASE_DIFFUSE_MODEL=this._baseDiffuseModel,e.DIELECTRIC_SPECULAR_MODEL=this._dielectricSpecularModel,e.CONDUCTOR_SPECULAR_MODEL=this._conductorSpecularModel}getClassName(){return"PBRBRDFConfiguration"}}c.DEFAULT_USE_ENERGY_CONSERVATION=!0,c.DEFAULT_USE_SMITH_VISIBILITY_HEIGHT_CORRELATED=!0,c.DEFAULT_USE_SPHERICAL_HARMONICS=!0,c.DEFAULT_USE_SPECULAR_GLOSSINESS_INPUT_ENERGY_CONSERVATION=!0,c.DEFAULT_MIX_IBL_RADIANCE_WITH_IRRADIANCE=!0,c.DEFAULT_USE_LEGACY_SPECULAR_ENERGY_CONSERVATION=!0,c.DEFAULT_DIFFUSE_MODEL=0,c.DEFAULT_DIELECTRIC_SPECULAR_MODEL=0,c.DEFAULT_CONDUCTOR_SPECULAR_MODEL=0,(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],c.prototype,"useEnergyConservation",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],c.prototype,"useSmithVisibilityHeightCorrelated",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],c.prototype,"useSphericalHarmonics",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],c.prototype,"useSpecularGlossinessInputEnergyConservation",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],c.prototype,"mixIblRadianceWithIrradiance",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],c.prototype,"useLegacySpecularEnergyConservation",void 0),(0,t.__decorate)([(0,i.serialize)("baseDiffuseModel"),(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],c.prototype,"baseDiffuseModel",void 0),(0,t.__decorate)([(0,i.serialize)("dielectricSpecularModel"),(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],c.prototype,"dielectricSpecularModel",void 0),(0,t.__decorate)([(0,i.serialize)("conductorSpecularModel"),(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],c.prototype,"conductorSpecularModel",void 0);var E=e.i(68069),d=e.i(57970),A=e.i(66052),p=e.i(52344),x=h,R=e.i(93565),S=e.i(47044),m=e.i(20193),f=T,C=h,I=e.i(72014);class M extends C.MaterialDefines{constructor(){super(...arguments),this.CLEARCOAT=!1,this.CLEARCOAT_DEFAULTIOR=!1,this.CLEARCOAT_TEXTURE=!1,this.CLEARCOAT_TEXTURE_ROUGHNESS=!1,this.CLEARCOAT_TEXTUREDIRECTUV=0,this.CLEARCOAT_TEXTURE_ROUGHNESSDIRECTUV=0,this.CLEARCOAT_BUMP=!1,this.CLEARCOAT_BUMPDIRECTUV=0,this.CLEARCOAT_USE_ROUGHNESS_FROM_MAINTEXTURE=!1,this.CLEARCOAT_REMAP_F0=!1,this.CLEARCOAT_TINT=!1,this.CLEARCOAT_TINT_TEXTURE=!1,this.CLEARCOAT_TINT_TEXTUREDIRECTUV=0,this.CLEARCOAT_TINT_GAMMATEXTURE=!1}}class y extends f.MaterialPluginBase{_markAllSubMeshesAsTexturesDirty(){this._enable(this._isEnabled),this._internalMarkAllSubMeshesAsTexturesDirty()}isCompatible(){return!0}constructor(e,t=!0){super(e,"PBRClearCoat",100,new M,t),this._isEnabled=!1,this.isEnabled=!1,this.intensity=1,this.roughness=0,this._indexOfRefraction=y._DefaultIndexOfRefraction,this.indexOfRefraction=y._DefaultIndexOfRefraction,this._texture=null,this.texture=null,this._useRoughnessFromMainTexture=!0,this.useRoughnessFromMainTexture=!0,this._textureRoughness=null,this.textureRoughness=null,this._remapF0OnInterfaceChange=!0,this.remapF0OnInterfaceChange=!0,this._bumpTexture=null,this.bumpTexture=null,this._isTintEnabled=!1,this.isTintEnabled=!1,this.tintColor=r.Color3.White(),this.tintColorAtDistance=1,this.tintThickness=1,this._tintTexture=null,this.tintTexture=null,this._internalMarkAllSubMeshesAsTexturesDirty=e._dirtyCallbacks[1]}isReadyForSubMesh(e,t,i){if(!this._isEnabled)return!0;let s=this._material._disableBumpMap;return(!e._areTexturesDirty||!t.texturesEnabled||(!this._texture||!S.MaterialFlags.ClearCoatTextureEnabled||!!this._texture.isReadyOrNotBlocking())&&(!this._textureRoughness||!S.MaterialFlags.ClearCoatTextureEnabled||!!this._textureRoughness.isReadyOrNotBlocking())&&(!i.getCaps().standardDerivatives||!this._bumpTexture||!S.MaterialFlags.ClearCoatBumpTextureEnabled||!!s||!!this._bumpTexture.isReady())&&(!this._isTintEnabled||!this._tintTexture||!S.MaterialFlags.ClearCoatTintTextureEnabled||!!this._tintTexture.isReadyOrNotBlocking()))&&!0}prepareDefinesBeforeAttributes(e,t){this._isEnabled?(e.CLEARCOAT=!0,e.CLEARCOAT_USE_ROUGHNESS_FROM_MAINTEXTURE=this._useRoughnessFromMainTexture,e.CLEARCOAT_REMAP_F0=this._remapF0OnInterfaceChange,e._areTexturesDirty&&t.texturesEnabled&&(this._texture&&S.MaterialFlags.ClearCoatTextureEnabled?(0,I.PrepareDefinesForMergedUV)(this._texture,e,"CLEARCOAT_TEXTURE"):e.CLEARCOAT_TEXTURE=!1,this._textureRoughness&&S.MaterialFlags.ClearCoatTextureEnabled?(0,I.PrepareDefinesForMergedUV)(this._textureRoughness,e,"CLEARCOAT_TEXTURE_ROUGHNESS"):e.CLEARCOAT_TEXTURE_ROUGHNESS=!1,this._bumpTexture&&S.MaterialFlags.ClearCoatBumpTextureEnabled?(0,I.PrepareDefinesForMergedUV)(this._bumpTexture,e,"CLEARCOAT_BUMP"):e.CLEARCOAT_BUMP=!1,e.CLEARCOAT_DEFAULTIOR=this._indexOfRefraction===y._DefaultIndexOfRefraction,this._isTintEnabled?(e.CLEARCOAT_TINT=!0,this._tintTexture&&S.MaterialFlags.ClearCoatTintTextureEnabled?((0,I.PrepareDefinesForMergedUV)(this._tintTexture,e,"CLEARCOAT_TINT_TEXTURE"),e.CLEARCOAT_TINT_GAMMATEXTURE=this._tintTexture.gammaSpace):e.CLEARCOAT_TINT_TEXTURE=!1):(e.CLEARCOAT_TINT=!1,e.CLEARCOAT_TINT_TEXTURE=!1))):(e.CLEARCOAT=!1,e.CLEARCOAT_TEXTURE=!1,e.CLEARCOAT_TEXTURE_ROUGHNESS=!1,e.CLEARCOAT_BUMP=!1,e.CLEARCOAT_TINT=!1,e.CLEARCOAT_TINT_TEXTURE=!1,e.CLEARCOAT_USE_ROUGHNESS_FROM_MAINTEXTURE=!1,e.CLEARCOAT_DEFAULTIOR=!1,e.CLEARCOAT_TEXTUREDIRECTUV=0,e.CLEARCOAT_TEXTURE_ROUGHNESSDIRECTUV=0,e.CLEARCOAT_BUMPDIRECTUV=0,e.CLEARCOAT_REMAP_F0=!1,e.CLEARCOAT_TINT_TEXTUREDIRECTUV=0,e.CLEARCOAT_TINT_GAMMATEXTURE=!1)}bindForSubMesh(e,t,i,s){if(!this._isEnabled)return;let r=s.materialDefines,a=this._material.isFrozen,n=this._material._disableBumpMap,l=this._material._invertNormalMapX,o=this._material._invertNormalMapY;if(!e.useUbo||!a||!e.isSync){(this._texture||this._textureRoughness)&&S.MaterialFlags.ClearCoatTextureEnabled&&(e.updateFloat4("vClearCoatInfos",this._texture?.coordinatesIndex??0,this._texture?.level??0,this._textureRoughness?.coordinatesIndex??0,this._textureRoughness?.level??0),this._texture&&(0,I.BindTextureMatrix)(this._texture,e,"clearCoat"),this._textureRoughness&&!r.CLEARCOAT_USE_ROUGHNESS_FROM_MAINTEXTURE&&(0,I.BindTextureMatrix)(this._textureRoughness,e,"clearCoatRoughness")),this._bumpTexture&&i.getCaps().standardDerivatives&&S.MaterialFlags.ClearCoatTextureEnabled&&!n&&(e.updateFloat2("vClearCoatBumpInfos",this._bumpTexture.coordinatesIndex,this._bumpTexture.level),(0,I.BindTextureMatrix)(this._bumpTexture,e,"clearCoatBump"),t._mirroredCameraPosition?e.updateFloat2("vClearCoatTangentSpaceParams",l?1:-1,o?1:-1):e.updateFloat2("vClearCoatTangentSpaceParams",l?-1:1,o?-1:1)),this._tintTexture&&S.MaterialFlags.ClearCoatTintTextureEnabled&&(e.updateFloat2("vClearCoatTintInfos",this._tintTexture.coordinatesIndex,this._tintTexture.level),(0,I.BindTextureMatrix)(this._tintTexture,e,"clearCoatTint")),e.updateFloat2("vClearCoatParams",this.intensity,this.roughness);let s=1-this._indexOfRefraction,a=1+this._indexOfRefraction,u=Math.pow(-s/a,2),h=1/this._indexOfRefraction;e.updateFloat4("vClearCoatRefractionParams",u,h,s,a),this._isTintEnabled&&(e.updateFloat4("vClearCoatTintParams",this.tintColor.r,this.tintColor.g,this.tintColor.b,Math.max(1e-5,this.tintThickness)),e.updateFloat("clearCoatColorAtDistance",Math.max(1e-5,this.tintColorAtDistance)))}t.texturesEnabled&&(this._texture&&S.MaterialFlags.ClearCoatTextureEnabled&&e.setTexture("clearCoatSampler",this._texture),this._textureRoughness&&!r.CLEARCOAT_USE_ROUGHNESS_FROM_MAINTEXTURE&&S.MaterialFlags.ClearCoatTextureEnabled&&e.setTexture("clearCoatRoughnessSampler",this._textureRoughness),this._bumpTexture&&i.getCaps().standardDerivatives&&S.MaterialFlags.ClearCoatBumpTextureEnabled&&!n&&e.setTexture("clearCoatBumpSampler",this._bumpTexture),this._isTintEnabled&&this._tintTexture&&S.MaterialFlags.ClearCoatTintTextureEnabled&&e.setTexture("clearCoatTintSampler",this._tintTexture))}hasTexture(e){return this._texture===e||this._textureRoughness===e||this._bumpTexture===e||this._tintTexture===e}getActiveTextures(e){this._texture&&e.push(this._texture),this._textureRoughness&&e.push(this._textureRoughness),this._bumpTexture&&e.push(this._bumpTexture),this._tintTexture&&e.push(this._tintTexture)}getAnimatables(e){this._texture&&this._texture.animations&&this._texture.animations.length>0&&e.push(this._texture),this._textureRoughness&&this._textureRoughness.animations&&this._textureRoughness.animations.length>0&&e.push(this._textureRoughness),this._bumpTexture&&this._bumpTexture.animations&&this._bumpTexture.animations.length>0&&e.push(this._bumpTexture),this._tintTexture&&this._tintTexture.animations&&this._tintTexture.animations.length>0&&e.push(this._tintTexture)}dispose(e){e&&(this._texture?.dispose(),this._textureRoughness?.dispose(),this._bumpTexture?.dispose(),this._tintTexture?.dispose())}getClassName(){return"PBRClearCoatConfiguration"}addFallbacks(e,t,i){return e.CLEARCOAT_BUMP&&t.addFallback(i++,"CLEARCOAT_BUMP"),e.CLEARCOAT_TINT&&t.addFallback(i++,"CLEARCOAT_TINT"),e.CLEARCOAT&&t.addFallback(i++,"CLEARCOAT"),i}getSamplers(e){e.push("clearCoatSampler","clearCoatRoughnessSampler","clearCoatBumpSampler","clearCoatTintSampler")}getUniforms(){return{ubo:[{name:"vClearCoatParams",size:2,type:"vec2"},{name:"vClearCoatRefractionParams",size:4,type:"vec4"},{name:"vClearCoatInfos",size:4,type:"vec4"},{name:"clearCoatMatrix",size:16,type:"mat4"},{name:"clearCoatRoughnessMatrix",size:16,type:"mat4"},{name:"vClearCoatBumpInfos",size:2,type:"vec2"},{name:"vClearCoatTangentSpaceParams",size:2,type:"vec2"},{name:"clearCoatBumpMatrix",size:16,type:"mat4"},{name:"vClearCoatTintParams",size:4,type:"vec4"},{name:"clearCoatColorAtDistance",size:1,type:"float"},{name:"vClearCoatTintInfos",size:2,type:"vec2"},{name:"clearCoatTintMatrix",size:16,type:"mat4"}]}}}y._DefaultIndexOfRefraction=1.5,(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],y.prototype,"isEnabled",void 0),(0,t.__decorate)([(0,i.serialize)()],y.prototype,"intensity",void 0),(0,t.__decorate)([(0,i.serialize)()],y.prototype,"roughness",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],y.prototype,"indexOfRefraction",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],y.prototype,"texture",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],y.prototype,"useRoughnessFromMainTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],y.prototype,"textureRoughness",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],y.prototype,"remapF0OnInterfaceChange",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],y.prototype,"bumpTexture",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],y.prototype,"isTintEnabled",void 0),(0,t.__decorate)([(0,i.serializeAsColor3)()],y.prototype,"tintColor",void 0),(0,t.__decorate)([(0,i.serialize)()],y.prototype,"tintColorAtDistance",void 0),(0,t.__decorate)([(0,i.serialize)()],y.prototype,"tintThickness",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],y.prototype,"tintTexture",void 0);var g=T,b=h;class L extends b.MaterialDefines{constructor(){super(...arguments),this.IRIDESCENCE=!1,this.IRIDESCENCE_TEXTURE=!1,this.IRIDESCENCE_TEXTUREDIRECTUV=0,this.IRIDESCENCE_THICKNESS_TEXTURE=!1,this.IRIDESCENCE_THICKNESS_TEXTUREDIRECTUV=0}}class N extends g.MaterialPluginBase{_markAllSubMeshesAsTexturesDirty(){this._enable(this._isEnabled),this._internalMarkAllSubMeshesAsTexturesDirty()}isCompatible(){return!0}constructor(e,t=!0){super(e,"PBRIridescence",110,new L,t),this._isEnabled=!1,this.isEnabled=!1,this.intensity=1,this.minimumThickness=N._DefaultMinimumThickness,this.maximumThickness=N._DefaultMaximumThickness,this.indexOfRefraction=N._DefaultIndexOfRefraction,this._texture=null,this.texture=null,this._thicknessTexture=null,this.thicknessTexture=null,this._internalMarkAllSubMeshesAsTexturesDirty=e._dirtyCallbacks[1]}isReadyForSubMesh(e,t){return!this._isEnabled||(!e._areTexturesDirty||!t.texturesEnabled||(!this._texture||!S.MaterialFlags.IridescenceTextureEnabled||!!this._texture.isReadyOrNotBlocking())&&(!this._thicknessTexture||!S.MaterialFlags.IridescenceTextureEnabled||!!this._thicknessTexture.isReadyOrNotBlocking()))&&!0}prepareDefinesBeforeAttributes(e,t){this._isEnabled?(e.IRIDESCENCE=!0,e._areTexturesDirty&&t.texturesEnabled&&(this._texture&&S.MaterialFlags.IridescenceTextureEnabled?(0,I.PrepareDefinesForMergedUV)(this._texture,e,"IRIDESCENCE_TEXTURE"):e.IRIDESCENCE_TEXTURE=!1,this._thicknessTexture&&S.MaterialFlags.IridescenceTextureEnabled?(0,I.PrepareDefinesForMergedUV)(this._thicknessTexture,e,"IRIDESCENCE_THICKNESS_TEXTURE"):e.IRIDESCENCE_THICKNESS_TEXTURE=!1)):(e.IRIDESCENCE=!1,e.IRIDESCENCE_TEXTURE=!1,e.IRIDESCENCE_THICKNESS_TEXTURE=!1,e.IRIDESCENCE_TEXTUREDIRECTUV=0,e.IRIDESCENCE_THICKNESS_TEXTUREDIRECTUV=0)}bindForSubMesh(e,t){if(!this._isEnabled)return;let i=this._material.isFrozen;e.useUbo&&i&&e.isSync||((this._texture||this._thicknessTexture)&&S.MaterialFlags.IridescenceTextureEnabled&&(e.updateFloat4("vIridescenceInfos",this._texture?.coordinatesIndex??0,this._texture?.level??0,this._thicknessTexture?.coordinatesIndex??0,this._thicknessTexture?.level??0),this._texture&&(0,I.BindTextureMatrix)(this._texture,e,"iridescence"),this._thicknessTexture&&(0,I.BindTextureMatrix)(this._thicknessTexture,e,"iridescenceThickness")),e.updateFloat4("vIridescenceParams",this.intensity,this.indexOfRefraction,this.minimumThickness,this.maximumThickness)),t.texturesEnabled&&(this._texture&&S.MaterialFlags.IridescenceTextureEnabled&&e.setTexture("iridescenceSampler",this._texture),this._thicknessTexture&&S.MaterialFlags.IridescenceTextureEnabled&&e.setTexture("iridescenceThicknessSampler",this._thicknessTexture))}hasTexture(e){return this._texture===e||this._thicknessTexture===e}getActiveTextures(e){this._texture&&e.push(this._texture),this._thicknessTexture&&e.push(this._thicknessTexture)}getAnimatables(e){this._texture&&this._texture.animations&&this._texture.animations.length>0&&e.push(this._texture),this._thicknessTexture&&this._thicknessTexture.animations&&this._thicknessTexture.animations.length>0&&e.push(this._thicknessTexture)}dispose(e){e&&(this._texture?.dispose(),this._thicknessTexture?.dispose())}getClassName(){return"PBRIridescenceConfiguration"}addFallbacks(e,t,i){return e.IRIDESCENCE&&t.addFallback(i++,"IRIDESCENCE"),i}getSamplers(e){e.push("iridescenceSampler","iridescenceThicknessSampler")}getUniforms(){return{ubo:[{name:"vIridescenceParams",size:4,type:"vec4"},{name:"vIridescenceInfos",size:4,type:"vec4"},{name:"iridescenceMatrix",size:16,type:"mat4"},{name:"iridescenceThicknessMatrix",size:16,type:"mat4"}]}}}N._DefaultMinimumThickness=100,N._DefaultMaximumThickness=400,N._DefaultIndexOfRefraction=1.3,(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],N.prototype,"isEnabled",void 0),(0,t.__decorate)([(0,i.serialize)()],N.prototype,"intensity",void 0),(0,t.__decorate)([(0,i.serialize)()],N.prototype,"minimumThickness",void 0),(0,t.__decorate)([(0,i.serialize)()],N.prototype,"maximumThickness",void 0),(0,t.__decorate)([(0,i.serialize)()],N.prototype,"indexOfRefraction",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],N.prototype,"texture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],N.prototype,"thicknessTexture",void 0);var F=T,O=h;class P extends O.MaterialDefines{constructor(){super(...arguments),this.ANISOTROPIC=!1,this.ANISOTROPIC_TEXTURE=!1,this.ANISOTROPIC_TEXTUREDIRECTUV=0,this.ANISOTROPIC_LEGACY=!1,this.MAINUV1=!1}}class D extends F.MaterialPluginBase{set angle(e){this.direction.x=Math.cos(e),this.direction.y=Math.sin(e)}get angle(){return Math.atan2(this.direction.y,this.direction.x)}_markAllSubMeshesAsTexturesDirty(){this._enable(this._isEnabled),this._internalMarkAllSubMeshesAsTexturesDirty()}_markAllSubMeshesAsMiscDirty(){this._enable(this._isEnabled),this._internalMarkAllSubMeshesAsMiscDirty()}isCompatible(){return!0}constructor(e,t=!0){super(e,"PBRAnisotropic",110,new P,t),this._isEnabled=!1,this.isEnabled=!1,this.intensity=1,this.direction=new o.Vector2(1,0),this._texture=null,this.texture=null,this._legacy=!1,this.legacy=!1,this._internalMarkAllSubMeshesAsTexturesDirty=e._dirtyCallbacks[1],this._internalMarkAllSubMeshesAsMiscDirty=e._dirtyCallbacks[16]}isReadyForSubMesh(e,t){return!this._isEnabled||!e._areTexturesDirty||!t.texturesEnabled||!this._texture||!S.MaterialFlags.AnisotropicTextureEnabled||!!this._texture.isReadyOrNotBlocking()}prepareDefinesBeforeAttributes(e,t,i){this._isEnabled?(e.ANISOTROPIC=this._isEnabled,this._isEnabled&&!i.isVerticesDataPresent(u.VertexBuffer.TangentKind)&&(e._needUVs=!0,e.MAINUV1=!0),e._areTexturesDirty&&t.texturesEnabled&&(this._texture&&S.MaterialFlags.AnisotropicTextureEnabled?(0,I.PrepareDefinesForMergedUV)(this._texture,e,"ANISOTROPIC_TEXTURE"):e.ANISOTROPIC_TEXTURE=!1),e._areMiscDirty&&(e.ANISOTROPIC_LEGACY=this._legacy)):(e.ANISOTROPIC=!1,e.ANISOTROPIC_TEXTURE=!1,e.ANISOTROPIC_TEXTUREDIRECTUV=0,e.ANISOTROPIC_LEGACY=!1)}bindForSubMesh(e,t){if(!this._isEnabled)return;let i=this._material.isFrozen;e.useUbo&&i&&e.isSync||(this._texture&&S.MaterialFlags.AnisotropicTextureEnabled&&(e.updateFloat2("vAnisotropyInfos",this._texture.coordinatesIndex,this._texture.level),(0,I.BindTextureMatrix)(this._texture,e,"anisotropy")),e.updateFloat3("vAnisotropy",this.direction.x,this.direction.y,this.intensity)),t.texturesEnabled&&this._texture&&S.MaterialFlags.AnisotropicTextureEnabled&&e.setTexture("anisotropySampler",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&&this._texture.dispose()}getClassName(){return"PBRAnisotropicConfiguration"}addFallbacks(e,t,i){return e.ANISOTROPIC&&t.addFallback(i++,"ANISOTROPIC"),i}getSamplers(e){e.push("anisotropySampler")}getUniforms(){return{ubo:[{name:"vAnisotropy",size:3,type:"vec3"},{name:"vAnisotropyInfos",size:2,type:"vec2"},{name:"anisotropyMatrix",size:16,type:"mat4"}]}}parse(e,t,i){super.parse(e,t,i),void 0===e.legacy&&(this.legacy=!0)}}(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],D.prototype,"isEnabled",void 0),(0,t.__decorate)([(0,i.serialize)()],D.prototype,"intensity",void 0),(0,t.__decorate)([(0,i.serializeAsVector2)()],D.prototype,"direction",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],D.prototype,"texture",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],D.prototype,"legacy",void 0);var v=T,U=h;class B extends U.MaterialDefines{constructor(){super(...arguments),this.SHEEN=!1,this.SHEEN_TEXTURE=!1,this.SHEEN_GAMMATEXTURE=!1,this.SHEEN_TEXTURE_ROUGHNESS=!1,this.SHEEN_TEXTUREDIRECTUV=0,this.SHEEN_TEXTURE_ROUGHNESSDIRECTUV=0,this.SHEEN_LINKWITHALBEDO=!1,this.SHEEN_ROUGHNESS=!1,this.SHEEN_ALBEDOSCALING=!1,this.SHEEN_USE_ROUGHNESS_FROM_MAINTEXTURE=!1}}class k extends v.MaterialPluginBase{_markAllSubMeshesAsTexturesDirty(){this._enable(this._isEnabled),this._internalMarkAllSubMeshesAsTexturesDirty()}isCompatible(){return!0}constructor(e,t=!0){super(e,"Sheen",120,new B,t),this._isEnabled=!1,this.isEnabled=!1,this._linkSheenWithAlbedo=!1,this.linkSheenWithAlbedo=!1,this.intensity=1,this.color=r.Color3.White(),this._texture=null,this.texture=null,this._useRoughnessFromMainTexture=!0,this.useRoughnessFromMainTexture=!0,this._roughness=null,this.roughness=null,this._textureRoughness=null,this.textureRoughness=null,this._albedoScaling=!1,this.albedoScaling=!1,this._internalMarkAllSubMeshesAsTexturesDirty=e._dirtyCallbacks[1]}isReadyForSubMesh(e,t){return!this._isEnabled||(!e._areTexturesDirty||!t.texturesEnabled||(!this._texture||!S.MaterialFlags.SheenTextureEnabled||!!this._texture.isReadyOrNotBlocking())&&(!this._textureRoughness||!S.MaterialFlags.SheenTextureEnabled||!!this._textureRoughness.isReadyOrNotBlocking()))&&!0}prepareDefinesBeforeAttributes(e,t){this._isEnabled?(e.SHEEN=!0,e.SHEEN_LINKWITHALBEDO=this._linkSheenWithAlbedo,e.SHEEN_ROUGHNESS=null!==this._roughness,e.SHEEN_ALBEDOSCALING=this._albedoScaling,e.SHEEN_USE_ROUGHNESS_FROM_MAINTEXTURE=this._useRoughnessFromMainTexture,e._areTexturesDirty&&t.texturesEnabled&&(this._texture&&S.MaterialFlags.SheenTextureEnabled?((0,I.PrepareDefinesForMergedUV)(this._texture,e,"SHEEN_TEXTURE"),e.SHEEN_GAMMATEXTURE=this._texture.gammaSpace):e.SHEEN_TEXTURE=!1,this._textureRoughness&&S.MaterialFlags.SheenTextureEnabled?(0,I.PrepareDefinesForMergedUV)(this._textureRoughness,e,"SHEEN_TEXTURE_ROUGHNESS"):e.SHEEN_TEXTURE_ROUGHNESS=!1)):(e.SHEEN=!1,e.SHEEN_TEXTURE=!1,e.SHEEN_TEXTURE_ROUGHNESS=!1,e.SHEEN_LINKWITHALBEDO=!1,e.SHEEN_ROUGHNESS=!1,e.SHEEN_ALBEDOSCALING=!1,e.SHEEN_USE_ROUGHNESS_FROM_MAINTEXTURE=!1,e.SHEEN_GAMMATEXTURE=!1,e.SHEEN_TEXTUREDIRECTUV=0,e.SHEEN_TEXTURE_ROUGHNESSDIRECTUV=0)}bindForSubMesh(e,t,i,s){if(!this._isEnabled)return;let r=s.materialDefines,a=this._material.isFrozen;e.useUbo&&a&&e.isSync||((this._texture||this._textureRoughness)&&S.MaterialFlags.SheenTextureEnabled&&(e.updateFloat4("vSheenInfos",this._texture?.coordinatesIndex??0,this._texture?.level??0,this._textureRoughness?.coordinatesIndex??0,this._textureRoughness?.level??0),this._texture&&(0,I.BindTextureMatrix)(this._texture,e,"sheen"),this._textureRoughness&&!r.SHEEN_USE_ROUGHNESS_FROM_MAINTEXTURE&&(0,I.BindTextureMatrix)(this._textureRoughness,e,"sheenRoughness")),e.updateFloat4("vSheenColor",this.color.r,this.color.g,this.color.b,this.intensity),null!==this._roughness&&e.updateFloat("vSheenRoughness",this._roughness)),t.texturesEnabled&&(this._texture&&S.MaterialFlags.SheenTextureEnabled&&e.setTexture("sheenSampler",this._texture),this._textureRoughness&&!r.SHEEN_USE_ROUGHNESS_FROM_MAINTEXTURE&&S.MaterialFlags.SheenTextureEnabled&&e.setTexture("sheenRoughnessSampler",this._textureRoughness))}hasTexture(e){return this._texture===e||this._textureRoughness===e}getActiveTextures(e){this._texture&&e.push(this._texture),this._textureRoughness&&e.push(this._textureRoughness)}getAnimatables(e){this._texture&&this._texture.animations&&this._texture.animations.length>0&&e.push(this._texture),this._textureRoughness&&this._textureRoughness.animations&&this._textureRoughness.animations.length>0&&e.push(this._textureRoughness)}dispose(e){e&&(this._texture?.dispose(),this._textureRoughness?.dispose())}getClassName(){return"PBRSheenConfiguration"}addFallbacks(e,t,i){return e.SHEEN&&t.addFallback(i++,"SHEEN"),i}getSamplers(e){e.push("sheenSampler","sheenRoughnessSampler")}getUniforms(){return{ubo:[{name:"vSheenColor",size:4,type:"vec4"},{name:"vSheenRoughness",size:1,type:"float"},{name:"vSheenInfos",size:4,type:"vec4"},{name:"sheenMatrix",size:16,type:"mat4"},{name:"sheenRoughnessMatrix",size:16,type:"mat4"}]}}}(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],k.prototype,"isEnabled",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],k.prototype,"linkSheenWithAlbedo",void 0),(0,t.__decorate)([(0,i.serialize)()],k.prototype,"intensity",void 0),(0,t.__decorate)([(0,i.serializeAsColor3)()],k.prototype,"color",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],k.prototype,"texture",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],k.prototype,"useRoughnessFromMainTexture",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],k.prototype,"roughness",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],k.prototype,"textureRoughness",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],k.prototype,"albedoScaling",void 0);var H=T,G=h;class z extends G.MaterialDefines{constructor(){super(...arguments),this.SUBSURFACE=!1,this.SS_REFRACTION=!1,this.SS_REFRACTION_USE_INTENSITY_FROM_THICKNESS=!1,this.SS_TRANSLUCENCY=!1,this.SS_TRANSLUCENCY_USE_INTENSITY_FROM_THICKNESS=!1,this.SS_SCATTERING=!1,this.SS_DISPERSION=!1,this.SS_THICKNESSANDMASK_TEXTURE=!1,this.SS_THICKNESSANDMASK_TEXTUREDIRECTUV=0,this.SS_HAS_THICKNESS=!1,this.SS_REFRACTIONINTENSITY_TEXTURE=!1,this.SS_REFRACTIONINTENSITY_TEXTUREDIRECTUV=0,this.SS_TRANSLUCENCYINTENSITY_TEXTURE=!1,this.SS_TRANSLUCENCYINTENSITY_TEXTUREDIRECTUV=0,this.SS_TRANSLUCENCYCOLOR_TEXTURE=!1,this.SS_TRANSLUCENCYCOLOR_TEXTUREDIRECTUV=0,this.SS_TRANSLUCENCYCOLOR_TEXTURE_GAMMA=!1,this.SS_REFRACTIONMAP_3D=!1,this.SS_REFRACTIONMAP_OPPOSITEZ=!1,this.SS_LODINREFRACTIONALPHA=!1,this.SS_GAMMAREFRACTION=!1,this.SS_RGBDREFRACTION=!1,this.SS_LINEARSPECULARREFRACTION=!1,this.SS_LINKREFRACTIONTOTRANSPARENCY=!1,this.SS_ALBEDOFORREFRACTIONTINT=!1,this.SS_ALBEDOFORTRANSLUCENCYTINT=!1,this.SS_USE_LOCAL_REFRACTIONMAP_CUBIC=!1,this.SS_USE_THICKNESS_AS_DEPTH=!1,this.SS_USE_GLTF_TEXTURES=!1,this.SS_APPLY_ALBEDO_AFTER_SUBSURFACE=!1,this.SS_TRANSLUCENCY_LEGACY=!1}}class V extends H.MaterialPluginBase{get scatteringDiffusionProfile(){return this._scene.subSurfaceConfiguration?this._scene.subSurfaceConfiguration.ssDiffusionProfileColors[this._scatteringDiffusionProfileIndex]:null}set scatteringDiffusionProfile(e){this._scene.enableSubSurfaceForPrePass()&&e&&(this._scatteringDiffusionProfileIndex=this._scene.subSurfaceConfiguration.addDiffusionProfile(e))}get volumeIndexOfRefraction(){return this._volumeIndexOfRefraction>=1?this._volumeIndexOfRefraction:this._indexOfRefraction}set volumeIndexOfRefraction(e){e>=1?this._volumeIndexOfRefraction=e:this._volumeIndexOfRefraction=-1}get legacyTransluceny(){return this.legacyTranslucency}set legacyTransluceny(e){this.legacyTranslucency=e}_markAllSubMeshesAsTexturesDirty(){this._enable(this._isRefractionEnabled||this._isTranslucencyEnabled||this._isScatteringEnabled),this._internalMarkAllSubMeshesAsTexturesDirty()}_markScenePrePassDirty(){this._enable(this._isRefractionEnabled||this._isTranslucencyEnabled||this._isScatteringEnabled),this._internalMarkAllSubMeshesAsTexturesDirty(),this._internalMarkScenePrePassDirty()}isCompatible(){return!0}constructor(e,t=!0){super(e,"PBRSubSurface",130,new z,t),this._isRefractionEnabled=!1,this.isRefractionEnabled=!1,this._isTranslucencyEnabled=!1,this.isTranslucencyEnabled=!1,this._isDispersionEnabled=!1,this.isDispersionEnabled=!1,this._isScatteringEnabled=!1,this.isScatteringEnabled=!1,this._scatteringDiffusionProfileIndex=0,this.refractionIntensity=1,this.translucencyIntensity=1,this._useAlbedoToTintRefraction=!1,this.useAlbedoToTintRefraction=!1,this._useAlbedoToTintTranslucency=!1,this.useAlbedoToTintTranslucency=!1,this._thicknessTexture=null,this.thicknessTexture=null,this._refractionTexture=null,this.refractionTexture=null,this._indexOfRefraction=1.5,this.indexOfRefraction=1.5,this._volumeIndexOfRefraction=-1,this._invertRefractionY=!1,this.invertRefractionY=!1,this._linkRefractionWithTransparency=!1,this.linkRefractionWithTransparency=!1,this.minimumThickness=0,this.maximumThickness=1,this.useThicknessAsDepth=!1,this.tintColor=r.Color3.White(),this.tintColorAtDistance=1,this.dispersion=0,this.diffusionDistance=r.Color3.White(),this._useMaskFromThicknessTexture=!1,this.useMaskFromThicknessTexture=!1,this._refractionIntensityTexture=null,this.refractionIntensityTexture=null,this._translucencyIntensityTexture=null,this.translucencyIntensityTexture=null,this.translucencyColor=null,this._translucencyColorTexture=null,this.translucencyColorTexture=null,this._useGltfStyleTextures=!0,this.useGltfStyleTextures=!0,this.applyAlbedoAfterSubSurface=V.DEFAULT_APPLY_ALBEDO_AFTERSUBSURFACE,this.legacyTranslucency=V.DEFAULT_LEGACY_TRANSLUCENCY,this._scene=e.getScene(),this.registerForExtraEvents=!0,this._internalMarkAllSubMeshesAsTexturesDirty=e._dirtyCallbacks[1],this._internalMarkScenePrePassDirty=e._dirtyCallbacks[32]}isReadyForSubMesh(e,t){if(!this._isRefractionEnabled&&!this._isTranslucencyEnabled&&!this._isScatteringEnabled)return!0;if(e._areTexturesDirty&&t.texturesEnabled){if(this._thicknessTexture&&S.MaterialFlags.ThicknessTextureEnabled&&!this._thicknessTexture.isReadyOrNotBlocking()||this._refractionIntensityTexture&&S.MaterialFlags.RefractionIntensityTextureEnabled&&!this._refractionIntensityTexture.isReadyOrNotBlocking()||this._translucencyColorTexture&&S.MaterialFlags.TranslucencyColorTextureEnabled&&!this._translucencyColorTexture.isReadyOrNotBlocking()||this._translucencyIntensityTexture&&S.MaterialFlags.TranslucencyIntensityTextureEnabled&&!this._translucencyIntensityTexture.isReadyOrNotBlocking())return!1;let e=this._getRefractionTexture(t);if(e&&S.MaterialFlags.RefractionTextureEnabled&&!e.isReadyOrNotBlocking())return!1}return!0}prepareDefinesBeforeAttributes(e,t){if(!this._isRefractionEnabled&&!this._isTranslucencyEnabled&&!this._isScatteringEnabled){e.SUBSURFACE=!1,e.SS_DISPERSION=!1,e.SS_TRANSLUCENCY=!1,e.SS_SCATTERING=!1,e.SS_REFRACTION=!1,e.SS_REFRACTION_USE_INTENSITY_FROM_THICKNESS=!1,e.SS_TRANSLUCENCY_USE_INTENSITY_FROM_THICKNESS=!1,e.SS_THICKNESSANDMASK_TEXTURE=!1,e.SS_THICKNESSANDMASK_TEXTUREDIRECTUV=0,e.SS_HAS_THICKNESS=!1,e.SS_REFRACTIONINTENSITY_TEXTURE=!1,e.SS_REFRACTIONINTENSITY_TEXTUREDIRECTUV=0,e.SS_TRANSLUCENCYINTENSITY_TEXTURE=!1,e.SS_TRANSLUCENCYINTENSITY_TEXTUREDIRECTUV=0,e.SS_REFRACTIONMAP_3D=!1,e.SS_REFRACTIONMAP_OPPOSITEZ=!1,e.SS_LODINREFRACTIONALPHA=!1,e.SS_GAMMAREFRACTION=!1,e.SS_RGBDREFRACTION=!1,e.SS_LINEARSPECULARREFRACTION=!1,e.SS_LINKREFRACTIONTOTRANSPARENCY=!1,e.SS_ALBEDOFORREFRACTIONTINT=!1,e.SS_ALBEDOFORTRANSLUCENCYTINT=!1,e.SS_USE_LOCAL_REFRACTIONMAP_CUBIC=!1,e.SS_USE_THICKNESS_AS_DEPTH=!1,e.SS_USE_GLTF_TEXTURES=!1,e.SS_TRANSLUCENCYCOLOR_TEXTURE=!1,e.SS_TRANSLUCENCYCOLOR_TEXTUREDIRECTUV=0,e.SS_TRANSLUCENCYCOLOR_TEXTURE_GAMMA=!1,e.SS_APPLY_ALBEDO_AFTER_SUBSURFACE=!1;return}if(e._areTexturesDirty){if(e.SUBSURFACE=!0,e.SS_DISPERSION=this._isDispersionEnabled,e.SS_TRANSLUCENCY=this._isTranslucencyEnabled,e.SS_TRANSLUCENCY_USE_INTENSITY_FROM_THICKNESS=!1,e.SS_TRANSLUCENCY_LEGACY=this.legacyTranslucency,e.SS_SCATTERING=this._isScatteringEnabled,e.SS_THICKNESSANDMASK_TEXTURE=!1,e.SS_REFRACTIONINTENSITY_TEXTURE=!1,e.SS_TRANSLUCENCYINTENSITY_TEXTURE=!1,e.SS_HAS_THICKNESS=!1,e.SS_USE_GLTF_TEXTURES=!1,e.SS_REFRACTION=!1,e.SS_REFRACTION_USE_INTENSITY_FROM_THICKNESS=!1,e.SS_REFRACTIONMAP_3D=!1,e.SS_GAMMAREFRACTION=!1,e.SS_RGBDREFRACTION=!1,e.SS_LINEARSPECULARREFRACTION=!1,e.SS_REFRACTIONMAP_OPPOSITEZ=!1,e.SS_LODINREFRACTIONALPHA=!1,e.SS_LINKREFRACTIONTOTRANSPARENCY=!1,e.SS_ALBEDOFORREFRACTIONTINT=!1,e.SS_ALBEDOFORTRANSLUCENCYTINT=!1,e.SS_USE_LOCAL_REFRACTIONMAP_CUBIC=!1,e.SS_USE_THICKNESS_AS_DEPTH=!1,e.SS_TRANSLUCENCYCOLOR_TEXTURE=!1,e.SS_APPLY_ALBEDO_AFTER_SUBSURFACE=this.applyAlbedoAfterSubSurface,e._areTexturesDirty&&t.texturesEnabled&&(this._thicknessTexture&&S.MaterialFlags.ThicknessTextureEnabled&&(0,I.PrepareDefinesForMergedUV)(this._thicknessTexture,e,"SS_THICKNESSANDMASK_TEXTURE"),this._refractionIntensityTexture&&S.MaterialFlags.RefractionIntensityTextureEnabled&&(0,I.PrepareDefinesForMergedUV)(this._refractionIntensityTexture,e,"SS_REFRACTIONINTENSITY_TEXTURE"),this._translucencyIntensityTexture&&S.MaterialFlags.TranslucencyIntensityTextureEnabled&&(0,I.PrepareDefinesForMergedUV)(this._translucencyIntensityTexture,e,"SS_TRANSLUCENCYINTENSITY_TEXTURE"),this._translucencyColorTexture&&S.MaterialFlags.TranslucencyColorTextureEnabled&&((0,I.PrepareDefinesForMergedUV)(this._translucencyColorTexture,e,"SS_TRANSLUCENCYCOLOR_TEXTURE"),e.SS_TRANSLUCENCYCOLOR_TEXTURE_GAMMA=this._translucencyColorTexture.gammaSpace)),e.SS_HAS_THICKNESS=this.maximumThickness-this.minimumThickness!=0,e.SS_USE_GLTF_TEXTURES=this._useGltfStyleTextures,e.SS_REFRACTION_USE_INTENSITY_FROM_THICKNESS=this._useMaskFromThicknessTexture&&!this._refractionIntensityTexture,e.SS_TRANSLUCENCY_USE_INTENSITY_FROM_THICKNESS=this._useMaskFromThicknessTexture&&!this._translucencyIntensityTexture,this._isRefractionEnabled&&t.texturesEnabled){let i=this._getRefractionTexture(t);i&&S.MaterialFlags.RefractionTextureEnabled&&(e.SS_REFRACTION=!0,e.SS_REFRACTIONMAP_3D=i.isCube,e.SS_GAMMAREFRACTION=i.gammaSpace,e.SS_RGBDREFRACTION=i.isRGBD,e.SS_LINEARSPECULARREFRACTION=i.linearSpecularLOD,e.SS_REFRACTIONMAP_OPPOSITEZ=this._scene.useRightHandedSystem&&i.isCube?!i.invertZ:i.invertZ,e.SS_LODINREFRACTIONALPHA=i.lodLevelInAlpha,e.SS_LINKREFRACTIONTOTRANSPARENCY=this._linkRefractionWithTransparency,e.SS_ALBEDOFORREFRACTIONTINT=this._useAlbedoToTintRefraction,e.SS_USE_LOCAL_REFRACTIONMAP_CUBIC=i.isCube&&i.boundingBoxSize,e.SS_USE_THICKNESS_AS_DEPTH=this.useThicknessAsDepth)}this._isTranslucencyEnabled&&(e.SS_ALBEDOFORTRANSLUCENCYTINT=this._useAlbedoToTintTranslucency)}}hardBindForSubMesh(e,t,i,s){if(this._isRefractionEnabled||this._isTranslucencyEnabled||this._isScatteringEnabled)if(0===this.maximumThickness&&0===this.minimumThickness)e.updateFloat2("vThicknessParam",0,0);else{s.getRenderingMesh().getWorldMatrix().decompose(o.TmpVectors.Vector3[0]);let t=Math.max(Math.abs(o.TmpVectors.Vector3[0].x),Math.abs(o.TmpVectors.Vector3[0].y),Math.abs(o.TmpVectors.Vector3[0].z));e.updateFloat2("vThicknessParam",this.minimumThickness*t,(this.maximumThickness-this.minimumThickness)*t)}}bindForSubMesh(e,t,i,s){if(!this._isRefractionEnabled&&!this._isTranslucencyEnabled&&!this._isScatteringEnabled)return;let r=s.materialDefines,a=this._material.isFrozen,n=this._material.realTimeFiltering,l=r.LODBASEDMICROSFURACE,o=this._getRefractionTexture(t);if(!e.useUbo||!a||!e.isSync){if(this._thicknessTexture&&S.MaterialFlags.ThicknessTextureEnabled&&(e.updateFloat2("vThicknessInfos",this._thicknessTexture.coordinatesIndex,this._thicknessTexture.level),(0,I.BindTextureMatrix)(this._thicknessTexture,e,"thickness")),this._refractionIntensityTexture&&S.MaterialFlags.RefractionIntensityTextureEnabled&&r.SS_REFRACTIONINTENSITY_TEXTURE&&(e.updateFloat2("vRefractionIntensityInfos",this._refractionIntensityTexture.coordinatesIndex,this._refractionIntensityTexture.level),(0,I.BindTextureMatrix)(this._refractionIntensityTexture,e,"refractionIntensity")),this._translucencyColorTexture&&S.MaterialFlags.TranslucencyColorTextureEnabled&&r.SS_TRANSLUCENCYCOLOR_TEXTURE&&(e.updateFloat2("vTranslucencyColorInfos",this._translucencyColorTexture.coordinatesIndex,this._translucencyColorTexture.level),(0,I.BindTextureMatrix)(this._translucencyColorTexture,e,"translucencyColor")),this._translucencyIntensityTexture&&S.MaterialFlags.TranslucencyIntensityTextureEnabled&&r.SS_TRANSLUCENCYINTENSITY_TEXTURE&&(e.updateFloat2("vTranslucencyIntensityInfos",this._translucencyIntensityTexture.coordinatesIndex,this._translucencyIntensityTexture.level),(0,I.BindTextureMatrix)(this._translucencyIntensityTexture,e,"translucencyIntensity")),o&&S.MaterialFlags.RefractionTextureEnabled){e.updateMatrix("refractionMatrix",o.getRefractionTextureMatrix());let t=1;!o.isCube&&o.depth&&(t=o.depth);let i=o.getSize().width,s=this.volumeIndexOfRefraction;e.updateFloat4("vRefractionInfos",o.level,1/s,t,this._invertRefractionY?-1:1),e.updateFloat4("vRefractionMicrosurfaceInfos",i,o.lodGenerationScale,o.lodGenerationOffset,1/this.indexOfRefraction),n&&e.updateFloat2("vRefractionFilteringInfo",i,Math.log2(i)),o.boundingBoxSize&&(e.updateVector3("vRefractionPosition",o.boundingBoxPosition),e.updateVector3("vRefractionSize",o.boundingBoxSize))}this._isScatteringEnabled&&e.updateFloat("scatteringDiffusionProfile",this._scatteringDiffusionProfileIndex),e.updateColor3("vDiffusionDistance",this.diffusionDistance),e.updateFloat4("vTintColor",this.tintColor.r,this.tintColor.g,this.tintColor.b,Math.max(1e-5,this.tintColorAtDistance)),e.updateColor4("vTranslucencyColor",this.translucencyColor??this.tintColor,0),e.updateFloat3("vSubSurfaceIntensity",this.refractionIntensity,this.translucencyIntensity,0),e.updateFloat("dispersion",this.dispersion)}t.texturesEnabled&&(this._thicknessTexture&&S.MaterialFlags.ThicknessTextureEnabled&&e.setTexture("thicknessSampler",this._thicknessTexture),this._refractionIntensityTexture&&S.MaterialFlags.RefractionIntensityTextureEnabled&&r.SS_REFRACTIONINTENSITY_TEXTURE&&e.setTexture("refractionIntensitySampler",this._refractionIntensityTexture),this._translucencyIntensityTexture&&S.MaterialFlags.TranslucencyIntensityTextureEnabled&&r.SS_TRANSLUCENCYINTENSITY_TEXTURE&&e.setTexture("translucencyIntensitySampler",this._translucencyIntensityTexture),this._translucencyColorTexture&&S.MaterialFlags.TranslucencyColorTextureEnabled&&r.SS_TRANSLUCENCYCOLOR_TEXTURE&&e.setTexture("translucencyColorSampler",this._translucencyColorTexture),o&&S.MaterialFlags.RefractionTextureEnabled&&(l?e.setTexture("refractionSampler",o):(e.setTexture("refractionSampler",o._lodTextureMid||o),e.setTexture("refractionSamplerLow",o._lodTextureLow||o),e.setTexture("refractionSamplerHigh",o._lodTextureHigh||o))))}_getRefractionTexture(e){return this._refractionTexture?this._refractionTexture:this._isRefractionEnabled?e.environmentTexture:null}get disableAlphaBlending(){return this._isRefractionEnabled&&this._linkRefractionWithTransparency}fillRenderTargetTextures(e){S.MaterialFlags.RefractionTextureEnabled&&this._refractionTexture&&this._refractionTexture.isRenderTarget&&e.push(this._refractionTexture)}hasTexture(e){return this._thicknessTexture===e||this._refractionTexture===e||this._refractionIntensityTexture===e||this._translucencyIntensityTexture===e||this._translucencyColorTexture===e}hasRenderTargetTextures(){return!!S.MaterialFlags.RefractionTextureEnabled&&!!this._refractionTexture&&!!this._refractionTexture.isRenderTarget}getActiveTextures(e){this._thicknessTexture&&e.push(this._thicknessTexture),this._refractionTexture&&e.push(this._refractionTexture),this._refractionIntensityTexture&&e.push(this._refractionIntensityTexture),this._translucencyColorTexture&&e.push(this._translucencyColorTexture),this._translucencyIntensityTexture&&e.push(this._translucencyIntensityTexture)}getAnimatables(e){this._thicknessTexture&&this._thicknessTexture.animations&&this._thicknessTexture.animations.length>0&&e.push(this._thicknessTexture),this._refractionTexture&&this._refractionTexture.animations&&this._refractionTexture.animations.length>0&&e.push(this._refractionTexture),this._refractionIntensityTexture&&this._refractionIntensityTexture.animations&&this._refractionIntensityTexture.animations.length>0&&e.push(this._refractionIntensityTexture),this._translucencyColorTexture&&this._translucencyColorTexture.animations&&this._translucencyColorTexture.animations.length>0&&e.push(this._translucencyColorTexture),this._translucencyIntensityTexture&&this._translucencyIntensityTexture.animations&&this._translucencyIntensityTexture.animations.length>0&&e.push(this._translucencyIntensityTexture)}dispose(e){e&&(this._thicknessTexture&&this._thicknessTexture.dispose(),this._refractionTexture&&this._refractionTexture.dispose(),this._refractionIntensityTexture&&this._refractionIntensityTexture.dispose(),this._translucencyColorTexture&&this._translucencyColorTexture.dispose(),this._translucencyIntensityTexture&&this._translucencyIntensityTexture.dispose())}getClassName(){return"PBRSubSurfaceConfiguration"}addFallbacks(e,t,i){return e.SS_SCATTERING&&t.addFallback(i++,"SS_SCATTERING"),e.SS_TRANSLUCENCY&&t.addFallback(i++,"SS_TRANSLUCENCY"),i}getSamplers(e){e.push("thicknessSampler","refractionIntensitySampler","translucencyIntensitySampler","refractionSampler","refractionSamplerLow","refractionSamplerHigh","translucencyColorSampler")}getUniforms(){return{ubo:[{name:"vRefractionMicrosurfaceInfos",size:4,type:"vec4"},{name:"vRefractionFilteringInfo",size:2,type:"vec2"},{name:"vTranslucencyIntensityInfos",size:2,type:"vec2"},{name:"vRefractionInfos",size:4,type:"vec4"},{name:"refractionMatrix",size:16,type:"mat4"},{name:"vThicknessInfos",size:2,type:"vec2"},{name:"vRefractionIntensityInfos",size:2,type:"vec2"},{name:"thicknessMatrix",size:16,type:"mat4"},{name:"refractionIntensityMatrix",size:16,type:"mat4"},{name:"translucencyIntensityMatrix",size:16,type:"mat4"},{name:"vThicknessParam",size:2,type:"vec2"},{name:"vDiffusionDistance",size:3,type:"vec3"},{name:"vTintColor",size:4,type:"vec4"},{name:"vSubSurfaceIntensity",size:3,type:"vec3"},{name:"vRefractionPosition",size:3,type:"vec3"},{name:"vRefractionSize",size:3,type:"vec3"},{name:"scatteringDiffusionProfile",size:1,type:"float"},{name:"dispersion",size:1,type:"float"},{name:"vTranslucencyColor",size:4,type:"vec4"},{name:"vTranslucencyColorInfos",size:2,type:"vec2"},{name:"translucencyColorMatrix",size:16,type:"mat4"}]}}}V.DEFAULT_APPLY_ALBEDO_AFTERSUBSURFACE=!1,V.DEFAULT_LEGACY_TRANSLUCENCY=!1,(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"isRefractionEnabled",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"isTranslucencyEnabled",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"isDispersionEnabled",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markScenePrePassDirty")],V.prototype,"isScatteringEnabled",void 0),(0,t.__decorate)([(0,i.serialize)()],V.prototype,"_scatteringDiffusionProfileIndex",void 0),(0,t.__decorate)([(0,i.serialize)()],V.prototype,"refractionIntensity",void 0),(0,t.__decorate)([(0,i.serialize)()],V.prototype,"translucencyIntensity",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"useAlbedoToTintRefraction",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"useAlbedoToTintTranslucency",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"thicknessTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"refractionTexture",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"indexOfRefraction",void 0),(0,t.__decorate)([(0,i.serialize)()],V.prototype,"_volumeIndexOfRefraction",void 0),(0,t.__decorate)([(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"volumeIndexOfRefraction",null),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"invertRefractionY",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"linkRefractionWithTransparency",void 0),(0,t.__decorate)([(0,i.serialize)()],V.prototype,"minimumThickness",void 0),(0,t.__decorate)([(0,i.serialize)()],V.prototype,"maximumThickness",void 0),(0,t.__decorate)([(0,i.serialize)()],V.prototype,"useThicknessAsDepth",void 0),(0,t.__decorate)([(0,i.serializeAsColor3)()],V.prototype,"tintColor",void 0),(0,t.__decorate)([(0,i.serialize)()],V.prototype,"tintColorAtDistance",void 0),(0,t.__decorate)([(0,i.serialize)()],V.prototype,"dispersion",void 0),(0,t.__decorate)([(0,i.serializeAsColor3)()],V.prototype,"diffusionDistance",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"useMaskFromThicknessTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"refractionIntensityTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"translucencyIntensityTexture",void 0),(0,t.__decorate)([(0,i.serializeAsColor3)()],V.prototype,"translucencyColor",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"translucencyColorTexture",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],V.prototype,"useGltfStyleTextures",void 0),(0,t.__decorate)([(0,i.serialize)()],V.prototype,"applyAlbedoAfterSubSurface",void 0),(0,t.__decorate)([(0,i.serialize)()],V.prototype,"legacyTranslucency",void 0);var X=e.i(96066),Y=e.i(4760),W=e.i(69858),w=e.i(48004),K=e.i(33987),Q=e.i(88955),Z=e.i(75613),j=e.i(54670);let J={effect:null,subMesh:null};class $ extends(0,Q.PrepassDefinesMixin)((0,K.UVDefinesMixin)(x.MaterialDefines)){}class q extends(0,d.ImageProcessingDefinesMixin)($){constructor(e){super(e),this.PBR=!0,this.NUM_SAMPLES="0",this.REALTIME_FILTERING=!1,this.IBL_CDF_FILTERING=!1,this.ALBEDO=!1,this.GAMMAALBEDO=!1,this.ALBEDODIRECTUV=0,this.VERTEXCOLOR=!1,this.BASE_WEIGHT=!1,this.BASE_WEIGHTDIRECTUV=0,this.BASE_DIFFUSE_ROUGHNESS=!1,this.BASE_DIFFUSE_ROUGHNESSDIRECTUV=0,this.BAKED_VERTEX_ANIMATION_TEXTURE=!1,this.AMBIENT=!1,this.AMBIENTDIRECTUV=0,this.AMBIENTINGRAYSCALE=!1,this.OPACITY=!1,this.VERTEXALPHA=!1,this.OPACITYDIRECTUV=0,this.OPACITYRGB=!1,this.ALPHATEST=!1,this.DEPTHPREPASS=!1,this.ALPHABLEND=!1,this.ALPHAFROMALBEDO=!1,this.ALPHATESTVALUE="0.5",this.SPECULAROVERALPHA=!1,this.RADIANCEOVERALPHA=!1,this.ALPHAFRESNEL=!1,this.LINEARALPHAFRESNEL=!1,this.PREMULTIPLYALPHA=!1,this.EMISSIVE=!1,this.EMISSIVEDIRECTUV=0,this.GAMMAEMISSIVE=!1,this.REFLECTIVITY=!1,this.REFLECTIVITY_GAMMA=!1,this.REFLECTIVITYDIRECTUV=0,this.SPECULARTERM=!1,this.MICROSURFACEFROMREFLECTIVITYMAP=!1,this.MICROSURFACEAUTOMATIC=!1,this.LODBASEDMICROSFURACE=!1,this.MICROSURFACEMAP=!1,this.MICROSURFACEMAPDIRECTUV=0,this.METALLICWORKFLOW=!1,this.ROUGHNESSSTOREINMETALMAPALPHA=!1,this.ROUGHNESSSTOREINMETALMAPGREEN=!1,this.METALLNESSSTOREINMETALMAPBLUE=!1,this.AOSTOREINMETALMAPRED=!1,this.METALLIC_REFLECTANCE=!1,this.METALLIC_REFLECTANCE_GAMMA=!1,this.METALLIC_REFLECTANCEDIRECTUV=0,this.METALLIC_REFLECTANCE_USE_ALPHA_ONLY=!1,this.REFLECTANCE=!1,this.REFLECTANCE_GAMMA=!1,this.REFLECTANCEDIRECTUV=0,this.ENVIRONMENTBRDF=!1,this.ENVIRONMENTBRDF_RGBD=!1,this.NORMAL=!1,this.TANGENT=!1,this.BUMP=!1,this.BUMPDIRECTUV=0,this.OBJECTSPACE_NORMALMAP=!1,this.PARALLAX=!1,this.PARALLAX_RHS=!1,this.PARALLAXOCCLUSION=!1,this.NORMALXYSCALE=!0,this.LIGHTMAP=!1,this.LIGHTMAPDIRECTUV=0,this.USELIGHTMAPASSHADOWMAP=!1,this.GAMMALIGHTMAP=!1,this.RGBDLIGHTMAP=!1,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,this.LINEARSPECULARREFLECTION=!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.MULTIVIEW=!1,this.ORDER_INDEPENDENT_TRANSPARENCY=!1,this.ORDER_INDEPENDENT_TRANSPARENCY_16BITS=!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.rebuild()}reset(){super.reset(),this.ALPHATESTVALUE="0.5",this.PBR=!0,this.NORMALXYSCALE=!0}}class ee extends(0,Z.ImageProcessingMixin)(R.PushMaterial){}class et extends ee{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 canRenderToMRT(){return!0}constructor(e,t,i=!1){super(e,t,void 0,i||et.ForceGLSL),this._directIntensity=1,this._emissiveIntensity=1,this._environmentIntensity=1,this._specularIntensity=1,this._lightingInfos=new o.Vector4(this._directIntensity,this._emissiveIntensity,this._environmentIntensity,this._specularIntensity),this._disableBumpMap=!1,this._albedoTexture=null,this._baseWeightTexture=null,this._baseDiffuseRoughnessTexture=null,this._ambientTexture=null,this._ambientTextureStrength=1,this._ambientTextureImpactOnAnalyticalLights=et.DEFAULT_AO_ON_ANALYTICAL_LIGHTS,this._opacityTexture=null,this._reflectionTexture=null,this._emissiveTexture=null,this._reflectivityTexture=null,this._metallicTexture=null,this._metallic=null,this._roughness=null,this._metallicF0Factor=1,this._metallicReflectanceColor=r.Color3.White(),this._useOnlyMetallicFromMetallicReflectanceTexture=!1,this._metallicReflectanceTexture=null,this._reflectanceTexture=null,this._microSurfaceTexture=null,this._bumpTexture=null,this._lightmapTexture=null,this._ambientColor=new r.Color3(0,0,0),this._albedoColor=new r.Color3(1,1,1),this._baseWeight=1,this._baseDiffuseRoughness=null,this._reflectivityColor=new r.Color3(1,1,1),this._reflectionColor=new r.Color3(1,1,1),this._emissiveColor=new r.Color3(0,0,0),this._microSurface=.9,this._useLightmapAsShadowmap=!1,this._useHorizonOcclusion=!0,this._useRadianceOcclusion=!0,this._useAlphaFromAlbedoTexture=!1,this._useSpecularOverAlpha=!0,this._useMicroSurfaceFromReflectivityMapAlpha=!1,this._useRoughnessFromMetallicTextureAlpha=!0,this._useRoughnessFromMetallicTextureGreen=!1,this._useMetallnessFromMetallicTextureBlue=!1,this._useAmbientOcclusionFromMetallicTextureRed=!1,this._useAmbientInGrayScale=!1,this._useAutoMicroSurfaceFromReflectivityMap=!1,this._lightFalloff=et.LIGHTFALLOFF_PHYSICAL,this._useRadianceOverAlpha=!0,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._forceIrradianceInFragment=!1,this._realTimeFiltering=!1,this._realTimeFilteringQuality=8,this._forceNormalForward=!1,this._enableSpecularAntiAliasing=!1,this._renderTargets=new n.SmartArray(16),this._globalAmbientColor=new r.Color3(0,0,0),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.brdf=new c(this),this.clearCoat=new y(this),this.iridescence=new N(this),this.anisotropy=new D(this),this.sheen=new k(this),this.subSurface=new V(this),this.detailMap=new X.DetailMapConfiguration(this),this._attachImageProcessingConfiguration(null),this.getRenderTargetTextures=()=>(this._renderTargets.reset(),S.MaterialFlags.ReflectionTextureEnabled&&this._reflectionTexture&&this._reflectionTexture.isRenderTarget&&this._renderTargets.push(this._reflectionTexture),this._eventInfo.renderTargets=this._renderTargets,this._callbackPluginEventFillRenderTargetTextures(this._eventInfo),this._renderTargets),this._environmentBRDFTexture=(0,s.GetEnvironmentBRDFTexture)(this.getScene()),this.prePassConfiguration=new E.PrePassConfiguration}get hasRenderTargetTextures(){return!!S.MaterialFlags.ReflectionTextureEnabled&&!!this._reflectionTexture&&!!this._reflectionTexture.isRenderTarget||this._cacheHasRenderTargetTextures}get isPrePassCapable(){return!this.disableDepthWrite}getClassName(){return"PBRBaseMaterial"}get _disableAlphaBlending(){return this._transparencyMode===et.PBRMATERIAL_OPAQUE||this._transparencyMode===et.PBRMATERIAL_ALPHATEST||this.subSurface?.disableAlphaBlending}needAlphaBlending(){return this._hasTransparencyMode?this._transparencyModeIsBlend:!this._disableAlphaBlending&&(this.alpha<1||null!=this._opacityTexture||this._shouldUseAlphaFromAlbedoTexture())}needAlphaTesting(){return this._hasTransparencyMode?this._transparencyModeIsTest:!this.subSurface?.disableAlphaBlending&&this._hasAlphaChannel()&&(null==this._transparencyMode||this._transparencyMode===et.PBRMATERIAL_ALPHATEST)}_shouldUseAlphaFromAlbedoTexture(){return null!=this._albedoTexture&&this._albedoTexture.hasAlpha&&this._useAlphaFromAlbedoTexture&&this._transparencyMode!==et.PBRMATERIAL_OPAQUE}_hasAlphaChannel(){return null!=this._albedoTexture&&this._albedoTexture.hasAlpha||null!=this._opacityTexture}getAlphaTestTexture(){return this._albedoTexture}isReadyForSubMesh(e,t,i){this._uniformBufferLayoutBuilt||this.buildUniformLayout();let s=t._drawWrapper;if(s.effect&&this.isFrozen&&s._wasPreviouslyReady&&s._wasPreviouslyUsingInstances===i)return!0;t.materialDefines||(this._callbackPluginEventGeneric(4,this._eventInfo),t.materialDefines=new q(this._eventInfo.defineNames));let r=t.materialDefines;if(this._isReadyForSubMesh(t))return!0;let n=this.getScene(),l=n.getEngine();if(r._areTexturesDirty&&(this._eventInfo.hasRenderTargetTextures=!1,this._callbackPluginEventHasRenderTargetTextures(this._eventInfo),this._cacheHasRenderTargetTextures=this._eventInfo.hasRenderTargetTextures,n.texturesEnabled)){if(this._albedoTexture&&S.MaterialFlags.DiffuseTextureEnabled&&!this._albedoTexture.isReadyOrNotBlocking()||this._baseWeightTexture&&S.MaterialFlags.BaseWeightTextureEnabled&&!this._baseWeightTexture.isReadyOrNotBlocking()||this._baseDiffuseRoughnessTexture&&S.MaterialFlags.BaseDiffuseRoughnessTextureEnabled&&!this._baseDiffuseRoughnessTexture.isReadyOrNotBlocking()||this._ambientTexture&&S.MaterialFlags.AmbientTextureEnabled&&!this._ambientTexture.isReadyOrNotBlocking()||this._opacityTexture&&S.MaterialFlags.OpacityTextureEnabled&&!this._opacityTexture.isReadyOrNotBlocking())return!1;let e=this._getReflectionTexture();if(e&&S.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._lightmapTexture&&S.MaterialFlags.LightmapTextureEnabled&&!this._lightmapTexture.isReadyOrNotBlocking()||this._emissiveTexture&&S.MaterialFlags.EmissiveTextureEnabled&&!this._emissiveTexture.isReadyOrNotBlocking())return!1;if(S.MaterialFlags.SpecularTextureEnabled){if(this._metallicTexture){if(!this._metallicTexture.isReadyOrNotBlocking())return!1}else if(this._reflectivityTexture&&!this._reflectivityTexture.isReadyOrNotBlocking())return!1;if(this._metallicReflectanceTexture&&!this._metallicReflectanceTexture.isReadyOrNotBlocking()||this._reflectanceTexture&&!this._reflectanceTexture.isReadyOrNotBlocking()||this._microSurfaceTexture&&!this._microSurfaceTexture.isReadyOrNotBlocking())return!1}if(l.getCaps().standardDerivatives&&this._bumpTexture&&S.MaterialFlags.BumpTextureEnabled&&!this._disableBumpMap&&!this._bumpTexture.isReady()||this._environmentBRDFTexture&&S.MaterialFlags.ReflectionTextureEnabled&&!this._environmentBRDFTexture.isReady())return!1}if(this._eventInfo.isReadyForSubMesh=!0,this._eventInfo.defines=r,this._eventInfo.subMesh=t,this._callbackPluginEventIsReadyForSubMesh(this._eventInfo),!this._eventInfo.isReadyForSubMesh||r._areImageProcessingDirty&&this._imageProcessingConfiguration&&!this._imageProcessingConfiguration.isReady())return!1;if(r.AREALIGHTUSED||r.CLUSTLIGHT_BATCH){for(let t=0;t<e.lightSources.length;t++)if(!e.lightSources[t]._isReady())return!1}if(l.getCaps().standardDerivatives||e.isVerticesDataPresent(u.VertexBuffer.NormalKind)||(e.createNormals(!0),a.Logger.Warn("PBRMaterial: Normals have been created for the mesh: "+e.name)),!(0,I.AreLightsTexturesReady)(n,e,this._maxSimultaneousLights,this._disableLighting))return!1;let o=t.effect,h=r._areLightsDisposed,T=this._prepareEffect(e,t.getRenderingMesh(),r,this.onCompiled,this.onError,i,null),_=!1;if(T)if(this._onEffectCreatedObservable&&(J.effect=T,J.subMesh=t,this._onEffectCreatedObservable.notifyObservers(J)),this.allowShaderHotSwapping&&o&&!T.isReady()){if(r.markAsUnprocessed(),_=this.isFrozen,h)return r._areLightsDisposed=!0,!1}else n.resetCachedMaterial(),t.setEffect(T,r,this._materialContext);return!!t.effect&&!!t.effect.isReady()&&(r._renderId=n.getRenderId(),s._wasPreviouslyReady=!_,s._wasPreviouslyUsingInstances=!!i,this._checkScenePerformancePriority(),!0)}isMetallicWorkflow(){return null!=this._metallic||null!=this._roughness||!!this._metallicTexture}_prepareEffect(t,i,s,r=null,a=null,n=null,l=null){if(this._prepareDefines(t,i,s,n,l),!s.isDirty)return null;s.markAsProcessed();let o=this.getScene().getEngine(),h=new m.EffectFallbacks,T=0;s.USESPHERICALINVERTEX&&h.addFallback(T++,"USESPHERICALINVERTEX"),s.FOG&&h.addFallback(T,"FOG"),s.SPECULARAA&&h.addFallback(T,"SPECULARAA"),s.POINTSIZE&&h.addFallback(T,"POINTSIZE"),s.LOGARITHMICDEPTH&&h.addFallback(T,"LOGARITHMICDEPTH"),s.PARALLAX&&h.addFallback(T,"PARALLAX"),s.PARALLAX_RHS&&h.addFallback(T,"PARALLAX_RHS"),s.PARALLAXOCCLUSION&&h.addFallback(T++,"PARALLAXOCCLUSION"),s.ENVIRONMENTBRDF&&h.addFallback(T++,"ENVIRONMENTBRDF"),s.TANGENT&&h.addFallback(T++,"TANGENT"),s.BUMP&&h.addFallback(T++,"BUMP"),T=(0,I.HandleFallbacksForShadows)(s,h,this._maxSimultaneousLights,T),s.SPECULARTERM&&h.addFallback(T++,"SPECULARTERM"),s.USESPHERICALFROMREFLECTIONMAP&&h.addFallback(T++,"USESPHERICALFROMREFLECTIONMAP"),s.USEIRRADIANCEMAP&&h.addFallback(T++,"USEIRRADIANCEMAP"),s.LIGHTMAP&&h.addFallback(T++,"LIGHTMAP"),s.NORMAL&&h.addFallback(T++,"NORMAL"),s.AMBIENT&&h.addFallback(T++,"AMBIENT"),s.EMISSIVE&&h.addFallback(T++,"EMISSIVE"),s.VERTEXCOLOR&&h.addFallback(T++,"VERTEXCOLOR"),s.MORPHTARGETS&&h.addFallback(T++,"MORPHTARGETS"),s.MULTIVIEW&&h.addFallback(0,"MULTIVIEW");let _=[u.VertexBuffer.PositionKind];s.NORMAL&&_.push(u.VertexBuffer.NormalKind),s.TANGENT&&_.push(u.VertexBuffer.TangentKind);for(let e=1;e<=6;++e)s["UV"+e]&&_.push(`uv${1===e?"":e}`);s.VERTEXCOLOR&&_.push(u.VertexBuffer.ColorKind),(0,I.PrepareAttributesForBones)(_,t,s,h),(0,I.PrepareAttributesForInstances)(_,s),(0,I.PrepareAttributesForMorphTargets)(_,t,s),(0,I.PrepareAttributesForBakedVertexAnimation)(_,t,s);let c="pbr",d=["world","view","viewProjection","vEyePosition","vLightsType","vAmbientColor","vAlbedoColor","baseWeight","baseDiffuseRoughness","vReflectivityColor","vMetallicReflectanceFactors","vEmissiveColor","visibility","vFogInfos","vFogColor","pointSize","vAlbedoInfos","vBaseWeightInfos","vBaseDiffuseRoughnessInfos","vAmbientInfos","vOpacityInfos","vEmissiveInfos","vReflectivityInfos","vMetallicReflectanceInfos","vReflectanceInfos","vMicroSurfaceSamplerInfos","vBumpInfos","vLightmapInfos","mBones","albedoMatrix","baseWeightMatrix","baseDiffuseRoughnessMatrix","ambientMatrix","opacityMatrix","emissiveMatrix","reflectivityMatrix","normalMatrix","microSurfaceSamplerMatrix","bumpMatrix","lightmapMatrix","metallicReflectanceMatrix","reflectanceMatrix","vLightingIntensity","logarithmicDepthConstant","vTangentSpaceParams","boneTextureInfo","vDebugMode","morphTargetTextureInfo","morphTargetTextureIndices","cameraInfo","vTextureRepetitionHexTilingParams"],p=["albedoSampler","baseWeightSampler","baseDiffuseRoughnessSampler","reflectivitySampler","ambientSampler","emissiveSampler","bumpSampler","lightmapSampler","opacitySampler","microSurfaceSampler","environmentBrdfSampler","boneSampler","metallicReflectanceSampler","reflectanceSampler","morphTargets","oitDepthSampler","oitFrontColorSampler","areaLightsLTC1Sampler","areaLightsLTC2Sampler"];(0,I.PrepareUniformsAndSamplersForIBL)(d,p,!0);let x=["Material","Scene","Mesh"],R={maxSimultaneousLights:this._maxSimultaneousLights,maxSimultaneousMorphTargets:s.NUM_MORPH_INFLUENCERS};if(this._eventInfo.fallbacks=h,this._eventInfo.fallbackRank=T,this._eventInfo.defines=s,this._eventInfo.uniforms=d,this._eventInfo.attributes=_,this._eventInfo.samplers=p,this._eventInfo.uniformBuffersNames=x,this._eventInfo.customCode=void 0,this._eventInfo.mesh=t,this._eventInfo.indexParameters=R,this._callbackPluginEventGeneric(128,this._eventInfo),w.MaterialHelperGeometryRendering.AddUniformsAndSamplers(d,p),E.PrePassConfiguration.AddUniforms(d),E.PrePassConfiguration.AddSamplers(p),(0,Y.AddClipPlaneUniforms)(d),this._useVertexPulling){let e=i?.geometry;e&&(this._vertexPullingMetadata=(0,W.PrepareVertexPullingUniforms)(e),this._vertexPullingMetadata&&this._vertexPullingMetadata.forEach((e,t)=>{d.push(`vp_${t}_info`)}))}else this._vertexPullingMetadata=null;A.ImageProcessingConfiguration&&(A.ImageProcessingConfiguration.PrepareUniforms(d,s),A.ImageProcessingConfiguration.PrepareSamplers(p,s)),(0,I.PrepareUniformsAndSamplersList)({uniformsNames:d,uniformBuffersNames:x,samplers:p,defines:s,maxSimultaneousLights:this._maxSimultaneousLights,shaderLanguage:this._shaderLanguage});let S={};this.customShaderNameResolve&&(c=this.customShaderNameResolve(c,d,x,p,s,_,S));let f=s.toString(),C=o.createEffect(c,{attributes:_,uniformsNames:d,uniformBuffersNames:x,samplers:p,defines:f,fallbacks:h,onCompiled:r,onError:a,indexParameters:R,processFinalCode:S.processFinalCode,processCodeAfterIncludes:this._eventInfo.customCode,multiTarget:s.PREPASS,shaderLanguage:this._shaderLanguage,extraInitializationsAsync:this._shadersLoaded?void 0:async()=>{1===this.shaderLanguage?await Promise.all([e.A(49219),e.A(8331)]):await Promise.all([e.A(19432),e.A(64102)]),this._shadersLoaded=!0}},o);return this._eventInfo.customCode=void 0,C}_prepareDefines(e,t,i,s=null,r=null){let a=t.hasThinInstances,n=this.getScene(),l=n.getEngine();(0,I.PrepareDefinesForLights)(n,e,i,!0,this._maxSimultaneousLights,this._disableLighting),i._needNormals=!0,(0,I.PrepareDefinesForMultiview)(n,i);let o=this.needAlphaBlendingForMesh(e)&&this.getScene().useOrderIndependentTransparency;if((0,I.PrepareDefinesForPrePass)(n,i,this.canRenderToMRT&&!o),(0,I.PrepareDefinesForOIT)(n,i,o),w.MaterialHelperGeometryRendering.PrepareDefines(l.currentRenderPassId,e,i),i.METALLICWORKFLOW=this.isMetallicWorkflow(),i._areTexturesDirty){i._needUVs=!1;for(let e=1;e<=6;++e)i["MAINUV"+e]=!1;if(n.texturesEnabled){i.ALBEDODIRECTUV=0,i.BASE_WEIGHTDIRECTUV=0,i.BASE_DIFFUSE_ROUGHNESSDIRECTUV=0,i.AMBIENTDIRECTUV=0,i.OPACITYDIRECTUV=0,i.EMISSIVEDIRECTUV=0,i.REFLECTIVITYDIRECTUV=0,i.MICROSURFACEMAPDIRECTUV=0,i.METALLIC_REFLECTANCEDIRECTUV=0,i.REFLECTANCEDIRECTUV=0,i.BUMPDIRECTUV=0,i.LIGHTMAPDIRECTUV=0,l.getCaps().textureLOD&&(i.LODBASEDMICROSFURACE=!0),this._albedoTexture&&S.MaterialFlags.DiffuseTextureEnabled?((0,I.PrepareDefinesForMergedUV)(this._albedoTexture,i,"ALBEDO"),i.GAMMAALBEDO=this._albedoTexture.gammaSpace):i.ALBEDO=!1,this._baseWeightTexture&&S.MaterialFlags.BaseWeightTextureEnabled?(0,I.PrepareDefinesForMergedUV)(this._baseWeightTexture,i,"BASE_WEIGHT"):i.BASE_WEIGHT=!1,this._baseDiffuseRoughnessTexture&&S.MaterialFlags.BaseDiffuseRoughnessTextureEnabled?(0,I.PrepareDefinesForMergedUV)(this._baseDiffuseRoughnessTexture,i,"BASE_DIFFUSE_ROUGHNESS"):i.BASE_DIFFUSE_ROUGHNESS=!1,this._ambientTexture&&S.MaterialFlags.AmbientTextureEnabled?((0,I.PrepareDefinesForMergedUV)(this._ambientTexture,i,"AMBIENT"),i.AMBIENTINGRAYSCALE=this._useAmbientInGrayScale):i.AMBIENT=!1,this._opacityTexture&&S.MaterialFlags.OpacityTextureEnabled?((0,I.PrepareDefinesForMergedUV)(this._opacityTexture,i,"OPACITY"),i.OPACITYRGB=this._opacityTexture.getAlphaFromRGB):i.OPACITY=!1;let e=this._getReflectionTexture(),t=this._forceIrradianceInFragment||this.realTimeFiltering||this._twoSidedLighting||l.getCaps().maxVaryingVectors<=8||null!=this._baseDiffuseRoughnessTexture;(0,I.PrepareDefinesForIBL)(n,e,i,this.realTimeFiltering,this.realTimeFilteringQuality,!t),this._lightmapTexture&&S.MaterialFlags.LightmapTextureEnabled?((0,I.PrepareDefinesForMergedUV)(this._lightmapTexture,i,"LIGHTMAP"),i.USELIGHTMAPASSHADOWMAP=this._useLightmapAsShadowmap,i.GAMMALIGHTMAP=this._lightmapTexture.gammaSpace,i.RGBDLIGHTMAP=this._lightmapTexture.isRGBD):i.LIGHTMAP=!1,this._emissiveTexture&&S.MaterialFlags.EmissiveTextureEnabled?((0,I.PrepareDefinesForMergedUV)(this._emissiveTexture,i,"EMISSIVE"),i.GAMMAEMISSIVE=this._emissiveTexture.gammaSpace):i.EMISSIVE=!1,S.MaterialFlags.SpecularTextureEnabled?(this._metallicTexture?((0,I.PrepareDefinesForMergedUV)(this._metallicTexture,i,"REFLECTIVITY"),i.ROUGHNESSSTOREINMETALMAPALPHA=this._useRoughnessFromMetallicTextureAlpha,i.ROUGHNESSSTOREINMETALMAPGREEN=!this._useRoughnessFromMetallicTextureAlpha&&this._useRoughnessFromMetallicTextureGreen,i.METALLNESSSTOREINMETALMAPBLUE=this._useMetallnessFromMetallicTextureBlue,i.AOSTOREINMETALMAPRED=this._useAmbientOcclusionFromMetallicTextureRed,i.REFLECTIVITY_GAMMA=!1):this._reflectivityTexture?((0,I.PrepareDefinesForMergedUV)(this._reflectivityTexture,i,"REFLECTIVITY"),i.MICROSURFACEFROMREFLECTIVITYMAP=this._useMicroSurfaceFromReflectivityMapAlpha,i.MICROSURFACEAUTOMATIC=this._useAutoMicroSurfaceFromReflectivityMap,i.REFLECTIVITY_GAMMA=this._reflectivityTexture.gammaSpace):i.REFLECTIVITY=!1,this._metallicReflectanceTexture||this._reflectanceTexture?(i.METALLIC_REFLECTANCE_USE_ALPHA_ONLY=this._useOnlyMetallicFromMetallicReflectanceTexture,this._metallicReflectanceTexture?((0,I.PrepareDefinesForMergedUV)(this._metallicReflectanceTexture,i,"METALLIC_REFLECTANCE"),i.METALLIC_REFLECTANCE_GAMMA=this._metallicReflectanceTexture.gammaSpace):i.METALLIC_REFLECTANCE=!1,this._reflectanceTexture&&(!this._metallicReflectanceTexture||this._metallicReflectanceTexture&&this._useOnlyMetallicFromMetallicReflectanceTexture)?((0,I.PrepareDefinesForMergedUV)(this._reflectanceTexture,i,"REFLECTANCE"),i.REFLECTANCE_GAMMA=this._reflectanceTexture.gammaSpace):i.REFLECTANCE=!1):(i.METALLIC_REFLECTANCE=!1,i.REFLECTANCE=!1),this._microSurfaceTexture?(0,I.PrepareDefinesForMergedUV)(this._microSurfaceTexture,i,"MICROSURFACEMAP"):i.MICROSURFACEMAP=!1):(i.REFLECTIVITY=!1,i.MICROSURFACEMAP=!1),l.getCaps().standardDerivatives&&this._bumpTexture&&S.MaterialFlags.BumpTextureEnabled&&!this._disableBumpMap?((0,I.PrepareDefinesForMergedUV)(this._bumpTexture,i,"BUMP"),this._useParallax&&this._albedoTexture&&S.MaterialFlags.DiffuseTextureEnabled?(i.PARALLAX=!0,i.PARALLAX_RHS=n.useRightHandedSystem,i.PARALLAXOCCLUSION=!!this._useParallaxOcclusion):i.PARALLAX=!1,i.OBJECTSPACE_NORMALMAP=this._useObjectSpaceNormalMap):(i.BUMP=!1,i.PARALLAX=!1,i.PARALLAX_RHS=!1,i.PARALLAXOCCLUSION=!1,i.OBJECTSPACE_NORMALMAP=!1),this._environmentBRDFTexture&&S.MaterialFlags.ReflectionTextureEnabled?(i.ENVIRONMENTBRDF=!0,i.ENVIRONMENTBRDF_RGBD=this._environmentBRDFTexture.isRGBD):(i.ENVIRONMENTBRDF=!1,i.ENVIRONMENTBRDF_RGBD=!1),this._shouldUseAlphaFromAlbedoTexture()?i.ALPHAFROMALBEDO=!0:i.ALPHAFROMALBEDO=!1}i.SPECULAROVERALPHA=this._useSpecularOverAlpha,this._lightFalloff===et.LIGHTFALLOFF_STANDARD?(i.USEPHYSICALLIGHTFALLOFF=!1,i.USEGLTFLIGHTFALLOFF=!1):this._lightFalloff===et.LIGHTFALLOFF_GLTF?(i.USEPHYSICALLIGHTFALLOFF=!1,i.USEGLTFLIGHTFALLOFF=!0):(i.USEPHYSICALLIGHTFALLOFF=!0,i.USEGLTFLIGHTFALLOFF=!1),i.RADIANCEOVERALPHA=this._useRadianceOverAlpha,!this.backFaceCulling&&this._twoSidedLighting?i.TWOSIDEDLIGHTING=!0:i.TWOSIDEDLIGHTING=!1,i.MIRRORED=!!n._mirroredCameraPosition,i.SPECULARAA=l.getCaps().standardDerivatives&&this._enableSpecularAntiAliasing}(i._areTexturesDirty||i._areMiscDirty)&&(i.ALPHATESTVALUE=`${this._alphaCutOff}${this._alphaCutOff%1==0?".":""}`,i.PREMULTIPLYALPHA=7===this.alphaMode||8===this.alphaMode,i.ALPHABLEND=this.needAlphaBlendingForMesh(e),i.ALPHAFRESNEL=this._useAlphaFresnel||this._useLinearAlphaFresnel,i.LINEARALPHAFRESNEL=this._useLinearAlphaFresnel),i._areTexturesDirty&&(i.TEXTURE_REPETITION_MODE=l.version>1||l.isWebGPU?this.textureRepetitionMode:0),i._areImageProcessingDirty&&this._imageProcessingConfiguration&&this._imageProcessingConfiguration.prepareDefines(i),i.FORCENORMALFORWARD=this._forceNormalForward,i.RADIANCEOCCLUSION=this._useRadianceOcclusion,i.HORIZONOCCLUSION=this._useHorizonOcclusion,i._areMiscDirty&&((0,I.PrepareDefinesForMisc)(e,n,this._useLogarithmicDepth,this.pointsCloud,this.fogEnabled,this.needAlphaTestingForMesh(e),i,this._applyDecalMapAfterDetailMap,this._useVertexPulling,t,this._isVertexOutputInvariant),i.UNLIT=this._unlit||(this.pointsCloud||this.wireframe)&&!e.isVerticesDataPresent(u.VertexBuffer.NormalKind),i.DEBUGMODE=this._debugMode),(0,I.PrepareDefinesForFrameBoundValues)(n,l,this,i,!!s,r,a),this._eventInfo.defines=i,this._eventInfo.mesh=e,this._callbackPluginEventPrepareDefinesBeforeAttributes(this._eventInfo),(0,I.PrepareDefinesForAttributes)(e,i,!0,!0,!0,this._transparencyMode!==et.PBRMATERIAL_OPAQUE),this._callbackPluginEventPrepareDefines(this._eventInfo)}forceCompilation(e,t,i){let s={clipPlane:!1,useInstances:!1,...i};this._uniformBufferLayoutBuilt||this.buildUniformLayout(),this._callbackPluginEventGeneric(4,this._eventInfo),(()=>{if(this._breakShaderLoadedCheck)return;let i=new q(this._eventInfo.defineNames),r=this._prepareEffect(e,e,i,void 0,void 0,s.useInstances,s.clipPlane);this._onEffectCreatedObservable&&(J.effect=r,J.subMesh=null,this._onEffectCreatedObservable.notifyObservers(J)),r.isReady()?t&&t(this):r.onCompileObservable.add(()=>{t&&t(this)})})()}buildUniformLayout(){let e=this._uniformBuffer;e.addUniform("vAlbedoInfos",2),e.addUniform("vBaseWeightInfos",2),e.addUniform("vBaseDiffuseRoughnessInfos",2),e.addUniform("vAmbientInfos",4),e.addUniform("vOpacityInfos",2),e.addUniform("vEmissiveInfos",2),e.addUniform("vLightmapInfos",2),e.addUniform("vReflectivityInfos",3),e.addUniform("vMicroSurfaceSamplerInfos",2),e.addUniform("vBumpInfos",3),e.addUniform("albedoMatrix",16),e.addUniform("baseWeightMatrix",16),e.addUniform("baseDiffuseRoughnessMatrix",16),e.addUniform("ambientMatrix",16),e.addUniform("opacityMatrix",16),e.addUniform("emissiveMatrix",16),e.addUniform("lightmapMatrix",16),e.addUniform("reflectivityMatrix",16),e.addUniform("microSurfaceSamplerMatrix",16),e.addUniform("bumpMatrix",16),e.addUniform("vTangentSpaceParams",2),e.addUniform("vAlbedoColor",4),e.addUniform("baseWeight",1),e.addUniform("baseDiffuseRoughness",1),e.addUniform("vLightingIntensity",4),e.addUniform("pointSize",1),e.addUniform("vReflectivityColor",4),e.addUniform("vEmissiveColor",3),e.addUniform("vAmbientColor",3),e.addUniform("vDebugMode",2),e.addUniform("vMetallicReflectanceFactors",4),e.addUniform("vMetallicReflectanceInfos",2),e.addUniform("metallicReflectanceMatrix",16),e.addUniform("vReflectanceInfos",2),e.addUniform("reflectanceMatrix",16),e.addUniform("cameraInfo",4),e.addUniform("vTextureRepetitionHexTilingParams",4),(0,I.PrepareUniformLayoutForIBL)(e,!0,!0,!0,!0,!0),super.buildUniformLayout()}bindForSubMesh(e,t,i){let s=this.getScene(),a=i.materialDefines;if(!a)return;let n=i.effect;if(!n)return;this._activeEffect=n,t.getMeshUniformBuffer().bindToEffect(n,"Mesh"),t.transferToEffect(e);let o=s.getEngine();this._uniformBuffer.bindToEffect(n,"Material"),this.prePassConfiguration.bindForSubMesh(this._activeEffect,s,t,e,this.isFrozen),w.MaterialHelperGeometryRendering.Bind(o.currentRenderPassId,this._activeEffect,t,e,this);let u=s.activeCamera;u?this._uniformBuffer.updateFloat4("cameraInfo",u.minZ,u.maxZ,0,0):this._uniformBuffer.updateFloat4("cameraInfo",0,0,0,0);let h=this.textureRepetitionHexTilingParams;this._uniformBuffer.updateFloat4("vTextureRepetitionHexTilingParams",h[0],h[1],h[2],h[3]),this._eventInfo.subMesh=i,this._callbackPluginEventHardBindForSubMesh(this._eventInfo),a.OBJECTSPACE_NORMALMAP&&(e.toNormalMatrix(this._normalMatrix),this.bindOnlyNormalMatrix(this._normalMatrix));let T=this._mustRebind(s,n,i,t.visibility),_=o._features.needToAlwaysBindUniformBuffers;(0,I.BindBonesParameters)(t,this._activeEffect,this.prePassConfiguration),this._vertexPullingMetadata&&(0,W.BindVertexPullingUniforms)(this._activeEffect,this._vertexPullingMetadata);let c=null,E=this._uniformBuffer;if(T){if(this.bindViewProjection(n),c=this._getReflectionTexture(),!E.useUbo||!this.isFrozen||!E.isSync||i._drawWrapper._forceRebindOnNextCall){if(s.texturesEnabled&&(this._albedoTexture&&S.MaterialFlags.DiffuseTextureEnabled&&(E.updateFloat2("vAlbedoInfos",this._albedoTexture.coordinatesIndex,this._albedoTexture.level),(0,I.BindTextureMatrix)(this._albedoTexture,E,"albedo")),this._baseWeightTexture&&S.MaterialFlags.BaseWeightTextureEnabled&&(E.updateFloat2("vBaseWeightInfos",this._baseWeightTexture.coordinatesIndex,this._baseWeightTexture.level),(0,I.BindTextureMatrix)(this._baseWeightTexture,E,"baseWeight")),this._baseDiffuseRoughnessTexture&&S.MaterialFlags.BaseDiffuseRoughnessTextureEnabled&&(E.updateFloat2("vBaseDiffuseRoughnessInfos",this._baseDiffuseRoughnessTexture.coordinatesIndex,this._baseDiffuseRoughnessTexture.level),(0,I.BindTextureMatrix)(this._baseDiffuseRoughnessTexture,E,"baseDiffuseRoughness")),this._ambientTexture&&S.MaterialFlags.AmbientTextureEnabled&&(E.updateFloat4("vAmbientInfos",this._ambientTexture.coordinatesIndex,this._ambientTexture.level,this._ambientTextureStrength,this._ambientTextureImpactOnAnalyticalLights),(0,I.BindTextureMatrix)(this._ambientTexture,E,"ambient")),this._opacityTexture&&S.MaterialFlags.OpacityTextureEnabled&&(E.updateFloat2("vOpacityInfos",this._opacityTexture.coordinatesIndex,this._opacityTexture.level),(0,I.BindTextureMatrix)(this._opacityTexture,E,"opacity")),this._emissiveTexture&&S.MaterialFlags.EmissiveTextureEnabled&&(E.updateFloat2("vEmissiveInfos",this._emissiveTexture.coordinatesIndex,this._emissiveTexture.level),(0,I.BindTextureMatrix)(this._emissiveTexture,E,"emissive")),this._lightmapTexture&&S.MaterialFlags.LightmapTextureEnabled&&(E.updateFloat2("vLightmapInfos",this._lightmapTexture.coordinatesIndex,this._lightmapTexture.level),(0,I.BindTextureMatrix)(this._lightmapTexture,E,"lightmap")),S.MaterialFlags.SpecularTextureEnabled&&(this._metallicTexture?(E.updateFloat3("vReflectivityInfos",this._metallicTexture.coordinatesIndex,this._metallicTexture.level,this._ambientTextureStrength),(0,I.BindTextureMatrix)(this._metallicTexture,E,"reflectivity")):this._reflectivityTexture&&(E.updateFloat3("vReflectivityInfos",this._reflectivityTexture.coordinatesIndex,this._reflectivityTexture.level,1),(0,I.BindTextureMatrix)(this._reflectivityTexture,E,"reflectivity")),this._metallicReflectanceTexture&&(E.updateFloat2("vMetallicReflectanceInfos",this._metallicReflectanceTexture.coordinatesIndex,this._metallicReflectanceTexture.level),(0,I.BindTextureMatrix)(this._metallicReflectanceTexture,E,"metallicReflectance")),this._reflectanceTexture&&a.REFLECTANCE&&(E.updateFloat2("vReflectanceInfos",this._reflectanceTexture.coordinatesIndex,this._reflectanceTexture.level),(0,I.BindTextureMatrix)(this._reflectanceTexture,E,"reflectance")),this._microSurfaceTexture&&(E.updateFloat2("vMicroSurfaceSamplerInfos",this._microSurfaceTexture.coordinatesIndex,this._microSurfaceTexture.level),(0,I.BindTextureMatrix)(this._microSurfaceTexture,E,"microSurfaceSampler"))),this._bumpTexture&&o.getCaps().standardDerivatives&&S.MaterialFlags.BumpTextureEnabled&&!this._disableBumpMap&&(E.updateFloat3("vBumpInfos",this._bumpTexture.coordinatesIndex,this._bumpTexture.level,this._parallaxScaleBias),(0,I.BindTextureMatrix)(this._bumpTexture,E,"bump"),s._mirroredCameraPosition?E.updateFloat2("vTangentSpaceParams",this._invertNormalMapX?1:-1,this._invertNormalMapY?1:-1):E.updateFloat2("vTangentSpaceParams",this._invertNormalMapX?-1:1,this._invertNormalMapY?-1:1)),(0,I.BindIBLParameters)(s,a,E,this._reflectionColor,c,this.realTimeFiltering,!0,!0,!0,!0,!0)),this.pointsCloud&&E.updateFloat("pointSize",this.pointSize),a.METALLICWORKFLOW){r.TmpColors.Color4[0].r=void 0===this._metallic||null===this._metallic?1:this._metallic,r.TmpColors.Color4[0].g=void 0===this._roughness||null===this._roughness?1:this._roughness;let e=this.subSurface?._indexOfRefraction??1.5;r.TmpColors.Color4[0].b=e;let t=Math.pow((e-1)/(e+1),2);r.TmpColors.Color4[0].a=t,E.updateDirectColor4("vReflectivityColor",r.TmpColors.Color4[0]),E.updateColor4("vMetallicReflectanceFactors",this._metallicReflectanceColor,this._metallicF0Factor)}else E.updateColor4("vReflectivityColor",this._reflectivityColor,this._microSurface);E.updateColor3("vEmissiveColor",S.MaterialFlags.EmissiveTextureEnabled?this._emissiveColor:r.Color3.BlackReadOnly),!a.SS_REFRACTION&&this.subSurface?._linkRefractionWithTransparency?E.updateColor4("vAlbedoColor",this._albedoColor,1):E.updateColor4("vAlbedoColor",this._albedoColor,this.alpha),E.updateFloat("baseWeight",this._baseWeight),E.updateFloat("baseDiffuseRoughness",this._baseDiffuseRoughness||0),this._lightingInfos.x=this._directIntensity,this._lightingInfos.y=this._emissiveIntensity,this._lightingInfos.z=this._environmentIntensity*s.environmentIntensity,this._lightingInfos.w=this._specularIntensity,E.updateVector4("vLightingIntensity",this._lightingInfos),s.ambientColor.multiplyToRef(this._ambientColor,this._globalAmbientColor),E.updateColor3("vAmbientColor",this._globalAmbientColor),E.updateFloat2("vDebugMode",this.debugLimit,this.debugFactor)}s.texturesEnabled&&(this._albedoTexture&&S.MaterialFlags.DiffuseTextureEnabled&&E.setTexture("albedoSampler",this._albedoTexture),this._baseWeightTexture&&S.MaterialFlags.BaseWeightTextureEnabled&&E.setTexture("baseWeightSampler",this._baseWeightTexture),this._baseDiffuseRoughnessTexture&&S.MaterialFlags.BaseDiffuseRoughnessTextureEnabled&&E.setTexture("baseDiffuseRoughnessSampler",this._baseDiffuseRoughnessTexture),this._ambientTexture&&S.MaterialFlags.AmbientTextureEnabled&&E.setTexture("ambientSampler",this._ambientTexture),this._opacityTexture&&S.MaterialFlags.OpacityTextureEnabled&&E.setTexture("opacitySampler",this._opacityTexture),(0,I.BindIBLSamplers)(s,a,E,c,this.realTimeFiltering),a.ENVIRONMENTBRDF&&E.setTexture("environmentBrdfSampler",this._environmentBRDFTexture),this._emissiveTexture&&S.MaterialFlags.EmissiveTextureEnabled&&E.setTexture("emissiveSampler",this._emissiveTexture),this._lightmapTexture&&S.MaterialFlags.LightmapTextureEnabled&&E.setTexture("lightmapSampler",this._lightmapTexture),S.MaterialFlags.SpecularTextureEnabled&&(this._metallicTexture?E.setTexture("reflectivitySampler",this._metallicTexture):this._reflectivityTexture&&E.setTexture("reflectivitySampler",this._reflectivityTexture),this._metallicReflectanceTexture&&E.setTexture("metallicReflectanceSampler",this._metallicReflectanceTexture),this._reflectanceTexture&&a.REFLECTANCE&&E.setTexture("reflectanceSampler",this._reflectanceTexture),this._microSurfaceTexture&&E.setTexture("microSurfaceSampler",this._microSurfaceTexture)),this._bumpTexture&&o.getCaps().standardDerivatives&&S.MaterialFlags.BumpTextureEnabled&&!this._disableBumpMap&&E.setTexture("bumpSampler",this._bumpTexture)),this.getScene().useOrderIndependentTransparency&&this.needAlphaBlendingForMesh(t)&&this.getScene().depthPeelingRenderer.bind(n),this._eventInfo.subMesh=i,this._callbackPluginEventBindForSubMesh(this._eventInfo),(0,Y.BindClipPlane)(this._activeEffect,this,s),this.bindEyePosition(n)}else _&&(this._needToBindSceneUbo=!0);(T||!this.isFrozen||_)&&s.lightsEnabled&&!this._disableLighting&&(0,I.BindLights)(s,t,this._activeEffect,a,this._maxSimultaneousLights),(T||!this.isFrozen)&&((s.fogEnabled&&t.applyFog&&s.fogMode!==l.Scene.FOGMODE_NONE||c||this.subSurface.refractionTexture||t.receiveShadows||a.PREPASS||a.CLUSTLIGHT_BATCH)&&this.bindView(n),(0,I.BindFogParameters)(s,t,this._activeEffect,!0),a.NUM_MORPH_INFLUENCERS&&(0,I.BindMorphTargetParameters)(t,this._activeEffect),a.BAKED_VERTEX_ANIMATION_TEXTURE&&t.bakedVertexAnimationManager?.bind(n,a.INSTANCES),this._imageProcessingConfiguration.bind(this._activeEffect),(0,I.BindLogDepth)(a,this._activeEffect,s)),this._afterBind(t,this._activeEffect,i),E.update()}getAnimatables(){let e=super.getAnimatables();return this._albedoTexture&&this._albedoTexture.animations&&this._albedoTexture.animations.length>0&&e.push(this._albedoTexture),this._baseWeightTexture&&this._baseWeightTexture.animations&&this._baseWeightTexture.animations.length>0&&e.push(this._baseWeightTexture),this._baseDiffuseRoughnessTexture&&this._baseDiffuseRoughnessTexture.animations&&this._baseDiffuseRoughnessTexture.animations.length>0&&e.push(this._baseDiffuseRoughnessTexture),this._ambientTexture&&this._ambientTexture.animations&&this._ambientTexture.animations.length>0&&e.push(this._ambientTexture),this._opacityTexture&&this._opacityTexture.animations&&this._opacityTexture.animations.length>0&&e.push(this._opacityTexture),this._reflectionTexture&&this._reflectionTexture.animations&&this._reflectionTexture.animations.length>0&&e.push(this._reflectionTexture),this._emissiveTexture&&this._emissiveTexture.animations&&this._emissiveTexture.animations.length>0&&e.push(this._emissiveTexture),this._metallicTexture&&this._metallicTexture.animations&&this._metallicTexture.animations.length>0?e.push(this._metallicTexture):this._reflectivityTexture&&this._reflectivityTexture.animations&&this._reflectivityTexture.animations.length>0&&e.push(this._reflectivityTexture),this._bumpTexture&&this._bumpTexture.animations&&this._bumpTexture.animations.length>0&&e.push(this._bumpTexture),this._lightmapTexture&&this._lightmapTexture.animations&&this._lightmapTexture.animations.length>0&&e.push(this._lightmapTexture),this._metallicReflectanceTexture&&this._metallicReflectanceTexture.animations&&this._metallicReflectanceTexture.animations.length>0&&e.push(this._metallicReflectanceTexture),this._reflectanceTexture&&this._reflectanceTexture.animations&&this._reflectanceTexture.animations.length>0&&e.push(this._reflectanceTexture),this._microSurfaceTexture&&this._microSurfaceTexture.animations&&this._microSurfaceTexture.animations.length>0&&e.push(this._microSurfaceTexture),e}_getReflectionTexture(){return this._reflectionTexture?this._reflectionTexture:this.getScene().environmentTexture}getActiveTextures(){let e=super.getActiveTextures();return this._albedoTexture&&e.push(this._albedoTexture),this._baseWeightTexture&&e.push(this._baseWeightTexture),this._baseDiffuseRoughnessTexture&&e.push(this._baseDiffuseRoughnessTexture),this._ambientTexture&&e.push(this._ambientTexture),this._opacityTexture&&e.push(this._opacityTexture),this._reflectionTexture&&e.push(this._reflectionTexture),this._emissiveTexture&&e.push(this._emissiveTexture),this._reflectivityTexture&&e.push(this._reflectivityTexture),this._metallicTexture&&e.push(this._metallicTexture),this._metallicReflectanceTexture&&e.push(this._metallicReflectanceTexture),this._reflectanceTexture&&e.push(this._reflectanceTexture),this._microSurfaceTexture&&e.push(this._microSurfaceTexture),this._bumpTexture&&e.push(this._bumpTexture),this._lightmapTexture&&e.push(this._lightmapTexture),e}hasTexture(e){return!!super.hasTexture(e)||this._albedoTexture===e||this._baseWeightTexture===e||this._baseDiffuseRoughnessTexture===e||this._ambientTexture===e||this._opacityTexture===e||this._reflectionTexture===e||this._emissiveTexture===e||this._reflectivityTexture===e||this._metallicTexture===e||this._metallicReflectanceTexture===e||this._reflectanceTexture===e||this._microSurfaceTexture===e||this._bumpTexture===e||this._lightmapTexture===e||!1}setPrePassRenderer(){if(!this.subSurface?.isScatteringEnabled)return!1;let e=this.getScene().enableSubSurfaceForPrePass();return e&&(e.enabled=!0),!0}dispose(e,t){this._breakShaderLoadedCheck=!0,t&&(this._environmentBRDFTexture&&this.getScene().environmentBRDFTexture!==this._environmentBRDFTexture&&this._environmentBRDFTexture.dispose(),this._albedoTexture?.dispose(),this._baseWeightTexture?.dispose(),this._baseDiffuseRoughnessTexture?.dispose(),this._ambientTexture?.dispose(),this._opacityTexture?.dispose(),this._reflectionTexture?.dispose(),this._emissiveTexture?.dispose(),this._metallicTexture?.dispose(),this._reflectivityTexture?.dispose(),this._bumpTexture?.dispose(),this._lightmapTexture?.dispose(),this._metallicReflectanceTexture?.dispose(),this._reflectanceTexture?.dispose(),this._microSurfaceTexture?.dispose()),this._renderTargets.dispose(),this._imageProcessingConfiguration&&this._imageProcessingObserver&&this._imageProcessingConfiguration.onUpdateParameters.remove(this._imageProcessingObserver),super.dispose(e,t)}}et.PBRMATERIAL_OPAQUE=p.Material.MATERIAL_OPAQUE,et.PBRMATERIAL_ALPHATEST=p.Material.MATERIAL_ALPHATEST,et.PBRMATERIAL_ALPHABLEND=p.Material.MATERIAL_ALPHABLEND,et.PBRMATERIAL_ALPHATESTANDBLEND=p.Material.MATERIAL_ALPHATESTANDBLEND,et.DEFAULT_AO_ON_ANALYTICAL_LIGHTS=0,et.LIGHTFALLOFF_PHYSICAL=0,et.LIGHTFALLOFF_GLTF=1,et.LIGHTFALLOFF_STANDARD=2,et.ForceGLSL=!1,(0,t.__decorate)([(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],et.prototype,"debugMode",void 0),Object.getOwnPropertyDescriptor(et.prototype,"decalMap")||Object.defineProperty(et.prototype,"decalMap",(0,j._MissingSideEffectProperty)("PBRBaseMaterial","decalMap"));var ei=e.i(95397),es=e.i(48477);class er extends et{get refractionTexture(){return this.subSurface.refractionTexture}set refractionTexture(e){this.subSurface.refractionTexture=e,e?this.subSurface.isRefractionEnabled=!0:this.subSurface.linkRefractionWithTransparency||(this.subSurface.isRefractionEnabled=!1)}get indexOfRefraction(){return this.subSurface.indexOfRefraction}set indexOfRefraction(e){this.subSurface.indexOfRefraction=e}get invertRefractionY(){return this.subSurface.invertRefractionY}set invertRefractionY(e){this.subSurface.invertRefractionY=e}get linkRefractionWithTransparency(){return this.subSurface.linkRefractionWithTransparency}set linkRefractionWithTransparency(e){this.subSurface.linkRefractionWithTransparency=e,e&&(this.subSurface.isRefractionEnabled=!0)}get usePhysicalLightFalloff(){return this._lightFalloff===et.LIGHTFALLOFF_PHYSICAL}set usePhysicalLightFalloff(e){e!==this.usePhysicalLightFalloff&&(this._markAllSubMeshesAsTexturesDirty(),e?this._lightFalloff=et.LIGHTFALLOFF_PHYSICAL:this._lightFalloff=et.LIGHTFALLOFF_STANDARD)}get useGLTFLightFalloff(){return this._lightFalloff===et.LIGHTFALLOFF_GLTF}set useGLTFLightFalloff(e){e!==this.useGLTFLightFalloff&&(this._markAllSubMeshesAsTexturesDirty(),e?this._lightFalloff=et.LIGHTFALLOFF_GLTF:this._lightFalloff=et.LIGHTFALLOFF_STANDARD)}constructor(e,t,i=!1){super(e,t,i),this.directIntensity=1,this.emissiveIntensity=1,this.environmentIntensity=1,this.specularIntensity=1,this.disableBumpMap=!1,this.ambientTextureStrength=1,this.ambientTextureImpactOnAnalyticalLights=er.DEFAULT_AO_ON_ANALYTICAL_LIGHTS,this.metallicF0Factor=1,this.metallicReflectanceColor=r.Color3.White(),this.useOnlyMetallicFromMetallicReflectanceTexture=!1,this.ambientColor=new r.Color3(0,0,0),this.albedoColor=new r.Color3(1,1,1),this.baseWeight=1,this.reflectivityColor=new r.Color3(1,1,1),this.reflectionColor=new r.Color3(1,1,1),this.emissiveColor=new r.Color3(0,0,0),this.microSurface=1,this.useLightmapAsShadowmap=!1,this.useAlphaFromAlbedoTexture=!1,this.forceAlphaTest=!1,this.alphaCutOff=.4,this.useSpecularOverAlpha=!0,this.useMicroSurfaceFromReflectivityMapAlpha=!1,this.useRoughnessFromMetallicTextureAlpha=!0,this.useRoughnessFromMetallicTextureGreen=!1,this.useMetallnessFromMetallicTextureBlue=!1,this.useAmbientOcclusionFromMetallicTextureRed=!1,this.useAmbientInGrayScale=!1,this.useAutoMicroSurfaceFromReflectivityMap=!1,this.useRadianceOverAlpha=!0,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._environmentBRDFTexture=(0,s.GetEnvironmentBRDFTexture)(this.getScene())}getClassName(){return"PBRMaterial"}clone(e,t=!0,i=""){let s=ei.SerializationHelper.Clone(()=>new er(e,this.getScene()),this,{cloneTexturesOnlyOnce:t});return s.id=e,s.name=e,this.stencil.copyTo(s.stencil),this._clonePlugins(s,i),s}serialize(){let e=super.serialize();return e.customType="BABYLON.PBRMaterial",e}static Parse(e,t,i){let s=ei.SerializationHelper.Parse(()=>new er(e.name,t),e,t,i);return e.stencil&&s.stencil.parse(e.stencil,t,i),p.Material._ParsePlugins(e,s,t,i),e.clearCoat&&s.clearCoat.parse(e.clearCoat,t,i),e.anisotropy&&s.anisotropy.parse(e.anisotropy,t,i),e.brdf&&s.brdf.parse(e.brdf,t,i),e.sheen&&s.sheen.parse(e.sheen,t,i),e.subSurface&&s.subSurface.parse(e.subSurface,t,i),e.iridescence&&s.iridescence.parse(e.iridescence,t,i),s}}er.PBRMATERIAL_OPAQUE=et.PBRMATERIAL_OPAQUE,er.PBRMATERIAL_ALPHATEST=et.PBRMATERIAL_ALPHATEST,er.PBRMATERIAL_ALPHABLEND=et.PBRMATERIAL_ALPHABLEND,er.PBRMATERIAL_ALPHATESTANDBLEND=et.PBRMATERIAL_ALPHATESTANDBLEND,er.DEFAULT_AO_ON_ANALYTICAL_LIGHTS=et.DEFAULT_AO_ON_ANALYTICAL_LIGHTS,(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"directIntensity",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"emissiveIntensity",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"environmentIntensity",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"specularIntensity",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"disableBumpMap",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"albedoTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"baseWeightTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"baseDiffuseRoughnessTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"ambientTexture",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"ambientTextureStrength",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"ambientTextureImpactOnAnalyticalLights",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesAndMiscDirty")],er.prototype,"opacityTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"reflectionTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"emissiveTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"reflectivityTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"metallicTexture",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"metallic",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"roughness",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"metallicF0Factor",void 0),(0,t.__decorate)([(0,i.serializeAsColor3)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"metallicReflectanceColor",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useOnlyMetallicFromMetallicReflectanceTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"metallicReflectanceTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"reflectanceTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"microSurfaceTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"bumpTexture",void 0),(0,t.__decorate)([(0,i.serializeAsTexture)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty",null)],er.prototype,"lightmapTexture",void 0),(0,t.__decorate)([(0,i.serializeAsColor3)("ambient"),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"ambientColor",void 0),(0,t.__decorate)([(0,i.serializeAsColor3)("albedo"),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"albedoColor",void 0),(0,t.__decorate)([(0,i.serialize)("baseWeight"),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"baseWeight",void 0),(0,t.__decorate)([(0,i.serialize)("baseDiffuseRoughness"),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"baseDiffuseRoughness",void 0),(0,t.__decorate)([(0,i.serializeAsColor3)("reflectivity"),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"reflectivityColor",void 0),(0,t.__decorate)([(0,i.serializeAsColor3)("reflection"),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"reflectionColor",void 0),(0,t.__decorate)([(0,i.serializeAsColor3)("emissive"),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"emissiveColor",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"microSurface",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useLightmapAsShadowmap",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesAndMiscDirty")],er.prototype,"useAlphaFromAlbedoTexture",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesAndMiscDirty")],er.prototype,"forceAlphaTest",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesAndMiscDirty")],er.prototype,"alphaCutOff",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useSpecularOverAlpha",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useMicroSurfaceFromReflectivityMapAlpha",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useRoughnessFromMetallicTextureAlpha",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useRoughnessFromMetallicTextureGreen",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useMetallnessFromMetallicTextureBlue",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useAmbientOcclusionFromMetallicTextureRed",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useAmbientInGrayScale",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useAutoMicroSurfaceFromReflectivityMap",void 0),(0,t.__decorate)([(0,i.serialize)()],er.prototype,"usePhysicalLightFalloff",null),(0,t.__decorate)([(0,i.serialize)()],er.prototype,"useGLTFLightFalloff",null),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useRadianceOverAlpha",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useObjectSpaceNormalMap",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useParallax",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useParallaxOcclusion",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"parallaxScaleBias",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsLightsDirty")],er.prototype,"disableLighting",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"forceIrradianceInFragment",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsLightsDirty")],er.prototype,"maxSimultaneousLights",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"invertNormalMapX",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"invertNormalMapY",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"twoSidedLighting",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useAlphaFresnel",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useLinearAlphaFresnel",void 0),(0,t.__decorate)([(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"environmentBRDFTexture",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"forceNormalForward",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"enableSpecularAntiAliasing",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useHorizonOcclusion",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsTexturesDirty")],er.prototype,"useRadianceOcclusion",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],er.prototype,"unlit",void 0),(0,t.__decorate)([(0,i.serialize)(),(0,i.expandToProperty)("_markAllSubMeshesAsMiscDirty")],er.prototype,"applyDecalMapAfterDetailMap",void 0);let ea=!1;function en(){ea||(ea=!0,(0,es.RegisterClass)("BABYLON.PBRMaterial",er))}function el(){en()}e.s(["PBRMaterial",0,er,"RegisterPBRMaterial",0,el,"RegisterPbrMaterial",0,en],86176),en(),e.s([],47814),e.i(47814),e.i(86176),e.s(["PBRMaterial",0,er,"RegisterPBRMaterial",0,el,"RegisterPbrMaterial",0,en],78619)}]);
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,93891,i=>{"use strict";i.s([],63667),i.i(63667);var n=i.i(25282);i.s(["ThinEngine",()=>n.ThinEngine],93891)}]);
|