@splinetool/runtime 2.0.9 → 2.0.10
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/build/hana-ui.js +73 -43
- package/build/hana-ui.js.br +0 -0
- package/build/hana-ui.js.gz +0 -0
- package/build/hana-ui.wasm +0 -0
- package/build/hana-ui.wasm.br +0 -0
- package/build/hana-ui.wasm.gz +0 -0
- package/build/{runtime-chunk-ZTHLLGVX.js → runtime-chunk-4LKRNVPP.js} +1 -1
- package/build/{runtime-chunk-ZTHLLGVX.js.br → runtime-chunk-4LKRNVPP.js.br} +0 -0
- package/build/runtime-chunk-4LKRNVPP.js.gz +0 -0
- package/build/{runtime-chunk-3D6ELLRB.js → runtime-chunk-7FDJ7IIR.js} +1 -1
- package/build/runtime-chunk-7FDJ7IIR.js.br +0 -0
- package/build/runtime-chunk-7FDJ7IIR.js.gz +0 -0
- package/build/{runtime-chunk-5RKK7JBF.js → runtime-chunk-BLFFIB2B.js} +1 -1
- package/build/runtime-chunk-BLFFIB2B.js.br +0 -0
- package/build/runtime-chunk-BLFFIB2B.js.gz +0 -0
- package/build/{runtime-chunk-U7JVP2TI.js → runtime-chunk-CDR3AZNB.js} +1 -1
- package/build/runtime-chunk-CDR3AZNB.js.br +0 -0
- package/build/runtime-chunk-CDR3AZNB.js.gz +0 -0
- package/build/{runtime-chunk-CUH4PXNR.js → runtime-chunk-CDYE22J6.js} +1 -1
- package/build/runtime-chunk-CDYE22J6.js.br +0 -0
- package/build/runtime-chunk-CDYE22J6.js.gz +0 -0
- package/build/runtime-chunk-DZIH7EMN.js +1 -0
- package/build/runtime-chunk-DZIH7EMN.js.br +0 -0
- package/build/runtime-chunk-DZIH7EMN.js.gz +0 -0
- package/build/{runtime-chunk-SOL2NZB4.js → runtime-chunk-FN2C54JM.js} +1 -1
- package/build/runtime-chunk-FN2C54JM.js.br +0 -0
- package/build/runtime-chunk-FN2C54JM.js.gz +0 -0
- package/build/runtime-chunk-I6B5A36U.js +1 -0
- package/build/runtime-chunk-I6B5A36U.js.br +0 -0
- package/build/runtime-chunk-I6B5A36U.js.gz +0 -0
- package/build/{runtime-chunk-KRQKRJPD.js → runtime-chunk-JSRKKIOS.js} +1 -1
- package/build/runtime-chunk-JSRKKIOS.js.br +0 -0
- package/build/runtime-chunk-JSRKKIOS.js.gz +0 -0
- package/build/{runtime-chunk-LVFNCYIC.js → runtime-chunk-KKDM5MC5.js} +1 -1
- package/build/runtime-chunk-KKDM5MC5.js.br +0 -0
- package/build/runtime-chunk-KKDM5MC5.js.gz +0 -0
- package/build/{runtime-chunk-YNTJMLA5.js → runtime-chunk-L2C7JGYG.js} +1 -1
- package/build/runtime-chunk-L2C7JGYG.js.br +0 -0
- package/build/runtime-chunk-L2C7JGYG.js.gz +0 -0
- package/build/{runtime-chunk-RYIFGI7L.js → runtime-chunk-LQL2PJVX.js} +1 -1
- package/build/runtime-chunk-LQL2PJVX.js.br +0 -0
- package/build/runtime-chunk-LQL2PJVX.js.gz +0 -0
- package/build/{runtime-chunk-YANJNJO2.js → runtime-chunk-M4BPCY7K.js} +1 -1
- package/build/runtime-chunk-M4BPCY7K.js.br +0 -0
- package/build/runtime-chunk-M4BPCY7K.js.gz +0 -0
- package/build/{runtime-chunk-R3V4RB3X.js → runtime-chunk-MOZWC42D.js} +1 -1
- package/build/runtime-chunk-MOZWC42D.js.br +0 -0
- package/build/runtime-chunk-MOZWC42D.js.gz +0 -0
- package/build/{runtime-chunk-EPFYNTQQ.js → runtime-chunk-MVJAFW5H.js} +1 -1
- package/build/runtime-chunk-MVJAFW5H.js.br +1 -0
- package/build/runtime-chunk-MVJAFW5H.js.gz +0 -0
- package/build/{runtime-chunk-CXBK7LPG.js → runtime-chunk-QSJVWNNM.js} +1 -1
- package/build/runtime-chunk-QSJVWNNM.js.br +0 -0
- package/build/runtime-chunk-QSJVWNNM.js.gz +0 -0
- package/build/{runtime-chunk-VJPN4EM6.js → runtime-chunk-RTRWO43P.js} +1 -1
- package/build/runtime-chunk-RTRWO43P.js.br +0 -0
- package/build/runtime-chunk-RTRWO43P.js.gz +0 -0
- package/build/{runtime-chunk-UFFTT5MI.js → runtime-chunk-RX3SW5K2.js} +1 -1
- package/build/runtime-chunk-RX3SW5K2.js.br +0 -0
- package/build/runtime-chunk-RX3SW5K2.js.gz +0 -0
- package/build/{runtime-chunk-4FRVTTCF.js → runtime-chunk-UHCXLQHA.js} +1 -1
- package/build/runtime-chunk-UHCXLQHA.js.br +0 -0
- package/build/runtime-chunk-UHCXLQHA.js.gz +0 -0
- package/build/{runtime-chunk-FJZAL2GU.js → runtime-chunk-VNO2DW74.js} +1 -1
- package/build/runtime-chunk-VNO2DW74.js.br +0 -0
- package/build/runtime-chunk-VNO2DW74.js.gz +0 -0
- package/build/{runtime-chunk-WFTAZCXD.js → runtime-chunk-WQ2NXI3U.js} +1 -1
- package/build/runtime-chunk-WQ2NXI3U.js.br +0 -0
- package/build/runtime-chunk-WQ2NXI3U.js.gz +0 -0
- package/build/{runtime-chunk-KJLTN6RE.js → runtime-chunk-YO3XFDZF.js} +1 -1
- package/build/runtime-chunk-YO3XFDZF.js.br +0 -0
- package/build/runtime-chunk-YO3XFDZF.js.gz +0 -0
- package/build/{runtime-chunk-44F5FA4N.js → runtime-chunk-YS7K3AW3.js} +1 -1
- package/build/runtime-chunk-YS7K3AW3.js.br +0 -0
- package/build/runtime-chunk-YS7K3AW3.js.gz +0 -0
- package/build/{runtime-chunk-33KX2TOT.js → runtime-chunk-ZASM3KKC.js} +1 -1
- package/build/runtime-chunk-ZASM3KKC.js.br +0 -0
- package/build/runtime-chunk-ZASM3KKC.js.gz +0 -0
- package/build/{runtime-chunk-ROGQC3YL.js → runtime-chunk-ZLOMOV3N.js} +1 -1
- package/build/runtime-chunk-ZLOMOV3N.js.br +0 -0
- package/build/runtime-chunk-ZLOMOV3N.js.gz +0 -0
- package/build/{runtime-chunk-5MDYMRYM.js → runtime-chunk-ZM7N5SZG.js} +1 -1
- package/build/runtime-chunk-ZM7N5SZG.js.br +0 -0
- package/build/runtime-chunk-ZM7N5SZG.js.gz +0 -0
- package/build/{runtime-classicRuntime-7YZ7NLMG.js → runtime-classicRuntime-A3DEJ3YH.js} +1 -1
- package/build/runtime-classicRuntime-A3DEJ3YH.js.br +0 -0
- package/build/runtime-classicRuntime-A3DEJ3YH.js.gz +0 -0
- package/build/{runtime-cloners-H554LSFU.js → runtime-cloners-UFF7A36S.js} +1 -1
- package/build/runtime-cloners-UFF7A36S.js.br +1 -0
- package/build/runtime-cloners-UFF7A36S.js.gz +0 -0
- package/build/{runtime-components-ZCELGDQ5.js → runtime-components-EESAIEPO.js} +1 -1
- package/build/runtime-components-EESAIEPO.js.br +0 -0
- package/build/runtime-components-EESAIEPO.js.gz +0 -0
- package/build/{runtime-createDestroy-FK2ZKK66.js → runtime-createDestroy-WBIIVRMC.js} +1 -1
- package/build/runtime-createDestroy-WBIIVRMC.js.br +0 -0
- package/build/runtime-createDestroy-WBIIVRMC.js.gz +0 -0
- package/build/{runtime-dragDrop-E4OSDFGY.js → runtime-dragDrop-D45J5GQ5.js} +1 -1
- package/build/runtime-dragDrop-D45J5GQ5.js.br +0 -0
- package/build/runtime-dragDrop-D45J5GQ5.js.gz +0 -0
- package/build/{runtime-gameControls-A3BST7FA.js → runtime-gameControls-GNLQ3FT6.js} +1 -1
- package/build/runtime-gameControls-GNLQ3FT6.js.br +0 -0
- package/build/runtime-gameControls-GNLQ3FT6.js.gz +0 -0
- package/build/{runtime-hair-W5WKY4OE.js → runtime-hair-55OFZZFY.js} +1 -1
- package/build/runtime-hair-55OFZZFY.js.br +1 -0
- package/build/runtime-hair-55OFZZFY.js.gz +0 -0
- package/build/{runtime-mergeStaticGeometries-5FS3LGQQ.js → runtime-mergeStaticGeometries-NLUOSGZB.js} +1 -1
- package/build/runtime-mergeStaticGeometries-NLUOSGZB.js.br +0 -0
- package/build/runtime-mergeStaticGeometries-NLUOSGZB.js.gz +0 -0
- package/build/{runtime-miscActions-F72HQZ5I.js → runtime-miscActions-5YY5ARQT.js} +1 -1
- package/build/runtime-miscActions-5YY5ARQT.js.br +0 -0
- package/build/runtime-miscActions-5YY5ARQT.js.gz +0 -0
- package/build/{runtime-mouseHover-44D2CVLI.js → runtime-mouseHover-MTTJI6DT.js} +1 -1
- package/build/runtime-mouseHover-MTTJI6DT.js.br +0 -0
- package/build/runtime-mouseHover-MTTJI6DT.js.gz +0 -0
- package/build/{runtime-particles-5BBDNO44.js → runtime-particles-VZVZJ35I.js} +1 -1
- package/build/runtime-particles-VZVZJ35I.js.br +0 -0
- package/build/runtime-particles-VZVZJ35I.js.gz +0 -0
- package/build/{runtime-paths-YF5SB3I3.js → runtime-paths-4UDUBYZN.js} +1 -1
- package/build/runtime-paths-4UDUBYZN.js.br +0 -0
- package/build/runtime-paths-4UDUBYZN.js.gz +0 -0
- package/build/{runtime-resize-ZORLCUGS.js → runtime-resize-QYCZUOPF.js} +1 -1
- package/build/runtime-resize-QYCZUOPF.js.br +0 -0
- package/build/runtime-resize-QYCZUOPF.js.gz +0 -0
- package/build/{runtime-sceneTransition-EEJJDLOW.js → runtime-sceneTransition-FC5TQNCH.js} +1 -1
- package/build/runtime-sceneTransition-FC5TQNCH.js.br +0 -0
- package/build/runtime-sceneTransition-FC5TQNCH.js.gz +0 -0
- package/build/{runtime-scroll-HSHQUB6P.js → runtime-scroll-VKMCDMAZ.js} +1 -1
- package/build/runtime-scroll-VKMCDMAZ.js.br +0 -0
- package/build/runtime-scroll-VKMCDMAZ.js.gz +0 -0
- package/build/runtime-shapeBlends-3QLNRN2O.js +1 -0
- package/build/runtime-shapeBlends-3QLNRN2O.js.br +4 -0
- package/build/runtime-shapeBlends-3QLNRN2O.js.gz +0 -0
- package/build/{runtime-text-UGIMBR6B.js → runtime-text-IYCY3PFB.js} +1 -1
- package/build/runtime-text-IYCY3PFB.js.br +0 -0
- package/build/runtime-text-IYCY3PFB.js.gz +0 -0
- package/build/{runtime-textInputs-HE2LSUKB.js → runtime-textInputs-LFDWIRLC.js} +1 -1
- package/build/runtime-textInputs-LFDWIRLC.js.br +0 -0
- package/build/runtime-textInputs-LFDWIRLC.js.gz +0 -0
- package/build/runtime-timeline-WNUPRRKW.js +1 -0
- package/build/runtime-timeline-WNUPRRKW.js.br +0 -0
- package/build/runtime-timeline-WNUPRRKW.js.gz +0 -0
- package/build/{runtime-tracking-WYI7223D.js → runtime-tracking-HMTCBZ7J.js} +1 -1
- package/build/runtime-tracking-HMTCBZ7J.js.br +0 -0
- package/build/runtime-tracking-HMTCBZ7J.js.gz +0 -0
- package/build/{runtime-transitions-ISGRYHHG.js → runtime-transitions-NPD3CNKU.js} +1 -1
- package/build/runtime-transitions-NPD3CNKU.js.br +0 -0
- package/build/runtime-transitions-NPD3CNKU.js.gz +0 -0
- package/build/{runtime-ui2d-K7CMSG7Q.js → runtime-ui2d-NZTQW5UJ.js} +1 -1
- package/build/runtime-ui2d-NZTQW5UJ.js.br +0 -0
- package/build/runtime-ui2d-NZTQW5UJ.js.gz +0 -0
- package/build/{runtime-vectorShapes-TE66F2C6.js → runtime-vectorShapes-26IDV3ZL.js} +1 -1
- package/build/runtime-vectorShapes-26IDV3ZL.js.br +0 -0
- package/build/runtime-vectorShapes-26IDV3ZL.js.gz +0 -0
- package/build/{runtime-webgpu-JHHLEDVG.js → runtime-webgpu-CDBERG7X.js} +1 -1
- package/build/runtime-webgpu-CDBERG7X.js.br +0 -0
- package/build/runtime-webgpu-CDBERG7X.js.gz +0 -0
- package/build/runtime.cjs +5 -5
- package/build/runtime.js +1 -1
- package/build/runtime.js.br +0 -0
- package/build/runtime.js.gz +0 -0
- package/build/runtime.standalone.js +1 -1
- package/build/runtime.standalone.js.br +0 -0
- package/build/runtime.standalone.js.gz +0 -0
- package/build/runtime.standalone.webgl.js +1 -1
- package/build/runtime.standalone.webgl.js.br +0 -0
- package/build/runtime.standalone.webgl.js.gz +0 -0
- package/build/runtime.standalone.webgpu.js +1 -1
- package/build/runtime.standalone.webgpu.js.br +0 -0
- package/build/runtime.standalone.webgpu.js.gz +0 -0
- package/build/runtime.standalone.webgpu.micro.js +1 -1
- package/build/runtime.standalone.webgpu.micro.js.br +0 -0
- package/build/runtime.standalone.webgpu.micro.js.gz +0 -0
- package/build/runtime.standalone.webgpu.min.js +1 -1
- package/build/runtime.standalone.webgpu.min.js.br +0 -0
- package/build/runtime.standalone.webgpu.min.js.gz +0 -0
- package/build/snippets/hana-82e9eb82a79dead4/js-imports.js +204 -77
- package/package.json +1 -1
- package/build/runtime-chunk-2SOMTXZZ.js +0 -1
- package/build/runtime-chunk-2SOMTXZZ.js.br +0 -0
- package/build/runtime-chunk-2SOMTXZZ.js.gz +0 -0
- package/build/runtime-chunk-33KX2TOT.js.br +0 -0
- package/build/runtime-chunk-33KX2TOT.js.gz +0 -0
- package/build/runtime-chunk-3D6ELLRB.js.br +0 -0
- package/build/runtime-chunk-3D6ELLRB.js.gz +0 -0
- package/build/runtime-chunk-44F5FA4N.js.br +0 -0
- package/build/runtime-chunk-44F5FA4N.js.gz +0 -0
- package/build/runtime-chunk-4FRVTTCF.js.br +0 -0
- package/build/runtime-chunk-4FRVTTCF.js.gz +0 -0
- package/build/runtime-chunk-5MDYMRYM.js.br +0 -0
- package/build/runtime-chunk-5MDYMRYM.js.gz +0 -0
- package/build/runtime-chunk-5RKK7JBF.js.br +0 -0
- package/build/runtime-chunk-5RKK7JBF.js.gz +0 -0
- package/build/runtime-chunk-CUH4PXNR.js.br +0 -0
- package/build/runtime-chunk-CUH4PXNR.js.gz +0 -0
- package/build/runtime-chunk-CXBK7LPG.js.br +0 -0
- package/build/runtime-chunk-CXBK7LPG.js.gz +0 -0
- package/build/runtime-chunk-EPFYNTQQ.js.br +0 -0
- package/build/runtime-chunk-EPFYNTQQ.js.gz +0 -0
- package/build/runtime-chunk-FJZAL2GU.js.br +0 -0
- package/build/runtime-chunk-FJZAL2GU.js.gz +0 -0
- package/build/runtime-chunk-HRGNIGSC.js +0 -1
- package/build/runtime-chunk-HRGNIGSC.js.br +0 -0
- package/build/runtime-chunk-HRGNIGSC.js.gz +0 -0
- package/build/runtime-chunk-KJLTN6RE.js.br +0 -0
- package/build/runtime-chunk-KJLTN6RE.js.gz +0 -0
- package/build/runtime-chunk-KRQKRJPD.js.br +0 -0
- package/build/runtime-chunk-KRQKRJPD.js.gz +0 -0
- package/build/runtime-chunk-LVFNCYIC.js.br +0 -0
- package/build/runtime-chunk-LVFNCYIC.js.gz +0 -0
- package/build/runtime-chunk-R3V4RB3X.js.br +0 -0
- package/build/runtime-chunk-R3V4RB3X.js.gz +0 -0
- package/build/runtime-chunk-ROGQC3YL.js.br +0 -0
- package/build/runtime-chunk-ROGQC3YL.js.gz +0 -0
- package/build/runtime-chunk-RYIFGI7L.js.br +0 -0
- package/build/runtime-chunk-RYIFGI7L.js.gz +0 -0
- package/build/runtime-chunk-SOL2NZB4.js.br +0 -0
- package/build/runtime-chunk-SOL2NZB4.js.gz +0 -0
- package/build/runtime-chunk-U7JVP2TI.js.br +0 -0
- package/build/runtime-chunk-U7JVP2TI.js.gz +0 -0
- package/build/runtime-chunk-UFFTT5MI.js.br +0 -0
- package/build/runtime-chunk-UFFTT5MI.js.gz +0 -0
- package/build/runtime-chunk-VJPN4EM6.js.br +0 -0
- package/build/runtime-chunk-VJPN4EM6.js.gz +0 -0
- package/build/runtime-chunk-WFTAZCXD.js.br +0 -0
- package/build/runtime-chunk-WFTAZCXD.js.gz +0 -0
- package/build/runtime-chunk-YANJNJO2.js.br +0 -0
- package/build/runtime-chunk-YANJNJO2.js.gz +0 -0
- package/build/runtime-chunk-YNTJMLA5.js.br +0 -0
- package/build/runtime-chunk-YNTJMLA5.js.gz +0 -0
- package/build/runtime-chunk-ZTHLLGVX.js.gz +0 -0
- package/build/runtime-classicRuntime-7YZ7NLMG.js.br +0 -0
- package/build/runtime-classicRuntime-7YZ7NLMG.js.gz +0 -0
- package/build/runtime-cloners-H554LSFU.js.br +0 -0
- package/build/runtime-cloners-H554LSFU.js.gz +0 -0
- package/build/runtime-components-ZCELGDQ5.js.br +0 -0
- package/build/runtime-components-ZCELGDQ5.js.gz +0 -0
- package/build/runtime-createDestroy-FK2ZKK66.js.br +0 -0
- package/build/runtime-createDestroy-FK2ZKK66.js.gz +0 -0
- package/build/runtime-dragDrop-E4OSDFGY.js.br +0 -0
- package/build/runtime-dragDrop-E4OSDFGY.js.gz +0 -0
- package/build/runtime-gameControls-A3BST7FA.js.br +0 -0
- package/build/runtime-gameControls-A3BST7FA.js.gz +0 -0
- package/build/runtime-hair-W5WKY4OE.js.br +0 -2
- package/build/runtime-hair-W5WKY4OE.js.gz +0 -0
- package/build/runtime-mergeStaticGeometries-5FS3LGQQ.js.br +0 -0
- package/build/runtime-mergeStaticGeometries-5FS3LGQQ.js.gz +0 -0
- package/build/runtime-miscActions-F72HQZ5I.js.br +0 -0
- package/build/runtime-miscActions-F72HQZ5I.js.gz +0 -0
- package/build/runtime-mouseHover-44D2CVLI.js.br +0 -0
- package/build/runtime-mouseHover-44D2CVLI.js.gz +0 -0
- package/build/runtime-particles-5BBDNO44.js.br +0 -0
- package/build/runtime-particles-5BBDNO44.js.gz +0 -0
- package/build/runtime-paths-YF5SB3I3.js.br +0 -0
- package/build/runtime-paths-YF5SB3I3.js.gz +0 -0
- package/build/runtime-resize-ZORLCUGS.js.br +0 -0
- package/build/runtime-resize-ZORLCUGS.js.gz +0 -0
- package/build/runtime-sceneTransition-EEJJDLOW.js.br +0 -0
- package/build/runtime-sceneTransition-EEJJDLOW.js.gz +0 -0
- package/build/runtime-scroll-HSHQUB6P.js.br +0 -0
- package/build/runtime-scroll-HSHQUB6P.js.gz +0 -0
- package/build/runtime-shapeBlends-5ND6NZVA.js +0 -1
- package/build/runtime-shapeBlends-5ND6NZVA.js.br +0 -3
- package/build/runtime-shapeBlends-5ND6NZVA.js.gz +0 -0
- package/build/runtime-text-UGIMBR6B.js.br +0 -0
- package/build/runtime-text-UGIMBR6B.js.gz +0 -0
- package/build/runtime-textInputs-HE2LSUKB.js.br +0 -0
- package/build/runtime-textInputs-HE2LSUKB.js.gz +0 -0
- package/build/runtime-timeline-ZY2DQMB7.js +0 -1
- package/build/runtime-timeline-ZY2DQMB7.js.br +0 -0
- package/build/runtime-timeline-ZY2DQMB7.js.gz +0 -0
- package/build/runtime-tracking-WYI7223D.js.br +0 -0
- package/build/runtime-tracking-WYI7223D.js.gz +0 -0
- package/build/runtime-transitions-ISGRYHHG.js.br +0 -0
- package/build/runtime-transitions-ISGRYHHG.js.gz +0 -0
- package/build/runtime-ui2d-K7CMSG7Q.js.br +0 -0
- package/build/runtime-ui2d-K7CMSG7Q.js.gz +0 -0
- package/build/runtime-vectorShapes-TE66F2C6.js.br +0 -0
- package/build/runtime-vectorShapes-TE66F2C6.js.gz +0 -0
- package/build/runtime-webgpu-JHHLEDVG.js.br +0 -0
- package/build/runtime-webgpu-JHHLEDVG.js.gz +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as t,b as e,d as r}from"./runtime-chunk-FJZAL2GU.js";import{g as i}from"./runtime-chunk-4KZXQGUQ.js";import{L as a,za as o}from"./runtime-chunk-VPEJ5BFD.js";import{Ae as s,Ec as n,Fc as p,Oc as h,Rc as c,Tc as m,bd as f,dd as u,ud as d,wd as l,we as g,xe as v}from"./runtime-chunk-VGN7YHB7.js";var C=new p,j=new g,T=class extends l{constructor(t){let e=new u,r=new d({color:16777215,vertexColors:!0,toneMapped:!1}),i=[],a=[],o={},s=new m(15711266),n=new m(15711266),p=new m(2857471);function h(t,e,r){c(t,r),c(e,r)}function c(t,e){i.push(0,0,0),a.push(e.r,e.g,e.b),void 0===o[t]&&(o[t]=[]),o[t].push(i.length/3-1)}h("n1","n2",s),h("n2","n4",s),h("n4","n3",s),h("n3","n1",s),h("f1","f2",s),h("f2","f4",s),h("f4","f3",s),h("f3","f1",s),h("n1","f1",s),h("n2","f2",s),h("n3","f3",s),h("n4","f4",s),h("p","n1",n),h("p","n2",n),h("p","n3",n),h("p","n4",n),h("u1","u2",p),h("u2","u3",p),h("u3","u1",p),e.setAttribute("position",new f(i,3)),e.setAttribute("color",new f(a,3)),super(e,r),this.type="CameraHelper",this.camera=t,this.camera.updateProjectionMatrix&&this.camera.updateProjectionMatrix(),this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1,this.pointMap=o,this.update()}update(){let t=this.geometry,e=this.pointMap;j.projectionMatrixInverse.elements=[.5112609807824982,-0,-0,-0,-0,.41421356237309503,-0,-0,-0,-0,-0,-.099999,-0,-0,-1.0000000000000002,.100001];let r=.8;y("n1",e,t,j,-1,-1,r),y("n2",e,t,j,1,-1,r),y("n3",e,t,j,-1,1,r),y("n4",e,t,j,1,1,r);let i=r;y("f1",e,t,j,-1,-1,i),y("f2",e,t,j,1,-1,i),y("f3",e,t,j,-1,1,i),y("f4",e,t,j,1,1,i);let a=i;y("u1",e,t,j,.35,1.1,a),y("u2",e,t,j,-.35,1.1,a),y("u3",e,t,j,0,1.55,a),t.getAttribute("position").needsUpdate=!0}dispose(){this.geometry.dispose(),this.material.dispose()}};function y(t,e,r,i,a,o,s){C.set(a,o,s).unproject(i);let n=e[t];if(void 0!==n){let t=r.getAttribute("position");for(let e=0,r=n.length;e<r;e++)t.setXYZ(n[e],C.x,C.y,C.z)}}var w=class extends(t(T)){constructor(t){super(t),this.object=t,this.name=`CombinedCameraHelper: ${t.uuid}`}updateMatrixWorld(t){super.updateMatrixWorld(t),this.updateTarget()}updateTarget(){let t=this.object.getTarget();this.updateWorldMatrix(!0,!1),this.worldToLocal(t)}raycast(t,r){e(this.object,this.geometry,t,r,!0)}};function P(t){return 1-Math.pow(1-t,3)}var b=new p,x=new p,_=new n,M=new p,O=new p,F=new p,A=class extends(r(g,w)){constructor(t="",e={...o.defaultData,name:""}){super(),this._cameraType="OrthographicCamera",this.targetOffset=a.DefaultTargetOffset,this.isUpVectorFlipped=!1,this.angleOffsetFromUp=0,this.wasMovedByUser=!1,this.wasMovedBySwitchCameraAction=!1,this._createdAt=typeof performance<"u"?performance.now():0,this._tickProjectionTransition=()=>{let t=this._projectionTransition;if(void 0===t)return;if(this.disposed)return void this._endProjectionTransition();t.raf=requestAnimationFrame(this._tickProjectionTransition);let e=A.projectionTransitionRequestRender??t.requestRender;this.updateProjectionMatrix(),e?.()},this.super_Entity(t,e),this.previousProjectionMatrix=new h,this.matrixAutoUpdate=!0,this.width=window.innerWidth,this.height=window.innerHeight;let r=this.width,i=this.height;this.orthoCamera=new s(-.5*r,.5*r,.5*i,-.5*i,-5e4,1e4),this.perspCamera=new v(45,r/i,50,1e4),this.left=this.orthoCamera.left,this.right=this.orthoCamera.right,this.top=this.orthoCamera.top,this.bottom=this.orthoCamera.bottom,this.far=this.orthoCamera.far,this.view=this.orthoCamera.view,this.aspect=this.perspCamera.aspect,this.focus=this.perspCamera.focus,this.filmGauge=this.perspCamera.filmGauge,this.filmOffset=this.perspCamera.filmOffset,this.objectHelper.update()}static withoutProjectionTransition(t){let e=A.projectionTransitionsEnabled;A.projectionTransitionsEnabled=!1;try{return t()}finally{A.projectionTransitionsEnabled=e}}get isPerspectiveCamera(){return"PerspectiveCamera"===this.cameraType}get isOrthographicCamera(){return!this.isPerspectiveCamera}get cameraType(){return this._cameraType}set fov(t){this.perspCamera.fov=t}get fov(){return this.perspCamera.fov}setNear(t,e){"PerspectiveCamera"===t?this.perspCamera.near=e:this.orthoCamera.near=e}setZoom(t,e){e>=0&&("PerspectiveCamera"===t?this.perspCamera.zoom=e:this.orthoCamera.zoom=e)}set cameraType(t){"PerspectiveCamera"===t?this.toPerspective():"OrthographicCamera"===t&&this.toOrthographic()}get near(){return"PerspectiveCamera"===this._cameraType?this.perspCamera.near:this.orthoCamera.near}set near(t){"PerspectiveCamera"===this._cameraType?this.perspCamera.near=t:this.orthoCamera.near=t}get zoom(){return"PerspectiveCamera"===this._cameraType?this.perspCamera.zoom:this.orthoCamera.zoom}set zoom(t){t>=0&&("PerspectiveCamera"===this._cameraType?this.perspCamera.zoom=t:this.orthoCamera.zoom=t)}lookAt(t,e,r){"number"==typeof t&&(t=new p(t,e,r)),super.lookAt(t),this.getWorldPosition(b),this.targetOffset=b.distanceTo(t)}getTarget(t=new p){return this.getWorldDirection(x),this.getWorldPosition(b),x.multiplyScalar(this.targetOffset),t.copy(b).add(x),t}getDistanceToTarget(){let t=this.getTarget();return this.getWorldPosition(b),b.distanceTo(t)}updateUp(){this.getWorldQuaternion(_),M.set(0,0,1).applyQuaternion(_),O.copy(c.DEFAULT_UP),this.isUpVectorFlipped&&O.negate(),O.applyQuaternion(_),F.copy(c.DEFAULT_UP).projectOnPlane(M),this.angleOffsetFromUp=F.angleTo(O),this.angleOffsetFromUp*=F.cross(O).dot(M)>=0?1:-1}updateTransformState(t,e){let r=super.updateTransformState(t,e);return void 0!==t.isUpVectorFlipped&&(this.isUpVectorFlipped=t.isUpVectorFlipped),this.updateUp(),r}getViewFrontToObject(t){let e=t.getWorldPosition(new p),r=t.getWorldDirection(new p).multiplyScalar(this.targetOffset);return{position:e.clone().add(r),target:e}}getViewToTarget(t){let e=this.getWorldDirection(new p).multiplyScalar(this.targetOffset);return{position:t.clone().sub(e),target:t}}getViewToObject(t){let e=new p;return t.getWorldPosition(e),this.getViewToTarget(e)}setViewplaneSize(t,e,r=!1){if(this.aspect=t/e,r){let r=t>e?this.aspect:1,i=t>e?1:this.aspect;this.left=-395*r,this.right=395*r,this.top=1/i*395,this.bottom=1/i*-395}else this.left=.5*-t,this.right=.5*t,this.top=.5*e,this.bottom=.5*-e;this.updateProjectionMatrix()}copyViewPlaneSize(t){this.aspect=t.aspect,this.left=t.left,this.right=t.right,this.top=t.top,this.bottom=t.bottom,this.updateProjectionMatrix()}toOrthographic(){this.orthoCamera.left=this.left,this.orthoCamera.right=this.right,this.orthoCamera.top=this.top,this.orthoCamera.bottom=this.bottom,this.orthoCamera.view=this.view,this.orthoCamera.far=this.far,this.orthoCamera.updateProjectionMatrix(),this.projectionMatrix=this.orthoCamera.projectionMatrix,this.projectionMatrixInverse=this.orthoCamera.projectionMatrixInverse,this._cameraType="OrthographicCamera",this._applyProjectionTransition(),this.objectHelper&&this.objectHelper.update()}toPerspective(){this.perspCamera.aspect=this.aspect,this.perspCamera.fov=this.fov,this.perspCamera.view=this.view,this.perspCamera.far=this.far,this.perspCamera.updateProjectionMatrix(),this.projectionMatrix=this.perspCamera.projectionMatrix,this.projectionMatrixInverse=this.perspCamera.projectionMatrixInverse,this._cameraType="PerspectiveCamera",this._applyProjectionTransition(),this.objectHelper&&this.objectHelper.update()}get isProjectionTransitioning(){return void 0!==this._projectionTransition}get projectionTransitionProgress(){let t=this._projectionTransition;if(void 0===t)return 1;let e=(performance.now()-t.start)/t.duration;return e>=1?1:e<=0?0:P(e)}get _activeSubCamera(){return"PerspectiveCamera"===this._cameraType?this.perspCamera:this.orthoCamera}_canAnimateProjection(){return A.projectionTransitionsEnabled&&"function"==typeof requestAnimationFrame&&typeof performance<"u"&&performance.now()-this._createdAt>=A.projectionTransitionMinAgeMs}_beginProjectionTransition(t){let e=this._projectionTransition;void 0===e&&(e={from:new h,blend:new h,blendInverse:new h,start:0,duration:A.projectionTransitionDuration,referenceDepth:1,raf:0,requestRender:t},this._projectionTransition=e),e.from.copy(this.projectionMatrix),e.start=performance.now(),e.duration=A.projectionTransitionDuration,e.referenceDepth=Number.isFinite(this.targetOffset)?Math.max(1,this.targetOffset):1,t&&(e.requestRender=t),0!==e.raf&&cancelAnimationFrame(e.raf),e.raf=requestAnimationFrame(this._tickProjectionTransition)}_applyProjectionTransition(){let t=this._projectionTransition;if(void 0===t)return;let e=(performance.now()-t.start)/t.duration;if(e>=1)return void this._endProjectionTransition();let r=P(e),i=t.from.elements,a=this._activeSubCamera.projectionMatrix.elements,o=t.blend.elements,s=t.referenceDepth,n=Math.max(1e-6,i[15]-i[11]*s),p=r*n/(r*n+(1-r)*Math.max(1e-6,a[15]-a[11]*s));for(let t=0;t<16;t++)o[t]=i[t]+(a[t]-i[t])*p;t.blendInverse.copy(t.blend).invert(),this.projectionMatrix=t.blend,this.projectionMatrixInverse=t.blendInverse}_endProjectionTransition(){let t=this._projectionTransition;if(void 0===t)return;0!==t.raf&&cancelAnimationFrame(t.raf),this._projectionTransition=void 0;let e=this._activeSubCamera;this.projectionMatrix=e.projectionMatrix,this.projectionMatrixInverse=e.projectionMatrixInverse}_syncProjectionTransition(t){let e=t._projectionTransition;if(void 0===e)return void(void 0!==this._projectionTransition&&this._endProjectionTransition());let r=this._projectionTransition;void 0===r?(r={from:new h,blend:new h,blendInverse:new h,start:0,duration:1,referenceDepth:1,raf:0,requestRender:void 0},this._projectionTransition=r):0!==r.raf&&(cancelAnimationFrame(r.raf),r.raf=0),r.requestRender=void 0,r.from.copy(e.from),r.start=e.start,r.duration=e.duration,r.referenceDepth=e.referenceDepth,this._applyProjectionTransition()}setFocalLength(t){this.perspCamera.setFocalLength(t),this.toPerspective()}getFocalLength(){return this.perspCamera.getFocalLength()}getEffectiveFOV(){return this.perspCamera.getEffectiveFOV()}getFilmWidth(){return this.perspCamera.getFilmWidth()}getFilmHeight(){return this.perspCamera.getFilmHeight()}setViewOffset(t,e,r,i,a,o){"PerspectiveCamera"===this._cameraType?this.perspCamera.setViewOffset(t,e,r,i,a,o):this.orthoCamera.setViewOffset(t,e,r,i,a,o),this._applyProjectionTransition()}clearViewOffset(){"PerspectiveCamera"===this._cameraType?(this.perspCamera.clearViewOffset(),this.toPerspective()):(this.orthoCamera.clearViewOffset(),this.toOrthographic())}copyHistory(){this.previousProjectionMatrix&&this.previousProjectionMatrix.copy(this.projectionMatrix)}updateProjectionMatrix(){"PerspectiveCamera"===this._cameraType?this.toPerspective():"OrthographicCamera"===this._cameraType&&this.toOrthographic()}updateMatrixWorld(t){super.updateMatrixWorld(t),this.matrixWorldInverse.copy(this.matrixWorld).invert()}updateWorldMatrix(t,e){super.updateWorldMatrix(t,e),this.matrixWorldInverse.copy(this.matrixWorld).invert()}copy(t,e){return super.copy(t,e),this.parent=t.parent,this.orthoCamera.copy(t.orthoCamera),this.perspCamera.copy(t.perspCamera),this.left=t.left,this.right=t.right,this.top=t.top,this.bottom=t.bottom,this.far=t.far,this.view=null===t.view?null:Object.assign({},t.view),this._cameraType=t._cameraType,this.aspect=t.aspect,this.fov=t.fov,this.focus=t.focus,this.filmGauge=t.filmGauge,this.filmOffset=t.filmOffset,this.targetOffset=a.sanitizeTargetOffset(t.targetOffset),this.updateProjectionMatrix(),this._syncProjectionTransition(t),this}toCameraState(t=[]){let e={type:this.cameraType,far:this.far,orthographic:{near:this.orthoCamera.near,zoom:this.orthoCamera.zoom},perspective:{near:this.perspCamera.near,fov:this.perspCamera.fov,zoom:this.perspCamera.zoom},up:this.up.toArray(),targetOffset:this.targetOffset,isUpVectorFlipped:this.isUpVectorFlipped};return i(e,t)}updateCameraSubtype(t,e){let r="perspective"===t?"PerspectiveCamera":"OrthographicCamera";void 0!==e.zoom&&this.setZoom(r,e.zoom),void 0!==e.near&&this.setNear(r,e.near),void 0!==e.fov&&"PerspectiveCamera"===r&&(this.fov=e.fov)}updateState(t,e){this.updateCameraState(t,e)}updateCameraState(t,e){this.updateState_Entity(t,e),void 0!==t.far&&(this.far=t.far),void 0!==t.orthographic&&this.updateCameraSubtype("orthographic",t.orthographic),void 0!==t.perspective&&this.updateCameraSubtype("perspective",t.perspective),void 0!==t.type&&(t.type!==this._cameraType&&this._canAnimateProjection()&&this._beginProjectionTransition(e?.shared.requestRender),this.cameraType=t.type),void 0!==t.up&&this.up.fromArray(t.up.map(t=>"number"==typeof t?t:0)),void 0!==t.targetOffset&&(this.targetOffset=a.sanitizeTargetOffset(t.targetOffset)),void 0!==t.isUpVectorFlipped&&(this.isUpVectorFlipped=t.isUpVectorFlipped),this.updateProjectionMatrix()}updateByPatchedOp(t,e,r){super.updateByPatchedOp(t,e,r),1===t.path.length&&0===t.type&&this.updateCameraSubtype(t.path[0],t.props)}toState(t){return{...super.toState(t),...this.toCameraState(t),type:this.cameraType}}},V=A;V.projectionTransitionsEnabled=!1,V.projectionTransitionDuration=350,V.projectionTransitionMinAgeMs=1e3;export{V as a};
|
|
1
|
+
import{a as t,b as e,d as r}from"./runtime-chunk-VNO2DW74.js";import{g as i}from"./runtime-chunk-4KZXQGUQ.js";import{L as a,za as o}from"./runtime-chunk-VPEJ5BFD.js";import{Ae as s,Ec as n,Fc as p,Oc as h,Rc as c,Tc as m,bd as f,dd as u,ud as d,wd as l,we as g,xe as v}from"./runtime-chunk-VGN7YHB7.js";var C=new p,j=new g,T=class extends l{constructor(t){let e=new u,r=new d({color:16777215,vertexColors:!0,toneMapped:!1}),i=[],a=[],o={},s=new m(15711266),n=new m(15711266),p=new m(2857471);function h(t,e,r){c(t,r),c(e,r)}function c(t,e){i.push(0,0,0),a.push(e.r,e.g,e.b),void 0===o[t]&&(o[t]=[]),o[t].push(i.length/3-1)}h("n1","n2",s),h("n2","n4",s),h("n4","n3",s),h("n3","n1",s),h("f1","f2",s),h("f2","f4",s),h("f4","f3",s),h("f3","f1",s),h("n1","f1",s),h("n2","f2",s),h("n3","f3",s),h("n4","f4",s),h("p","n1",n),h("p","n2",n),h("p","n3",n),h("p","n4",n),h("u1","u2",p),h("u2","u3",p),h("u3","u1",p),e.setAttribute("position",new f(i,3)),e.setAttribute("color",new f(a,3)),super(e,r),this.type="CameraHelper",this.camera=t,this.camera.updateProjectionMatrix&&this.camera.updateProjectionMatrix(),this.matrix=t.matrixWorld,this.matrixAutoUpdate=!1,this.pointMap=o,this.update()}update(){let t=this.geometry,e=this.pointMap;j.projectionMatrixInverse.elements=[.5112609807824982,-0,-0,-0,-0,.41421356237309503,-0,-0,-0,-0,-0,-.099999,-0,-0,-1.0000000000000002,.100001];let r=.8;y("n1",e,t,j,-1,-1,r),y("n2",e,t,j,1,-1,r),y("n3",e,t,j,-1,1,r),y("n4",e,t,j,1,1,r);let i=r;y("f1",e,t,j,-1,-1,i),y("f2",e,t,j,1,-1,i),y("f3",e,t,j,-1,1,i),y("f4",e,t,j,1,1,i);let a=i;y("u1",e,t,j,.35,1.1,a),y("u2",e,t,j,-.35,1.1,a),y("u3",e,t,j,0,1.55,a),t.getAttribute("position").needsUpdate=!0}dispose(){this.geometry.dispose(),this.material.dispose()}};function y(t,e,r,i,a,o,s){C.set(a,o,s).unproject(i);let n=e[t];if(void 0!==n){let t=r.getAttribute("position");for(let e=0,r=n.length;e<r;e++)t.setXYZ(n[e],C.x,C.y,C.z)}}var w=class extends(t(T)){constructor(t){super(t),this.object=t,this.name=`CombinedCameraHelper: ${t.uuid}`}updateMatrixWorld(t){super.updateMatrixWorld(t),this.updateTarget()}updateTarget(){let t=this.object.getTarget();this.updateWorldMatrix(!0,!1),this.worldToLocal(t)}raycast(t,r){e(this.object,this.geometry,t,r,!0)}};function P(t){return 1-Math.pow(1-t,3)}var b=new p,x=new p,_=new n,M=new p,O=new p,F=new p,V=class extends(r(g,w)){constructor(t="",e={...o.defaultData,name:""}){super(),this._cameraType="OrthographicCamera",this.targetOffset=a.DefaultTargetOffset,this.isUpVectorFlipped=!1,this.angleOffsetFromUp=0,this.wasMovedByUser=!1,this.wasMovedBySwitchCameraAction=!1,this._createdAt=typeof performance<"u"?performance.now():0,this._tickProjectionTransition=()=>{let t=this._projectionTransition;if(void 0===t)return;if(this.disposed)return void this._endProjectionTransition();t.raf=requestAnimationFrame(this._tickProjectionTransition);let e=V.projectionTransitionRequestRender??t.requestRender;this.updateProjectionMatrix(),e?.()},this.super_Entity(t,e),this.previousProjectionMatrix=new h,this.matrixAutoUpdate=!0,this.width=window.innerWidth,this.height=window.innerHeight;let r=this.width,i=this.height;this.orthoCamera=new s(-.5*r,.5*r,.5*i,-.5*i,-5e4,1e4),this.perspCamera=new v(45,r/i,50,1e4),this.left=this.orthoCamera.left,this.right=this.orthoCamera.right,this.top=this.orthoCamera.top,this.bottom=this.orthoCamera.bottom,this.far=this.orthoCamera.far,this.view=this.orthoCamera.view,this.aspect=this.perspCamera.aspect,this.focus=this.perspCamera.focus,this.filmGauge=this.perspCamera.filmGauge,this.filmOffset=this.perspCamera.filmOffset,this.objectHelper.update()}static withoutProjectionTransition(t){let e=V.projectionTransitionsEnabled;V.projectionTransitionsEnabled=!1;try{return t()}finally{V.projectionTransitionsEnabled=e}}get isPerspectiveCamera(){return"PerspectiveCamera"===this.cameraType}get isOrthographicCamera(){return!this.isPerspectiveCamera}get cameraType(){return this._cameraType}set fov(t){this.perspCamera.fov=t}get fov(){return this.perspCamera.fov}setNear(t,e){"PerspectiveCamera"===t?this.perspCamera.near=e:this.orthoCamera.near=e}setZoom(t,e){e>=0&&("PerspectiveCamera"===t?this.perspCamera.zoom=e:this.orthoCamera.zoom=e)}set cameraType(t){"PerspectiveCamera"===t?this.toPerspective():"OrthographicCamera"===t&&this.toOrthographic()}get near(){return"PerspectiveCamera"===this._cameraType?this.perspCamera.near:this.orthoCamera.near}set near(t){"PerspectiveCamera"===this._cameraType?this.perspCamera.near=t:this.orthoCamera.near=t}get zoom(){return"PerspectiveCamera"===this._cameraType?this.perspCamera.zoom:this.orthoCamera.zoom}set zoom(t){t>=0&&("PerspectiveCamera"===this._cameraType?this.perspCamera.zoom=t:this.orthoCamera.zoom=t)}lookAt(t,e,r){"number"==typeof t&&(t=new p(t,e,r)),super.lookAt(t),this.getWorldPosition(b),this.targetOffset=b.distanceTo(t)}getTarget(t=new p){return this.getWorldDirection(x),this.getWorldPosition(b),x.multiplyScalar(this.targetOffset),t.copy(b).add(x),t}getDistanceToTarget(){let t=this.getTarget();return this.getWorldPosition(b),b.distanceTo(t)}updateUp(){this.getWorldQuaternion(_),M.set(0,0,1).applyQuaternion(_),O.copy(c.DEFAULT_UP),this.isUpVectorFlipped&&O.negate(),O.applyQuaternion(_),F.copy(c.DEFAULT_UP).projectOnPlane(M),this.angleOffsetFromUp=F.angleTo(O),this.angleOffsetFromUp*=F.cross(O).dot(M)>=0?1:-1}updateTransformState(t,e){let r=super.updateTransformState(t,e);return void 0!==t.isUpVectorFlipped&&(this.isUpVectorFlipped=t.isUpVectorFlipped),this.updateUp(),r}getViewFrontToObject(t){let e=t.getWorldPosition(new p),r=t.getWorldDirection(new p).multiplyScalar(this.targetOffset);return{position:e.clone().add(r),target:e}}getViewToTarget(t){let e=this.getWorldDirection(new p).multiplyScalar(this.targetOffset);return{position:t.clone().sub(e),target:t}}getViewToObject(t){let e=new p;return t.getWorldPosition(e),this.getViewToTarget(e)}setViewplaneSize(t,e,r=!1){if(this.aspect=t/e,r){let r=t>e?this.aspect:1,i=t>e?1:this.aspect;this.left=-395*r,this.right=395*r,this.top=1/i*395,this.bottom=1/i*-395}else this.left=.5*-t,this.right=.5*t,this.top=.5*e,this.bottom=.5*-e;this.updateProjectionMatrix()}copyViewPlaneSize(t){this.aspect=t.aspect,this.left=t.left,this.right=t.right,this.top=t.top,this.bottom=t.bottom,this.updateProjectionMatrix()}toOrthographic(){this.orthoCamera.left=this.left,this.orthoCamera.right=this.right,this.orthoCamera.top=this.top,this.orthoCamera.bottom=this.bottom,this.orthoCamera.view=this.view,this.orthoCamera.far=this.far,this.orthoCamera.updateProjectionMatrix(),this.projectionMatrix=this.orthoCamera.projectionMatrix,this.projectionMatrixInverse=this.orthoCamera.projectionMatrixInverse,this._cameraType="OrthographicCamera",this._applyProjectionTransition(),this.objectHelper&&this.objectHelper.update()}toPerspective(){this.perspCamera.aspect=this.aspect,this.perspCamera.fov=this.fov,this.perspCamera.view=this.view,this.perspCamera.far=this.far,this.perspCamera.updateProjectionMatrix(),this.projectionMatrix=this.perspCamera.projectionMatrix,this.projectionMatrixInverse=this.perspCamera.projectionMatrixInverse,this._cameraType="PerspectiveCamera",this._applyProjectionTransition(),this.objectHelper&&this.objectHelper.update()}get isProjectionTransitioning(){return void 0!==this._projectionTransition}get projectionTransitionProgress(){let t=this._projectionTransition;if(void 0===t)return 1;let e=(performance.now()-t.start)/t.duration;return e>=1?1:e<=0?0:P(e)}get _activeSubCamera(){return"PerspectiveCamera"===this._cameraType?this.perspCamera:this.orthoCamera}_canAnimateProjection(){return V.projectionTransitionsEnabled&&"function"==typeof requestAnimationFrame&&typeof performance<"u"&&performance.now()-this._createdAt>=V.projectionTransitionMinAgeMs}_beginProjectionTransition(t){let e=this._projectionTransition;void 0===e&&(e={from:new h,blend:new h,blendInverse:new h,start:0,duration:V.projectionTransitionDuration,referenceDepth:1,raf:0,requestRender:t},this._projectionTransition=e),e.from.copy(this.projectionMatrix),e.start=performance.now(),e.duration=V.projectionTransitionDuration,e.referenceDepth=Number.isFinite(this.targetOffset)?Math.max(1,this.targetOffset):1,t&&(e.requestRender=t),0!==e.raf&&cancelAnimationFrame(e.raf),e.raf=requestAnimationFrame(this._tickProjectionTransition)}_applyProjectionTransition(){let t=this._projectionTransition;if(void 0===t)return;let e=(performance.now()-t.start)/t.duration;if(e>=1)return void this._endProjectionTransition();let r=P(e),i=t.from.elements,a=this._activeSubCamera.projectionMatrix.elements,o=t.blend.elements,s=t.referenceDepth,n=Math.max(1e-6,i[15]-i[11]*s),p=r*n/(r*n+(1-r)*Math.max(1e-6,a[15]-a[11]*s));for(let t=0;t<16;t++)o[t]=i[t]+(a[t]-i[t])*p;t.blendInverse.copy(t.blend).invert(),this.projectionMatrix=t.blend,this.projectionMatrixInverse=t.blendInverse}_endProjectionTransition(){let t=this._projectionTransition;if(void 0===t)return;0!==t.raf&&cancelAnimationFrame(t.raf),this._projectionTransition=void 0;let e=this._activeSubCamera;this.projectionMatrix=e.projectionMatrix,this.projectionMatrixInverse=e.projectionMatrixInverse}_syncProjectionTransition(t){let e=t._projectionTransition;if(void 0===e)return void(void 0!==this._projectionTransition&&this._endProjectionTransition());let r=this._projectionTransition;void 0===r?(r={from:new h,blend:new h,blendInverse:new h,start:0,duration:1,referenceDepth:1,raf:0,requestRender:void 0},this._projectionTransition=r):0!==r.raf&&(cancelAnimationFrame(r.raf),r.raf=0),r.requestRender=void 0,r.from.copy(e.from),r.start=e.start,r.duration=e.duration,r.referenceDepth=e.referenceDepth,this._applyProjectionTransition()}setFocalLength(t){this.perspCamera.setFocalLength(t),this.toPerspective()}getFocalLength(){return this.perspCamera.getFocalLength()}getEffectiveFOV(){return this.perspCamera.getEffectiveFOV()}getFilmWidth(){return this.perspCamera.getFilmWidth()}getFilmHeight(){return this.perspCamera.getFilmHeight()}setViewOffset(t,e,r,i,a,o){"PerspectiveCamera"===this._cameraType?this.perspCamera.setViewOffset(t,e,r,i,a,o):this.orthoCamera.setViewOffset(t,e,r,i,a,o),this._applyProjectionTransition()}clearViewOffset(){"PerspectiveCamera"===this._cameraType?(this.perspCamera.clearViewOffset(),this.toPerspective()):(this.orthoCamera.clearViewOffset(),this.toOrthographic())}copyHistory(){this.previousProjectionMatrix&&this.previousProjectionMatrix.copy(this.projectionMatrix)}updateProjectionMatrix(){"PerspectiveCamera"===this._cameraType?this.toPerspective():"OrthographicCamera"===this._cameraType&&this.toOrthographic()}updateMatrixWorld(t){super.updateMatrixWorld(t),this.matrixWorldInverse.copy(this.matrixWorld).invert()}updateWorldMatrix(t,e){super.updateWorldMatrix(t,e),this.matrixWorldInverse.copy(this.matrixWorld).invert()}copy(t,e){return super.copy(t,e),this.parent=t.parent,this.orthoCamera.copy(t.orthoCamera),this.perspCamera.copy(t.perspCamera),this.left=t.left,this.right=t.right,this.top=t.top,this.bottom=t.bottom,this.far=t.far,this.view=null===t.view?null:Object.assign({},t.view),this._cameraType=t._cameraType,this.aspect=t.aspect,this.fov=t.fov,this.focus=t.focus,this.filmGauge=t.filmGauge,this.filmOffset=t.filmOffset,this.targetOffset=a.sanitizeTargetOffset(t.targetOffset),this.updateProjectionMatrix(),this._syncProjectionTransition(t),this}toCameraState(t=[]){let e={type:this.cameraType,far:this.far,orthographic:{near:this.orthoCamera.near,zoom:this.orthoCamera.zoom},perspective:{near:this.perspCamera.near,fov:this.perspCamera.fov,zoom:this.perspCamera.zoom},up:this.up.toArray(),targetOffset:this.targetOffset,isUpVectorFlipped:this.isUpVectorFlipped};return i(e,t)}updateCameraSubtype(t,e){let r="perspective"===t?"PerspectiveCamera":"OrthographicCamera";void 0!==e.zoom&&this.setZoom(r,e.zoom),void 0!==e.near&&this.setNear(r,e.near),void 0!==e.fov&&"PerspectiveCamera"===r&&(this.fov=e.fov)}updateState(t,e){this.updateCameraState(t,e)}updateCameraState(t,e){this.updateState_Entity(t,e),void 0!==t.far&&(this.far=t.far),void 0!==t.orthographic&&this.updateCameraSubtype("orthographic",t.orthographic),void 0!==t.perspective&&this.updateCameraSubtype("perspective",t.perspective),void 0!==t.type&&(t.type!==this._cameraType&&this._canAnimateProjection()&&this._beginProjectionTransition(e?.shared.requestRender),this.cameraType=t.type),void 0!==t.up&&this.up.fromArray(t.up.map(t=>"number"==typeof t?t:0)),void 0!==t.targetOffset&&(this.targetOffset=a.sanitizeTargetOffset(t.targetOffset)),void 0!==t.isUpVectorFlipped&&(this.isUpVectorFlipped=t.isUpVectorFlipped),this.updateProjectionMatrix()}updateByPatchedOp(t,e,r){super.updateByPatchedOp(t,e,r),1===t.path.length&&0===t.type&&this.updateCameraSubtype(t.path[0],t.props)}toState(t){return{...super.toState(t),...this.toCameraState(t),type:this.cameraType}}},A=V;A.projectionTransitionsEnabled=!1,A.projectionTransitionDuration=350,A.projectionTransitionMinAgeMs=1e3;export{A as a};
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e,b as t}from"./runtime-chunk-
|
|
1
|
+
import{a as e,b as t}from"./runtime-chunk-M4BPCY7K.js";import{c as s,d as o}from"./runtime-chunk-VNO2DW74.js";import{da as r}from"./runtime-chunk-7FDJ7IIR.js";import{h as i,o as a,p as n,q as d,r as h,s as l,t as m,v as p}from"./runtime-chunk-MOZWC42D.js";import{i as u}from"./runtime-chunk-2PT2WH66.js";import{Oc as c,bd as y,dd as g,ue as f}from"./runtime-chunk-VGN7YHB7.js";var b=new c,M=new c,A=new c,v=new c,S=new c;function w(e){let t=!1;return e.scene.objects.traverse((e,s)=>{"BooleanGeometry"===s.geometry?.type&&(t=!0)}),t}function D(e,t){let s=e.cloner;return void 0!==s&&s.parent===t?s:void 0}var x=new Float32Array(0);function O(e,t,s,o){let r=16*(t.children.length+1);x.length<r&&(x=new Float32Array(r));let i=0,a=e=>{e.toArray(x,16*i),i++},n=!0!==t.parameters.hideBase;n&&a(o),A.multiplyMatrices(e.hiddenMatrix,e.matrix);for(let e of t.children)!u(e)||!1===e.playModeVisible||(v.multiplyMatrices(e.hiddenMatrix,e.matrix).multiply(e.pivotMatrix),S.multiplyMatrices(A,v),(!n||!S.equals(o))&&a(S));try{return 0===i?0:m(s,x.subarray(0,16*i))}finally{l(s)}}var B,F=class extends r{constructor(e,t,s){super(e,t),this.data=t,this.meshSetAddresses=[],this.needsTransformForDownstream=!1,this.geometry=new g,this.onAfterRender=(e,t,s,o,r,i)=>{super.onAfterRender(e,t,s,o,r,i),this.recomputeBoolean()},this.geometry.userData.parameters={width:0,height:0,depth:0}}get booleanOp(){return this.data.geometry.operation}get phongAngle(){return this.data.geometry.phongAngle??45}get isLOD(){return this.recomputeBoolean(),!1}updateByPatchedOp(e,t,s){super.updateByPatchedOp(e,t,s),1===e.path.length&&"geometry"===e.path[0]&&0===e.type&&void 0!==e.props.operation&&(this.freeBooleanPointer(),this.resetBBoxNeedsUpdate())}freeBooleanPointer(){super.freeBooleanPointer(),this.geometry.dispose()}recomputeBoolean(s,o=!0){if(-1!==this.booleanMeshSetAddress&&!s)return;for(let e=0;e<this.children.length;e++){let t=this.children[e];t instanceof F&&!0===t.dataPatched.visible&&t.recomputeBoolean(!0===s,o)}this.meshSetAddresses=[];for(let e=0;e<this.children.length;e++){let t=this.children[e];if(t instanceof p&&!0===t.dataPatched.visible&&t.geometry.attributes.position?.count>0&&t.geometry.drawRange.count>0&&0!==t.booleanMeshSetAddress){b.multiplyMatrices(t.hiddenMatrix,t.matrix).multiply(t.pivotMatrix);try{let e=D(t,this);if(-1===t.booleanMeshSetAddress){if((t.geometry.index??t.geometry.getAttribute("position")).count/3<15e5){let r=a(t.geometry,!0===s,o);t.booleanMeshSetAddress=void 0===e||-1===r?r:O(t,e,r,b)}if(-1===t.booleanMeshSetAddress)return;void 0===e&&h(t.booleanMeshSetAddress,b),t.booleanMatrixInvOld.copy(b).invert(),t.booleanWasTransformed=!1}else t instanceof F&&!0===t.needsTransformForDownstream?(void 0===e?h(t.booleanMeshSetAddress,b):t.booleanMeshSetAddress=O(t,e,t.booleanMeshSetAddress,b),t.needsTransformForDownstream=!1):!0===t.booleanWasTransformed&&(h(t.booleanMeshSetAddress,M.multiplyMatrices(b,t.booleanMatrixInvOld)),t.booleanMatrixInvOld.copy(b).invert(),t.booleanWasTransformed=!1)}catch(e){console.error(e),t.booleanMeshSetAddress=0,t.geometry.userData.booleanOperationDidFail=!0;continue}if(0===t.booleanMeshSetAddress)continue;this.meshSetAddresses.push(t.booleanMeshSetAddress),t.geometry.userData.booleanOperationDidFail=!1}}if(0===this.meshSetAddresses.length){if(0!==this.geometry.getAttribute("position")?.array.length){let e=this.geometry;e.dispose(),this.geometry=new g,this.geometry.userData=e.userData,this.geometry.boundingSphere=e.boundingSphere,this.geometry.setAttribute("position",new y([],3))}return void this.geometry.setDrawRange(0,0)}if(!0===s)return d(this.meshSetAddresses,this.booleanOp);let r=this.geometry;r.dispose(),this.geometry=new g,this.geometry.userData=r.userData,this.geometry.boundingSphere=r.boundingSphere;try{this.booleanMeshSetAddress=n(this.meshSetAddresses,this.booleanOp,this.geometry,this.phongAngle)}catch(e){this.booleanMeshSetAddress=0,this.geometry.userData.booleanOperationDidFail=!0,console.error(e)}this.booleanMatrixInvOld.copy(this.matrix).invert(),this.needsTransformForDownstream=!0,e(this),t(this)}dispose(){super.dispose(),this.geometry.dispose()}};(B||(B={})).is=function(e){return i.is(e)&&e instanceof f};var P=(e,t)=>class extends(o(e,t)){updateState_Light(e,t){if(this.updateState_Entity(e,t),void 0!==e.color&&(this.color=t.shared.color(e.color)),void 0!==e.intensity&&(this.intensity=e.intensity*Math.PI),void 0!==e.depth){let t=this.shadow;t.camera.far=e.depth,t.needsUpdate=!0}void 0!==e.shadows&&(this.castShadow=e.shadows)}},T=e=>e instanceof p,j=e=>null!==e&&e instanceof F,I=e=>s.is(e);export{w as a,F as b,B as c,P as d,T as e,j as f,I as g};
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{e,g as t,j as a}from"./runtime-chunk-HRGNIGSC.js";import{a as r}from"./runtime-chunk-5MDYMRYM.js";import{a as n,b as o}from"./runtime-chunk-VJPN4EM6.js";import{c as i,e as s,f as l}from"./runtime-chunk-33KX2TOT.js";import{a as u}from"./runtime-chunk-44F5FA4N.js";import{b as d}from"./runtime-chunk-KRQKRJPD.js";import{U as p,Y as c,Z as h,da as f,ea as g,h as m}from"./runtime-chunk-3D6ELLRB.js";import{v as y}from"./runtime-chunk-R3V4RB3X.js";import{d as b,e as v}from"./runtime-chunk-2PT2WH66.js";import{d as w,f as j}from"./runtime-chunk-4KZXQGUQ.js";import{A as D,B as S,I as E,N as V,O as B,P as x,Q as O,R as A,S as C,da as k,ma as M,pa as R,va as N,z as P}from"./runtime-chunk-VPEJ5BFD.js";import{Cc as G,Dc as q,Ec as z,Fc as I,Oc as F,Pc as $,Tc as T}from"./runtime-chunk-VGN7YHB7.js";var{degToRad:_,radToDeg:U}=G,L=new I,W=new I,Q=new z;function K(e,t,a,r,n,o){let i=void 0!==a[e]?a[e]:void 0,s=r[e];if(null==s)return;let l=null!=i?"string"==typeof i?Number(n.getVariable(i)??0):i:t[e],u="string"==typeof s?Number(n.getVariable(s)??0):s;return l!==u?{update:a=>{let r=G.lerp(l,u,a);t[e]=o?Math.trunc(r):r},start:()=>{t[e]=l},end:()=>{t[e]=u}}:void 0}function Y(e,t,a,r,n,o){let i=a[e]?a[e]:void 0,s=r[e];if(!s)return;let l=t[e],u=[...i??l].map(e=>"string"==typeof e?Number(n.getVariable(e)??0):e),d=[...s].map(e=>"string"==typeof e?Number(n.getVariable(e)??0):e);return u.length!==d.length||w(u,d)?void 0:{update:a=>{u.forEach((r,n)=>{let i=G.lerp(r,d[n],a);t[e][n]=o?Math.trunc(i):i})},start:()=>{Object.assign(t[e],u)},end:()=>{Object.assign(t[e],d)}}}function H(e,t,a){return t.forEach((t,r)=>{e.setComponent(r,"string"==typeof t?Number(a.getVariable(t)??0):t)}),e}function J(e,t,a,r,n){let o=a[e]?a[e]:void 0,i=r[e];if(!i)return;let s=t[e],l=o?H(new I,o,n):s.clone(),u=H(new I,i,n);return l.equals(u)?void 0:{update:e=>{s.lerpVectors(l,u,e)},start:()=>{s.copy(l)},end:()=>{s.copy(u)}}}function X(e,t,a){return t.forEach((t,r)=>{e.setComponent(r,"string"==typeof t?Number(a.getVariable(t)??0):t)}),e}function Z(e,t,a,r,n){let o=a[e]?a[e]:void 0,i=r[e];if(!i)return;let s=t[e],l=!(s instanceof q),u=s instanceof q?s:(new q).fromArray(s),d=o?X(new q,o,n):u.clone(),p=X(new q,i,n);return d.equals(p)?void 0:{update:a=>{u.lerpVectors(d,p,a),l&&(t[e]=u.toArray())},start:()=>{u.copy(d),l&&(t[e]=u.toArray())},end:()=>{u.copy(p),l&&(t[e]=u.toArray())}}}function ee(e,t,a,r,n){let o=a[e]?a[e]:void 0,i=r[e];if(!i)return;let s=t[e],l=new m(s.r,s.g,s.b,s.a),u=o?"string"==typeof o?n.getColor(o).clone():new m(o.r,o.g,o.b,o.a):l.clone(),d="string"==typeof i?n.getColor(i).clone():new m(i.r,i.g,i.b,i.a);return u.equals(d)?void 0:{update:a=>{l.lerpColors(u,d,a);let r=G.lerp(u.a,d.a,a);l.a=r,t[e]={r:l.r,g:l.g,b:l.b,a:l.a}},start:()=>{l.copy(u)},end:()=>{l.copy(d)}}}function te(e,t,a,r,n){return"number"==typeof t[e]?K(e,t,a??{},r,n):Array.isArray(t[e])?Y(e,t,a??{},r,n):void 0}function ae(e,t,a,r,n){let o=a[e],i=r[e];if("number"==typeof t[e])Math.abs(o-i)>1e-4&&(t[e]=G.lerp(o,i,n));else if(Array.isArray(t[e]))for(let a=0,r=o.length;a<r;a++)t[e][a]=G.lerp(o[a],i[a],n)}function re(e,t,a,r){let n=e.geometry.userData.parameters.extrusion;if(n)return M.forEach(e=>{ae(e,n,t,a,r)}),n}function ne(e,t,a,r){let n=e.updatedPathSnapping;if(n)return N.forEach(e=>{ae(e,n,t,a,r)}),n}function oe(e,t,a,r,n){let o=e.getValue(r);if(void 0!==o){if("colors"===r)return function(e,t,a,r="colors"){if(!e.hasValue(r)||!(r in a))return;let n=[],o=e.getValue(r),i=t?t[r]:o.map(e=>e.toArray()),s=a[r];for(let e=0;e<o.length;++e){let t=[...i[e]],a=[...s[e]];S.isEqual(t,a)||n.push({update:r=>{o[e].fromArray(S.lerp(t,a,r))},start:()=>{o[e].fromArray(t)},end:()=>{o[e].fromArray(a)}})}return n.length?n:void 0}(e,t,a,r);if(Array.isArray(o))return"steps"===r?function(e,t,a,r="steps"){if(!e.hasValue(r)||!(r in a))return;let n=[],o=e.getValue(r),i=t?t[r]:o,s=a[r];return w(i,s)||n.push({update:t=>{let a=[...o];for(let e=0;e<o.length;++e){let r=i[e],n=s[e];a[e]=G.lerp(r,n,t)}e.setValue(r,a)},start:()=>{e.setValue(r,i)},end:()=>{e.setValue(r,s)}}),n.length?n:void 0}(e,t,a,r):void 0;if("number"==typeof o)return function(e,t,a,r,n){if(!e.hasValue(r)||!(r in a))return;let o=t?t[r]:e.getValue(r),i=a[r],s="string"==typeof o?Number(n.getVariable(o)??0):o,l="string"==typeof i?Number(n.getVariable(i)??0):i;return{update:t=>{e.setValue(r,G.lerp(s,l,t))},start:()=>{e.setValue(r,s)},end:()=>{e.setValue(r,l)}}}(e,t,a,r,n);if("boolean"!=typeof o){if(o instanceof q)return function(e,t,a,r){if(!e.hasValue(r)||!(r in a))return;let n=e.getValue(r),o=t?(new q).fromArray(t[r]):n.clone(),i=(new q).fromArray(a[r]);return o.equals(i)?void 0:{update:e=>{n.lerpVectors(o,i,e)},start:()=>{n.copy(o)},end:()=>{n.copy(i)}}}(e,t,a,r);if(o instanceof I)return function(e,t,a,r,n){if(!e.hasValue(r)||!(r in a))return;let o=e.getValue(r),i=t?t[r]:void 0,s=a[r],l=i?H(new I,i,n):o.clone(),u=H(new I,s,n);return l.equals(u)?void 0:{update:e=>{o.lerpVectors(l,u,e)},start:()=>{o.copy(l)},end:()=>{o.copy(u)}}}(e,t,a,r,n);if(o instanceof m)return function(e,t,a,r,n){if(!e.hasValue(r)||!(r in a))return;let o=t?t[r]:void 0,i=a[r],s=e.getValue(r),l=o?"string"==typeof o?n.color(o).clone():(new T).setRGB(o.r,o.g,o.b):s.clone(),u="string"==typeof i?n.color(i).clone():new m(i.r,i.g,i.b,i.a);if(l.equals(u))return;let d=s.clone();return{update:t=>{e.getValue(r)!==d&&e.setValue(r,d),d.lerpColors(l,u,t)},start:()=>{d.copy(l)},end:()=>{d.copy(u)}}}(e,t,a,r,n);if(o instanceof T)return function(e,t,a,r,n){if(!e.hasValue(r)||!(r in a))return;let o=t?t[r]:void 0,i=a[r],s=e.getValue(r),l=o?"string"==typeof o?n.color(o).clone():(new T).setRGB(o.r,o.g,o.b):s.clone(),u="string"==typeof i?n.color(i).clone():(new T).setRGB(i.r,i.g,i.b);if(l.equals(u))return;let d=s.clone();return{update:t=>{e.getValue(r)!==d&&e.setValue(r,d),d.lerpColors(l,u,t)},start:()=>{d.copy(l)},end:()=>{d.copy(u)}}}(e,t,a,r,n);if("isTexture"in o)return function(e,t,a,r="texture"){if(!e.hasValue(r)||!(r in a))return;let n=e.getNode("rotation"),o=t?.[r]?.rotation??0,i=a[r]?.rotation??0;if(n&&o!==i)return{update:e=>{n.value=G.lerp(o,i,e)*G.DEG2RAD},start:()=>{n.value=o*G.DEG2RAD},end:()=>{n.value=i*G.DEG2RAD}};let s=e.getNode("mat"),l=s&&"function"==typeof s.updateMatrix?s:e.getValue("mat");if(!l)return;let u=t?t[r]:l,d=a[r],p=[...u.repeat],c=[...u.offset],h=[...d.repeat],f=[...d.offset],g=u.rotation??0,m=d.rotation??0;return P.isEqual(p,h)&&P.isEqual(c,f)&&g===m?void 0:{update:e=>{l.repeat=P.lerp(p,h,e),l.offset=P.lerp(c,f,e),l.rotation=G.lerp(g,m,e),l.updateMatrix()},start:()=>{l.repeat=[...p],l.offset=[...c],l.rotation=g,l.updateMatrix()},end:()=>{l.repeat=[...h],l.offset=[...f],l.rotation=m,l.updateMatrix()}}}(e,t,a,r)}}}function ie(e,t,a,r){let n=[],o=p(a,r)||!!t.layers&&p(t,r);n.push(function(e,t){return{update:()=>{e.transparent=t}}}(e,o)),function(e,t,a){let r=e.ensureRainbowNoiseCompiled;if("function"==typeof r)for(let n of[...e.layers]){if("rainbow"!==n.type)continue;let o=t.layers?.data(n.uuid),i=a.layers.data(n.uuid);(c(o?.noiseStrength)||c(i?.noiseStrength))&&r.call(e,n.uuid)}}(e,t,a);for(let o of e.layers){let e=t.layers?.data(o.uuid),i=a.layers.data(o.uuid);if(!i||"light"!==o.type&&(!(o.visible??1)||!(i.visible??1)))continue;let s=h[o.type]??[],l=o.getNames().filter(e=>!s.includes(e)&&!k.some(t=>e.includes(t)));for(let t of l)try{let a=oe(o,e,i,t,r);a&&(Array.isArray(a)?n.push(...a):n.push(a))}catch(e){console.error(`lerpMaterial: unexpected material layer for ${t}`,e)}}return n}function se(e,t,a,r,n,o){let i=oe(t,a,r,e,o);!i||(Array.isArray(i)?i.forEach(e=>e.update(n)):i.update(n))}new $;var le=new I,ue=new $;function de(e,t,a,r){let n=r.cloner?.parameters;if(n){ae("count",n,e,t,a),n.count=Math.trunc(n.count);for(let r of B)ae(r,n.radial,e.radial,t.radial,a);for(let r of x)ae(r,n.linear,e.linear,t.linear,a);for(let r of O)ae(r,n.grid,e.grid,t.grid,a);for(let r of A)ae(r,n.toObject,e.toObject,t.toObject,a);return n}}function pe(e,t,a,r){let n=r.cloner?.parameters;if(n){for(let r of C)ae(r,n.randomnessObject,e.randomnessObject,t.randomnessObject,a);return n}}function ce(r,n,o,p,c){let h=[];return r.data.visible&&h.push(...function(e,t,a,r,n){let o,i,u,d,p,c,h,f,g=[];if(v(e)?(o=Z("position",e,t,a,n),o&&g.push(o),u=K("rotation",e,t,a,n),u&&g.push(u),d=Z("shear",e,t,a,n),d&&g.push(d)):(f={slide:t.pathSnapping?.slide??e.updatedPathSnapping?.slide??e.dataPatched.pathSnapping?.slide??0,offset:t.pathSnapping?.offset??e.updatedPathSnapping?.offset??e.dataPatched.pathSnapping?.offset??0},c=K("slide",f,t.pathSnapping??e.updatedPathSnapping??e.dataPatched.pathSnapping,a.pathSnapping??e.dataPatched.pathSnapping,n),c&&g.push(c),h=K("offset",f,t.pathSnapping??e.updatedPathSnapping??e.dataPatched.pathSnapping,a.pathSnapping??e.dataPatched.pathSnapping,n),h&&g.push(h),!c&&!h&&(o=J("position",e,t,a,n),o&&g.push(o),i=J("scale",e,t,a,n),i&&g.push(i),u=function(e,t,a,r,n){let o=t?.rotation?t.rotation.map(e=>("string"==typeof e?Number(n.getVariable(e)??0):e)*G.DEG2RAD):void 0,i=a.rotation?.map(e=>("string"==typeof e?Number(n.getVariable(e)??0):e)*G.DEG2RAD);if(!i)return;let s=o?(new I).fromArray(o):(new I).setFromEuler(e.rotation),l=(new I).fromArray(i);if(s.equals(l))return;let u=le.subVectors(l,s);if(r&&u.toArray().every(e=>Math.abs(e)<2*Math.PI)){let t=(new z).setFromEuler(ue.setFromVector3(s)),a=(new z).setFromEuler(ue.setFromVector3(l));return{update:r=>{!function(e,t,a,r){if(0===r)return a.copy(e);if(1===r)return a.copy(t);let n=e.w*t.w+e.x*t.x+e.y*t.y+e.z*t.z;if(n>=1)return a.copy(e);let o=1-n*n;if(o<=Number.EPSILON){let n=1-r;return a.w=n*e.w+r*t.w,a.x=n*e.x+r*t.x,a.y=n*e.y+r*t.y,a.z=n*e.z+r*t.z,a.normalize(),a}let i=Math.sqrt(o),s=Math.atan2(i,n),l=Math.sin((1-r)*s)/i,u=Math.sin(r*s)/i;a.w=e.w*l+t.w*u,a.x=e.x*l+t.x*u,a.y=e.y*l+t.y*u,a.z=e.z*l+t.z*u}(t,a,e.quaternion,r)},start:()=>{e.rotation.setFromVector3(s)},end:()=>{e.rotation.setFromVector3(l)}}}return{update:t=>{le.lerpVectors(s,l,t),e.rotation.setFromVector3(le)},start:()=>{e.rotation.setFromVector3(s)},end:()=>{e.rotation.setFromVector3(l)}}}(e,t,a,r,n),u&&g.push(u),p=function(e,t,a,r){let n=a[e]?a[e]:void 0,o=r[e];if(!o)return;let i=t[e],s=n?(new F).fromArray(n):i.clone(),l=new I,u=new z,d=new I;s.decompose(l,u,d);let p=(new F).fromArray(o),c=new I,h=new z,f=new I;return p.decompose(c,h,f),s.equals(p)?void 0:{update:e=>{Q.slerpQuaternions(u,h,e),L.lerpVectors(l,c,e),W.lerpVectors(d,f,e),i.compose(L,Q,W)},start:()=>{i.compose(l,u,d)},end:()=>{i.compose(c,h,f)}}}("hiddenMatrix",e,t,a),p&&g.push(p))),o||i||u||p||c||h){let a=v(e)?()=>{e.updateWorldMatrix(!0,!1,!0),e.resetBBoxNeedsUpdate()}:()=>{e.updateMatrix(),e.hasNonUniformScale&&(e.updateMatrixWorld(),e.updateMatrixWorldRigid()),e.parent?.matrixWorldFusedFalse&&(e.matrixWorld.multiplyMatrices(e.parent.matrixWorldFusedFalse,e.matrix),e.matrixWorldNeedsUpdate=!1),s(e)&&l(e.parent)&&e.invalidateDownstreamBooleanData(!0),e.updatePathSnapping(Object.assign({},t.pathSnapping,f))};g.push({update:a,start:a,end:a})}return g}(r,n,o,c,p.shared)),v(r)?h.push(...function(r,n,o,i,s){let l,u,d,p,c,h,f,g,m,y,b,v,w,j,D,S=[];if("width"in r&&(l=K("width",r,n,o,s),l&&S.push(l)),"height"in r&&(u=K("height",r,n,o,s),u&&S.push(u)),r instanceof e||r instanceof a){let t={...n.fill},a={...o.fill};void 0!==t.enabled&&t.enabled!==a.enabled&&(S.push(function(t){return{update:()=>{t instanceof e&&(t.fill.enabled=!0)}}}(r)),t.enabled||Object.assign(t,{enabled:!0,color:{...t.color,a:0}}),a.enabled||Object.assign(a,{enabled:!0,color:{...a.color,a:0}})),d=ee("color",r.fill,t,a,s),d&&S.push(d)}if(r instanceof e){let t={...n.stroke},a={...o.stroke};(t.enabled||a.enabled)&&(S.push(function(t){return{update:()=>{t instanceof e&&(t.stroke.enabled=!0)}}}(r)),t.enabled||Object.assign(t,{enabled:!0,color:{...t.color,a:0}}),a.enabled||Object.assign(a,{enabled:!0,color:{...a.color,a:0}})),p=ee("color",r.stroke,t,a,s),p&&S.push(p),c=K("thickness",r.stroke,t,a,s),c&&S.push(c)}if(r instanceof e){let t={...n.dropShadow},a={...o.dropShadow};(t.enabled||a.enabled)&&(S.push(function(t){return{update:()=>{t instanceof e&&(t.dropShadow.enabled=!0)}}}(r)),t.enabled||Object.assign(t,{enabled:!0,color:{...t.color,a:0}}),a.enabled||Object.assign(a,{enabled:!0,color:{...a.color,a:0}})),h=ee("color",r.dropShadow,t,a,s),h&&S.push(h),f=K("blurRadius",r.dropShadow,t,a,s),f&&S.push(f),m=K("spread",r.dropShadow,t,a,s),m&&S.push(m),g=Z("offset",r.dropShadow,t,a,s),g&&S.push(g)}if(r instanceof e){let t={...n.innerShadow},a={...o.innerShadow};(t.enabled||a.enabled)&&(S.push(function(t){return{update:()=>{t instanceof e&&(t.innerShadow.enabled=!0)}}}(r)),t.enabled||Object.assign(t,{enabled:!0,color:{...t.color,a:0}}),a.enabled||Object.assign(a,{enabled:!0,color:{...a.color,a:0}})),y=ee("color",r.innerShadow,t,a,s),y&&S.push(y),b=K("blurRadius",r.innerShadow,t,a,s),b&&S.push(b),w=K("spread",r.innerShadow,t,a,s),w&&S.push(w),v=Z("offset",r.innerShadow,t,a,s),v&&S.push(v)}if(r instanceof e||r instanceof a){let t={...n.backgroundBlur},a={...o.backgroundBlur};(t.enabled||a.enabled)&&(S.push(function(t){return{update:()=>{t instanceof e&&(t.backgroundBlur.enabled=!0)}}}(r)),t.enabled||Object.assign(t,{enabled:!0,radius:0}),a.enabled||Object.assign(a,{enabled:!0,radius:0})),j=K("radius",r.backgroundBlur,t,a,s),j&&S.push(j)}if(r instanceof e){let t={...n.layerBlur},a={...o.layerBlur};(t.enabled||a.enabled)&&(S.push(function(t){return{update:()=>{t instanceof e&&(t.layerBlur.enabled=!0)}}}(r)),t.enabled||Object.assign(t,{enabled:!0,radius:0}),a.enabled||Object.assign(a,{enabled:!0,radius:0})),D=K("radius",r.layerBlur,t,a,s),D&&S.push(D)}if(r instanceof a||r instanceof t){let e=Y("cornerRadius",r,n,o,s);e&&S.push(e)}return S}(r,n,o,0,p.shared)):(r.data.visible&&h.push(...function(e,t,a,r){let n=[];if(!("cloner"in a)||!e.cloner)return n;let o=e.cloner,i="cloner"in t?t.cloner:{},s=a.cloner;V.forEach(e=>{let t;t="count"===e?K("count",o.parameters,i,s,r.shared,!0):te(e,o.parameters,i??{},s,r.shared),t&&n.push(t)});let l=function(e,t,a,r){if("radial"!==e.parameters.type)return;let n=t.radial,o=a.radial;if(!o)return;let i=e.parameters.radial,s=[];return B.forEach(e=>{let t=te(e,i,n??{},o,r);t&&s.push(t)}),s}(o,i,s,r.shared);l?.length&&n.push(...l);let u=function(e,t,a,r){if("linear"!==e.parameters.type)return;let n=t.linear,o=a.linear;if(!o)return;let i=[],s=e.parameters.linear;return x.forEach(e=>{let t=te(e,s,n??{},o,r);t&&i.push(t)}),i}(o,i,s,r.shared);u?.length&&n.push(...u);let d=function(e,t,a,r){if("grid"!==e.parameters.type)return;let n=t.grid,o=a.grid;if(!o)return;let i=[],s=e.parameters.grid;return O.forEach(e=>{let t;t="count"===e?Y(e,s,n??{},o,r,!0):te(e,s,n??{},o,r),t&&i.push(t)}),i}(o,i,s,r.shared);d?.length&&n.push(...d);let p=function(e,t,a,r){if("toObject"!==e.parameters.type)return;let n=t.toObject,o=a.toObject;if(!o)return;let i=[],s=e.parameters.toObject;return A.forEach(e=>{let t;t="count"===e?K(e,s,n??{},o,r,!0):te(e,s,n??{},o,r),t&&i.push(t)}),i}(o,i,s,r.shared);p?.length&&n.push(...p);let c=function(e,t,a,r){if(!e.parameters.randomness)return;let n=t.randomnessObject,o=a.randomnessObject;if(!o)return;let i=[],s=e.parameters.randomnessObject;return C.forEach(e=>{let t=te(e,s,n??{},o,r);t&&i.push(t)}),i}(o,i,s,r.shared);return c?.length&&n.push(...c),n.length&&n.push({update:()=>{o.update(r)}}),n}(r,n,o,p)),r instanceof y?(r instanceof g&&r.data.visible&&h.push(...function(e,t,a,r){let n=[];if(!("geometry"in a))return n;let o=e.geometry.userData.parameters,i="geometry"in t?t.geometry:{},s=a.geometry;if(e instanceof d){let t=function(e,t,a,r){if(void 0===a.scaleBaked)return;let n=(t.scaleBaked??e.data.geometry.scaleBaked).map(e=>"string"==typeof e?Number(r.shared.getVariable(e)??0):e),o=a.scaleBaked.map(e=>"string"==typeof e?Number(r.shared.getVariable(e)??0):e);if(D.isEqual(n,o))return;let i=[];return i.push({update:t=>{e.updateGeometryInteractions({scaleBaked:[G.lerp(n[0],o[0],t),G.lerp(n[1],o[1],t),G.lerp(n[2],o[2],t)]},r.shared),e.invalidateDownstreamBooleanData(),e.refreshAttachedClonersInteractions(r)},start:()=>{e.updateGeometryInteractions({scaleBaked:n},r.shared),e.invalidateDownstreamBooleanData(),e.refreshAttachedClonersInteractions(r)},end:()=>{e.updateGeometryInteractions({scaleBaked:o},r.shared),e.invalidateDownstreamBooleanData(),e.refreshAttachedClonersInteractions(r)}}),i}(e,i,s,r);t&&n.push(...t)}else{let t={};if(Object.assign(t,j(o,R),j(i,R)),R.forEach(e=>{let a=te(e,t,i,s,r.shared);a&&n.push(a)}),b(e)){Object.assign(t,{extrusion:{...o.extrusion}});let e=function(e,t,a,r){if(!a.extrusion)return;let n=e.extrusion,o=t.extrusion??{},i=a.extrusion,s=[];return M.forEach(e=>{let t=te(e,n,o,i,r);t&&s.push(t)}),s}(t,i,s,r.shared);e&&n.push(...e)}n.length&&n.push({update:a=>{e.updateGeometryInteractions(t,r.shared),e.updateGeometryGroupsIfNeeded(),e.refreshAttachedClonersInteractions(r)},start:a=>{e.updateGeometryInteractions(t,r.shared),e.updateGeometryGroupsIfNeeded(),e.refreshAttachedClonersInteractions(r)},end:a=>{e.updateGeometryInteractions(t,r.shared),e.updateGeometryGroupsIfNeeded(),e.refreshAttachedClonersInteractions(r)}})}return n}(r,n,o,p)),r.data.visible&&!(r instanceof f&&r.materialOverride)&&h.push(...function(e,t,a,r){let n=[];if(Array.isArray(e.material)){if(!("materials"in a)||!a.materials)return n;let o="materials"in t&&t.materials?t.materials:[],i=a.materials;e.material.forEach((e,t)=>{if(!i[t])return;let a=o[t]??{},s=i[t];"string"==typeof a||"string"==typeof s||n.push(...ie(e,a,s,r))})}else{if(!("material"in a)||!a.material)return n;let o="material"in t&&t.material?t.material:{},i=a.material;if("string"==typeof o||"string"==typeof i)return n;n.push(...ie(e.material,o,i,r))}return n}(r,n,o,p.shared))):i.is(r)?r.data.visible&&h.push(...function(e,t,a,r){let n=[];if(void 0!==a.intensity){let o=K("intensity",e,t,a,r);o&&n.push(o)}if(void 0!==a.color){let o=function(e,t,a,r,n){let o=a[e]?a[e]:void 0,i=r[e];if(!i)return;let s=t[e],l=o?"string"==typeof o?n.getColor(o).clone():(new T).setRGB(o.r,o.g,o.b):s.clone(),u="string"==typeof i?n.getColor(i).clone():(new T).setRGB(i.r,i.g,i.b);if(l.equals(u))return;let d=s.clone();return{update:a=>{d.lerpColors(l,u,a),t[e]?.copy?.(d)},start:()=>{d.copy(l)},end:()=>{d.copy(u)}}}("color",e,t,a,r);o&&n.push(o)}return n}(r,n,o,p.shared)):r instanceof u&&h.push(...function(e,t,a,r){let n=[],o="OrthographicCamera"===e.cameraType?t.orthographic?.zoom:t.perspective?.zoom,i="OrthographicCamera"===e.cameraType?a.orthographic?.zoom:a.perspective?.zoom;if(void 0!==i){let t=o??e.zoom,a=i;t!==a&&n.push({update:r=>{e.zoom=G.lerp(t,a,r),e.updateProjectionMatrix()},start:()=>{e.zoom=t,e.updateProjectionMatrix()},end:()=>{e.zoom=a,e.updateProjectionMatrix()}})}if(void 0!==a.targetOffset){let o=K("targetOffset",e,t,a,r);o&&n.push(o)}return n}(r,n,o,p.shared))),h.length?{update:e=>{h.forEach(t=>t.update(e))},start:e=>{h.forEach(t=>t.start?.(e))},end:e=>{h.forEach(t=>t.end?.(e))}}:void 0}function he(e,t){return{position(t){Object.assign(e.position,t),(void 0!==t.x||void 0!==t.y||void 0!==t.z)&&(e.updateMatrix(),e.resetBBoxNeedsUpdate(),e instanceof g&&e.invalidateDownstreamBooleanData(),e.dispatchEvent({type:"requestRender"}))},rotation(t){let a=Object.keys(t)[0];e.rotation[a]=t[a]*G.DEG2RAD,(void 0!==t.x||void 0!==t.y||void 0!==t.z)&&(e.updateMatrix(),e.resetBBoxNeedsUpdate(),e instanceof g&&e.invalidateDownstreamBooleanData(),e.dispatchEvent({type:"requestRender"}))},scale(t){Object.assign(e.scale,t),(void 0!==t.x||void 0!==t.y||void 0!==t.z)&&(e.updateMatrix(),e.resetBBoxNeedsUpdate(),e instanceof g&&e.invalidateDownstreamBooleanData(),e.dispatchEvent({type:"requestRender"}))},shapeSize(a){e instanceof g&&(e.userData.value={...e.userData.value,...a},(void 0!==a.x||void 0!==a.y||void 0!==a.z)&&(e.updateGeometryInteractions({width:e.userData.value.x,height:e.userData.value.y,depth:e.userData.value.z},t.shared),e.resetBBoxNeedsUpdate(),e.invalidateDownstreamBooleanData(),e.dispatchEvent({type:"requestRender"})))},material(a,r,n){n&&(Object.entries(n).forEach(([a,{start:n,end:o,t:i}])=>{let s=r.getValue(a);e instanceof y&&!Array.isArray(e.material)&&"alpha"===a&&"number"==typeof s&&s>0&&(e.material.transparent=!0),void 0!==s&&se(a,r,n,o,i,t.shared)}),e.dispatchEvent({type:"requestRender"}))},opacity(a){if(e instanceof y&&!Array.isArray(e.material)){let r=e.material.getLayersOfType("light")[0];if(void 0===r)return;e.material.transparent=!0,se("alphaOverride",r,{alphaOverride:a},{alphaOverride:a+1},0,t.shared),e.dispatchEvent({type:"requestRender"})}},light(t,a){(e instanceof n||e instanceof r||e instanceof o)&&(e[t]=a,e.dispatchEvent({type:"requestRender"}))},cloner(e){e.cloner?.update(t),e instanceof g&&e.invalidateDownstreamBooleanData(),e.dispatchEvent({type:"requestRender"})},pathExtrusion(e,a){e.geometry.userData.parameters.extrusion={...e.geometry.userData.parameters.extrusion,...a},e.updateGeometryInteractions({extrusion:{...e.geometry.userData.parameters.extrusion}},t.shared),e.resetBBoxNeedsUpdate(),e.invalidateDownstreamBooleanData(),e.dispatchEvent({type:"requestRender"})},pathSnapping(t){e.userData.pathSnapping={...e.userData.pathSnapping,...t},e.updatePathSnapping(e.userData.pathSnapping),e.dispatchEvent({type:"requestRender"})}}}var fe={type:"beginState"};function ge(e){let t;if(5===e.easing){let{control1:a,control2:r}=e;t=`cubicBezier(\n\t\t\t${a[0]}, ${a[1]}, ${r[0]}, ${r[1]}\n\t\t)`}else if(6===e.easing){let{mass:a,stiffness:r,damping:n,velocity:o}=e;t=`spring( ${a}, ${r}, ${n}, ${o} )`}else{let a;switch(e.easing){case 0:default:a=E.linear;break;case 1:a=E.ease;break;case 2:a=E.easeIn;break;case 3:a=E.easeOut;break;case 4:a=E.easeInOut}let[r,n,o,i]=a;t=`cubicBezier( ${r}, ${n}, ${o}, ${i} )`}return{duration:Math.max(e.duration,1e-4),easing:t}}function me(e){let t={delay:0,loop:-1===e.repeat||e.repeat+1};if(0===e.repeat)t.direction="normal",t.rewind=!1;else switch(e.direction){case"pingpong":t.direction="alternate",t.rewind=!1;break;case"pingpong-rewind":t.direction="alternate",t.rewind=!0;break;default:t.direction="normal",t.rewind=!1}switch(t.delay=0,t.endDelay=0,t.startOnceDelay=0,t.pingPongDelayCorrection=0,t.pingPongEndDelayCorrection=0,e.delayDirection){case"start-once":t.startOnceDelay=e.delay;break;case"start":t.delay=e.delay;break;case"end":t.endDelay=e.delay;break;case"start-end":case void 0:t.delay=e.delay,t.endDelay=e.delay}return"alternate"===t.direction&&(t.delay/=2,t.endDelay/=2,"start"===e.delayDirection?(t.pingPongDelayCorrection=t.delay,"number"==typeof t.loop&&t.loop%2==0&&(t.pingPongEndDelayCorrection=t.delay)):"end"===e.delayDirection?"number"==typeof t.loop&&t.loop%2!=0&&(t.pingPongEndDelayCorrection=t.endDelay):"start-end"===e.delayDirection&&(t.pingPongDelayCorrection=t.delay,t.pingPongEndDelayCorrection=t.endDelay)),t}var ye={type:"completeState",isfromEntity:!1};function be(e,t){let a,r;if("string"==typeof t?(a=t,r=e.states?.[a]):null===t&&(a=null,r=e.data),void 0!==a&&void 0!==r)return{id:a,data:r}}var ve=class{constructor(e,t,a,r,n,o,i){if(this.object=e,this.data=r,this.sharedAssets=n,this.allowSlerp=o,this.page=i,this.targets={t:0},this.firstLoop=!0,this._changeBegan=!1,this._changeCompleted=!0,this.onChange=()=>{this.callback&&(this.callback.update(this.targets.t),this.object.requestRender()),0===this.targets.t||1===this.targets.t?this._changeCompleted||(this._changeCompleted=!0,this._changeBegan=!1,this.onChangeComplete()):(this._changeCompleted&&(this._changeCompleted=!1),this._changeBegan||(this._changeBegan=!0,this.onChangeBegin()))},this.onChangeBegin=()=>{this.object.reversibleToState=this.to.id;let e=this.targets.t>.5?this.from.id:this.to.id;this.object.prevState!==this.object.currentState&&(this.object.prevState=this.object.currentState),this.object.currentState=e,this.object.dispatchEvent({type:"beginState",state:e}),v(this.object)||this.object.traverseEntity(e=>{e!==this.object&&e instanceof u&&e.dispatchEvent(fe)})},this.onChangeComplete=()=>{this.firstLoop&&(this.onFirstLoop(),this.firstLoop=!1),this.object.reversibleToState=this.to.id;let e=this.targets.t<.5?this.from.id:this.to.id;this.object.prevState!==this.object.currentState&&(this.object.prevState=this.object.currentState),this.object.currentState=e,this.object.dispatchEvent({type:"completeState",state:e}),v(this.object)||this.object.traverseEntity(e=>{e!==this.object&&e instanceof u&&e.dispatchEvent(ye)})},this.onFirstLoop=()=>{this.useCurrentState&&(this.callback=ce(this.object,this.from.data,this.to.data,{scene:this.page.scene,shared:this.sharedAssets},this.allowSlerp))},void 0===t){let e=be(this.object,this.object.currentState===a?this.object.prevState:this.object.currentState);if(!e)throw new Error("Missing property");this.from=e}else{let e=be(this.object,t);if(!e)throw new Error("Missing property");this.from=e}if(void 0===a)throw new Error("Missing property");{let e=be(this.object,a);if(!e)throw new Error("Missing property");this.to=e}this.useCurrentState=void 0===t||void 0===a,this.params={targets:this.targets,t:1,autoplay:!1,...me(r),...ge(r),change:this.onChange},this.callback=ce(this.object,void 0===t?{}:this.from.data,void 0===a?{}:this.to.data,{scene:this.page.scene,shared:this.sharedAssets},this.allowSlerp)}get changeBegan(){return this._changeBegan}get changeCompleted(){return this._changeCompleted}};export{re as a,ne as b,de as c,pe as d,he as e,fe as f,ge as g,me as h,ye as i,be as j,ve as k};
|
|
1
|
+
import{e,g as t,j as a}from"./runtime-chunk-I6B5A36U.js";import{a as r}from"./runtime-chunk-ZM7N5SZG.js";import{a as n,b as o}from"./runtime-chunk-RTRWO43P.js";import{c as i,e as s,f as l}from"./runtime-chunk-ZASM3KKC.js";import{a as u}from"./runtime-chunk-YS7K3AW3.js";import{b as d}from"./runtime-chunk-JSRKKIOS.js";import{U as p,Y as c,Z as h,da as f,ea as g,h as m}from"./runtime-chunk-7FDJ7IIR.js";import{v as y}from"./runtime-chunk-MOZWC42D.js";import{d as b,e as v}from"./runtime-chunk-2PT2WH66.js";import{d as w,f as j}from"./runtime-chunk-4KZXQGUQ.js";import{A as S,B as D,I as E,N as V,O as x,P as B,Q as O,R as A,S as C,da as k,ma as M,pa as R,va as N,z as P}from"./runtime-chunk-VPEJ5BFD.js";import{Cc as G,Dc as q,Ec as z,Fc as I,Oc as F,Pc as $,Tc as T}from"./runtime-chunk-VGN7YHB7.js";var{degToRad:U,radToDeg:W}=G,_=new I,L=new I,K=new z;function Z(e,t,a,r,n,o){let i=void 0!==a[e]?a[e]:void 0,s=r[e];if(null==s)return;let l=null!=i?"string"==typeof i?Number(n.getVariable(i)??0):i:t[e],u="string"==typeof s?Number(n.getVariable(s)??0):s;return l!==u?{update:a=>{let r=G.lerp(l,u,a);t[e]=o?Math.trunc(r):r},start:()=>{t[e]=l},end:()=>{t[e]=u}}:void 0}function Q(e,t,a,r,n,o){let i=a[e]?a[e]:void 0,s=r[e];if(!s)return;let l=t[e],u=[...i??l].map(e=>"string"==typeof e?Number(n.getVariable(e)??0):e),d=[...s].map(e=>"string"==typeof e?Number(n.getVariable(e)??0):e);return u.length!==d.length||w(u,d)?void 0:{update:a=>{u.forEach((r,n)=>{let i=G.lerp(r,d[n],a);t[e][n]=o?Math.trunc(i):i})},start:()=>{Object.assign(t[e],u)},end:()=>{Object.assign(t[e],d)}}}function J(e,t,a){return t.forEach((t,r)=>{e.setComponent(r,"string"==typeof t?Number(a.getVariable(t)??0):t)}),e}function Y(e,t,a,r,n){let o=a[e]?a[e]:void 0,i=r[e];if(!i)return;let s=t[e],l=o?J(new I,o,n):s.clone(),u=J(new I,i,n);return l.equals(u)?void 0:{update:e=>{s.lerpVectors(l,u,e)},start:()=>{s.copy(l)},end:()=>{s.copy(u)}}}function H(e,t,a){return t.forEach((t,r)=>{e.setComponent(r,"string"==typeof t?Number(a.getVariable(t)??0):t)}),e}function X(e,t,a,r,n){let o=a[e]?a[e]:void 0,i=r[e];if(!i)return;let s=t[e],l=!(s instanceof q),u=s instanceof q?s:(new q).fromArray(s),d=o?H(new q,o,n):u.clone(),p=H(new q,i,n);return d.equals(p)?void 0:{update:a=>{u.lerpVectors(d,p,a),l&&(t[e]=u.toArray())},start:()=>{u.copy(d),l&&(t[e]=u.toArray())},end:()=>{u.copy(p),l&&(t[e]=u.toArray())}}}function ee(e,t,a,r,n){let o=a[e]?a[e]:void 0,i=r[e];if(!i)return;let s=t[e],l=new m(s.r,s.g,s.b,s.a),u=o?"string"==typeof o?n.getColor(o).clone():new m(o.r,o.g,o.b,o.a):l.clone(),d="string"==typeof i?n.getColor(i).clone():new m(i.r,i.g,i.b,i.a);return u.equals(d)?void 0:{update:a=>{l.lerpColors(u,d,a);let r=G.lerp(u.a,d.a,a);l.a=r,t[e]={r:l.r,g:l.g,b:l.b,a:l.a}},start:()=>{l.copy(u)},end:()=>{l.copy(d)}}}function te(e,t,a,r,n){return"number"==typeof t[e]?Z(e,t,a??{},r,n):Array.isArray(t[e])?Q(e,t,a??{},r,n):void 0}function ae(e,t,a,r,n){let o=a[e],i=r[e];if("number"==typeof t[e])Math.abs(o-i)>1e-4&&(t[e]=G.lerp(o,i,n));else if(Array.isArray(t[e]))for(let a=0,r=o.length;a<r;a++)t[e][a]=G.lerp(o[a],i[a],n)}function re(e,t,a,r){let n=e.geometry.userData.parameters.extrusion;if(n)return M.forEach(e=>{ae(e,n,t,a,r)}),n}function ne(e,t,a,r){let n=e.updatedPathSnapping;if(n)return N.forEach(e=>{ae(e,n,t,a,r)}),n}function oe(e,t,a,r,n){let o=e.getValue(r);if(void 0!==o){if("colors"===r)return function(e,t,a,r="colors"){if(!e.hasValue(r)||!(r in a))return;let n=[],o=e.getValue(r),i=t?t[r]:o.map(e=>e.toArray()),s=a[r];for(let e=0;e<o.length;++e){let t=[...i[e]],a=[...s[e]];D.isEqual(t,a)||n.push({update:r=>{o[e].fromArray(D.lerp(t,a,r))},start:()=>{o[e].fromArray(t)},end:()=>{o[e].fromArray(a)}})}return n.length?n:void 0}(e,t,a,r);if(Array.isArray(o))return"steps"===r?function(e,t,a,r="steps"){if(!e.hasValue(r)||!(r in a))return;let n=[],o=e.getValue(r),i=t?t[r]:o,s=a[r];return w(i,s)||n.push({update:t=>{let a=[...o];for(let e=0;e<o.length;++e){let r=i[e],n=s[e];a[e]=G.lerp(r,n,t)}e.setValue(r,a)},start:()=>{e.setValue(r,i)},end:()=>{e.setValue(r,s)}}),n.length?n:void 0}(e,t,a,r):void 0;if("number"==typeof o)return function(e,t,a,r,n){if(!e.hasValue(r)||!(r in a))return;let o=t?t[r]:e.getValue(r),i=a[r],s="string"==typeof o?Number(n.getVariable(o)??0):o,l="string"==typeof i?Number(n.getVariable(i)??0):i;return{update:t=>{e.setValue(r,G.lerp(s,l,t))},start:()=>{e.setValue(r,s)},end:()=>{e.setValue(r,l)}}}(e,t,a,r,n);if("boolean"!=typeof o){if(o instanceof q)return function(e,t,a,r){if(!e.hasValue(r)||!(r in a))return;let n=e.getValue(r),o=t?(new q).fromArray(t[r]):n.clone(),i=(new q).fromArray(a[r]);return o.equals(i)?void 0:{update:e=>{n.lerpVectors(o,i,e)},start:()=>{n.copy(o)},end:()=>{n.copy(i)}}}(e,t,a,r);if(o instanceof I)return function(e,t,a,r,n){if(!e.hasValue(r)||!(r in a))return;let o=e.getValue(r),i=t?t[r]:void 0,s=a[r],l=i?J(new I,i,n):o.clone(),u=J(new I,s,n);return l.equals(u)?void 0:{update:e=>{o.lerpVectors(l,u,e)},start:()=>{o.copy(l)},end:()=>{o.copy(u)}}}(e,t,a,r,n);if(o instanceof m)return function(e,t,a,r,n){if(!e.hasValue(r)||!(r in a))return;let o=t?t[r]:void 0,i=a[r],s=e.getValue(r),l=o?"string"==typeof o?n.color(o).clone():(new T).setRGB(o.r,o.g,o.b):s.clone(),u="string"==typeof i?n.color(i).clone():new m(i.r,i.g,i.b,i.a);if(l.equals(u))return;let d=s.clone();return{update:t=>{e.getValue(r)!==d&&e.setValue(r,d),d.lerpColors(l,u,t)},start:()=>{d.copy(l)},end:()=>{d.copy(u)}}}(e,t,a,r,n);if(o instanceof T)return function(e,t,a,r,n){if(!e.hasValue(r)||!(r in a))return;let o=t?t[r]:void 0,i=a[r],s=e.getValue(r),l=o?"string"==typeof o?n.color(o).clone():(new T).setRGB(o.r,o.g,o.b):s.clone(),u="string"==typeof i?n.color(i).clone():(new T).setRGB(i.r,i.g,i.b);if(l.equals(u))return;let d=s.clone();return{update:t=>{e.getValue(r)!==d&&e.setValue(r,d),d.lerpColors(l,u,t)},start:()=>{d.copy(l)},end:()=>{d.copy(u)}}}(e,t,a,r,n);if("isTexture"in o)return function(e,t,a,r="texture"){if(!e.hasValue(r)||!(r in a))return;let n=e.getNode("rotation"),o=t?.[r]?.rotation??0,i=a[r]?.rotation??0;if(n&&o!==i)return{update:e=>{n.value=G.lerp(o,i,e)*G.DEG2RAD},start:()=>{n.value=o*G.DEG2RAD},end:()=>{n.value=i*G.DEG2RAD}};let s=e.getNode("mat"),l=s&&"function"==typeof s.updateMatrix?s:e.getValue("mat");if(!l)return;let u=t?t[r]:l,d=a[r],p=[...u.repeat],c=[...u.offset],h=[...d.repeat],f=[...d.offset],g=u.rotation??0,m=d.rotation??0;return P.isEqual(p,h)&&P.isEqual(c,f)&&g===m?void 0:{update:e=>{l.repeat=P.lerp(p,h,e),l.offset=P.lerp(c,f,e),l.rotation=G.lerp(g,m,e),l.updateMatrix()},start:()=>{l.repeat=[...p],l.offset=[...c],l.rotation=g,l.updateMatrix()},end:()=>{l.repeat=[...h],l.offset=[...f],l.rotation=m,l.updateMatrix()}}}(e,t,a,r)}}}function ie(e,t,a,r){let n=[],o=p(a,r)||!!t.layers&&p(t,r);n.push(function(e,t){return{update:()=>{e.transparent=t}}}(e,o)),function(e,t,a){let r=e.ensureRainbowNoiseCompiled;if("function"==typeof r)for(let n of[...e.layers]){if("rainbow"!==n.type)continue;let o=t.layers?.data(n.uuid),i=a.layers.data(n.uuid);(c(o?.noiseStrength)||c(i?.noiseStrength))&&r.call(e,n.uuid)}}(e,t,a);for(let o of e.layers){let e=t.layers?.data(o.uuid),i=a.layers.data(o.uuid);if(!i||"light"!==o.type&&(!(o.visible??1)||!(i.visible??1)))continue;let s=h[o.type]??[],l=o.getNames().filter(e=>!s.includes(e)&&!k.some(t=>e.includes(t)));for(let t of l)try{let a=oe(o,e,i,t,r);a&&(Array.isArray(a)?n.push(...a):n.push(a))}catch(e){console.error(`lerpMaterial: unexpected material layer for ${t}`,e)}}return n}function se(e,t,a,r,n,o){let i=oe(t,a,r,e,o);!i||(Array.isArray(i)?i.forEach(e=>e.update(n)):i.update(n))}new $;var le=new I,ue=new $;function de(e,t,a,r){let n=r.cloner?.parameters;if(n){ae("count",n,e,t,a),n.count=Math.trunc(n.count);for(let r of x)ae(r,n.radial,e.radial,t.radial,a);for(let r of B)ae(r,n.linear,e.linear,t.linear,a);for(let r of O)ae(r,n.grid,e.grid,t.grid,a);for(let r of A)ae(r,n.toObject,e.toObject,t.toObject,a);return n}}function pe(e,t,a,r){let n=r.cloner?.parameters;if(n){for(let r of C)ae(r,n.randomnessObject,e.randomnessObject,t.randomnessObject,a);return n}}function ce(r,n,o,p,c){let h=[];return r.data.visible&&h.push(...function(e,t,a,r,n){let o,i,u,d,p,c,h,f,g=[];if(v(e)?(o=X("position",e,t,a,n),o&&g.push(o),u=Z("rotation",e,t,a,n),u&&g.push(u),d=X("shear",e,t,a,n),d&&g.push(d)):(f={slide:t.pathSnapping?.slide??e.updatedPathSnapping?.slide??e.dataPatched.pathSnapping?.slide??0,offset:t.pathSnapping?.offset??e.updatedPathSnapping?.offset??e.dataPatched.pathSnapping?.offset??0},c=Z("slide",f,t.pathSnapping??e.updatedPathSnapping??e.dataPatched.pathSnapping,a.pathSnapping??e.dataPatched.pathSnapping,n),c&&g.push(c),h=Z("offset",f,t.pathSnapping??e.updatedPathSnapping??e.dataPatched.pathSnapping,a.pathSnapping??e.dataPatched.pathSnapping,n),h&&g.push(h),!c&&!h&&(o=Y("position",e,t,a,n),o&&g.push(o),i=Y("scale",e,t,a,n),i&&g.push(i),u=function(e,t,a,r,n){let o=t?.rotation?t.rotation.map(e=>("string"==typeof e?Number(n.getVariable(e)??0):e)*G.DEG2RAD):void 0,i=a.rotation?.map(e=>("string"==typeof e?Number(n.getVariable(e)??0):e)*G.DEG2RAD);if(!i)return;let s=o?(new I).fromArray(o):(new I).setFromEuler(e.rotation),l=(new I).fromArray(i);if(s.equals(l))return;let u=le.subVectors(l,s);if(r&&u.toArray().every(e=>Math.abs(e)<2*Math.PI)){let t=(new z).setFromEuler(ue.setFromVector3(s)),a=(new z).setFromEuler(ue.setFromVector3(l));return{update:r=>{!function(e,t,a,r){if(0===r)return a.copy(e);if(1===r)return a.copy(t);let n=e.w*t.w+e.x*t.x+e.y*t.y+e.z*t.z;if(n>=1)return a.copy(e);let o=1-n*n;if(o<=Number.EPSILON){let n=1-r;return a.w=n*e.w+r*t.w,a.x=n*e.x+r*t.x,a.y=n*e.y+r*t.y,a.z=n*e.z+r*t.z,a.normalize(),a}let i=Math.sqrt(o),s=Math.atan2(i,n),l=Math.sin((1-r)*s)/i,u=Math.sin(r*s)/i;a.w=e.w*l+t.w*u,a.x=e.x*l+t.x*u,a.y=e.y*l+t.y*u,a.z=e.z*l+t.z*u}(t,a,e.quaternion,r)},start:()=>{e.rotation.setFromVector3(s)},end:()=>{e.rotation.setFromVector3(l)}}}return{update:t=>{le.lerpVectors(s,l,t),e.rotation.setFromVector3(le)},start:()=>{e.rotation.setFromVector3(s)},end:()=>{e.rotation.setFromVector3(l)}}}(e,t,a,r,n),u&&g.push(u),p=function(e,t,a,r){let n=a[e]?a[e]:void 0,o=r[e];if(!o)return;let i=t[e],s=n?(new F).fromArray(n):i.clone(),l=new I,u=new z,d=new I;s.decompose(l,u,d);let p=(new F).fromArray(o),c=new I,h=new z,f=new I;return p.decompose(c,h,f),s.equals(p)?void 0:{update:e=>{K.slerpQuaternions(u,h,e),_.lerpVectors(l,c,e),L.lerpVectors(d,f,e),i.compose(_,K,L)},start:()=>{i.compose(l,u,d)},end:()=>{i.compose(c,h,f)}}}("hiddenMatrix",e,t,a),p&&g.push(p))),o||i||u||p||c||h){let a=v(e)?()=>{e.updateWorldMatrix(!0,!1,!0),e.resetBBoxNeedsUpdate()}:()=>{e.updateMatrix(),e.hasNonUniformScale&&(e.updateMatrixWorld(),e.updateMatrixWorldRigid()),e.parent?.matrixWorldFusedFalse&&(e.matrixWorld.multiplyMatrices(e.parent.matrixWorldFusedFalse,e.matrix),e.matrixWorldNeedsUpdate=!1),s(e)&&l(e.parent)&&e.invalidateDownstreamBooleanData(!0),e.updatePathSnapping(Object.assign({},t.pathSnapping,f))};g.push({update:a,start:a,end:a})}return g}(r,n,o,c,p.shared)),v(r)?h.push(...function(r,n,o,i,s){let l,u,d,p,c,h,f,g,m,y,b,v,w,j,S,D=[];if("width"in r&&(l=Z("width",r,n,o,s),l&&D.push(l)),"height"in r&&(u=Z("height",r,n,o,s),u&&D.push(u)),r instanceof e||r instanceof a){let t={...n.fill},a={...o.fill};void 0!==t.enabled&&t.enabled!==a.enabled&&(D.push(function(t){return{update:()=>{t instanceof e&&(t.fill.enabled=!0)}}}(r)),t.enabled||Object.assign(t,{enabled:!0,color:{...t.color,a:0}}),a.enabled||Object.assign(a,{enabled:!0,color:{...a.color,a:0}})),d=ee("color",r.fill,t,a,s),d&&D.push(d)}if(r instanceof e){let t={...n.stroke},a={...o.stroke};(t.enabled||a.enabled)&&(D.push(function(t){return{update:()=>{t instanceof e&&(t.stroke.enabled=!0)}}}(r)),t.enabled||Object.assign(t,{enabled:!0,color:{...t.color,a:0}}),a.enabled||Object.assign(a,{enabled:!0,color:{...a.color,a:0}})),p=ee("color",r.stroke,t,a,s),p&&D.push(p),c=Z("thickness",r.stroke,t,a,s),c&&D.push(c)}if(r instanceof e){let t={...n.dropShadow},a={...o.dropShadow};(t.enabled||a.enabled)&&(D.push(function(t){return{update:()=>{t instanceof e&&(t.dropShadow.enabled=!0)}}}(r)),t.enabled||Object.assign(t,{enabled:!0,color:{...t.color,a:0}}),a.enabled||Object.assign(a,{enabled:!0,color:{...a.color,a:0}})),h=ee("color",r.dropShadow,t,a,s),h&&D.push(h),f=Z("blurRadius",r.dropShadow,t,a,s),f&&D.push(f),m=Z("spread",r.dropShadow,t,a,s),m&&D.push(m),g=X("offset",r.dropShadow,t,a,s),g&&D.push(g)}if(r instanceof e){let t={...n.innerShadow},a={...o.innerShadow};(t.enabled||a.enabled)&&(D.push(function(t){return{update:()=>{t instanceof e&&(t.innerShadow.enabled=!0)}}}(r)),t.enabled||Object.assign(t,{enabled:!0,color:{...t.color,a:0}}),a.enabled||Object.assign(a,{enabled:!0,color:{...a.color,a:0}})),y=ee("color",r.innerShadow,t,a,s),y&&D.push(y),b=Z("blurRadius",r.innerShadow,t,a,s),b&&D.push(b),w=Z("spread",r.innerShadow,t,a,s),w&&D.push(w),v=X("offset",r.innerShadow,t,a,s),v&&D.push(v)}if(r instanceof e||r instanceof a){let t={...n.backgroundBlur},a={...o.backgroundBlur};(t.enabled||a.enabled)&&(D.push(function(t){return{update:()=>{t instanceof e&&(t.backgroundBlur.enabled=!0)}}}(r)),t.enabled||Object.assign(t,{enabled:!0,radius:0}),a.enabled||Object.assign(a,{enabled:!0,radius:0})),j=Z("radius",r.backgroundBlur,t,a,s),j&&D.push(j)}if(r instanceof e){let t={...n.layerBlur},a={...o.layerBlur};(t.enabled||a.enabled)&&(D.push(function(t){return{update:()=>{t instanceof e&&(t.layerBlur.enabled=!0)}}}(r)),t.enabled||Object.assign(t,{enabled:!0,radius:0}),a.enabled||Object.assign(a,{enabled:!0,radius:0})),S=Z("radius",r.layerBlur,t,a,s),S&&D.push(S)}if(r instanceof a||r instanceof t){let e=Q("cornerRadius",r,n,o,s);e&&D.push(e)}return D}(r,n,o,0,p.shared)):(r.data.visible&&h.push(...function(e,t,a,r){let n=[];if(!("cloner"in a)||!e.cloner)return n;let o=e.cloner,i="cloner"in t?t.cloner:{},s=a.cloner;V.forEach(e=>{let t;t="count"===e?Z("count",o.parameters,i,s,r.shared,!0):te(e,o.parameters,i??{},s,r.shared),t&&n.push(t)});let l=function(e,t,a,r){if("radial"!==e.parameters.type)return;let n=t.radial,o=a.radial;if(!o)return;let i=e.parameters.radial,s=[];return x.forEach(e=>{let t=te(e,i,n??{},o,r);t&&s.push(t)}),s}(o,i,s,r.shared);l?.length&&n.push(...l);let u=function(e,t,a,r){if("linear"!==e.parameters.type)return;let n=t.linear,o=a.linear;if(!o)return;let i=[],s=e.parameters.linear;return B.forEach(e=>{let t=te(e,s,n??{},o,r);t&&i.push(t)}),i}(o,i,s,r.shared);u?.length&&n.push(...u);let d=function(e,t,a,r){if("grid"!==e.parameters.type)return;let n=t.grid,o=a.grid;if(!o)return;let i=[],s=e.parameters.grid;return O.forEach(e=>{let t;t="count"===e?Q(e,s,n??{},o,r,!0):te(e,s,n??{},o,r),t&&i.push(t)}),i}(o,i,s,r.shared);d?.length&&n.push(...d);let p=function(e,t,a,r){if("toObject"!==e.parameters.type)return;let n=t.toObject,o=a.toObject;if(!o)return;let i=[],s=e.parameters.toObject;return A.forEach(e=>{let t;t="count"===e?Z(e,s,n??{},o,r,!0):te(e,s,n??{},o,r),t&&i.push(t)}),i}(o,i,s,r.shared);p?.length&&n.push(...p);let c=function(e,t,a,r){if(!e.parameters.randomness)return;let n=t.randomnessObject,o=a.randomnessObject;if(!o)return;let i=[],s=e.parameters.randomnessObject;return C.forEach(e=>{let t=te(e,s,n??{},o,r);t&&i.push(t)}),i}(o,i,s,r.shared);return c?.length&&n.push(...c),n.length&&n.push({update:()=>{o.update(r)}}),n}(r,n,o,p)),r instanceof y?(r instanceof g&&r.data.visible&&h.push(...function(e,t,a,r){let n=[];if(!("geometry"in a))return n;let o=e.geometry.userData.parameters,i="geometry"in t?t.geometry:{},s=a.geometry;if(e instanceof d){let t=function(e,t,a,r){if(void 0===a.scaleBaked)return;let n=(t.scaleBaked??e.data.geometry.scaleBaked).map(e=>"string"==typeof e?Number(r.shared.getVariable(e)??0):e),o=a.scaleBaked.map(e=>"string"==typeof e?Number(r.shared.getVariable(e)??0):e);if(S.isEqual(n,o))return;let i=[];return i.push({update:t=>{e.updateGeometryInteractions({scaleBaked:[G.lerp(n[0],o[0],t),G.lerp(n[1],o[1],t),G.lerp(n[2],o[2],t)]},r.shared),e.invalidateDownstreamBooleanData(),e.refreshAttachedClonersInteractions(r)},start:()=>{e.updateGeometryInteractions({scaleBaked:n},r.shared),e.invalidateDownstreamBooleanData(),e.refreshAttachedClonersInteractions(r)},end:()=>{e.updateGeometryInteractions({scaleBaked:o},r.shared),e.invalidateDownstreamBooleanData(),e.refreshAttachedClonersInteractions(r)}}),i}(e,i,s,r);t&&n.push(...t)}else{let t={};if(Object.assign(t,j(o,R),j(i,R)),R.forEach(e=>{let a=te(e,t,i,s,r.shared);a&&n.push(a)}),b(e)){Object.assign(t,{extrusion:{...o.extrusion}});let e=function(e,t,a,r){if(!a.extrusion)return;let n=e.extrusion,o=t.extrusion??{},i=a.extrusion,s=[];return M.forEach(e=>{let t=te(e,n,o,i,r);t&&s.push(t)}),s}(t,i,s,r.shared);e&&n.push(...e)}n.length&&n.push({update:a=>{e.updateGeometryInteractions(t,r.shared),e.updateGeometryGroupsIfNeeded(),e.refreshAttachedClonersInteractions(r)},start:a=>{e.updateGeometryInteractions(t,r.shared),e.updateGeometryGroupsIfNeeded(),e.refreshAttachedClonersInteractions(r)},end:a=>{e.updateGeometryInteractions(t,r.shared),e.updateGeometryGroupsIfNeeded(),e.refreshAttachedClonersInteractions(r)}})}return n}(r,n,o,p)),r.data.visible&&!(r instanceof f&&r.materialOverride)&&h.push(...function(e,t,a,r){let n=[];if(Array.isArray(e.material)){if(!("materials"in a)||!a.materials)return n;let o="materials"in t&&t.materials?t.materials:[],i=a.materials;e.material.forEach((e,t)=>{if(!i[t])return;let a=o[t]??{},s=i[t];"string"==typeof a||"string"==typeof s||n.push(...ie(e,a,s,r))})}else{if(!("material"in a)||!a.material)return n;let o="material"in t&&t.material?t.material:{},i=a.material;if("string"==typeof o||"string"==typeof i)return n;n.push(...ie(e.material,o,i,r))}return n}(r,n,o,p.shared))):i.is(r)?r.data.visible&&h.push(...function(e,t,a,r){let n=[];if(void 0!==a.intensity){let o=Z("intensity",e,t,a,r);o&&n.push(o)}if(void 0!==a.color){let o=function(e,t,a,r,n){let o=a[e]?a[e]:void 0,i=r[e];if(!i)return;let s=t[e],l=o?"string"==typeof o?n.getColor(o).clone():(new T).setRGB(o.r,o.g,o.b):s.clone(),u="string"==typeof i?n.getColor(i).clone():(new T).setRGB(i.r,i.g,i.b);if(l.equals(u))return;let d=s.clone();return{update:a=>{d.lerpColors(l,u,a),t[e]?.copy?.(d)},start:()=>{d.copy(l)},end:()=>{d.copy(u)}}}("color",e,t,a,r);o&&n.push(o)}return n}(r,n,o,p.shared)):r instanceof u&&h.push(...function(e,t,a,r){let n=[],o="OrthographicCamera"===e.cameraType?t.orthographic?.zoom:t.perspective?.zoom,i="OrthographicCamera"===e.cameraType?a.orthographic?.zoom:a.perspective?.zoom;if(void 0!==i){let t=o??e.zoom,a=i;t!==a&&n.push({update:r=>{e.zoom=G.lerp(t,a,r),e.updateProjectionMatrix()},start:()=>{e.zoom=t,e.updateProjectionMatrix()},end:()=>{e.zoom=a,e.updateProjectionMatrix()}})}if(void 0!==a.targetOffset){let o=Z("targetOffset",e,t,a,r);o&&n.push(o)}return n}(r,n,o,p.shared))),h.length?{update:e=>{h.forEach(t=>t.update(e))},start:e=>{h.forEach(t=>t.start?.(e))},end:e=>{h.forEach(t=>t.end?.(e))}}:void 0}function he(e,t){return{position(t){Object.assign(e.position,t),(void 0!==t.x||void 0!==t.y||void 0!==t.z)&&(e.updateMatrix(),e.resetBBoxNeedsUpdate(),e instanceof g&&e.invalidateDownstreamBooleanData(),e.dispatchEvent({type:"requestRender"}))},rotation(t){let a=Object.keys(t)[0];e.rotation[a]=t[a]*G.DEG2RAD,(void 0!==t.x||void 0!==t.y||void 0!==t.z)&&(e.updateMatrix(),e.resetBBoxNeedsUpdate(),e instanceof g&&e.invalidateDownstreamBooleanData(),e.dispatchEvent({type:"requestRender"}))},scale(t){Object.assign(e.scale,t),(void 0!==t.x||void 0!==t.y||void 0!==t.z)&&(e.updateMatrix(),e.resetBBoxNeedsUpdate(),e instanceof g&&e.invalidateDownstreamBooleanData(),e.dispatchEvent({type:"requestRender"}))},shapeSize(a){e instanceof g&&(e.userData.value={...e.userData.value,...a},(void 0!==a.x||void 0!==a.y||void 0!==a.z)&&(e.updateGeometryInteractions({width:e.userData.value.x,height:e.userData.value.y,depth:e.userData.value.z},t.shared),e.resetBBoxNeedsUpdate(),e.invalidateDownstreamBooleanData(),e.dispatchEvent({type:"requestRender"})))},material(a,r,n){n&&(Object.entries(n).forEach(([a,{start:n,end:o,t:i}])=>{let s=r.getValue(a);e instanceof y&&!Array.isArray(e.material)&&"alpha"===a&&"number"==typeof s&&s>0&&(e.material.transparent=!0),void 0!==s&&se(a,r,n,o,i,t.shared)}),e.dispatchEvent({type:"requestRender"}))},opacity(a){if(e instanceof y&&!Array.isArray(e.material)){let r=e.material.getLayersOfType("light")[0];if(void 0===r)return;e.material.transparent=!0,se("alphaOverride",r,{alphaOverride:a},{alphaOverride:a+1},0,t.shared),e.dispatchEvent({type:"requestRender"})}},light(t,a){(e instanceof n||e instanceof r||e instanceof o)&&(e[t]=a,e.dispatchEvent({type:"requestRender"}))},cloner(e){e.cloner?.update(t),e instanceof g&&e.invalidateDownstreamBooleanData(),e.dispatchEvent({type:"requestRender"})},pathExtrusion(e,a){e.geometry.userData.parameters.extrusion={...e.geometry.userData.parameters.extrusion,...a},e.updateGeometryInteractions({extrusion:{...e.geometry.userData.parameters.extrusion}},t.shared),e.resetBBoxNeedsUpdate(),e.invalidateDownstreamBooleanData(),e.dispatchEvent({type:"requestRender"})},pathSnapping(t){e.userData.pathSnapping={...e.userData.pathSnapping,...t},e.updatePathSnapping(e.userData.pathSnapping),e.dispatchEvent({type:"requestRender"})}}}var fe={type:"beginState"};function ge(e){let t;if(5===e.easing){let{control1:a,control2:r}=e;t=`cubicBezier(\n\t\t\t${a[0]}, ${a[1]}, ${r[0]}, ${r[1]}\n\t\t)`}else if(6===e.easing){let{mass:a,stiffness:r,damping:n,velocity:o}=e;t=`spring( ${a}, ${r}, ${n}, ${o} )`}else{let a;switch(e.easing){case 0:default:a=E.linear;break;case 1:a=E.ease;break;case 2:a=E.easeIn;break;case 3:a=E.easeOut;break;case 4:a=E.easeInOut}let[r,n,o,i]=a;t=`cubicBezier( ${r}, ${n}, ${o}, ${i} )`}return{duration:Math.max(e.duration,1e-4),easing:t}}function me(e){let t={delay:0,loop:-1===e.repeat||e.repeat+1};if(0===e.repeat)t.direction="normal",t.rewind=!1;else switch(e.direction){case"pingpong":t.direction="alternate",t.rewind=!1;break;case"pingpong-rewind":t.direction="alternate",t.rewind=!0;break;default:t.direction="normal",t.rewind=!1}switch(t.delay=0,t.endDelay=0,t.startOnceDelay=0,t.pingPongDelayCorrection=0,t.pingPongEndDelayCorrection=0,e.delayDirection){case"start-once":t.startOnceDelay=e.delay;break;case"start":t.delay=e.delay;break;case"end":t.endDelay=e.delay;break;case"start-end":case void 0:t.delay=e.delay,t.endDelay=e.delay}return"alternate"===t.direction&&(t.delay/=2,t.endDelay/=2,"start"===e.delayDirection?(t.pingPongDelayCorrection=t.delay,"number"==typeof t.loop&&t.loop%2==0&&(t.pingPongEndDelayCorrection=t.delay)):"end"===e.delayDirection?"number"==typeof t.loop&&t.loop%2!=0&&(t.pingPongEndDelayCorrection=t.endDelay):"start-end"===e.delayDirection&&(t.pingPongDelayCorrection=t.delay,t.pingPongEndDelayCorrection=t.endDelay)),t}var ye={type:"completeState",isfromEntity:!1};function be(e,t){let a,r;if("string"==typeof t?(a=t,r=e.states?.[a]):null===t&&(a=null,r=e.data),void 0!==a&&void 0!==r)return{id:a,data:r}}var ve=class{constructor(e,t,a,r,n,o,i){if(this.object=e,this.data=r,this.sharedAssets=n,this.allowSlerp=o,this.page=i,this.targets={t:0},this.firstLoop=!0,this._changeBegan=!1,this._changeCompleted=!0,this.onChange=()=>{this.callback&&(this.callback.update(this.targets.t),this.object.requestRender()),0===this.targets.t||1===this.targets.t?this._changeCompleted||(this._changeCompleted=!0,this._changeBegan=!1,this.onChangeComplete()):(this._changeCompleted&&(this._changeCompleted=!1),this._changeBegan||(this._changeBegan=!0,this.onChangeBegin()))},this.onChangeBegin=()=>{this.object.reversibleToState=this.to.id;let e=this.targets.t>.5?this.from.id:this.to.id;this.object.prevState!==this.object.currentState&&(this.object.prevState=this.object.currentState),this.object.currentState=e,this.object.dispatchEvent({type:"beginState",state:e}),v(this.object)||this.object.traverseEntity(e=>{e!==this.object&&e instanceof u&&e.dispatchEvent(fe)})},this.onChangeComplete=()=>{this.firstLoop&&(this.onFirstLoop(),this.firstLoop=!1),this.object.reversibleToState=this.to.id;let e=this.targets.t<.5?this.from.id:this.to.id;this.object.prevState!==this.object.currentState&&(this.object.prevState=this.object.currentState),this.object.currentState=e,this.object.dispatchEvent({type:"completeState",state:e}),v(this.object)||this.object.traverseEntity(e=>{e!==this.object&&e instanceof u&&e.dispatchEvent(ye)})},this.onFirstLoop=()=>{this.useCurrentState&&(this.callback=ce(this.object,this.from.data,this.to.data,{scene:this.page.scene,shared:this.sharedAssets},this.allowSlerp))},void 0===t){let e=be(this.object,this.object.currentState===a?this.object.prevState:this.object.currentState);if(!e)throw new Error("Missing property");this.from=e}else{let e=be(this.object,t);if(!e)throw new Error("Missing property");this.from=e}if(void 0===a)throw new Error("Missing property");{let e=be(this.object,a);if(!e)throw new Error("Missing property");this.to=e}this.useCurrentState=void 0===t||void 0===a,this.params={targets:this.targets,t:1,autoplay:!1,...me(r),...ge(r),change:this.onChange},this.callback=ce(this.object,void 0===t?{}:this.from.data,void 0===a?{}:this.to.data,{scene:this.page.scene,shared:this.sharedAssets},this.allowSlerp)}get changeBegan(){return this._changeBegan}get changeCompleted(){return this._changeCompleted}};export{re as a,ne as b,de as c,pe as d,he as e,fe as f,ge as g,me as h,ye as i,be as j,ve as k};
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{d as s}from"./runtime-chunk-
|
|
1
|
+
import{d as s}from"./runtime-chunk-ZASM3KKC.js";import{a as t,b as i}from"./runtime-chunk-VNO2DW74.js";import{Fc as a,Tc as o,Te as e,We as h,Xc as r,ze as d}from"./runtime-chunk-VGN7YHB7.js";var n=class extends(t(e)){constructor(s,t=15,i=6710886){super(s,t,i),this.object=s,this.name=`PointLightHelper: ${s.uuid}`}raycast(s,t){i(this.object,n.geometryHelper,s,t)}},p=class extends(s(d,n)){constructor(s,t,i){super(),this.super_Entity(s,t),this.castShadow=!0,this.shadow.mapSize.width=1024,this.shadow.mapSize.height=1024,this.shadow.normalBias=1,this.layers.enable(3);let e=this.shadow.camera;e.fov=90,e.aspect=1,e.near=100,e.far=2500;let d=new a(-e.far+this.position.x,-e.far+this.position.y,-e.far+this.position.z),n=new a(e.far+this.position.x,e.far+this.position.y,e.far+this.position.z),p=new r(d,n),c=new h(p,new o(16755200));c.visible=!1,this.gizmos.shadowmap=c,this.update()}update(){if(this.shadow&&(this.shadow.camera.updateProjectionMatrix(),this.gizmos))for(let s in this.gizmos){let t=this.gizmos[s];if(t instanceof h){let s=this.shadow.camera,i=new a(-s.far+this.position.x,-s.far+this.position.y,-s.far+this.position.z),o=new a(s.far+this.position.x,s.far+this.position.y,s.far+this.position.z);t.box.set(i,o),t.updateMatrixWorld(!0)}}}updateMatrixWorld(s){super.updateMatrixWorld(s),this.objectHelper&&this.objectHelper.update()}updateState(s,t){this.updateState_Light(s,t),void 0!==s.distance&&(this.distance=s.distance),void 0!==s.decay&&(this.decay=s.decay),void 0!==s.shadowRadius&&(this.shadow.radius=s.shadowRadius),void 0!==s.shadowResolution&&(this.shadow.mapSize.set(s.shadowResolution,s.shadowResolution),this.shadow.map&&(this.shadow.map.dispose(),this.shadow.map=null))}};export{p as a};
|
|
Binary file
|
|
Binary file
|