diff --git a/dist/assets/Datenschutz-04c4c2c8.js b/dist/assets/Datenschutz-b2f9b6d6.js similarity index 73% rename from dist/assets/Datenschutz-04c4c2c8.js rename to dist/assets/Datenschutz-b2f9b6d6.js index 4e6c181..4b732cb 100644 --- a/dist/assets/Datenschutz-04c4c2c8.js +++ b/dist/assets/Datenschutz-b2f9b6d6.js @@ -1 +1 @@ -import{_ as e,o as t,c as n,a as s}from"./index-ba943ae9.js";const c={},_={class:"komponenten"},o=s("h1",null,"Hier werden Daten geschützt",-1),a=[o];function r(d,i){return t(),n("div",_,a)}const h=e(c,[["render",r]]);export{h as default}; +import{_ as e,o as t,c as n,a as s}from"./index-f8797872.js";const c={},_={class:"komponenten"},o=s("h1",null,"Hier werden Daten geschützt",-1),a=[o];function r(d,i){return t(),n("div",_,a)}const h=e(c,[["render",r]]);export{h as default}; diff --git a/dist/assets/Impressum-1f20f6a5.js b/dist/assets/Impressum-07c8cc21.js similarity index 73% rename from dist/assets/Impressum-1f20f6a5.js rename to dist/assets/Impressum-07c8cc21.js index 1a21241..a329d02 100644 --- a/dist/assets/Impressum-1f20f6a5.js +++ b/dist/assets/Impressum-07c8cc21.js @@ -1 +1 @@ -import{_ as e,o as s,c as t,a as _}from"./index-ba943ae9.js";const c={},o={class:"about"},n=_("h1",null,"Impressum ist richtig und wichtig",-1),r=[n];function a(i,u){return s(),t("div",o,r)}const m=e(c,[["render",a]]);export{m as default}; +import{_ as e,o as s,c as t,a as _}from"./index-f8797872.js";const c={},o={class:"about"},n=_("h1",null,"Impressum ist richtig und wichtig",-1),r=[n];function a(i,u){return s(),t("div",o,r)}const m=e(c,[["render",a]]);export{m as default}; diff --git a/dist/assets/index-ecef823d.css b/dist/assets/index-229e0940.css similarity index 89% rename from dist/assets/index-ecef823d.css rename to dist/assets/index-229e0940.css index 3c7ddcf..45207a9 100644 --- a/dist/assets/index-ecef823d.css +++ b/dist/assets/index-229e0940.css @@ -1 +1 @@ -:root{--vt-c-white: #ffffff;--vt-c-white-soft: #f8f8f8;--vt-c-white-mute: #f2f2f2;--vt-c-black: #181818;--vt-c-black-soft: #222222;--vt-c-black-mute: #282828;--vt-c-indigo: #2c3e50;--vt-c-divider-light-1: rgba(60, 60, 60, .29);--vt-c-divider-light-2: rgba(60, 60, 60, .12);--vt-c-divider-dark-1: rgba(84, 84, 84, .65);--vt-c-divider-dark-2: rgba(84, 84, 84, .48);--vt-c-text-light-1: var(--vt-c-indigo);--vt-c-text-light-2: rgba(60, 60, 60, .66);--vt-c-text-dark-1: var(--vt-c-white);--vt-c-text-dark-2: rgba(235, 235, 235, .64)}:root{--color-background: var(--vt-c-white);--color-background-soft: var(--vt-c-white-soft);--color-background-mute: var(--vt-c-white-mute);--color-border: var(--vt-c-divider-light-2);--color-border-hover: var(--vt-c-divider-light-1);--color-heading: var(--vt-c-text-light-1);--color-text: var(--vt-c-text-light-1);--section-gap: 160px;--color-highlight: #00916E;--color-analogous1: #00916e;--color-analogous2: #006b91;--color-complementary: #910023}@media (prefers-color-scheme: dark){:root{--color-background: var(--vt-c-black);--color-background-soft: var(--vt-c-black-soft);--color-background-mute: var(--vt-c-black-mute);--color-border: var(--vt-c-divider-dark-2);--color-border-hover: var(--vt-c-divider-dark-1);--color-heading: var(--vt-c-text-dark-1);--color-text: var(--vt-c-text-dark-2)}}*,*:before,*:after{box-sizing:border-box;margin:0;font-weight:400}body{min-height:100vh;color:var(--color-text);background:var(--color-background);transition:color .5s,background-color .5s;line-height:1.6;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif;font-size:15px;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}#app{max-width:1280px;margin:0 auto;padding:2rem;font-weight:400}h2{margin-bottom:.5rem}h1{color:var(--color-highlight)}button{margin:.5rem 0}a,.green{text-decoration:none;color:var(--color-highlight);transition:.4s}.button,button{cursor:pointer;font-size:.75rem;font-weight:700;text-transform:uppercase;display:inline-block;text-decoration:none;color:#000;background:var(--color-highlight);padding:.5em 1.25em;border-radius:.25rem}.button:hover,button:hover{background:var(--color-background-mute)}div[contenteditable=true],h2[contenteditable=true],p[contenteditable=true]{line-height:1.5;max-height:300px;overflow-y:auto;cursor:text}div[contenteditable=true]:empty:before,h2[contenteditable=true]:empty:before,p[contenteditable=true]:empty:before{content:"Hier Text eingeben";color:#ccc}@media (hover: hover){a:hover{background-color:#54545433}}.dark-mode-container{position:fixed;top:22px;right:0;z-index:2;display:inline-block;cursor:pointer}.dark-mode-toggle{background-color:var(--color-background);color:var(--color-heading);border:1px solid var(--color-border);padding:8px 16px;cursor:pointer;transition:background-color .3s,color .3s,border-color .3s}.iconButton:hover{background-color:var(--vt-c-white-mute);color:var(--vt-c-black-soft);border-color:var(--color-border-hover)}.iconButton{display:flex;align-items:center;justify-content:center;padding:4px;background-color:var(--color-background);color:var(--color-heading);border:1px solid var(--color-border);border-radius:50%;transition:background-color .3s,color .3s,border-color .3s}#colorPicker{width:32px;height:32px;margin:0;border:none;background:none}.iconBar{display:grid;grid-template-rows:auto;grid-row-gap:8px;width:fit-content;position:fixed;bottom:10%;right:5%;z-index:5}.overlay{height:100%;width:100%;position:fixed;z-index:1;left:0;top:0;background-color:#000;background-color:#000000e6;overflow:hidden;transition:.5s}.overlayContent{position:relative;top:25%;width:100%;text-align:center;margin-top:30px}.overlay a{padding:8px;text-decoration:none;font-size:36px;color:#818181;display:block;transition:.3s}.overlay a:hover,.overlay a:focus{color:#f1f1f1}@media screen and (max-height: 450px){.overlay a{font-size:20px}}.hamburger{z-index:2;display:inline-block;cursor:pointer}.bar1,.bar2,.bar3{width:35px;height:5px;background-color:var(--color-text);margin:6px 0;transition:.4s}.opened .bar1{transform:translateY(11px) rotate(-45deg)}.opened .bar2{opacity:0}.opened .bar3{transform:translateY(-11px) rotate(45deg)}.opened .bar1,.opened .bar3{background-color:#818181}a{scroll-behavior:smooth}.progressContainer{margin-top:8px;width:100%;height:8px;background:var(--color-background-mute);transition:background-color .3s}.progressBar{height:8px;background:var(--color-highlight);width:0%}.footer{margin-top:32px;padding:32px 0;display:flex;justify-content:center;gap:32px;a {font-size: large;}}header[data-v-1d3973aa]{line-height:1.5;max-height:100vh;position:sticky;top:0;background:var(--color-background);padding:8px;transition:background-color .5s,color .3s;z-index:10;flex-wrap:wrap}.logo[data-v-1d3973aa]{display:block;margin:0 auto 2rem}@media (min-width: 1024px){header[data-v-1d3973aa]{display:flex;place-items:center}.logo[data-v-1d3973aa]{margin:0}header .wrapper[data-v-1d3973aa]{display:flex;place-items:flex-start;flex-wrap:wrap}}@media (max-width: 1024px){header[data-v-1d3973aa]{display:flex;place-items:center}.logo[data-v-1d3973aa]{margin:0}header .wrapper[data-v-1d3973aa]{display:flex;place-items:flex-start;flex-wrap:wrap}}.navBar[data-v-1d3973aa]{width:100%;display:flex;justify-content:space-between;align-items:center}.break[data-v-1d3973aa]{flex-basis:100%;height:0}.column{display:flex;flex-wrap:wrap;padding:0 4px}.row{box-sizing:border-box;padding:0 4px;flex:25%;max-width:25%}.image-container{position:relative;margin-top:8px;width:100%;overflow:hidden}.image-container img{margin-top:8px;vertical-align:middle;width:100%}.imgOverlay{position:absolute;top:7px;left:0;width:100%;height:100%;background-color:#00000080;display:flex;justify-content:center;align-items:center;opacity:0;transition:opacity .3s ease}.image-container:hover .imgOverlay{opacity:1}.delete-icon{color:#fff;font-size:24px;cursor:pointer;position:absolute;top:5px;right:15px}.custom-file-upload{display:inline-block;padding:12px 20px;font-size:16px;color:#fff;background-color:var(--color-highlight);border-radius:5px;cursor:pointer;transition:background-color .3s ease;margin-top:16px}.custom-file-upload:hover{background-color:#0003}@media screen and (max-width: 800px){.row{flex:50%;max-width:50%}}@media screen and (max-width: 600px){.row{flex:100%;max-width:100%}}.contact-form{margin-top:40px}form{display:grid;grid-template-columns:50% 50%;grid-gap:8px;padding-right:8px;margin-bottom:20px}input.name,input.email,input{margin-bottom:16px}.nachricht,.datenschutz{grid-column:span 2}label{display:block;margin-bottom:5px}input[type=text],input[type=email],textarea{width:100%;padding:8px;font-size:16px;border:1px solid #ccc;border-radius:4px;box-sizing:border-box;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif}@media (max-width: 600px){form{display:block}.datenschutz{font-size:12px}}button{padding:10px 20px;font-size:16px;border:none;border-radius:4px;background-color:var( --color-highlight);cursor:pointer}button:disabled{background-color:#ccc;cursor:not-allowed}.tiltingCard{--perspective: 500px;--rotateX: 0;--rotateY: 0;--angle: 15deg;height:50vh;width:100%;position:relative;display:grid;place-content:center;text-align:center;box-shadow:0 0 8px gray;padding:2rem;background-image:url(/assets/wandern-ebaec989.jpg);background-size:cover;background-position:bottom center;transform:perspective(var(--perspective)) rotateX(var(--rotateX)) rotateY(var(--rotateY));transition:transform .35s ease}.mousePositionTracker{position:absolute;top:0;right:0;bottom:0;left:0}.mousePositionTracker>div{position:absolute;width:calc(100% / 3);height:calc(100% / 3);z-index:2}.tiltingCard:has(.mousePositionTracker>div:nth-child(1):hover){--rotateX: var(--angle);--rotateY: calc(var(--angle) * -1)}.tiltingCard:has(.mousePositionTracker>div:nth-child(2):hover){--rotateX: var(--angle)}.tiltingCard:has(.mousePositionTracker>div:nth-child(3):hover){--rotateX: var(--angle);--rotateY: var(--angle)}.tiltingCard:has(.mousePositionTracker>div:nth-child(4):hover){--rotateY: calc(var(--angle) * -1)}.tiltingCard:has(.mousePositionTracker>div:nth-child(6):hover){--rotateY: var(--angle)}.tiltingCard:has(.mousePositionTracker>div:nth-child(7):hover){--rotateX: calc(var(--angle) * -1);--rotateY: calc(var(--angle) * -1)}.tiltingCard:has(.mousePositionTracker>div:nth-child(8):hover){--rotateX: calc(var(--angle) * -1)}.tiltingCard:has(.mousePositionTracker>div:nth-child(9):hover){--rotateX: calc(var(--angle) * -1);--rotateY: var(--angle)}.mousePositionTracker>div:nth-of-type(3n-2){left:0}.mousePositionTracker>div:nth-of-type(3n-1){left:calc(100% / 3)}.mousePositionTracker>div:nth-of-type(3n){right:0}.mousePositionTracker>div:nth-child(n+1):nth-child(-n+3){top:0}.mousePositionTracker>div:nth-child(n+4):nth-child(-n+6){top:calc(100% / 3)}.mousePositionTracker>div:nth-child(n+7):nth-child(-n+9){bottom:0}.hero{display:grid;grid-template-columns:50% 50%;grid-gap:8px;margin:64px 8px 0;padding:16px 8px 0}.heroImg{width:100%;height:50vh;object-fit:cover;object-position:bottom center}.heroText{display:flex;flex-direction:column;justify-content:center}.heroText button{color:#fff;background-color:var(--color-highlight);max-width:13rem;transition:background-color .3s ease}.heroText button:hover{background-color:#0003}@media (max-width: 1024px){.hero{display:flex;flex-direction:column-reverse;margin:0}.heroImg{height:50vh}}.cardContainer{position:relative;display:flex;flex-wrap:wrap;padding:0 4px}#card1{background-image:url(/assets/baum-2026ca64.jpg)}#card2{background-image:url(/assets/mischpult-4b61b6fb.jpg)}#card3{background-image:url(/assets/lightroom-d20c534d.jpg)}#card4{background-image:url(/assets/pinsel-bf8bd085.jpg)}.card{flex:24%;max-width:25%;margin:4px;padding:clamp(1.5rem,20vh,10rem) 0 0;color:#fff;transition:transform ease .25s;overflow:hidden}.card:hover{transform:scale(1.05)}.cardBody{padding:1.5rem;background:linear-gradient(rgb(0 0 0 / 0),rgb(0 0 0 / .25) 15%,rgb(0 0 0 / 1))}.cardBody p{color:#fffc;margin-bottom:1.25em}@media (hover: hover),(prefers-reduced-motion: no-preference){.cardBody{transform:translateY(60%);transition:transform .5s ease}.card:hover .cardBody{transform:translateY(0);transition-delay:.5s}.cardBody>*:not(.cardTitle){opacity:0;transition:opacity 1.2s linear .4s}.card:hover .cardBody>*:not(.cardTitle){opacity:1}.cardTitle:after{content:"";position:absolute;left:-1.5rem;top:100%;height:3px;width:calc(100% + 1.5rem);background:var(--color-highlight);transform:scaleX(0);transition:transform .2s ease;transform-origin:left}.card:hover .cardTitle:after{transition:transform .5s ease;transform:scaleX(1)}}.cardTitle{position:relative;width:max-content}@media screen and (max-width: 1000px){.card{flex:46%;max-width:50%}}@media screen and (max-width: 600px){.card{flex:100%;max-width:100%}.cardBody{transform:translateY(60%);transition:transform .5s ease}.card .cardBody{transform:translateY(0);transition-delay:.5s}.cardBody>*:not(.cardTitle){opacity:0;transition:opacity 1.2s linear .4s}.card .cardBody>*:not(.cardTitle){opacity:1}.cardTitle:after{content:"";position:absolute;left:-1.5rem;top:100%;height:3px;width:calc(100% + 1.5rem);background:var(--color-highlight);transform:scaleX(0);transition:transform .2s ease;transform-origin:left}.card .cardTitle:after{transition:transform .5s ease;transform:scaleX(1)}}.slider{-webkit-appearance:none;width:100%;height:16px;border-radius:5px;background:var(--color-background-mute);outline:none;opacity:.7;-webkit-transition:.2s;transition:opacity .2s}.slider::-webkit-slider-thumb{-webkit-appearance:none;-moz-appearance:none;appearance:none;width:25px;height:25px;border-radius:50%;background:var(--color-highlight);cursor:pointer}.slider::-moz-range-thumb{width:25px;height:25px;border-radius:50%;background:var(--color-highlight);cursor:pointer}.skillContainer{width:100%;background-color:var(--color-background-mute)}.skill{display:flex;justify-content:space-between;text-align:right;padding:8px;margin-bottom:8px;color:var(--vt-c-white);background:linear-gradient(90deg,var(--color-analogous2) 0%,var(--color-highlight) 100%)}.skillAnlegen{display:none}.newSkill{display:block}.skillCreator{display:inline-block;cursor:pointer;margin-top:8px}.CreatorBar1,.CreatorBar2{width:35px;height:5px;background-color:var(--color-text);margin:6px 0;transition:.4s}.CreatorBar1{transform:translateY(11px) rotate(-90deg)}.create .CreatorBar1{transform:translateY(11px) rotate(0)}section{padding-top:80px;position:relative}.first-section{padding-top:0}.actions{display:block;position:absolute;top:64px;right:8px}.actions-inner{display:flex;gap:10px;padding:5px;border-radius:4px}.select-section{margin-right:-8px;margin-top:8px;font-size:12px;font-weight:700;border-radius:4px;border:none;cursor:pointer;color:#fff;background-color:var(--color-highlight);transition:background-color .3s ease;height:30px;display:inline-flex}.select-section:hover,.select-section:focus{background-color:#0003;outline:none}.add-section,.remove-button{color:#fff;border:none;border-radius:4px;cursor:pointer;width:30px;height:30px;background-color:var(--color-highlight);justify-content:center;align-items:center;transition:background-color .3s ease;display:inline-flex}.add-section{font-size:24px}.remove-button{font-size:18px}.add-section:hover,.remove-button:hover{background-color:#0003} +:root{--vt-c-white: #ffffff;--vt-c-white-soft: #f8f8f8;--vt-c-white-mute: #f2f2f2;--vt-c-black: #181818;--vt-c-black-soft: #222222;--vt-c-black-mute: #282828;--vt-c-indigo: #2c3e50;--vt-c-divider-light-1: rgba(60, 60, 60, .29);--vt-c-divider-light-2: rgba(60, 60, 60, .12);--vt-c-divider-dark-1: rgba(84, 84, 84, .65);--vt-c-divider-dark-2: rgba(84, 84, 84, .48);--vt-c-text-light-1: var(--vt-c-indigo);--vt-c-text-light-2: rgba(60, 60, 60, .66);--vt-c-text-dark-1: var(--vt-c-white);--vt-c-text-dark-2: rgba(235, 235, 235, .64)}:root{--color-background: var(--vt-c-white);--color-background-soft: var(--vt-c-white-soft);--color-background-mute: var(--vt-c-white-mute);--color-border: var(--vt-c-divider-light-2);--color-border-hover: var(--vt-c-divider-light-1);--color-heading: var(--vt-c-text-light-1);--color-text: var(--vt-c-text-light-1);--section-gap: 160px;--color-highlight: #00916E;--color-analogous1: #00916e;--color-analogous2: #006b91;--color-complementary: #910023}@media (prefers-color-scheme: dark){:root{--color-background: var(--vt-c-black);--color-background-soft: var(--vt-c-black-soft);--color-background-mute: var(--vt-c-black-mute);--color-border: var(--vt-c-divider-dark-2);--color-border-hover: var(--vt-c-divider-dark-1);--color-heading: var(--vt-c-text-dark-1);--color-text: var(--vt-c-text-dark-2)}}*,*:before,*:after{box-sizing:border-box;margin:0;font-weight:400}body{min-height:100vh;color:var(--color-text);background:var(--color-background);transition:color .5s,background-color .5s;line-height:1.6;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif;font-size:15px;text-rendering:optimizeLegibility;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}#app{max-width:1280px;margin:0 auto;padding:2rem;font-weight:400}h2{margin-bottom:.5rem}h1{color:var(--color-highlight)}button{margin:.5rem 0}a,.green{text-decoration:none;color:var(--color-highlight);transition:.4s}.button,button{cursor:pointer;font-size:.75rem;font-weight:700;text-transform:uppercase;display:inline-block;text-decoration:none;color:#000;background:var(--color-highlight);padding:.5em 1.25em;border-radius:.25rem}.button:hover,button:hover{background:var(--color-background-mute)}div[contenteditable=true],h2[contenteditable=true],p[contenteditable=true]{line-height:1.5;max-height:300px;overflow-y:auto;cursor:text}div[contenteditable=true]:empty:before,h2[contenteditable=true]:empty:before,p[contenteditable=true]:empty:before{content:"Hier Text eingeben";color:#ccc}@media (hover: hover){a:hover{background-color:#54545433}}.dark-mode-container{position:fixed;top:22px;right:0;z-index:2;display:inline-block;cursor:pointer}.dark-mode-toggle{background-color:var(--color-background);color:var(--color-heading);border:1px solid var(--color-border);padding:8px 16px;cursor:pointer;transition:background-color .3s,color .3s,border-color .3s}.iconButton:hover{background-color:var(--vt-c-white-mute);color:var(--vt-c-black-soft);border-color:var(--color-border-hover)}.iconButton{display:flex;align-items:center;justify-content:center;padding:4px;background-color:var(--color-background);color:var(--color-heading);border:1px solid var(--color-border);border-radius:50%;transition:background-color .3s,color .3s,border-color .3s}#colorPicker{width:32px;height:32px;margin:0;border:none;background:none}.iconBar{display:grid;grid-template-rows:auto;grid-row-gap:8px;width:fit-content;position:fixed;bottom:10%;right:5%;z-index:5}.overlay{height:100%;width:100%;position:fixed;z-index:1;left:0;top:0;background-color:#000;background-color:#000000e6;overflow:hidden;transition:.5s}.overlayContent{position:relative;top:25%;width:100%;text-align:center;margin-top:30px}.overlay a{padding:8px;text-decoration:none;font-size:36px;color:#818181;display:block;transition:.3s}.overlay a:hover,.overlay a:focus{color:#f1f1f1}@media screen and (max-height: 450px){.overlay a{font-size:20px}}.hamburger{z-index:2;display:inline-block;cursor:pointer}.bar1,.bar2,.bar3{width:35px;height:5px;background-color:var(--color-text);margin:6px 0;transition:.4s}.opened .bar1{transform:translateY(11px) rotate(-45deg)}.opened .bar2{opacity:0}.opened .bar3{transform:translateY(-11px) rotate(45deg)}.opened .bar1,.opened .bar3{background-color:#818181}a{scroll-behavior:smooth}.progressContainer{margin-top:8px;width:100%;height:8px;background:var(--color-background-mute);transition:background-color .3s}.progressBar{height:8px;background:var(--color-highlight);width:0%}.footer{margin-top:32px;padding:32px 0;display:flex;justify-content:center;gap:32px;a {font-size: large;}}header[data-v-1d3973aa]{line-height:1.5;max-height:100vh;position:sticky;top:0;background:var(--color-background);padding:8px;transition:background-color .5s,color .3s;z-index:10;flex-wrap:wrap}.logo[data-v-1d3973aa]{display:block;margin:0 auto 2rem}@media (min-width: 1024px){header[data-v-1d3973aa]{display:flex;place-items:center}.logo[data-v-1d3973aa]{margin:0}header .wrapper[data-v-1d3973aa]{display:flex;place-items:flex-start;flex-wrap:wrap}}@media (max-width: 1024px){header[data-v-1d3973aa]{display:flex;place-items:center}.logo[data-v-1d3973aa]{margin:0}header .wrapper[data-v-1d3973aa]{display:flex;place-items:flex-start;flex-wrap:wrap}}.navBar[data-v-1d3973aa]{width:100%;display:flex;justify-content:space-between;align-items:center}.break[data-v-1d3973aa]{flex-basis:100%;height:0}.column{display:flex;flex-wrap:wrap;padding:0 4px}.row{box-sizing:border-box;padding:0 4px;flex:25%;max-width:25%}.image-container{position:relative;margin-top:8px;width:100%;overflow:hidden}.image-container img{margin-top:8px;vertical-align:middle;width:100%}.imgOverlay{position:absolute;top:7px;left:0;width:100%;height:100%;background-color:#00000080;display:flex;justify-content:center;align-items:center;opacity:0;transition:opacity .3s ease}.image-container:hover .imgOverlay{opacity:1}.delete-icon{color:#fff;font-size:24px;cursor:pointer;position:absolute;top:5px;right:15px}.custom-file-upload{display:inline-block;padding:12px 20px;font-size:16px;color:#fff;background-color:var(--color-highlight);border-radius:5px;cursor:pointer;transition:background-color .3s ease;margin-top:16px}.custom-file-upload:hover{background-color:#0003}@media screen and (max-width: 800px){.row{flex:50%;max-width:50%}}@media screen and (max-width: 600px){.row{flex:100%;max-width:100%}}.contact-form{margin-top:40px}form{display:grid;grid-template-columns:50% 50%;grid-gap:8px;padding-right:8px;margin-bottom:20px}input.name,input.email,input{margin-bottom:16px}.nachricht,.datenschutz{grid-column:span 2}label{display:block;margin-bottom:5px}input[type=text],input[type=email],textarea{width:100%;padding:8px;font-size:16px;border:1px solid #ccc;border-radius:4px;box-sizing:border-box;font-family:Inter,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif}@media (max-width: 600px){form{display:block}.datenschutz{font-size:12px}}button{padding:10px 20px;font-size:16px;border:none;border-radius:4px;background-color:var( --color-highlight);cursor:pointer}button:disabled{background-color:#ccc;cursor:not-allowed}.tiltingCard{--perspective: 500px;--rotateX: 0;--rotateY: 0;--angle: 15deg;height:50vh;width:100%;position:relative;display:grid;place-content:center;text-align:center;box-shadow:0 0 8px gray;padding:2rem;background-image:url(/assets/wandern-ebaec989.jpg);background-size:cover;background-position:bottom center;transform:perspective(var(--perspective)) rotateX(var(--rotateX)) rotateY(var(--rotateY));transition:transform .35s ease}.mousePositionTracker{position:absolute;top:0;right:0;bottom:0;left:0}.mousePositionTracker>div{position:absolute;width:calc(100% / 3);height:calc(100% / 3);z-index:2}.tiltingCard:has(.mousePositionTracker>div:nth-child(1):hover){--rotateX: var(--angle);--rotateY: calc(var(--angle) * -1)}.tiltingCard:has(.mousePositionTracker>div:nth-child(2):hover){--rotateX: var(--angle)}.tiltingCard:has(.mousePositionTracker>div:nth-child(3):hover){--rotateX: var(--angle);--rotateY: var(--angle)}.tiltingCard:has(.mousePositionTracker>div:nth-child(4):hover){--rotateY: calc(var(--angle) * -1)}.tiltingCard:has(.mousePositionTracker>div:nth-child(6):hover){--rotateY: var(--angle)}.tiltingCard:has(.mousePositionTracker>div:nth-child(7):hover){--rotateX: calc(var(--angle) * -1);--rotateY: calc(var(--angle) * -1)}.tiltingCard:has(.mousePositionTracker>div:nth-child(8):hover){--rotateX: calc(var(--angle) * -1)}.tiltingCard:has(.mousePositionTracker>div:nth-child(9):hover){--rotateX: calc(var(--angle) * -1);--rotateY: var(--angle)}.mousePositionTracker>div:nth-of-type(3n-2){left:0}.mousePositionTracker>div:nth-of-type(3n-1){left:calc(100% / 3)}.mousePositionTracker>div:nth-of-type(3n){right:0}.mousePositionTracker>div:nth-child(n+1):nth-child(-n+3){top:0}.mousePositionTracker>div:nth-child(n+4):nth-child(-n+6){top:calc(100% / 3)}.mousePositionTracker>div:nth-child(n+7):nth-child(-n+9){bottom:0}.hero{display:grid;grid-template-columns:50% 50%;grid-gap:8px;margin:64px 8px 0;padding:16px 8px 0}.heroImg{width:100%;height:50vh;object-fit:cover;object-position:bottom center}.heroText{display:flex;flex-direction:column;justify-content:center}.heroText button{color:#fff;background-color:var(--color-highlight);max-width:13rem;transition:background-color .3s ease}.heroText button:hover{background-color:#0003}@media (max-width: 1024px){.hero{display:flex;flex-direction:column-reverse;margin:0}.heroImg{height:50vh}}.cardContainer{position:relative;display:flex;flex-wrap:wrap;padding:0 4px}#card1{background-image:url(/assets/baum-2026ca64.jpg)}#card2{background-image:url(/assets/mischpult-4b61b6fb.jpg)}#card3{background-image:url(/assets/lightroom-d20c534d.jpg)}#card4{background-image:url(/assets/pinsel-bf8bd085.jpg)}.card{flex:24%;max-width:25%;margin:4px;padding:clamp(1.5rem,20vh,10rem) 0 0;color:#fff;transition:transform ease .25s;overflow:hidden}.card:hover{transform:scale(1.05)}.cardBody{padding:1.5rem;background:linear-gradient(rgb(0 0 0 / 0),rgb(0 0 0 / .25) 15%,rgb(0 0 0 / 1))}.cardBody p{color:#fffc;margin-bottom:1.25em}@media (hover: hover),(prefers-reduced-motion: no-preference){.cardBody{transform:translateY(60%);transition:transform .5s ease}.card:hover .cardBody{transform:translateY(0);transition-delay:.5s}.cardBody>*:not(.cardTitle){opacity:0;transition:opacity 1.2s linear .4s}.card:hover .cardBody>*:not(.cardTitle){opacity:1}.cardTitle:after{content:"";position:absolute;left:-1.5rem;top:100%;height:3px;width:calc(100% + 1.5rem);background:var(--color-highlight);transform:scaleX(0);transition:transform .2s ease;transform-origin:left}.card:hover .cardTitle:after{transition:transform .5s ease;transform:scaleX(1)}}.cardTitle{position:relative;width:max-content}@media screen and (max-width: 1000px){.card{flex:46%;max-width:50%}}@media screen and (max-width: 600px){.card{flex:100%;max-width:100%}.cardBody{transform:translateY(60%);transition:transform .5s ease}.card .cardBody{transform:translateY(0);transition-delay:.5s}.cardBody>*:not(.cardTitle){opacity:0;transition:opacity 1.2s linear .4s}.card .cardBody>*:not(.cardTitle){opacity:1}.cardTitle:after{content:"";position:absolute;left:-1.5rem;top:100%;height:3px;width:calc(100% + 1.5rem);background:var(--color-highlight);transform:scaleX(0);transition:transform .2s ease;transform-origin:left}.card .cardTitle:after{transition:transform .5s ease;transform:scaleX(1)}}.slider{-webkit-appearance:none;width:100%;height:16px;border-radius:5px;background:var(--color-background-mute);outline:none;opacity:.7;-webkit-transition:.2s;transition:opacity .2s}.slider::-webkit-slider-thumb{-webkit-appearance:none;-moz-appearance:none;appearance:none;width:25px;height:25px;border-radius:50%;background:var(--color-highlight);cursor:pointer}.slider::-moz-range-thumb{width:25px;height:25px;border-radius:50%;background:var(--color-highlight);cursor:pointer}.skillContainer{width:100%;background-color:var(--color-background-mute)}.skill{display:flex;justify-content:space-between;text-align:right;padding:8px;margin-bottom:8px;color:var(--vt-c-white);background:linear-gradient(90deg,var(--color-analogous2) 0%,var(--color-highlight) 100%)}.skillAnlegen{display:none}.newSkill{display:block}.skillCreator{display:inline-block;cursor:pointer;margin-top:8px}.CreatorBar1,.CreatorBar2{width:35px;height:5px;background-color:var(--color-text);margin:6px 0;transition:.4s}.CreatorBar1{transform:translateY(11px) rotate(-90deg)}.create .CreatorBar1{transform:translateY(11px) rotate(0)}.object{height:280px}.arrow{position:absolute;top:50%;transform:translateY(-20%);font-size:60px;color:#000;cursor:pointer}.arrow:hover{font-size:80px;transform:translateY(-30%);color:#d3d3d3}.arrow-left{left:20px}.arrow-right{right:20px}.fileInput{padding:10px 15px;font-weight:700}.customFileInput{padding:10px 15px;font-size:16px;font-weight:700;color:#fff;background-color:var(--color-highlight);border:none;cursor:pointer;transition:background-color .3s ease}.customFileInput:hover{background-color:#0003}section{padding-top:80px;position:relative}.first-section{padding-top:0}.actions{display:block;position:absolute;top:64px;right:8px}.actions-inner{display:flex;gap:10px;padding:5px;border-radius:4px}.select-section{margin-right:-8px;margin-top:8px;font-size:12px;font-weight:700;border-radius:4px;border:none;cursor:pointer;color:#fff;background-color:var(--color-highlight);transition:background-color .3s ease;height:30px;display:inline-flex}.select-section:hover,.select-section:focus{background-color:#0003;outline:none}.add-section,.remove-button{color:#fff;border:none;border-radius:4px;cursor:pointer;width:30px;height:30px;background-color:var(--color-highlight);justify-content:center;align-items:center;transition:background-color .3s ease;display:inline-flex}.add-section{font-size:24px}.remove-button{font-size:18px}.add-section:hover,.remove-button:hover{background-color:#0003} diff --git a/dist/assets/index-ba943ae9.js b/dist/assets/index-f8797872.js similarity index 91% rename from dist/assets/index-ba943ae9.js rename to dist/assets/index-f8797872.js index d9a8c61..c9e0fea 100644 --- a/dist/assets/index-ba943ae9.js +++ b/dist/assets/index-f8797872.js @@ -1,20 +1,20 @@ -(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))n(r);new MutationObserver(r=>{for(const s of r)if(s.type==="childList")for(const o of s.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&n(o)}).observe(document,{childList:!0,subtree:!0});function t(r){const s={};return r.integrity&&(s.integrity=r.integrity),r.referrerPolicy&&(s.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?s.credentials="include":r.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function n(r){if(r.ep)return;r.ep=!0;const s=t(r);fetch(r.href,s)}})();function bc(i,e){const t=Object.create(null),n=i.split(",");for(let r=0;r!!t[r.toLowerCase()]:r=>!!t[r]}const f0={},yr=[],Nt=()=>{},md=()=>!1,gd=/^on[^a-z]/,rl=i=>gd.test(i),wc=i=>i.startsWith("onUpdate:"),j0=Object.assign,Mc=(i,e)=>{const t=i.indexOf(e);t>-1&&i.splice(t,1)},vd=Object.prototype.hasOwnProperty,Ye=(i,e)=>vd.call(i,e),Ee=Array.isArray,_r=i=>To(i)==="[object Map]",jr=i=>To(i)==="[object Set]",X9=i=>To(i)==="[object Date]",Ne=i=>typeof i=="function",T0=i=>typeof i=="string",Er=i=>typeof i=="symbol",l0=i=>i!==null&&typeof i=="object",Q3=i=>(l0(i)||Ne(i))&&Ne(i.then)&&Ne(i.catch),Z3=Object.prototype.toString,To=i=>Z3.call(i),xd=i=>To(i).slice(8,-1),K3=i=>To(i)==="[object Object]",Sc=i=>T0(i)&&i!=="NaN"&&i[0]!=="-"&&""+parseInt(i,10)===i,Aa=bc(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),sl=i=>{const e=Object.create(null);return t=>e[t]||(e[t]=i(t))},yd=/-(\w)/g,qt=sl(i=>i.replace(yd,(e,t)=>t?t.toUpperCase():"")),_d=/\B([A-Z])/g,Yr=sl(i=>i.replace(_d,"-$1").toLowerCase()),ol=sl(i=>i.charAt(0).toUpperCase()+i.slice(1)),Nl=sl(i=>i?`on${ol(i)}`:""),Ri=(i,e)=>!Object.is(i,e),Ea=(i,e)=>{for(let t=0;t{Object.defineProperty(i,e,{configurable:!0,enumerable:!1,value:t})},Oa=i=>{const e=parseFloat(i);return isNaN(e)?i:e};let j9;const F1=()=>j9||(j9=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Fi(i){if(Ee(i)){const e={};for(let t=0;t{if(t){const n=t.split(wd);n.length>1&&(e[n[0].trim()]=n[1].trim())}}),e}function qn(i){let e="";if(T0(i))e=i;else if(Ee(i))for(let t=0;tAo(t,e))}const pr=i=>T0(i)?i:i==null?"":Ee(i)||l0(i)&&(i.toString===Z3||!Ne(i.toString))?JSON.stringify(i,$3,2):String(i),$3=(i,e)=>e&&e.__v_isRef?$3(i,e.value):_r(e)?{[`Map(${e.size})`]:[...e.entries()].reduce((t,[n,r])=>(t[`${n} =>`]=r,t),{})}:jr(e)?{[`Set(${e.size})`]:[...e.values()]}:l0(e)&&!Ee(e)&&!K3(e)?String(e):e;let Lt;class eh{constructor(e=!1){this.detached=e,this._active=!0,this.effects=[],this.cleanups=[],this.parent=Lt,!e&&Lt&&(this.index=(Lt.scopes||(Lt.scopes=[])).push(this)-1)}get active(){return this._active}run(e){if(this._active){const t=Lt;try{return Lt=this,e()}finally{Lt=t}}}on(){Lt=this}off(){Lt=this.parent}stop(e){if(this._active){let t,n;for(t=0,n=this.effects.length;t{const e=new Set(i);return e.w=0,e.n=0,e},th=i=>(i.w&Qn)>0,nh=i=>(i.n&Qn)>0,Fd=({deps:i})=>{if(i.length)for(let e=0;e{const{deps:e}=i;if(e.length){let t=0;for(let n=0;n{(u==="length"||!Er(u)&&u>=l)&&a.push(c)})}else switch(t!==void 0&&a.push(o.get(t)),e){case"add":Ee(i)?Sc(t)&&a.push(o.get("length")):(a.push(o.get(Ei)),_r(i)&&a.push(o.get(D1)));break;case"delete":Ee(i)||(a.push(o.get(Ei)),_r(i)&&a.push(o.get(D1)));break;case"set":_r(i)&&a.push(o.get(Ei));break}if(a.length===1)a[0]&&N1(a[0]);else{const l=[];for(const c of a)c&&l.push(...c);N1(Ac(l))}}function N1(i,e){const t=Ee(i)?i:[...i];for(const n of t)n.computed&&q9(n);for(const n of t)n.computed||q9(n)}function q9(i,e){(i!==Ct||i.allowRecurse)&&(i.scheduler?i.scheduler():i.run())}function Dd(i,e){var t;return(t=Ua.get(i))==null?void 0:t.get(e)}const Nd=bc("__proto__,__v_isRef,__isVue"),sh=new Set(Object.getOwnPropertyNames(Symbol).filter(i=>i!=="arguments"&&i!=="caller").map(i=>Symbol[i]).filter(Er)),Q9=Od();function Od(){const i={};return["includes","indexOf","lastIndexOf"].forEach(e=>{i[e]=function(...t){const n=Ze(this);for(let s=0,o=this.length;s{i[e]=function(...t){qr();const n=Ze(this)[e].apply(this,t);return Qr(),n}}),i}function Ud(i){const e=Ze(this);return ct(e,"has",i),e.hasOwnProperty(i)}class oh{constructor(e=!1,t=!1){this._isReadonly=e,this._shallow=t}get(e,t,n){const r=this._isReadonly,s=this._shallow;if(t==="__v_isReactive")return!r;if(t==="__v_isReadonly")return r;if(t==="__v_isShallow")return s;if(t==="__v_raw"&&n===(r?s?Zd:uh:s?ch:lh).get(e))return e;const o=Ee(e);if(!r){if(o&&Ye(Q9,t))return Reflect.get(Q9,t,n);if(t==="hasOwnProperty")return Ud}const a=Reflect.get(e,t,n);return(Er(t)?sh.has(t):Nd(t))||(r||ct(e,"get",t),s)?a:F0(a)?o&&Sc(t)?a:a.value:l0(a)?r?fh(a):ll(a):a}}class ah extends oh{constructor(e=!1){super(!1,e)}set(e,t,n,r){let s=e[t];if(Lr(s)&&F0(s)&&!F0(n))return!1;if(!this._shallow&&(!za(n)&&!Lr(n)&&(s=Ze(s),n=Ze(n)),!Ee(e)&&F0(s)&&!F0(n)))return s.value=n,!0;const o=Ee(e)&&Sc(t)?Number(t)i,al=i=>Reflect.getPrototypeOf(i);function Oo(i,e,t=!1,n=!1){i=i.__v_raw;const r=Ze(i),s=Ze(e);t||(Ri(e,s)&&ct(r,"get",e),ct(r,"get",s));const{has:o}=al(r),a=n?Lc:t?Fc:Js;if(o.call(r,e))return a(i.get(e));if(o.call(r,s))return a(i.get(s));i!==r&&i.get(e)}function Uo(i,e=!1){const t=this.__v_raw,n=Ze(t),r=Ze(i);return e||(Ri(i,r)&&ct(n,"has",i),ct(n,"has",r)),i===r?t.has(i):t.has(i)||t.has(r)}function zo(i,e=!1){return i=i.__v_raw,!e&&ct(Ze(i),"iterate",Ei),Reflect.get(i,"size",i)}function Z9(i){i=Ze(i);const e=Ze(this);return al(e).has.call(e,i)||(e.add(i),dn(e,"add",i,i)),this}function K9(i,e){e=Ze(e);const t=Ze(this),{has:n,get:r}=al(t);let s=n.call(t,i);s||(i=Ze(i),s=n.call(t,i));const o=r.call(t,i);return t.set(i,e),s?Ri(e,o)&&dn(t,"set",i,e):dn(t,"add",i,e),this}function J9(i){const e=Ze(this),{has:t,get:n}=al(e);let r=t.call(e,i);r||(i=Ze(i),r=t.call(e,i)),n&&n.call(e,i);const s=e.delete(i);return r&&dn(e,"delete",i,void 0),s}function $9(){const i=Ze(this),e=i.size!==0,t=i.clear();return e&&dn(i,"clear",void 0,void 0),t}function Bo(i,e){return function(n,r){const s=this,o=s.__v_raw,a=Ze(o),l=e?Lc:i?Fc:Js;return!i&&ct(a,"iterate",Ei),o.forEach((c,u)=>n.call(r,l(c),l(u),s))}}function ko(i,e,t){return function(...n){const r=this.__v_raw,s=Ze(r),o=_r(s),a=i==="entries"||i===Symbol.iterator&&o,l=i==="keys"&&o,c=r[i](...n),u=t?Lc:e?Fc:Js;return!e&&ct(s,"iterate",l?D1:Ei),{next(){const{value:h,done:f}=c.next();return f?{value:h,done:f}:{value:a?[u(h[0]),u(h[1])]:u(h),done:f}},[Symbol.iterator](){return this}}}}function Mn(i){return function(...e){return i==="delete"?!1:this}}function Hd(){const i={get(s){return Oo(this,s)},get size(){return zo(this)},has:Uo,add:Z9,set:K9,delete:J9,clear:$9,forEach:Bo(!1,!1)},e={get(s){return Oo(this,s,!1,!0)},get size(){return zo(this)},has:Uo,add:Z9,set:K9,delete:J9,clear:$9,forEach:Bo(!1,!0)},t={get(s){return Oo(this,s,!0)},get size(){return zo(this,!0)},has(s){return Uo.call(this,s,!0)},add:Mn("add"),set:Mn("set"),delete:Mn("delete"),clear:Mn("clear"),forEach:Bo(!0,!1)},n={get(s){return Oo(this,s,!0,!0)},get size(){return zo(this,!0)},has(s){return Uo.call(this,s,!0)},add:Mn("add"),set:Mn("set"),delete:Mn("delete"),clear:Mn("clear"),forEach:Bo(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(s=>{i[s]=ko(s,!1,!1),t[s]=ko(s,!0,!1),e[s]=ko(s,!1,!0),n[s]=ko(s,!0,!0)}),[i,t,e,n]}const[Vd,Wd,Xd,jd]=Hd();function Pc(i,e){const t=e?i?jd:Xd:i?Wd:Vd;return(n,r,s)=>r==="__v_isReactive"?!i:r==="__v_isReadonly"?i:r==="__v_raw"?n:Reflect.get(Ye(t,r)&&r in n?t:n,r,s)}const Yd={get:Pc(!1,!1)},qd={get:Pc(!1,!0)},Qd={get:Pc(!0,!1)},lh=new WeakMap,ch=new WeakMap,uh=new WeakMap,Zd=new WeakMap;function Kd(i){switch(i){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function Jd(i){return i.__v_skip||!Object.isExtensible(i)?0:Kd(xd(i))}function ll(i){return Lr(i)?i:Cc(i,!1,Bd,Yd,lh)}function hh(i){return Cc(i,!1,Gd,qd,ch)}function fh(i){return Cc(i,!0,kd,Qd,uh)}function Cc(i,e,t,n,r){if(!l0(i)||i.__v_raw&&!(e&&i.__v_isReactive))return i;const s=r.get(i);if(s)return s;const o=Jd(i);if(o===0)return i;const a=new Proxy(i,o===2?n:t);return r.set(i,a),a}function br(i){return Lr(i)?br(i.__v_raw):!!(i&&i.__v_isReactive)}function Lr(i){return!!(i&&i.__v_isReadonly)}function za(i){return!!(i&&i.__v_isShallow)}function dh(i){return br(i)||Lr(i)}function Ze(i){const e=i&&i.__v_raw;return e?Ze(e):i}function Rc(i){return Na(i,"__v_skip",!0),i}const Js=i=>l0(i)?ll(i):i,Fc=i=>l0(i)?fh(i):i;function ph(i){kn&&Ct&&(i=Ze(i),rh(i.dep||(i.dep=Ac())))}function mh(i,e){i=Ze(i);const t=i.dep;t&&N1(t)}function F0(i){return!!(i&&i.__v_isRef===!0)}function P0(i){return gh(i,!1)}function $d(i){return gh(i,!0)}function gh(i,e){return F0(i)?i:new e8(i,e)}class e8{constructor(e,t){this.__v_isShallow=t,this.dep=void 0,this.__v_isRef=!0,this._rawValue=t?e:Ze(e),this._value=t?e:Js(e)}get value(){return ph(this),this._value}set value(e){const t=this.__v_isShallow||za(e)||Lr(e);e=t?e:Ze(e),Ri(e,this._rawValue)&&(this._rawValue=e,this._value=t?e:Js(e),mh(this))}}function Gn(i){return F0(i)?i.value:i}const t8={get:(i,e,t)=>Gn(Reflect.get(i,e,t)),set:(i,e,t,n)=>{const r=i[e];return F0(r)&&!F0(t)?(r.value=t,!0):Reflect.set(i,e,t,n)}};function vh(i){return br(i)?i:new Proxy(i,t8)}class n8{constructor(e,t,n){this._object=e,this._key=t,this._defaultValue=n,this.__v_isRef=!0}get value(){const e=this._object[this._key];return e===void 0?this._defaultValue:e}set value(e){this._object[this._key]=e}get dep(){return Dd(Ze(this._object),this._key)}}class i8{constructor(e){this._getter=e,this.__v_isRef=!0,this.__v_isReadonly=!0}get value(){return this._getter()}}function xh(i,e,t){return F0(i)?i:Ne(i)?new i8(i):l0(i)&&arguments.length>1?r8(i,e,t):P0(i)}function r8(i,e,t){const n=i[e];return F0(n)?n:new n8(i,e,t)}class s8{constructor(e,t,n,r){this._setter=t,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this._dirty=!0,this.effect=new Ec(e,()=>{this._dirty||(this._dirty=!0,mh(this))}),this.effect.computed=this,this.effect.active=this._cacheable=!r,this.__v_isReadonly=n}get value(){const e=Ze(this);return ph(e),(e._dirty||!e._cacheable)&&(e._dirty=!1,e._value=e.effect.run()),e._value}set value(e){this._setter(e)}}function o8(i,e,t=!1){let n,r;const s=Ne(i);return s?(n=i,r=Nt):(n=i.get,r=i.set),new s8(n,r,s||!r,t)}function Hn(i,e,t,n){let r;try{r=n?i(...n):i()}catch(s){cl(s,e,t)}return r}function Ot(i,e,t,n){if(Ne(i)){const s=Hn(i,e,t,n);return s&&Q3(s)&&s.catch(o=>{cl(o,e,t)}),s}const r=[];for(let s=0;s>>1,r=Z0[n],s=eo(r);sjt&&Z0.splice(e,1)}function u8(i){Ee(i)?wr.push(...i):(!hn||!hn.includes(i,i.allowRecurse?Mi+1:Mi))&&wr.push(i),bh()}function e2(i,e=$s?jt+1:0){for(;eeo(t)-eo(n)),Mi=0;Mii.id==null?1/0:i.id,h8=(i,e)=>{const t=eo(i)-eo(e);if(t===0){if(i.pre&&!e.pre)return-1;if(e.pre&&!i.pre)return 1}return t};function Mh(i){O1=!1,$s=!0,Z0.sort(h8);const e=Nt;try{for(jt=0;jtT0(d)?d.trim():d)),h&&(r=t.map(Oa))}let a,l=n[a=Nl(e)]||n[a=Nl(qt(e))];!l&&s&&(l=n[a=Nl(Yr(e))]),l&&Ot(l,i,6,r);const c=n[a+"Once"];if(c){if(!i.emitted)i.emitted={};else if(i.emitted[a])return;i.emitted[a]=!0,Ot(c,i,6,r)}}function Sh(i,e,t=!1){const n=e.emitsCache,r=n.get(i);if(r!==void 0)return r;const s=i.emits;let o={},a=!1;if(!Ne(i)){const l=c=>{const u=Sh(c,e,!0);u&&(a=!0,j0(o,u))};!t&&e.mixins.length&&e.mixins.forEach(l),i.extends&&l(i.extends),i.mixins&&i.mixins.forEach(l)}return!s&&!a?(l0(i)&&n.set(i,null),null):(Ee(s)?s.forEach(l=>o[l]=null):j0(o,s),l0(i)&&n.set(i,o),o)}function ul(i,e){return!i||!rl(e)?!1:(e=e.slice(2).replace(/Once$/,""),Ye(i,e[0].toLowerCase()+e.slice(1))||Ye(i,Yr(e))||Ye(i,e))}let dt=null,hl=null;function Ba(i){const e=dt;return dt=i,hl=i&&i.type.__scopeId||null,e}function d8(i){hl=i}function p8(){hl=null}function Mr(i,e=dt,t){if(!e||i._n)return i;const n=(...r)=>{n._d&&h2(-1);const s=Ba(e);let o;try{o=i(...r)}finally{Ba(s),n._d&&h2(1)}return o};return n._n=!0,n._c=!0,n._d=!0,n}function Ol(i){const{type:e,vnode:t,proxy:n,withProxy:r,props:s,propsOptions:[o],slots:a,attrs:l,emit:c,render:u,renderCache:h,data:f,setupState:d,ctx:g,inheritAttrs:v}=i;let _,m;const p=Ba(i);try{if(t.shapeFlag&4){const x=r||n;_=Wt(u.call(x,x,h,s,d,f,g)),m=l}else{const x=e;_=Wt(x.length>1?x(s,{attrs:l,slots:a,emit:c}):x(s,null)),m=e.props?l:m8(l)}}catch(x){ks.length=0,cl(x,i,1),_=je(Ii)}let y=_;if(m&&v!==!1){const x=Object.keys(m),{shapeFlag:w}=y;x.length&&w&7&&(o&&x.some(wc)&&(m=g8(m,o)),y=Pr(y,m))}return t.dirs&&(y=Pr(y),y.dirs=y.dirs?y.dirs.concat(t.dirs):t.dirs),t.transition&&(y.transition=t.transition),_=y,Ba(p),_}const m8=i=>{let e;for(const t in i)(t==="class"||t==="style"||rl(t))&&((e||(e={}))[t]=i[t]);return e},g8=(i,e)=>{const t={};for(const n in i)(!wc(n)||!(n.slice(9)in e))&&(t[n]=i[n]);return t};function v8(i,e,t){const{props:n,children:r,component:s}=i,{props:o,children:a,patchFlag:l}=e,c=s.emitsOptions;if(e.dirs||e.transition)return!0;if(t&&l>=0){if(l&1024)return!0;if(l&16)return n?t2(n,o,c):!!o;if(l&8){const u=e.dynamicProps;for(let h=0;hi.__isSuspense;function b8(i,e){e&&e.pendingBranch?Ee(i)?e.effects.push(...i):e.effects.push(i):u8(i)}function w8(i,e){return Oc(i,null,e)}const Go={};function Ke(i,e,t){return Oc(i,e,t)}function Oc(i,e,{immediate:t,deep:n,flush:r,onTrack:s,onTrigger:o}=f0){var a;const l=Rd()===((a=U0)==null?void 0:a.scope)?U0:null;let c,u=!1,h=!1;if(F0(i)?(c=()=>i.value,u=za(i)):br(i)?(c=()=>i,n=!0):Ee(i)?(h=!0,u=i.some(x=>br(x)||za(x)),c=()=>i.map(x=>{if(F0(x))return x.value;if(br(x))return Ti(x);if(Ne(x))return Hn(x,l,2)})):Ne(i)?e?c=()=>Hn(i,l,2):c=()=>{if(!(l&&l.isUnmounted))return f&&f(),Ot(i,l,3,[d])}:c=Nt,e&&n){const x=c;c=()=>Ti(x())}let f,d=x=>{f=p.onStop=()=>{Hn(x,l,4)}},g;if(io)if(d=Nt,e?t&&Ot(e,l,3,[c(),h?[]:void 0,d]):c(),r==="sync"){const x=m6();g=x.__watcherHandles||(x.__watcherHandles=[])}else return Nt;let v=h?new Array(i.length).fill(Go):Go;const _=()=>{if(p.active)if(e){const x=p.run();(n||u||(h?x.some((w,A)=>Ri(w,v[A])):Ri(x,v)))&&(f&&f(),Ot(e,l,3,[x,v===Go?void 0:h&&v[0]===Go?[]:v,d]),v=x)}else p.run()};_.allowRecurse=!!e;let m;r==="sync"?m=_:r==="post"?m=()=>ot(_,l&&l.suspense):(_.pre=!0,l&&(_.id=l.uid),m=()=>Dc(_));const p=new Ec(c,m);e?t?_():v=p.run():r==="post"?ot(p.run.bind(p),l&&l.suspense):p.run();const y=()=>{p.stop(),l&&l.scope&&Mc(l.scope.effects,p)};return g&&g.push(y),y}function M8(i,e,t){const n=this.proxy,r=T0(i)?i.includes(".")?Eh(n,i):()=>n[i]:i.bind(n,n);let s;Ne(e)?s=e:(s=e.handler,t=e);const o=U0;Cr(this);const a=Oc(r,s.bind(n),t);return o?Cr(o):Li(),a}function Eh(i,e){const t=e.split(".");return()=>{let n=i;for(let r=0;r{Ti(t,e)});else if(K3(i))for(const t in i)Ti(i[t],e);return i}function Bn(i,e){const t=dt;if(t===null)return i;const n=ml(t)||t.proxy,r=i.dirs||(i.dirs=[]);for(let s=0;sj0({name:i.name},e,{setup:i}))():i}const La=i=>!!i.type.__asyncLoader,Lh=i=>i.type.__isKeepAlive;function S8(i,e){Ph(i,"a",e)}function T8(i,e){Ph(i,"da",e)}function Ph(i,e,t=U0){const n=i.__wdc||(i.__wdc=()=>{let r=t;for(;r;){if(r.isDeactivated)return;r=r.parent}return i()});if(fl(e,n,t),t){let r=t.parent;for(;r&&r.parent;)Lh(r.parent.vnode)&&A8(n,e,t,r),r=r.parent}}function A8(i,e,t,n){const r=fl(e,i,n,!0);Uc(()=>{Mc(n[e],r)},t)}function fl(i,e,t=U0,n=!1){if(t){const r=t[i]||(t[i]=[]),s=e.__weh||(e.__weh=(...o)=>{if(t.isUnmounted)return;qr(),Cr(t);const a=Ot(e,t,i,o);return Li(),Qr(),a});return n?r.unshift(s):r.push(s),s}}const yn=i=>(e,t=U0)=>(!io||i==="sp")&&fl(i,(...n)=>e(...n),t),E8=yn("bm"),L8=yn("m"),P8=yn("bu"),C8=yn("u"),R8=yn("bum"),Uc=yn("um"),F8=yn("sp"),I8=yn("rtg"),D8=yn("rtc");function N8(i,e=U0){fl("ec",i,e)}function to(i,e,t,n){let r;const s=t&&t[n];if(Ee(i)||T0(i)){r=new Array(i.length);for(let o=0,a=i.length;oe(o,a,void 0,s&&s[a]));else{const o=Object.keys(i);r=new Array(o.length);for(let a=0,l=o.length;ai?Gh(i)?ml(i)||i.proxy:U1(i.parent):null,zs=j0(Object.create(null),{$:i=>i,$el:i=>i.vnode.el,$data:i=>i.data,$props:i=>i.props,$attrs:i=>i.attrs,$slots:i=>i.slots,$refs:i=>i.refs,$parent:i=>U1(i.parent),$root:i=>U1(i.root),$emit:i=>i.emit,$options:i=>zc(i),$forceUpdate:i=>i.f||(i.f=()=>Dc(i.update)),$nextTick:i=>i.n||(i.n=_h.bind(i.proxy)),$watch:i=>M8.bind(i)}),Ul=(i,e)=>i!==f0&&!i.__isScriptSetup&&Ye(i,e),O8={get({_:i},e){const{ctx:t,setupState:n,data:r,props:s,accessCache:o,type:a,appContext:l}=i;let c;if(e[0]!=="$"){const d=o[e];if(d!==void 0)switch(d){case 1:return n[e];case 2:return r[e];case 4:return t[e];case 3:return s[e]}else{if(Ul(n,e))return o[e]=1,n[e];if(r!==f0&&Ye(r,e))return o[e]=2,r[e];if((c=i.propsOptions[0])&&Ye(c,e))return o[e]=3,s[e];if(t!==f0&&Ye(t,e))return o[e]=4,t[e];z1&&(o[e]=0)}}const u=zs[e];let h,f;if(u)return e==="$attrs"&&ct(i,"get",e),u(i);if((h=a.__cssModules)&&(h=h[e]))return h;if(t!==f0&&Ye(t,e))return o[e]=4,t[e];if(f=l.config.globalProperties,Ye(f,e))return f[e]},set({_:i},e,t){const{data:n,setupState:r,ctx:s}=i;return Ul(r,e)?(r[e]=t,!0):n!==f0&&Ye(n,e)?(n[e]=t,!0):Ye(i.props,e)||e[0]==="$"&&e.slice(1)in i?!1:(s[e]=t,!0)},has({_:{data:i,setupState:e,accessCache:t,ctx:n,appContext:r,propsOptions:s}},o){let a;return!!t[o]||i!==f0&&Ye(i,o)||Ul(e,o)||(a=s[0])&&Ye(a,o)||Ye(n,o)||Ye(zs,o)||Ye(r.config.globalProperties,o)},defineProperty(i,e,t){return t.get!=null?i._.accessCache[e]=0:Ye(t,"value")&&this.set(i,e,t.value,null),Reflect.defineProperty(i,e,t)}};function i2(i){return Ee(i)?i.reduce((e,t)=>(e[t]=null,e),{}):i}let z1=!0;function U8(i){const e=zc(i),t=i.proxy,n=i.ctx;z1=!1,e.beforeCreate&&r2(e.beforeCreate,i,"bc");const{data:r,computed:s,methods:o,watch:a,provide:l,inject:c,created:u,beforeMount:h,mounted:f,beforeUpdate:d,updated:g,activated:v,deactivated:_,beforeDestroy:m,beforeUnmount:p,destroyed:y,unmounted:x,render:w,renderTracked:A,renderTriggered:b,errorCaptured:L,serverPrefetch:B,expose:I,inheritAttrs:C,components:Y,directives:O,filters:G}=e;if(c&&z8(c,n,null),o)for(const k in o){const Z=o[k];Ne(Z)&&(n[k]=Z.bind(t))}if(r){const k=r.call(t,t);l0(k)&&(i.data=ll(k))}if(z1=!0,s)for(const k in s){const Z=s[k],le=Ne(Z)?Z.bind(t,t):Ne(Z.get)?Z.get.bind(t,t):Nt,ve=!Ne(Z)&&Ne(Z.set)?Z.set.bind(t):Nt,ce=Rt({get:le,set:ve});Object.defineProperty(n,k,{enumerable:!0,configurable:!0,get:()=>ce.value,set:ye=>ce.value=ye})}if(a)for(const k in a)Ch(a[k],n,t,k);if(l){const k=Ne(l)?l.call(t):l;Reflect.ownKeys(k).forEach(Z=>{Bs(Z,k[Z])})}u&&r2(u,i,"c");function N(k,Z){Ee(Z)?Z.forEach(le=>k(le.bind(t))):Z&&k(Z.bind(t))}if(N(E8,h),N(L8,f),N(P8,d),N(C8,g),N(S8,v),N(T8,_),N(N8,L),N(D8,A),N(I8,b),N(R8,p),N(Uc,x),N(F8,B),Ee(I))if(I.length){const k=i.exposed||(i.exposed={});I.forEach(Z=>{Object.defineProperty(k,Z,{get:()=>t[Z],set:le=>t[Z]=le})})}else i.exposed||(i.exposed={});w&&i.render===Nt&&(i.render=w),C!=null&&(i.inheritAttrs=C),Y&&(i.components=Y),O&&(i.directives=O)}function z8(i,e,t=Nt){Ee(i)&&(i=B1(i));for(const n in i){const r=i[n];let s;l0(r)?"default"in r?s=nt(r.from||n,r.default,!0):s=nt(r.from||n):s=nt(r),F0(s)?Object.defineProperty(e,n,{enumerable:!0,configurable:!0,get:()=>s.value,set:o=>s.value=o}):e[n]=s}}function r2(i,e,t){Ot(Ee(i)?i.map(n=>n.bind(e.proxy)):i.bind(e.proxy),e,t)}function Ch(i,e,t,n){const r=n.includes(".")?Eh(t,n):()=>t[n];if(T0(i)){const s=e[i];Ne(s)&&Ke(r,s)}else if(Ne(i))Ke(r,i.bind(t));else if(l0(i))if(Ee(i))i.forEach(s=>Ch(s,e,t,n));else{const s=Ne(i.handler)?i.handler.bind(t):e[i.handler];Ne(s)&&Ke(r,s,i)}}function zc(i){const e=i.type,{mixins:t,extends:n}=e,{mixins:r,optionsCache:s,config:{optionMergeStrategies:o}}=i.appContext,a=s.get(e);let l;return a?l=a:!r.length&&!t&&!n?l=e:(l={},r.length&&r.forEach(c=>ka(l,c,o,!0)),ka(l,e,o)),l0(e)&&s.set(e,l),l}function ka(i,e,t,n=!1){const{mixins:r,extends:s}=e;s&&ka(i,s,t,!0),r&&r.forEach(o=>ka(i,o,t,!0));for(const o in e)if(!(n&&o==="expose")){const a=B8[o]||t&&t[o];i[o]=a?a(i[o],e[o]):e[o]}return i}const B8={data:s2,props:o2,emits:o2,methods:Ns,computed:Ns,beforeCreate:et,created:et,beforeMount:et,mounted:et,beforeUpdate:et,updated:et,beforeDestroy:et,beforeUnmount:et,destroyed:et,unmounted:et,activated:et,deactivated:et,errorCaptured:et,serverPrefetch:et,components:Ns,directives:Ns,watch:G8,provide:s2,inject:k8};function s2(i,e){return e?i?function(){return j0(Ne(i)?i.call(this,this):i,Ne(e)?e.call(this,this):e)}:e:i}function k8(i,e){return Ns(B1(i),B1(e))}function B1(i){if(Ee(i)){const e={};for(let t=0;t1)return t&&Ne(e)?e.call(n&&n.proxy):e}}function W8(i,e,t,n=!1){const r={},s={};Na(s,pl,1),i.propsDefaults=Object.create(null),Fh(i,e,r,s);for(const o in i.propsOptions[0])o in r||(r[o]=void 0);t?i.props=n?r:hh(r):i.type.props?i.props=r:i.props=s,i.attrs=s}function X8(i,e,t,n){const{props:r,attrs:s,vnode:{patchFlag:o}}=i,a=Ze(r),[l]=i.propsOptions;let c=!1;if((n||o>0)&&!(o&16)){if(o&8){const u=i.vnode.dynamicProps;for(let h=0;h{l=!0;const[f,d]=Ih(h,e,!0);j0(o,f),d&&a.push(...d)};!t&&e.mixins.length&&e.mixins.forEach(u),i.extends&&u(i.extends),i.mixins&&i.mixins.forEach(u)}if(!s&&!l)return l0(i)&&n.set(i,yr),yr;if(Ee(s))for(let u=0;u-1,d[1]=v<0||g-1||Ye(d,"default"))&&a.push(h)}}}const c=[o,a];return l0(i)&&n.set(i,c),c}function a2(i){return i[0]!=="$"}function l2(i){const e=i&&i.toString().match(/^\s*(function|class) (\w+)/);return e?e[2]:i===null?"null":""}function c2(i,e){return l2(i)===l2(e)}function u2(i,e){return Ee(e)?e.findIndex(t=>c2(t,i)):Ne(e)&&c2(e,i)?0:-1}const Dh=i=>i[0]==="_"||i==="$stable",Bc=i=>Ee(i)?i.map(Wt):[Wt(i)],j8=(i,e,t)=>{if(e._n)return e;const n=Mr((...r)=>Bc(e(...r)),t);return n._c=!1,n},Nh=(i,e,t)=>{const n=i._ctx;for(const r in i){if(Dh(r))continue;const s=i[r];if(Ne(s))e[r]=j8(r,s,n);else if(s!=null){const o=Bc(s);e[r]=()=>o}}},Oh=(i,e)=>{const t=Bc(e);i.slots.default=()=>t},Y8=(i,e)=>{if(i.vnode.shapeFlag&32){const t=e._;t?(i.slots=Ze(e),Na(e,"_",t)):Nh(e,i.slots={})}else i.slots={},e&&Oh(i,e);Na(i.slots,pl,1)},q8=(i,e,t)=>{const{vnode:n,slots:r}=i;let s=!0,o=f0;if(n.shapeFlag&32){const a=e._;a?t&&a===1?s=!1:(j0(r,e),!t&&a===1&&delete r._):(s=!e.$stable,Nh(e,r)),o=e}else e&&(Oh(i,e),o={default:1});if(s)for(const a in r)!Dh(a)&&o[a]==null&&delete r[a]};function G1(i,e,t,n,r=!1){if(Ee(i)){i.forEach((f,d)=>G1(f,e&&(Ee(e)?e[d]:e),t,n,r));return}if(La(n)&&!r)return;const s=n.shapeFlag&4?ml(n.component)||n.component.proxy:n.el,o=r?null:s,{i:a,r:l}=i,c=e&&e.r,u=a.refs===f0?a.refs={}:a.refs,h=a.setupState;if(c!=null&&c!==l&&(T0(c)?(u[c]=null,Ye(h,c)&&(h[c]=null)):F0(c)&&(c.value=null)),Ne(l))Hn(l,a,12,[o,u]);else{const f=T0(l),d=F0(l);if(f||d){const g=()=>{if(i.f){const v=f?Ye(h,l)?h[l]:u[l]:l.value;r?Ee(v)&&Mc(v,s):Ee(v)?v.includes(s)||v.push(s):f?(u[l]=[s],Ye(h,l)&&(h[l]=u[l])):(l.value=[s],i.k&&(u[i.k]=l.value))}else f?(u[l]=o,Ye(h,l)&&(h[l]=o)):d&&(l.value=o,i.k&&(u[i.k]=o))};o?(g.id=-1,ot(g,t)):g()}}}const ot=b8;function Q8(i){return Z8(i)}function Z8(i,e){const t=F1();t.__VUE__=!0;const{insert:n,remove:r,patchProp:s,createElement:o,createText:a,createComment:l,setText:c,setElementText:u,parentNode:h,nextSibling:f,setScopeId:d=Nt,insertStaticContent:g}=i,v=(M,E,F,W=null,X=null,T=null,S=!1,U=null,q=!!E.dynamicChildren)=>{if(M===E)return;M&&!vs(M,E)&&(W=V(M),ye(M,X,T,!0),M=null),E.patchFlag===-2&&(q=!1,E.dynamicChildren=null);const{type:H,ref:oe,shapeFlag:ue}=E;switch(H){case dl:_(M,E,F,W);break;case Ii:m(M,E,F,W);break;case Pa:M==null&&p(E,F,W,S);break;case W0:Y(M,E,F,W,X,T,S,U,q);break;default:ue&1?w(M,E,F,W,X,T,S,U,q):ue&6?O(M,E,F,W,X,T,S,U,q):(ue&64||ue&128)&&H.process(M,E,F,W,X,T,S,U,q,Q)}oe!=null&&X&&G1(oe,M&&M.ref,T,E||M,!E)},_=(M,E,F,W)=>{if(M==null)n(E.el=a(E.children),F,W);else{const X=E.el=M.el;E.children!==M.children&&c(X,E.children)}},m=(M,E,F,W)=>{M==null?n(E.el=l(E.children||""),F,W):E.el=M.el},p=(M,E,F,W)=>{[M.el,M.anchor]=g(M.children,E,F,W,M.el,M.anchor)},y=({el:M,anchor:E},F,W)=>{let X;for(;M&&M!==E;)X=f(M),n(M,F,W),M=X;n(E,F,W)},x=({el:M,anchor:E})=>{let F;for(;M&&M!==E;)F=f(M),r(M),M=F;r(E)},w=(M,E,F,W,X,T,S,U,q)=>{S=S||E.type==="svg",M==null?A(E,F,W,X,T,S,U,q):B(M,E,X,T,S,U,q)},A=(M,E,F,W,X,T,S,U)=>{let q,H;const{type:oe,props:ue,shapeFlag:he,transition:xe,dirs:ge}=M;if(q=M.el=o(M.type,T,ue&&ue.is,ue),he&8?u(q,M.children):he&16&&L(M.children,q,null,W,X,T&&oe!=="foreignObject",S,U),ge&&pi(M,null,W,"created"),b(q,M,M.scopeId,S,W),ue){for(const fe in ue)fe!=="value"&&!Aa(fe)&&s(q,fe,null,ue[fe],T,M.children,W,X,K);"value"in ue&&s(q,"value",null,ue.value),(H=ue.onVnodeBeforeMount)&&Gt(H,W,M)}ge&&pi(M,null,W,"beforeMount");const z=K8(X,xe);z&&xe.beforeEnter(q),n(q,E,F),((H=ue&&ue.onVnodeMounted)||z||ge)&&ot(()=>{H&&Gt(H,W,M),z&&xe.enter(q),ge&&pi(M,null,W,"mounted")},X)},b=(M,E,F,W,X)=>{if(F&&d(M,F),W)for(let T=0;T{for(let H=q;H{const U=E.el=M.el;let{patchFlag:q,dynamicChildren:H,dirs:oe}=E;q|=M.patchFlag&16;const ue=M.props||f0,he=E.props||f0;let xe;F&&mi(F,!1),(xe=he.onVnodeBeforeUpdate)&&Gt(xe,F,E,M),oe&&pi(E,M,F,"beforeUpdate"),F&&mi(F,!0);const ge=X&&E.type!=="foreignObject";if(H?I(M.dynamicChildren,H,U,F,W,ge,T):S||Z(M,E,U,null,F,W,ge,T,!1),q>0){if(q&16)C(U,E,ue,he,F,W,X);else if(q&2&&ue.class!==he.class&&s(U,"class",null,he.class,X),q&4&&s(U,"style",ue.style,he.style,X),q&8){const z=E.dynamicProps;for(let fe=0;fe{xe&&Gt(xe,F,E,M),oe&&pi(E,M,F,"updated")},W)},I=(M,E,F,W,X,T,S)=>{for(let U=0;U{if(F!==W){if(F!==f0)for(const U in F)!Aa(U)&&!(U in W)&&s(M,U,F[U],null,S,E.children,X,T,K);for(const U in W){if(Aa(U))continue;const q=W[U],H=F[U];q!==H&&U!=="value"&&s(M,U,H,q,S,E.children,X,T,K)}"value"in W&&s(M,"value",F.value,W.value)}},Y=(M,E,F,W,X,T,S,U,q)=>{const H=E.el=M?M.el:a(""),oe=E.anchor=M?M.anchor:a("");let{patchFlag:ue,dynamicChildren:he,slotScopeIds:xe}=E;xe&&(U=U?U.concat(xe):xe),M==null?(n(H,F,W),n(oe,F,W),L(E.children,F,oe,X,T,S,U,q)):ue>0&&ue&64&&he&&M.dynamicChildren?(I(M.dynamicChildren,he,F,X,T,S,U),(E.key!=null||X&&E===X.subTree)&&Uh(M,E,!0)):Z(M,E,F,oe,X,T,S,U,q)},O=(M,E,F,W,X,T,S,U,q)=>{E.slotScopeIds=U,M==null?E.shapeFlag&512?X.ctx.activate(E,F,W,S,q):G(E,F,W,X,T,S,q):j(M,E,q)},G=(M,E,F,W,X,T,S)=>{const U=M.component=o6(M,W,X);if(Lh(M)&&(U.ctx.renderer=Q),l6(U),U.asyncDep){if(X&&X.registerDep(U,N),!M.el){const q=U.subTree=je(Ii);m(null,q,E,F)}return}N(U,M,E,F,X,T,S)},j=(M,E,F)=>{const W=E.component=M.component;if(v8(M,E,F))if(W.asyncDep&&!W.asyncResolved){k(W,E,F);return}else W.next=E,c8(W.update),W.update();else E.el=M.el,W.vnode=E},N=(M,E,F,W,X,T,S)=>{const U=()=>{if(M.isMounted){let{next:oe,bu:ue,u:he,parent:xe,vnode:ge}=M,z=oe,fe;mi(M,!1),oe?(oe.el=ge.el,k(M,oe,S)):oe=ge,ue&&Ea(ue),(fe=oe.props&&oe.props.onVnodeBeforeUpdate)&&Gt(fe,xe,oe,ge),mi(M,!0);const ne=Ol(M),Te=M.subTree;M.subTree=ne,v(Te,ne,h(Te.el),V(Te),M,X,T),oe.el=ne.el,z===null&&x8(M,ne.el),he&&ot(he,X),(fe=oe.props&&oe.props.onVnodeUpdated)&&ot(()=>Gt(fe,xe,oe,ge),X)}else{let oe;const{el:ue,props:he}=E,{bm:xe,m:ge,parent:z}=M,fe=La(E);if(mi(M,!1),xe&&Ea(xe),!fe&&(oe=he&&he.onVnodeBeforeMount)&&Gt(oe,z,E),mi(M,!0),ue&&we){const ne=()=>{M.subTree=Ol(M),we(ue,M.subTree,M,X,null)};fe?E.type.__asyncLoader().then(()=>!M.isUnmounted&&ne()):ne()}else{const ne=M.subTree=Ol(M);v(null,ne,F,W,M,X,T),E.el=ne.el}if(ge&&ot(ge,X),!fe&&(oe=he&&he.onVnodeMounted)){const ne=E;ot(()=>Gt(oe,z,ne),X)}(E.shapeFlag&256||z&&La(z.vnode)&&z.vnode.shapeFlag&256)&&M.a&&ot(M.a,X),M.isMounted=!0,E=F=W=null}},q=M.effect=new Ec(U,()=>Dc(H),M.scope),H=M.update=()=>q.run();H.id=M.uid,mi(M,!0),H()},k=(M,E,F)=>{E.component=M;const W=M.vnode.props;M.vnode=E,M.next=null,X8(M,E.props,W,F),q8(M,E.children,F),qr(),e2(),Qr()},Z=(M,E,F,W,X,T,S,U,q=!1)=>{const H=M&&M.children,oe=M?M.shapeFlag:0,ue=E.children,{patchFlag:he,shapeFlag:xe}=E;if(he>0){if(he&128){ve(H,ue,F,W,X,T,S,U,q);return}else if(he&256){le(H,ue,F,W,X,T,S,U,q);return}}xe&8?(oe&16&&K(H,X,T),ue!==H&&u(F,ue)):oe&16?xe&16?ve(H,ue,F,W,X,T,S,U,q):K(H,X,T,!0):(oe&8&&u(F,""),xe&16&&L(ue,F,W,X,T,S,U,q))},le=(M,E,F,W,X,T,S,U,q)=>{M=M||yr,E=E||yr;const H=M.length,oe=E.length,ue=Math.min(H,oe);let he;for(he=0;heoe?K(M,X,T,!0,!1,ue):L(E,F,W,X,T,S,U,q,ue)},ve=(M,E,F,W,X,T,S,U,q)=>{let H=0;const oe=E.length;let ue=M.length-1,he=oe-1;for(;H<=ue&&H<=he;){const xe=M[H],ge=E[H]=q?Nn(E[H]):Wt(E[H]);if(vs(xe,ge))v(xe,ge,F,null,X,T,S,U,q);else break;H++}for(;H<=ue&&H<=he;){const xe=M[ue],ge=E[he]=q?Nn(E[he]):Wt(E[he]);if(vs(xe,ge))v(xe,ge,F,null,X,T,S,U,q);else break;ue--,he--}if(H>ue){if(H<=he){const xe=he+1,ge=xehe)for(;H<=ue;)ye(M[H],X,T,!0),H++;else{const xe=H,ge=H,z=new Map;for(H=ge;H<=he;H++){const ke=E[H]=q?Nn(E[H]):Wt(E[H]);ke.key!=null&&z.set(ke.key,H)}let fe,ne=0;const Te=he-ge+1;let D=!1,_e=0;const Ie=new Array(Te);for(H=0;H=Te){ye(ke,X,T,!0);continue}let Oe;if(ke.key!=null)Oe=z.get(ke.key);else for(fe=ge;fe<=he;fe++)if(Ie[fe-ge]===0&&vs(ke,E[fe])){Oe=fe;break}Oe===void 0?ye(ke,X,T,!0):(Ie[Oe-ge]=H+1,Oe>=_e?_e=Oe:D=!0,v(ke,E[Oe],F,null,X,T,S,U,q),ne++)}const Ue=D?J8(Ie):yr;for(fe=Ue.length-1,H=Te-1;H>=0;H--){const ke=ge+H,Oe=E[ke],g0=ke+1{const{el:T,type:S,transition:U,children:q,shapeFlag:H}=M;if(H&6){ce(M.component.subTree,E,F,W);return}if(H&128){M.suspense.move(E,F,W);return}if(H&64){S.move(M,E,F,Q);return}if(S===W0){n(T,E,F);for(let ue=0;ueU.enter(T),X);else{const{leave:ue,delayLeave:he,afterLeave:xe}=U,ge=()=>n(T,E,F),z=()=>{ue(T,()=>{ge(),xe&&xe()})};he?he(T,ge,z):z()}else n(T,E,F)},ye=(M,E,F,W=!1,X=!1)=>{const{type:T,props:S,ref:U,children:q,dynamicChildren:H,shapeFlag:oe,patchFlag:ue,dirs:he}=M;if(U!=null&&G1(U,null,F,M,!0),oe&256){E.ctx.deactivate(M);return}const xe=oe&1&&he,ge=!La(M);let z;if(ge&&(z=S&&S.onVnodeBeforeUnmount)&&Gt(z,E,M),oe&6)pe(M.component,F,W);else{if(oe&128){M.suspense.unmount(F,W);return}xe&&pi(M,null,E,"beforeUnmount"),oe&64?M.type.remove(M,E,F,X,Q,W):H&&(T!==W0||ue>0&&ue&64)?K(H,E,F,!1,!0):(T===W0&&ue&384||!X&&oe&16)&&K(q,E,F),W&&$(M)}(ge&&(z=S&&S.onVnodeUnmounted)||xe)&&ot(()=>{z&&Gt(z,E,M),xe&&pi(M,null,E,"unmounted")},F)},$=M=>{const{type:E,el:F,anchor:W,transition:X}=M;if(E===W0){se(F,W);return}if(E===Pa){x(M);return}const T=()=>{r(F),X&&!X.persisted&&X.afterLeave&&X.afterLeave()};if(M.shapeFlag&1&&X&&!X.persisted){const{leave:S,delayLeave:U}=X,q=()=>S(F,T);U?U(M.el,T,q):q()}else T()},se=(M,E)=>{let F;for(;M!==E;)F=f(M),r(M),M=F;r(E)},pe=(M,E,F)=>{const{bum:W,scope:X,update:T,subTree:S,um:U}=M;W&&Ea(W),X.stop(),T&&(T.active=!1,ye(S,M,E,F)),U&&ot(U,E),ot(()=>{M.isUnmounted=!0},E),E&&E.pendingBranch&&!E.isUnmounted&&M.asyncDep&&!M.asyncResolved&&M.suspenseId===E.pendingId&&(E.deps--,E.deps===0&&E.resolve())},K=(M,E,F,W=!1,X=!1,T=0)=>{for(let S=T;SM.shapeFlag&6?V(M.component.subTree):M.shapeFlag&128?M.suspense.next():f(M.anchor||M.el),te=(M,E,F)=>{M==null?E._vnode&&ye(E._vnode,null,null,!0):v(E._vnode||null,M,E,null,null,null,F),e2(),wh(),E._vnode=M},Q={p:v,um:ye,m:ce,r:$,mt:G,mc:L,pc:Z,pbc:I,n:V,o:i};let re,we;return e&&([re,we]=e(Q)),{render:te,hydrate:re,createApp:V8(te,re)}}function mi({effect:i,update:e},t){i.allowRecurse=e.allowRecurse=t}function K8(i,e){return(!i||i&&!i.pendingBranch)&&e&&!e.persisted}function Uh(i,e,t=!1){const n=i.children,r=e.children;if(Ee(n)&&Ee(r))for(let s=0;s>1,i[t[a]]0&&(e[n]=t[s-1]),t[s]=n)}}for(s=t.length,o=t[s-1];s-- >0;)t[s]=o,o=e[o];return t}const $8=i=>i.__isTeleport,W0=Symbol.for("v-fgt"),dl=Symbol.for("v-txt"),Ii=Symbol.for("v-cmt"),Pa=Symbol.for("v-stc"),ks=[];let Ft=null;function We(i=!1){ks.push(Ft=i?null:[])}function e6(){ks.pop(),Ft=ks[ks.length-1]||null}let no=1;function h2(i){no+=i}function zh(i){return i.dynamicChildren=no>0?Ft||yr:null,e6(),no>0&&Ft&&Ft.push(i),i}function Qe(i,e,t,n,r,s){return zh(me(i,e,t,n,r,s,!0))}function kc(i,e,t,n,r){return zh(je(i,e,t,n,r,!0))}function H1(i){return i?i.__v_isVNode===!0:!1}function vs(i,e){return i.type===e.type&&i.key===e.key}const pl="__vInternal",Bh=({key:i})=>i??null,Ca=({ref:i,ref_key:e,ref_for:t})=>(typeof i=="number"&&(i=""+i),i!=null?T0(i)||F0(i)||Ne(i)?{i:dt,r:i,k:e,f:!!t}:i:null);function me(i,e=null,t=null,n=0,r=null,s=i===W0?0:1,o=!1,a=!1){const l={__v_isVNode:!0,__v_skip:!0,type:i,props:e,key:e&&Bh(e),ref:e&&Ca(e),scopeId:hl,slotScopeIds:null,children:t,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:s,patchFlag:n,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:dt};return a?(Hc(l,t),s&128&&i.normalize(l)):t&&(l.shapeFlag|=T0(t)?8:16),no>0&&!o&&Ft&&(l.patchFlag>0||s&6)&&l.patchFlag!==32&&Ft.push(l),l}const je=t6;function t6(i,e=null,t=null,n=0,r=null,s=!1){if((!i||i===Th)&&(i=Ii),H1(i)){const a=Pr(i,e,!0);return t&&Hc(a,t),no>0&&!s&&Ft&&(a.shapeFlag&6?Ft[Ft.indexOf(i)]=a:Ft.push(a)),a.patchFlag|=-2,a}if(d6(i)&&(i=i.__vccOpts),e){e=kh(e);let{class:a,style:l}=e;a&&!T0(a)&&(e.class=qn(a)),l0(l)&&(dh(l)&&!Ee(l)&&(l=j0({},l)),e.style=Fi(l))}const o=T0(i)?1:_8(i)?128:$8(i)?64:l0(i)?4:Ne(i)?2:0;return me(i,e,t,n,r,o,s,!0)}function kh(i){return i?dh(i)||pl in i?j0({},i):i:null}function Pr(i,e,t=!1){const{props:n,ref:r,patchFlag:s,children:o}=i,a=e?i6(n||{},e):n;return{__v_isVNode:!0,__v_skip:!0,type:i.type,props:a,key:a&&Bh(a),ref:e&&e.ref?t&&r?Ee(r)?r.concat(Ca(e)):[r,Ca(e)]:Ca(e):r,scopeId:i.scopeId,slotScopeIds:i.slotScopeIds,children:o,target:i.target,targetAnchor:i.targetAnchor,staticCount:i.staticCount,shapeFlag:i.shapeFlag,patchFlag:e&&i.type!==W0?s===-1?16:s|16:s,dynamicProps:i.dynamicProps,dynamicChildren:i.dynamicChildren,appContext:i.appContext,dirs:i.dirs,transition:i.transition,component:i.component,suspense:i.suspense,ssContent:i.ssContent&&Pr(i.ssContent),ssFallback:i.ssFallback&&Pr(i.ssFallback),el:i.el,anchor:i.anchor,ctx:i.ctx,ce:i.ce}}function Gs(i=" ",e=0){return je(dl,null,i,e)}function n6(i,e){const t=je(Pa,null,i);return t.staticCount=e,t}function Gc(i="",e=!1){return e?(We(),kc(Ii,null,i)):je(Ii,null,i)}function Wt(i){return i==null||typeof i=="boolean"?je(Ii):Ee(i)?je(W0,null,i.slice()):typeof i=="object"?Nn(i):je(dl,null,String(i))}function Nn(i){return i.el===null&&i.patchFlag!==-1||i.memo?i:Pr(i)}function Hc(i,e){let t=0;const{shapeFlag:n}=i;if(e==null)e=null;else if(Ee(e))t=16;else if(typeof e=="object")if(n&65){const r=e.default;r&&(r._c&&(r._d=!1),Hc(i,r()),r._c&&(r._d=!0));return}else{t=32;const r=e._;!r&&!(pl in e)?e._ctx=dt:r===3&&dt&&(dt.slots._===1?e._=1:(e._=2,i.patchFlag|=1024))}else Ne(e)?(e={default:e,_ctx:dt},t=32):(e=String(e),n&64?(t=16,e=[Gs(e)]):t=8);i.children=e,i.shapeFlag|=t}function i6(...i){const e={};for(let t=0;tU0||dt;let Vc,Hi,f2="__VUE_INSTANCE_SETTERS__";(Hi=F1()[f2])||(Hi=F1()[f2]=[]),Hi.push(i=>U0=i),Vc=i=>{Hi.length>1?Hi.forEach(e=>e(i)):Hi[0](i)};const Cr=i=>{Vc(i),i.scope.on()},Li=()=>{U0&&U0.scope.off(),Vc(null)};function Gh(i){return i.vnode.shapeFlag&4}let io=!1;function l6(i,e=!1){io=e;const{props:t,children:n}=i.vnode,r=Gh(i);W8(i,t,r,e),Y8(i,n);const s=r?c6(i,e):void 0;return io=!1,s}function c6(i,e){const t=i.type;i.accessCache=Object.create(null),i.proxy=Rc(new Proxy(i.ctx,O8));const{setup:n}=t;if(n){const r=i.setupContext=n.length>1?h6(i):null;Cr(i),qr();const s=Hn(n,i,0,[i.props,r]);if(Qr(),Li(),Q3(s)){if(s.then(Li,Li),e)return s.then(o=>{d2(i,o,e)}).catch(o=>{cl(o,i,0)});i.asyncDep=s}else d2(i,s,e)}else Hh(i,e)}function d2(i,e,t){Ne(e)?i.type.__ssrInlineRender?i.ssrRender=e:i.render=e:l0(e)&&(i.setupState=vh(e)),Hh(i,t)}let p2;function Hh(i,e,t){const n=i.type;if(!i.render){if(!e&&p2&&!n.render){const r=n.template||zc(i).template;if(r){const{isCustomElement:s,compilerOptions:o}=i.appContext.config,{delimiters:a,compilerOptions:l}=n,c=j0(j0({isCustomElement:s,delimiters:a},o),l);n.render=p2(r,c)}}i.render=n.render||Nt}{Cr(i),qr();try{U8(i)}finally{Qr(),Li()}}}function u6(i){return i.attrsProxy||(i.attrsProxy=new Proxy(i.attrs,{get(e,t){return ct(i,"get","$attrs"),e[t]}}))}function h6(i){const e=t=>{i.exposed=t||{}};return{get attrs(){return u6(i)},slots:i.slots,emit:i.emit,expose:e}}function ml(i){if(i.exposed)return i.exposeProxy||(i.exposeProxy=new Proxy(vh(Rc(i.exposed)),{get(e,t){if(t in e)return e[t];if(t in zs)return zs[t](i)},has(e,t){return t in e||t in zs}}))}function f6(i,e=!0){return Ne(i)?i.displayName||i.name:i.name||e&&i.__name}function d6(i){return Ne(i)&&"__vccOpts"in i}const Rt=(i,e)=>o8(i,e,io);function Vh(i,e,t){const n=arguments.length;return n===2?l0(e)&&!Ee(e)?H1(e)?je(i,null,[e]):je(i,e):je(i,null,e):(n>3?t=Array.prototype.slice.call(arguments,2):n===3&&H1(t)&&(t=[t]),je(i,e,t))}const p6=Symbol.for("v-scx"),m6=()=>nt(p6),g6="3.3.8",v6="http://www.w3.org/2000/svg",Si=typeof document<"u"?document:null,m2=Si&&Si.createElement("template"),x6={insert:(i,e,t)=>{e.insertBefore(i,t||null)},remove:i=>{const e=i.parentNode;e&&e.removeChild(i)},createElement:(i,e,t,n)=>{const r=e?Si.createElementNS(v6,i):Si.createElement(i,t?{is:t}:void 0);return i==="select"&&n&&n.multiple!=null&&r.setAttribute("multiple",n.multiple),r},createText:i=>Si.createTextNode(i),createComment:i=>Si.createComment(i),setText:(i,e)=>{i.nodeValue=e},setElementText:(i,e)=>{i.textContent=e},parentNode:i=>i.parentNode,nextSibling:i=>i.nextSibling,querySelector:i=>Si.querySelector(i),setScopeId(i,e){i.setAttribute(e,"")},insertStaticContent(i,e,t,n,r,s){const o=t?t.previousSibling:e.lastChild;if(r&&(r===s||r.nextSibling))for(;e.insertBefore(r.cloneNode(!0),t),!(r===s||!(r=r.nextSibling)););else{m2.innerHTML=n?`${i}`:i;const a=m2.content;if(n){const l=a.firstChild;for(;l.firstChild;)a.appendChild(l.firstChild);a.removeChild(l)}e.insertBefore(a,t)}return[o?o.nextSibling:e.firstChild,t?t.previousSibling:e.lastChild]}},y6=Symbol("_vtc");function _6(i,e,t){const n=i[y6];n&&(e=(e?[e,...n]:[...n]).join(" ")),e==null?i.removeAttribute("class"):t?i.setAttribute("class",e):i.className=e}const b6=Symbol("_vod");function w6(i,e,t){const n=i.style,r=T0(t);if(t&&!r){if(e&&!T0(e))for(const s in e)t[s]==null&&V1(n,s,"");for(const s in t)V1(n,s,t[s])}else{const s=n.display;r?e!==t&&(n.cssText=t):e&&i.removeAttribute("style"),b6 in i&&(n.display=s)}}const g2=/\s*!important$/;function V1(i,e,t){if(Ee(t))t.forEach(n=>V1(i,e,n));else if(t==null&&(t=""),e.startsWith("--"))i.setProperty(e,t);else{const n=M6(i,e);g2.test(t)?i.setProperty(Yr(n),t.replace(g2,""),"important"):i[n]=t}}const v2=["Webkit","Moz","ms"],zl={};function M6(i,e){const t=zl[e];if(t)return t;let n=qt(e);if(n!=="filter"&&n in i)return zl[e]=n;n=ol(n);for(let r=0;rBl||(P6.then(()=>Bl=0),Bl=Date.now());function R6(i,e){const t=n=>{if(!n._vts)n._vts=Date.now();else if(n._vts<=t.attached)return;Ot(F6(n,t.value),e,5,[n])};return t.value=i,t.attached=C6(),t}function F6(i,e){if(Ee(e)){const t=i.stopImmediatePropagation;return i.stopImmediatePropagation=()=>{t.call(i),i._stopped=!0},e.map(n=>r=>!r._stopped&&n&&n(r))}else return e}const b2=/^on[a-z]/,I6=(i,e,t,n,r=!1,s,o,a,l)=>{e==="class"?_6(i,n,r):e==="style"?w6(i,t,n):rl(e)?wc(e)||E6(i,e,t,n,o):(e[0]==="."?(e=e.slice(1),!0):e[0]==="^"?(e=e.slice(1),!1):D6(i,e,n,r))?T6(i,e,n,s,o,a,l):(e==="true-value"?i._trueValue=n:e==="false-value"&&(i._falseValue=n),S6(i,e,n,r))};function D6(i,e,t,n){return n?!!(e==="innerHTML"||e==="textContent"||e in i&&b2.test(e)&&Ne(t)):e==="spellcheck"||e==="draggable"||e==="translate"||e==="form"||e==="list"&&i.tagName==="INPUT"||e==="type"&&i.tagName==="TEXTAREA"||b2.test(e)&&T0(t)?!1:e in i}const Rr=i=>{const e=i.props["onUpdate:modelValue"]||!1;return Ee(e)?t=>Ea(e,t):e};function N6(i){i.target.composing=!0}function w2(i){const e=i.target;e.composing&&(e.composing=!1,e.dispatchEvent(new Event("input")))}const pn=Symbol("_assign"),Sr={created(i,{modifiers:{lazy:e,trim:t,number:n}},r){i[pn]=Rr(r);const s=n||r.props&&r.props.type==="number";Un(i,e?"change":"input",o=>{if(o.target.composing)return;let a=i.value;t&&(a=a.trim()),s&&(a=Oa(a)),i[pn](a)}),t&&Un(i,"change",()=>{i.value=i.value.trim()}),e||(Un(i,"compositionstart",N6),Un(i,"compositionend",w2),Un(i,"change",w2))},mounted(i,{value:e}){i.value=e??""},beforeUpdate(i,{value:e,modifiers:{lazy:t,trim:n,number:r}},s){if(i[pn]=Rr(s),i.composing||document.activeElement===i&&i.type!=="range"&&(t||n&&i.value.trim()===e||(r||i.type==="number")&&Oa(i.value)===e))return;const o=e??"";i.value!==o&&(i.value=o)}},O6={deep:!0,created(i,e,t){i[pn]=Rr(t),Un(i,"change",()=>{const n=i._modelValue,r=ro(i),s=i.checked,o=i[pn];if(Ee(n)){const a=Tc(n,r),l=a!==-1;if(s&&!l)o(n.concat(r));else if(!s&&l){const c=[...n];c.splice(a,1),o(c)}}else if(jr(n)){const a=new Set(n);s?a.add(r):a.delete(r),o(a)}else o(Wh(i,s))})},mounted:M2,beforeUpdate(i,e,t){i[pn]=Rr(t),M2(i,e,t)}};function M2(i,{value:e,oldValue:t},n){i._modelValue=e,Ee(e)?i.checked=Tc(e,n.props.value)>-1:jr(e)?i.checked=e.has(n.props.value):e!==t&&(i.checked=Ao(e,Wh(i,!0)))}const U6={deep:!0,created(i,{value:e,modifiers:{number:t}},n){const r=jr(e);Un(i,"change",()=>{const s=Array.prototype.filter.call(i.options,o=>o.selected).map(o=>t?Oa(ro(o)):ro(o));i[pn](i.multiple?r?new Set(s):s:s[0])}),i[pn]=Rr(n)},mounted(i,{value:e}){S2(i,e)},beforeUpdate(i,e,t){i[pn]=Rr(t)},updated(i,{value:e}){S2(i,e)}};function S2(i,e){const t=i.multiple;if(!(t&&!Ee(e)&&!jr(e))){for(let n=0,r=i.options.length;n-1:s.selected=e.has(o);else if(Ao(ro(s),e)){i.selectedIndex!==n&&(i.selectedIndex=n);return}}!t&&i.selectedIndex!==-1&&(i.selectedIndex=-1)}}function ro(i){return"_value"in i?i._value:i.value}function Wh(i,e){const t=e?"_trueValue":"_falseValue";return t in i?i[t]:e}const z6=["ctrl","shift","alt","meta"],B6={stop:i=>i.stopPropagation(),prevent:i=>i.preventDefault(),self:i=>i.target!==i.currentTarget,ctrl:i=>!i.ctrlKey,shift:i=>!i.shiftKey,alt:i=>!i.altKey,meta:i=>!i.metaKey,left:i=>"button"in i&&i.button!==0,middle:i=>"button"in i&&i.button!==1,right:i=>"button"in i&&i.button!==2,exact:(i,e)=>z6.some(t=>i[`${t}Key`]&&!e.includes(t))},Xh=(i,e)=>(t,...n)=>{for(let r=0;r{const e=G6().createApp(...i),{mount:t}=e;return e.mount=n=>{const r=V6(n);if(!r)return;const s=e._component;!Ne(s)&&!s.render&&!s.template&&(s.template=r.innerHTML),r.innerHTML="";const o=t(r,!1,r instanceof SVGElement);return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),o},e};function V6(i){return T0(i)?document.querySelector(i):i}var W6=!1;/*! +(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const r of document.querySelectorAll('link[rel="modulepreload"]'))n(r);new MutationObserver(r=>{for(const s of r)if(s.type==="childList")for(const o of s.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&n(o)}).observe(document,{childList:!0,subtree:!0});function t(r){const s={};return r.integrity&&(s.integrity=r.integrity),r.referrerPolicy&&(s.referrerPolicy=r.referrerPolicy),r.crossOrigin==="use-credentials"?s.credentials="include":r.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function n(r){if(r.ep)return;r.ep=!0;const s=t(r);fetch(r.href,s)}})();function wc(i,e){const t=Object.create(null),n=i.split(",");for(let r=0;r!!t[r.toLowerCase()]:r=>!!t[r]}const f0={},yr=[],Nt=()=>{},md=()=>!1,gd=/^on[^a-z]/,rl=i=>gd.test(i),Mc=i=>i.startsWith("onUpdate:"),j0=Object.assign,Sc=(i,e)=>{const t=i.indexOf(e);t>-1&&i.splice(t,1)},vd=Object.prototype.hasOwnProperty,Ye=(i,e)=>vd.call(i,e),Ee=Array.isArray,_r=i=>To(i)==="[object Map]",Yr=i=>To(i)==="[object Set]",X9=i=>To(i)==="[object Date]",Ne=i=>typeof i=="function",T0=i=>typeof i=="string",Lr=i=>typeof i=="symbol",l0=i=>i!==null&&typeof i=="object",Q3=i=>(l0(i)||Ne(i))&&Ne(i.then)&&Ne(i.catch),K3=Object.prototype.toString,To=i=>K3.call(i),xd=i=>To(i).slice(8,-1),Z3=i=>To(i)==="[object Object]",Tc=i=>T0(i)&&i!=="NaN"&&i[0]!=="-"&&""+parseInt(i,10)===i,Aa=wc(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),sl=i=>{const e=Object.create(null);return t=>e[t]||(e[t]=i(t))},yd=/-(\w)/g,qt=sl(i=>i.replace(yd,(e,t)=>t?t.toUpperCase():"")),_d=/\B([A-Z])/g,qr=sl(i=>i.replace(_d,"-$1").toLowerCase()),ol=sl(i=>i.charAt(0).toUpperCase()+i.slice(1)),Ol=sl(i=>i?`on${ol(i)}`:""),Ri=(i,e)=>!Object.is(i,e),Ea=(i,e)=>{for(let t=0;t{Object.defineProperty(i,e,{configurable:!0,enumerable:!1,value:t})},Oa=i=>{const e=parseFloat(i);return isNaN(e)?i:e};let j9;const I1=()=>j9||(j9=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Fi(i){if(Ee(i)){const e={};for(let t=0;t{if(t){const n=t.split(wd);n.length>1&&(e[n[0].trim()]=n[1].trim())}}),e}function qn(i){let e="";if(T0(i))e=i;else if(Ee(i))for(let t=0;tAo(t,e))}const pr=i=>T0(i)?i:i==null?"":Ee(i)||l0(i)&&(i.toString===K3||!Ne(i.toString))?JSON.stringify(i,$3,2):String(i),$3=(i,e)=>e&&e.__v_isRef?$3(i,e.value):_r(e)?{[`Map(${e.size})`]:[...e.entries()].reduce((t,[n,r])=>(t[`${n} =>`]=r,t),{})}:Yr(e)?{[`Set(${e.size})`]:[...e.values()]}:l0(e)&&!Ee(e)&&!Z3(e)?String(e):e;let Lt;class eh{constructor(e=!1){this.detached=e,this._active=!0,this.effects=[],this.cleanups=[],this.parent=Lt,!e&&Lt&&(this.index=(Lt.scopes||(Lt.scopes=[])).push(this)-1)}get active(){return this._active}run(e){if(this._active){const t=Lt;try{return Lt=this,e()}finally{Lt=t}}}on(){Lt=this}off(){Lt=this.parent}stop(e){if(this._active){let t,n;for(t=0,n=this.effects.length;t{const e=new Set(i);return e.w=0,e.n=0,e},th=i=>(i.w&Qn)>0,nh=i=>(i.n&Qn)>0,Fd=({deps:i})=>{if(i.length)for(let e=0;e{const{deps:e}=i;if(e.length){let t=0;for(let n=0;n{(u==="length"||!Lr(u)&&u>=l)&&a.push(c)})}else switch(t!==void 0&&a.push(o.get(t)),e){case"add":Ee(i)?Tc(t)&&a.push(o.get("length")):(a.push(o.get(Ei)),_r(i)&&a.push(o.get(N1)));break;case"delete":Ee(i)||(a.push(o.get(Ei)),_r(i)&&a.push(o.get(N1)));break;case"set":_r(i)&&a.push(o.get(Ei));break}if(a.length===1)a[0]&&O1(a[0]);else{const l=[];for(const c of a)c&&l.push(...c);O1(Ec(l))}}function O1(i,e){const t=Ee(i)?i:[...i];for(const n of t)n.computed&&q9(n);for(const n of t)n.computed||q9(n)}function q9(i,e){(i!==Ct||i.allowRecurse)&&(i.scheduler?i.scheduler():i.run())}function Dd(i,e){var t;return(t=Ua.get(i))==null?void 0:t.get(e)}const Nd=wc("__proto__,__v_isRef,__isVue"),sh=new Set(Object.getOwnPropertyNames(Symbol).filter(i=>i!=="arguments"&&i!=="caller").map(i=>Symbol[i]).filter(Lr)),Q9=Od();function Od(){const i={};return["includes","indexOf","lastIndexOf"].forEach(e=>{i[e]=function(...t){const n=Ke(this);for(let s=0,o=this.length;s{i[e]=function(...t){Qr();const n=Ke(this)[e].apply(this,t);return Kr(),n}}),i}function Ud(i){const e=Ke(this);return ct(e,"has",i),e.hasOwnProperty(i)}class oh{constructor(e=!1,t=!1){this._isReadonly=e,this._shallow=t}get(e,t,n){const r=this._isReadonly,s=this._shallow;if(t==="__v_isReactive")return!r;if(t==="__v_isReadonly")return r;if(t==="__v_isShallow")return s;if(t==="__v_raw"&&n===(r?s?Kd:uh:s?ch:lh).get(e))return e;const o=Ee(e);if(!r){if(o&&Ye(Q9,t))return Reflect.get(Q9,t,n);if(t==="hasOwnProperty")return Ud}const a=Reflect.get(e,t,n);return(Lr(t)?sh.has(t):Nd(t))||(r||ct(e,"get",t),s)?a:F0(a)?o&&Tc(t)?a:a.value:l0(a)?r?fh(a):ll(a):a}}class ah extends oh{constructor(e=!1){super(!1,e)}set(e,t,n,r){let s=e[t];if(Pr(s)&&F0(s)&&!F0(n))return!1;if(!this._shallow&&(!za(n)&&!Pr(n)&&(s=Ke(s),n=Ke(n)),!Ee(e)&&F0(s)&&!F0(n)))return s.value=n,!0;const o=Ee(e)&&Tc(t)?Number(t)i,al=i=>Reflect.getPrototypeOf(i);function Oo(i,e,t=!1,n=!1){i=i.__v_raw;const r=Ke(i),s=Ke(e);t||(Ri(e,s)&&ct(r,"get",e),ct(r,"get",s));const{has:o}=al(r),a=n?Pc:t?Ic:Js;if(o.call(r,e))return a(i.get(e));if(o.call(r,s))return a(i.get(s));i!==r&&i.get(e)}function Uo(i,e=!1){const t=this.__v_raw,n=Ke(t),r=Ke(i);return e||(Ri(i,r)&&ct(n,"has",i),ct(n,"has",r)),i===r?t.has(i):t.has(i)||t.has(r)}function zo(i,e=!1){return i=i.__v_raw,!e&&ct(Ke(i),"iterate",Ei),Reflect.get(i,"size",i)}function K9(i){i=Ke(i);const e=Ke(this);return al(e).has.call(e,i)||(e.add(i),dn(e,"add",i,i)),this}function Z9(i,e){e=Ke(e);const t=Ke(this),{has:n,get:r}=al(t);let s=n.call(t,i);s||(i=Ke(i),s=n.call(t,i));const o=r.call(t,i);return t.set(i,e),s?Ri(e,o)&&dn(t,"set",i,e):dn(t,"add",i,e),this}function J9(i){const e=Ke(this),{has:t,get:n}=al(e);let r=t.call(e,i);r||(i=Ke(i),r=t.call(e,i)),n&&n.call(e,i);const s=e.delete(i);return r&&dn(e,"delete",i,void 0),s}function $9(){const i=Ke(this),e=i.size!==0,t=i.clear();return e&&dn(i,"clear",void 0,void 0),t}function Bo(i,e){return function(n,r){const s=this,o=s.__v_raw,a=Ke(o),l=e?Pc:i?Ic:Js;return!i&&ct(a,"iterate",Ei),o.forEach((c,u)=>n.call(r,l(c),l(u),s))}}function ko(i,e,t){return function(...n){const r=this.__v_raw,s=Ke(r),o=_r(s),a=i==="entries"||i===Symbol.iterator&&o,l=i==="keys"&&o,c=r[i](...n),u=t?Pc:e?Ic:Js;return!e&&ct(s,"iterate",l?N1:Ei),{next(){const{value:h,done:f}=c.next();return f?{value:h,done:f}:{value:a?[u(h[0]),u(h[1])]:u(h),done:f}},[Symbol.iterator](){return this}}}}function Mn(i){return function(...e){return i==="delete"?!1:this}}function Hd(){const i={get(s){return Oo(this,s)},get size(){return zo(this)},has:Uo,add:K9,set:Z9,delete:J9,clear:$9,forEach:Bo(!1,!1)},e={get(s){return Oo(this,s,!1,!0)},get size(){return zo(this)},has:Uo,add:K9,set:Z9,delete:J9,clear:$9,forEach:Bo(!1,!0)},t={get(s){return Oo(this,s,!0)},get size(){return zo(this,!0)},has(s){return Uo.call(this,s,!0)},add:Mn("add"),set:Mn("set"),delete:Mn("delete"),clear:Mn("clear"),forEach:Bo(!0,!1)},n={get(s){return Oo(this,s,!0,!0)},get size(){return zo(this,!0)},has(s){return Uo.call(this,s,!0)},add:Mn("add"),set:Mn("set"),delete:Mn("delete"),clear:Mn("clear"),forEach:Bo(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(s=>{i[s]=ko(s,!1,!1),t[s]=ko(s,!0,!1),e[s]=ko(s,!1,!0),n[s]=ko(s,!0,!0)}),[i,t,e,n]}const[Vd,Wd,Xd,jd]=Hd();function Cc(i,e){const t=e?i?jd:Xd:i?Wd:Vd;return(n,r,s)=>r==="__v_isReactive"?!i:r==="__v_isReadonly"?i:r==="__v_raw"?n:Reflect.get(Ye(t,r)&&r in n?t:n,r,s)}const Yd={get:Cc(!1,!1)},qd={get:Cc(!1,!0)},Qd={get:Cc(!0,!1)},lh=new WeakMap,ch=new WeakMap,uh=new WeakMap,Kd=new WeakMap;function Zd(i){switch(i){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function Jd(i){return i.__v_skip||!Object.isExtensible(i)?0:Zd(xd(i))}function ll(i){return Pr(i)?i:Rc(i,!1,Bd,Yd,lh)}function hh(i){return Rc(i,!1,Gd,qd,ch)}function fh(i){return Rc(i,!0,kd,Qd,uh)}function Rc(i,e,t,n,r){if(!l0(i)||i.__v_raw&&!(e&&i.__v_isReactive))return i;const s=r.get(i);if(s)return s;const o=Jd(i);if(o===0)return i;const a=new Proxy(i,o===2?n:t);return r.set(i,a),a}function br(i){return Pr(i)?br(i.__v_raw):!!(i&&i.__v_isReactive)}function Pr(i){return!!(i&&i.__v_isReadonly)}function za(i){return!!(i&&i.__v_isShallow)}function dh(i){return br(i)||Pr(i)}function Ke(i){const e=i&&i.__v_raw;return e?Ke(e):i}function Fc(i){return Na(i,"__v_skip",!0),i}const Js=i=>l0(i)?ll(i):i,Ic=i=>l0(i)?fh(i):i;function ph(i){kn&&Ct&&(i=Ke(i),rh(i.dep||(i.dep=Ec())))}function mh(i,e){i=Ke(i);const t=i.dep;t&&O1(t)}function F0(i){return!!(i&&i.__v_isRef===!0)}function P0(i){return gh(i,!1)}function $d(i){return gh(i,!0)}function gh(i,e){return F0(i)?i:new e8(i,e)}class e8{constructor(e,t){this.__v_isShallow=t,this.dep=void 0,this.__v_isRef=!0,this._rawValue=t?e:Ke(e),this._value=t?e:Js(e)}get value(){return ph(this),this._value}set value(e){const t=this.__v_isShallow||za(e)||Pr(e);e=t?e:Ke(e),Ri(e,this._rawValue)&&(this._rawValue=e,this._value=t?e:Js(e),mh(this))}}function Gn(i){return F0(i)?i.value:i}const t8={get:(i,e,t)=>Gn(Reflect.get(i,e,t)),set:(i,e,t,n)=>{const r=i[e];return F0(r)&&!F0(t)?(r.value=t,!0):Reflect.set(i,e,t,n)}};function vh(i){return br(i)?i:new Proxy(i,t8)}class n8{constructor(e,t,n){this._object=e,this._key=t,this._defaultValue=n,this.__v_isRef=!0}get value(){const e=this._object[this._key];return e===void 0?this._defaultValue:e}set value(e){this._object[this._key]=e}get dep(){return Dd(Ke(this._object),this._key)}}class i8{constructor(e){this._getter=e,this.__v_isRef=!0,this.__v_isReadonly=!0}get value(){return this._getter()}}function xh(i,e,t){return F0(i)?i:Ne(i)?new i8(i):l0(i)&&arguments.length>1?r8(i,e,t):P0(i)}function r8(i,e,t){const n=i[e];return F0(n)?n:new n8(i,e,t)}class s8{constructor(e,t,n,r){this._setter=t,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this._dirty=!0,this.effect=new Lc(e,()=>{this._dirty||(this._dirty=!0,mh(this))}),this.effect.computed=this,this.effect.active=this._cacheable=!r,this.__v_isReadonly=n}get value(){const e=Ke(this);return ph(e),(e._dirty||!e._cacheable)&&(e._dirty=!1,e._value=e.effect.run()),e._value}set value(e){this._setter(e)}}function o8(i,e,t=!1){let n,r;const s=Ne(i);return s?(n=i,r=Nt):(n=i.get,r=i.set),new s8(n,r,s||!r,t)}function Hn(i,e,t,n){let r;try{r=n?i(...n):i()}catch(s){cl(s,e,t)}return r}function Ot(i,e,t,n){if(Ne(i)){const s=Hn(i,e,t,n);return s&&Q3(s)&&s.catch(o=>{cl(o,e,t)}),s}const r=[];for(let s=0;s>>1,r=K0[n],s=eo(r);sjt&&K0.splice(e,1)}function u8(i){Ee(i)?wr.push(...i):(!hn||!hn.includes(i,i.allowRecurse?Mi+1:Mi))&&wr.push(i),bh()}function e2(i,e=$s?jt+1:0){for(;eeo(t)-eo(n)),Mi=0;Mii.id==null?1/0:i.id,h8=(i,e)=>{const t=eo(i)-eo(e);if(t===0){if(i.pre&&!e.pre)return-1;if(e.pre&&!i.pre)return 1}return t};function Mh(i){U1=!1,$s=!0,K0.sort(h8);const e=Nt;try{for(jt=0;jtT0(d)?d.trim():d)),h&&(r=t.map(Oa))}let a,l=n[a=Ol(e)]||n[a=Ol(qt(e))];!l&&s&&(l=n[a=Ol(qr(e))]),l&&Ot(l,i,6,r);const c=n[a+"Once"];if(c){if(!i.emitted)i.emitted={};else if(i.emitted[a])return;i.emitted[a]=!0,Ot(c,i,6,r)}}function Sh(i,e,t=!1){const n=e.emitsCache,r=n.get(i);if(r!==void 0)return r;const s=i.emits;let o={},a=!1;if(!Ne(i)){const l=c=>{const u=Sh(c,e,!0);u&&(a=!0,j0(o,u))};!t&&e.mixins.length&&e.mixins.forEach(l),i.extends&&l(i.extends),i.mixins&&i.mixins.forEach(l)}return!s&&!a?(l0(i)&&n.set(i,null),null):(Ee(s)?s.forEach(l=>o[l]=null):j0(o,s),l0(i)&&n.set(i,o),o)}function ul(i,e){return!i||!rl(e)?!1:(e=e.slice(2).replace(/Once$/,""),Ye(i,e[0].toLowerCase()+e.slice(1))||Ye(i,qr(e))||Ye(i,e))}let dt=null,hl=null;function Ba(i){const e=dt;return dt=i,hl=i&&i.type.__scopeId||null,e}function d8(i){hl=i}function p8(){hl=null}function Mr(i,e=dt,t){if(!e||i._n)return i;const n=(...r)=>{n._d&&h2(-1);const s=Ba(e);let o;try{o=i(...r)}finally{Ba(s),n._d&&h2(1)}return o};return n._n=!0,n._c=!0,n._d=!0,n}function Ul(i){const{type:e,vnode:t,proxy:n,withProxy:r,props:s,propsOptions:[o],slots:a,attrs:l,emit:c,render:u,renderCache:h,data:f,setupState:d,ctx:g,inheritAttrs:v}=i;let _,m;const p=Ba(i);try{if(t.shapeFlag&4){const x=r||n;_=Wt(u.call(x,x,h,s,d,f,g)),m=l}else{const x=e;_=Wt(x.length>1?x(s,{attrs:l,slots:a,emit:c}):x(s,null)),m=e.props?l:m8(l)}}catch(x){Gs.length=0,cl(x,i,1),_=je(Ii)}let y=_;if(m&&v!==!1){const x=Object.keys(m),{shapeFlag:w}=y;x.length&&w&7&&(o&&x.some(Mc)&&(m=g8(m,o)),y=Cr(y,m))}return t.dirs&&(y=Cr(y),y.dirs=y.dirs?y.dirs.concat(t.dirs):t.dirs),t.transition&&(y.transition=t.transition),_=y,Ba(p),_}const m8=i=>{let e;for(const t in i)(t==="class"||t==="style"||rl(t))&&((e||(e={}))[t]=i[t]);return e},g8=(i,e)=>{const t={};for(const n in i)(!Mc(n)||!(n.slice(9)in e))&&(t[n]=i[n]);return t};function v8(i,e,t){const{props:n,children:r,component:s}=i,{props:o,children:a,patchFlag:l}=e,c=s.emitsOptions;if(e.dirs||e.transition)return!0;if(t&&l>=0){if(l&1024)return!0;if(l&16)return n?t2(n,o,c):!!o;if(l&8){const u=e.dynamicProps;for(let h=0;hi.__isSuspense;function b8(i,e){e&&e.pendingBranch?Ee(i)?e.effects.push(...i):e.effects.push(i):u8(i)}function w8(i,e){return Uc(i,null,e)}const Go={};function Ze(i,e,t){return Uc(i,e,t)}function Uc(i,e,{immediate:t,deep:n,flush:r,onTrack:s,onTrigger:o}=f0){var a;const l=Rd()===((a=z0)==null?void 0:a.scope)?z0:null;let c,u=!1,h=!1;if(F0(i)?(c=()=>i.value,u=za(i)):br(i)?(c=()=>i,n=!0):Ee(i)?(h=!0,u=i.some(x=>br(x)||za(x)),c=()=>i.map(x=>{if(F0(x))return x.value;if(br(x))return Ti(x);if(Ne(x))return Hn(x,l,2)})):Ne(i)?e?c=()=>Hn(i,l,2):c=()=>{if(!(l&&l.isUnmounted))return f&&f(),Ot(i,l,3,[d])}:c=Nt,e&&n){const x=c;c=()=>Ti(x())}let f,d=x=>{f=p.onStop=()=>{Hn(x,l,4)}},g;if(io)if(d=Nt,e?t&&Ot(e,l,3,[c(),h?[]:void 0,d]):c(),r==="sync"){const x=m6();g=x.__watcherHandles||(x.__watcherHandles=[])}else return Nt;let v=h?new Array(i.length).fill(Go):Go;const _=()=>{if(p.active)if(e){const x=p.run();(n||u||(h?x.some((w,A)=>Ri(w,v[A])):Ri(x,v)))&&(f&&f(),Ot(e,l,3,[x,v===Go?void 0:h&&v[0]===Go?[]:v,d]),v=x)}else p.run()};_.allowRecurse=!!e;let m;r==="sync"?m=_:r==="post"?m=()=>ot(_,l&&l.suspense):(_.pre=!0,l&&(_.id=l.uid),m=()=>Nc(_));const p=new Lc(c,m);e?t?_():v=p.run():r==="post"?ot(p.run.bind(p),l&&l.suspense):p.run();const y=()=>{p.stop(),l&&l.scope&&Sc(l.scope.effects,p)};return g&&g.push(y),y}function M8(i,e,t){const n=this.proxy,r=T0(i)?i.includes(".")?Eh(n,i):()=>n[i]:i.bind(n,n);let s;Ne(e)?s=e:(s=e.handler,t=e);const o=z0;Rr(this);const a=Uc(r,s.bind(n),t);return o?Rr(o):Li(),a}function Eh(i,e){const t=e.split(".");return()=>{let n=i;for(let r=0;r{Ti(t,e)});else if(Z3(i))for(const t in i)Ti(i[t],e);return i}function Bn(i,e){const t=dt;if(t===null)return i;const n=gl(t)||t.proxy,r=i.dirs||(i.dirs=[]);for(let s=0;sj0({name:i.name},e,{setup:i}))():i}const La=i=>!!i.type.__asyncLoader,Lh=i=>i.type.__isKeepAlive;function S8(i,e){Ph(i,"a",e)}function T8(i,e){Ph(i,"da",e)}function Ph(i,e,t=z0){const n=i.__wdc||(i.__wdc=()=>{let r=t;for(;r;){if(r.isDeactivated)return;r=r.parent}return i()});if(fl(e,n,t),t){let r=t.parent;for(;r&&r.parent;)Lh(r.parent.vnode)&&A8(n,e,t,r),r=r.parent}}function A8(i,e,t,n){const r=fl(e,i,n,!0);zc(()=>{Sc(n[e],r)},t)}function fl(i,e,t=z0,n=!1){if(t){const r=t[i]||(t[i]=[]),s=e.__weh||(e.__weh=(...o)=>{if(t.isUnmounted)return;Qr(),Rr(t);const a=Ot(e,t,i,o);return Li(),Kr(),a});return n?r.unshift(s):r.push(s),s}}const yn=i=>(e,t=z0)=>(!io||i==="sp")&&fl(i,(...n)=>e(...n),t),E8=yn("bm"),L8=yn("m"),P8=yn("bu"),C8=yn("u"),R8=yn("bum"),zc=yn("um"),F8=yn("sp"),I8=yn("rtg"),D8=yn("rtc");function N8(i,e=z0){fl("ec",i,e)}function to(i,e,t,n){let r;const s=t&&t[n];if(Ee(i)||T0(i)){r=new Array(i.length);for(let o=0,a=i.length;oe(o,a,void 0,s&&s[a]));else{const o=Object.keys(i);r=new Array(o.length);for(let a=0,l=o.length;ai?Gh(i)?gl(i)||i.proxy:z1(i.parent):null,Bs=j0(Object.create(null),{$:i=>i,$el:i=>i.vnode.el,$data:i=>i.data,$props:i=>i.props,$attrs:i=>i.attrs,$slots:i=>i.slots,$refs:i=>i.refs,$parent:i=>z1(i.parent),$root:i=>z1(i.root),$emit:i=>i.emit,$options:i=>Bc(i),$forceUpdate:i=>i.f||(i.f=()=>Nc(i.update)),$nextTick:i=>i.n||(i.n=_h.bind(i.proxy)),$watch:i=>M8.bind(i)}),zl=(i,e)=>i!==f0&&!i.__isScriptSetup&&Ye(i,e),O8={get({_:i},e){const{ctx:t,setupState:n,data:r,props:s,accessCache:o,type:a,appContext:l}=i;let c;if(e[0]!=="$"){const d=o[e];if(d!==void 0)switch(d){case 1:return n[e];case 2:return r[e];case 4:return t[e];case 3:return s[e]}else{if(zl(n,e))return o[e]=1,n[e];if(r!==f0&&Ye(r,e))return o[e]=2,r[e];if((c=i.propsOptions[0])&&Ye(c,e))return o[e]=3,s[e];if(t!==f0&&Ye(t,e))return o[e]=4,t[e];B1&&(o[e]=0)}}const u=Bs[e];let h,f;if(u)return e==="$attrs"&&ct(i,"get",e),u(i);if((h=a.__cssModules)&&(h=h[e]))return h;if(t!==f0&&Ye(t,e))return o[e]=4,t[e];if(f=l.config.globalProperties,Ye(f,e))return f[e]},set({_:i},e,t){const{data:n,setupState:r,ctx:s}=i;return zl(r,e)?(r[e]=t,!0):n!==f0&&Ye(n,e)?(n[e]=t,!0):Ye(i.props,e)||e[0]==="$"&&e.slice(1)in i?!1:(s[e]=t,!0)},has({_:{data:i,setupState:e,accessCache:t,ctx:n,appContext:r,propsOptions:s}},o){let a;return!!t[o]||i!==f0&&Ye(i,o)||zl(e,o)||(a=s[0])&&Ye(a,o)||Ye(n,o)||Ye(Bs,o)||Ye(r.config.globalProperties,o)},defineProperty(i,e,t){return t.get!=null?i._.accessCache[e]=0:Ye(t,"value")&&this.set(i,e,t.value,null),Reflect.defineProperty(i,e,t)}};function i2(i){return Ee(i)?i.reduce((e,t)=>(e[t]=null,e),{}):i}let B1=!0;function U8(i){const e=Bc(i),t=i.proxy,n=i.ctx;B1=!1,e.beforeCreate&&r2(e.beforeCreate,i,"bc");const{data:r,computed:s,methods:o,watch:a,provide:l,inject:c,created:u,beforeMount:h,mounted:f,beforeUpdate:d,updated:g,activated:v,deactivated:_,beforeDestroy:m,beforeUnmount:p,destroyed:y,unmounted:x,render:w,renderTracked:A,renderTriggered:b,errorCaptured:L,serverPrefetch:B,expose:I,inheritAttrs:C,components:Y,directives:O,filters:G}=e;if(c&&z8(c,n,null),o)for(const k in o){const K=o[k];Ne(K)&&(n[k]=K.bind(t))}if(r){const k=r.call(t,t);l0(k)&&(i.data=ll(k))}if(B1=!0,s)for(const k in s){const K=s[k],le=Ne(K)?K.bind(t,t):Ne(K.get)?K.get.bind(t,t):Nt,ve=!Ne(K)&&Ne(K.set)?K.set.bind(t):Nt,ce=Rt({get:le,set:ve});Object.defineProperty(n,k,{enumerable:!0,configurable:!0,get:()=>ce.value,set:ye=>ce.value=ye})}if(a)for(const k in a)Ch(a[k],n,t,k);if(l){const k=Ne(l)?l.call(t):l;Reflect.ownKeys(k).forEach(K=>{ks(K,k[K])})}u&&r2(u,i,"c");function N(k,K){Ee(K)?K.forEach(le=>k(le.bind(t))):K&&k(K.bind(t))}if(N(E8,h),N(L8,f),N(P8,d),N(C8,g),N(S8,v),N(T8,_),N(N8,L),N(D8,A),N(I8,b),N(R8,p),N(zc,x),N(F8,B),Ee(I))if(I.length){const k=i.exposed||(i.exposed={});I.forEach(K=>{Object.defineProperty(k,K,{get:()=>t[K],set:le=>t[K]=le})})}else i.exposed||(i.exposed={});w&&i.render===Nt&&(i.render=w),C!=null&&(i.inheritAttrs=C),Y&&(i.components=Y),O&&(i.directives=O)}function z8(i,e,t=Nt){Ee(i)&&(i=k1(i));for(const n in i){const r=i[n];let s;l0(r)?"default"in r?s=nt(r.from||n,r.default,!0):s=nt(r.from||n):s=nt(r),F0(s)?Object.defineProperty(e,n,{enumerable:!0,configurable:!0,get:()=>s.value,set:o=>s.value=o}):e[n]=s}}function r2(i,e,t){Ot(Ee(i)?i.map(n=>n.bind(e.proxy)):i.bind(e.proxy),e,t)}function Ch(i,e,t,n){const r=n.includes(".")?Eh(t,n):()=>t[n];if(T0(i)){const s=e[i];Ne(s)&&Ze(r,s)}else if(Ne(i))Ze(r,i.bind(t));else if(l0(i))if(Ee(i))i.forEach(s=>Ch(s,e,t,n));else{const s=Ne(i.handler)?i.handler.bind(t):e[i.handler];Ne(s)&&Ze(r,s,i)}}function Bc(i){const e=i.type,{mixins:t,extends:n}=e,{mixins:r,optionsCache:s,config:{optionMergeStrategies:o}}=i.appContext,a=s.get(e);let l;return a?l=a:!r.length&&!t&&!n?l=e:(l={},r.length&&r.forEach(c=>ka(l,c,o,!0)),ka(l,e,o)),l0(e)&&s.set(e,l),l}function ka(i,e,t,n=!1){const{mixins:r,extends:s}=e;s&&ka(i,s,t,!0),r&&r.forEach(o=>ka(i,o,t,!0));for(const o in e)if(!(n&&o==="expose")){const a=B8[o]||t&&t[o];i[o]=a?a(i[o],e[o]):e[o]}return i}const B8={data:s2,props:o2,emits:o2,methods:Os,computed:Os,beforeCreate:et,created:et,beforeMount:et,mounted:et,beforeUpdate:et,updated:et,beforeDestroy:et,beforeUnmount:et,destroyed:et,unmounted:et,activated:et,deactivated:et,errorCaptured:et,serverPrefetch:et,components:Os,directives:Os,watch:G8,provide:s2,inject:k8};function s2(i,e){return e?i?function(){return j0(Ne(i)?i.call(this,this):i,Ne(e)?e.call(this,this):e)}:e:i}function k8(i,e){return Os(k1(i),k1(e))}function k1(i){if(Ee(i)){const e={};for(let t=0;t1)return t&&Ne(e)?e.call(n&&n.proxy):e}}function W8(i,e,t,n=!1){const r={},s={};Na(s,pl,1),i.propsDefaults=Object.create(null),Fh(i,e,r,s);for(const o in i.propsOptions[0])o in r||(r[o]=void 0);t?i.props=n?r:hh(r):i.type.props?i.props=r:i.props=s,i.attrs=s}function X8(i,e,t,n){const{props:r,attrs:s,vnode:{patchFlag:o}}=i,a=Ke(r),[l]=i.propsOptions;let c=!1;if((n||o>0)&&!(o&16)){if(o&8){const u=i.vnode.dynamicProps;for(let h=0;h{l=!0;const[f,d]=Ih(h,e,!0);j0(o,f),d&&a.push(...d)};!t&&e.mixins.length&&e.mixins.forEach(u),i.extends&&u(i.extends),i.mixins&&i.mixins.forEach(u)}if(!s&&!l)return l0(i)&&n.set(i,yr),yr;if(Ee(s))for(let u=0;u-1,d[1]=v<0||g-1||Ye(d,"default"))&&a.push(h)}}}const c=[o,a];return l0(i)&&n.set(i,c),c}function a2(i){return i[0]!=="$"}function l2(i){const e=i&&i.toString().match(/^\s*(function|class) (\w+)/);return e?e[2]:i===null?"null":""}function c2(i,e){return l2(i)===l2(e)}function u2(i,e){return Ee(e)?e.findIndex(t=>c2(t,i)):Ne(e)&&c2(e,i)?0:-1}const Dh=i=>i[0]==="_"||i==="$stable",kc=i=>Ee(i)?i.map(Wt):[Wt(i)],j8=(i,e,t)=>{if(e._n)return e;const n=Mr((...r)=>kc(e(...r)),t);return n._c=!1,n},Nh=(i,e,t)=>{const n=i._ctx;for(const r in i){if(Dh(r))continue;const s=i[r];if(Ne(s))e[r]=j8(r,s,n);else if(s!=null){const o=kc(s);e[r]=()=>o}}},Oh=(i,e)=>{const t=kc(e);i.slots.default=()=>t},Y8=(i,e)=>{if(i.vnode.shapeFlag&32){const t=e._;t?(i.slots=Ke(e),Na(e,"_",t)):Nh(e,i.slots={})}else i.slots={},e&&Oh(i,e);Na(i.slots,pl,1)},q8=(i,e,t)=>{const{vnode:n,slots:r}=i;let s=!0,o=f0;if(n.shapeFlag&32){const a=e._;a?t&&a===1?s=!1:(j0(r,e),!t&&a===1&&delete r._):(s=!e.$stable,Nh(e,r)),o=e}else e&&(Oh(i,e),o={default:1});if(s)for(const a in r)!Dh(a)&&o[a]==null&&delete r[a]};function H1(i,e,t,n,r=!1){if(Ee(i)){i.forEach((f,d)=>H1(f,e&&(Ee(e)?e[d]:e),t,n,r));return}if(La(n)&&!r)return;const s=n.shapeFlag&4?gl(n.component)||n.component.proxy:n.el,o=r?null:s,{i:a,r:l}=i,c=e&&e.r,u=a.refs===f0?a.refs={}:a.refs,h=a.setupState;if(c!=null&&c!==l&&(T0(c)?(u[c]=null,Ye(h,c)&&(h[c]=null)):F0(c)&&(c.value=null)),Ne(l))Hn(l,a,12,[o,u]);else{const f=T0(l),d=F0(l);if(f||d){const g=()=>{if(i.f){const v=f?Ye(h,l)?h[l]:u[l]:l.value;r?Ee(v)&&Sc(v,s):Ee(v)?v.includes(s)||v.push(s):f?(u[l]=[s],Ye(h,l)&&(h[l]=u[l])):(l.value=[s],i.k&&(u[i.k]=l.value))}else f?(u[l]=o,Ye(h,l)&&(h[l]=o)):d&&(l.value=o,i.k&&(u[i.k]=o))};o?(g.id=-1,ot(g,t)):g()}}}const ot=b8;function Q8(i){return K8(i)}function K8(i,e){const t=I1();t.__VUE__=!0;const{insert:n,remove:r,patchProp:s,createElement:o,createText:a,createComment:l,setText:c,setElementText:u,parentNode:h,nextSibling:f,setScopeId:d=Nt,insertStaticContent:g}=i,v=(M,E,F,W=null,X=null,T=null,S=!1,U=null,q=!!E.dynamicChildren)=>{if(M===E)return;M&&!xs(M,E)&&(W=V(M),ye(M,X,T,!0),M=null),E.patchFlag===-2&&(q=!1,E.dynamicChildren=null);const{type:H,ref:oe,shapeFlag:ue}=E;switch(H){case dl:_(M,E,F,W);break;case Ii:m(M,E,F,W);break;case Pa:M==null&&p(E,F,W,S);break;case U0:Y(M,E,F,W,X,T,S,U,q);break;default:ue&1?w(M,E,F,W,X,T,S,U,q):ue&6?O(M,E,F,W,X,T,S,U,q):(ue&64||ue&128)&&H.process(M,E,F,W,X,T,S,U,q,Q)}oe!=null&&X&&H1(oe,M&&M.ref,T,E||M,!E)},_=(M,E,F,W)=>{if(M==null)n(E.el=a(E.children),F,W);else{const X=E.el=M.el;E.children!==M.children&&c(X,E.children)}},m=(M,E,F,W)=>{M==null?n(E.el=l(E.children||""),F,W):E.el=M.el},p=(M,E,F,W)=>{[M.el,M.anchor]=g(M.children,E,F,W,M.el,M.anchor)},y=({el:M,anchor:E},F,W)=>{let X;for(;M&&M!==E;)X=f(M),n(M,F,W),M=X;n(E,F,W)},x=({el:M,anchor:E})=>{let F;for(;M&&M!==E;)F=f(M),r(M),M=F;r(E)},w=(M,E,F,W,X,T,S,U,q)=>{S=S||E.type==="svg",M==null?A(E,F,W,X,T,S,U,q):B(M,E,X,T,S,U,q)},A=(M,E,F,W,X,T,S,U)=>{let q,H;const{type:oe,props:ue,shapeFlag:he,transition:xe,dirs:ge}=M;if(q=M.el=o(M.type,T,ue&&ue.is,ue),he&8?u(q,M.children):he&16&&L(M.children,q,null,W,X,T&&oe!=="foreignObject",S,U),ge&&pi(M,null,W,"created"),b(q,M,M.scopeId,S,W),ue){for(const fe in ue)fe!=="value"&&!Aa(fe)&&s(q,fe,null,ue[fe],T,M.children,W,X,Z);"value"in ue&&s(q,"value",null,ue.value),(H=ue.onVnodeBeforeMount)&&Gt(H,W,M)}ge&&pi(M,null,W,"beforeMount");const z=Z8(X,xe);z&&xe.beforeEnter(q),n(q,E,F),((H=ue&&ue.onVnodeMounted)||z||ge)&&ot(()=>{H&&Gt(H,W,M),z&&xe.enter(q),ge&&pi(M,null,W,"mounted")},X)},b=(M,E,F,W,X)=>{if(F&&d(M,F),W)for(let T=0;T{for(let H=q;H{const U=E.el=M.el;let{patchFlag:q,dynamicChildren:H,dirs:oe}=E;q|=M.patchFlag&16;const ue=M.props||f0,he=E.props||f0;let xe;F&&mi(F,!1),(xe=he.onVnodeBeforeUpdate)&&Gt(xe,F,E,M),oe&&pi(E,M,F,"beforeUpdate"),F&&mi(F,!0);const ge=X&&E.type!=="foreignObject";if(H?I(M.dynamicChildren,H,U,F,W,ge,T):S||K(M,E,U,null,F,W,ge,T,!1),q>0){if(q&16)C(U,E,ue,he,F,W,X);else if(q&2&&ue.class!==he.class&&s(U,"class",null,he.class,X),q&4&&s(U,"style",ue.style,he.style,X),q&8){const z=E.dynamicProps;for(let fe=0;fe{xe&&Gt(xe,F,E,M),oe&&pi(E,M,F,"updated")},W)},I=(M,E,F,W,X,T,S)=>{for(let U=0;U{if(F!==W){if(F!==f0)for(const U in F)!Aa(U)&&!(U in W)&&s(M,U,F[U],null,S,E.children,X,T,Z);for(const U in W){if(Aa(U))continue;const q=W[U],H=F[U];q!==H&&U!=="value"&&s(M,U,H,q,S,E.children,X,T,Z)}"value"in W&&s(M,"value",F.value,W.value)}},Y=(M,E,F,W,X,T,S,U,q)=>{const H=E.el=M?M.el:a(""),oe=E.anchor=M?M.anchor:a("");let{patchFlag:ue,dynamicChildren:he,slotScopeIds:xe}=E;xe&&(U=U?U.concat(xe):xe),M==null?(n(H,F,W),n(oe,F,W),L(E.children,F,oe,X,T,S,U,q)):ue>0&&ue&64&&he&&M.dynamicChildren?(I(M.dynamicChildren,he,F,X,T,S,U),(E.key!=null||X&&E===X.subTree)&&Uh(M,E,!0)):K(M,E,F,oe,X,T,S,U,q)},O=(M,E,F,W,X,T,S,U,q)=>{E.slotScopeIds=U,M==null?E.shapeFlag&512?X.ctx.activate(E,F,W,S,q):G(E,F,W,X,T,S,q):j(M,E,q)},G=(M,E,F,W,X,T,S)=>{const U=M.component=o6(M,W,X);if(Lh(M)&&(U.ctx.renderer=Q),l6(U),U.asyncDep){if(X&&X.registerDep(U,N),!M.el){const q=U.subTree=je(Ii);m(null,q,E,F)}return}N(U,M,E,F,X,T,S)},j=(M,E,F)=>{const W=E.component=M.component;if(v8(M,E,F))if(W.asyncDep&&!W.asyncResolved){k(W,E,F);return}else W.next=E,c8(W.update),W.update();else E.el=M.el,W.vnode=E},N=(M,E,F,W,X,T,S)=>{const U=()=>{if(M.isMounted){let{next:oe,bu:ue,u:he,parent:xe,vnode:ge}=M,z=oe,fe;mi(M,!1),oe?(oe.el=ge.el,k(M,oe,S)):oe=ge,ue&&Ea(ue),(fe=oe.props&&oe.props.onVnodeBeforeUpdate)&&Gt(fe,xe,oe,ge),mi(M,!0);const ne=Ul(M),Te=M.subTree;M.subTree=ne,v(Te,ne,h(Te.el),V(Te),M,X,T),oe.el=ne.el,z===null&&x8(M,ne.el),he&&ot(he,X),(fe=oe.props&&oe.props.onVnodeUpdated)&&ot(()=>Gt(fe,xe,oe,ge),X)}else{let oe;const{el:ue,props:he}=E,{bm:xe,m:ge,parent:z}=M,fe=La(E);if(mi(M,!1),xe&&Ea(xe),!fe&&(oe=he&&he.onVnodeBeforeMount)&&Gt(oe,z,E),mi(M,!0),ue&&we){const ne=()=>{M.subTree=Ul(M),we(ue,M.subTree,M,X,null)};fe?E.type.__asyncLoader().then(()=>!M.isUnmounted&&ne()):ne()}else{const ne=M.subTree=Ul(M);v(null,ne,F,W,M,X,T),E.el=ne.el}if(ge&&ot(ge,X),!fe&&(oe=he&&he.onVnodeMounted)){const ne=E;ot(()=>Gt(oe,z,ne),X)}(E.shapeFlag&256||z&&La(z.vnode)&&z.vnode.shapeFlag&256)&&M.a&&ot(M.a,X),M.isMounted=!0,E=F=W=null}},q=M.effect=new Lc(U,()=>Nc(H),M.scope),H=M.update=()=>q.run();H.id=M.uid,mi(M,!0),H()},k=(M,E,F)=>{E.component=M;const W=M.vnode.props;M.vnode=E,M.next=null,X8(M,E.props,W,F),q8(M,E.children,F),Qr(),e2(),Kr()},K=(M,E,F,W,X,T,S,U,q=!1)=>{const H=M&&M.children,oe=M?M.shapeFlag:0,ue=E.children,{patchFlag:he,shapeFlag:xe}=E;if(he>0){if(he&128){ve(H,ue,F,W,X,T,S,U,q);return}else if(he&256){le(H,ue,F,W,X,T,S,U,q);return}}xe&8?(oe&16&&Z(H,X,T),ue!==H&&u(F,ue)):oe&16?xe&16?ve(H,ue,F,W,X,T,S,U,q):Z(H,X,T,!0):(oe&8&&u(F,""),xe&16&&L(ue,F,W,X,T,S,U,q))},le=(M,E,F,W,X,T,S,U,q)=>{M=M||yr,E=E||yr;const H=M.length,oe=E.length,ue=Math.min(H,oe);let he;for(he=0;heoe?Z(M,X,T,!0,!1,ue):L(E,F,W,X,T,S,U,q,ue)},ve=(M,E,F,W,X,T,S,U,q)=>{let H=0;const oe=E.length;let ue=M.length-1,he=oe-1;for(;H<=ue&&H<=he;){const xe=M[H],ge=E[H]=q?Nn(E[H]):Wt(E[H]);if(xs(xe,ge))v(xe,ge,F,null,X,T,S,U,q);else break;H++}for(;H<=ue&&H<=he;){const xe=M[ue],ge=E[he]=q?Nn(E[he]):Wt(E[he]);if(xs(xe,ge))v(xe,ge,F,null,X,T,S,U,q);else break;ue--,he--}if(H>ue){if(H<=he){const xe=he+1,ge=xehe)for(;H<=ue;)ye(M[H],X,T,!0),H++;else{const xe=H,ge=H,z=new Map;for(H=ge;H<=he;H++){const ke=E[H]=q?Nn(E[H]):Wt(E[H]);ke.key!=null&&z.set(ke.key,H)}let fe,ne=0;const Te=he-ge+1;let D=!1,_e=0;const Ie=new Array(Te);for(H=0;H=Te){ye(ke,X,T,!0);continue}let Oe;if(ke.key!=null)Oe=z.get(ke.key);else for(fe=ge;fe<=he;fe++)if(Ie[fe-ge]===0&&xs(ke,E[fe])){Oe=fe;break}Oe===void 0?ye(ke,X,T,!0):(Ie[Oe-ge]=H+1,Oe>=_e?_e=Oe:D=!0,v(ke,E[Oe],F,null,X,T,S,U,q),ne++)}const Ue=D?J8(Ie):yr;for(fe=Ue.length-1,H=Te-1;H>=0;H--){const ke=ge+H,Oe=E[ke],g0=ke+1{const{el:T,type:S,transition:U,children:q,shapeFlag:H}=M;if(H&6){ce(M.component.subTree,E,F,W);return}if(H&128){M.suspense.move(E,F,W);return}if(H&64){S.move(M,E,F,Q);return}if(S===U0){n(T,E,F);for(let ue=0;ueU.enter(T),X);else{const{leave:ue,delayLeave:he,afterLeave:xe}=U,ge=()=>n(T,E,F),z=()=>{ue(T,()=>{ge(),xe&&xe()})};he?he(T,ge,z):z()}else n(T,E,F)},ye=(M,E,F,W=!1,X=!1)=>{const{type:T,props:S,ref:U,children:q,dynamicChildren:H,shapeFlag:oe,patchFlag:ue,dirs:he}=M;if(U!=null&&H1(U,null,F,M,!0),oe&256){E.ctx.deactivate(M);return}const xe=oe&1&&he,ge=!La(M);let z;if(ge&&(z=S&&S.onVnodeBeforeUnmount)&&Gt(z,E,M),oe&6)me(M.component,F,W);else{if(oe&128){M.suspense.unmount(F,W);return}xe&&pi(M,null,E,"beforeUnmount"),oe&64?M.type.remove(M,E,F,X,Q,W):H&&(T!==U0||ue>0&&ue&64)?Z(H,E,F,!1,!0):(T===U0&&ue&384||!X&&oe&16)&&Z(q,E,F),W&&$(M)}(ge&&(z=S&&S.onVnodeUnmounted)||xe)&&ot(()=>{z&&Gt(z,E,M),xe&&pi(M,null,E,"unmounted")},F)},$=M=>{const{type:E,el:F,anchor:W,transition:X}=M;if(E===U0){se(F,W);return}if(E===Pa){x(M);return}const T=()=>{r(F),X&&!X.persisted&&X.afterLeave&&X.afterLeave()};if(M.shapeFlag&1&&X&&!X.persisted){const{leave:S,delayLeave:U}=X,q=()=>S(F,T);U?U(M.el,T,q):q()}else T()},se=(M,E)=>{let F;for(;M!==E;)F=f(M),r(M),M=F;r(E)},me=(M,E,F)=>{const{bum:W,scope:X,update:T,subTree:S,um:U}=M;W&&Ea(W),X.stop(),T&&(T.active=!1,ye(S,M,E,F)),U&&ot(U,E),ot(()=>{M.isUnmounted=!0},E),E&&E.pendingBranch&&!E.isUnmounted&&M.asyncDep&&!M.asyncResolved&&M.suspenseId===E.pendingId&&(E.deps--,E.deps===0&&E.resolve())},Z=(M,E,F,W=!1,X=!1,T=0)=>{for(let S=T;SM.shapeFlag&6?V(M.component.subTree):M.shapeFlag&128?M.suspense.next():f(M.anchor||M.el),te=(M,E,F)=>{M==null?E._vnode&&ye(E._vnode,null,null,!0):v(E._vnode||null,M,E,null,null,null,F),e2(),wh(),E._vnode=M},Q={p:v,um:ye,m:ce,r:$,mt:G,mc:L,pc:K,pbc:I,n:V,o:i};let re,we;return e&&([re,we]=e(Q)),{render:te,hydrate:re,createApp:V8(te,re)}}function mi({effect:i,update:e},t){i.allowRecurse=e.allowRecurse=t}function Z8(i,e){return(!i||i&&!i.pendingBranch)&&e&&!e.persisted}function Uh(i,e,t=!1){const n=i.children,r=e.children;if(Ee(n)&&Ee(r))for(let s=0;s>1,i[t[a]]0&&(e[n]=t[s-1]),t[s]=n)}}for(s=t.length,o=t[s-1];s-- >0;)t[s]=o,o=e[o];return t}const $8=i=>i.__isTeleport,U0=Symbol.for("v-fgt"),dl=Symbol.for("v-txt"),Ii=Symbol.for("v-cmt"),Pa=Symbol.for("v-stc"),Gs=[];let Ft=null;function Ge(i=!1){Gs.push(Ft=i?null:[])}function e6(){Gs.pop(),Ft=Gs[Gs.length-1]||null}let no=1;function h2(i){no+=i}function zh(i){return i.dynamicChildren=no>0?Ft||yr:null,e6(),no>0&&Ft&&Ft.push(i),i}function qe(i,e,t,n,r,s){return zh(de(i,e,t,n,r,s,!0))}function Gc(i,e,t,n,r){return zh(je(i,e,t,n,r,!0))}function V1(i){return i?i.__v_isVNode===!0:!1}function xs(i,e){return i.type===e.type&&i.key===e.key}const pl="__vInternal",Bh=({key:i})=>i??null,Ca=({ref:i,ref_key:e,ref_for:t})=>(typeof i=="number"&&(i=""+i),i!=null?T0(i)||F0(i)||Ne(i)?{i:dt,r:i,k:e,f:!!t}:i:null);function de(i,e=null,t=null,n=0,r=null,s=i===U0?0:1,o=!1,a=!1){const l={__v_isVNode:!0,__v_skip:!0,type:i,props:e,key:e&&Bh(e),ref:e&&Ca(e),scopeId:hl,slotScopeIds:null,children:t,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:s,patchFlag:n,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:dt};return a?(Hc(l,t),s&128&&i.normalize(l)):t&&(l.shapeFlag|=T0(t)?8:16),no>0&&!o&&Ft&&(l.patchFlag>0||s&6)&&l.patchFlag!==32&&Ft.push(l),l}const je=t6;function t6(i,e=null,t=null,n=0,r=null,s=!1){if((!i||i===Th)&&(i=Ii),V1(i)){const a=Cr(i,e,!0);return t&&Hc(a,t),no>0&&!s&&Ft&&(a.shapeFlag&6?Ft[Ft.indexOf(i)]=a:Ft.push(a)),a.patchFlag|=-2,a}if(d6(i)&&(i=i.__vccOpts),e){e=kh(e);let{class:a,style:l}=e;a&&!T0(a)&&(e.class=qn(a)),l0(l)&&(dh(l)&&!Ee(l)&&(l=j0({},l)),e.style=Fi(l))}const o=T0(i)?1:_8(i)?128:$8(i)?64:l0(i)?4:Ne(i)?2:0;return de(i,e,t,n,r,o,s,!0)}function kh(i){return i?dh(i)||pl in i?j0({},i):i:null}function Cr(i,e,t=!1){const{props:n,ref:r,patchFlag:s,children:o}=i,a=e?i6(n||{},e):n;return{__v_isVNode:!0,__v_skip:!0,type:i.type,props:a,key:a&&Bh(a),ref:e&&e.ref?t&&r?Ee(r)?r.concat(Ca(e)):[r,Ca(e)]:Ca(e):r,scopeId:i.scopeId,slotScopeIds:i.slotScopeIds,children:o,target:i.target,targetAnchor:i.targetAnchor,staticCount:i.staticCount,shapeFlag:i.shapeFlag,patchFlag:e&&i.type!==U0?s===-1?16:s|16:s,dynamicProps:i.dynamicProps,dynamicChildren:i.dynamicChildren,appContext:i.appContext,dirs:i.dirs,transition:i.transition,component:i.component,suspense:i.suspense,ssContent:i.ssContent&&Cr(i.ssContent),ssFallback:i.ssFallback&&Cr(i.ssFallback),el:i.el,anchor:i.anchor,ctx:i.ctx,ce:i.ce}}function Sr(i=" ",e=0){return je(dl,null,i,e)}function n6(i,e){const t=je(Pa,null,i);return t.staticCount=e,t}function ml(i="",e=!1){return e?(Ge(),Gc(Ii,null,i)):je(Ii,null,i)}function Wt(i){return i==null||typeof i=="boolean"?je(Ii):Ee(i)?je(U0,null,i.slice()):typeof i=="object"?Nn(i):je(dl,null,String(i))}function Nn(i){return i.el===null&&i.patchFlag!==-1||i.memo?i:Cr(i)}function Hc(i,e){let t=0;const{shapeFlag:n}=i;if(e==null)e=null;else if(Ee(e))t=16;else if(typeof e=="object")if(n&65){const r=e.default;r&&(r._c&&(r._d=!1),Hc(i,r()),r._c&&(r._d=!0));return}else{t=32;const r=e._;!r&&!(pl in e)?e._ctx=dt:r===3&&dt&&(dt.slots._===1?e._=1:(e._=2,i.patchFlag|=1024))}else Ne(e)?(e={default:e,_ctx:dt},t=32):(e=String(e),n&64?(t=16,e=[Sr(e)]):t=8);i.children=e,i.shapeFlag|=t}function i6(...i){const e={};for(let t=0;tz0||dt;let Vc,Hi,f2="__VUE_INSTANCE_SETTERS__";(Hi=I1()[f2])||(Hi=I1()[f2]=[]),Hi.push(i=>z0=i),Vc=i=>{Hi.length>1?Hi.forEach(e=>e(i)):Hi[0](i)};const Rr=i=>{Vc(i),i.scope.on()},Li=()=>{z0&&z0.scope.off(),Vc(null)};function Gh(i){return i.vnode.shapeFlag&4}let io=!1;function l6(i,e=!1){io=e;const{props:t,children:n}=i.vnode,r=Gh(i);W8(i,t,r,e),Y8(i,n);const s=r?c6(i,e):void 0;return io=!1,s}function c6(i,e){const t=i.type;i.accessCache=Object.create(null),i.proxy=Fc(new Proxy(i.ctx,O8));const{setup:n}=t;if(n){const r=i.setupContext=n.length>1?h6(i):null;Rr(i),Qr();const s=Hn(n,i,0,[i.props,r]);if(Kr(),Li(),Q3(s)){if(s.then(Li,Li),e)return s.then(o=>{d2(i,o,e)}).catch(o=>{cl(o,i,0)});i.asyncDep=s}else d2(i,s,e)}else Hh(i,e)}function d2(i,e,t){Ne(e)?i.type.__ssrInlineRender?i.ssrRender=e:i.render=e:l0(e)&&(i.setupState=vh(e)),Hh(i,t)}let p2;function Hh(i,e,t){const n=i.type;if(!i.render){if(!e&&p2&&!n.render){const r=n.template||Bc(i).template;if(r){const{isCustomElement:s,compilerOptions:o}=i.appContext.config,{delimiters:a,compilerOptions:l}=n,c=j0(j0({isCustomElement:s,delimiters:a},o),l);n.render=p2(r,c)}}i.render=n.render||Nt}{Rr(i),Qr();try{U8(i)}finally{Kr(),Li()}}}function u6(i){return i.attrsProxy||(i.attrsProxy=new Proxy(i.attrs,{get(e,t){return ct(i,"get","$attrs"),e[t]}}))}function h6(i){const e=t=>{i.exposed=t||{}};return{get attrs(){return u6(i)},slots:i.slots,emit:i.emit,expose:e}}function gl(i){if(i.exposed)return i.exposeProxy||(i.exposeProxy=new Proxy(vh(Fc(i.exposed)),{get(e,t){if(t in e)return e[t];if(t in Bs)return Bs[t](i)},has(e,t){return t in e||t in Bs}}))}function f6(i,e=!0){return Ne(i)?i.displayName||i.name:i.name||e&&i.__name}function d6(i){return Ne(i)&&"__vccOpts"in i}const Rt=(i,e)=>o8(i,e,io);function Vh(i,e,t){const n=arguments.length;return n===2?l0(e)&&!Ee(e)?V1(e)?je(i,null,[e]):je(i,e):je(i,null,e):(n>3?t=Array.prototype.slice.call(arguments,2):n===3&&V1(t)&&(t=[t]),je(i,e,t))}const p6=Symbol.for("v-scx"),m6=()=>nt(p6),g6="3.3.8",v6="http://www.w3.org/2000/svg",Si=typeof document<"u"?document:null,m2=Si&&Si.createElement("template"),x6={insert:(i,e,t)=>{e.insertBefore(i,t||null)},remove:i=>{const e=i.parentNode;e&&e.removeChild(i)},createElement:(i,e,t,n)=>{const r=e?Si.createElementNS(v6,i):Si.createElement(i,t?{is:t}:void 0);return i==="select"&&n&&n.multiple!=null&&r.setAttribute("multiple",n.multiple),r},createText:i=>Si.createTextNode(i),createComment:i=>Si.createComment(i),setText:(i,e)=>{i.nodeValue=e},setElementText:(i,e)=>{i.textContent=e},parentNode:i=>i.parentNode,nextSibling:i=>i.nextSibling,querySelector:i=>Si.querySelector(i),setScopeId(i,e){i.setAttribute(e,"")},insertStaticContent(i,e,t,n,r,s){const o=t?t.previousSibling:e.lastChild;if(r&&(r===s||r.nextSibling))for(;e.insertBefore(r.cloneNode(!0),t),!(r===s||!(r=r.nextSibling)););else{m2.innerHTML=n?`${i}`:i;const a=m2.content;if(n){const l=a.firstChild;for(;l.firstChild;)a.appendChild(l.firstChild);a.removeChild(l)}e.insertBefore(a,t)}return[o?o.nextSibling:e.firstChild,t?t.previousSibling:e.lastChild]}},y6=Symbol("_vtc");function _6(i,e,t){const n=i[y6];n&&(e=(e?[e,...n]:[...n]).join(" ")),e==null?i.removeAttribute("class"):t?i.setAttribute("class",e):i.className=e}const b6=Symbol("_vod");function w6(i,e,t){const n=i.style,r=T0(t);if(t&&!r){if(e&&!T0(e))for(const s in e)t[s]==null&&W1(n,s,"");for(const s in t)W1(n,s,t[s])}else{const s=n.display;r?e!==t&&(n.cssText=t):e&&i.removeAttribute("style"),b6 in i&&(n.display=s)}}const g2=/\s*!important$/;function W1(i,e,t){if(Ee(t))t.forEach(n=>W1(i,e,n));else if(t==null&&(t=""),e.startsWith("--"))i.setProperty(e,t);else{const n=M6(i,e);g2.test(t)?i.setProperty(qr(n),t.replace(g2,""),"important"):i[n]=t}}const v2=["Webkit","Moz","ms"],Bl={};function M6(i,e){const t=Bl[e];if(t)return t;let n=qt(e);if(n!=="filter"&&n in i)return Bl[e]=n;n=ol(n);for(let r=0;rkl||(P6.then(()=>kl=0),kl=Date.now());function R6(i,e){const t=n=>{if(!n._vts)n._vts=Date.now();else if(n._vts<=t.attached)return;Ot(F6(n,t.value),e,5,[n])};return t.value=i,t.attached=C6(),t}function F6(i,e){if(Ee(e)){const t=i.stopImmediatePropagation;return i.stopImmediatePropagation=()=>{t.call(i),i._stopped=!0},e.map(n=>r=>!r._stopped&&n&&n(r))}else return e}const b2=/^on[a-z]/,I6=(i,e,t,n,r=!1,s,o,a,l)=>{e==="class"?_6(i,n,r):e==="style"?w6(i,t,n):rl(e)?Mc(e)||E6(i,e,t,n,o):(e[0]==="."?(e=e.slice(1),!0):e[0]==="^"?(e=e.slice(1),!1):D6(i,e,n,r))?T6(i,e,n,s,o,a,l):(e==="true-value"?i._trueValue=n:e==="false-value"&&(i._falseValue=n),S6(i,e,n,r))};function D6(i,e,t,n){return n?!!(e==="innerHTML"||e==="textContent"||e in i&&b2.test(e)&&Ne(t)):e==="spellcheck"||e==="draggable"||e==="translate"||e==="form"||e==="list"&&i.tagName==="INPUT"||e==="type"&&i.tagName==="TEXTAREA"||b2.test(e)&&T0(t)?!1:e in i}const Fr=i=>{const e=i.props["onUpdate:modelValue"]||!1;return Ee(e)?t=>Ea(e,t):e};function N6(i){i.target.composing=!0}function w2(i){const e=i.target;e.composing&&(e.composing=!1,e.dispatchEvent(new Event("input")))}const pn=Symbol("_assign"),Tr={created(i,{modifiers:{lazy:e,trim:t,number:n}},r){i[pn]=Fr(r);const s=n||r.props&&r.props.type==="number";Un(i,e?"change":"input",o=>{if(o.target.composing)return;let a=i.value;t&&(a=a.trim()),s&&(a=Oa(a)),i[pn](a)}),t&&Un(i,"change",()=>{i.value=i.value.trim()}),e||(Un(i,"compositionstart",N6),Un(i,"compositionend",w2),Un(i,"change",w2))},mounted(i,{value:e}){i.value=e??""},beforeUpdate(i,{value:e,modifiers:{lazy:t,trim:n,number:r}},s){if(i[pn]=Fr(s),i.composing||document.activeElement===i&&i.type!=="range"&&(t||n&&i.value.trim()===e||(r||i.type==="number")&&Oa(i.value)===e))return;const o=e??"";i.value!==o&&(i.value=o)}},O6={deep:!0,created(i,e,t){i[pn]=Fr(t),Un(i,"change",()=>{const n=i._modelValue,r=ro(i),s=i.checked,o=i[pn];if(Ee(n)){const a=Ac(n,r),l=a!==-1;if(s&&!l)o(n.concat(r));else if(!s&&l){const c=[...n];c.splice(a,1),o(c)}}else if(Yr(n)){const a=new Set(n);s?a.add(r):a.delete(r),o(a)}else o(Wh(i,s))})},mounted:M2,beforeUpdate(i,e,t){i[pn]=Fr(t),M2(i,e,t)}};function M2(i,{value:e,oldValue:t},n){i._modelValue=e,Ee(e)?i.checked=Ac(e,n.props.value)>-1:Yr(e)?i.checked=e.has(n.props.value):e!==t&&(i.checked=Ao(e,Wh(i,!0)))}const U6={deep:!0,created(i,{value:e,modifiers:{number:t}},n){const r=Yr(e);Un(i,"change",()=>{const s=Array.prototype.filter.call(i.options,o=>o.selected).map(o=>t?Oa(ro(o)):ro(o));i[pn](i.multiple?r?new Set(s):s:s[0])}),i[pn]=Fr(n)},mounted(i,{value:e}){S2(i,e)},beforeUpdate(i,e,t){i[pn]=Fr(t)},updated(i,{value:e}){S2(i,e)}};function S2(i,e){const t=i.multiple;if(!(t&&!Ee(e)&&!Yr(e))){for(let n=0,r=i.options.length;n-1:s.selected=e.has(o);else if(Ao(ro(s),e)){i.selectedIndex!==n&&(i.selectedIndex=n);return}}!t&&i.selectedIndex!==-1&&(i.selectedIndex=-1)}}function ro(i){return"_value"in i?i._value:i.value}function Wh(i,e){const t=e?"_trueValue":"_falseValue";return t in i?i[t]:e}const z6=["ctrl","shift","alt","meta"],B6={stop:i=>i.stopPropagation(),prevent:i=>i.preventDefault(),self:i=>i.target!==i.currentTarget,ctrl:i=>!i.ctrlKey,shift:i=>!i.shiftKey,alt:i=>!i.altKey,meta:i=>!i.metaKey,left:i=>"button"in i&&i.button!==0,middle:i=>"button"in i&&i.button!==1,right:i=>"button"in i&&i.button!==2,exact:(i,e)=>z6.some(t=>i[`${t}Key`]&&!e.includes(t))},Xh=(i,e)=>(t,...n)=>{for(let r=0;r{const e=G6().createApp(...i),{mount:t}=e;return e.mount=n=>{const r=V6(n);if(!r)return;const s=e._component;!Ne(s)&&!s.render&&!s.template&&(s.template=r.innerHTML),r.innerHTML="";const o=t(r,!1,r instanceof SVGElement);return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),o},e};function V6(i){return T0(i)?document.querySelector(i):i}var W6=!1;/*! * pinia v2.1.7 * (c) 2023 Eduardo San Martin Morote * @license MIT - */const X6=Symbol();var A2;(function(i){i.direct="direct",i.patchObject="patch object",i.patchFunction="patch function"})(A2||(A2={}));function j6(){const i=Pd(!0),e=i.run(()=>P0({}));let t=[],n=[];const r=Rc({install(s){r._a=s,s.provide(X6,r),s.config.globalProperties.$pinia=r,n.forEach(o=>t.push(o)),n=[]},use(s){return!this._a&&!W6?n.push(s):t.push(s),this},_p:t,_a:null,_e:i,_s:new Map,state:e});return r}const Y6="/assets/logo-7e7c7361.svg";/*! + */const X6=Symbol();var A2;(function(i){i.direct="direct",i.patchObject="patch object",i.patchFunction="patch function"})(A2||(A2={}));function j6(){const i=Pd(!0),e=i.run(()=>P0({}));let t=[],n=[];const r=Fc({install(s){r._a=s,s.provide(X6,r),s.config.globalProperties.$pinia=r,n.forEach(o=>t.push(o)),n=[]},use(s){return!this._a&&!W6?n.push(s):t.push(s),this},_p:t,_a:null,_e:i,_s:new Map,state:e});return r}const Y6="/assets/logo-7e7c7361.svg";/*! * vue-router v4.2.5 * (c) 2023 Eduardo San Martin Morote * @license MIT - */const hr=typeof window<"u";function q6(i){return i.__esModule||i[Symbol.toStringTag]==="Module"}const i0=Object.assign;function kl(i,e){const t={};for(const n in e){const r=e[n];t[n]=zt(r)?r.map(i):i(r)}return t}const Hs=()=>{},zt=Array.isArray,Q6=/\/$/,Z6=i=>i.replace(Q6,"");function Gl(i,e,t="/"){let n,r={},s="",o="";const a=e.indexOf("#");let l=e.indexOf("?");return a=0&&(l=-1),l>-1&&(n=e.slice(0,l),s=e.slice(l+1,a>-1?a:e.length),r=i(s)),a>-1&&(n=n||e.slice(0,a),o=e.slice(a,e.length)),n=e7(n??e,t),{fullPath:n+(s&&"?")+s+o,path:n,query:r,hash:o}}function K6(i,e){const t=e.query?i(e.query):"";return e.path+(t&&"?")+t+(e.hash||"")}function E2(i,e){return!e||!i.toLowerCase().startsWith(e.toLowerCase())?i:i.slice(e.length)||"/"}function J6(i,e,t){const n=e.matched.length-1,r=t.matched.length-1;return n>-1&&n===r&&Fr(e.matched[n],t.matched[r])&&jh(e.params,t.params)&&i(e.query)===i(t.query)&&e.hash===t.hash}function Fr(i,e){return(i.aliasOf||i)===(e.aliasOf||e)}function jh(i,e){if(Object.keys(i).length!==Object.keys(e).length)return!1;for(const t in i)if(!$6(i[t],e[t]))return!1;return!0}function $6(i,e){return zt(i)?L2(i,e):zt(e)?L2(e,i):i===e}function L2(i,e){return zt(e)?i.length===e.length&&i.every((t,n)=>t===e[n]):i.length===1&&i[0]===e}function e7(i,e){if(i.startsWith("/"))return i;if(!i)return e;const t=e.split("/"),n=i.split("/"),r=n[n.length-1];(r===".."||r===".")&&n.push("");let s=t.length-1,o,a;for(o=0;o1&&s--;else break;return t.slice(0,s).join("/")+"/"+n.slice(o-(o===n.length?1:0)).join("/")}var so;(function(i){i.pop="pop",i.push="push"})(so||(so={}));var Vs;(function(i){i.back="back",i.forward="forward",i.unknown=""})(Vs||(Vs={}));function t7(i){if(!i)if(hr){const e=document.querySelector("base");i=e&&e.getAttribute("href")||"/",i=i.replace(/^\w+:\/\/[^\/]+/,"")}else i="/";return i[0]!=="/"&&i[0]!=="#"&&(i="/"+i),Z6(i)}const n7=/^[^#]+#/;function i7(i,e){return i.replace(n7,"#")+e}function r7(i,e){const t=document.documentElement.getBoundingClientRect(),n=i.getBoundingClientRect();return{behavior:e.behavior,left:n.left-t.left-(e.left||0),top:n.top-t.top-(e.top||0)}}const gl=()=>({left:window.pageXOffset,top:window.pageYOffset});function s7(i){let e;if("el"in i){const t=i.el,n=typeof t=="string"&&t.startsWith("#"),r=typeof t=="string"?n?document.getElementById(t.slice(1)):document.querySelector(t):t;if(!r)return;e=r7(r,i)}else e=i;"scrollBehavior"in document.documentElement.style?window.scrollTo(e):window.scrollTo(e.left!=null?e.left:window.pageXOffset,e.top!=null?e.top:window.pageYOffset)}function P2(i,e){return(history.state?history.state.position-e:-1)+i}const W1=new Map;function o7(i,e){W1.set(i,e)}function a7(i){const e=W1.get(i);return W1.delete(i),e}let l7=()=>location.protocol+"//"+location.host;function Yh(i,e){const{pathname:t,search:n,hash:r}=e,s=i.indexOf("#");if(s>-1){let a=r.includes(i.slice(s))?i.slice(s).length:1,l=r.slice(a);return l[0]!=="/"&&(l="/"+l),E2(l,"")}return E2(t,i)+n+r}function c7(i,e,t,n){let r=[],s=[],o=null;const a=({state:f})=>{const d=Yh(i,location),g=t.value,v=e.value;let _=0;if(f){if(t.value=d,e.value=f,o&&o===g){o=null;return}_=v?f.position-v.position:0}else n(d);r.forEach(m=>{m(t.value,g,{delta:_,type:so.pop,direction:_?_>0?Vs.forward:Vs.back:Vs.unknown})})};function l(){o=t.value}function c(f){r.push(f);const d=()=>{const g=r.indexOf(f);g>-1&&r.splice(g,1)};return s.push(d),d}function u(){const{history:f}=window;f.state&&f.replaceState(i0({},f.state,{scroll:gl()}),"")}function h(){for(const f of s)f();s=[],window.removeEventListener("popstate",a),window.removeEventListener("beforeunload",u)}return window.addEventListener("popstate",a),window.addEventListener("beforeunload",u,{passive:!0}),{pauseListeners:l,listen:c,destroy:h}}function C2(i,e,t,n=!1,r=!1){return{back:i,current:e,forward:t,replaced:n,position:window.history.length,scroll:r?gl():null}}function u7(i){const{history:e,location:t}=window,n={value:Yh(i,t)},r={value:e.state};r.value||s(n.value,{back:null,current:n.value,forward:null,position:e.length-1,replaced:!0,scroll:null},!0);function s(l,c,u){const h=i.indexOf("#"),f=h>-1?(t.host&&document.querySelector("base")?i:i.slice(h))+l:l7()+i+l;try{e[u?"replaceState":"pushState"](c,"",f),r.value=c}catch(d){console.error(d),t[u?"replace":"assign"](f)}}function o(l,c){const u=i0({},e.state,C2(r.value.back,l,r.value.forward,!0),c,{position:r.value.position});s(l,u,!0),n.value=l}function a(l,c){const u=i0({},r.value,e.state,{forward:l,scroll:gl()});s(u.current,u,!0);const h=i0({},C2(n.value,l,null),{position:u.position+1},c);s(l,h,!1),n.value=l}return{location:n,state:r,push:a,replace:o}}function h7(i){i=t7(i);const e=u7(i),t=c7(i,e.state,e.location,e.replace);function n(s,o=!0){o||t.pauseListeners(),history.go(s)}const r=i0({location:"",base:i,go:n,createHref:i7.bind(null,i)},e,t);return Object.defineProperty(r,"location",{enumerable:!0,get:()=>e.location.value}),Object.defineProperty(r,"state",{enumerable:!0,get:()=>e.state.value}),r}function f7(i){return typeof i=="string"||i&&typeof i=="object"}function qh(i){return typeof i=="string"||typeof i=="symbol"}const Sn={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},Qh=Symbol("");var R2;(function(i){i[i.aborted=4]="aborted",i[i.cancelled=8]="cancelled",i[i.duplicated=16]="duplicated"})(R2||(R2={}));function Ir(i,e){return i0(new Error,{type:i,[Qh]:!0},e)}function nn(i,e){return i instanceof Error&&Qh in i&&(e==null||!!(i.type&e))}const F2="[^/]+?",d7={sensitive:!1,strict:!1,start:!0,end:!0},p7=/[.+*?^${}()[\]/\\]/g;function m7(i,e){const t=i0({},d7,e),n=[];let r=t.start?"^":"";const s=[];for(const c of i){const u=c.length?[]:[90];t.strict&&!c.length&&(r+="/");for(let h=0;he.length?e.length===1&&e[0]===40+40?1:-1:0}function v7(i,e){let t=0;const n=i.score,r=e.score;for(;t0&&e[e.length-1]<0}const x7={type:0,value:""},y7=/[a-zA-Z0-9_]/;function _7(i){if(!i)return[[]];if(i==="/")return[[x7]];if(!i.startsWith("/"))throw new Error(`Invalid path "${i}"`);function e(d){throw new Error(`ERR (${t})/"${c}": ${d}`)}let t=0,n=t;const r=[];let s;function o(){s&&r.push(s),s=[]}let a=0,l,c="",u="";function h(){c&&(t===0?s.push({type:0,value:c}):t===1||t===2||t===3?(s.length>1&&(l==="*"||l==="+")&&e(`A repeatable param (${c}) must be alone in its segment. eg: '/:ids+.`),s.push({type:1,value:c,regexp:u,repeatable:l==="*"||l==="+",optional:l==="*"||l==="?"})):e("Invalid state to consume buffer"),c="")}function f(){c+=l}for(;a{o(p)}:Hs}function o(u){if(qh(u)){const h=n.get(u);h&&(n.delete(u),t.splice(t.indexOf(h),1),h.children.forEach(o),h.alias.forEach(o))}else{const h=t.indexOf(u);h>-1&&(t.splice(h,1),u.record.name&&n.delete(u.record.name),u.children.forEach(o),u.alias.forEach(o))}}function a(){return t}function l(u){let h=0;for(;h=0&&(u.record.path!==t[h].record.path||!Zh(u,t[h]));)h++;t.splice(h,0,u),u.record.name&&!N2(u)&&n.set(u.record.name,u)}function c(u,h){let f,d={},g,v;if("name"in u&&u.name){if(f=n.get(u.name),!f)throw Ir(1,{location:u});v=f.record.name,d=i0(D2(h.params,f.keys.filter(p=>!p.optional).map(p=>p.name)),u.params&&D2(u.params,f.keys.map(p=>p.name))),g=f.stringify(d)}else if("path"in u)g=u.path,f=t.find(p=>p.re.test(g)),f&&(d=f.parse(g),v=f.record.name);else{if(f=h.name?n.get(h.name):t.find(p=>p.re.test(h.path)),!f)throw Ir(1,{location:u,currentLocation:h});v=f.record.name,d=i0({},h.params,u.params),g=f.stringify(d)}const _=[];let m=f;for(;m;)_.unshift(m.record),m=m.parent;return{name:v,path:g,params:d,matched:_,meta:T7(_)}}return i.forEach(u=>s(u)),{addRoute:s,resolve:c,removeRoute:o,getRoutes:a,getRecordMatcher:r}}function D2(i,e){const t={};for(const n of e)n in i&&(t[n]=i[n]);return t}function M7(i){return{path:i.path,redirect:i.redirect,name:i.name,meta:i.meta||{},aliasOf:void 0,beforeEnter:i.beforeEnter,props:S7(i),children:i.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in i?i.components||null:i.component&&{default:i.component}}}function S7(i){const e={},t=i.props||!1;if("component"in i)e.default=t;else for(const n in i.components)e[n]=typeof t=="object"?t[n]:t;return e}function N2(i){for(;i;){if(i.record.aliasOf)return!0;i=i.parent}return!1}function T7(i){return i.reduce((e,t)=>i0(e,t.meta),{})}function O2(i,e){const t={};for(const n in i)t[n]=n in e?e[n]:i[n];return t}function Zh(i,e){return e.children.some(t=>t===i||Zh(i,t))}const Kh=/#/g,A7=/&/g,E7=/\//g,L7=/=/g,P7=/\?/g,Jh=/\+/g,C7=/%5B/g,R7=/%5D/g,$h=/%5E/g,F7=/%60/g,e4=/%7B/g,I7=/%7C/g,t4=/%7D/g,D7=/%20/g;function Wc(i){return encodeURI(""+i).replace(I7,"|").replace(C7,"[").replace(R7,"]")}function N7(i){return Wc(i).replace(e4,"{").replace(t4,"}").replace($h,"^")}function X1(i){return Wc(i).replace(Jh,"%2B").replace(D7,"+").replace(Kh,"%23").replace(A7,"%26").replace(F7,"`").replace(e4,"{").replace(t4,"}").replace($h,"^")}function O7(i){return X1(i).replace(L7,"%3D")}function U7(i){return Wc(i).replace(Kh,"%23").replace(P7,"%3F")}function z7(i){return i==null?"":U7(i).replace(E7,"%2F")}function Ha(i){try{return decodeURIComponent(""+i)}catch{}return""+i}function B7(i){const e={};if(i===""||i==="?")return e;const n=(i[0]==="?"?i.slice(1):i).split("&");for(let r=0;rs&&X1(s)):[n&&X1(n)]).forEach(s=>{s!==void 0&&(e+=(e.length?"&":"")+t,s!=null&&(e+="="+s))})}return e}function k7(i){const e={};for(const t in i){const n=i[t];n!==void 0&&(e[t]=zt(n)?n.map(r=>r==null?null:""+r):n==null?n:""+n)}return e}const G7=Symbol(""),z2=Symbol(""),Xc=Symbol(""),n4=Symbol(""),j1=Symbol("");function xs(){let i=[];function e(n){return i.push(n),()=>{const r=i.indexOf(n);r>-1&&i.splice(r,1)}}function t(){i=[]}return{add:e,list:()=>i.slice(),reset:t}}function On(i,e,t,n,r){const s=n&&(n.enterCallbacks[r]=n.enterCallbacks[r]||[]);return()=>new Promise((o,a)=>{const l=h=>{h===!1?a(Ir(4,{from:t,to:e})):h instanceof Error?a(h):f7(h)?a(Ir(2,{from:e,to:h})):(s&&n.enterCallbacks[r]===s&&typeof h=="function"&&s.push(h),o())},c=i.call(n&&n.instances[r],e,t,l);let u=Promise.resolve(c);i.length<3&&(u=u.then(l)),u.catch(h=>a(h))})}function Hl(i,e,t,n){const r=[];for(const s of i)for(const o in s.components){let a=s.components[o];if(!(e!=="beforeRouteEnter"&&!s.instances[o]))if(H7(a)){const c=(a.__vccOpts||a)[e];c&&r.push(On(c,t,n,s,o))}else{let l=a();r.push(()=>l.then(c=>{if(!c)return Promise.reject(new Error(`Couldn't resolve component "${o}" at "${s.path}"`));const u=q6(c)?c.default:c;s.components[o]=u;const f=(u.__vccOpts||u)[e];return f&&On(f,t,n,s,o)()}))}}return r}function H7(i){return typeof i=="object"||"displayName"in i||"props"in i||"__vccOpts"in i}function B2(i){const e=nt(Xc),t=nt(n4),n=Rt(()=>e.resolve(Gn(i.to))),r=Rt(()=>{const{matched:l}=n.value,{length:c}=l,u=l[c-1],h=t.matched;if(!u||!h.length)return-1;const f=h.findIndex(Fr.bind(null,u));if(f>-1)return f;const d=k2(l[c-2]);return c>1&&k2(u)===d&&h[h.length-1].path!==d?h.findIndex(Fr.bind(null,l[c-2])):f}),s=Rt(()=>r.value>-1&&j7(t.params,n.value.params)),o=Rt(()=>r.value>-1&&r.value===t.matched.length-1&&jh(t.params,n.value.params));function a(l={}){return X7(l)?e[Gn(i.replace)?"replace":"push"](Gn(i.to)).catch(Hs):Promise.resolve()}return{route:n,href:Rt(()=>n.value.href),isActive:s,isExactActive:o,navigate:a}}const V7=Le({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:B2,setup(i,{slots:e}){const t=ll(B2(i)),{options:n}=nt(Xc),r=Rt(()=>({[G2(i.activeClass,n.linkActiveClass,"router-link-active")]:t.isActive,[G2(i.exactActiveClass,n.linkExactActiveClass,"router-link-exact-active")]:t.isExactActive}));return()=>{const s=e.default&&e.default(t);return i.custom?s:Vh("a",{"aria-current":t.isExactActive?i.ariaCurrentValue:null,href:t.href,onClick:t.navigate,class:r.value},s)}}}),W7=V7;function X7(i){if(!(i.metaKey||i.altKey||i.ctrlKey||i.shiftKey)&&!i.defaultPrevented&&!(i.button!==void 0&&i.button!==0)){if(i.currentTarget&&i.currentTarget.getAttribute){const e=i.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(e))return}return i.preventDefault&&i.preventDefault(),!0}}function j7(i,e){for(const t in e){const n=e[t],r=i[t];if(typeof n=="string"){if(n!==r)return!1}else if(!zt(r)||r.length!==n.length||n.some((s,o)=>s!==r[o]))return!1}return!0}function k2(i){return i?i.aliasOf?i.aliasOf.path:i.path:""}const G2=(i,e,t)=>i??e??t,Y7=Le({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(i,{attrs:e,slots:t}){const n=nt(j1),r=Rt(()=>i.route||n.value),s=nt(z2,0),o=Rt(()=>{let c=Gn(s);const{matched:u}=r.value;let h;for(;(h=u[c])&&!h.components;)c++;return c}),a=Rt(()=>r.value.matched[o.value]);Bs(z2,Rt(()=>o.value+1)),Bs(G7,a),Bs(j1,r);const l=P0();return Ke(()=>[l.value,a.value,i.name],([c,u,h],[f,d,g])=>{u&&(u.instances[h]=c,d&&d!==u&&c&&c===f&&(u.leaveGuards.size||(u.leaveGuards=d.leaveGuards),u.updateGuards.size||(u.updateGuards=d.updateGuards))),c&&u&&(!d||!Fr(u,d)||!f)&&(u.enterCallbacks[h]||[]).forEach(v=>v(c))},{flush:"post"}),()=>{const c=r.value,u=i.name,h=a.value,f=h&&h.components[u];if(!f)return H2(t.default,{Component:f,route:c});const d=h.props[u],g=d?d===!0?c.params:typeof d=="function"?d(c):d:null,_=Vh(f,i0({},g,e,{onVnodeUnmounted:m=>{m.component.isUnmounted&&(h.instances[u]=null)},ref:l}));return H2(t.default,{Component:_,route:c})||_}}});function H2(i,e){if(!i)return null;const t=i(e);return t.length===1?t[0]:t}const i4=Y7;function q7(i){const e=w7(i.routes,i),t=i.parseQuery||B7,n=i.stringifyQuery||U2,r=i.history,s=xs(),o=xs(),a=xs(),l=$d(Sn);let c=Sn;hr&&i.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const u=kl.bind(null,V=>""+V),h=kl.bind(null,z7),f=kl.bind(null,Ha);function d(V,te){let Q,re;return qh(V)?(Q=e.getRecordMatcher(V),re=te):re=V,e.addRoute(re,Q)}function g(V){const te=e.getRecordMatcher(V);te&&e.removeRoute(te)}function v(){return e.getRoutes().map(V=>V.record)}function _(V){return!!e.getRecordMatcher(V)}function m(V,te){if(te=i0({},te||l.value),typeof V=="string"){const F=Gl(t,V,te.path),W=e.resolve({path:F.path},te),X=r.createHref(F.fullPath);return i0(F,W,{params:f(W.params),hash:Ha(F.hash),redirectedFrom:void 0,href:X})}let Q;if("path"in V)Q=i0({},V,{path:Gl(t,V.path,te.path).path});else{const F=i0({},V.params);for(const W in F)F[W]==null&&delete F[W];Q=i0({},V,{params:h(F)}),te.params=h(te.params)}const re=e.resolve(Q,te),we=V.hash||"";re.params=u(f(re.params));const M=K6(n,i0({},V,{hash:N7(we),path:re.path})),E=r.createHref(M);return i0({fullPath:M,hash:we,query:n===U2?k7(V.query):V.query||{}},re,{redirectedFrom:void 0,href:E})}function p(V){return typeof V=="string"?Gl(t,V,l.value.path):i0({},V)}function y(V,te){if(c!==V)return Ir(8,{from:te,to:V})}function x(V){return b(V)}function w(V){return x(i0(p(V),{replace:!0}))}function A(V){const te=V.matched[V.matched.length-1];if(te&&te.redirect){const{redirect:Q}=te;let re=typeof Q=="function"?Q(V):Q;return typeof re=="string"&&(re=re.includes("?")||re.includes("#")?re=p(re):{path:re},re.params={}),i0({query:V.query,hash:V.hash,params:"path"in re?{}:V.params},re)}}function b(V,te){const Q=c=m(V),re=l.value,we=V.state,M=V.force,E=V.replace===!0,F=A(Q);if(F)return b(i0(p(F),{state:typeof F=="object"?i0({},we,F.state):we,force:M,replace:E}),te||Q);const W=Q;W.redirectedFrom=te;let X;return!M&&J6(n,re,Q)&&(X=Ir(16,{to:W,from:re}),ce(re,re,!0,!1)),(X?Promise.resolve(X):I(W,re)).catch(T=>nn(T)?nn(T,2)?T:ve(T):Z(T,W,re)).then(T=>{if(T){if(nn(T,2))return b(i0({replace:E},p(T.to),{state:typeof T.to=="object"?i0({},we,T.to.state):we,force:M}),te||W)}else T=Y(W,re,!0,E,we);return C(W,re,T),T})}function L(V,te){const Q=y(V,te);return Q?Promise.reject(Q):Promise.resolve()}function B(V){const te=se.values().next().value;return te&&typeof te.runWithContext=="function"?te.runWithContext(V):V()}function I(V,te){let Q;const[re,we,M]=Q7(V,te);Q=Hl(re.reverse(),"beforeRouteLeave",V,te);for(const F of re)F.leaveGuards.forEach(W=>{Q.push(On(W,V,te))});const E=L.bind(null,V,te);return Q.push(E),K(Q).then(()=>{Q=[];for(const F of s.list())Q.push(On(F,V,te));return Q.push(E),K(Q)}).then(()=>{Q=Hl(we,"beforeRouteUpdate",V,te);for(const F of we)F.updateGuards.forEach(W=>{Q.push(On(W,V,te))});return Q.push(E),K(Q)}).then(()=>{Q=[];for(const F of M)if(F.beforeEnter)if(zt(F.beforeEnter))for(const W of F.beforeEnter)Q.push(On(W,V,te));else Q.push(On(F.beforeEnter,V,te));return Q.push(E),K(Q)}).then(()=>(V.matched.forEach(F=>F.enterCallbacks={}),Q=Hl(M,"beforeRouteEnter",V,te),Q.push(E),K(Q))).then(()=>{Q=[];for(const F of o.list())Q.push(On(F,V,te));return Q.push(E),K(Q)}).catch(F=>nn(F,8)?F:Promise.reject(F))}function C(V,te,Q){a.list().forEach(re=>B(()=>re(V,te,Q)))}function Y(V,te,Q,re,we){const M=y(V,te);if(M)return M;const E=te===Sn,F=hr?history.state:{};Q&&(re||E?r.replace(V.fullPath,i0({scroll:E&&F&&F.scroll},we)):r.push(V.fullPath,we)),l.value=V,ce(V,te,Q,E),ve()}let O;function G(){O||(O=r.listen((V,te,Q)=>{if(!pe.listening)return;const re=m(V),we=A(re);if(we){b(i0(we,{replace:!0}),re).catch(Hs);return}c=re;const M=l.value;hr&&o7(P2(M.fullPath,Q.delta),gl()),I(re,M).catch(E=>nn(E,12)?E:nn(E,2)?(b(E.to,re).then(F=>{nn(F,20)&&!Q.delta&&Q.type===so.pop&&r.go(-1,!1)}).catch(Hs),Promise.reject()):(Q.delta&&r.go(-Q.delta,!1),Z(E,re,M))).then(E=>{E=E||Y(re,M,!1),E&&(Q.delta&&!nn(E,8)?r.go(-Q.delta,!1):Q.type===so.pop&&nn(E,20)&&r.go(-1,!1)),C(re,M,E)}).catch(Hs)}))}let j=xs(),N=xs(),k;function Z(V,te,Q){ve(V);const re=N.list();return re.length?re.forEach(we=>we(V,te,Q)):console.error(V),Promise.reject(V)}function le(){return k&&l.value!==Sn?Promise.resolve():new Promise((V,te)=>{j.add([V,te])})}function ve(V){return k||(k=!V,G(),j.list().forEach(([te,Q])=>V?Q(V):te()),j.reset()),V}function ce(V,te,Q,re){const{scrollBehavior:we}=i;if(!hr||!we)return Promise.resolve();const M=!Q&&a7(P2(V.fullPath,0))||(re||!Q)&&history.state&&history.state.scroll||null;return _h().then(()=>we(V,te,M)).then(E=>E&&s7(E)).catch(E=>Z(E,V,te))}const ye=V=>r.go(V);let $;const se=new Set,pe={currentRoute:l,listening:!0,addRoute:d,removeRoute:g,hasRoute:_,getRoutes:v,resolve:m,options:i,push:x,replace:w,go:ye,back:()=>ye(-1),forward:()=>ye(1),beforeEach:s.add,beforeResolve:o.add,afterEach:a.add,onError:N.add,isReady:le,install(V){const te=this;V.component("RouterLink",W7),V.component("RouterView",i4),V.config.globalProperties.$router=te,Object.defineProperty(V.config.globalProperties,"$route",{enumerable:!0,get:()=>Gn(l)}),hr&&!$&&l.value===Sn&&($=!0,x(r.location).catch(we=>{}));const Q={};for(const we in Sn)Object.defineProperty(Q,we,{get:()=>l.value[we],enumerable:!0});V.provide(Xc,te),V.provide(n4,hh(Q)),V.provide(j1,l);const re=V.unmount;se.add(V),V.unmount=function(){se.delete(V),se.size<1&&(c=Sn,O&&O(),O=null,l.value=Sn,$=!1,k=!1),re()}}};function K(V){return V.reduce((te,Q)=>te.then(()=>B(Q)),Promise.resolve())}return pe}function Q7(i,e){const t=[],n=[],r=[],s=Math.max(e.matched.length,i.matched.length);for(let o=0;oFr(c,a))?n.push(a):t.push(a));const l=i.matched[o];l&&(e.matched.find(c=>Fr(c,l))||r.push(l))}return[t,n,r]}const _n=(i,e)=>{const t=i.__vccOpts||i;for(const[n,r]of e)t[n]=r;return t},Z7={},K7={xmlns:"http://www.w3.org/2000/svg",class:"icon icon-tabler icon-tabler-sun-high",width:"32",height:"32",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},J7=n6('',10),$7=[J7];function ep(i,e){return We(),Qe("svg",K7,$7)}const tp=_n(Z7,[["render",ep]]),np={},ip={xmlns:"http://www.w3.org/2000/svg",class:"icon icon-tabler icon-tabler-moon",width:"32",height:"32",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},rp=me("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null,-1),sp=me("path",{d:"M12 3c.132 0 .263 0 .393 0a7.5 7.5 0 0 0 7.92 12.446a9 9 0 1 1 -8.313 -12.454z"},null,-1),op=[rp,sp];function ap(i,e){return We(),Qe("svg",ip,op)}const lp=_n(np,[["render",ap]]);const cp={__name:"DarkMode",setup(i){const e=P0(!0);function t(){window.matchMedia&&window.matchMedia("(prefers-color-scheme:dark)").matches?e.value=!0:e.value=!1}t();function n(){e.value=!e.value,e.value?(document.documentElement.style.setProperty("--color-background","var(--vt-c-black)"),document.documentElement.style.setProperty("--color-background-soft","var(--vt-c-black-soft);"),document.documentElement.style.setProperty("--color-background-mute","var(--vt-c-black-mute)"),document.documentElement.style.setProperty("--color-border","var(--vt-c-divider-dark-2)"),document.documentElement.style.setProperty("--color-border-hover","var(--vt-c-divider-dark-1)"),document.documentElement.style.setProperty("--color-heading","var(--vt-c-text-dark-1)"),document.documentElement.style.setProperty("--color-text","var(--vt-c-text-dark-2)")):(document.documentElement.style.setProperty("--color-background","var(--vt-c-white)"),document.documentElement.style.setProperty("--color-background-soft","var(--vt-c-white-soft);"),document.documentElement.style.setProperty("--color-background-mute","var(--vt-c-white-mute)"),document.documentElement.style.setProperty("--color-border","var(--vt-c-divider-light-2)"),document.documentElement.style.setProperty("--color-border-hover","var(--vt-c-divider-light-1)"),document.documentElement.style.setProperty("--color-heading","var(--vt-c-text-light-1)"),document.documentElement.style.setProperty("--color-text","var(--vt-c-text-light-2)"))}return(r,s)=>e.value?(We(),Qe("button",{key:0,onClick:n,class:"iconButton"},[je(tp)])):(We(),Qe("button",{key:1,onClick:n,class:"iconButton"},[je(lp)]))}},up={},hp={xmlns:"http://www.w3.org/2000/svg",class:"icon icon-tabler icon-tabler-chevron-up",width:"32",height:"32",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},fp=me("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null,-1),dp=me("path",{d:"M6 15l6 -6l6 6"},null,-1),pp=[fp,dp];function mp(i,e){return We(),Qe("svg",hp,pp)}const gp=_n(up,[["render",mp]]);const vp={__name:"ToTopButton",setup(i){const e=P0(!1);window.onscroll=function(){t()};function t(){document.body.scrollTop>20||document.documentElement.scrollTop>20?e.value=!0:e.value=!1}function n(){window.scrollTo({top:0,behavior:"smooth"})}return(r,s)=>e.value?(We(),Qe("button",{key:0,onClick:n,class:"iconButton"},[je(gp)])):Gc("",!0)}};const xp={class:"iconButton"},yp={__name:"ThemePicker",setup(i){const e=P0("#00916E");function t(){document.documentElement.style.setProperty("--color-highlight",e.value)}return(n,r)=>(We(),Qe("div",xp,[Bn(me("input",{"onUpdate:modelValue":r[0]||(r[0]=s=>e.value=s),type:"color",id:"colorPicker",name:"highlightColor",onChange:r[1]||(r[1]=s=>t())},null,544),[[Sr,e.value]])]))}};const _p={class:"iconBar"},bp={__name:"IconBar",setup(i){return(e,t)=>(We(),Qe("div",_p,[je(vp),je(yp),je(cp)]))}};const wp=me("div",{class:"bar1"},null,-1),Mp=me("div",{class:"bar2"},null,-1),Sp=me("div",{class:"bar3"},null,-1),Tp=[wp,Mp,Sp],Ap={__name:"HamburgerMenu",setup(i){const e=P0("0%"),t=P0(!1);function n(){t.value=!t.value}function r(){n(),e.value=e.value==="0%"?"100%":"0%",document.body.style.overflow=document.body.style.overflow==="hidden"?"auto":"hidden"}return(s,o)=>(We(),Qe(W0,null,[me("div",{class:qn(["hamburger",{opened:t.value}]),onClick:r},Tp,2),me("div",{id:"myNav",class:"overlay",style:Fi({height:e.value})},[me("nav",{id:"test",class:"overlayContent"},[me("a",{onClick:r,href:"#section1"},"Start"),me("a",{onClick:r,href:"#section2"},"Über mich"),me("a",{onClick:r,href:"#section3"},"Meine Projekte"),me("a",{onClick:r,href:"#section4"},"Meine Skills"),me("a",{onClick:r,href:"#section5"},"Galerie"),me("a",{onClick:r,href:"#section6"},"3D-Model"),me("a",{onClick:r,href:"#section7"},"Kontakt")])],4)],64))}};const Ep={class:"progressContainer"},Lp=me("div",{class:"progressBar",id:"myBar"},null,-1),Pp=[Lp],Cp={__name:"ProgressBar",setup(i){return window.addEventListener("scroll",()=>{var e=document.body.scrollTop||document.documentElement.scrollTop,t=document.documentElement.scrollHeight-document.documentElement.clientHeight,n=e/t*100;document.getElementById("myBar").style.width=n+"%"}),(e,t)=>(We(),Qe("div",Ep,Pp))}};const Rp={class:"footer"},Fp={__name:"Footer",setup(i){function e(){window.scrollTo({top:0,behavior:"smooth"})}return(t,n)=>{const r=yi("RouterLink");return We(),Qe("div",Rp,[je(r,{onClick:e,to:"/"},{default:Mr(()=>[Gs("Home")]),_:1}),je(r,{onClick:e,to:"/impressum"},{default:Mr(()=>[Gs("Impressum")]),_:1}),je(r,{onClick:e,to:"/datenschutz"},{default:Mr(()=>[Gs("Datenschutz")]),_:1})])}}};const jc=i=>(d8("data-v-1d3973aa"),i=i(),p8(),i),Ip={class:"navBar"},Dp=jc(()=>me("img",{alt:"Vue logo",class:"logo",src:Y6,width:"48",height:"48"},null,-1)),Np=jc(()=>me("h1",null,"Portfolio",-1)),Op=jc(()=>me("div",{class:"break"},null,-1)),Up={__name:"App",setup(i){return(e,t)=>(We(),Qe(W0,null,[me("header",null,[me("div",Ip,[Dp,Np,je(Ap)]),Op,je(Cp)]),je(bp),je(Gn(i4)),je(Fp)],64))}},zp=_n(Up,[["__scopeId","data-v-1d3973aa"]]),Bp="modulepreload",kp=function(i){return"/"+i},V2={},W2=function(e,t,n){if(!t||t.length===0)return e();const r=document.getElementsByTagName("link");return Promise.all(t.map(s=>{if(s=kp(s),s in V2)return;V2[s]=!0;const o=s.endsWith(".css"),a=o?'[rel="stylesheet"]':"";if(!!n)for(let u=r.length-1;u>=0;u--){const h=r[u];if(h.href===s&&(!o||h.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${s}"]${a}`))return;const c=document.createElement("link");if(c.rel=o?"stylesheet":Bp,o||(c.as="script",c.crossOrigin=""),c.href=s,document.head.appendChild(c),o)return new Promise((u,h)=>{c.addEventListener("load",u),c.addEventListener("error",()=>h(new Error(`Unable to preload CSS for ${s}`)))})})).then(()=>e()).catch(s=>{const o=new Event("vite:preloadError",{cancelable:!0});if(o.payload=s,window.dispatchEvent(o),!o.defaultPrevented)throw s})};const Gp={data(){return{images:[{id:1,src:"/img/arbeit.jpg"},{id:2,src:"/img/baum.jpg"},{id:3,src:"/img/strasse.jpg"},{id:4,src:"/img/eishoehle.jpg"},{id:5,src:"/img/fastfood.jpg"},{id:6,src:"/img/eule.jpg"},{id:7,src:"/img/lightroom.jpg"},{id:8,src:"/img/kamera.jpg"},{id:9,src:"/img/leuchtreklame.jpg"},{id:10,src:"/img/schachbrett.jpg"},{id:11,src:"/img/pinsel.jpg"},{id:12,src:"/img/mischpult.jpg"},{id:13,src:"/img/drohne.jpg"},{id:14,src:"/img/glasfaser.jpg"}],imageIdCounter:14,isHovered:null}},computed:{imageGroups(){return this.calculateImageGroups()}},methods:{calculateImageGroups(){const i=[],e=this.images.length,t=4,n=Math.ceil(e/t);for(let r=0;rt.id===i);e!==-1&&(this.images.splice(e,1),this.isHovered=null,this.updateImageGroups())},addNewImage(i){const e=i.target.files;if(e.length===0)return;const t=new FileReader;t.onload=()=>{const n=t.result;this.imageIdCounter++;const r={id:this.imageIdCounter,src:n,alt:"Neues Bild"};this.images.push(r),this.updateImageGroups()},t.readAsDataURL(e[0])},updateImageGroups(){this.$nextTick(()=>{this.images.sort((i,e)=>i.src.localeCompare(e.src)),this.$forceUpdate()})}}},Hp={class:"column"},Vp=["onMouseover"],Wp=["src","alt"],Xp={key:0,class:"imgOverlay"},jp=["onClick"],Yp={class:"row"},qp=me("label",{for:"fileInput",class:"custom-file-upload"},[me("span",{style:{"font-weight":"bold"}},"HINZUFÜGEN: (+)")],-1);function Qp(i,e,t,n,r,s){return We(),Qe("div",Hp,[(We(!0),Qe(W0,null,to(s.imageGroups,(o,a)=>(We(),Qe("div",{key:a,class:"row"},[(We(!0),Qe(W0,null,to(o,(l,c)=>(We(),Qe("div",{key:l.id,class:"image-container",onMouseover:u=>s.highlightImage(l.id)},[me("img",{src:l.src,alt:l.alt},null,8,Wp),r.isHovered===l.id?(We(),Qe("div",Xp,[me("span",{onClick:u=>s.deleteImage(l.id),class:"delete-icon"},"X",8,jp)])):Gc("",!0)],40,Vp))),128))]))),128)),me("div",Yp,[me("input",{type:"file",id:"fileInput",onChange:e[0]||(e[0]=(...o)=>s.addNewImage&&s.addNewImage(...o)),style:{display:"none"}},null,32),qp])])}const X2=_n(Gp,[["render",Qp]]);const Zp={class:"contact-form"},Kp=me("h2",null,"Kontaktformular",-1),Jp=["onSubmit"],$p={class:"form-group"},em={class:"form-group"},tm={class:"nachricht"},nm={class:"datenschutz"},im=["disabled"],j2={__name:"Contact",setup(i){const e=P0(""),t=P0(""),n=P0(""),r=P0(!1);function s(){r.value?(console.log("Formular abgeschickt:",{name:e.value,email:t.value,message:n.value}),e.value="",t.value="",n.value="",r.value=!1):alert("Bitte bestätigen Sie die Datenschutzerklärung.")}return(o,a)=>(We(),Qe("div",Zp,[Kp,me("form",{onSubmit:Xh(s,["prevent"])},[me("div",$p,[Bn(me("input",{placeholder:"Name",type:"text",id:"name","onUpdate:modelValue":a[0]||(a[0]=l=>e.value=l),required:""},null,512),[[Sr,e.value]])]),me("div",em,[Bn(me("input",{placeholder:"E-Mail",type:"email",id:"email","onUpdate:modelValue":a[1]||(a[1]=l=>t.value=l),required:""},null,512),[[Sr,t.value]])]),me("div",tm,[Bn(me("textarea",{placeholder:"Nachricht",id:"message","onUpdate:modelValue":a[2]||(a[2]=l=>n.value=l),rows:"5",required:""},null,512),[[Sr,n.value]])]),me("div",nm,[me("label",null,[Bn(me("input",{type:"checkbox","onUpdate:modelValue":a[3]||(a[3]=l=>r.value=l),required:""},null,512),[[O6,r.value]]),Gs(" Ich bestätige die Datenschutzerklärung. ")])]),me("button",{type:"submit",disabled:!r.value},"Absenden",8,im)],40,Jp)]))}};const rm={},sm={class:"tiltingCard"},om=me("div",{class:"mousePositionTracker"},[me("div"),me("div"),me("div"),me("div"),me("div"),me("div"),me("div"),me("div"),me("div")],-1),am=[om];function lm(i,e){return We(),Qe("div",sm,am)}const cm=_n(rm,[["render",lm]]);const um={class:"hero"},hm=me("div",{class:"heroText"},[me("h2",{contenteditable:"true"},"Hi, mein Name ist Lorem Ipsum."),me("p",{contenteditable:"true"},"Ich erstelle Sachen"),me("button",{onclick:"window.location.href='#section6';"},"Nimm Kontakt auf!")],-1),Y2={__name:"Hero",setup(i){return(e,t)=>(We(),Qe("div",um,[hm,me("div",null,[je(cm)])]))}};const fm={},dm={class:"cardContainer"},pm={id:"card1",class:"card"},mm={class:"cardBody",contenteditable:"true",ref:"editableContent"},gm=me("h2",{class:"cardTitle"},"Etwas tolles",-1),vm=me("p",null,"Lorem ipsum, dolor sit amet consectetur adipisicing elit. Fuga placeat odio pariatur doloribus sint?",-1),xm=me("a",{href:"#",class:"button"},"Mehr erfahren",-1),ym=[gm,vm,xm],_m={id:"card2",class:"card"},bm={class:"cardBody",contenteditable:"true",ref:"editableContent"},wm=me("h2",{class:"cardTitle"},"Etwas spannendes",-1),Mm=me("p",null,"Lorem ipsum, dolor sit amet consectetur adipisicing elit. Fuga placeat odio pariatur doloribus sint?",-1),Sm=me("a",{href:"#",class:"button"},"Mehr erfahren",-1),Tm=[wm,Mm,Sm],Am={id:"card3",class:"card"},Em={class:"cardBody",contenteditable:"true",ref:"editableContent"},Lm=me("h2",{class:"cardTitle"},"Etwas interessantes",-1),Pm=me("p",null,"Lorem ipsum, dolor sit amet consectetur adipisicing elit. Fuga placeat odio pariatur doloribus sint?",-1),Cm=me("a",{href:"#",class:"button"},"Mehr erfahren",-1),Rm=[Lm,Pm,Cm],Fm={id:"card4",class:"card"},Im={class:"cardBody",contenteditable:"true",ref:"editableContent"},Dm=me("h2",{class:"cardTitle"},"Etwas lustiges",-1),Nm=me("p",null,"Lorem ipsum, dolor sit amet consectetur adipisicing elit. Fuga placeat odio pariatur doloribus sint?",-1),Om=me("a",{href:"#",class:"button"},"Mehr erfahren",-1),Um=[Dm,Nm,Om];function zm(i,e){return We(),Qe("div",dm,[me("div",pm,[me("div",mm,ym,512)]),me("div",_m,[me("div",bm,Tm,512)]),me("div",Am,[me("div",Em,Rm,512)]),me("div",Fm,[me("div",Im,Um,512)])])}const q2=_n(fm,[["render",zm]]);const Bm={class:"skillContainer"},km=me("div",{class:"CreatorBar1"},null,-1),Gm=me("div",{class:"CreatorBar2"},null,-1),Hm=[km,Gm],Vm=me("h3",{style:{margin:"32px 0 8px 0"}},"Neuen Skill anlegen:",-1),Wm={class:"skillContainer"},Xm=["onSubmit"],jm=me("button",null,"Erstellen",-1),Q2={__name:"Skills",setup(i){const e=P0(!1),t=P0(50),n=P0(""),r=P0([{text:"HTML",percetage:"77"},{text:"CSS",percetage:"86"},{text:"JavaScript",percetage:"65"}]);function s(){r.value.push({text:n.value,percetage:t.value}),t.value=50,n.value=""}function o(){e.value=!e.value}return(a,l)=>(We(),Qe(W0,null,[(We(!0),Qe(W0,null,to(r.value,c=>(We(),Qe("div",Bm,[me("div",{class:"skill",style:Fi({width:c.percetage+"%"})},[me("p",null,pr(c.text),1),me("p",null,pr(c.percetage)+"%",1)],4)]))),256)),me("div",{class:qn(["skillCreator",{create:e.value}]),onClick:o},Hm,2),me("div",{class:qn(["skillAnlegen",{newSkill:e.value}])},[Vm,me("div",Wm,[me("div",{class:"skill",style:Fi({width:t.value+"%"})},[me("p",null,pr(n.value),1),me("p",null,pr(t.value)+"%",1)],4)]),me("form",{onSubmit:Xh(s,["prevent"]),style:{display:"block"}},[Bn(me("input",{"onUpdate:modelValue":l[0]||(l[0]=c=>t.value=c),type:"range",min:"0",max:"100",class:"slider"},null,512),[[Sr,t.value]]),Bn(me("input",{type:"text","onUpdate:modelValue":l[1]||(l[1]=c=>n.value=c),placeholder:"Bezeichnung",style:{"max-width":"50%","margin-right":"8px"}},null,512),[[Sr,n.value]]),jm],40,Xm)],2)],64))}};/** + */const hr=typeof window<"u";function q6(i){return i.__esModule||i[Symbol.toStringTag]==="Module"}const i0=Object.assign;function Gl(i,e){const t={};for(const n in e){const r=e[n];t[n]=zt(r)?r.map(i):i(r)}return t}const Hs=()=>{},zt=Array.isArray,Q6=/\/$/,K6=i=>i.replace(Q6,"");function Hl(i,e,t="/"){let n,r={},s="",o="";const a=e.indexOf("#");let l=e.indexOf("?");return a=0&&(l=-1),l>-1&&(n=e.slice(0,l),s=e.slice(l+1,a>-1?a:e.length),r=i(s)),a>-1&&(n=n||e.slice(0,a),o=e.slice(a,e.length)),n=e7(n??e,t),{fullPath:n+(s&&"?")+s+o,path:n,query:r,hash:o}}function Z6(i,e){const t=e.query?i(e.query):"";return e.path+(t&&"?")+t+(e.hash||"")}function E2(i,e){return!e||!i.toLowerCase().startsWith(e.toLowerCase())?i:i.slice(e.length)||"/"}function J6(i,e,t){const n=e.matched.length-1,r=t.matched.length-1;return n>-1&&n===r&&Ir(e.matched[n],t.matched[r])&&jh(e.params,t.params)&&i(e.query)===i(t.query)&&e.hash===t.hash}function Ir(i,e){return(i.aliasOf||i)===(e.aliasOf||e)}function jh(i,e){if(Object.keys(i).length!==Object.keys(e).length)return!1;for(const t in i)if(!$6(i[t],e[t]))return!1;return!0}function $6(i,e){return zt(i)?L2(i,e):zt(e)?L2(e,i):i===e}function L2(i,e){return zt(e)?i.length===e.length&&i.every((t,n)=>t===e[n]):i.length===1&&i[0]===e}function e7(i,e){if(i.startsWith("/"))return i;if(!i)return e;const t=e.split("/"),n=i.split("/"),r=n[n.length-1];(r===".."||r===".")&&n.push("");let s=t.length-1,o,a;for(o=0;o1&&s--;else break;return t.slice(0,s).join("/")+"/"+n.slice(o-(o===n.length?1:0)).join("/")}var so;(function(i){i.pop="pop",i.push="push"})(so||(so={}));var Vs;(function(i){i.back="back",i.forward="forward",i.unknown=""})(Vs||(Vs={}));function t7(i){if(!i)if(hr){const e=document.querySelector("base");i=e&&e.getAttribute("href")||"/",i=i.replace(/^\w+:\/\/[^\/]+/,"")}else i="/";return i[0]!=="/"&&i[0]!=="#"&&(i="/"+i),K6(i)}const n7=/^[^#]+#/;function i7(i,e){return i.replace(n7,"#")+e}function r7(i,e){const t=document.documentElement.getBoundingClientRect(),n=i.getBoundingClientRect();return{behavior:e.behavior,left:n.left-t.left-(e.left||0),top:n.top-t.top-(e.top||0)}}const vl=()=>({left:window.pageXOffset,top:window.pageYOffset});function s7(i){let e;if("el"in i){const t=i.el,n=typeof t=="string"&&t.startsWith("#"),r=typeof t=="string"?n?document.getElementById(t.slice(1)):document.querySelector(t):t;if(!r)return;e=r7(r,i)}else e=i;"scrollBehavior"in document.documentElement.style?window.scrollTo(e):window.scrollTo(e.left!=null?e.left:window.pageXOffset,e.top!=null?e.top:window.pageYOffset)}function P2(i,e){return(history.state?history.state.position-e:-1)+i}const X1=new Map;function o7(i,e){X1.set(i,e)}function a7(i){const e=X1.get(i);return X1.delete(i),e}let l7=()=>location.protocol+"//"+location.host;function Yh(i,e){const{pathname:t,search:n,hash:r}=e,s=i.indexOf("#");if(s>-1){let a=r.includes(i.slice(s))?i.slice(s).length:1,l=r.slice(a);return l[0]!=="/"&&(l="/"+l),E2(l,"")}return E2(t,i)+n+r}function c7(i,e,t,n){let r=[],s=[],o=null;const a=({state:f})=>{const d=Yh(i,location),g=t.value,v=e.value;let _=0;if(f){if(t.value=d,e.value=f,o&&o===g){o=null;return}_=v?f.position-v.position:0}else n(d);r.forEach(m=>{m(t.value,g,{delta:_,type:so.pop,direction:_?_>0?Vs.forward:Vs.back:Vs.unknown})})};function l(){o=t.value}function c(f){r.push(f);const d=()=>{const g=r.indexOf(f);g>-1&&r.splice(g,1)};return s.push(d),d}function u(){const{history:f}=window;f.state&&f.replaceState(i0({},f.state,{scroll:vl()}),"")}function h(){for(const f of s)f();s=[],window.removeEventListener("popstate",a),window.removeEventListener("beforeunload",u)}return window.addEventListener("popstate",a),window.addEventListener("beforeunload",u,{passive:!0}),{pauseListeners:l,listen:c,destroy:h}}function C2(i,e,t,n=!1,r=!1){return{back:i,current:e,forward:t,replaced:n,position:window.history.length,scroll:r?vl():null}}function u7(i){const{history:e,location:t}=window,n={value:Yh(i,t)},r={value:e.state};r.value||s(n.value,{back:null,current:n.value,forward:null,position:e.length-1,replaced:!0,scroll:null},!0);function s(l,c,u){const h=i.indexOf("#"),f=h>-1?(t.host&&document.querySelector("base")?i:i.slice(h))+l:l7()+i+l;try{e[u?"replaceState":"pushState"](c,"",f),r.value=c}catch(d){console.error(d),t[u?"replace":"assign"](f)}}function o(l,c){const u=i0({},e.state,C2(r.value.back,l,r.value.forward,!0),c,{position:r.value.position});s(l,u,!0),n.value=l}function a(l,c){const u=i0({},r.value,e.state,{forward:l,scroll:vl()});s(u.current,u,!0);const h=i0({},C2(n.value,l,null),{position:u.position+1},c);s(l,h,!1),n.value=l}return{location:n,state:r,push:a,replace:o}}function h7(i){i=t7(i);const e=u7(i),t=c7(i,e.state,e.location,e.replace);function n(s,o=!0){o||t.pauseListeners(),history.go(s)}const r=i0({location:"",base:i,go:n,createHref:i7.bind(null,i)},e,t);return Object.defineProperty(r,"location",{enumerable:!0,get:()=>e.location.value}),Object.defineProperty(r,"state",{enumerable:!0,get:()=>e.state.value}),r}function f7(i){return typeof i=="string"||i&&typeof i=="object"}function qh(i){return typeof i=="string"||typeof i=="symbol"}const Sn={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},Qh=Symbol("");var R2;(function(i){i[i.aborted=4]="aborted",i[i.cancelled=8]="cancelled",i[i.duplicated=16]="duplicated"})(R2||(R2={}));function Dr(i,e){return i0(new Error,{type:i,[Qh]:!0},e)}function nn(i,e){return i instanceof Error&&Qh in i&&(e==null||!!(i.type&e))}const F2="[^/]+?",d7={sensitive:!1,strict:!1,start:!0,end:!0},p7=/[.+*?^${}()[\]/\\]/g;function m7(i,e){const t=i0({},d7,e),n=[];let r=t.start?"^":"";const s=[];for(const c of i){const u=c.length?[]:[90];t.strict&&!c.length&&(r+="/");for(let h=0;he.length?e.length===1&&e[0]===40+40?1:-1:0}function v7(i,e){let t=0;const n=i.score,r=e.score;for(;t0&&e[e.length-1]<0}const x7={type:0,value:""},y7=/[a-zA-Z0-9_]/;function _7(i){if(!i)return[[]];if(i==="/")return[[x7]];if(!i.startsWith("/"))throw new Error(`Invalid path "${i}"`);function e(d){throw new Error(`ERR (${t})/"${c}": ${d}`)}let t=0,n=t;const r=[];let s;function o(){s&&r.push(s),s=[]}let a=0,l,c="",u="";function h(){c&&(t===0?s.push({type:0,value:c}):t===1||t===2||t===3?(s.length>1&&(l==="*"||l==="+")&&e(`A repeatable param (${c}) must be alone in its segment. eg: '/:ids+.`),s.push({type:1,value:c,regexp:u,repeatable:l==="*"||l==="+",optional:l==="*"||l==="?"})):e("Invalid state to consume buffer"),c="")}function f(){c+=l}for(;a{o(p)}:Hs}function o(u){if(qh(u)){const h=n.get(u);h&&(n.delete(u),t.splice(t.indexOf(h),1),h.children.forEach(o),h.alias.forEach(o))}else{const h=t.indexOf(u);h>-1&&(t.splice(h,1),u.record.name&&n.delete(u.record.name),u.children.forEach(o),u.alias.forEach(o))}}function a(){return t}function l(u){let h=0;for(;h=0&&(u.record.path!==t[h].record.path||!Kh(u,t[h]));)h++;t.splice(h,0,u),u.record.name&&!N2(u)&&n.set(u.record.name,u)}function c(u,h){let f,d={},g,v;if("name"in u&&u.name){if(f=n.get(u.name),!f)throw Dr(1,{location:u});v=f.record.name,d=i0(D2(h.params,f.keys.filter(p=>!p.optional).map(p=>p.name)),u.params&&D2(u.params,f.keys.map(p=>p.name))),g=f.stringify(d)}else if("path"in u)g=u.path,f=t.find(p=>p.re.test(g)),f&&(d=f.parse(g),v=f.record.name);else{if(f=h.name?n.get(h.name):t.find(p=>p.re.test(h.path)),!f)throw Dr(1,{location:u,currentLocation:h});v=f.record.name,d=i0({},h.params,u.params),g=f.stringify(d)}const _=[];let m=f;for(;m;)_.unshift(m.record),m=m.parent;return{name:v,path:g,params:d,matched:_,meta:T7(_)}}return i.forEach(u=>s(u)),{addRoute:s,resolve:c,removeRoute:o,getRoutes:a,getRecordMatcher:r}}function D2(i,e){const t={};for(const n of e)n in i&&(t[n]=i[n]);return t}function M7(i){return{path:i.path,redirect:i.redirect,name:i.name,meta:i.meta||{},aliasOf:void 0,beforeEnter:i.beforeEnter,props:S7(i),children:i.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in i?i.components||null:i.component&&{default:i.component}}}function S7(i){const e={},t=i.props||!1;if("component"in i)e.default=t;else for(const n in i.components)e[n]=typeof t=="object"?t[n]:t;return e}function N2(i){for(;i;){if(i.record.aliasOf)return!0;i=i.parent}return!1}function T7(i){return i.reduce((e,t)=>i0(e,t.meta),{})}function O2(i,e){const t={};for(const n in i)t[n]=n in e?e[n]:i[n];return t}function Kh(i,e){return e.children.some(t=>t===i||Kh(i,t))}const Zh=/#/g,A7=/&/g,E7=/\//g,L7=/=/g,P7=/\?/g,Jh=/\+/g,C7=/%5B/g,R7=/%5D/g,$h=/%5E/g,F7=/%60/g,e4=/%7B/g,I7=/%7C/g,t4=/%7D/g,D7=/%20/g;function Wc(i){return encodeURI(""+i).replace(I7,"|").replace(C7,"[").replace(R7,"]")}function N7(i){return Wc(i).replace(e4,"{").replace(t4,"}").replace($h,"^")}function j1(i){return Wc(i).replace(Jh,"%2B").replace(D7,"+").replace(Zh,"%23").replace(A7,"%26").replace(F7,"`").replace(e4,"{").replace(t4,"}").replace($h,"^")}function O7(i){return j1(i).replace(L7,"%3D")}function U7(i){return Wc(i).replace(Zh,"%23").replace(P7,"%3F")}function z7(i){return i==null?"":U7(i).replace(E7,"%2F")}function Ha(i){try{return decodeURIComponent(""+i)}catch{}return""+i}function B7(i){const e={};if(i===""||i==="?")return e;const n=(i[0]==="?"?i.slice(1):i).split("&");for(let r=0;rs&&j1(s)):[n&&j1(n)]).forEach(s=>{s!==void 0&&(e+=(e.length?"&":"")+t,s!=null&&(e+="="+s))})}return e}function k7(i){const e={};for(const t in i){const n=i[t];n!==void 0&&(e[t]=zt(n)?n.map(r=>r==null?null:""+r):n==null?n:""+n)}return e}const G7=Symbol(""),z2=Symbol(""),Xc=Symbol(""),n4=Symbol(""),Y1=Symbol("");function ys(){let i=[];function e(n){return i.push(n),()=>{const r=i.indexOf(n);r>-1&&i.splice(r,1)}}function t(){i=[]}return{add:e,list:()=>i.slice(),reset:t}}function On(i,e,t,n,r){const s=n&&(n.enterCallbacks[r]=n.enterCallbacks[r]||[]);return()=>new Promise((o,a)=>{const l=h=>{h===!1?a(Dr(4,{from:t,to:e})):h instanceof Error?a(h):f7(h)?a(Dr(2,{from:e,to:h})):(s&&n.enterCallbacks[r]===s&&typeof h=="function"&&s.push(h),o())},c=i.call(n&&n.instances[r],e,t,l);let u=Promise.resolve(c);i.length<3&&(u=u.then(l)),u.catch(h=>a(h))})}function Vl(i,e,t,n){const r=[];for(const s of i)for(const o in s.components){let a=s.components[o];if(!(e!=="beforeRouteEnter"&&!s.instances[o]))if(H7(a)){const c=(a.__vccOpts||a)[e];c&&r.push(On(c,t,n,s,o))}else{let l=a();r.push(()=>l.then(c=>{if(!c)return Promise.reject(new Error(`Couldn't resolve component "${o}" at "${s.path}"`));const u=q6(c)?c.default:c;s.components[o]=u;const f=(u.__vccOpts||u)[e];return f&&On(f,t,n,s,o)()}))}}return r}function H7(i){return typeof i=="object"||"displayName"in i||"props"in i||"__vccOpts"in i}function B2(i){const e=nt(Xc),t=nt(n4),n=Rt(()=>e.resolve(Gn(i.to))),r=Rt(()=>{const{matched:l}=n.value,{length:c}=l,u=l[c-1],h=t.matched;if(!u||!h.length)return-1;const f=h.findIndex(Ir.bind(null,u));if(f>-1)return f;const d=k2(l[c-2]);return c>1&&k2(u)===d&&h[h.length-1].path!==d?h.findIndex(Ir.bind(null,l[c-2])):f}),s=Rt(()=>r.value>-1&&j7(t.params,n.value.params)),o=Rt(()=>r.value>-1&&r.value===t.matched.length-1&&jh(t.params,n.value.params));function a(l={}){return X7(l)?e[Gn(i.replace)?"replace":"push"](Gn(i.to)).catch(Hs):Promise.resolve()}return{route:n,href:Rt(()=>n.value.href),isActive:s,isExactActive:o,navigate:a}}const V7=Le({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:B2,setup(i,{slots:e}){const t=ll(B2(i)),{options:n}=nt(Xc),r=Rt(()=>({[G2(i.activeClass,n.linkActiveClass,"router-link-active")]:t.isActive,[G2(i.exactActiveClass,n.linkExactActiveClass,"router-link-exact-active")]:t.isExactActive}));return()=>{const s=e.default&&e.default(t);return i.custom?s:Vh("a",{"aria-current":t.isExactActive?i.ariaCurrentValue:null,href:t.href,onClick:t.navigate,class:r.value},s)}}}),W7=V7;function X7(i){if(!(i.metaKey||i.altKey||i.ctrlKey||i.shiftKey)&&!i.defaultPrevented&&!(i.button!==void 0&&i.button!==0)){if(i.currentTarget&&i.currentTarget.getAttribute){const e=i.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(e))return}return i.preventDefault&&i.preventDefault(),!0}}function j7(i,e){for(const t in e){const n=e[t],r=i[t];if(typeof n=="string"){if(n!==r)return!1}else if(!zt(r)||r.length!==n.length||n.some((s,o)=>s!==r[o]))return!1}return!0}function k2(i){return i?i.aliasOf?i.aliasOf.path:i.path:""}const G2=(i,e,t)=>i??e??t,Y7=Le({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(i,{attrs:e,slots:t}){const n=nt(Y1),r=Rt(()=>i.route||n.value),s=nt(z2,0),o=Rt(()=>{let c=Gn(s);const{matched:u}=r.value;let h;for(;(h=u[c])&&!h.components;)c++;return c}),a=Rt(()=>r.value.matched[o.value]);ks(z2,Rt(()=>o.value+1)),ks(G7,a),ks(Y1,r);const l=P0();return Ze(()=>[l.value,a.value,i.name],([c,u,h],[f,d,g])=>{u&&(u.instances[h]=c,d&&d!==u&&c&&c===f&&(u.leaveGuards.size||(u.leaveGuards=d.leaveGuards),u.updateGuards.size||(u.updateGuards=d.updateGuards))),c&&u&&(!d||!Ir(u,d)||!f)&&(u.enterCallbacks[h]||[]).forEach(v=>v(c))},{flush:"post"}),()=>{const c=r.value,u=i.name,h=a.value,f=h&&h.components[u];if(!f)return H2(t.default,{Component:f,route:c});const d=h.props[u],g=d?d===!0?c.params:typeof d=="function"?d(c):d:null,_=Vh(f,i0({},g,e,{onVnodeUnmounted:m=>{m.component.isUnmounted&&(h.instances[u]=null)},ref:l}));return H2(t.default,{Component:_,route:c})||_}}});function H2(i,e){if(!i)return null;const t=i(e);return t.length===1?t[0]:t}const i4=Y7;function q7(i){const e=w7(i.routes,i),t=i.parseQuery||B7,n=i.stringifyQuery||U2,r=i.history,s=ys(),o=ys(),a=ys(),l=$d(Sn);let c=Sn;hr&&i.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const u=Gl.bind(null,V=>""+V),h=Gl.bind(null,z7),f=Gl.bind(null,Ha);function d(V,te){let Q,re;return qh(V)?(Q=e.getRecordMatcher(V),re=te):re=V,e.addRoute(re,Q)}function g(V){const te=e.getRecordMatcher(V);te&&e.removeRoute(te)}function v(){return e.getRoutes().map(V=>V.record)}function _(V){return!!e.getRecordMatcher(V)}function m(V,te){if(te=i0({},te||l.value),typeof V=="string"){const F=Hl(t,V,te.path),W=e.resolve({path:F.path},te),X=r.createHref(F.fullPath);return i0(F,W,{params:f(W.params),hash:Ha(F.hash),redirectedFrom:void 0,href:X})}let Q;if("path"in V)Q=i0({},V,{path:Hl(t,V.path,te.path).path});else{const F=i0({},V.params);for(const W in F)F[W]==null&&delete F[W];Q=i0({},V,{params:h(F)}),te.params=h(te.params)}const re=e.resolve(Q,te),we=V.hash||"";re.params=u(f(re.params));const M=Z6(n,i0({},V,{hash:N7(we),path:re.path})),E=r.createHref(M);return i0({fullPath:M,hash:we,query:n===U2?k7(V.query):V.query||{}},re,{redirectedFrom:void 0,href:E})}function p(V){return typeof V=="string"?Hl(t,V,l.value.path):i0({},V)}function y(V,te){if(c!==V)return Dr(8,{from:te,to:V})}function x(V){return b(V)}function w(V){return x(i0(p(V),{replace:!0}))}function A(V){const te=V.matched[V.matched.length-1];if(te&&te.redirect){const{redirect:Q}=te;let re=typeof Q=="function"?Q(V):Q;return typeof re=="string"&&(re=re.includes("?")||re.includes("#")?re=p(re):{path:re},re.params={}),i0({query:V.query,hash:V.hash,params:"path"in re?{}:V.params},re)}}function b(V,te){const Q=c=m(V),re=l.value,we=V.state,M=V.force,E=V.replace===!0,F=A(Q);if(F)return b(i0(p(F),{state:typeof F=="object"?i0({},we,F.state):we,force:M,replace:E}),te||Q);const W=Q;W.redirectedFrom=te;let X;return!M&&J6(n,re,Q)&&(X=Dr(16,{to:W,from:re}),ce(re,re,!0,!1)),(X?Promise.resolve(X):I(W,re)).catch(T=>nn(T)?nn(T,2)?T:ve(T):K(T,W,re)).then(T=>{if(T){if(nn(T,2))return b(i0({replace:E},p(T.to),{state:typeof T.to=="object"?i0({},we,T.to.state):we,force:M}),te||W)}else T=Y(W,re,!0,E,we);return C(W,re,T),T})}function L(V,te){const Q=y(V,te);return Q?Promise.reject(Q):Promise.resolve()}function B(V){const te=se.values().next().value;return te&&typeof te.runWithContext=="function"?te.runWithContext(V):V()}function I(V,te){let Q;const[re,we,M]=Q7(V,te);Q=Vl(re.reverse(),"beforeRouteLeave",V,te);for(const F of re)F.leaveGuards.forEach(W=>{Q.push(On(W,V,te))});const E=L.bind(null,V,te);return Q.push(E),Z(Q).then(()=>{Q=[];for(const F of s.list())Q.push(On(F,V,te));return Q.push(E),Z(Q)}).then(()=>{Q=Vl(we,"beforeRouteUpdate",V,te);for(const F of we)F.updateGuards.forEach(W=>{Q.push(On(W,V,te))});return Q.push(E),Z(Q)}).then(()=>{Q=[];for(const F of M)if(F.beforeEnter)if(zt(F.beforeEnter))for(const W of F.beforeEnter)Q.push(On(W,V,te));else Q.push(On(F.beforeEnter,V,te));return Q.push(E),Z(Q)}).then(()=>(V.matched.forEach(F=>F.enterCallbacks={}),Q=Vl(M,"beforeRouteEnter",V,te),Q.push(E),Z(Q))).then(()=>{Q=[];for(const F of o.list())Q.push(On(F,V,te));return Q.push(E),Z(Q)}).catch(F=>nn(F,8)?F:Promise.reject(F))}function C(V,te,Q){a.list().forEach(re=>B(()=>re(V,te,Q)))}function Y(V,te,Q,re,we){const M=y(V,te);if(M)return M;const E=te===Sn,F=hr?history.state:{};Q&&(re||E?r.replace(V.fullPath,i0({scroll:E&&F&&F.scroll},we)):r.push(V.fullPath,we)),l.value=V,ce(V,te,Q,E),ve()}let O;function G(){O||(O=r.listen((V,te,Q)=>{if(!me.listening)return;const re=m(V),we=A(re);if(we){b(i0(we,{replace:!0}),re).catch(Hs);return}c=re;const M=l.value;hr&&o7(P2(M.fullPath,Q.delta),vl()),I(re,M).catch(E=>nn(E,12)?E:nn(E,2)?(b(E.to,re).then(F=>{nn(F,20)&&!Q.delta&&Q.type===so.pop&&r.go(-1,!1)}).catch(Hs),Promise.reject()):(Q.delta&&r.go(-Q.delta,!1),K(E,re,M))).then(E=>{E=E||Y(re,M,!1),E&&(Q.delta&&!nn(E,8)?r.go(-Q.delta,!1):Q.type===so.pop&&nn(E,20)&&r.go(-1,!1)),C(re,M,E)}).catch(Hs)}))}let j=ys(),N=ys(),k;function K(V,te,Q){ve(V);const re=N.list();return re.length?re.forEach(we=>we(V,te,Q)):console.error(V),Promise.reject(V)}function le(){return k&&l.value!==Sn?Promise.resolve():new Promise((V,te)=>{j.add([V,te])})}function ve(V){return k||(k=!V,G(),j.list().forEach(([te,Q])=>V?Q(V):te()),j.reset()),V}function ce(V,te,Q,re){const{scrollBehavior:we}=i;if(!hr||!we)return Promise.resolve();const M=!Q&&a7(P2(V.fullPath,0))||(re||!Q)&&history.state&&history.state.scroll||null;return _h().then(()=>we(V,te,M)).then(E=>E&&s7(E)).catch(E=>K(E,V,te))}const ye=V=>r.go(V);let $;const se=new Set,me={currentRoute:l,listening:!0,addRoute:d,removeRoute:g,hasRoute:_,getRoutes:v,resolve:m,options:i,push:x,replace:w,go:ye,back:()=>ye(-1),forward:()=>ye(1),beforeEach:s.add,beforeResolve:o.add,afterEach:a.add,onError:N.add,isReady:le,install(V){const te=this;V.component("RouterLink",W7),V.component("RouterView",i4),V.config.globalProperties.$router=te,Object.defineProperty(V.config.globalProperties,"$route",{enumerable:!0,get:()=>Gn(l)}),hr&&!$&&l.value===Sn&&($=!0,x(r.location).catch(we=>{}));const Q={};for(const we in Sn)Object.defineProperty(Q,we,{get:()=>l.value[we],enumerable:!0});V.provide(Xc,te),V.provide(n4,hh(Q)),V.provide(Y1,l);const re=V.unmount;se.add(V),V.unmount=function(){se.delete(V),se.size<1&&(c=Sn,O&&O(),O=null,l.value=Sn,$=!1,k=!1),re()}}};function Z(V){return V.reduce((te,Q)=>te.then(()=>B(Q)),Promise.resolve())}return me}function Q7(i,e){const t=[],n=[],r=[],s=Math.max(e.matched.length,i.matched.length);for(let o=0;oIr(c,a))?n.push(a):t.push(a));const l=i.matched[o];l&&(e.matched.find(c=>Ir(c,l))||r.push(l))}return[t,n,r]}const _n=(i,e)=>{const t=i.__vccOpts||i;for(const[n,r]of e)t[n]=r;return t},K7={},Z7={xmlns:"http://www.w3.org/2000/svg",class:"icon icon-tabler icon-tabler-sun-high",width:"32",height:"32",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},J7=n6('',10),$7=[J7];function ep(i,e){return Ge(),qe("svg",Z7,$7)}const tp=_n(K7,[["render",ep]]),np={},ip={xmlns:"http://www.w3.org/2000/svg",class:"icon icon-tabler icon-tabler-moon",width:"32",height:"32",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},rp=de("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null,-1),sp=de("path",{d:"M12 3c.132 0 .263 0 .393 0a7.5 7.5 0 0 0 7.92 12.446a9 9 0 1 1 -8.313 -12.454z"},null,-1),op=[rp,sp];function ap(i,e){return Ge(),qe("svg",ip,op)}const lp=_n(np,[["render",ap]]);const cp={__name:"DarkMode",setup(i){const e=P0(!0);function t(){window.matchMedia&&window.matchMedia("(prefers-color-scheme:dark)").matches?e.value=!0:e.value=!1}t();function n(){e.value=!e.value,e.value?(document.documentElement.style.setProperty("--color-background","var(--vt-c-black)"),document.documentElement.style.setProperty("--color-background-soft","var(--vt-c-black-soft);"),document.documentElement.style.setProperty("--color-background-mute","var(--vt-c-black-mute)"),document.documentElement.style.setProperty("--color-border","var(--vt-c-divider-dark-2)"),document.documentElement.style.setProperty("--color-border-hover","var(--vt-c-divider-dark-1)"),document.documentElement.style.setProperty("--color-heading","var(--vt-c-text-dark-1)"),document.documentElement.style.setProperty("--color-text","var(--vt-c-text-dark-2)")):(document.documentElement.style.setProperty("--color-background","var(--vt-c-white)"),document.documentElement.style.setProperty("--color-background-soft","var(--vt-c-white-soft);"),document.documentElement.style.setProperty("--color-background-mute","var(--vt-c-white-mute)"),document.documentElement.style.setProperty("--color-border","var(--vt-c-divider-light-2)"),document.documentElement.style.setProperty("--color-border-hover","var(--vt-c-divider-light-1)"),document.documentElement.style.setProperty("--color-heading","var(--vt-c-text-light-1)"),document.documentElement.style.setProperty("--color-text","var(--vt-c-text-light-2)"))}return(r,s)=>e.value?(Ge(),qe("button",{key:0,onClick:n,class:"iconButton"},[je(tp)])):(Ge(),qe("button",{key:1,onClick:n,class:"iconButton"},[je(lp)]))}},up={},hp={xmlns:"http://www.w3.org/2000/svg",class:"icon icon-tabler icon-tabler-chevron-up",width:"32",height:"32",viewBox:"0 0 24 24","stroke-width":"2",stroke:"currentColor",fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},fp=de("path",{stroke:"none",d:"M0 0h24v24H0z",fill:"none"},null,-1),dp=de("path",{d:"M6 15l6 -6l6 6"},null,-1),pp=[fp,dp];function mp(i,e){return Ge(),qe("svg",hp,pp)}const gp=_n(up,[["render",mp]]);const vp={__name:"ToTopButton",setup(i){const e=P0(!1);window.onscroll=function(){t()};function t(){document.body.scrollTop>20||document.documentElement.scrollTop>20?e.value=!0:e.value=!1}function n(){window.scrollTo({top:0,behavior:"smooth"})}return(r,s)=>e.value?(Ge(),qe("button",{key:0,onClick:n,class:"iconButton"},[je(gp)])):ml("",!0)}};const xp={class:"iconButton"},yp={__name:"ThemePicker",setup(i){const e=P0("#00916E");function t(){document.documentElement.style.setProperty("--color-highlight",e.value)}return(n,r)=>(Ge(),qe("div",xp,[Bn(de("input",{"onUpdate:modelValue":r[0]||(r[0]=s=>e.value=s),type:"color",id:"colorPicker",name:"highlightColor",onChange:r[1]||(r[1]=s=>t())},null,544),[[Tr,e.value]])]))}};const _p={class:"iconBar"},bp={__name:"IconBar",setup(i){return(e,t)=>(Ge(),qe("div",_p,[je(vp),je(yp),je(cp)]))}};const wp=de("div",{class:"bar1"},null,-1),Mp=de("div",{class:"bar2"},null,-1),Sp=de("div",{class:"bar3"},null,-1),Tp=[wp,Mp,Sp],Ap={__name:"HamburgerMenu",setup(i){const e=P0("0%"),t=P0(!1);function n(){t.value=!t.value}function r(){n(),e.value=e.value==="0%"?"100%":"0%",document.body.style.overflow=document.body.style.overflow==="hidden"?"auto":"hidden"}return(s,o)=>(Ge(),qe(U0,null,[de("div",{class:qn(["hamburger",{opened:t.value}]),onClick:r},Tp,2),de("div",{id:"myNav",class:"overlay",style:Fi({height:e.value})},[de("nav",{id:"test",class:"overlayContent"},[de("a",{onClick:r,href:"#section1"},"Start"),de("a",{onClick:r,href:"#section2"},"Über mich"),de("a",{onClick:r,href:"#section3"},"Meine Projekte"),de("a",{onClick:r,href:"#section4"},"Meine Skills"),de("a",{onClick:r,href:"#section5"},"Galerie"),de("a",{onClick:r,href:"#section6"},"3D-Model"),de("a",{onClick:r,href:"#section7"},"Kontakt")])],4)],64))}};const Ep={class:"progressContainer"},Lp=de("div",{class:"progressBar",id:"myBar"},null,-1),Pp=[Lp],Cp={__name:"ProgressBar",setup(i){return window.addEventListener("scroll",()=>{var e=document.body.scrollTop||document.documentElement.scrollTop,t=document.documentElement.scrollHeight-document.documentElement.clientHeight,n=e/t*100;document.getElementById("myBar").style.width=n+"%"}),(e,t)=>(Ge(),qe("div",Ep,Pp))}};const Rp={class:"footer"},Fp={__name:"Footer",setup(i){function e(){window.scrollTo({top:0,behavior:"smooth"})}return(t,n)=>{const r=yi("RouterLink");return Ge(),qe("div",Rp,[je(r,{onClick:e,to:"/"},{default:Mr(()=>[Sr("Home")]),_:1}),je(r,{onClick:e,to:"/impressum"},{default:Mr(()=>[Sr("Impressum")]),_:1}),je(r,{onClick:e,to:"/datenschutz"},{default:Mr(()=>[Sr("Datenschutz")]),_:1})])}}};const jc=i=>(d8("data-v-1d3973aa"),i=i(),p8(),i),Ip={class:"navBar"},Dp=jc(()=>de("img",{alt:"Vue logo",class:"logo",src:Y6,width:"48",height:"48"},null,-1)),Np=jc(()=>de("h1",null,"Portfolio",-1)),Op=jc(()=>de("div",{class:"break"},null,-1)),Up={__name:"App",setup(i){return(e,t)=>(Ge(),qe(U0,null,[de("header",null,[de("div",Ip,[Dp,Np,je(Ap)]),Op,je(Cp)]),je(bp),je(Gn(i4)),je(Fp)],64))}},zp=_n(Up,[["__scopeId","data-v-1d3973aa"]]),Bp="modulepreload",kp=function(i){return"/"+i},V2={},W2=function(e,t,n){if(!t||t.length===0)return e();const r=document.getElementsByTagName("link");return Promise.all(t.map(s=>{if(s=kp(s),s in V2)return;V2[s]=!0;const o=s.endsWith(".css"),a=o?'[rel="stylesheet"]':"";if(!!n)for(let u=r.length-1;u>=0;u--){const h=r[u];if(h.href===s&&(!o||h.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${s}"]${a}`))return;const c=document.createElement("link");if(c.rel=o?"stylesheet":Bp,o||(c.as="script",c.crossOrigin=""),c.href=s,document.head.appendChild(c),o)return new Promise((u,h)=>{c.addEventListener("load",u),c.addEventListener("error",()=>h(new Error(`Unable to preload CSS for ${s}`)))})})).then(()=>e()).catch(s=>{const o=new Event("vite:preloadError",{cancelable:!0});if(o.payload=s,window.dispatchEvent(o),!o.defaultPrevented)throw s})};const Gp={data(){return{images:[{id:1,src:"/img/arbeit.jpg"},{id:2,src:"/img/baum.jpg"},{id:3,src:"/img/strasse.jpg"},{id:4,src:"/img/eishoehle.jpg"},{id:5,src:"/img/fastfood.jpg"},{id:6,src:"/img/eule.jpg"},{id:7,src:"/img/lightroom.jpg"},{id:8,src:"/img/kamera.jpg"},{id:9,src:"/img/leuchtreklame.jpg"},{id:10,src:"/img/schachbrett.jpg"},{id:11,src:"/img/pinsel.jpg"},{id:12,src:"/img/mischpult.jpg"},{id:13,src:"/img/drohne.jpg"},{id:14,src:"/img/glasfaser.jpg"}],imageIdCounter:14,isHovered:null}},computed:{imageGroups(){return this.calculateImageGroups()}},methods:{calculateImageGroups(){const i=[],e=this.images.length,t=4,n=Math.ceil(e/t);for(let r=0;rt.id===i);e!==-1&&(this.images.splice(e,1),this.isHovered=null,this.updateImageGroups())},addNewImage(i){const e=i.target.files;if(e.length===0)return;const t=new FileReader;t.onload=()=>{const n=t.result;this.imageIdCounter++;const r={id:this.imageIdCounter,src:n,alt:"Neues Bild"};this.images.push(r),this.updateImageGroups()},t.readAsDataURL(e[0])},updateImageGroups(){this.$nextTick(()=>{this.images.sort((i,e)=>i.src.localeCompare(e.src)),this.$forceUpdate()})}}},Hp={class:"column"},Vp=["onMouseover"],Wp=["src","alt"],Xp={key:0,class:"imgOverlay"},jp=["onClick"],Yp={class:"row"},qp=de("label",{for:"fileInput",class:"custom-file-upload"},[de("span",{style:{"font-weight":"bold"}},"HINZUFÜGEN: (+)")],-1);function Qp(i,e,t,n,r,s){return Ge(),qe("div",Hp,[(Ge(!0),qe(U0,null,to(s.imageGroups,(o,a)=>(Ge(),qe("div",{key:a,class:"row"},[(Ge(!0),qe(U0,null,to(o,(l,c)=>(Ge(),qe("div",{key:l.id,class:"image-container",onMouseover:u=>s.highlightImage(l.id)},[de("img",{src:l.src,alt:l.alt},null,8,Wp),r.isHovered===l.id?(Ge(),qe("div",Xp,[de("span",{onClick:u=>s.deleteImage(l.id),class:"delete-icon"},"X",8,jp)])):ml("",!0)],40,Vp))),128))]))),128)),de("div",Yp,[de("input",{type:"file",id:"fileInput",onChange:e[0]||(e[0]=(...o)=>s.addNewImage&&s.addNewImage(...o)),style:{display:"none"}},null,32),qp])])}const X2=_n(Gp,[["render",Qp]]);const Kp={class:"contact-form"},Zp=de("h2",null,"Kontaktformular",-1),Jp=["onSubmit"],$p={class:"form-group"},em={class:"form-group"},tm={class:"nachricht"},nm={class:"datenschutz"},im=["disabled"],j2={__name:"Contact",setup(i){const e=P0(""),t=P0(""),n=P0(""),r=P0(!1);function s(){r.value?(console.log("Formular abgeschickt:",{name:e.value,email:t.value,message:n.value}),e.value="",t.value="",n.value="",r.value=!1):alert("Bitte bestätigen Sie die Datenschutzerklärung.")}return(o,a)=>(Ge(),qe("div",Kp,[Zp,de("form",{onSubmit:Xh(s,["prevent"])},[de("div",$p,[Bn(de("input",{placeholder:"Name",type:"text",id:"name","onUpdate:modelValue":a[0]||(a[0]=l=>e.value=l),required:""},null,512),[[Tr,e.value]])]),de("div",em,[Bn(de("input",{placeholder:"E-Mail",type:"email",id:"email","onUpdate:modelValue":a[1]||(a[1]=l=>t.value=l),required:""},null,512),[[Tr,t.value]])]),de("div",tm,[Bn(de("textarea",{placeholder:"Nachricht",id:"message","onUpdate:modelValue":a[2]||(a[2]=l=>n.value=l),rows:"5",required:""},null,512),[[Tr,n.value]])]),de("div",nm,[de("label",null,[Bn(de("input",{type:"checkbox","onUpdate:modelValue":a[3]||(a[3]=l=>r.value=l),required:""},null,512),[[O6,r.value]]),Sr(" Ich bestätige die Datenschutzerklärung. ")])]),de("button",{type:"submit",disabled:!r.value},"Absenden",8,im)],40,Jp)]))}};const rm={},sm={class:"tiltingCard"},om=de("div",{class:"mousePositionTracker"},[de("div"),de("div"),de("div"),de("div"),de("div"),de("div"),de("div"),de("div"),de("div")],-1),am=[om];function lm(i,e){return Ge(),qe("div",sm,am)}const cm=_n(rm,[["render",lm]]);const um={class:"hero"},hm=de("div",{class:"heroText"},[de("h2",{contenteditable:"true"},"Hi, mein Name ist Lorem Ipsum."),de("p",{contenteditable:"true"},"Ich erstelle Sachen"),de("button",{onclick:"window.location.href='#section6';"},"Nimm Kontakt auf!")],-1),Y2={__name:"Hero",setup(i){return(e,t)=>(Ge(),qe("div",um,[hm,de("div",null,[je(cm)])]))}};const fm={},dm={class:"cardContainer"},pm={id:"card1",class:"card"},mm={class:"cardBody",contenteditable:"true",ref:"editableContent"},gm=de("h2",{class:"cardTitle"},"Etwas tolles",-1),vm=de("p",null,"Lorem ipsum, dolor sit amet consectetur adipisicing elit. Fuga placeat odio pariatur doloribus sint?",-1),xm=de("a",{href:"#",class:"button"},"Mehr erfahren",-1),ym=[gm,vm,xm],_m={id:"card2",class:"card"},bm={class:"cardBody",contenteditable:"true",ref:"editableContent"},wm=de("h2",{class:"cardTitle"},"Etwas spannendes",-1),Mm=de("p",null,"Lorem ipsum, dolor sit amet consectetur adipisicing elit. Fuga placeat odio pariatur doloribus sint?",-1),Sm=de("a",{href:"#",class:"button"},"Mehr erfahren",-1),Tm=[wm,Mm,Sm],Am={id:"card3",class:"card"},Em={class:"cardBody",contenteditable:"true",ref:"editableContent"},Lm=de("h2",{class:"cardTitle"},"Etwas interessantes",-1),Pm=de("p",null,"Lorem ipsum, dolor sit amet consectetur adipisicing elit. Fuga placeat odio pariatur doloribus sint?",-1),Cm=de("a",{href:"#",class:"button"},"Mehr erfahren",-1),Rm=[Lm,Pm,Cm],Fm={id:"card4",class:"card"},Im={class:"cardBody",contenteditable:"true",ref:"editableContent"},Dm=de("h2",{class:"cardTitle"},"Etwas lustiges",-1),Nm=de("p",null,"Lorem ipsum, dolor sit amet consectetur adipisicing elit. Fuga placeat odio pariatur doloribus sint?",-1),Om=de("a",{href:"#",class:"button"},"Mehr erfahren",-1),Um=[Dm,Nm,Om];function zm(i,e){return Ge(),qe("div",dm,[de("div",pm,[de("div",mm,ym,512)]),de("div",_m,[de("div",bm,Tm,512)]),de("div",Am,[de("div",Em,Rm,512)]),de("div",Fm,[de("div",Im,Um,512)])])}const q2=_n(fm,[["render",zm]]);const Bm={class:"skillContainer"},km=de("div",{class:"CreatorBar1"},null,-1),Gm=de("div",{class:"CreatorBar2"},null,-1),Hm=[km,Gm],Vm=de("h3",{style:{margin:"32px 0 8px 0"}},"Neuen Skill anlegen:",-1),Wm={class:"skillContainer"},Xm=["onSubmit"],jm=de("button",null,"Erstellen",-1),Q2={__name:"Skills",setup(i){const e=P0(!1),t=P0(50),n=P0(""),r=P0([{text:"HTML",percetage:"77"},{text:"CSS",percetage:"86"},{text:"JavaScript",percetage:"65"}]);function s(){r.value.push({text:n.value,percetage:t.value}),t.value=50,n.value=""}function o(){e.value=!e.value}return(a,l)=>(Ge(),qe(U0,null,[(Ge(!0),qe(U0,null,to(r.value,c=>(Ge(),qe("div",Bm,[de("div",{class:"skill",style:Fi({width:c.percetage+"%"})},[de("p",null,pr(c.text),1),de("p",null,pr(c.percetage)+"%",1)],4)]))),256)),de("div",{class:qn(["skillCreator",{create:e.value}]),onClick:o},Hm,2),de("div",{class:qn(["skillAnlegen",{newSkill:e.value}])},[Vm,de("div",Wm,[de("div",{class:"skill",style:Fi({width:t.value+"%"})},[de("p",null,pr(n.value),1),de("p",null,pr(t.value)+"%",1)],4)]),de("form",{onSubmit:Xh(s,["prevent"]),style:{display:"block"}},[Bn(de("input",{"onUpdate:modelValue":l[0]||(l[0]=c=>t.value=c),type:"range",min:"0",max:"100",class:"slider"},null,512),[[Tr,t.value]]),Bn(de("input",{type:"text","onUpdate:modelValue":l[1]||(l[1]=c=>n.value=c),placeholder:"Bezeichnung",style:{"max-width":"50%","margin-right":"8px"}},null,512),[[Tr,n.value]]),jm],40,Xm)],2)],64))}};/** * @license * Copyright 2010-2021 Three.js Authors * SPDX-License-Identifier: MIT - */const r4="134",Vi={LEFT:0,MIDDLE:1,RIGHT:2,ROTATE:0,DOLLY:1,PAN:2},Wi={ROTATE:0,PAN:1,DOLLY_PAN:2,DOLLY_ROTATE:3},Ym=0,Z2=1,qm=2,s4=1,Qm=2,Os=3,Dr=0,L0=1,Zn=2,o4=1,V0=0,Ws=1,Y1=2,K2=3,J2=4,a4=5,zn=100,Zm=101,Km=102,$2=103,eu=104,q1=200,Jm=201,$m=202,eg=203,l4=204,c4=205,u4=206,tg=207,h4=208,ng=209,ig=210,rg=0,sg=1,og=2,Q1=3,ag=4,lg=5,cg=6,ug=7,vl=0,hg=1,fg=2,Pi=0,dg=1,pg=2,mg=3,gg=4,vg=5,mr=300,Zr=301,Eo=302,Va=303,Z1=304,xl=306,Yc=307,Qt=1e3,m0=1001,Wa=1002,r0=1003,K1=1004,J1=1005,s0=1006,f4=1007,Ni=1008,Kn=1009,xg=1010,yg=1011,oo=1012,_g=1013,Ra=1014,gt=1015,Vn=1016,bg=1017,wg=1018,Mg=1019,Xs=1020,Sg=1021,Yt=1022,a0=1023,Tg=1024,Ag=1025,Eg=a0,Tr=1026,ao=1027,Lg=1028,Pg=1029,Cg=1030,Rg=1031,Fg=1032,Ig=1033,tu=33776,nu=33777,iu=33778,ru=33779,su=35840,ou=35841,au=35842,lu=35843,Dg=36196,cu=37492,uu=37496,Ng=37808,Og=37809,Ug=37810,zg=37811,Bg=37812,kg=37813,Gg=37814,Hg=37815,Vg=37816,Wg=37817,Xg=37818,jg=37819,Yg=37820,qg=37821,Qg=36492,Zg=37840,Kg=37841,Jg=37842,$g=37843,ev=37844,tv=37845,nv=37846,iv=37847,rv=37848,sv=37849,ov=37850,av=37851,lv=37852,cv=37853,uv=2200,hv=2201,fv=2202,lo=2300,Nr=2301,Vl=2302,gr=2400,vr=2401,Xa=2402,qc=2500,d4=2501,dv=0,pv=1,p4=2,J0=3e3,at=3001,Qc=3007,Zc=3002,mv=3003,m4=3004,g4=3005,v4=3006,gv=3200,x4=3201,Oi=0,vv=1,Wl=7680,xv=519,co=35044,ja=35048,hu="300 es";class ni{addEventListener(e,t){this._listeners===void 0&&(this._listeners={});const n=this._listeners;n[e]===void 0&&(n[e]=[]),n[e].indexOf(t)===-1&&n[e].push(t)}hasEventListener(e,t){if(this._listeners===void 0)return!1;const n=this._listeners;return n[e]!==void 0&&n[e].indexOf(t)!==-1}removeEventListener(e,t){if(this._listeners===void 0)return;const r=this._listeners[e];if(r!==void 0){const s=r.indexOf(t);s!==-1&&r.splice(s,1)}}dispatchEvent(e){if(this._listeners===void 0)return;const n=this._listeners[e.type];if(n!==void 0){e.target=this;const r=n.slice(0);for(let s=0,o=r.length;s>8&255]+H0[i>>16&255]+H0[i>>24&255]+"-"+H0[e&255]+H0[e>>8&255]+"-"+H0[e>>16&15|64]+H0[e>>24&255]+"-"+H0[t&63|128]+H0[t>>8&255]+"-"+H0[t>>16&255]+H0[t>>24&255]+H0[n&255]+H0[n>>8&255]+H0[n>>16&255]+H0[n>>24&255]).toUpperCase()}function Q0(i,e,t){return Math.max(e,Math.min(t,i))}function Kc(i,e){return(i%e+e)%e}function _v(i,e,t,n,r){return n+(i-e)*(r-n)/(t-e)}function bv(i,e,t){return i!==e?(t-i)/(e-i):0}function Ys(i,e,t){return(1-t)*i+t*e}function wv(i,e,t,n){return Ys(i,e,1-Math.exp(-t*n))}function Mv(i,e=1){return e-Math.abs(Kc(i,e*2)-e)}function Sv(i,e,t){return i<=e?0:i>=t?1:(i=(i-e)/(t-e),i*i*(3-2*i))}function Tv(i,e,t){return i<=e?0:i>=t?1:(i=(i-e)/(t-e),i*i*i*(i*(i*6-15)+10))}function Av(i,e){return i+Math.floor(Math.random()*(e-i+1))}function Ev(i,e){return i+Math.random()*(e-i)}function Lv(i){return i*(.5-Math.random())}function Pv(i){return i!==void 0&&(Ho=i%2147483647),Ho=Ho*16807%2147483647,(Ho-1)/2147483646}function Cv(i){return i*js}function Rv(i){return i*uo}function $1(i){return(i&i-1)===0&&i!==0}function y4(i){return Math.pow(2,Math.ceil(Math.log(i)/Math.LN2))}function _4(i){return Math.pow(2,Math.floor(Math.log(i)/Math.LN2))}function Fv(i,e,t,n,r){const s=Math.cos,o=Math.sin,a=s(t/2),l=o(t/2),c=s((e+n)/2),u=o((e+n)/2),h=s((e-n)/2),f=o((e-n)/2),d=s((n-e)/2),g=o((n-e)/2);switch(r){case"XYX":i.set(a*u,l*h,l*f,a*c);break;case"YZY":i.set(l*f,a*u,l*h,a*c);break;case"ZXZ":i.set(l*h,l*f,a*u,a*c);break;case"XZX":i.set(a*u,l*g,l*d,a*c);break;case"YXY":i.set(l*d,a*u,l*g,a*c);break;case"ZYZ":i.set(l*g,l*d,a*u,a*c);break;default:console.warn("THREE.MathUtils: .setQuaternionFromProperEuler() encountered an unknown order: "+r)}}var vt=Object.freeze({__proto__:null,DEG2RAD:js,RAD2DEG:uo,generateUUID:yt,clamp:Q0,euclideanModulo:Kc,mapLinear:_v,inverseLerp:bv,lerp:Ys,damp:wv,pingpong:Mv,smoothstep:Sv,smootherstep:Tv,randInt:Av,randFloat:Ev,randFloatSpread:Lv,seededRandom:Pv,degToRad:Cv,radToDeg:Rv,isPowerOfTwo:$1,ceilPowerOfTwo:y4,floorPowerOfTwo:_4,setQuaternionFromProperEuler:Fv});class ee{constructor(e=0,t=0){this.x=e,this.y=t}get width(){return this.x}set width(e){this.x=e}get height(){return this.y}set height(e){this.y=e}set(e,t){return this.x=e,this.y=t,this}setScalar(e){return this.x=e,this.y=e,this}setX(e){return this.x=e,this}setY(e){return this.y=e,this}setComponent(e,t){switch(e){case 0:this.x=t;break;case 1:this.y=t;break;default:throw new Error("index is out of range: "+e)}return this}getComponent(e){switch(e){case 0:return this.x;case 1:return this.y;default:throw new Error("index is out of range: "+e)}}clone(){return new this.constructor(this.x,this.y)}copy(e){return this.x=e.x,this.y=e.y,this}add(e,t){return t!==void 0?(console.warn("THREE.Vector2: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(e,t)):(this.x+=e.x,this.y+=e.y,this)}addScalar(e){return this.x+=e,this.y+=e,this}addVectors(e,t){return this.x=e.x+t.x,this.y=e.y+t.y,this}addScaledVector(e,t){return this.x+=e.x*t,this.y+=e.y*t,this}sub(e,t){return t!==void 0?(console.warn("THREE.Vector2: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(e,t)):(this.x-=e.x,this.y-=e.y,this)}subScalar(e){return this.x-=e,this.y-=e,this}subVectors(e,t){return this.x=e.x-t.x,this.y=e.y-t.y,this}multiply(e){return this.x*=e.x,this.y*=e.y,this}multiplyScalar(e){return this.x*=e,this.y*=e,this}divide(e){return this.x/=e.x,this.y/=e.y,this}divideScalar(e){return this.multiplyScalar(1/e)}applyMatrix3(e){const t=this.x,n=this.y,r=e.elements;return this.x=r[0]*t+r[3]*n+r[6],this.y=r[1]*t+r[4]*n+r[7],this}min(e){return this.x=Math.min(this.x,e.x),this.y=Math.min(this.y,e.y),this}max(e){return this.x=Math.max(this.x,e.x),this.y=Math.max(this.y,e.y),this}clamp(e,t){return this.x=Math.max(e.x,Math.min(t.x,this.x)),this.y=Math.max(e.y,Math.min(t.y,this.y)),this}clampScalar(e,t){return this.x=Math.max(e,Math.min(t,this.x)),this.y=Math.max(e,Math.min(t,this.y)),this}clampLength(e,t){const n=this.length();return this.divideScalar(n||1).multiplyScalar(Math.max(e,Math.min(t,n)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this}negate(){return this.x=-this.x,this.y=-this.y,this}dot(e){return this.x*e.x+this.y*e.y}cross(e){return this.x*e.y-this.y*e.x}lengthSq(){return this.x*this.x+this.y*this.y}length(){return Math.sqrt(this.x*this.x+this.y*this.y)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)}normalize(){return this.divideScalar(this.length()||1)}angle(){return Math.atan2(-this.y,-this.x)+Math.PI}distanceTo(e){return Math.sqrt(this.distanceToSquared(e))}distanceToSquared(e){const t=this.x-e.x,n=this.y-e.y;return t*t+n*n}manhattanDistanceTo(e){return Math.abs(this.x-e.x)+Math.abs(this.y-e.y)}setLength(e){return this.normalize().multiplyScalar(e)}lerp(e,t){return this.x+=(e.x-this.x)*t,this.y+=(e.y-this.y)*t,this}lerpVectors(e,t,n){return this.x=e.x+(t.x-e.x)*n,this.y=e.y+(t.y-e.y)*n,this}equals(e){return e.x===this.x&&e.y===this.y}fromArray(e,t=0){return this.x=e[t],this.y=e[t+1],this}toArray(e=[],t=0){return e[t]=this.x,e[t+1]=this.y,e}fromBufferAttribute(e,t,n){return n!==void 0&&console.warn("THREE.Vector2: offset has been removed from .fromBufferAttribute()."),this.x=e.getX(t),this.y=e.getY(t),this}rotateAround(e,t){const n=Math.cos(t),r=Math.sin(t),s=this.x-e.x,o=this.y-e.y;return this.x=s*n-o*r+e.x,this.y=s*r+o*n+e.y,this}random(){return this.x=Math.random(),this.y=Math.random(),this}*[Symbol.iterator](){yield this.x,yield this.y}}ee.prototype.isVector2=!0;class B0{constructor(){this.elements=[1,0,0,0,1,0,0,0,1],arguments.length>0&&console.error("THREE.Matrix3: the constructor no longer reads arguments. use .set() instead.")}set(e,t,n,r,s,o,a,l,c){const u=this.elements;return u[0]=e,u[1]=r,u[2]=a,u[3]=t,u[4]=s,u[5]=l,u[6]=n,u[7]=o,u[8]=c,this}identity(){return this.set(1,0,0,0,1,0,0,0,1),this}copy(e){const t=this.elements,n=e.elements;return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=n[4],t[5]=n[5],t[6]=n[6],t[7]=n[7],t[8]=n[8],this}extractBasis(e,t,n){return e.setFromMatrix3Column(this,0),t.setFromMatrix3Column(this,1),n.setFromMatrix3Column(this,2),this}setFromMatrix4(e){const t=e.elements;return this.set(t[0],t[4],t[8],t[1],t[5],t[9],t[2],t[6],t[10]),this}multiply(e){return this.multiplyMatrices(this,e)}premultiply(e){return this.multiplyMatrices(e,this)}multiplyMatrices(e,t){const n=e.elements,r=t.elements,s=this.elements,o=n[0],a=n[3],l=n[6],c=n[1],u=n[4],h=n[7],f=n[2],d=n[5],g=n[8],v=r[0],_=r[3],m=r[6],p=r[1],y=r[4],x=r[7],w=r[2],A=r[5],b=r[8];return s[0]=o*v+a*p+l*w,s[3]=o*_+a*y+l*A,s[6]=o*m+a*x+l*b,s[1]=c*v+u*p+h*w,s[4]=c*_+u*y+h*A,s[7]=c*m+u*x+h*b,s[2]=f*v+d*p+g*w,s[5]=f*_+d*y+g*A,s[8]=f*m+d*x+g*b,this}multiplyScalar(e){const t=this.elements;return t[0]*=e,t[3]*=e,t[6]*=e,t[1]*=e,t[4]*=e,t[7]*=e,t[2]*=e,t[5]*=e,t[8]*=e,this}determinant(){const e=this.elements,t=e[0],n=e[1],r=e[2],s=e[3],o=e[4],a=e[5],l=e[6],c=e[7],u=e[8];return t*o*u-t*a*c-n*s*u+n*a*l+r*s*c-r*o*l}invert(){const e=this.elements,t=e[0],n=e[1],r=e[2],s=e[3],o=e[4],a=e[5],l=e[6],c=e[7],u=e[8],h=u*o-a*c,f=a*l-u*s,d=c*s-o*l,g=t*h+n*f+r*d;if(g===0)return this.set(0,0,0,0,0,0,0,0,0);const v=1/g;return e[0]=h*v,e[1]=(r*c-u*n)*v,e[2]=(a*n-r*o)*v,e[3]=f*v,e[4]=(u*t-r*l)*v,e[5]=(r*s-a*t)*v,e[6]=d*v,e[7]=(n*l-c*t)*v,e[8]=(o*t-n*s)*v,this}transpose(){let e;const t=this.elements;return e=t[1],t[1]=t[3],t[3]=e,e=t[2],t[2]=t[6],t[6]=e,e=t[5],t[5]=t[7],t[7]=e,this}getNormalMatrix(e){return this.setFromMatrix4(e).invert().transpose()}transposeIntoArray(e){const t=this.elements;return e[0]=t[0],e[1]=t[3],e[2]=t[6],e[3]=t[1],e[4]=t[4],e[5]=t[7],e[6]=t[2],e[7]=t[5],e[8]=t[8],this}setUvTransform(e,t,n,r,s,o,a){const l=Math.cos(s),c=Math.sin(s);return this.set(n*l,n*c,-n*(l*o+c*a)+o+e,-r*c,r*l,-r*(-c*o+l*a)+a+t,0,0,1),this}scale(e,t){const n=this.elements;return n[0]*=e,n[3]*=e,n[6]*=e,n[1]*=t,n[4]*=t,n[7]*=t,this}rotate(e){const t=Math.cos(e),n=Math.sin(e),r=this.elements,s=r[0],o=r[3],a=r[6],l=r[1],c=r[4],u=r[7];return r[0]=t*s+n*l,r[3]=t*o+n*c,r[6]=t*a+n*u,r[1]=-n*s+t*l,r[4]=-n*o+t*c,r[7]=-n*a+t*u,this}translate(e,t){const n=this.elements;return n[0]+=e*n[2],n[3]+=e*n[5],n[6]+=e*n[8],n[1]+=t*n[2],n[4]+=t*n[5],n[7]+=t*n[8],this}equals(e){const t=this.elements,n=e.elements;for(let r=0;r<9;r++)if(t[r]!==n[r])return!1;return!0}fromArray(e,t=0){for(let n=0;n<9;n++)this.elements[n]=e[n+t];return this}toArray(e=[],t=0){const n=this.elements;return e[t]=n[0],e[t+1]=n[1],e[t+2]=n[2],e[t+3]=n[3],e[t+4]=n[4],e[t+5]=n[5],e[t+6]=n[6],e[t+7]=n[7],e[t+8]=n[8],e}clone(){return new this.constructor().fromArray(this.elements)}}B0.prototype.isMatrix3=!0;function b4(i){if(i.length===0)return-1/0;let e=i[0];for(let t=1,n=i.length;te&&(e=i[t]);return e}function yl(i){return document.createElementNS("http://www.w3.org/1999/xhtml",i)}function fu(i,e=0){let t=3735928559^e,n=1103547991^e;for(let r=0,s;r>>16,2246822507)^Math.imul(n^n>>>13,3266489909),n=Math.imul(n^n>>>16,2246822507)^Math.imul(t^t>>>13,3266489909),4294967296*(2097151&n)+(t>>>0)}let Xi;class Kr{static getDataURL(e){if(/^data:/i.test(e.src)||typeof HTMLCanvasElement>"u")return e.src;let t;if(e instanceof HTMLCanvasElement)t=e;else{Xi===void 0&&(Xi=yl("canvas")),Xi.width=e.width,Xi.height=e.height;const n=Xi.getContext("2d");e instanceof ImageData?n.putImageData(e,0,0):n.drawImage(e,0,0,e.width,e.height),t=Xi}return t.width>2048||t.height>2048?(console.warn("THREE.ImageUtils.getDataURL: Image converted to jpg for performance reasons",e),t.toDataURL("image/jpeg",.6)):t.toDataURL("image/png")}}let Iv=0,A0=class ec extends ni{constructor(e=ec.DEFAULT_IMAGE,t=ec.DEFAULT_MAPPING,n=m0,r=m0,s=s0,o=Ni,a=a0,l=Kn,c=1,u=J0){super(),Object.defineProperty(this,"id",{value:Iv++}),this.uuid=yt(),this.name="",this.image=e,this.mipmaps=[],this.mapping=t,this.wrapS=n,this.wrapT=r,this.magFilter=s,this.minFilter=o,this.anisotropy=c,this.format=a,this.internalFormat=null,this.type=l,this.offset=new ee(0,0),this.repeat=new ee(1,1),this.center=new ee(0,0),this.rotation=0,this.matrixAutoUpdate=!0,this.matrix=new B0,this.generateMipmaps=!0,this.premultiplyAlpha=!1,this.flipY=!0,this.unpackAlignment=4,this.encoding=u,this.userData={},this.version=0,this.onUpdate=null,this.isRenderTargetTexture=!1}updateMatrix(){this.matrix.setUvTransform(this.offset.x,this.offset.y,this.repeat.x,this.repeat.y,this.rotation,this.center.x,this.center.y)}clone(){return new this.constructor().copy(this)}copy(e){return this.name=e.name,this.image=e.image,this.mipmaps=e.mipmaps.slice(0),this.mapping=e.mapping,this.wrapS=e.wrapS,this.wrapT=e.wrapT,this.magFilter=e.magFilter,this.minFilter=e.minFilter,this.anisotropy=e.anisotropy,this.format=e.format,this.internalFormat=e.internalFormat,this.type=e.type,this.offset.copy(e.offset),this.repeat.copy(e.repeat),this.center.copy(e.center),this.rotation=e.rotation,this.matrixAutoUpdate=e.matrixAutoUpdate,this.matrix.copy(e.matrix),this.generateMipmaps=e.generateMipmaps,this.premultiplyAlpha=e.premultiplyAlpha,this.flipY=e.flipY,this.unpackAlignment=e.unpackAlignment,this.encoding=e.encoding,this.userData=JSON.parse(JSON.stringify(e.userData)),this}toJSON(e){const t=e===void 0||typeof e=="string";if(!t&&e.textures[this.uuid]!==void 0)return e.textures[this.uuid];const n={metadata:{version:4.5,type:"Texture",generator:"Texture.toJSON"},uuid:this.uuid,name:this.name,mapping:this.mapping,repeat:[this.repeat.x,this.repeat.y],offset:[this.offset.x,this.offset.y],center:[this.center.x,this.center.y],rotation:this.rotation,wrap:[this.wrapS,this.wrapT],format:this.format,type:this.type,encoding:this.encoding,minFilter:this.minFilter,magFilter:this.magFilter,anisotropy:this.anisotropy,flipY:this.flipY,premultiplyAlpha:this.premultiplyAlpha,unpackAlignment:this.unpackAlignment};if(this.image!==void 0){const r=this.image;if(r.uuid===void 0&&(r.uuid=yt()),!t&&e.images[r.uuid]===void 0){let s;if(Array.isArray(r)){s=[];for(let o=0,a=r.length;o1)switch(this.wrapS){case Qt:e.x=e.x-Math.floor(e.x);break;case m0:e.x=e.x<0?0:1;break;case Wa:Math.abs(Math.floor(e.x)%2)===1?e.x=Math.ceil(e.x)-e.x:e.x=e.x-Math.floor(e.x);break}if(e.y<0||e.y>1)switch(this.wrapT){case Qt:e.y=e.y-Math.floor(e.y);break;case m0:e.y=e.y<0?0:1;break;case Wa:Math.abs(Math.floor(e.y)%2)===1?e.y=Math.ceil(e.y)-e.y:e.y=e.y-Math.floor(e.y);break}return this.flipY&&(e.y=1-e.y),e}set needsUpdate(e){e===!0&&this.version++}};A0.DEFAULT_IMAGE=void 0;A0.DEFAULT_MAPPING=mr;A0.prototype.isTexture=!0;function Xl(i){return typeof HTMLImageElement<"u"&&i instanceof HTMLImageElement||typeof HTMLCanvasElement<"u"&&i instanceof HTMLCanvasElement||typeof ImageBitmap<"u"&&i instanceof ImageBitmap?Kr.getDataURL(i):i.data?{data:Array.prototype.slice.call(i.data),width:i.width,height:i.height,type:i.data.constructor.name}:(console.warn("THREE.Texture: Unable to serialize Texture."),{})}class $e{constructor(e=0,t=0,n=0,r=1){this.x=e,this.y=t,this.z=n,this.w=r}get width(){return this.z}set width(e){this.z=e}get height(){return this.w}set height(e){this.w=e}set(e,t,n,r){return this.x=e,this.y=t,this.z=n,this.w=r,this}setScalar(e){return this.x=e,this.y=e,this.z=e,this.w=e,this}setX(e){return this.x=e,this}setY(e){return this.y=e,this}setZ(e){return this.z=e,this}setW(e){return this.w=e,this}setComponent(e,t){switch(e){case 0:this.x=t;break;case 1:this.y=t;break;case 2:this.z=t;break;case 3:this.w=t;break;default:throw new Error("index is out of range: "+e)}return this}getComponent(e){switch(e){case 0:return this.x;case 1:return this.y;case 2:return this.z;case 3:return this.w;default:throw new Error("index is out of range: "+e)}}clone(){return new this.constructor(this.x,this.y,this.z,this.w)}copy(e){return this.x=e.x,this.y=e.y,this.z=e.z,this.w=e.w!==void 0?e.w:1,this}add(e,t){return t!==void 0?(console.warn("THREE.Vector4: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(e,t)):(this.x+=e.x,this.y+=e.y,this.z+=e.z,this.w+=e.w,this)}addScalar(e){return this.x+=e,this.y+=e,this.z+=e,this.w+=e,this}addVectors(e,t){return this.x=e.x+t.x,this.y=e.y+t.y,this.z=e.z+t.z,this.w=e.w+t.w,this}addScaledVector(e,t){return this.x+=e.x*t,this.y+=e.y*t,this.z+=e.z*t,this.w+=e.w*t,this}sub(e,t){return t!==void 0?(console.warn("THREE.Vector4: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(e,t)):(this.x-=e.x,this.y-=e.y,this.z-=e.z,this.w-=e.w,this)}subScalar(e){return this.x-=e,this.y-=e,this.z-=e,this.w-=e,this}subVectors(e,t){return this.x=e.x-t.x,this.y=e.y-t.y,this.z=e.z-t.z,this.w=e.w-t.w,this}multiply(e){return this.x*=e.x,this.y*=e.y,this.z*=e.z,this.w*=e.w,this}multiplyScalar(e){return this.x*=e,this.y*=e,this.z*=e,this.w*=e,this}applyMatrix4(e){const t=this.x,n=this.y,r=this.z,s=this.w,o=e.elements;return this.x=o[0]*t+o[4]*n+o[8]*r+o[12]*s,this.y=o[1]*t+o[5]*n+o[9]*r+o[13]*s,this.z=o[2]*t+o[6]*n+o[10]*r+o[14]*s,this.w=o[3]*t+o[7]*n+o[11]*r+o[15]*s,this}divideScalar(e){return this.multiplyScalar(1/e)}setAxisAngleFromQuaternion(e){this.w=2*Math.acos(e.w);const t=Math.sqrt(1-e.w*e.w);return t<1e-4?(this.x=1,this.y=0,this.z=0):(this.x=e.x/t,this.y=e.y/t,this.z=e.z/t),this}setAxisAngleFromRotationMatrix(e){let t,n,r,s;const l=e.elements,c=l[0],u=l[4],h=l[8],f=l[1],d=l[5],g=l[9],v=l[2],_=l[6],m=l[10];if(Math.abs(u-f)<.01&&Math.abs(h-v)<.01&&Math.abs(g-_)<.01){if(Math.abs(u+f)<.1&&Math.abs(h+v)<.1&&Math.abs(g+_)<.1&&Math.abs(c+d+m-3)<.1)return this.set(1,0,0,0),this;t=Math.PI;const y=(c+1)/2,x=(d+1)/2,w=(m+1)/2,A=(u+f)/4,b=(h+v)/4,L=(g+_)/4;return y>x&&y>w?y<.01?(n=0,r=.707106781,s=.707106781):(n=Math.sqrt(y),r=A/n,s=b/n):x>w?x<.01?(n=.707106781,r=0,s=.707106781):(r=Math.sqrt(x),n=A/r,s=L/r):w<.01?(n=.707106781,r=.707106781,s=0):(s=Math.sqrt(w),n=b/s,r=L/s),this.set(n,r,s,t),this}let p=Math.sqrt((_-g)*(_-g)+(h-v)*(h-v)+(f-u)*(f-u));return Math.abs(p)<.001&&(p=1),this.x=(_-g)/p,this.y=(h-v)/p,this.z=(f-u)/p,this.w=Math.acos((c+d+m-1)/2),this}min(e){return this.x=Math.min(this.x,e.x),this.y=Math.min(this.y,e.y),this.z=Math.min(this.z,e.z),this.w=Math.min(this.w,e.w),this}max(e){return this.x=Math.max(this.x,e.x),this.y=Math.max(this.y,e.y),this.z=Math.max(this.z,e.z),this.w=Math.max(this.w,e.w),this}clamp(e,t){return this.x=Math.max(e.x,Math.min(t.x,this.x)),this.y=Math.max(e.y,Math.min(t.y,this.y)),this.z=Math.max(e.z,Math.min(t.z,this.z)),this.w=Math.max(e.w,Math.min(t.w,this.w)),this}clampScalar(e,t){return this.x=Math.max(e,Math.min(t,this.x)),this.y=Math.max(e,Math.min(t,this.y)),this.z=Math.max(e,Math.min(t,this.z)),this.w=Math.max(e,Math.min(t,this.w)),this}clampLength(e,t){const n=this.length();return this.divideScalar(n||1).multiplyScalar(Math.max(e,Math.min(t,n)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this.w=Math.floor(this.w),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this.w=Math.ceil(this.w),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this.w=Math.round(this.w),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this.z=this.z<0?Math.ceil(this.z):Math.floor(this.z),this.w=this.w<0?Math.ceil(this.w):Math.floor(this.w),this}negate(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this.w=-this.w,this}dot(e){return this.x*e.x+this.y*e.y+this.z*e.z+this.w*e.w}lengthSq(){return this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w}length(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)+Math.abs(this.w)}normalize(){return this.divideScalar(this.length()||1)}setLength(e){return this.normalize().multiplyScalar(e)}lerp(e,t){return this.x+=(e.x-this.x)*t,this.y+=(e.y-this.y)*t,this.z+=(e.z-this.z)*t,this.w+=(e.w-this.w)*t,this}lerpVectors(e,t,n){return this.x=e.x+(t.x-e.x)*n,this.y=e.y+(t.y-e.y)*n,this.z=e.z+(t.z-e.z)*n,this.w=e.w+(t.w-e.w)*n,this}equals(e){return e.x===this.x&&e.y===this.y&&e.z===this.z&&e.w===this.w}fromArray(e,t=0){return this.x=e[t],this.y=e[t+1],this.z=e[t+2],this.w=e[t+3],this}toArray(e=[],t=0){return e[t]=this.x,e[t+1]=this.y,e[t+2]=this.z,e[t+3]=this.w,e}fromBufferAttribute(e,t,n){return n!==void 0&&console.warn("THREE.Vector4: offset has been removed from .fromBufferAttribute()."),this.x=e.getX(t),this.y=e.getY(t),this.z=e.getZ(t),this.w=e.getW(t),this}random(){return this.x=Math.random(),this.y=Math.random(),this.z=Math.random(),this.w=Math.random(),this}*[Symbol.iterator](){yield this.x,yield this.y,yield this.z,yield this.w}}$e.prototype.isVector4=!0;class C0 extends ni{constructor(e,t,n={}){super(),this.width=e,this.height=t,this.depth=1,this.scissor=new $e(0,0,e,t),this.scissorTest=!1,this.viewport=new $e(0,0,e,t),this.texture=new A0(void 0,n.mapping,n.wrapS,n.wrapT,n.magFilter,n.minFilter,n.format,n.type,n.anisotropy,n.encoding),this.texture.isRenderTargetTexture=!0,this.texture.image={width:e,height:t,depth:1},this.texture.generateMipmaps=n.generateMipmaps!==void 0?n.generateMipmaps:!1,this.texture.internalFormat=n.internalFormat!==void 0?n.internalFormat:null,this.texture.minFilter=n.minFilter!==void 0?n.minFilter:s0,this.depthBuffer=n.depthBuffer!==void 0?n.depthBuffer:!0,this.stencilBuffer=n.stencilBuffer!==void 0?n.stencilBuffer:!1,this.depthTexture=n.depthTexture!==void 0?n.depthTexture:null}setTexture(e){e.image={width:this.width,height:this.height,depth:this.depth},this.texture=e}setSize(e,t,n=1){(this.width!==e||this.height!==t||this.depth!==n)&&(this.width=e,this.height=t,this.depth=n,this.texture.image.width=e,this.texture.image.height=t,this.texture.image.depth=n,this.dispose()),this.viewport.set(0,0,e,t),this.scissor.set(0,0,e,t)}clone(){return new this.constructor().copy(this)}copy(e){return this.width=e.width,this.height=e.height,this.depth=e.depth,this.viewport.copy(e.viewport),this.texture=e.texture.clone(),this.texture.image={...this.texture.image},this.depthBuffer=e.depthBuffer,this.stencilBuffer=e.stencilBuffer,this.depthTexture=e.depthTexture,this}dispose(){this.dispatchEvent({type:"dispose"})}}C0.prototype.isWebGLRenderTarget=!0;class Dv extends C0{constructor(e,t,n){super(e,t);const r=this.texture;this.texture=[];for(let s=0;s=0?1:-1,y=1-m*m;if(y>Number.EPSILON){const w=Math.sqrt(y),A=Math.atan2(w,m*p);_=Math.sin(_*A)/w,a=Math.sin(a*A)/w}const x=a*p;if(l=l*_+f*x,c=c*_+d*x,u=u*_+g*x,h=h*_+v*x,_===1-a){const w=1/Math.sqrt(l*l+c*c+u*u+h*h);l*=w,c*=w,u*=w,h*=w}}e[t]=l,e[t+1]=c,e[t+2]=u,e[t+3]=h}static multiplyQuaternionsFlat(e,t,n,r,s,o){const a=n[r],l=n[r+1],c=n[r+2],u=n[r+3],h=s[o],f=s[o+1],d=s[o+2],g=s[o+3];return e[t]=a*g+u*h+l*d-c*f,e[t+1]=l*g+u*f+c*h-a*d,e[t+2]=c*g+u*d+a*f-l*h,e[t+3]=u*g-a*h-l*f-c*d,e}get x(){return this._x}set x(e){this._x=e,this._onChangeCallback()}get y(){return this._y}set y(e){this._y=e,this._onChangeCallback()}get z(){return this._z}set z(e){this._z=e,this._onChangeCallback()}get w(){return this._w}set w(e){this._w=e,this._onChangeCallback()}set(e,t,n,r){return this._x=e,this._y=t,this._z=n,this._w=r,this._onChangeCallback(),this}clone(){return new this.constructor(this._x,this._y,this._z,this._w)}copy(e){return this._x=e.x,this._y=e.y,this._z=e.z,this._w=e.w,this._onChangeCallback(),this}setFromEuler(e,t){if(!(e&&e.isEuler))throw new Error("THREE.Quaternion: .setFromEuler() now expects an Euler rotation rather than a Vector3 and order.");const n=e._x,r=e._y,s=e._z,o=e._order,a=Math.cos,l=Math.sin,c=a(n/2),u=a(r/2),h=a(s/2),f=l(n/2),d=l(r/2),g=l(s/2);switch(o){case"XYZ":this._x=f*u*h+c*d*g,this._y=c*d*h-f*u*g,this._z=c*u*g+f*d*h,this._w=c*u*h-f*d*g;break;case"YXZ":this._x=f*u*h+c*d*g,this._y=c*d*h-f*u*g,this._z=c*u*g-f*d*h,this._w=c*u*h+f*d*g;break;case"ZXY":this._x=f*u*h-c*d*g,this._y=c*d*h+f*u*g,this._z=c*u*g+f*d*h,this._w=c*u*h-f*d*g;break;case"ZYX":this._x=f*u*h-c*d*g,this._y=c*d*h+f*u*g,this._z=c*u*g-f*d*h,this._w=c*u*h+f*d*g;break;case"YZX":this._x=f*u*h+c*d*g,this._y=c*d*h+f*u*g,this._z=c*u*g-f*d*h,this._w=c*u*h-f*d*g;break;case"XZY":this._x=f*u*h-c*d*g,this._y=c*d*h-f*u*g,this._z=c*u*g+f*d*h,this._w=c*u*h+f*d*g;break;default:console.warn("THREE.Quaternion: .setFromEuler() encountered an unknown order: "+o)}return t!==!1&&this._onChangeCallback(),this}setFromAxisAngle(e,t){const n=t/2,r=Math.sin(n);return this._x=e.x*r,this._y=e.y*r,this._z=e.z*r,this._w=Math.cos(n),this._onChangeCallback(),this}setFromRotationMatrix(e){const t=e.elements,n=t[0],r=t[4],s=t[8],o=t[1],a=t[5],l=t[9],c=t[2],u=t[6],h=t[10],f=n+a+h;if(f>0){const d=.5/Math.sqrt(f+1);this._w=.25/d,this._x=(u-l)*d,this._y=(s-c)*d,this._z=(o-r)*d}else if(n>a&&n>h){const d=2*Math.sqrt(1+n-a-h);this._w=(u-l)/d,this._x=.25*d,this._y=(r+o)/d,this._z=(s+c)/d}else if(a>h){const d=2*Math.sqrt(1+a-n-h);this._w=(s-c)/d,this._x=(r+o)/d,this._y=.25*d,this._z=(l+u)/d}else{const d=2*Math.sqrt(1+h-n-a);this._w=(o-r)/d,this._x=(s+c)/d,this._y=(l+u)/d,this._z=.25*d}return this._onChangeCallback(),this}setFromUnitVectors(e,t){let n=e.dot(t)+1;return nMath.abs(e.z)?(this._x=-e.y,this._y=e.x,this._z=0,this._w=n):(this._x=0,this._y=-e.z,this._z=e.y,this._w=n)):(this._x=e.y*t.z-e.z*t.y,this._y=e.z*t.x-e.x*t.z,this._z=e.x*t.y-e.y*t.x,this._w=n),this.normalize()}angleTo(e){return 2*Math.acos(Math.abs(Q0(this.dot(e),-1,1)))}rotateTowards(e,t){const n=this.angleTo(e);if(n===0)return this;const r=Math.min(1,t/n);return this.slerp(e,r),this}identity(){return this.set(0,0,0,1)}invert(){return this.conjugate()}conjugate(){return this._x*=-1,this._y*=-1,this._z*=-1,this._onChangeCallback(),this}dot(e){return this._x*e._x+this._y*e._y+this._z*e._z+this._w*e._w}lengthSq(){return this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w}length(){return Math.sqrt(this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w)}normalize(){let e=this.length();return e===0?(this._x=0,this._y=0,this._z=0,this._w=1):(e=1/e,this._x=this._x*e,this._y=this._y*e,this._z=this._z*e,this._w=this._w*e),this._onChangeCallback(),this}multiply(e,t){return t!==void 0?(console.warn("THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead."),this.multiplyQuaternions(e,t)):this.multiplyQuaternions(this,e)}premultiply(e){return this.multiplyQuaternions(e,this)}multiplyQuaternions(e,t){const n=e._x,r=e._y,s=e._z,o=e._w,a=t._x,l=t._y,c=t._z,u=t._w;return this._x=n*u+o*a+r*c-s*l,this._y=r*u+o*l+s*a-n*c,this._z=s*u+o*c+n*l-r*a,this._w=o*u-n*a-r*l-s*c,this._onChangeCallback(),this}slerp(e,t){if(t===0)return this;if(t===1)return this.copy(e);const n=this._x,r=this._y,s=this._z,o=this._w;let a=o*e._w+n*e._x+r*e._y+s*e._z;if(a<0?(this._w=-e._w,this._x=-e._x,this._y=-e._y,this._z=-e._z,a=-a):this.copy(e),a>=1)return this._w=o,this._x=n,this._y=r,this._z=s,this;const l=1-a*a;if(l<=Number.EPSILON){const d=1-t;return this._w=d*o+t*this._w,this._x=d*n+t*this._x,this._y=d*r+t*this._y,this._z=d*s+t*this._z,this.normalize(),this._onChangeCallback(),this}const c=Math.sqrt(l),u=Math.atan2(c,a),h=Math.sin((1-t)*u)/c,f=Math.sin(t*u)/c;return this._w=o*h+this._w*f,this._x=n*h+this._x*f,this._y=r*h+this._y*f,this._z=s*h+this._z*f,this._onChangeCallback(),this}slerpQuaternions(e,t,n){this.copy(e).slerp(t,n)}random(){const e=Math.random(),t=Math.sqrt(1-e),n=Math.sqrt(e),r=2*Math.PI*Math.random(),s=2*Math.PI*Math.random();return this.set(t*Math.cos(r),n*Math.sin(s),n*Math.cos(s),t*Math.sin(r))}equals(e){return e._x===this._x&&e._y===this._y&&e._z===this._z&&e._w===this._w}fromArray(e,t=0){return this._x=e[t],this._y=e[t+1],this._z=e[t+2],this._w=e[t+3],this._onChangeCallback(),this}toArray(e=[],t=0){return e[t]=this._x,e[t+1]=this._y,e[t+2]=this._z,e[t+3]=this._w,e}fromBufferAttribute(e,t){return this._x=e.getX(t),this._y=e.getY(t),this._z=e.getZ(t),this._w=e.getW(t),this}_onChange(e){return this._onChangeCallback=e,this}_onChangeCallback(){}}S0.prototype.isQuaternion=!0;class P{constructor(e=0,t=0,n=0){this.x=e,this.y=t,this.z=n}set(e,t,n){return n===void 0&&(n=this.z),this.x=e,this.y=t,this.z=n,this}setScalar(e){return this.x=e,this.y=e,this.z=e,this}setX(e){return this.x=e,this}setY(e){return this.y=e,this}setZ(e){return this.z=e,this}setComponent(e,t){switch(e){case 0:this.x=t;break;case 1:this.y=t;break;case 2:this.z=t;break;default:throw new Error("index is out of range: "+e)}return this}getComponent(e){switch(e){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw new Error("index is out of range: "+e)}}clone(){return new this.constructor(this.x,this.y,this.z)}copy(e){return this.x=e.x,this.y=e.y,this.z=e.z,this}add(e,t){return t!==void 0?(console.warn("THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(e,t)):(this.x+=e.x,this.y+=e.y,this.z+=e.z,this)}addScalar(e){return this.x+=e,this.y+=e,this.z+=e,this}addVectors(e,t){return this.x=e.x+t.x,this.y=e.y+t.y,this.z=e.z+t.z,this}addScaledVector(e,t){return this.x+=e.x*t,this.y+=e.y*t,this.z+=e.z*t,this}sub(e,t){return t!==void 0?(console.warn("THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(e,t)):(this.x-=e.x,this.y-=e.y,this.z-=e.z,this)}subScalar(e){return this.x-=e,this.y-=e,this.z-=e,this}subVectors(e,t){return this.x=e.x-t.x,this.y=e.y-t.y,this.z=e.z-t.z,this}multiply(e,t){return t!==void 0?(console.warn("THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead."),this.multiplyVectors(e,t)):(this.x*=e.x,this.y*=e.y,this.z*=e.z,this)}multiplyScalar(e){return this.x*=e,this.y*=e,this.z*=e,this}multiplyVectors(e,t){return this.x=e.x*t.x,this.y=e.y*t.y,this.z=e.z*t.z,this}applyEuler(e){return e&&e.isEuler||console.error("THREE.Vector3: .applyEuler() now expects an Euler rotation rather than a Vector3 and order."),this.applyQuaternion(du.setFromEuler(e))}applyAxisAngle(e,t){return this.applyQuaternion(du.setFromAxisAngle(e,t))}applyMatrix3(e){const t=this.x,n=this.y,r=this.z,s=e.elements;return this.x=s[0]*t+s[3]*n+s[6]*r,this.y=s[1]*t+s[4]*n+s[7]*r,this.z=s[2]*t+s[5]*n+s[8]*r,this}applyNormalMatrix(e){return this.applyMatrix3(e).normalize()}applyMatrix4(e){const t=this.x,n=this.y,r=this.z,s=e.elements,o=1/(s[3]*t+s[7]*n+s[11]*r+s[15]);return this.x=(s[0]*t+s[4]*n+s[8]*r+s[12])*o,this.y=(s[1]*t+s[5]*n+s[9]*r+s[13])*o,this.z=(s[2]*t+s[6]*n+s[10]*r+s[14])*o,this}applyQuaternion(e){const t=this.x,n=this.y,r=this.z,s=e.x,o=e.y,a=e.z,l=e.w,c=l*t+o*r-a*n,u=l*n+a*t-s*r,h=l*r+s*n-o*t,f=-s*t-o*n-a*r;return this.x=c*l+f*-s+u*-a-h*-o,this.y=u*l+f*-o+h*-s-c*-a,this.z=h*l+f*-a+c*-o-u*-s,this}project(e){return this.applyMatrix4(e.matrixWorldInverse).applyMatrix4(e.projectionMatrix)}unproject(e){return this.applyMatrix4(e.projectionMatrixInverse).applyMatrix4(e.matrixWorld)}transformDirection(e){const t=this.x,n=this.y,r=this.z,s=e.elements;return this.x=s[0]*t+s[4]*n+s[8]*r,this.y=s[1]*t+s[5]*n+s[9]*r,this.z=s[2]*t+s[6]*n+s[10]*r,this.normalize()}divide(e){return this.x/=e.x,this.y/=e.y,this.z/=e.z,this}divideScalar(e){return this.multiplyScalar(1/e)}min(e){return this.x=Math.min(this.x,e.x),this.y=Math.min(this.y,e.y),this.z=Math.min(this.z,e.z),this}max(e){return this.x=Math.max(this.x,e.x),this.y=Math.max(this.y,e.y),this.z=Math.max(this.z,e.z),this}clamp(e,t){return this.x=Math.max(e.x,Math.min(t.x,this.x)),this.y=Math.max(e.y,Math.min(t.y,this.y)),this.z=Math.max(e.z,Math.min(t.z,this.z)),this}clampScalar(e,t){return this.x=Math.max(e,Math.min(t,this.x)),this.y=Math.max(e,Math.min(t,this.y)),this.z=Math.max(e,Math.min(t,this.z)),this}clampLength(e,t){const n=this.length();return this.divideScalar(n||1).multiplyScalar(Math.max(e,Math.min(t,n)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this.z=this.z<0?Math.ceil(this.z):Math.floor(this.z),this}negate(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this}dot(e){return this.x*e.x+this.y*e.y+this.z*e.z}lengthSq(){return this.x*this.x+this.y*this.y+this.z*this.z}length(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)}normalize(){return this.divideScalar(this.length()||1)}setLength(e){return this.normalize().multiplyScalar(e)}lerp(e,t){return this.x+=(e.x-this.x)*t,this.y+=(e.y-this.y)*t,this.z+=(e.z-this.z)*t,this}lerpVectors(e,t,n){return this.x=e.x+(t.x-e.x)*n,this.y=e.y+(t.y-e.y)*n,this.z=e.z+(t.z-e.z)*n,this}cross(e,t){return t!==void 0?(console.warn("THREE.Vector3: .cross() now only accepts one argument. Use .crossVectors( a, b ) instead."),this.crossVectors(e,t)):this.crossVectors(this,e)}crossVectors(e,t){const n=e.x,r=e.y,s=e.z,o=t.x,a=t.y,l=t.z;return this.x=r*l-s*a,this.y=s*o-n*l,this.z=n*a-r*o,this}projectOnVector(e){const t=e.lengthSq();if(t===0)return this.set(0,0,0);const n=e.dot(this)/t;return this.copy(e).multiplyScalar(n)}projectOnPlane(e){return jl.copy(this).projectOnVector(e),this.sub(jl)}reflect(e){return this.sub(jl.copy(e).multiplyScalar(2*this.dot(e)))}angleTo(e){const t=Math.sqrt(this.lengthSq()*e.lengthSq());if(t===0)return Math.PI/2;const n=this.dot(e)/t;return Math.acos(Q0(n,-1,1))}distanceTo(e){return Math.sqrt(this.distanceToSquared(e))}distanceToSquared(e){const t=this.x-e.x,n=this.y-e.y,r=this.z-e.z;return t*t+n*n+r*r}manhattanDistanceTo(e){return Math.abs(this.x-e.x)+Math.abs(this.y-e.y)+Math.abs(this.z-e.z)}setFromSpherical(e){return this.setFromSphericalCoords(e.radius,e.phi,e.theta)}setFromSphericalCoords(e,t,n){const r=Math.sin(t)*e;return this.x=r*Math.sin(n),this.y=Math.cos(t)*e,this.z=r*Math.cos(n),this}setFromCylindrical(e){return this.setFromCylindricalCoords(e.radius,e.theta,e.y)}setFromCylindricalCoords(e,t,n){return this.x=e*Math.sin(t),this.y=n,this.z=e*Math.cos(t),this}setFromMatrixPosition(e){const t=e.elements;return this.x=t[12],this.y=t[13],this.z=t[14],this}setFromMatrixScale(e){const t=this.setFromMatrixColumn(e,0).length(),n=this.setFromMatrixColumn(e,1).length(),r=this.setFromMatrixColumn(e,2).length();return this.x=t,this.y=n,this.z=r,this}setFromMatrixColumn(e,t){return this.fromArray(e.elements,t*4)}setFromMatrix3Column(e,t){return this.fromArray(e.elements,t*3)}equals(e){return e.x===this.x&&e.y===this.y&&e.z===this.z}fromArray(e,t=0){return this.x=e[t],this.y=e[t+1],this.z=e[t+2],this}toArray(e=[],t=0){return e[t]=this.x,e[t+1]=this.y,e[t+2]=this.z,e}fromBufferAttribute(e,t,n){return n!==void 0&&console.warn("THREE.Vector3: offset has been removed from .fromBufferAttribute()."),this.x=e.getX(t),this.y=e.getY(t),this.z=e.getZ(t),this}random(){return this.x=Math.random(),this.y=Math.random(),this.z=Math.random(),this}randomDirection(){const e=(Math.random()-.5)*2,t=Math.random()*Math.PI*2,n=Math.sqrt(1-e**2);return this.x=n*Math.cos(t),this.y=n*Math.sin(t),this.z=e,this}*[Symbol.iterator](){yield this.x,yield this.y,yield this.z}}P.prototype.isVector3=!0;const jl=new P,du=new S0;class Mt{constructor(e=new P(1/0,1/0,1/0),t=new P(-1/0,-1/0,-1/0)){this.min=e,this.max=t}set(e,t){return this.min.copy(e),this.max.copy(t),this}setFromArray(e){let t=1/0,n=1/0,r=1/0,s=-1/0,o=-1/0,a=-1/0;for(let l=0,c=e.length;ls&&(s=u),h>o&&(o=h),f>a&&(a=f)}return this.min.set(t,n,r),this.max.set(s,o,a),this}setFromBufferAttribute(e){let t=1/0,n=1/0,r=1/0,s=-1/0,o=-1/0,a=-1/0;for(let l=0,c=e.count;ls&&(s=u),h>o&&(o=h),f>a&&(a=f)}return this.min.set(t,n,r),this.max.set(s,o,a),this}setFromPoints(e){this.makeEmpty();for(let t=0,n=e.length;tthis.max.x||e.ythis.max.y||e.zthis.max.z)}containsBox(e){return this.min.x<=e.min.x&&e.max.x<=this.max.x&&this.min.y<=e.min.y&&e.max.y<=this.max.y&&this.min.z<=e.min.z&&e.max.z<=this.max.z}getParameter(e,t){return t.set((e.x-this.min.x)/(this.max.x-this.min.x),(e.y-this.min.y)/(this.max.y-this.min.y),(e.z-this.min.z)/(this.max.z-this.min.z))}intersectsBox(e){return!(e.max.xthis.max.x||e.max.ythis.max.y||e.max.zthis.max.z)}intersectsSphere(e){return this.clampPoint(e.center,ys),ys.distanceToSquared(e.center)<=e.radius*e.radius}intersectsPlane(e){let t,n;return e.normal.x>0?(t=e.normal.x*this.min.x,n=e.normal.x*this.max.x):(t=e.normal.x*this.max.x,n=e.normal.x*this.min.x),e.normal.y>0?(t+=e.normal.y*this.min.y,n+=e.normal.y*this.max.y):(t+=e.normal.y*this.max.y,n+=e.normal.y*this.min.y),e.normal.z>0?(t+=e.normal.z*this.min.z,n+=e.normal.z*this.max.z):(t+=e.normal.z*this.max.z,n+=e.normal.z*this.min.z),t<=-e.constant&&n>=-e.constant}intersectsTriangle(e){if(this.isEmpty())return!1;this.getCenter(_s),Vo.subVectors(this.max,_s),ji.subVectors(e.a,_s),Yi.subVectors(e.b,_s),qi.subVectors(e.c,_s),Tn.subVectors(Yi,ji),An.subVectors(qi,Yi),gi.subVectors(ji,qi);let t=[0,-Tn.z,Tn.y,0,-An.z,An.y,0,-gi.z,gi.y,Tn.z,0,-Tn.x,An.z,0,-An.x,gi.z,0,-gi.x,-Tn.y,Tn.x,0,-An.y,An.x,0,-gi.y,gi.x,0];return!ql(t,ji,Yi,qi,Vo)||(t=[1,0,0,0,1,0,0,0,1],!ql(t,ji,Yi,qi,Vo))?!1:(Wo.crossVectors(Tn,An),t=[Wo.x,Wo.y,Wo.z],ql(t,ji,Yi,qi,Vo))}clampPoint(e,t){return t.copy(e).clamp(this.min,this.max)}distanceToPoint(e){return ys.copy(e).clamp(this.min,this.max).sub(e).length()}getBoundingSphere(e){return this.getCenter(e.center),e.radius=this.getSize(ys).length()*.5,e}intersect(e){return this.min.max(e.min),this.max.min(e.max),this.isEmpty()&&this.makeEmpty(),this}union(e){return this.min.min(e.min),this.max.max(e.max),this}applyMatrix4(e){return this.isEmpty()?this:(rn[0].set(this.min.x,this.min.y,this.min.z).applyMatrix4(e),rn[1].set(this.min.x,this.min.y,this.max.z).applyMatrix4(e),rn[2].set(this.min.x,this.max.y,this.min.z).applyMatrix4(e),rn[3].set(this.min.x,this.max.y,this.max.z).applyMatrix4(e),rn[4].set(this.max.x,this.min.y,this.min.z).applyMatrix4(e),rn[5].set(this.max.x,this.min.y,this.max.z).applyMatrix4(e),rn[6].set(this.max.x,this.max.y,this.min.z).applyMatrix4(e),rn[7].set(this.max.x,this.max.y,this.max.z).applyMatrix4(e),this.setFromPoints(rn),this)}translate(e){return this.min.add(e),this.max.add(e),this}equals(e){return e.min.equals(this.min)&&e.max.equals(this.max)}}Mt.prototype.isBox3=!0;const rn=[new P,new P,new P,new P,new P,new P,new P,new P],ys=new P,Yl=new Mt,ji=new P,Yi=new P,qi=new P,Tn=new P,An=new P,gi=new P,_s=new P,Vo=new P,Wo=new P,vi=new P;function ql(i,e,t,n,r){for(let s=0,o=i.length-3;s<=o;s+=3){vi.fromArray(i,s);const a=r.x*Math.abs(vi.x)+r.y*Math.abs(vi.y)+r.z*Math.abs(vi.z),l=e.dot(vi),c=t.dot(vi),u=n.dot(vi);if(Math.max(-Math.max(l,c,u),Math.min(l,c,u))>a)return!1}return!0}const Nv=new Mt,pu=new P,Ql=new P,Zl=new P;let Ui=class{constructor(e=new P,t=-1){this.center=e,this.radius=t}set(e,t){return this.center.copy(e),this.radius=t,this}setFromPoints(e,t){const n=this.center;t!==void 0?n.copy(t):Nv.setFromPoints(e).getCenter(n);let r=0;for(let s=0,o=e.length;sthis.radius*this.radius&&(t.sub(this.center).normalize(),t.multiplyScalar(this.radius).add(this.center)),t}getBoundingBox(e){return this.isEmpty()?(e.makeEmpty(),e):(e.set(this.center,this.center),e.expandByScalar(this.radius),e)}applyMatrix4(e){return this.center.applyMatrix4(e),this.radius=this.radius*e.getMaxScaleOnAxis(),this}translate(e){return this.center.add(e),this}expandByPoint(e){Zl.subVectors(e,this.center);const t=Zl.lengthSq();if(t>this.radius*this.radius){const n=Math.sqrt(t),r=(n-this.radius)*.5;this.center.add(Zl.multiplyScalar(r/n)),this.radius+=r}return this}union(e){return Ql.subVectors(e.center,this.center).normalize().multiplyScalar(e.radius),this.expandByPoint(pu.copy(e.center).add(Ql)),this.expandByPoint(pu.copy(e.center).sub(Ql)),this}equals(e){return e.center.equals(this.center)&&e.radius===this.radius}clone(){return new this.constructor().copy(this)}};const sn=new P,Kl=new P,Xo=new P,En=new P,Jl=new P,jo=new P,$l=new P;class zi{constructor(e=new P,t=new P(0,0,-1)){this.origin=e,this.direction=t}set(e,t){return this.origin.copy(e),this.direction.copy(t),this}copy(e){return this.origin.copy(e.origin),this.direction.copy(e.direction),this}at(e,t){return t.copy(this.direction).multiplyScalar(e).add(this.origin)}lookAt(e){return this.direction.copy(e).sub(this.origin).normalize(),this}recast(e){return this.origin.copy(this.at(e,sn)),this}closestPointToPoint(e,t){t.subVectors(e,this.origin);const n=t.dot(this.direction);return n<0?t.copy(this.origin):t.copy(this.direction).multiplyScalar(n).add(this.origin)}distanceToPoint(e){return Math.sqrt(this.distanceSqToPoint(e))}distanceSqToPoint(e){const t=sn.subVectors(e,this.origin).dot(this.direction);return t<0?this.origin.distanceToSquared(e):(sn.copy(this.direction).multiplyScalar(t).add(this.origin),sn.distanceToSquared(e))}distanceSqToSegment(e,t,n,r){Kl.copy(e).add(t).multiplyScalar(.5),Xo.copy(t).sub(e).normalize(),En.copy(this.origin).sub(Kl);const s=e.distanceTo(t)*.5,o=-this.direction.dot(Xo),a=En.dot(this.direction),l=-En.dot(Xo),c=En.lengthSq(),u=Math.abs(1-o*o);let h,f,d,g;if(u>0)if(h=o*l-a,f=o*a-l,g=s*u,h>=0)if(f>=-g)if(f<=g){const v=1/u;h*=v,f*=v,d=h*(h+o*f+2*a)+f*(o*h+f+2*l)+c}else f=s,h=Math.max(0,-(o*f+a)),d=-h*h+f*(f+2*l)+c;else f=-s,h=Math.max(0,-(o*f+a)),d=-h*h+f*(f+2*l)+c;else f<=-g?(h=Math.max(0,-(-o*s+a)),f=h>0?-s:Math.min(Math.max(-s,-l),s),d=-h*h+f*(f+2*l)+c):f<=g?(h=0,f=Math.min(Math.max(-s,-l),s),d=f*(f+2*l)+c):(h=Math.max(0,-(o*s+a)),f=h>0?s:Math.min(Math.max(-s,-l),s),d=-h*h+f*(f+2*l)+c);else f=o>0?-s:s,h=Math.max(0,-(o*f+a)),d=-h*h+f*(f+2*l)+c;return n&&n.copy(this.direction).multiplyScalar(h).add(this.origin),r&&r.copy(Xo).multiplyScalar(f).add(Kl),d}intersectSphere(e,t){sn.subVectors(e.center,this.origin);const n=sn.dot(this.direction),r=sn.dot(sn)-n*n,s=e.radius*e.radius;if(r>s)return null;const o=Math.sqrt(s-r),a=n-o,l=n+o;return a<0&&l<0?null:a<0?this.at(l,t):this.at(a,t)}intersectsSphere(e){return this.distanceSqToPoint(e.center)<=e.radius*e.radius}distanceToPlane(e){const t=e.normal.dot(this.direction);if(t===0)return e.distanceToPoint(this.origin)===0?0:null;const n=-(this.origin.dot(e.normal)+e.constant)/t;return n>=0?n:null}intersectPlane(e,t){const n=this.distanceToPlane(e);return n===null?null:this.at(n,t)}intersectsPlane(e){const t=e.distanceToPoint(this.origin);return t===0||e.normal.dot(this.direction)*t<0}intersectBox(e,t){let n,r,s,o,a,l;const c=1/this.direction.x,u=1/this.direction.y,h=1/this.direction.z,f=this.origin;return c>=0?(n=(e.min.x-f.x)*c,r=(e.max.x-f.x)*c):(n=(e.max.x-f.x)*c,r=(e.min.x-f.x)*c),u>=0?(s=(e.min.y-f.y)*u,o=(e.max.y-f.y)*u):(s=(e.max.y-f.y)*u,o=(e.min.y-f.y)*u),n>o||s>r||((s>n||n!==n)&&(n=s),(o=0?(a=(e.min.z-f.z)*h,l=(e.max.z-f.z)*h):(a=(e.max.z-f.z)*h,l=(e.min.z-f.z)*h),n>l||a>r)||((a>n||n!==n)&&(n=a),(l=0?n:r,t)}intersectsBox(e){return this.intersectBox(e,sn)!==null}intersectTriangle(e,t,n,r,s){Jl.subVectors(t,e),jo.subVectors(n,e),$l.crossVectors(Jl,jo);let o=this.direction.dot($l),a;if(o>0){if(r)return null;a=1}else if(o<0)a=-1,o=-o;else return null;En.subVectors(this.origin,e);const l=a*this.direction.dot(jo.crossVectors(En,jo));if(l<0)return null;const c=a*this.direction.dot(Jl.cross(En));if(c<0||l+c>o)return null;const u=-a*En.dot($l);return u<0?null:this.at(u/o,s)}applyMatrix4(e){return this.origin.applyMatrix4(e),this.direction.transformDirection(e),this}equals(e){return e.origin.equals(this.origin)&&e.direction.equals(this.direction)}clone(){return new this.constructor().copy(this)}}class Me{constructor(){this.elements=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],arguments.length>0&&console.error("THREE.Matrix4: the constructor no longer reads arguments. use .set() instead.")}set(e,t,n,r,s,o,a,l,c,u,h,f,d,g,v,_){const m=this.elements;return m[0]=e,m[4]=t,m[8]=n,m[12]=r,m[1]=s,m[5]=o,m[9]=a,m[13]=l,m[2]=c,m[6]=u,m[10]=h,m[14]=f,m[3]=d,m[7]=g,m[11]=v,m[15]=_,this}identity(){return this.set(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1),this}clone(){return new Me().fromArray(this.elements)}copy(e){const t=this.elements,n=e.elements;return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=n[4],t[5]=n[5],t[6]=n[6],t[7]=n[7],t[8]=n[8],t[9]=n[9],t[10]=n[10],t[11]=n[11],t[12]=n[12],t[13]=n[13],t[14]=n[14],t[15]=n[15],this}copyPosition(e){const t=this.elements,n=e.elements;return t[12]=n[12],t[13]=n[13],t[14]=n[14],this}setFromMatrix3(e){const t=e.elements;return this.set(t[0],t[3],t[6],0,t[1],t[4],t[7],0,t[2],t[5],t[8],0,0,0,0,1),this}extractBasis(e,t,n){return e.setFromMatrixColumn(this,0),t.setFromMatrixColumn(this,1),n.setFromMatrixColumn(this,2),this}makeBasis(e,t,n){return this.set(e.x,t.x,n.x,0,e.y,t.y,n.y,0,e.z,t.z,n.z,0,0,0,0,1),this}extractRotation(e){const t=this.elements,n=e.elements,r=1/Qi.setFromMatrixColumn(e,0).length(),s=1/Qi.setFromMatrixColumn(e,1).length(),o=1/Qi.setFromMatrixColumn(e,2).length();return t[0]=n[0]*r,t[1]=n[1]*r,t[2]=n[2]*r,t[3]=0,t[4]=n[4]*s,t[5]=n[5]*s,t[6]=n[6]*s,t[7]=0,t[8]=n[8]*o,t[9]=n[9]*o,t[10]=n[10]*o,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,this}makeRotationFromEuler(e){e&&e.isEuler||console.error("THREE.Matrix4: .makeRotationFromEuler() now expects a Euler rotation rather than a Vector3 and order.");const t=this.elements,n=e.x,r=e.y,s=e.z,o=Math.cos(n),a=Math.sin(n),l=Math.cos(r),c=Math.sin(r),u=Math.cos(s),h=Math.sin(s);if(e.order==="XYZ"){const f=o*u,d=o*h,g=a*u,v=a*h;t[0]=l*u,t[4]=-l*h,t[8]=c,t[1]=d+g*c,t[5]=f-v*c,t[9]=-a*l,t[2]=v-f*c,t[6]=g+d*c,t[10]=o*l}else if(e.order==="YXZ"){const f=l*u,d=l*h,g=c*u,v=c*h;t[0]=f+v*a,t[4]=g*a-d,t[8]=o*c,t[1]=o*h,t[5]=o*u,t[9]=-a,t[2]=d*a-g,t[6]=v+f*a,t[10]=o*l}else if(e.order==="ZXY"){const f=l*u,d=l*h,g=c*u,v=c*h;t[0]=f-v*a,t[4]=-o*h,t[8]=g+d*a,t[1]=d+g*a,t[5]=o*u,t[9]=v-f*a,t[2]=-o*c,t[6]=a,t[10]=o*l}else if(e.order==="ZYX"){const f=o*u,d=o*h,g=a*u,v=a*h;t[0]=l*u,t[4]=g*c-d,t[8]=f*c+v,t[1]=l*h,t[5]=v*c+f,t[9]=d*c-g,t[2]=-c,t[6]=a*l,t[10]=o*l}else if(e.order==="YZX"){const f=o*l,d=o*c,g=a*l,v=a*c;t[0]=l*u,t[4]=v-f*h,t[8]=g*h+d,t[1]=h,t[5]=o*u,t[9]=-a*u,t[2]=-c*u,t[6]=d*h+g,t[10]=f-v*h}else if(e.order==="XZY"){const f=o*l,d=o*c,g=a*l,v=a*c;t[0]=l*u,t[4]=-h,t[8]=c*u,t[1]=f*h+v,t[5]=o*u,t[9]=d*h-g,t[2]=g*h-d,t[6]=a*u,t[10]=v*h+f}return t[3]=0,t[7]=0,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,this}makeRotationFromQuaternion(e){return this.compose(Ov,e,Uv)}lookAt(e,t,n){const r=this.elements;return ht.subVectors(e,t),ht.lengthSq()===0&&(ht.z=1),ht.normalize(),Ln.crossVectors(n,ht),Ln.lengthSq()===0&&(Math.abs(n.z)===1?ht.x+=1e-4:ht.z+=1e-4,ht.normalize(),Ln.crossVectors(n,ht)),Ln.normalize(),Yo.crossVectors(ht,Ln),r[0]=Ln.x,r[4]=Yo.x,r[8]=ht.x,r[1]=Ln.y,r[5]=Yo.y,r[9]=ht.y,r[2]=Ln.z,r[6]=Yo.z,r[10]=ht.z,this}multiply(e,t){return t!==void 0?(console.warn("THREE.Matrix4: .multiply() now only accepts one argument. Use .multiplyMatrices( a, b ) instead."),this.multiplyMatrices(e,t)):this.multiplyMatrices(this,e)}premultiply(e){return this.multiplyMatrices(e,this)}multiplyMatrices(e,t){const n=e.elements,r=t.elements,s=this.elements,o=n[0],a=n[4],l=n[8],c=n[12],u=n[1],h=n[5],f=n[9],d=n[13],g=n[2],v=n[6],_=n[10],m=n[14],p=n[3],y=n[7],x=n[11],w=n[15],A=r[0],b=r[4],L=r[8],B=r[12],I=r[1],C=r[5],Y=r[9],O=r[13],G=r[2],j=r[6],N=r[10],k=r[14],Z=r[3],le=r[7],ve=r[11],ce=r[15];return s[0]=o*A+a*I+l*G+c*Z,s[4]=o*b+a*C+l*j+c*le,s[8]=o*L+a*Y+l*N+c*ve,s[12]=o*B+a*O+l*k+c*ce,s[1]=u*A+h*I+f*G+d*Z,s[5]=u*b+h*C+f*j+d*le,s[9]=u*L+h*Y+f*N+d*ve,s[13]=u*B+h*O+f*k+d*ce,s[2]=g*A+v*I+_*G+m*Z,s[6]=g*b+v*C+_*j+m*le,s[10]=g*L+v*Y+_*N+m*ve,s[14]=g*B+v*O+_*k+m*ce,s[3]=p*A+y*I+x*G+w*Z,s[7]=p*b+y*C+x*j+w*le,s[11]=p*L+y*Y+x*N+w*ve,s[15]=p*B+y*O+x*k+w*ce,this}multiplyScalar(e){const t=this.elements;return t[0]*=e,t[4]*=e,t[8]*=e,t[12]*=e,t[1]*=e,t[5]*=e,t[9]*=e,t[13]*=e,t[2]*=e,t[6]*=e,t[10]*=e,t[14]*=e,t[3]*=e,t[7]*=e,t[11]*=e,t[15]*=e,this}determinant(){const e=this.elements,t=e[0],n=e[4],r=e[8],s=e[12],o=e[1],a=e[5],l=e[9],c=e[13],u=e[2],h=e[6],f=e[10],d=e[14],g=e[3],v=e[7],_=e[11],m=e[15];return g*(+s*l*h-r*c*h-s*a*f+n*c*f+r*a*d-n*l*d)+v*(+t*l*d-t*c*f+s*o*f-r*o*d+r*c*u-s*l*u)+_*(+t*c*h-t*a*d-s*o*h+n*o*d+s*a*u-n*c*u)+m*(-r*a*u-t*l*h+t*a*f+r*o*h-n*o*f+n*l*u)}transpose(){const e=this.elements;let t;return t=e[1],e[1]=e[4],e[4]=t,t=e[2],e[2]=e[8],e[8]=t,t=e[6],e[6]=e[9],e[9]=t,t=e[3],e[3]=e[12],e[12]=t,t=e[7],e[7]=e[13],e[13]=t,t=e[11],e[11]=e[14],e[14]=t,this}setPosition(e,t,n){const r=this.elements;return e.isVector3?(r[12]=e.x,r[13]=e.y,r[14]=e.z):(r[12]=e,r[13]=t,r[14]=n),this}invert(){const e=this.elements,t=e[0],n=e[1],r=e[2],s=e[3],o=e[4],a=e[5],l=e[6],c=e[7],u=e[8],h=e[9],f=e[10],d=e[11],g=e[12],v=e[13],_=e[14],m=e[15],p=h*_*c-v*f*c+v*l*d-a*_*d-h*l*m+a*f*m,y=g*f*c-u*_*c-g*l*d+o*_*d+u*l*m-o*f*m,x=u*v*c-g*h*c+g*a*d-o*v*d-u*a*m+o*h*m,w=g*h*l-u*v*l-g*a*f+o*v*f+u*a*_-o*h*_,A=t*p+n*y+r*x+s*w;if(A===0)return this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);const b=1/A;return e[0]=p*b,e[1]=(v*f*s-h*_*s-v*r*d+n*_*d+h*r*m-n*f*m)*b,e[2]=(a*_*s-v*l*s+v*r*c-n*_*c-a*r*m+n*l*m)*b,e[3]=(h*l*s-a*f*s-h*r*c+n*f*c+a*r*d-n*l*d)*b,e[4]=y*b,e[5]=(u*_*s-g*f*s+g*r*d-t*_*d-u*r*m+t*f*m)*b,e[6]=(g*l*s-o*_*s-g*r*c+t*_*c+o*r*m-t*l*m)*b,e[7]=(o*f*s-u*l*s+u*r*c-t*f*c-o*r*d+t*l*d)*b,e[8]=x*b,e[9]=(g*h*s-u*v*s-g*n*d+t*v*d+u*n*m-t*h*m)*b,e[10]=(o*v*s-g*a*s+g*n*c-t*v*c-o*n*m+t*a*m)*b,e[11]=(u*a*s-o*h*s-u*n*c+t*h*c+o*n*d-t*a*d)*b,e[12]=w*b,e[13]=(u*v*r-g*h*r+g*n*f-t*v*f-u*n*_+t*h*_)*b,e[14]=(g*a*r-o*v*r-g*n*l+t*v*l+o*n*_-t*a*_)*b,e[15]=(o*h*r-u*a*r+u*n*l-t*h*l-o*n*f+t*a*f)*b,this}scale(e){const t=this.elements,n=e.x,r=e.y,s=e.z;return t[0]*=n,t[4]*=r,t[8]*=s,t[1]*=n,t[5]*=r,t[9]*=s,t[2]*=n,t[6]*=r,t[10]*=s,t[3]*=n,t[7]*=r,t[11]*=s,this}getMaxScaleOnAxis(){const e=this.elements,t=e[0]*e[0]+e[1]*e[1]+e[2]*e[2],n=e[4]*e[4]+e[5]*e[5]+e[6]*e[6],r=e[8]*e[8]+e[9]*e[9]+e[10]*e[10];return Math.sqrt(Math.max(t,n,r))}makeTranslation(e,t,n){return this.set(1,0,0,e,0,1,0,t,0,0,1,n,0,0,0,1),this}makeRotationX(e){const t=Math.cos(e),n=Math.sin(e);return this.set(1,0,0,0,0,t,-n,0,0,n,t,0,0,0,0,1),this}makeRotationY(e){const t=Math.cos(e),n=Math.sin(e);return this.set(t,0,n,0,0,1,0,0,-n,0,t,0,0,0,0,1),this}makeRotationZ(e){const t=Math.cos(e),n=Math.sin(e);return this.set(t,-n,0,0,n,t,0,0,0,0,1,0,0,0,0,1),this}makeRotationAxis(e,t){const n=Math.cos(t),r=Math.sin(t),s=1-n,o=e.x,a=e.y,l=e.z,c=s*o,u=s*a;return this.set(c*o+n,c*a-r*l,c*l+r*a,0,c*a+r*l,u*a+n,u*l-r*o,0,c*l-r*a,u*l+r*o,s*l*l+n,0,0,0,0,1),this}makeScale(e,t,n){return this.set(e,0,0,0,0,t,0,0,0,0,n,0,0,0,0,1),this}makeShear(e,t,n,r,s,o){return this.set(1,n,s,0,e,1,o,0,t,r,1,0,0,0,0,1),this}compose(e,t,n){const r=this.elements,s=t._x,o=t._y,a=t._z,l=t._w,c=s+s,u=o+o,h=a+a,f=s*c,d=s*u,g=s*h,v=o*u,_=o*h,m=a*h,p=l*c,y=l*u,x=l*h,w=n.x,A=n.y,b=n.z;return r[0]=(1-(v+m))*w,r[1]=(d+x)*w,r[2]=(g-y)*w,r[3]=0,r[4]=(d-x)*A,r[5]=(1-(f+m))*A,r[6]=(_+p)*A,r[7]=0,r[8]=(g+y)*b,r[9]=(_-p)*b,r[10]=(1-(f+v))*b,r[11]=0,r[12]=e.x,r[13]=e.y,r[14]=e.z,r[15]=1,this}decompose(e,t,n){const r=this.elements;let s=Qi.set(r[0],r[1],r[2]).length();const o=Qi.set(r[4],r[5],r[6]).length(),a=Qi.set(r[8],r[9],r[10]).length();this.determinant()<0&&(s=-s),e.x=r[12],e.y=r[13],e.z=r[14],Tt.copy(this);const c=1/s,u=1/o,h=1/a;return Tt.elements[0]*=c,Tt.elements[1]*=c,Tt.elements[2]*=c,Tt.elements[4]*=u,Tt.elements[5]*=u,Tt.elements[6]*=u,Tt.elements[8]*=h,Tt.elements[9]*=h,Tt.elements[10]*=h,t.setFromRotationMatrix(Tt),n.x=s,n.y=o,n.z=a,this}makePerspective(e,t,n,r,s,o){o===void 0&&console.warn("THREE.Matrix4: .makePerspective() has been redefined and has a new signature. Please check the docs.");const a=this.elements,l=2*s/(t-e),c=2*s/(n-r),u=(t+e)/(t-e),h=(n+r)/(n-r),f=-(o+s)/(o-s),d=-2*o*s/(o-s);return a[0]=l,a[4]=0,a[8]=u,a[12]=0,a[1]=0,a[5]=c,a[9]=h,a[13]=0,a[2]=0,a[6]=0,a[10]=f,a[14]=d,a[3]=0,a[7]=0,a[11]=-1,a[15]=0,this}makeOrthographic(e,t,n,r,s,o){const a=this.elements,l=1/(t-e),c=1/(n-r),u=1/(o-s),h=(t+e)*l,f=(n+r)*c,d=(o+s)*u;return a[0]=2*l,a[4]=0,a[8]=0,a[12]=-h,a[1]=0,a[5]=2*c,a[9]=0,a[13]=-f,a[2]=0,a[6]=0,a[10]=-2*u,a[14]=-d,a[3]=0,a[7]=0,a[11]=0,a[15]=1,this}equals(e){const t=this.elements,n=e.elements;for(let r=0;r<16;r++)if(t[r]!==n[r])return!1;return!0}fromArray(e,t=0){for(let n=0;n<16;n++)this.elements[n]=e[n+t];return this}toArray(e=[],t=0){const n=this.elements;return e[t]=n[0],e[t+1]=n[1],e[t+2]=n[2],e[t+3]=n[3],e[t+4]=n[4],e[t+5]=n[5],e[t+6]=n[6],e[t+7]=n[7],e[t+8]=n[8],e[t+9]=n[9],e[t+10]=n[10],e[t+11]=n[11],e[t+12]=n[12],e[t+13]=n[13],e[t+14]=n[14],e[t+15]=n[15],e}}Me.prototype.isMatrix4=!0;const Qi=new P,Tt=new Me,Ov=new P(0,0,0),Uv=new P(1,1,1),Ln=new P,Yo=new P,ht=new P,mu=new Me,gu=new S0;class It{constructor(e=0,t=0,n=0,r=It.DefaultOrder){this._x=e,this._y=t,this._z=n,this._order=r}get x(){return this._x}set x(e){this._x=e,this._onChangeCallback()}get y(){return this._y}set y(e){this._y=e,this._onChangeCallback()}get z(){return this._z}set z(e){this._z=e,this._onChangeCallback()}get order(){return this._order}set order(e){this._order=e,this._onChangeCallback()}set(e,t,n,r=this._order){return this._x=e,this._y=t,this._z=n,this._order=r,this._onChangeCallback(),this}clone(){return new this.constructor(this._x,this._y,this._z,this._order)}copy(e){return this._x=e._x,this._y=e._y,this._z=e._z,this._order=e._order,this._onChangeCallback(),this}setFromRotationMatrix(e,t=this._order,n=!0){const r=e.elements,s=r[0],o=r[4],a=r[8],l=r[1],c=r[5],u=r[9],h=r[2],f=r[6],d=r[10];switch(t){case"XYZ":this._y=Math.asin(Q0(a,-1,1)),Math.abs(a)<.9999999?(this._x=Math.atan2(-u,d),this._z=Math.atan2(-o,s)):(this._x=Math.atan2(f,c),this._z=0);break;case"YXZ":this._x=Math.asin(-Q0(u,-1,1)),Math.abs(u)<.9999999?(this._y=Math.atan2(a,d),this._z=Math.atan2(l,c)):(this._y=Math.atan2(-h,s),this._z=0);break;case"ZXY":this._x=Math.asin(Q0(f,-1,1)),Math.abs(f)<.9999999?(this._y=Math.atan2(-h,d),this._z=Math.atan2(-o,c)):(this._y=0,this._z=Math.atan2(l,s));break;case"ZYX":this._y=Math.asin(-Q0(h,-1,1)),Math.abs(h)<.9999999?(this._x=Math.atan2(f,d),this._z=Math.atan2(l,s)):(this._x=0,this._z=Math.atan2(-o,c));break;case"YZX":this._z=Math.asin(Q0(l,-1,1)),Math.abs(l)<.9999999?(this._x=Math.atan2(-u,c),this._y=Math.atan2(-h,s)):(this._x=0,this._y=Math.atan2(a,d));break;case"XZY":this._z=Math.asin(-Q0(o,-1,1)),Math.abs(o)<.9999999?(this._x=Math.atan2(f,c),this._y=Math.atan2(a,s)):(this._x=Math.atan2(-u,d),this._y=0);break;default:console.warn("THREE.Euler: .setFromRotationMatrix() encountered an unknown order: "+t)}return this._order=t,n===!0&&this._onChangeCallback(),this}setFromQuaternion(e,t,n){return mu.makeRotationFromQuaternion(e),this.setFromRotationMatrix(mu,t,n)}setFromVector3(e,t=this._order){return this.set(e.x,e.y,e.z,t)}reorder(e){return gu.setFromEuler(this),this.setFromQuaternion(gu,e)}equals(e){return e._x===this._x&&e._y===this._y&&e._z===this._z&&e._order===this._order}fromArray(e){return this._x=e[0],this._y=e[1],this._z=e[2],e[3]!==void 0&&(this._order=e[3]),this._onChangeCallback(),this}toArray(e=[],t=0){return e[t]=this._x,e[t+1]=this._y,e[t+2]=this._z,e[t+3]=this._order,e}toVector3(e){return e?e.set(this._x,this._y,this._z):new P(this._x,this._y,this._z)}_onChange(e){return this._onChangeCallback=e,this}_onChangeCallback(){}}It.prototype.isEuler=!0;It.DefaultOrder="XYZ";It.RotationOrders=["XYZ","YZX","ZXY","XZY","YXZ","ZYX"];class M4{constructor(){this.mask=1}set(e){this.mask=1<1){for(let t=0;t1){for(let n=0;n0){r.children=[];for(let a=0;a0){r.animations=[];for(let a=0;a0&&(n.geometries=a),l.length>0&&(n.materials=l),c.length>0&&(n.textures=c),u.length>0&&(n.images=u),h.length>0&&(n.shapes=h),f.length>0&&(n.skeletons=f),d.length>0&&(n.animations=d)}return n.object=r,n;function o(a){const l=[];for(const c in a){const u=a[c];delete u.metadata,l.push(u)}return l}}clone(e){return new this.constructor().copy(this,e)}copy(e,t=!0){if(this.name=e.name,this.up.copy(e.up),this.position.copy(e.position),this.rotation.order=e.rotation.order,this.quaternion.copy(e.quaternion),this.scale.copy(e.scale),this.matrix.copy(e.matrix),this.matrixWorld.copy(e.matrixWorld),this.matrixAutoUpdate=e.matrixAutoUpdate,this.matrixWorldNeedsUpdate=e.matrixWorldNeedsUpdate,this.layers.mask=e.layers.mask,this.visible=e.visible,this.castShadow=e.castShadow,this.receiveShadow=e.receiveShadow,this.frustumCulled=e.frustumCulled,this.renderOrder=e.renderOrder,this.userData=JSON.parse(JSON.stringify(e.userData)),t===!0)for(let n=0;n0?r.multiplyScalar(1/Math.sqrt(s)):r.set(0,0,0)}static getBarycoord(e,t,n,r,s){At.subVectors(r,t),an.subVectors(n,t),e1.subVectors(e,t);const o=At.dot(At),a=At.dot(an),l=At.dot(e1),c=an.dot(an),u=an.dot(e1),h=o*c-a*a;if(h===0)return s.set(-2,-1,-1);const f=1/h,d=(c*l-a*u)*f,g=(o*u-a*l)*f;return s.set(1-d-g,g,d)}static containsPoint(e,t,n,r){return this.getBarycoord(e,t,n,r,ln),ln.x>=0&&ln.y>=0&&ln.x+ln.y<=1}static getUV(e,t,n,r,s,o,a,l){return this.getBarycoord(e,t,n,r,ln),l.set(0,0),l.addScaledVector(s,ln.x),l.addScaledVector(o,ln.y),l.addScaledVector(a,ln.z),l}static isFrontFacing(e,t,n,r){return At.subVectors(n,t),an.subVectors(e,t),At.cross(an).dot(r)<0}set(e,t,n){return this.a.copy(e),this.b.copy(t),this.c.copy(n),this}setFromPointsAndIndices(e,t,n,r){return this.a.copy(e[t]),this.b.copy(e[n]),this.c.copy(e[r]),this}setFromAttributeAndIndices(e,t,n,r){return this.a.fromBufferAttribute(e,t),this.b.fromBufferAttribute(e,n),this.c.fromBufferAttribute(e,r),this}clone(){return new this.constructor().copy(this)}copy(e){return this.a.copy(e.a),this.b.copy(e.b),this.c.copy(e.c),this}getArea(){return At.subVectors(this.c,this.b),an.subVectors(this.a,this.b),At.cross(an).length()*.5}getMidpoint(e){return e.addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)}getNormal(e){return R0.getNormal(this.a,this.b,this.c,e)}getPlane(e){return e.setFromCoplanarPoints(this.a,this.b,this.c)}getBarycoord(e,t){return R0.getBarycoord(e,this.a,this.b,this.c,t)}getUV(e,t,n,r,s){return R0.getUV(e,this.a,this.b,this.c,t,n,r,s)}containsPoint(e){return R0.containsPoint(e,this.a,this.b,this.c)}isFrontFacing(e){return R0.isFrontFacing(this.a,this.b,this.c,e)}intersectsBox(e){return e.intersectsTriangle(this)}closestPointToPoint(e,t){const n=this.a,r=this.b,s=this.c;let o,a;Ki.subVectors(r,n),Ji.subVectors(s,n),t1.subVectors(e,n);const l=Ki.dot(t1),c=Ji.dot(t1);if(l<=0&&c<=0)return t.copy(n);n1.subVectors(e,r);const u=Ki.dot(n1),h=Ji.dot(n1);if(u>=0&&h<=u)return t.copy(r);const f=l*h-u*c;if(f<=0&&l>=0&&u<=0)return o=l/(l-u),t.copy(n).addScaledVector(Ki,o);i1.subVectors(e,s);const d=Ki.dot(i1),g=Ji.dot(i1);if(g>=0&&d<=g)return t.copy(s);const v=d*c-l*g;if(v<=0&&c>=0&&g<=0)return a=c/(c-g),t.copy(n).addScaledVector(Ji,a);const _=u*g-d*h;if(_<=0&&h-u>=0&&d-g>=0)return wu.subVectors(s,r),a=(h-u)/(h-u+(d-g)),t.copy(r).addScaledVector(wu,a);const m=1/(_+v+f);return o=v*m,a=f*m,t.copy(n).addScaledVector(Ki,o).addScaledVector(Ji,a)}equals(e){return e.a.equals(this.a)&&e.b.equals(this.b)&&e.c.equals(this.c)}}let Hv=0;class D0 extends ni{constructor(){super(),Object.defineProperty(this,"id",{value:Hv++}),this.uuid=yt(),this.name="",this.type="Material",this.fog=!0,this.blending=Ws,this.side=Dr,this.vertexColors=!1,this.opacity=1,this.format=a0,this.transparent=!1,this.blendSrc=l4,this.blendDst=c4,this.blendEquation=zn,this.blendSrcAlpha=null,this.blendDstAlpha=null,this.blendEquationAlpha=null,this.depthFunc=Q1,this.depthTest=!0,this.depthWrite=!0,this.stencilWriteMask=255,this.stencilFunc=xv,this.stencilRef=0,this.stencilFuncMask=255,this.stencilFail=Wl,this.stencilZFail=Wl,this.stencilZPass=Wl,this.stencilWrite=!1,this.clippingPlanes=null,this.clipIntersection=!1,this.clipShadows=!1,this.shadowSide=null,this.colorWrite=!0,this.precision=null,this.polygonOffset=!1,this.polygonOffsetFactor=0,this.polygonOffsetUnits=0,this.dithering=!1,this.alphaToCoverage=!1,this.premultipliedAlpha=!1,this.visible=!0,this.toneMapped=!0,this.userData={},this.version=0,this._alphaTest=0}get alphaTest(){return this._alphaTest}set alphaTest(e){this._alphaTest>0!=e>0&&this.version++,this._alphaTest=e}onBuild(){}onBeforeRender(){}onBeforeCompile(){}customProgramCacheKey(){return this.onBeforeCompile.toString()}setValues(e){if(e!==void 0)for(const t in e){const n=e[t];if(n===void 0){console.warn("THREE.Material: '"+t+"' parameter is undefined.");continue}if(t==="shading"){console.warn("THREE."+this.type+": .shading has been removed. Use the boolean .flatShading instead."),this.flatShading=n===o4;continue}const r=this[t];if(r===void 0){console.warn("THREE."+this.type+": '"+t+"' is not a property of this material.");continue}r&&r.isColor?r.set(n):r&&r.isVector3&&n&&n.isVector3?r.copy(n):this[t]=n}}toJSON(e){const t=e===void 0||typeof e=="string";t&&(e={textures:{},images:{}});const n={metadata:{version:4.5,type:"Material",generator:"Material.toJSON"}};n.uuid=this.uuid,n.type=this.type,this.name!==""&&(n.name=this.name),this.color&&this.color.isColor&&(n.color=this.color.getHex()),this.roughness!==void 0&&(n.roughness=this.roughness),this.metalness!==void 0&&(n.metalness=this.metalness),this.sheen!==void 0&&(n.sheen=this.sheen),this.sheenColor&&this.sheenColor.isColor&&(n.sheenColor=this.sheenColor.getHex()),this.sheenRoughness!==void 0&&(n.sheenRoughness=this.sheenRoughness),this.emissive&&this.emissive.isColor&&(n.emissive=this.emissive.getHex()),this.emissiveIntensity&&this.emissiveIntensity!==1&&(n.emissiveIntensity=this.emissiveIntensity),this.specular&&this.specular.isColor&&(n.specular=this.specular.getHex()),this.specularIntensity!==void 0&&(n.specularIntensity=this.specularIntensity),this.specularColor&&this.specularColor.isColor&&(n.specularColor=this.specularColor.getHex()),this.shininess!==void 0&&(n.shininess=this.shininess),this.clearcoat!==void 0&&(n.clearcoat=this.clearcoat),this.clearcoatRoughness!==void 0&&(n.clearcoatRoughness=this.clearcoatRoughness),this.clearcoatMap&&this.clearcoatMap.isTexture&&(n.clearcoatMap=this.clearcoatMap.toJSON(e).uuid),this.clearcoatRoughnessMap&&this.clearcoatRoughnessMap.isTexture&&(n.clearcoatRoughnessMap=this.clearcoatRoughnessMap.toJSON(e).uuid),this.clearcoatNormalMap&&this.clearcoatNormalMap.isTexture&&(n.clearcoatNormalMap=this.clearcoatNormalMap.toJSON(e).uuid,n.clearcoatNormalScale=this.clearcoatNormalScale.toArray()),this.map&&this.map.isTexture&&(n.map=this.map.toJSON(e).uuid),this.matcap&&this.matcap.isTexture&&(n.matcap=this.matcap.toJSON(e).uuid),this.alphaMap&&this.alphaMap.isTexture&&(n.alphaMap=this.alphaMap.toJSON(e).uuid),this.lightMap&&this.lightMap.isTexture&&(n.lightMap=this.lightMap.toJSON(e).uuid,n.lightMapIntensity=this.lightMapIntensity),this.aoMap&&this.aoMap.isTexture&&(n.aoMap=this.aoMap.toJSON(e).uuid,n.aoMapIntensity=this.aoMapIntensity),this.bumpMap&&this.bumpMap.isTexture&&(n.bumpMap=this.bumpMap.toJSON(e).uuid,n.bumpScale=this.bumpScale),this.normalMap&&this.normalMap.isTexture&&(n.normalMap=this.normalMap.toJSON(e).uuid,n.normalMapType=this.normalMapType,n.normalScale=this.normalScale.toArray()),this.displacementMap&&this.displacementMap.isTexture&&(n.displacementMap=this.displacementMap.toJSON(e).uuid,n.displacementScale=this.displacementScale,n.displacementBias=this.displacementBias),this.roughnessMap&&this.roughnessMap.isTexture&&(n.roughnessMap=this.roughnessMap.toJSON(e).uuid),this.metalnessMap&&this.metalnessMap.isTexture&&(n.metalnessMap=this.metalnessMap.toJSON(e).uuid),this.emissiveMap&&this.emissiveMap.isTexture&&(n.emissiveMap=this.emissiveMap.toJSON(e).uuid),this.specularMap&&this.specularMap.isTexture&&(n.specularMap=this.specularMap.toJSON(e).uuid),this.specularIntensityMap&&this.specularIntensityMap.isTexture&&(n.specularIntensityMap=this.specularIntensityMap.toJSON(e).uuid),this.specularColorMap&&this.specularColorMap.isTexture&&(n.specularColorMap=this.specularColorMap.toJSON(e).uuid),this.envMap&&this.envMap.isTexture&&(n.envMap=this.envMap.toJSON(e).uuid,this.combine!==void 0&&(n.combine=this.combine)),this.envMapIntensity!==void 0&&(n.envMapIntensity=this.envMapIntensity),this.reflectivity!==void 0&&(n.reflectivity=this.reflectivity),this.refractionRatio!==void 0&&(n.refractionRatio=this.refractionRatio),this.gradientMap&&this.gradientMap.isTexture&&(n.gradientMap=this.gradientMap.toJSON(e).uuid),this.transmission!==void 0&&(n.transmission=this.transmission),this.transmissionMap&&this.transmissionMap.isTexture&&(n.transmissionMap=this.transmissionMap.toJSON(e).uuid),this.thickness!==void 0&&(n.thickness=this.thickness),this.thicknessMap&&this.thicknessMap.isTexture&&(n.thicknessMap=this.thicknessMap.toJSON(e).uuid),this.attenuationDistance!==void 0&&(n.attenuationDistance=this.attenuationDistance),this.attenuationColor!==void 0&&(n.attenuationColor=this.attenuationColor.getHex()),this.size!==void 0&&(n.size=this.size),this.shadowSide!==null&&(n.shadowSide=this.shadowSide),this.sizeAttenuation!==void 0&&(n.sizeAttenuation=this.sizeAttenuation),this.blending!==Ws&&(n.blending=this.blending),this.side!==Dr&&(n.side=this.side),this.vertexColors&&(n.vertexColors=!0),this.opacity<1&&(n.opacity=this.opacity),this.format!==a0&&(n.format=this.format),this.transparent===!0&&(n.transparent=this.transparent),n.depthFunc=this.depthFunc,n.depthTest=this.depthTest,n.depthWrite=this.depthWrite,n.colorWrite=this.colorWrite,n.stencilWrite=this.stencilWrite,n.stencilWriteMask=this.stencilWriteMask,n.stencilFunc=this.stencilFunc,n.stencilRef=this.stencilRef,n.stencilFuncMask=this.stencilFuncMask,n.stencilFail=this.stencilFail,n.stencilZFail=this.stencilZFail,n.stencilZPass=this.stencilZPass,this.rotation&&this.rotation!==0&&(n.rotation=this.rotation),this.polygonOffset===!0&&(n.polygonOffset=!0),this.polygonOffsetFactor!==0&&(n.polygonOffsetFactor=this.polygonOffsetFactor),this.polygonOffsetUnits!==0&&(n.polygonOffsetUnits=this.polygonOffsetUnits),this.linewidth&&this.linewidth!==1&&(n.linewidth=this.linewidth),this.dashSize!==void 0&&(n.dashSize=this.dashSize),this.gapSize!==void 0&&(n.gapSize=this.gapSize),this.scale!==void 0&&(n.scale=this.scale),this.dithering===!0&&(n.dithering=!0),this.alphaTest>0&&(n.alphaTest=this.alphaTest),this.alphaToCoverage===!0&&(n.alphaToCoverage=this.alphaToCoverage),this.premultipliedAlpha===!0&&(n.premultipliedAlpha=this.premultipliedAlpha),this.wireframe===!0&&(n.wireframe=this.wireframe),this.wireframeLinewidth>1&&(n.wireframeLinewidth=this.wireframeLinewidth),this.wireframeLinecap!=="round"&&(n.wireframeLinecap=this.wireframeLinecap),this.wireframeLinejoin!=="round"&&(n.wireframeLinejoin=this.wireframeLinejoin),this.flatShading===!0&&(n.flatShading=this.flatShading),this.visible===!1&&(n.visible=!1),this.toneMapped===!1&&(n.toneMapped=!1),JSON.stringify(this.userData)!=="{}"&&(n.userData=this.userData);function r(s){const o=[];for(const a in s){const l=s[a];delete l.metadata,o.push(l)}return o}if(t){const s=r(e.textures),o=r(e.images);s.length>0&&(n.textures=s),o.length>0&&(n.images=o)}return n}clone(){return new this.constructor().copy(this)}copy(e){this.name=e.name,this.fog=e.fog,this.blending=e.blending,this.side=e.side,this.vertexColors=e.vertexColors,this.opacity=e.opacity,this.format=e.format,this.transparent=e.transparent,this.blendSrc=e.blendSrc,this.blendDst=e.blendDst,this.blendEquation=e.blendEquation,this.blendSrcAlpha=e.blendSrcAlpha,this.blendDstAlpha=e.blendDstAlpha,this.blendEquationAlpha=e.blendEquationAlpha,this.depthFunc=e.depthFunc,this.depthTest=e.depthTest,this.depthWrite=e.depthWrite,this.stencilWriteMask=e.stencilWriteMask,this.stencilFunc=e.stencilFunc,this.stencilRef=e.stencilRef,this.stencilFuncMask=e.stencilFuncMask,this.stencilFail=e.stencilFail,this.stencilZFail=e.stencilZFail,this.stencilZPass=e.stencilZPass,this.stencilWrite=e.stencilWrite;const t=e.clippingPlanes;let n=null;if(t!==null){const r=t.length;n=new Array(r);for(let s=0;s!==r;++s)n[s]=t[s].clone()}return this.clippingPlanes=n,this.clipIntersection=e.clipIntersection,this.clipShadows=e.clipShadows,this.shadowSide=e.shadowSide,this.colorWrite=e.colorWrite,this.precision=e.precision,this.polygonOffset=e.polygonOffset,this.polygonOffsetFactor=e.polygonOffsetFactor,this.polygonOffsetUnits=e.polygonOffsetUnits,this.dithering=e.dithering,this.alphaTest=e.alphaTest,this.alphaToCoverage=e.alphaToCoverage,this.premultipliedAlpha=e.premultipliedAlpha,this.visible=e.visible,this.toneMapped=e.toneMapped,this.userData=JSON.parse(JSON.stringify(e.userData)),this}dispose(){this.dispatchEvent({type:"dispose"})}set needsUpdate(e){e===!0&&this.version++}}D0.prototype.isMaterial=!0;const S4={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074},Et={h:0,s:0,l:0},Qo={h:0,s:0,l:0};function r1(i,e,t){return t<0&&(t+=1),t>1&&(t-=1),t<1/6?i+(e-i)*6*t:t<1/2?e:t<2/3?i+(e-i)*6*(2/3-t):i}function s1(i){return i<.04045?i*.0773993808:Math.pow(i*.9478672986+.0521327014,2.4)}function o1(i){return i<.0031308?i*12.92:1.055*Math.pow(i,.41666)-.055}class be{constructor(e,t,n){return t===void 0&&n===void 0?this.set(e):this.setRGB(e,t,n)}set(e){return e&&e.isColor?this.copy(e):typeof e=="number"?this.setHex(e):typeof e=="string"&&this.setStyle(e),this}setScalar(e){return this.r=e,this.g=e,this.b=e,this}setHex(e){return e=Math.floor(e),this.r=(e>>16&255)/255,this.g=(e>>8&255)/255,this.b=(e&255)/255,this}setRGB(e,t,n){return this.r=e,this.g=t,this.b=n,this}setHSL(e,t,n){if(e=Kc(e,1),t=Q0(t,0,1),n=Q0(n,0,1),t===0)this.r=this.g=this.b=n;else{const r=n<=.5?n*(1+t):n+t-n*t,s=2*n-r;this.r=r1(s,r,e+1/3),this.g=r1(s,r,e),this.b=r1(s,r,e-1/3)}return this}setStyle(e){function t(r){r!==void 0&&parseFloat(r)<1&&console.warn("THREE.Color: Alpha component of "+e+" will be ignored.")}let n;if(n=/^((?:rgb|hsl)a?)\(([^\)]*)\)/.exec(e)){let r;const s=n[1],o=n[2];switch(s){case"rgb":case"rgba":if(r=/^\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(o))return this.r=Math.min(255,parseInt(r[1],10))/255,this.g=Math.min(255,parseInt(r[2],10))/255,this.b=Math.min(255,parseInt(r[3],10))/255,t(r[4]),this;if(r=/^\s*(\d+)\%\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(o))return this.r=Math.min(100,parseInt(r[1],10))/100,this.g=Math.min(100,parseInt(r[2],10))/100,this.b=Math.min(100,parseInt(r[3],10))/100,t(r[4]),this;break;case"hsl":case"hsla":if(r=/^\s*(\d*\.?\d+)\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(o)){const a=parseFloat(r[1])/360,l=parseInt(r[2],10)/100,c=parseInt(r[3],10)/100;return t(r[4]),this.setHSL(a,l,c)}break}}else if(n=/^\#([A-Fa-f\d]+)$/.exec(e)){const r=n[1],s=r.length;if(s===3)return this.r=parseInt(r.charAt(0)+r.charAt(0),16)/255,this.g=parseInt(r.charAt(1)+r.charAt(1),16)/255,this.b=parseInt(r.charAt(2)+r.charAt(2),16)/255,this;if(s===6)return this.r=parseInt(r.charAt(0)+r.charAt(1),16)/255,this.g=parseInt(r.charAt(2)+r.charAt(3),16)/255,this.b=parseInt(r.charAt(4)+r.charAt(5),16)/255,this}return e&&e.length>0?this.setColorName(e):this}setColorName(e){const t=S4[e.toLowerCase()];return t!==void 0?this.setHex(t):console.warn("THREE.Color: Unknown color "+e),this}clone(){return new this.constructor(this.r,this.g,this.b)}copy(e){return this.r=e.r,this.g=e.g,this.b=e.b,this}copyGammaToLinear(e,t=2){return this.r=Math.pow(e.r,t),this.g=Math.pow(e.g,t),this.b=Math.pow(e.b,t),this}copyLinearToGamma(e,t=2){const n=t>0?1/t:1;return this.r=Math.pow(e.r,n),this.g=Math.pow(e.g,n),this.b=Math.pow(e.b,n),this}convertGammaToLinear(e){return this.copyGammaToLinear(this,e),this}convertLinearToGamma(e){return this.copyLinearToGamma(this,e),this}copySRGBToLinear(e){return this.r=s1(e.r),this.g=s1(e.g),this.b=s1(e.b),this}copyLinearToSRGB(e){return this.r=o1(e.r),this.g=o1(e.g),this.b=o1(e.b),this}convertSRGBToLinear(){return this.copySRGBToLinear(this),this}convertLinearToSRGB(){return this.copyLinearToSRGB(this),this}getHex(){return this.r*255<<16^this.g*255<<8^this.b*255<<0}getHexString(){return("000000"+this.getHex().toString(16)).slice(-6)}getHSL(e){const t=this.r,n=this.g,r=this.b,s=Math.max(t,n,r),o=Math.min(t,n,r);let a,l;const c=(o+s)/2;if(o===s)a=0,l=0;else{const u=s-o;switch(l=c<=.5?u/(s+o):u/(2-s-o),s){case t:a=(n-r)/u+(n65535?T4:Jc)(e,1):this.index=e,this}getAttribute(e){return this.attributes[e]}setAttribute(e,t){return this.attributes[e]=t,this}deleteAttribute(e){return delete this.attributes[e],this}hasAttribute(e){return this.attributes[e]!==void 0}addGroup(e,t,n=0){this.groups.push({start:e,count:t,materialIndex:n})}clearGroups(){this.groups=[]}setDrawRange(e,t){this.drawRange.start=e,this.drawRange.count=t}applyMatrix4(e){const t=this.attributes.position;t!==void 0&&(t.applyMatrix4(e),t.needsUpdate=!0);const n=this.attributes.normal;if(n!==void 0){const s=new B0().getNormalMatrix(e);n.applyNormalMatrix(s),n.needsUpdate=!0}const r=this.attributes.tangent;return r!==void 0&&(r.transformDirection(e),r.needsUpdate=!0),this.boundingBox!==null&&this.computeBoundingBox(),this.boundingSphere!==null&&this.computeBoundingSphere(),this}applyQuaternion(e){return pt.makeRotationFromQuaternion(e),this.applyMatrix4(pt),this}rotateX(e){return pt.makeRotationX(e),this.applyMatrix4(pt),this}rotateY(e){return pt.makeRotationY(e),this.applyMatrix4(pt),this}rotateZ(e){return pt.makeRotationZ(e),this.applyMatrix4(pt),this}translate(e,t,n){return pt.makeTranslation(e,t,n),this.applyMatrix4(pt),this}scale(e,t,n){return pt.makeScale(e,t,n),this.applyMatrix4(pt),this}lookAt(e){return a1.lookAt(e),a1.updateMatrix(),this.applyMatrix4(a1.matrix),this}center(){return this.computeBoundingBox(),this.boundingBox.getCenter($i).negate(),this.translate($i.x,$i.y,$i.z),this}setFromPoints(e){const t=[];for(let n=0,r=e.length;n0&&(e.userData=this.userData),this.parameters!==void 0){const l=this.parameters;for(const c in l)l[c]!==void 0&&(e[c]=l[c]);return e}e.data={attributes:{}};const t=this.index;t!==null&&(e.data.index={type:t.array.constructor.name,array:Array.prototype.slice.call(t.array)});const n=this.attributes;for(const l in n){const c=n[l];e.data.attributes[l]=c.toJSON(e.data)}const r={};let s=!1;for(const l in this.morphAttributes){const c=this.morphAttributes[l],u=[];for(let h=0,f=c.length;h0&&(r[l]=u,s=!0)}s&&(e.data.morphAttributes=r,e.data.morphTargetsRelative=this.morphTargetsRelative);const o=this.groups;o.length>0&&(e.data.groups=JSON.parse(JSON.stringify(o)));const a=this.boundingSphere;return a!==null&&(e.data.boundingSphere={center:a.center.toArray(),radius:a.radius}),e}clone(){return new this.constructor().copy(this)}copy(e){this.index=null,this.attributes={},this.morphAttributes={},this.groups=[],this.boundingBox=null,this.boundingSphere=null;const t={};this.name=e.name;const n=e.index;n!==null&&this.setIndex(n.clone(t));const r=e.attributes;for(const c in r){const u=r[c];this.setAttribute(c,u.clone(t))}const s=e.morphAttributes;for(const c in s){const u=[],h=s[c];for(let f=0,d=h.length;f0){const r=t[n[0]];if(r!==void 0){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let s=0,o=r.length;s0&&console.error("THREE.Mesh.updateMorphTargets() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")}}raycast(e,t){const n=this.geometry,r=this.material,s=this.matrixWorld;if(r===void 0||(n.boundingSphere===null&&n.computeBoundingSphere(),l1.copy(n.boundingSphere),l1.applyMatrix4(s),e.ray.intersectsSphere(l1)===!1)||(Mu.copy(s).invert(),er.copy(e.ray).applyMatrix4(Mu),n.boundingBox!==null&&er.intersectsBox(n.boundingBox)===!1))return;let o;if(n.isBufferGeometry){const a=n.index,l=n.attributes.position,c=n.morphAttributes.position,u=n.morphTargetsRelative,h=n.attributes.uv,f=n.attributes.uv2,d=n.groups,g=n.drawRange;if(a!==null)if(Array.isArray(r))for(let v=0,_=d.length;v<_;v++){const m=d[v],p=r[m.materialIndex],y=Math.max(m.start,g.start),x=Math.min(a.count,Math.min(m.start+m.count,g.start+g.count));for(let w=y,A=x;wt.far?null:{distance:c,point:ia.clone(),object:i}}function ra(i,e,t,n,r,s,o,a,l,c,u,h){Pn.fromBufferAttribute(r,c),Cn.fromBufferAttribute(r,u),Rn.fromBufferAttribute(r,h);const f=i.morphTargetInfluences;if(s&&f){Ko.set(0,0,0),Jo.set(0,0,0),$o.set(0,0,0);for(let g=0,v=s.length;g0?1:-1,u.push(le.x,le.y,le.z),h.push(ye/b),h.push(1-ve/L),k+=1}}for(let ve=0;ve>8&255]+V0[i>>16&255]+V0[i>>24&255]+"-"+V0[e&255]+V0[e>>8&255]+"-"+V0[e>>16&15|64]+V0[e>>24&255]+"-"+V0[t&63|128]+V0[t>>8&255]+"-"+V0[t>>16&255]+V0[t>>24&255]+V0[n&255]+V0[n>>8&255]+V0[n>>16&255]+V0[n>>24&255]).toUpperCase()}function Q0(i,e,t){return Math.max(e,Math.min(t,i))}function Zc(i,e){return(i%e+e)%e}function _v(i,e,t,n,r){return n+(i-e)*(r-n)/(t-e)}function bv(i,e,t){return i!==e?(t-i)/(e-i):0}function Ys(i,e,t){return(1-t)*i+t*e}function wv(i,e,t,n){return Ys(i,e,1-Math.exp(-t*n))}function Mv(i,e=1){return e-Math.abs(Zc(i,e*2)-e)}function Sv(i,e,t){return i<=e?0:i>=t?1:(i=(i-e)/(t-e),i*i*(3-2*i))}function Tv(i,e,t){return i<=e?0:i>=t?1:(i=(i-e)/(t-e),i*i*i*(i*(i*6-15)+10))}function Av(i,e){return i+Math.floor(Math.random()*(e-i+1))}function Ev(i,e){return i+Math.random()*(e-i)}function Lv(i){return i*(.5-Math.random())}function Pv(i){return i!==void 0&&(Ho=i%2147483647),Ho=Ho*16807%2147483647,(Ho-1)/2147483646}function Cv(i){return i*js}function Rv(i){return i*uo}function ec(i){return(i&i-1)===0&&i!==0}function y4(i){return Math.pow(2,Math.ceil(Math.log(i)/Math.LN2))}function _4(i){return Math.pow(2,Math.floor(Math.log(i)/Math.LN2))}function Fv(i,e,t,n,r){const s=Math.cos,o=Math.sin,a=s(t/2),l=o(t/2),c=s((e+n)/2),u=o((e+n)/2),h=s((e-n)/2),f=o((e-n)/2),d=s((n-e)/2),g=o((n-e)/2);switch(r){case"XYX":i.set(a*u,l*h,l*f,a*c);break;case"YZY":i.set(l*f,a*u,l*h,a*c);break;case"ZXZ":i.set(l*h,l*f,a*u,a*c);break;case"XZX":i.set(a*u,l*g,l*d,a*c);break;case"YXY":i.set(l*d,a*u,l*g,a*c);break;case"ZYZ":i.set(l*g,l*d,a*u,a*c);break;default:console.warn("THREE.MathUtils: .setQuaternionFromProperEuler() encountered an unknown order: "+r)}}var vt=Object.freeze({__proto__:null,DEG2RAD:js,RAD2DEG:uo,generateUUID:yt,clamp:Q0,euclideanModulo:Zc,mapLinear:_v,inverseLerp:bv,lerp:Ys,damp:wv,pingpong:Mv,smoothstep:Sv,smootherstep:Tv,randInt:Av,randFloat:Ev,randFloatSpread:Lv,seededRandom:Pv,degToRad:Cv,radToDeg:Rv,isPowerOfTwo:ec,ceilPowerOfTwo:y4,floorPowerOfTwo:_4,setQuaternionFromProperEuler:Fv});class ee{constructor(e=0,t=0){this.x=e,this.y=t}get width(){return this.x}set width(e){this.x=e}get height(){return this.y}set height(e){this.y=e}set(e,t){return this.x=e,this.y=t,this}setScalar(e){return this.x=e,this.y=e,this}setX(e){return this.x=e,this}setY(e){return this.y=e,this}setComponent(e,t){switch(e){case 0:this.x=t;break;case 1:this.y=t;break;default:throw new Error("index is out of range: "+e)}return this}getComponent(e){switch(e){case 0:return this.x;case 1:return this.y;default:throw new Error("index is out of range: "+e)}}clone(){return new this.constructor(this.x,this.y)}copy(e){return this.x=e.x,this.y=e.y,this}add(e,t){return t!==void 0?(console.warn("THREE.Vector2: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(e,t)):(this.x+=e.x,this.y+=e.y,this)}addScalar(e){return this.x+=e,this.y+=e,this}addVectors(e,t){return this.x=e.x+t.x,this.y=e.y+t.y,this}addScaledVector(e,t){return this.x+=e.x*t,this.y+=e.y*t,this}sub(e,t){return t!==void 0?(console.warn("THREE.Vector2: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(e,t)):(this.x-=e.x,this.y-=e.y,this)}subScalar(e){return this.x-=e,this.y-=e,this}subVectors(e,t){return this.x=e.x-t.x,this.y=e.y-t.y,this}multiply(e){return this.x*=e.x,this.y*=e.y,this}multiplyScalar(e){return this.x*=e,this.y*=e,this}divide(e){return this.x/=e.x,this.y/=e.y,this}divideScalar(e){return this.multiplyScalar(1/e)}applyMatrix3(e){const t=this.x,n=this.y,r=e.elements;return this.x=r[0]*t+r[3]*n+r[6],this.y=r[1]*t+r[4]*n+r[7],this}min(e){return this.x=Math.min(this.x,e.x),this.y=Math.min(this.y,e.y),this}max(e){return this.x=Math.max(this.x,e.x),this.y=Math.max(this.y,e.y),this}clamp(e,t){return this.x=Math.max(e.x,Math.min(t.x,this.x)),this.y=Math.max(e.y,Math.min(t.y,this.y)),this}clampScalar(e,t){return this.x=Math.max(e,Math.min(t,this.x)),this.y=Math.max(e,Math.min(t,this.y)),this}clampLength(e,t){const n=this.length();return this.divideScalar(n||1).multiplyScalar(Math.max(e,Math.min(t,n)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this}negate(){return this.x=-this.x,this.y=-this.y,this}dot(e){return this.x*e.x+this.y*e.y}cross(e){return this.x*e.y-this.y*e.x}lengthSq(){return this.x*this.x+this.y*this.y}length(){return Math.sqrt(this.x*this.x+this.y*this.y)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)}normalize(){return this.divideScalar(this.length()||1)}angle(){return Math.atan2(-this.y,-this.x)+Math.PI}distanceTo(e){return Math.sqrt(this.distanceToSquared(e))}distanceToSquared(e){const t=this.x-e.x,n=this.y-e.y;return t*t+n*n}manhattanDistanceTo(e){return Math.abs(this.x-e.x)+Math.abs(this.y-e.y)}setLength(e){return this.normalize().multiplyScalar(e)}lerp(e,t){return this.x+=(e.x-this.x)*t,this.y+=(e.y-this.y)*t,this}lerpVectors(e,t,n){return this.x=e.x+(t.x-e.x)*n,this.y=e.y+(t.y-e.y)*n,this}equals(e){return e.x===this.x&&e.y===this.y}fromArray(e,t=0){return this.x=e[t],this.y=e[t+1],this}toArray(e=[],t=0){return e[t]=this.x,e[t+1]=this.y,e}fromBufferAttribute(e,t,n){return n!==void 0&&console.warn("THREE.Vector2: offset has been removed from .fromBufferAttribute()."),this.x=e.getX(t),this.y=e.getY(t),this}rotateAround(e,t){const n=Math.cos(t),r=Math.sin(t),s=this.x-e.x,o=this.y-e.y;return this.x=s*n-o*r+e.x,this.y=s*r+o*n+e.y,this}random(){return this.x=Math.random(),this.y=Math.random(),this}*[Symbol.iterator](){yield this.x,yield this.y}}ee.prototype.isVector2=!0;class k0{constructor(){this.elements=[1,0,0,0,1,0,0,0,1],arguments.length>0&&console.error("THREE.Matrix3: the constructor no longer reads arguments. use .set() instead.")}set(e,t,n,r,s,o,a,l,c){const u=this.elements;return u[0]=e,u[1]=r,u[2]=a,u[3]=t,u[4]=s,u[5]=l,u[6]=n,u[7]=o,u[8]=c,this}identity(){return this.set(1,0,0,0,1,0,0,0,1),this}copy(e){const t=this.elements,n=e.elements;return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=n[4],t[5]=n[5],t[6]=n[6],t[7]=n[7],t[8]=n[8],this}extractBasis(e,t,n){return e.setFromMatrix3Column(this,0),t.setFromMatrix3Column(this,1),n.setFromMatrix3Column(this,2),this}setFromMatrix4(e){const t=e.elements;return this.set(t[0],t[4],t[8],t[1],t[5],t[9],t[2],t[6],t[10]),this}multiply(e){return this.multiplyMatrices(this,e)}premultiply(e){return this.multiplyMatrices(e,this)}multiplyMatrices(e,t){const n=e.elements,r=t.elements,s=this.elements,o=n[0],a=n[3],l=n[6],c=n[1],u=n[4],h=n[7],f=n[2],d=n[5],g=n[8],v=r[0],_=r[3],m=r[6],p=r[1],y=r[4],x=r[7],w=r[2],A=r[5],b=r[8];return s[0]=o*v+a*p+l*w,s[3]=o*_+a*y+l*A,s[6]=o*m+a*x+l*b,s[1]=c*v+u*p+h*w,s[4]=c*_+u*y+h*A,s[7]=c*m+u*x+h*b,s[2]=f*v+d*p+g*w,s[5]=f*_+d*y+g*A,s[8]=f*m+d*x+g*b,this}multiplyScalar(e){const t=this.elements;return t[0]*=e,t[3]*=e,t[6]*=e,t[1]*=e,t[4]*=e,t[7]*=e,t[2]*=e,t[5]*=e,t[8]*=e,this}determinant(){const e=this.elements,t=e[0],n=e[1],r=e[2],s=e[3],o=e[4],a=e[5],l=e[6],c=e[7],u=e[8];return t*o*u-t*a*c-n*s*u+n*a*l+r*s*c-r*o*l}invert(){const e=this.elements,t=e[0],n=e[1],r=e[2],s=e[3],o=e[4],a=e[5],l=e[6],c=e[7],u=e[8],h=u*o-a*c,f=a*l-u*s,d=c*s-o*l,g=t*h+n*f+r*d;if(g===0)return this.set(0,0,0,0,0,0,0,0,0);const v=1/g;return e[0]=h*v,e[1]=(r*c-u*n)*v,e[2]=(a*n-r*o)*v,e[3]=f*v,e[4]=(u*t-r*l)*v,e[5]=(r*s-a*t)*v,e[6]=d*v,e[7]=(n*l-c*t)*v,e[8]=(o*t-n*s)*v,this}transpose(){let e;const t=this.elements;return e=t[1],t[1]=t[3],t[3]=e,e=t[2],t[2]=t[6],t[6]=e,e=t[5],t[5]=t[7],t[7]=e,this}getNormalMatrix(e){return this.setFromMatrix4(e).invert().transpose()}transposeIntoArray(e){const t=this.elements;return e[0]=t[0],e[1]=t[3],e[2]=t[6],e[3]=t[1],e[4]=t[4],e[5]=t[7],e[6]=t[2],e[7]=t[5],e[8]=t[8],this}setUvTransform(e,t,n,r,s,o,a){const l=Math.cos(s),c=Math.sin(s);return this.set(n*l,n*c,-n*(l*o+c*a)+o+e,-r*c,r*l,-r*(-c*o+l*a)+a+t,0,0,1),this}scale(e,t){const n=this.elements;return n[0]*=e,n[3]*=e,n[6]*=e,n[1]*=t,n[4]*=t,n[7]*=t,this}rotate(e){const t=Math.cos(e),n=Math.sin(e),r=this.elements,s=r[0],o=r[3],a=r[6],l=r[1],c=r[4],u=r[7];return r[0]=t*s+n*l,r[3]=t*o+n*c,r[6]=t*a+n*u,r[1]=-n*s+t*l,r[4]=-n*o+t*c,r[7]=-n*a+t*u,this}translate(e,t){const n=this.elements;return n[0]+=e*n[2],n[3]+=e*n[5],n[6]+=e*n[8],n[1]+=t*n[2],n[4]+=t*n[5],n[7]+=t*n[8],this}equals(e){const t=this.elements,n=e.elements;for(let r=0;r<9;r++)if(t[r]!==n[r])return!1;return!0}fromArray(e,t=0){for(let n=0;n<9;n++)this.elements[n]=e[n+t];return this}toArray(e=[],t=0){const n=this.elements;return e[t]=n[0],e[t+1]=n[1],e[t+2]=n[2],e[t+3]=n[3],e[t+4]=n[4],e[t+5]=n[5],e[t+6]=n[6],e[t+7]=n[7],e[t+8]=n[8],e}clone(){return new this.constructor().fromArray(this.elements)}}k0.prototype.isMatrix3=!0;function b4(i){if(i.length===0)return-1/0;let e=i[0];for(let t=1,n=i.length;te&&(e=i[t]);return e}function _l(i){return document.createElementNS("http://www.w3.org/1999/xhtml",i)}function fu(i,e=0){let t=3735928559^e,n=1103547991^e;for(let r=0,s;r>>16,2246822507)^Math.imul(n^n>>>13,3266489909),n=Math.imul(n^n>>>16,2246822507)^Math.imul(t^t>>>13,3266489909),4294967296*(2097151&n)+(t>>>0)}let Xi;class Jr{static getDataURL(e){if(/^data:/i.test(e.src)||typeof HTMLCanvasElement>"u")return e.src;let t;if(e instanceof HTMLCanvasElement)t=e;else{Xi===void 0&&(Xi=_l("canvas")),Xi.width=e.width,Xi.height=e.height;const n=Xi.getContext("2d");e instanceof ImageData?n.putImageData(e,0,0):n.drawImage(e,0,0,e.width,e.height),t=Xi}return t.width>2048||t.height>2048?(console.warn("THREE.ImageUtils.getDataURL: Image converted to jpg for performance reasons",e),t.toDataURL("image/jpeg",.6)):t.toDataURL("image/png")}}let Iv=0,A0=class tc extends ni{constructor(e=tc.DEFAULT_IMAGE,t=tc.DEFAULT_MAPPING,n=m0,r=m0,s=s0,o=Ni,a=a0,l=Zn,c=1,u=J0){super(),Object.defineProperty(this,"id",{value:Iv++}),this.uuid=yt(),this.name="",this.image=e,this.mipmaps=[],this.mapping=t,this.wrapS=n,this.wrapT=r,this.magFilter=s,this.minFilter=o,this.anisotropy=c,this.format=a,this.internalFormat=null,this.type=l,this.offset=new ee(0,0),this.repeat=new ee(1,1),this.center=new ee(0,0),this.rotation=0,this.matrixAutoUpdate=!0,this.matrix=new k0,this.generateMipmaps=!0,this.premultiplyAlpha=!1,this.flipY=!0,this.unpackAlignment=4,this.encoding=u,this.userData={},this.version=0,this.onUpdate=null,this.isRenderTargetTexture=!1}updateMatrix(){this.matrix.setUvTransform(this.offset.x,this.offset.y,this.repeat.x,this.repeat.y,this.rotation,this.center.x,this.center.y)}clone(){return new this.constructor().copy(this)}copy(e){return this.name=e.name,this.image=e.image,this.mipmaps=e.mipmaps.slice(0),this.mapping=e.mapping,this.wrapS=e.wrapS,this.wrapT=e.wrapT,this.magFilter=e.magFilter,this.minFilter=e.minFilter,this.anisotropy=e.anisotropy,this.format=e.format,this.internalFormat=e.internalFormat,this.type=e.type,this.offset.copy(e.offset),this.repeat.copy(e.repeat),this.center.copy(e.center),this.rotation=e.rotation,this.matrixAutoUpdate=e.matrixAutoUpdate,this.matrix.copy(e.matrix),this.generateMipmaps=e.generateMipmaps,this.premultiplyAlpha=e.premultiplyAlpha,this.flipY=e.flipY,this.unpackAlignment=e.unpackAlignment,this.encoding=e.encoding,this.userData=JSON.parse(JSON.stringify(e.userData)),this}toJSON(e){const t=e===void 0||typeof e=="string";if(!t&&e.textures[this.uuid]!==void 0)return e.textures[this.uuid];const n={metadata:{version:4.5,type:"Texture",generator:"Texture.toJSON"},uuid:this.uuid,name:this.name,mapping:this.mapping,repeat:[this.repeat.x,this.repeat.y],offset:[this.offset.x,this.offset.y],center:[this.center.x,this.center.y],rotation:this.rotation,wrap:[this.wrapS,this.wrapT],format:this.format,type:this.type,encoding:this.encoding,minFilter:this.minFilter,magFilter:this.magFilter,anisotropy:this.anisotropy,flipY:this.flipY,premultiplyAlpha:this.premultiplyAlpha,unpackAlignment:this.unpackAlignment};if(this.image!==void 0){const r=this.image;if(r.uuid===void 0&&(r.uuid=yt()),!t&&e.images[r.uuid]===void 0){let s;if(Array.isArray(r)){s=[];for(let o=0,a=r.length;o1)switch(this.wrapS){case Qt:e.x=e.x-Math.floor(e.x);break;case m0:e.x=e.x<0?0:1;break;case Wa:Math.abs(Math.floor(e.x)%2)===1?e.x=Math.ceil(e.x)-e.x:e.x=e.x-Math.floor(e.x);break}if(e.y<0||e.y>1)switch(this.wrapT){case Qt:e.y=e.y-Math.floor(e.y);break;case m0:e.y=e.y<0?0:1;break;case Wa:Math.abs(Math.floor(e.y)%2)===1?e.y=Math.ceil(e.y)-e.y:e.y=e.y-Math.floor(e.y);break}return this.flipY&&(e.y=1-e.y),e}set needsUpdate(e){e===!0&&this.version++}};A0.DEFAULT_IMAGE=void 0;A0.DEFAULT_MAPPING=mr;A0.prototype.isTexture=!0;function jl(i){return typeof HTMLImageElement<"u"&&i instanceof HTMLImageElement||typeof HTMLCanvasElement<"u"&&i instanceof HTMLCanvasElement||typeof ImageBitmap<"u"&&i instanceof ImageBitmap?Jr.getDataURL(i):i.data?{data:Array.prototype.slice.call(i.data),width:i.width,height:i.height,type:i.data.constructor.name}:(console.warn("THREE.Texture: Unable to serialize Texture."),{})}class $e{constructor(e=0,t=0,n=0,r=1){this.x=e,this.y=t,this.z=n,this.w=r}get width(){return this.z}set width(e){this.z=e}get height(){return this.w}set height(e){this.w=e}set(e,t,n,r){return this.x=e,this.y=t,this.z=n,this.w=r,this}setScalar(e){return this.x=e,this.y=e,this.z=e,this.w=e,this}setX(e){return this.x=e,this}setY(e){return this.y=e,this}setZ(e){return this.z=e,this}setW(e){return this.w=e,this}setComponent(e,t){switch(e){case 0:this.x=t;break;case 1:this.y=t;break;case 2:this.z=t;break;case 3:this.w=t;break;default:throw new Error("index is out of range: "+e)}return this}getComponent(e){switch(e){case 0:return this.x;case 1:return this.y;case 2:return this.z;case 3:return this.w;default:throw new Error("index is out of range: "+e)}}clone(){return new this.constructor(this.x,this.y,this.z,this.w)}copy(e){return this.x=e.x,this.y=e.y,this.z=e.z,this.w=e.w!==void 0?e.w:1,this}add(e,t){return t!==void 0?(console.warn("THREE.Vector4: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(e,t)):(this.x+=e.x,this.y+=e.y,this.z+=e.z,this.w+=e.w,this)}addScalar(e){return this.x+=e,this.y+=e,this.z+=e,this.w+=e,this}addVectors(e,t){return this.x=e.x+t.x,this.y=e.y+t.y,this.z=e.z+t.z,this.w=e.w+t.w,this}addScaledVector(e,t){return this.x+=e.x*t,this.y+=e.y*t,this.z+=e.z*t,this.w+=e.w*t,this}sub(e,t){return t!==void 0?(console.warn("THREE.Vector4: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(e,t)):(this.x-=e.x,this.y-=e.y,this.z-=e.z,this.w-=e.w,this)}subScalar(e){return this.x-=e,this.y-=e,this.z-=e,this.w-=e,this}subVectors(e,t){return this.x=e.x-t.x,this.y=e.y-t.y,this.z=e.z-t.z,this.w=e.w-t.w,this}multiply(e){return this.x*=e.x,this.y*=e.y,this.z*=e.z,this.w*=e.w,this}multiplyScalar(e){return this.x*=e,this.y*=e,this.z*=e,this.w*=e,this}applyMatrix4(e){const t=this.x,n=this.y,r=this.z,s=this.w,o=e.elements;return this.x=o[0]*t+o[4]*n+o[8]*r+o[12]*s,this.y=o[1]*t+o[5]*n+o[9]*r+o[13]*s,this.z=o[2]*t+o[6]*n+o[10]*r+o[14]*s,this.w=o[3]*t+o[7]*n+o[11]*r+o[15]*s,this}divideScalar(e){return this.multiplyScalar(1/e)}setAxisAngleFromQuaternion(e){this.w=2*Math.acos(e.w);const t=Math.sqrt(1-e.w*e.w);return t<1e-4?(this.x=1,this.y=0,this.z=0):(this.x=e.x/t,this.y=e.y/t,this.z=e.z/t),this}setAxisAngleFromRotationMatrix(e){let t,n,r,s;const l=e.elements,c=l[0],u=l[4],h=l[8],f=l[1],d=l[5],g=l[9],v=l[2],_=l[6],m=l[10];if(Math.abs(u-f)<.01&&Math.abs(h-v)<.01&&Math.abs(g-_)<.01){if(Math.abs(u+f)<.1&&Math.abs(h+v)<.1&&Math.abs(g+_)<.1&&Math.abs(c+d+m-3)<.1)return this.set(1,0,0,0),this;t=Math.PI;const y=(c+1)/2,x=(d+1)/2,w=(m+1)/2,A=(u+f)/4,b=(h+v)/4,L=(g+_)/4;return y>x&&y>w?y<.01?(n=0,r=.707106781,s=.707106781):(n=Math.sqrt(y),r=A/n,s=b/n):x>w?x<.01?(n=.707106781,r=0,s=.707106781):(r=Math.sqrt(x),n=A/r,s=L/r):w<.01?(n=.707106781,r=.707106781,s=0):(s=Math.sqrt(w),n=b/s,r=L/s),this.set(n,r,s,t),this}let p=Math.sqrt((_-g)*(_-g)+(h-v)*(h-v)+(f-u)*(f-u));return Math.abs(p)<.001&&(p=1),this.x=(_-g)/p,this.y=(h-v)/p,this.z=(f-u)/p,this.w=Math.acos((c+d+m-1)/2),this}min(e){return this.x=Math.min(this.x,e.x),this.y=Math.min(this.y,e.y),this.z=Math.min(this.z,e.z),this.w=Math.min(this.w,e.w),this}max(e){return this.x=Math.max(this.x,e.x),this.y=Math.max(this.y,e.y),this.z=Math.max(this.z,e.z),this.w=Math.max(this.w,e.w),this}clamp(e,t){return this.x=Math.max(e.x,Math.min(t.x,this.x)),this.y=Math.max(e.y,Math.min(t.y,this.y)),this.z=Math.max(e.z,Math.min(t.z,this.z)),this.w=Math.max(e.w,Math.min(t.w,this.w)),this}clampScalar(e,t){return this.x=Math.max(e,Math.min(t,this.x)),this.y=Math.max(e,Math.min(t,this.y)),this.z=Math.max(e,Math.min(t,this.z)),this.w=Math.max(e,Math.min(t,this.w)),this}clampLength(e,t){const n=this.length();return this.divideScalar(n||1).multiplyScalar(Math.max(e,Math.min(t,n)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this.w=Math.floor(this.w),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this.w=Math.ceil(this.w),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this.w=Math.round(this.w),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this.z=this.z<0?Math.ceil(this.z):Math.floor(this.z),this.w=this.w<0?Math.ceil(this.w):Math.floor(this.w),this}negate(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this.w=-this.w,this}dot(e){return this.x*e.x+this.y*e.y+this.z*e.z+this.w*e.w}lengthSq(){return this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w}length(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)+Math.abs(this.w)}normalize(){return this.divideScalar(this.length()||1)}setLength(e){return this.normalize().multiplyScalar(e)}lerp(e,t){return this.x+=(e.x-this.x)*t,this.y+=(e.y-this.y)*t,this.z+=(e.z-this.z)*t,this.w+=(e.w-this.w)*t,this}lerpVectors(e,t,n){return this.x=e.x+(t.x-e.x)*n,this.y=e.y+(t.y-e.y)*n,this.z=e.z+(t.z-e.z)*n,this.w=e.w+(t.w-e.w)*n,this}equals(e){return e.x===this.x&&e.y===this.y&&e.z===this.z&&e.w===this.w}fromArray(e,t=0){return this.x=e[t],this.y=e[t+1],this.z=e[t+2],this.w=e[t+3],this}toArray(e=[],t=0){return e[t]=this.x,e[t+1]=this.y,e[t+2]=this.z,e[t+3]=this.w,e}fromBufferAttribute(e,t,n){return n!==void 0&&console.warn("THREE.Vector4: offset has been removed from .fromBufferAttribute()."),this.x=e.getX(t),this.y=e.getY(t),this.z=e.getZ(t),this.w=e.getW(t),this}random(){return this.x=Math.random(),this.y=Math.random(),this.z=Math.random(),this.w=Math.random(),this}*[Symbol.iterator](){yield this.x,yield this.y,yield this.z,yield this.w}}$e.prototype.isVector4=!0;class C0 extends ni{constructor(e,t,n={}){super(),this.width=e,this.height=t,this.depth=1,this.scissor=new $e(0,0,e,t),this.scissorTest=!1,this.viewport=new $e(0,0,e,t),this.texture=new A0(void 0,n.mapping,n.wrapS,n.wrapT,n.magFilter,n.minFilter,n.format,n.type,n.anisotropy,n.encoding),this.texture.isRenderTargetTexture=!0,this.texture.image={width:e,height:t,depth:1},this.texture.generateMipmaps=n.generateMipmaps!==void 0?n.generateMipmaps:!1,this.texture.internalFormat=n.internalFormat!==void 0?n.internalFormat:null,this.texture.minFilter=n.minFilter!==void 0?n.minFilter:s0,this.depthBuffer=n.depthBuffer!==void 0?n.depthBuffer:!0,this.stencilBuffer=n.stencilBuffer!==void 0?n.stencilBuffer:!1,this.depthTexture=n.depthTexture!==void 0?n.depthTexture:null}setTexture(e){e.image={width:this.width,height:this.height,depth:this.depth},this.texture=e}setSize(e,t,n=1){(this.width!==e||this.height!==t||this.depth!==n)&&(this.width=e,this.height=t,this.depth=n,this.texture.image.width=e,this.texture.image.height=t,this.texture.image.depth=n,this.dispose()),this.viewport.set(0,0,e,t),this.scissor.set(0,0,e,t)}clone(){return new this.constructor().copy(this)}copy(e){return this.width=e.width,this.height=e.height,this.depth=e.depth,this.viewport.copy(e.viewport),this.texture=e.texture.clone(),this.texture.image={...this.texture.image},this.depthBuffer=e.depthBuffer,this.stencilBuffer=e.stencilBuffer,this.depthTexture=e.depthTexture,this}dispose(){this.dispatchEvent({type:"dispose"})}}C0.prototype.isWebGLRenderTarget=!0;class Dv extends C0{constructor(e,t,n){super(e,t);const r=this.texture;this.texture=[];for(let s=0;s=0?1:-1,y=1-m*m;if(y>Number.EPSILON){const w=Math.sqrt(y),A=Math.atan2(w,m*p);_=Math.sin(_*A)/w,a=Math.sin(a*A)/w}const x=a*p;if(l=l*_+f*x,c=c*_+d*x,u=u*_+g*x,h=h*_+v*x,_===1-a){const w=1/Math.sqrt(l*l+c*c+u*u+h*h);l*=w,c*=w,u*=w,h*=w}}e[t]=l,e[t+1]=c,e[t+2]=u,e[t+3]=h}static multiplyQuaternionsFlat(e,t,n,r,s,o){const a=n[r],l=n[r+1],c=n[r+2],u=n[r+3],h=s[o],f=s[o+1],d=s[o+2],g=s[o+3];return e[t]=a*g+u*h+l*d-c*f,e[t+1]=l*g+u*f+c*h-a*d,e[t+2]=c*g+u*d+a*f-l*h,e[t+3]=u*g-a*h-l*f-c*d,e}get x(){return this._x}set x(e){this._x=e,this._onChangeCallback()}get y(){return this._y}set y(e){this._y=e,this._onChangeCallback()}get z(){return this._z}set z(e){this._z=e,this._onChangeCallback()}get w(){return this._w}set w(e){this._w=e,this._onChangeCallback()}set(e,t,n,r){return this._x=e,this._y=t,this._z=n,this._w=r,this._onChangeCallback(),this}clone(){return new this.constructor(this._x,this._y,this._z,this._w)}copy(e){return this._x=e.x,this._y=e.y,this._z=e.z,this._w=e.w,this._onChangeCallback(),this}setFromEuler(e,t){if(!(e&&e.isEuler))throw new Error("THREE.Quaternion: .setFromEuler() now expects an Euler rotation rather than a Vector3 and order.");const n=e._x,r=e._y,s=e._z,o=e._order,a=Math.cos,l=Math.sin,c=a(n/2),u=a(r/2),h=a(s/2),f=l(n/2),d=l(r/2),g=l(s/2);switch(o){case"XYZ":this._x=f*u*h+c*d*g,this._y=c*d*h-f*u*g,this._z=c*u*g+f*d*h,this._w=c*u*h-f*d*g;break;case"YXZ":this._x=f*u*h+c*d*g,this._y=c*d*h-f*u*g,this._z=c*u*g-f*d*h,this._w=c*u*h+f*d*g;break;case"ZXY":this._x=f*u*h-c*d*g,this._y=c*d*h+f*u*g,this._z=c*u*g+f*d*h,this._w=c*u*h-f*d*g;break;case"ZYX":this._x=f*u*h-c*d*g,this._y=c*d*h+f*u*g,this._z=c*u*g-f*d*h,this._w=c*u*h+f*d*g;break;case"YZX":this._x=f*u*h+c*d*g,this._y=c*d*h+f*u*g,this._z=c*u*g-f*d*h,this._w=c*u*h-f*d*g;break;case"XZY":this._x=f*u*h-c*d*g,this._y=c*d*h-f*u*g,this._z=c*u*g+f*d*h,this._w=c*u*h+f*d*g;break;default:console.warn("THREE.Quaternion: .setFromEuler() encountered an unknown order: "+o)}return t!==!1&&this._onChangeCallback(),this}setFromAxisAngle(e,t){const n=t/2,r=Math.sin(n);return this._x=e.x*r,this._y=e.y*r,this._z=e.z*r,this._w=Math.cos(n),this._onChangeCallback(),this}setFromRotationMatrix(e){const t=e.elements,n=t[0],r=t[4],s=t[8],o=t[1],a=t[5],l=t[9],c=t[2],u=t[6],h=t[10],f=n+a+h;if(f>0){const d=.5/Math.sqrt(f+1);this._w=.25/d,this._x=(u-l)*d,this._y=(s-c)*d,this._z=(o-r)*d}else if(n>a&&n>h){const d=2*Math.sqrt(1+n-a-h);this._w=(u-l)/d,this._x=.25*d,this._y=(r+o)/d,this._z=(s+c)/d}else if(a>h){const d=2*Math.sqrt(1+a-n-h);this._w=(s-c)/d,this._x=(r+o)/d,this._y=.25*d,this._z=(l+u)/d}else{const d=2*Math.sqrt(1+h-n-a);this._w=(o-r)/d,this._x=(s+c)/d,this._y=(l+u)/d,this._z=.25*d}return this._onChangeCallback(),this}setFromUnitVectors(e,t){let n=e.dot(t)+1;return nMath.abs(e.z)?(this._x=-e.y,this._y=e.x,this._z=0,this._w=n):(this._x=0,this._y=-e.z,this._z=e.y,this._w=n)):(this._x=e.y*t.z-e.z*t.y,this._y=e.z*t.x-e.x*t.z,this._z=e.x*t.y-e.y*t.x,this._w=n),this.normalize()}angleTo(e){return 2*Math.acos(Math.abs(Q0(this.dot(e),-1,1)))}rotateTowards(e,t){const n=this.angleTo(e);if(n===0)return this;const r=Math.min(1,t/n);return this.slerp(e,r),this}identity(){return this.set(0,0,0,1)}invert(){return this.conjugate()}conjugate(){return this._x*=-1,this._y*=-1,this._z*=-1,this._onChangeCallback(),this}dot(e){return this._x*e._x+this._y*e._y+this._z*e._z+this._w*e._w}lengthSq(){return this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w}length(){return Math.sqrt(this._x*this._x+this._y*this._y+this._z*this._z+this._w*this._w)}normalize(){let e=this.length();return e===0?(this._x=0,this._y=0,this._z=0,this._w=1):(e=1/e,this._x=this._x*e,this._y=this._y*e,this._z=this._z*e,this._w=this._w*e),this._onChangeCallback(),this}multiply(e,t){return t!==void 0?(console.warn("THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead."),this.multiplyQuaternions(e,t)):this.multiplyQuaternions(this,e)}premultiply(e){return this.multiplyQuaternions(e,this)}multiplyQuaternions(e,t){const n=e._x,r=e._y,s=e._z,o=e._w,a=t._x,l=t._y,c=t._z,u=t._w;return this._x=n*u+o*a+r*c-s*l,this._y=r*u+o*l+s*a-n*c,this._z=s*u+o*c+n*l-r*a,this._w=o*u-n*a-r*l-s*c,this._onChangeCallback(),this}slerp(e,t){if(t===0)return this;if(t===1)return this.copy(e);const n=this._x,r=this._y,s=this._z,o=this._w;let a=o*e._w+n*e._x+r*e._y+s*e._z;if(a<0?(this._w=-e._w,this._x=-e._x,this._y=-e._y,this._z=-e._z,a=-a):this.copy(e),a>=1)return this._w=o,this._x=n,this._y=r,this._z=s,this;const l=1-a*a;if(l<=Number.EPSILON){const d=1-t;return this._w=d*o+t*this._w,this._x=d*n+t*this._x,this._y=d*r+t*this._y,this._z=d*s+t*this._z,this.normalize(),this._onChangeCallback(),this}const c=Math.sqrt(l),u=Math.atan2(c,a),h=Math.sin((1-t)*u)/c,f=Math.sin(t*u)/c;return this._w=o*h+this._w*f,this._x=n*h+this._x*f,this._y=r*h+this._y*f,this._z=s*h+this._z*f,this._onChangeCallback(),this}slerpQuaternions(e,t,n){this.copy(e).slerp(t,n)}random(){const e=Math.random(),t=Math.sqrt(1-e),n=Math.sqrt(e),r=2*Math.PI*Math.random(),s=2*Math.PI*Math.random();return this.set(t*Math.cos(r),n*Math.sin(s),n*Math.cos(s),t*Math.sin(r))}equals(e){return e._x===this._x&&e._y===this._y&&e._z===this._z&&e._w===this._w}fromArray(e,t=0){return this._x=e[t],this._y=e[t+1],this._z=e[t+2],this._w=e[t+3],this._onChangeCallback(),this}toArray(e=[],t=0){return e[t]=this._x,e[t+1]=this._y,e[t+2]=this._z,e[t+3]=this._w,e}fromBufferAttribute(e,t){return this._x=e.getX(t),this._y=e.getY(t),this._z=e.getZ(t),this._w=e.getW(t),this}_onChange(e){return this._onChangeCallback=e,this}_onChangeCallback(){}}S0.prototype.isQuaternion=!0;class P{constructor(e=0,t=0,n=0){this.x=e,this.y=t,this.z=n}set(e,t,n){return n===void 0&&(n=this.z),this.x=e,this.y=t,this.z=n,this}setScalar(e){return this.x=e,this.y=e,this.z=e,this}setX(e){return this.x=e,this}setY(e){return this.y=e,this}setZ(e){return this.z=e,this}setComponent(e,t){switch(e){case 0:this.x=t;break;case 1:this.y=t;break;case 2:this.z=t;break;default:throw new Error("index is out of range: "+e)}return this}getComponent(e){switch(e){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw new Error("index is out of range: "+e)}}clone(){return new this.constructor(this.x,this.y,this.z)}copy(e){return this.x=e.x,this.y=e.y,this.z=e.z,this}add(e,t){return t!==void 0?(console.warn("THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),this.addVectors(e,t)):(this.x+=e.x,this.y+=e.y,this.z+=e.z,this)}addScalar(e){return this.x+=e,this.y+=e,this.z+=e,this}addVectors(e,t){return this.x=e.x+t.x,this.y=e.y+t.y,this.z=e.z+t.z,this}addScaledVector(e,t){return this.x+=e.x*t,this.y+=e.y*t,this.z+=e.z*t,this}sub(e,t){return t!==void 0?(console.warn("THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(e,t)):(this.x-=e.x,this.y-=e.y,this.z-=e.z,this)}subScalar(e){return this.x-=e,this.y-=e,this.z-=e,this}subVectors(e,t){return this.x=e.x-t.x,this.y=e.y-t.y,this.z=e.z-t.z,this}multiply(e,t){return t!==void 0?(console.warn("THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead."),this.multiplyVectors(e,t)):(this.x*=e.x,this.y*=e.y,this.z*=e.z,this)}multiplyScalar(e){return this.x*=e,this.y*=e,this.z*=e,this}multiplyVectors(e,t){return this.x=e.x*t.x,this.y=e.y*t.y,this.z=e.z*t.z,this}applyEuler(e){return e&&e.isEuler||console.error("THREE.Vector3: .applyEuler() now expects an Euler rotation rather than a Vector3 and order."),this.applyQuaternion(du.setFromEuler(e))}applyAxisAngle(e,t){return this.applyQuaternion(du.setFromAxisAngle(e,t))}applyMatrix3(e){const t=this.x,n=this.y,r=this.z,s=e.elements;return this.x=s[0]*t+s[3]*n+s[6]*r,this.y=s[1]*t+s[4]*n+s[7]*r,this.z=s[2]*t+s[5]*n+s[8]*r,this}applyNormalMatrix(e){return this.applyMatrix3(e).normalize()}applyMatrix4(e){const t=this.x,n=this.y,r=this.z,s=e.elements,o=1/(s[3]*t+s[7]*n+s[11]*r+s[15]);return this.x=(s[0]*t+s[4]*n+s[8]*r+s[12])*o,this.y=(s[1]*t+s[5]*n+s[9]*r+s[13])*o,this.z=(s[2]*t+s[6]*n+s[10]*r+s[14])*o,this}applyQuaternion(e){const t=this.x,n=this.y,r=this.z,s=e.x,o=e.y,a=e.z,l=e.w,c=l*t+o*r-a*n,u=l*n+a*t-s*r,h=l*r+s*n-o*t,f=-s*t-o*n-a*r;return this.x=c*l+f*-s+u*-a-h*-o,this.y=u*l+f*-o+h*-s-c*-a,this.z=h*l+f*-a+c*-o-u*-s,this}project(e){return this.applyMatrix4(e.matrixWorldInverse).applyMatrix4(e.projectionMatrix)}unproject(e){return this.applyMatrix4(e.projectionMatrixInverse).applyMatrix4(e.matrixWorld)}transformDirection(e){const t=this.x,n=this.y,r=this.z,s=e.elements;return this.x=s[0]*t+s[4]*n+s[8]*r,this.y=s[1]*t+s[5]*n+s[9]*r,this.z=s[2]*t+s[6]*n+s[10]*r,this.normalize()}divide(e){return this.x/=e.x,this.y/=e.y,this.z/=e.z,this}divideScalar(e){return this.multiplyScalar(1/e)}min(e){return this.x=Math.min(this.x,e.x),this.y=Math.min(this.y,e.y),this.z=Math.min(this.z,e.z),this}max(e){return this.x=Math.max(this.x,e.x),this.y=Math.max(this.y,e.y),this.z=Math.max(this.z,e.z),this}clamp(e,t){return this.x=Math.max(e.x,Math.min(t.x,this.x)),this.y=Math.max(e.y,Math.min(t.y,this.y)),this.z=Math.max(e.z,Math.min(t.z,this.z)),this}clampScalar(e,t){return this.x=Math.max(e,Math.min(t,this.x)),this.y=Math.max(e,Math.min(t,this.y)),this.z=Math.max(e,Math.min(t,this.z)),this}clampLength(e,t){const n=this.length();return this.divideScalar(n||1).multiplyScalar(Math.max(e,Math.min(t,n)))}floor(){return this.x=Math.floor(this.x),this.y=Math.floor(this.y),this.z=Math.floor(this.z),this}ceil(){return this.x=Math.ceil(this.x),this.y=Math.ceil(this.y),this.z=Math.ceil(this.z),this}round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this.z=Math.round(this.z),this}roundToZero(){return this.x=this.x<0?Math.ceil(this.x):Math.floor(this.x),this.y=this.y<0?Math.ceil(this.y):Math.floor(this.y),this.z=this.z<0?Math.ceil(this.z):Math.floor(this.z),this}negate(){return this.x=-this.x,this.y=-this.y,this.z=-this.z,this}dot(e){return this.x*e.x+this.y*e.y+this.z*e.z}lengthSq(){return this.x*this.x+this.y*this.y+this.z*this.z}length(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z)}manhattanLength(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)}normalize(){return this.divideScalar(this.length()||1)}setLength(e){return this.normalize().multiplyScalar(e)}lerp(e,t){return this.x+=(e.x-this.x)*t,this.y+=(e.y-this.y)*t,this.z+=(e.z-this.z)*t,this}lerpVectors(e,t,n){return this.x=e.x+(t.x-e.x)*n,this.y=e.y+(t.y-e.y)*n,this.z=e.z+(t.z-e.z)*n,this}cross(e,t){return t!==void 0?(console.warn("THREE.Vector3: .cross() now only accepts one argument. Use .crossVectors( a, b ) instead."),this.crossVectors(e,t)):this.crossVectors(this,e)}crossVectors(e,t){const n=e.x,r=e.y,s=e.z,o=t.x,a=t.y,l=t.z;return this.x=r*l-s*a,this.y=s*o-n*l,this.z=n*a-r*o,this}projectOnVector(e){const t=e.lengthSq();if(t===0)return this.set(0,0,0);const n=e.dot(this)/t;return this.copy(e).multiplyScalar(n)}projectOnPlane(e){return Yl.copy(this).projectOnVector(e),this.sub(Yl)}reflect(e){return this.sub(Yl.copy(e).multiplyScalar(2*this.dot(e)))}angleTo(e){const t=Math.sqrt(this.lengthSq()*e.lengthSq());if(t===0)return Math.PI/2;const n=this.dot(e)/t;return Math.acos(Q0(n,-1,1))}distanceTo(e){return Math.sqrt(this.distanceToSquared(e))}distanceToSquared(e){const t=this.x-e.x,n=this.y-e.y,r=this.z-e.z;return t*t+n*n+r*r}manhattanDistanceTo(e){return Math.abs(this.x-e.x)+Math.abs(this.y-e.y)+Math.abs(this.z-e.z)}setFromSpherical(e){return this.setFromSphericalCoords(e.radius,e.phi,e.theta)}setFromSphericalCoords(e,t,n){const r=Math.sin(t)*e;return this.x=r*Math.sin(n),this.y=Math.cos(t)*e,this.z=r*Math.cos(n),this}setFromCylindrical(e){return this.setFromCylindricalCoords(e.radius,e.theta,e.y)}setFromCylindricalCoords(e,t,n){return this.x=e*Math.sin(t),this.y=n,this.z=e*Math.cos(t),this}setFromMatrixPosition(e){const t=e.elements;return this.x=t[12],this.y=t[13],this.z=t[14],this}setFromMatrixScale(e){const t=this.setFromMatrixColumn(e,0).length(),n=this.setFromMatrixColumn(e,1).length(),r=this.setFromMatrixColumn(e,2).length();return this.x=t,this.y=n,this.z=r,this}setFromMatrixColumn(e,t){return this.fromArray(e.elements,t*4)}setFromMatrix3Column(e,t){return this.fromArray(e.elements,t*3)}equals(e){return e.x===this.x&&e.y===this.y&&e.z===this.z}fromArray(e,t=0){return this.x=e[t],this.y=e[t+1],this.z=e[t+2],this}toArray(e=[],t=0){return e[t]=this.x,e[t+1]=this.y,e[t+2]=this.z,e}fromBufferAttribute(e,t,n){return n!==void 0&&console.warn("THREE.Vector3: offset has been removed from .fromBufferAttribute()."),this.x=e.getX(t),this.y=e.getY(t),this.z=e.getZ(t),this}random(){return this.x=Math.random(),this.y=Math.random(),this.z=Math.random(),this}randomDirection(){const e=(Math.random()-.5)*2,t=Math.random()*Math.PI*2,n=Math.sqrt(1-e**2);return this.x=n*Math.cos(t),this.y=n*Math.sin(t),this.z=e,this}*[Symbol.iterator](){yield this.x,yield this.y,yield this.z}}P.prototype.isVector3=!0;const Yl=new P,du=new S0;class Mt{constructor(e=new P(1/0,1/0,1/0),t=new P(-1/0,-1/0,-1/0)){this.min=e,this.max=t}set(e,t){return this.min.copy(e),this.max.copy(t),this}setFromArray(e){let t=1/0,n=1/0,r=1/0,s=-1/0,o=-1/0,a=-1/0;for(let l=0,c=e.length;ls&&(s=u),h>o&&(o=h),f>a&&(a=f)}return this.min.set(t,n,r),this.max.set(s,o,a),this}setFromBufferAttribute(e){let t=1/0,n=1/0,r=1/0,s=-1/0,o=-1/0,a=-1/0;for(let l=0,c=e.count;ls&&(s=u),h>o&&(o=h),f>a&&(a=f)}return this.min.set(t,n,r),this.max.set(s,o,a),this}setFromPoints(e){this.makeEmpty();for(let t=0,n=e.length;tthis.max.x||e.ythis.max.y||e.zthis.max.z)}containsBox(e){return this.min.x<=e.min.x&&e.max.x<=this.max.x&&this.min.y<=e.min.y&&e.max.y<=this.max.y&&this.min.z<=e.min.z&&e.max.z<=this.max.z}getParameter(e,t){return t.set((e.x-this.min.x)/(this.max.x-this.min.x),(e.y-this.min.y)/(this.max.y-this.min.y),(e.z-this.min.z)/(this.max.z-this.min.z))}intersectsBox(e){return!(e.max.xthis.max.x||e.max.ythis.max.y||e.max.zthis.max.z)}intersectsSphere(e){return this.clampPoint(e.center,_s),_s.distanceToSquared(e.center)<=e.radius*e.radius}intersectsPlane(e){let t,n;return e.normal.x>0?(t=e.normal.x*this.min.x,n=e.normal.x*this.max.x):(t=e.normal.x*this.max.x,n=e.normal.x*this.min.x),e.normal.y>0?(t+=e.normal.y*this.min.y,n+=e.normal.y*this.max.y):(t+=e.normal.y*this.max.y,n+=e.normal.y*this.min.y),e.normal.z>0?(t+=e.normal.z*this.min.z,n+=e.normal.z*this.max.z):(t+=e.normal.z*this.max.z,n+=e.normal.z*this.min.z),t<=-e.constant&&n>=-e.constant}intersectsTriangle(e){if(this.isEmpty())return!1;this.getCenter(bs),Vo.subVectors(this.max,bs),ji.subVectors(e.a,bs),Yi.subVectors(e.b,bs),qi.subVectors(e.c,bs),Tn.subVectors(Yi,ji),An.subVectors(qi,Yi),gi.subVectors(ji,qi);let t=[0,-Tn.z,Tn.y,0,-An.z,An.y,0,-gi.z,gi.y,Tn.z,0,-Tn.x,An.z,0,-An.x,gi.z,0,-gi.x,-Tn.y,Tn.x,0,-An.y,An.x,0,-gi.y,gi.x,0];return!Ql(t,ji,Yi,qi,Vo)||(t=[1,0,0,0,1,0,0,0,1],!Ql(t,ji,Yi,qi,Vo))?!1:(Wo.crossVectors(Tn,An),t=[Wo.x,Wo.y,Wo.z],Ql(t,ji,Yi,qi,Vo))}clampPoint(e,t){return t.copy(e).clamp(this.min,this.max)}distanceToPoint(e){return _s.copy(e).clamp(this.min,this.max).sub(e).length()}getBoundingSphere(e){return this.getCenter(e.center),e.radius=this.getSize(_s).length()*.5,e}intersect(e){return this.min.max(e.min),this.max.min(e.max),this.isEmpty()&&this.makeEmpty(),this}union(e){return this.min.min(e.min),this.max.max(e.max),this}applyMatrix4(e){return this.isEmpty()?this:(rn[0].set(this.min.x,this.min.y,this.min.z).applyMatrix4(e),rn[1].set(this.min.x,this.min.y,this.max.z).applyMatrix4(e),rn[2].set(this.min.x,this.max.y,this.min.z).applyMatrix4(e),rn[3].set(this.min.x,this.max.y,this.max.z).applyMatrix4(e),rn[4].set(this.max.x,this.min.y,this.min.z).applyMatrix4(e),rn[5].set(this.max.x,this.min.y,this.max.z).applyMatrix4(e),rn[6].set(this.max.x,this.max.y,this.min.z).applyMatrix4(e),rn[7].set(this.max.x,this.max.y,this.max.z).applyMatrix4(e),this.setFromPoints(rn),this)}translate(e){return this.min.add(e),this.max.add(e),this}equals(e){return e.min.equals(this.min)&&e.max.equals(this.max)}}Mt.prototype.isBox3=!0;const rn=[new P,new P,new P,new P,new P,new P,new P,new P],_s=new P,ql=new Mt,ji=new P,Yi=new P,qi=new P,Tn=new P,An=new P,gi=new P,bs=new P,Vo=new P,Wo=new P,vi=new P;function Ql(i,e,t,n,r){for(let s=0,o=i.length-3;s<=o;s+=3){vi.fromArray(i,s);const a=r.x*Math.abs(vi.x)+r.y*Math.abs(vi.y)+r.z*Math.abs(vi.z),l=e.dot(vi),c=t.dot(vi),u=n.dot(vi);if(Math.max(-Math.max(l,c,u),Math.min(l,c,u))>a)return!1}return!0}const Nv=new Mt,pu=new P,Kl=new P,Zl=new P;let Ui=class{constructor(e=new P,t=-1){this.center=e,this.radius=t}set(e,t){return this.center.copy(e),this.radius=t,this}setFromPoints(e,t){const n=this.center;t!==void 0?n.copy(t):Nv.setFromPoints(e).getCenter(n);let r=0;for(let s=0,o=e.length;sthis.radius*this.radius&&(t.sub(this.center).normalize(),t.multiplyScalar(this.radius).add(this.center)),t}getBoundingBox(e){return this.isEmpty()?(e.makeEmpty(),e):(e.set(this.center,this.center),e.expandByScalar(this.radius),e)}applyMatrix4(e){return this.center.applyMatrix4(e),this.radius=this.radius*e.getMaxScaleOnAxis(),this}translate(e){return this.center.add(e),this}expandByPoint(e){Zl.subVectors(e,this.center);const t=Zl.lengthSq();if(t>this.radius*this.radius){const n=Math.sqrt(t),r=(n-this.radius)*.5;this.center.add(Zl.multiplyScalar(r/n)),this.radius+=r}return this}union(e){return Kl.subVectors(e.center,this.center).normalize().multiplyScalar(e.radius),this.expandByPoint(pu.copy(e.center).add(Kl)),this.expandByPoint(pu.copy(e.center).sub(Kl)),this}equals(e){return e.center.equals(this.center)&&e.radius===this.radius}clone(){return new this.constructor().copy(this)}};const sn=new P,Jl=new P,Xo=new P,En=new P,$l=new P,jo=new P,e1=new P;class zi{constructor(e=new P,t=new P(0,0,-1)){this.origin=e,this.direction=t}set(e,t){return this.origin.copy(e),this.direction.copy(t),this}copy(e){return this.origin.copy(e.origin),this.direction.copy(e.direction),this}at(e,t){return t.copy(this.direction).multiplyScalar(e).add(this.origin)}lookAt(e){return this.direction.copy(e).sub(this.origin).normalize(),this}recast(e){return this.origin.copy(this.at(e,sn)),this}closestPointToPoint(e,t){t.subVectors(e,this.origin);const n=t.dot(this.direction);return n<0?t.copy(this.origin):t.copy(this.direction).multiplyScalar(n).add(this.origin)}distanceToPoint(e){return Math.sqrt(this.distanceSqToPoint(e))}distanceSqToPoint(e){const t=sn.subVectors(e,this.origin).dot(this.direction);return t<0?this.origin.distanceToSquared(e):(sn.copy(this.direction).multiplyScalar(t).add(this.origin),sn.distanceToSquared(e))}distanceSqToSegment(e,t,n,r){Jl.copy(e).add(t).multiplyScalar(.5),Xo.copy(t).sub(e).normalize(),En.copy(this.origin).sub(Jl);const s=e.distanceTo(t)*.5,o=-this.direction.dot(Xo),a=En.dot(this.direction),l=-En.dot(Xo),c=En.lengthSq(),u=Math.abs(1-o*o);let h,f,d,g;if(u>0)if(h=o*l-a,f=o*a-l,g=s*u,h>=0)if(f>=-g)if(f<=g){const v=1/u;h*=v,f*=v,d=h*(h+o*f+2*a)+f*(o*h+f+2*l)+c}else f=s,h=Math.max(0,-(o*f+a)),d=-h*h+f*(f+2*l)+c;else f=-s,h=Math.max(0,-(o*f+a)),d=-h*h+f*(f+2*l)+c;else f<=-g?(h=Math.max(0,-(-o*s+a)),f=h>0?-s:Math.min(Math.max(-s,-l),s),d=-h*h+f*(f+2*l)+c):f<=g?(h=0,f=Math.min(Math.max(-s,-l),s),d=f*(f+2*l)+c):(h=Math.max(0,-(o*s+a)),f=h>0?s:Math.min(Math.max(-s,-l),s),d=-h*h+f*(f+2*l)+c);else f=o>0?-s:s,h=Math.max(0,-(o*f+a)),d=-h*h+f*(f+2*l)+c;return n&&n.copy(this.direction).multiplyScalar(h).add(this.origin),r&&r.copy(Xo).multiplyScalar(f).add(Jl),d}intersectSphere(e,t){sn.subVectors(e.center,this.origin);const n=sn.dot(this.direction),r=sn.dot(sn)-n*n,s=e.radius*e.radius;if(r>s)return null;const o=Math.sqrt(s-r),a=n-o,l=n+o;return a<0&&l<0?null:a<0?this.at(l,t):this.at(a,t)}intersectsSphere(e){return this.distanceSqToPoint(e.center)<=e.radius*e.radius}distanceToPlane(e){const t=e.normal.dot(this.direction);if(t===0)return e.distanceToPoint(this.origin)===0?0:null;const n=-(this.origin.dot(e.normal)+e.constant)/t;return n>=0?n:null}intersectPlane(e,t){const n=this.distanceToPlane(e);return n===null?null:this.at(n,t)}intersectsPlane(e){const t=e.distanceToPoint(this.origin);return t===0||e.normal.dot(this.direction)*t<0}intersectBox(e,t){let n,r,s,o,a,l;const c=1/this.direction.x,u=1/this.direction.y,h=1/this.direction.z,f=this.origin;return c>=0?(n=(e.min.x-f.x)*c,r=(e.max.x-f.x)*c):(n=(e.max.x-f.x)*c,r=(e.min.x-f.x)*c),u>=0?(s=(e.min.y-f.y)*u,o=(e.max.y-f.y)*u):(s=(e.max.y-f.y)*u,o=(e.min.y-f.y)*u),n>o||s>r||((s>n||n!==n)&&(n=s),(o=0?(a=(e.min.z-f.z)*h,l=(e.max.z-f.z)*h):(a=(e.max.z-f.z)*h,l=(e.min.z-f.z)*h),n>l||a>r)||((a>n||n!==n)&&(n=a),(l=0?n:r,t)}intersectsBox(e){return this.intersectBox(e,sn)!==null}intersectTriangle(e,t,n,r,s){$l.subVectors(t,e),jo.subVectors(n,e),e1.crossVectors($l,jo);let o=this.direction.dot(e1),a;if(o>0){if(r)return null;a=1}else if(o<0)a=-1,o=-o;else return null;En.subVectors(this.origin,e);const l=a*this.direction.dot(jo.crossVectors(En,jo));if(l<0)return null;const c=a*this.direction.dot($l.cross(En));if(c<0||l+c>o)return null;const u=-a*En.dot(e1);return u<0?null:this.at(u/o,s)}applyMatrix4(e){return this.origin.applyMatrix4(e),this.direction.transformDirection(e),this}equals(e){return e.origin.equals(this.origin)&&e.direction.equals(this.direction)}clone(){return new this.constructor().copy(this)}}class Me{constructor(){this.elements=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],arguments.length>0&&console.error("THREE.Matrix4: the constructor no longer reads arguments. use .set() instead.")}set(e,t,n,r,s,o,a,l,c,u,h,f,d,g,v,_){const m=this.elements;return m[0]=e,m[4]=t,m[8]=n,m[12]=r,m[1]=s,m[5]=o,m[9]=a,m[13]=l,m[2]=c,m[6]=u,m[10]=h,m[14]=f,m[3]=d,m[7]=g,m[11]=v,m[15]=_,this}identity(){return this.set(1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1),this}clone(){return new Me().fromArray(this.elements)}copy(e){const t=this.elements,n=e.elements;return t[0]=n[0],t[1]=n[1],t[2]=n[2],t[3]=n[3],t[4]=n[4],t[5]=n[5],t[6]=n[6],t[7]=n[7],t[8]=n[8],t[9]=n[9],t[10]=n[10],t[11]=n[11],t[12]=n[12],t[13]=n[13],t[14]=n[14],t[15]=n[15],this}copyPosition(e){const t=this.elements,n=e.elements;return t[12]=n[12],t[13]=n[13],t[14]=n[14],this}setFromMatrix3(e){const t=e.elements;return this.set(t[0],t[3],t[6],0,t[1],t[4],t[7],0,t[2],t[5],t[8],0,0,0,0,1),this}extractBasis(e,t,n){return e.setFromMatrixColumn(this,0),t.setFromMatrixColumn(this,1),n.setFromMatrixColumn(this,2),this}makeBasis(e,t,n){return this.set(e.x,t.x,n.x,0,e.y,t.y,n.y,0,e.z,t.z,n.z,0,0,0,0,1),this}extractRotation(e){const t=this.elements,n=e.elements,r=1/Qi.setFromMatrixColumn(e,0).length(),s=1/Qi.setFromMatrixColumn(e,1).length(),o=1/Qi.setFromMatrixColumn(e,2).length();return t[0]=n[0]*r,t[1]=n[1]*r,t[2]=n[2]*r,t[3]=0,t[4]=n[4]*s,t[5]=n[5]*s,t[6]=n[6]*s,t[7]=0,t[8]=n[8]*o,t[9]=n[9]*o,t[10]=n[10]*o,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,this}makeRotationFromEuler(e){e&&e.isEuler||console.error("THREE.Matrix4: .makeRotationFromEuler() now expects a Euler rotation rather than a Vector3 and order.");const t=this.elements,n=e.x,r=e.y,s=e.z,o=Math.cos(n),a=Math.sin(n),l=Math.cos(r),c=Math.sin(r),u=Math.cos(s),h=Math.sin(s);if(e.order==="XYZ"){const f=o*u,d=o*h,g=a*u,v=a*h;t[0]=l*u,t[4]=-l*h,t[8]=c,t[1]=d+g*c,t[5]=f-v*c,t[9]=-a*l,t[2]=v-f*c,t[6]=g+d*c,t[10]=o*l}else if(e.order==="YXZ"){const f=l*u,d=l*h,g=c*u,v=c*h;t[0]=f+v*a,t[4]=g*a-d,t[8]=o*c,t[1]=o*h,t[5]=o*u,t[9]=-a,t[2]=d*a-g,t[6]=v+f*a,t[10]=o*l}else if(e.order==="ZXY"){const f=l*u,d=l*h,g=c*u,v=c*h;t[0]=f-v*a,t[4]=-o*h,t[8]=g+d*a,t[1]=d+g*a,t[5]=o*u,t[9]=v-f*a,t[2]=-o*c,t[6]=a,t[10]=o*l}else if(e.order==="ZYX"){const f=o*u,d=o*h,g=a*u,v=a*h;t[0]=l*u,t[4]=g*c-d,t[8]=f*c+v,t[1]=l*h,t[5]=v*c+f,t[9]=d*c-g,t[2]=-c,t[6]=a*l,t[10]=o*l}else if(e.order==="YZX"){const f=o*l,d=o*c,g=a*l,v=a*c;t[0]=l*u,t[4]=v-f*h,t[8]=g*h+d,t[1]=h,t[5]=o*u,t[9]=-a*u,t[2]=-c*u,t[6]=d*h+g,t[10]=f-v*h}else if(e.order==="XZY"){const f=o*l,d=o*c,g=a*l,v=a*c;t[0]=l*u,t[4]=-h,t[8]=c*u,t[1]=f*h+v,t[5]=o*u,t[9]=d*h-g,t[2]=g*h-d,t[6]=a*u,t[10]=v*h+f}return t[3]=0,t[7]=0,t[11]=0,t[12]=0,t[13]=0,t[14]=0,t[15]=1,this}makeRotationFromQuaternion(e){return this.compose(Ov,e,Uv)}lookAt(e,t,n){const r=this.elements;return ht.subVectors(e,t),ht.lengthSq()===0&&(ht.z=1),ht.normalize(),Ln.crossVectors(n,ht),Ln.lengthSq()===0&&(Math.abs(n.z)===1?ht.x+=1e-4:ht.z+=1e-4,ht.normalize(),Ln.crossVectors(n,ht)),Ln.normalize(),Yo.crossVectors(ht,Ln),r[0]=Ln.x,r[4]=Yo.x,r[8]=ht.x,r[1]=Ln.y,r[5]=Yo.y,r[9]=ht.y,r[2]=Ln.z,r[6]=Yo.z,r[10]=ht.z,this}multiply(e,t){return t!==void 0?(console.warn("THREE.Matrix4: .multiply() now only accepts one argument. Use .multiplyMatrices( a, b ) instead."),this.multiplyMatrices(e,t)):this.multiplyMatrices(this,e)}premultiply(e){return this.multiplyMatrices(e,this)}multiplyMatrices(e,t){const n=e.elements,r=t.elements,s=this.elements,o=n[0],a=n[4],l=n[8],c=n[12],u=n[1],h=n[5],f=n[9],d=n[13],g=n[2],v=n[6],_=n[10],m=n[14],p=n[3],y=n[7],x=n[11],w=n[15],A=r[0],b=r[4],L=r[8],B=r[12],I=r[1],C=r[5],Y=r[9],O=r[13],G=r[2],j=r[6],N=r[10],k=r[14],K=r[3],le=r[7],ve=r[11],ce=r[15];return s[0]=o*A+a*I+l*G+c*K,s[4]=o*b+a*C+l*j+c*le,s[8]=o*L+a*Y+l*N+c*ve,s[12]=o*B+a*O+l*k+c*ce,s[1]=u*A+h*I+f*G+d*K,s[5]=u*b+h*C+f*j+d*le,s[9]=u*L+h*Y+f*N+d*ve,s[13]=u*B+h*O+f*k+d*ce,s[2]=g*A+v*I+_*G+m*K,s[6]=g*b+v*C+_*j+m*le,s[10]=g*L+v*Y+_*N+m*ve,s[14]=g*B+v*O+_*k+m*ce,s[3]=p*A+y*I+x*G+w*K,s[7]=p*b+y*C+x*j+w*le,s[11]=p*L+y*Y+x*N+w*ve,s[15]=p*B+y*O+x*k+w*ce,this}multiplyScalar(e){const t=this.elements;return t[0]*=e,t[4]*=e,t[8]*=e,t[12]*=e,t[1]*=e,t[5]*=e,t[9]*=e,t[13]*=e,t[2]*=e,t[6]*=e,t[10]*=e,t[14]*=e,t[3]*=e,t[7]*=e,t[11]*=e,t[15]*=e,this}determinant(){const e=this.elements,t=e[0],n=e[4],r=e[8],s=e[12],o=e[1],a=e[5],l=e[9],c=e[13],u=e[2],h=e[6],f=e[10],d=e[14],g=e[3],v=e[7],_=e[11],m=e[15];return g*(+s*l*h-r*c*h-s*a*f+n*c*f+r*a*d-n*l*d)+v*(+t*l*d-t*c*f+s*o*f-r*o*d+r*c*u-s*l*u)+_*(+t*c*h-t*a*d-s*o*h+n*o*d+s*a*u-n*c*u)+m*(-r*a*u-t*l*h+t*a*f+r*o*h-n*o*f+n*l*u)}transpose(){const e=this.elements;let t;return t=e[1],e[1]=e[4],e[4]=t,t=e[2],e[2]=e[8],e[8]=t,t=e[6],e[6]=e[9],e[9]=t,t=e[3],e[3]=e[12],e[12]=t,t=e[7],e[7]=e[13],e[13]=t,t=e[11],e[11]=e[14],e[14]=t,this}setPosition(e,t,n){const r=this.elements;return e.isVector3?(r[12]=e.x,r[13]=e.y,r[14]=e.z):(r[12]=e,r[13]=t,r[14]=n),this}invert(){const e=this.elements,t=e[0],n=e[1],r=e[2],s=e[3],o=e[4],a=e[5],l=e[6],c=e[7],u=e[8],h=e[9],f=e[10],d=e[11],g=e[12],v=e[13],_=e[14],m=e[15],p=h*_*c-v*f*c+v*l*d-a*_*d-h*l*m+a*f*m,y=g*f*c-u*_*c-g*l*d+o*_*d+u*l*m-o*f*m,x=u*v*c-g*h*c+g*a*d-o*v*d-u*a*m+o*h*m,w=g*h*l-u*v*l-g*a*f+o*v*f+u*a*_-o*h*_,A=t*p+n*y+r*x+s*w;if(A===0)return this.set(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0);const b=1/A;return e[0]=p*b,e[1]=(v*f*s-h*_*s-v*r*d+n*_*d+h*r*m-n*f*m)*b,e[2]=(a*_*s-v*l*s+v*r*c-n*_*c-a*r*m+n*l*m)*b,e[3]=(h*l*s-a*f*s-h*r*c+n*f*c+a*r*d-n*l*d)*b,e[4]=y*b,e[5]=(u*_*s-g*f*s+g*r*d-t*_*d-u*r*m+t*f*m)*b,e[6]=(g*l*s-o*_*s-g*r*c+t*_*c+o*r*m-t*l*m)*b,e[7]=(o*f*s-u*l*s+u*r*c-t*f*c-o*r*d+t*l*d)*b,e[8]=x*b,e[9]=(g*h*s-u*v*s-g*n*d+t*v*d+u*n*m-t*h*m)*b,e[10]=(o*v*s-g*a*s+g*n*c-t*v*c-o*n*m+t*a*m)*b,e[11]=(u*a*s-o*h*s-u*n*c+t*h*c+o*n*d-t*a*d)*b,e[12]=w*b,e[13]=(u*v*r-g*h*r+g*n*f-t*v*f-u*n*_+t*h*_)*b,e[14]=(g*a*r-o*v*r-g*n*l+t*v*l+o*n*_-t*a*_)*b,e[15]=(o*h*r-u*a*r+u*n*l-t*h*l-o*n*f+t*a*f)*b,this}scale(e){const t=this.elements,n=e.x,r=e.y,s=e.z;return t[0]*=n,t[4]*=r,t[8]*=s,t[1]*=n,t[5]*=r,t[9]*=s,t[2]*=n,t[6]*=r,t[10]*=s,t[3]*=n,t[7]*=r,t[11]*=s,this}getMaxScaleOnAxis(){const e=this.elements,t=e[0]*e[0]+e[1]*e[1]+e[2]*e[2],n=e[4]*e[4]+e[5]*e[5]+e[6]*e[6],r=e[8]*e[8]+e[9]*e[9]+e[10]*e[10];return Math.sqrt(Math.max(t,n,r))}makeTranslation(e,t,n){return this.set(1,0,0,e,0,1,0,t,0,0,1,n,0,0,0,1),this}makeRotationX(e){const t=Math.cos(e),n=Math.sin(e);return this.set(1,0,0,0,0,t,-n,0,0,n,t,0,0,0,0,1),this}makeRotationY(e){const t=Math.cos(e),n=Math.sin(e);return this.set(t,0,n,0,0,1,0,0,-n,0,t,0,0,0,0,1),this}makeRotationZ(e){const t=Math.cos(e),n=Math.sin(e);return this.set(t,-n,0,0,n,t,0,0,0,0,1,0,0,0,0,1),this}makeRotationAxis(e,t){const n=Math.cos(t),r=Math.sin(t),s=1-n,o=e.x,a=e.y,l=e.z,c=s*o,u=s*a;return this.set(c*o+n,c*a-r*l,c*l+r*a,0,c*a+r*l,u*a+n,u*l-r*o,0,c*l-r*a,u*l+r*o,s*l*l+n,0,0,0,0,1),this}makeScale(e,t,n){return this.set(e,0,0,0,0,t,0,0,0,0,n,0,0,0,0,1),this}makeShear(e,t,n,r,s,o){return this.set(1,n,s,0,e,1,o,0,t,r,1,0,0,0,0,1),this}compose(e,t,n){const r=this.elements,s=t._x,o=t._y,a=t._z,l=t._w,c=s+s,u=o+o,h=a+a,f=s*c,d=s*u,g=s*h,v=o*u,_=o*h,m=a*h,p=l*c,y=l*u,x=l*h,w=n.x,A=n.y,b=n.z;return r[0]=(1-(v+m))*w,r[1]=(d+x)*w,r[2]=(g-y)*w,r[3]=0,r[4]=(d-x)*A,r[5]=(1-(f+m))*A,r[6]=(_+p)*A,r[7]=0,r[8]=(g+y)*b,r[9]=(_-p)*b,r[10]=(1-(f+v))*b,r[11]=0,r[12]=e.x,r[13]=e.y,r[14]=e.z,r[15]=1,this}decompose(e,t,n){const r=this.elements;let s=Qi.set(r[0],r[1],r[2]).length();const o=Qi.set(r[4],r[5],r[6]).length(),a=Qi.set(r[8],r[9],r[10]).length();this.determinant()<0&&(s=-s),e.x=r[12],e.y=r[13],e.z=r[14],Tt.copy(this);const c=1/s,u=1/o,h=1/a;return Tt.elements[0]*=c,Tt.elements[1]*=c,Tt.elements[2]*=c,Tt.elements[4]*=u,Tt.elements[5]*=u,Tt.elements[6]*=u,Tt.elements[8]*=h,Tt.elements[9]*=h,Tt.elements[10]*=h,t.setFromRotationMatrix(Tt),n.x=s,n.y=o,n.z=a,this}makePerspective(e,t,n,r,s,o){o===void 0&&console.warn("THREE.Matrix4: .makePerspective() has been redefined and has a new signature. Please check the docs.");const a=this.elements,l=2*s/(t-e),c=2*s/(n-r),u=(t+e)/(t-e),h=(n+r)/(n-r),f=-(o+s)/(o-s),d=-2*o*s/(o-s);return a[0]=l,a[4]=0,a[8]=u,a[12]=0,a[1]=0,a[5]=c,a[9]=h,a[13]=0,a[2]=0,a[6]=0,a[10]=f,a[14]=d,a[3]=0,a[7]=0,a[11]=-1,a[15]=0,this}makeOrthographic(e,t,n,r,s,o){const a=this.elements,l=1/(t-e),c=1/(n-r),u=1/(o-s),h=(t+e)*l,f=(n+r)*c,d=(o+s)*u;return a[0]=2*l,a[4]=0,a[8]=0,a[12]=-h,a[1]=0,a[5]=2*c,a[9]=0,a[13]=-f,a[2]=0,a[6]=0,a[10]=-2*u,a[14]=-d,a[3]=0,a[7]=0,a[11]=0,a[15]=1,this}equals(e){const t=this.elements,n=e.elements;for(let r=0;r<16;r++)if(t[r]!==n[r])return!1;return!0}fromArray(e,t=0){for(let n=0;n<16;n++)this.elements[n]=e[n+t];return this}toArray(e=[],t=0){const n=this.elements;return e[t]=n[0],e[t+1]=n[1],e[t+2]=n[2],e[t+3]=n[3],e[t+4]=n[4],e[t+5]=n[5],e[t+6]=n[6],e[t+7]=n[7],e[t+8]=n[8],e[t+9]=n[9],e[t+10]=n[10],e[t+11]=n[11],e[t+12]=n[12],e[t+13]=n[13],e[t+14]=n[14],e[t+15]=n[15],e}}Me.prototype.isMatrix4=!0;const Qi=new P,Tt=new Me,Ov=new P(0,0,0),Uv=new P(1,1,1),Ln=new P,Yo=new P,ht=new P,mu=new Me,gu=new S0;class It{constructor(e=0,t=0,n=0,r=It.DefaultOrder){this._x=e,this._y=t,this._z=n,this._order=r}get x(){return this._x}set x(e){this._x=e,this._onChangeCallback()}get y(){return this._y}set y(e){this._y=e,this._onChangeCallback()}get z(){return this._z}set z(e){this._z=e,this._onChangeCallback()}get order(){return this._order}set order(e){this._order=e,this._onChangeCallback()}set(e,t,n,r=this._order){return this._x=e,this._y=t,this._z=n,this._order=r,this._onChangeCallback(),this}clone(){return new this.constructor(this._x,this._y,this._z,this._order)}copy(e){return this._x=e._x,this._y=e._y,this._z=e._z,this._order=e._order,this._onChangeCallback(),this}setFromRotationMatrix(e,t=this._order,n=!0){const r=e.elements,s=r[0],o=r[4],a=r[8],l=r[1],c=r[5],u=r[9],h=r[2],f=r[6],d=r[10];switch(t){case"XYZ":this._y=Math.asin(Q0(a,-1,1)),Math.abs(a)<.9999999?(this._x=Math.atan2(-u,d),this._z=Math.atan2(-o,s)):(this._x=Math.atan2(f,c),this._z=0);break;case"YXZ":this._x=Math.asin(-Q0(u,-1,1)),Math.abs(u)<.9999999?(this._y=Math.atan2(a,d),this._z=Math.atan2(l,c)):(this._y=Math.atan2(-h,s),this._z=0);break;case"ZXY":this._x=Math.asin(Q0(f,-1,1)),Math.abs(f)<.9999999?(this._y=Math.atan2(-h,d),this._z=Math.atan2(-o,c)):(this._y=0,this._z=Math.atan2(l,s));break;case"ZYX":this._y=Math.asin(-Q0(h,-1,1)),Math.abs(h)<.9999999?(this._x=Math.atan2(f,d),this._z=Math.atan2(l,s)):(this._x=0,this._z=Math.atan2(-o,c));break;case"YZX":this._z=Math.asin(Q0(l,-1,1)),Math.abs(l)<.9999999?(this._x=Math.atan2(-u,c),this._y=Math.atan2(-h,s)):(this._x=0,this._y=Math.atan2(a,d));break;case"XZY":this._z=Math.asin(-Q0(o,-1,1)),Math.abs(o)<.9999999?(this._x=Math.atan2(f,c),this._y=Math.atan2(a,s)):(this._x=Math.atan2(-u,d),this._y=0);break;default:console.warn("THREE.Euler: .setFromRotationMatrix() encountered an unknown order: "+t)}return this._order=t,n===!0&&this._onChangeCallback(),this}setFromQuaternion(e,t,n){return mu.makeRotationFromQuaternion(e),this.setFromRotationMatrix(mu,t,n)}setFromVector3(e,t=this._order){return this.set(e.x,e.y,e.z,t)}reorder(e){return gu.setFromEuler(this),this.setFromQuaternion(gu,e)}equals(e){return e._x===this._x&&e._y===this._y&&e._z===this._z&&e._order===this._order}fromArray(e){return this._x=e[0],this._y=e[1],this._z=e[2],e[3]!==void 0&&(this._order=e[3]),this._onChangeCallback(),this}toArray(e=[],t=0){return e[t]=this._x,e[t+1]=this._y,e[t+2]=this._z,e[t+3]=this._order,e}toVector3(e){return e?e.set(this._x,this._y,this._z):new P(this._x,this._y,this._z)}_onChange(e){return this._onChangeCallback=e,this}_onChangeCallback(){}}It.prototype.isEuler=!0;It.DefaultOrder="XYZ";It.RotationOrders=["XYZ","YZX","ZXY","XZY","YXZ","ZYX"];class M4{constructor(){this.mask=1}set(e){this.mask=1<1){for(let t=0;t1){for(let n=0;n0){r.children=[];for(let a=0;a0){r.animations=[];for(let a=0;a0&&(n.geometries=a),l.length>0&&(n.materials=l),c.length>0&&(n.textures=c),u.length>0&&(n.images=u),h.length>0&&(n.shapes=h),f.length>0&&(n.skeletons=f),d.length>0&&(n.animations=d)}return n.object=r,n;function o(a){const l=[];for(const c in a){const u=a[c];delete u.metadata,l.push(u)}return l}}clone(e){return new this.constructor().copy(this,e)}copy(e,t=!0){if(this.name=e.name,this.up.copy(e.up),this.position.copy(e.position),this.rotation.order=e.rotation.order,this.quaternion.copy(e.quaternion),this.scale.copy(e.scale),this.matrix.copy(e.matrix),this.matrixWorld.copy(e.matrixWorld),this.matrixAutoUpdate=e.matrixAutoUpdate,this.matrixWorldNeedsUpdate=e.matrixWorldNeedsUpdate,this.layers.mask=e.layers.mask,this.visible=e.visible,this.castShadow=e.castShadow,this.receiveShadow=e.receiveShadow,this.frustumCulled=e.frustumCulled,this.renderOrder=e.renderOrder,this.userData=JSON.parse(JSON.stringify(e.userData)),t===!0)for(let n=0;n0?r.multiplyScalar(1/Math.sqrt(s)):r.set(0,0,0)}static getBarycoord(e,t,n,r,s){At.subVectors(r,t),an.subVectors(n,t),t1.subVectors(e,t);const o=At.dot(At),a=At.dot(an),l=At.dot(t1),c=an.dot(an),u=an.dot(t1),h=o*c-a*a;if(h===0)return s.set(-2,-1,-1);const f=1/h,d=(c*l-a*u)*f,g=(o*u-a*l)*f;return s.set(1-d-g,g,d)}static containsPoint(e,t,n,r){return this.getBarycoord(e,t,n,r,ln),ln.x>=0&&ln.y>=0&&ln.x+ln.y<=1}static getUV(e,t,n,r,s,o,a,l){return this.getBarycoord(e,t,n,r,ln),l.set(0,0),l.addScaledVector(s,ln.x),l.addScaledVector(o,ln.y),l.addScaledVector(a,ln.z),l}static isFrontFacing(e,t,n,r){return At.subVectors(n,t),an.subVectors(e,t),At.cross(an).dot(r)<0}set(e,t,n){return this.a.copy(e),this.b.copy(t),this.c.copy(n),this}setFromPointsAndIndices(e,t,n,r){return this.a.copy(e[t]),this.b.copy(e[n]),this.c.copy(e[r]),this}setFromAttributeAndIndices(e,t,n,r){return this.a.fromBufferAttribute(e,t),this.b.fromBufferAttribute(e,n),this.c.fromBufferAttribute(e,r),this}clone(){return new this.constructor().copy(this)}copy(e){return this.a.copy(e.a),this.b.copy(e.b),this.c.copy(e.c),this}getArea(){return At.subVectors(this.c,this.b),an.subVectors(this.a,this.b),At.cross(an).length()*.5}getMidpoint(e){return e.addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)}getNormal(e){return R0.getNormal(this.a,this.b,this.c,e)}getPlane(e){return e.setFromCoplanarPoints(this.a,this.b,this.c)}getBarycoord(e,t){return R0.getBarycoord(e,this.a,this.b,this.c,t)}getUV(e,t,n,r,s){return R0.getUV(e,this.a,this.b,this.c,t,n,r,s)}containsPoint(e){return R0.containsPoint(e,this.a,this.b,this.c)}isFrontFacing(e){return R0.isFrontFacing(this.a,this.b,this.c,e)}intersectsBox(e){return e.intersectsTriangle(this)}closestPointToPoint(e,t){const n=this.a,r=this.b,s=this.c;let o,a;Zi.subVectors(r,n),Ji.subVectors(s,n),n1.subVectors(e,n);const l=Zi.dot(n1),c=Ji.dot(n1);if(l<=0&&c<=0)return t.copy(n);i1.subVectors(e,r);const u=Zi.dot(i1),h=Ji.dot(i1);if(u>=0&&h<=u)return t.copy(r);const f=l*h-u*c;if(f<=0&&l>=0&&u<=0)return o=l/(l-u),t.copy(n).addScaledVector(Zi,o);r1.subVectors(e,s);const d=Zi.dot(r1),g=Ji.dot(r1);if(g>=0&&d<=g)return t.copy(s);const v=d*c-l*g;if(v<=0&&c>=0&&g<=0)return a=c/(c-g),t.copy(n).addScaledVector(Ji,a);const _=u*g-d*h;if(_<=0&&h-u>=0&&d-g>=0)return wu.subVectors(s,r),a=(h-u)/(h-u+(d-g)),t.copy(r).addScaledVector(wu,a);const m=1/(_+v+f);return o=v*m,a=f*m,t.copy(n).addScaledVector(Zi,o).addScaledVector(Ji,a)}equals(e){return e.a.equals(this.a)&&e.b.equals(this.b)&&e.c.equals(this.c)}}let Hv=0;class D0 extends ni{constructor(){super(),Object.defineProperty(this,"id",{value:Hv++}),this.uuid=yt(),this.name="",this.type="Material",this.fog=!0,this.blending=Ws,this.side=Nr,this.vertexColors=!1,this.opacity=1,this.format=a0,this.transparent=!1,this.blendSrc=l4,this.blendDst=c4,this.blendEquation=zn,this.blendSrcAlpha=null,this.blendDstAlpha=null,this.blendEquationAlpha=null,this.depthFunc=K1,this.depthTest=!0,this.depthWrite=!0,this.stencilWriteMask=255,this.stencilFunc=xv,this.stencilRef=0,this.stencilFuncMask=255,this.stencilFail=Xl,this.stencilZFail=Xl,this.stencilZPass=Xl,this.stencilWrite=!1,this.clippingPlanes=null,this.clipIntersection=!1,this.clipShadows=!1,this.shadowSide=null,this.colorWrite=!0,this.precision=null,this.polygonOffset=!1,this.polygonOffsetFactor=0,this.polygonOffsetUnits=0,this.dithering=!1,this.alphaToCoverage=!1,this.premultipliedAlpha=!1,this.visible=!0,this.toneMapped=!0,this.userData={},this.version=0,this._alphaTest=0}get alphaTest(){return this._alphaTest}set alphaTest(e){this._alphaTest>0!=e>0&&this.version++,this._alphaTest=e}onBuild(){}onBeforeRender(){}onBeforeCompile(){}customProgramCacheKey(){return this.onBeforeCompile.toString()}setValues(e){if(e!==void 0)for(const t in e){const n=e[t];if(n===void 0){console.warn("THREE.Material: '"+t+"' parameter is undefined.");continue}if(t==="shading"){console.warn("THREE."+this.type+": .shading has been removed. Use the boolean .flatShading instead."),this.flatShading=n===o4;continue}const r=this[t];if(r===void 0){console.warn("THREE."+this.type+": '"+t+"' is not a property of this material.");continue}r&&r.isColor?r.set(n):r&&r.isVector3&&n&&n.isVector3?r.copy(n):this[t]=n}}toJSON(e){const t=e===void 0||typeof e=="string";t&&(e={textures:{},images:{}});const n={metadata:{version:4.5,type:"Material",generator:"Material.toJSON"}};n.uuid=this.uuid,n.type=this.type,this.name!==""&&(n.name=this.name),this.color&&this.color.isColor&&(n.color=this.color.getHex()),this.roughness!==void 0&&(n.roughness=this.roughness),this.metalness!==void 0&&(n.metalness=this.metalness),this.sheen!==void 0&&(n.sheen=this.sheen),this.sheenColor&&this.sheenColor.isColor&&(n.sheenColor=this.sheenColor.getHex()),this.sheenRoughness!==void 0&&(n.sheenRoughness=this.sheenRoughness),this.emissive&&this.emissive.isColor&&(n.emissive=this.emissive.getHex()),this.emissiveIntensity&&this.emissiveIntensity!==1&&(n.emissiveIntensity=this.emissiveIntensity),this.specular&&this.specular.isColor&&(n.specular=this.specular.getHex()),this.specularIntensity!==void 0&&(n.specularIntensity=this.specularIntensity),this.specularColor&&this.specularColor.isColor&&(n.specularColor=this.specularColor.getHex()),this.shininess!==void 0&&(n.shininess=this.shininess),this.clearcoat!==void 0&&(n.clearcoat=this.clearcoat),this.clearcoatRoughness!==void 0&&(n.clearcoatRoughness=this.clearcoatRoughness),this.clearcoatMap&&this.clearcoatMap.isTexture&&(n.clearcoatMap=this.clearcoatMap.toJSON(e).uuid),this.clearcoatRoughnessMap&&this.clearcoatRoughnessMap.isTexture&&(n.clearcoatRoughnessMap=this.clearcoatRoughnessMap.toJSON(e).uuid),this.clearcoatNormalMap&&this.clearcoatNormalMap.isTexture&&(n.clearcoatNormalMap=this.clearcoatNormalMap.toJSON(e).uuid,n.clearcoatNormalScale=this.clearcoatNormalScale.toArray()),this.map&&this.map.isTexture&&(n.map=this.map.toJSON(e).uuid),this.matcap&&this.matcap.isTexture&&(n.matcap=this.matcap.toJSON(e).uuid),this.alphaMap&&this.alphaMap.isTexture&&(n.alphaMap=this.alphaMap.toJSON(e).uuid),this.lightMap&&this.lightMap.isTexture&&(n.lightMap=this.lightMap.toJSON(e).uuid,n.lightMapIntensity=this.lightMapIntensity),this.aoMap&&this.aoMap.isTexture&&(n.aoMap=this.aoMap.toJSON(e).uuid,n.aoMapIntensity=this.aoMapIntensity),this.bumpMap&&this.bumpMap.isTexture&&(n.bumpMap=this.bumpMap.toJSON(e).uuid,n.bumpScale=this.bumpScale),this.normalMap&&this.normalMap.isTexture&&(n.normalMap=this.normalMap.toJSON(e).uuid,n.normalMapType=this.normalMapType,n.normalScale=this.normalScale.toArray()),this.displacementMap&&this.displacementMap.isTexture&&(n.displacementMap=this.displacementMap.toJSON(e).uuid,n.displacementScale=this.displacementScale,n.displacementBias=this.displacementBias),this.roughnessMap&&this.roughnessMap.isTexture&&(n.roughnessMap=this.roughnessMap.toJSON(e).uuid),this.metalnessMap&&this.metalnessMap.isTexture&&(n.metalnessMap=this.metalnessMap.toJSON(e).uuid),this.emissiveMap&&this.emissiveMap.isTexture&&(n.emissiveMap=this.emissiveMap.toJSON(e).uuid),this.specularMap&&this.specularMap.isTexture&&(n.specularMap=this.specularMap.toJSON(e).uuid),this.specularIntensityMap&&this.specularIntensityMap.isTexture&&(n.specularIntensityMap=this.specularIntensityMap.toJSON(e).uuid),this.specularColorMap&&this.specularColorMap.isTexture&&(n.specularColorMap=this.specularColorMap.toJSON(e).uuid),this.envMap&&this.envMap.isTexture&&(n.envMap=this.envMap.toJSON(e).uuid,this.combine!==void 0&&(n.combine=this.combine)),this.envMapIntensity!==void 0&&(n.envMapIntensity=this.envMapIntensity),this.reflectivity!==void 0&&(n.reflectivity=this.reflectivity),this.refractionRatio!==void 0&&(n.refractionRatio=this.refractionRatio),this.gradientMap&&this.gradientMap.isTexture&&(n.gradientMap=this.gradientMap.toJSON(e).uuid),this.transmission!==void 0&&(n.transmission=this.transmission),this.transmissionMap&&this.transmissionMap.isTexture&&(n.transmissionMap=this.transmissionMap.toJSON(e).uuid),this.thickness!==void 0&&(n.thickness=this.thickness),this.thicknessMap&&this.thicknessMap.isTexture&&(n.thicknessMap=this.thicknessMap.toJSON(e).uuid),this.attenuationDistance!==void 0&&(n.attenuationDistance=this.attenuationDistance),this.attenuationColor!==void 0&&(n.attenuationColor=this.attenuationColor.getHex()),this.size!==void 0&&(n.size=this.size),this.shadowSide!==null&&(n.shadowSide=this.shadowSide),this.sizeAttenuation!==void 0&&(n.sizeAttenuation=this.sizeAttenuation),this.blending!==Ws&&(n.blending=this.blending),this.side!==Nr&&(n.side=this.side),this.vertexColors&&(n.vertexColors=!0),this.opacity<1&&(n.opacity=this.opacity),this.format!==a0&&(n.format=this.format),this.transparent===!0&&(n.transparent=this.transparent),n.depthFunc=this.depthFunc,n.depthTest=this.depthTest,n.depthWrite=this.depthWrite,n.colorWrite=this.colorWrite,n.stencilWrite=this.stencilWrite,n.stencilWriteMask=this.stencilWriteMask,n.stencilFunc=this.stencilFunc,n.stencilRef=this.stencilRef,n.stencilFuncMask=this.stencilFuncMask,n.stencilFail=this.stencilFail,n.stencilZFail=this.stencilZFail,n.stencilZPass=this.stencilZPass,this.rotation&&this.rotation!==0&&(n.rotation=this.rotation),this.polygonOffset===!0&&(n.polygonOffset=!0),this.polygonOffsetFactor!==0&&(n.polygonOffsetFactor=this.polygonOffsetFactor),this.polygonOffsetUnits!==0&&(n.polygonOffsetUnits=this.polygonOffsetUnits),this.linewidth&&this.linewidth!==1&&(n.linewidth=this.linewidth),this.dashSize!==void 0&&(n.dashSize=this.dashSize),this.gapSize!==void 0&&(n.gapSize=this.gapSize),this.scale!==void 0&&(n.scale=this.scale),this.dithering===!0&&(n.dithering=!0),this.alphaTest>0&&(n.alphaTest=this.alphaTest),this.alphaToCoverage===!0&&(n.alphaToCoverage=this.alphaToCoverage),this.premultipliedAlpha===!0&&(n.premultipliedAlpha=this.premultipliedAlpha),this.wireframe===!0&&(n.wireframe=this.wireframe),this.wireframeLinewidth>1&&(n.wireframeLinewidth=this.wireframeLinewidth),this.wireframeLinecap!=="round"&&(n.wireframeLinecap=this.wireframeLinecap),this.wireframeLinejoin!=="round"&&(n.wireframeLinejoin=this.wireframeLinejoin),this.flatShading===!0&&(n.flatShading=this.flatShading),this.visible===!1&&(n.visible=!1),this.toneMapped===!1&&(n.toneMapped=!1),JSON.stringify(this.userData)!=="{}"&&(n.userData=this.userData);function r(s){const o=[];for(const a in s){const l=s[a];delete l.metadata,o.push(l)}return o}if(t){const s=r(e.textures),o=r(e.images);s.length>0&&(n.textures=s),o.length>0&&(n.images=o)}return n}clone(){return new this.constructor().copy(this)}copy(e){this.name=e.name,this.fog=e.fog,this.blending=e.blending,this.side=e.side,this.vertexColors=e.vertexColors,this.opacity=e.opacity,this.format=e.format,this.transparent=e.transparent,this.blendSrc=e.blendSrc,this.blendDst=e.blendDst,this.blendEquation=e.blendEquation,this.blendSrcAlpha=e.blendSrcAlpha,this.blendDstAlpha=e.blendDstAlpha,this.blendEquationAlpha=e.blendEquationAlpha,this.depthFunc=e.depthFunc,this.depthTest=e.depthTest,this.depthWrite=e.depthWrite,this.stencilWriteMask=e.stencilWriteMask,this.stencilFunc=e.stencilFunc,this.stencilRef=e.stencilRef,this.stencilFuncMask=e.stencilFuncMask,this.stencilFail=e.stencilFail,this.stencilZFail=e.stencilZFail,this.stencilZPass=e.stencilZPass,this.stencilWrite=e.stencilWrite;const t=e.clippingPlanes;let n=null;if(t!==null){const r=t.length;n=new Array(r);for(let s=0;s!==r;++s)n[s]=t[s].clone()}return this.clippingPlanes=n,this.clipIntersection=e.clipIntersection,this.clipShadows=e.clipShadows,this.shadowSide=e.shadowSide,this.colorWrite=e.colorWrite,this.precision=e.precision,this.polygonOffset=e.polygonOffset,this.polygonOffsetFactor=e.polygonOffsetFactor,this.polygonOffsetUnits=e.polygonOffsetUnits,this.dithering=e.dithering,this.alphaTest=e.alphaTest,this.alphaToCoverage=e.alphaToCoverage,this.premultipliedAlpha=e.premultipliedAlpha,this.visible=e.visible,this.toneMapped=e.toneMapped,this.userData=JSON.parse(JSON.stringify(e.userData)),this}dispose(){this.dispatchEvent({type:"dispose"})}set needsUpdate(e){e===!0&&this.version++}}D0.prototype.isMaterial=!0;const S4={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074},Et={h:0,s:0,l:0},Qo={h:0,s:0,l:0};function s1(i,e,t){return t<0&&(t+=1),t>1&&(t-=1),t<1/6?i+(e-i)*6*t:t<1/2?e:t<2/3?i+(e-i)*6*(2/3-t):i}function o1(i){return i<.04045?i*.0773993808:Math.pow(i*.9478672986+.0521327014,2.4)}function a1(i){return i<.0031308?i*12.92:1.055*Math.pow(i,.41666)-.055}class be{constructor(e,t,n){return t===void 0&&n===void 0?this.set(e):this.setRGB(e,t,n)}set(e){return e&&e.isColor?this.copy(e):typeof e=="number"?this.setHex(e):typeof e=="string"&&this.setStyle(e),this}setScalar(e){return this.r=e,this.g=e,this.b=e,this}setHex(e){return e=Math.floor(e),this.r=(e>>16&255)/255,this.g=(e>>8&255)/255,this.b=(e&255)/255,this}setRGB(e,t,n){return this.r=e,this.g=t,this.b=n,this}setHSL(e,t,n){if(e=Zc(e,1),t=Q0(t,0,1),n=Q0(n,0,1),t===0)this.r=this.g=this.b=n;else{const r=n<=.5?n*(1+t):n+t-n*t,s=2*n-r;this.r=s1(s,r,e+1/3),this.g=s1(s,r,e),this.b=s1(s,r,e-1/3)}return this}setStyle(e){function t(r){r!==void 0&&parseFloat(r)<1&&console.warn("THREE.Color: Alpha component of "+e+" will be ignored.")}let n;if(n=/^((?:rgb|hsl)a?)\(([^\)]*)\)/.exec(e)){let r;const s=n[1],o=n[2];switch(s){case"rgb":case"rgba":if(r=/^\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(o))return this.r=Math.min(255,parseInt(r[1],10))/255,this.g=Math.min(255,parseInt(r[2],10))/255,this.b=Math.min(255,parseInt(r[3],10))/255,t(r[4]),this;if(r=/^\s*(\d+)\%\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(o))return this.r=Math.min(100,parseInt(r[1],10))/100,this.g=Math.min(100,parseInt(r[2],10))/100,this.b=Math.min(100,parseInt(r[3],10))/100,t(r[4]),this;break;case"hsl":case"hsla":if(r=/^\s*(\d*\.?\d+)\s*,\s*(\d+)\%\s*,\s*(\d+)\%\s*(?:,\s*(\d*\.?\d+)\s*)?$/.exec(o)){const a=parseFloat(r[1])/360,l=parseInt(r[2],10)/100,c=parseInt(r[3],10)/100;return t(r[4]),this.setHSL(a,l,c)}break}}else if(n=/^\#([A-Fa-f\d]+)$/.exec(e)){const r=n[1],s=r.length;if(s===3)return this.r=parseInt(r.charAt(0)+r.charAt(0),16)/255,this.g=parseInt(r.charAt(1)+r.charAt(1),16)/255,this.b=parseInt(r.charAt(2)+r.charAt(2),16)/255,this;if(s===6)return this.r=parseInt(r.charAt(0)+r.charAt(1),16)/255,this.g=parseInt(r.charAt(2)+r.charAt(3),16)/255,this.b=parseInt(r.charAt(4)+r.charAt(5),16)/255,this}return e&&e.length>0?this.setColorName(e):this}setColorName(e){const t=S4[e.toLowerCase()];return t!==void 0?this.setHex(t):console.warn("THREE.Color: Unknown color "+e),this}clone(){return new this.constructor(this.r,this.g,this.b)}copy(e){return this.r=e.r,this.g=e.g,this.b=e.b,this}copyGammaToLinear(e,t=2){return this.r=Math.pow(e.r,t),this.g=Math.pow(e.g,t),this.b=Math.pow(e.b,t),this}copyLinearToGamma(e,t=2){const n=t>0?1/t:1;return this.r=Math.pow(e.r,n),this.g=Math.pow(e.g,n),this.b=Math.pow(e.b,n),this}convertGammaToLinear(e){return this.copyGammaToLinear(this,e),this}convertLinearToGamma(e){return this.copyLinearToGamma(this,e),this}copySRGBToLinear(e){return this.r=o1(e.r),this.g=o1(e.g),this.b=o1(e.b),this}copyLinearToSRGB(e){return this.r=a1(e.r),this.g=a1(e.g),this.b=a1(e.b),this}convertSRGBToLinear(){return this.copySRGBToLinear(this),this}convertLinearToSRGB(){return this.copyLinearToSRGB(this),this}getHex(){return this.r*255<<16^this.g*255<<8^this.b*255<<0}getHexString(){return("000000"+this.getHex().toString(16)).slice(-6)}getHSL(e){const t=this.r,n=this.g,r=this.b,s=Math.max(t,n,r),o=Math.min(t,n,r);let a,l;const c=(o+s)/2;if(o===s)a=0,l=0;else{const u=s-o;switch(l=c<=.5?u/(s+o):u/(2-s-o),s){case t:a=(n-r)/u+(n65535?T4:Jc)(e,1):this.index=e,this}getAttribute(e){return this.attributes[e]}setAttribute(e,t){return this.attributes[e]=t,this}deleteAttribute(e){return delete this.attributes[e],this}hasAttribute(e){return this.attributes[e]!==void 0}addGroup(e,t,n=0){this.groups.push({start:e,count:t,materialIndex:n})}clearGroups(){this.groups=[]}setDrawRange(e,t){this.drawRange.start=e,this.drawRange.count=t}applyMatrix4(e){const t=this.attributes.position;t!==void 0&&(t.applyMatrix4(e),t.needsUpdate=!0);const n=this.attributes.normal;if(n!==void 0){const s=new k0().getNormalMatrix(e);n.applyNormalMatrix(s),n.needsUpdate=!0}const r=this.attributes.tangent;return r!==void 0&&(r.transformDirection(e),r.needsUpdate=!0),this.boundingBox!==null&&this.computeBoundingBox(),this.boundingSphere!==null&&this.computeBoundingSphere(),this}applyQuaternion(e){return pt.makeRotationFromQuaternion(e),this.applyMatrix4(pt),this}rotateX(e){return pt.makeRotationX(e),this.applyMatrix4(pt),this}rotateY(e){return pt.makeRotationY(e),this.applyMatrix4(pt),this}rotateZ(e){return pt.makeRotationZ(e),this.applyMatrix4(pt),this}translate(e,t,n){return pt.makeTranslation(e,t,n),this.applyMatrix4(pt),this}scale(e,t,n){return pt.makeScale(e,t,n),this.applyMatrix4(pt),this}lookAt(e){return l1.lookAt(e),l1.updateMatrix(),this.applyMatrix4(l1.matrix),this}center(){return this.computeBoundingBox(),this.boundingBox.getCenter($i).negate(),this.translate($i.x,$i.y,$i.z),this}setFromPoints(e){const t=[];for(let n=0,r=e.length;n0&&(e.userData=this.userData),this.parameters!==void 0){const l=this.parameters;for(const c in l)l[c]!==void 0&&(e[c]=l[c]);return e}e.data={attributes:{}};const t=this.index;t!==null&&(e.data.index={type:t.array.constructor.name,array:Array.prototype.slice.call(t.array)});const n=this.attributes;for(const l in n){const c=n[l];e.data.attributes[l]=c.toJSON(e.data)}const r={};let s=!1;for(const l in this.morphAttributes){const c=this.morphAttributes[l],u=[];for(let h=0,f=c.length;h0&&(r[l]=u,s=!0)}s&&(e.data.morphAttributes=r,e.data.morphTargetsRelative=this.morphTargetsRelative);const o=this.groups;o.length>0&&(e.data.groups=JSON.parse(JSON.stringify(o)));const a=this.boundingSphere;return a!==null&&(e.data.boundingSphere={center:a.center.toArray(),radius:a.radius}),e}clone(){return new this.constructor().copy(this)}copy(e){this.index=null,this.attributes={},this.morphAttributes={},this.groups=[],this.boundingBox=null,this.boundingSphere=null;const t={};this.name=e.name;const n=e.index;n!==null&&this.setIndex(n.clone(t));const r=e.attributes;for(const c in r){const u=r[c];this.setAttribute(c,u.clone(t))}const s=e.morphAttributes;for(const c in s){const u=[],h=s[c];for(let f=0,d=h.length;f0){const r=t[n[0]];if(r!==void 0){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let s=0,o=r.length;s0&&console.error("THREE.Mesh.updateMorphTargets() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")}}raycast(e,t){const n=this.geometry,r=this.material,s=this.matrixWorld;if(r===void 0||(n.boundingSphere===null&&n.computeBoundingSphere(),c1.copy(n.boundingSphere),c1.applyMatrix4(s),e.ray.intersectsSphere(c1)===!1)||(Mu.copy(s).invert(),er.copy(e.ray).applyMatrix4(Mu),n.boundingBox!==null&&er.intersectsBox(n.boundingBox)===!1))return;let o;if(n.isBufferGeometry){const a=n.index,l=n.attributes.position,c=n.morphAttributes.position,u=n.morphTargetsRelative,h=n.attributes.uv,f=n.attributes.uv2,d=n.groups,g=n.drawRange;if(a!==null)if(Array.isArray(r))for(let v=0,_=d.length;v<_;v++){const m=d[v],p=r[m.materialIndex],y=Math.max(m.start,g.start),x=Math.min(a.count,Math.min(m.start+m.count,g.start+g.count));for(let w=y,A=x;wt.far?null:{distance:c,point:ia.clone(),object:i}}function ra(i,e,t,n,r,s,o,a,l,c,u,h){Pn.fromBufferAttribute(r,c),Cn.fromBufferAttribute(r,u),Rn.fromBufferAttribute(r,h);const f=i.morphTargetInfluences;if(s&&f){Zo.set(0,0,0),Jo.set(0,0,0),$o.set(0,0,0);for(let g=0,v=s.length;g0?1:-1,u.push(le.x,le.y,le.z),h.push(ye/b),h.push(1-ve/L),k+=1}}for(let ve=0;ve0&&(t.defines=this.defines),t.vertexShader=this.vertexShader,t.fragmentShader=this.fragmentShader;const n={};for(const r in this.extensions)this.extensions[r]===!0&&(n[r]=!0);return Object.keys(n).length>0&&(t.extensions=n),t}};u0.prototype.isShaderMaterial=!0;let $c=class extends t0{constructor(){super(),this.type="Camera",this.matrixWorldInverse=new Me,this.projectionMatrix=new Me,this.projectionMatrixInverse=new Me}copy(e,t){return super.copy(e,t),this.matrixWorldInverse.copy(e.matrixWorldInverse),this.projectionMatrix.copy(e.projectionMatrix),this.projectionMatrixInverse.copy(e.projectionMatrixInverse),this}getWorldDirection(e){this.updateWorldMatrix(!0,!1);const t=this.matrixWorld.elements;return e.set(-t[8],-t[9],-t[10]).normalize()}updateMatrixWorld(e){super.updateMatrixWorld(e),this.matrixWorldInverse.copy(this.matrixWorld).invert()}updateWorldMatrix(e,t){super.updateWorldMatrix(e,t),this.matrixWorldInverse.copy(this.matrixWorld).invert()}clone(){return new this.constructor().copy(this)}};$c.prototype.isCamera=!0;let X0=class extends $c{constructor(e=50,t=1,n=.1,r=2e3){super(),this.type="PerspectiveCamera",this.fov=e,this.zoom=1,this.near=n,this.far=r,this.focus=10,this.aspect=t,this.view=null,this.filmGauge=35,this.filmOffset=0,this.updateProjectionMatrix()}copy(e,t){return super.copy(e,t),this.fov=e.fov,this.zoom=e.zoom,this.near=e.near,this.far=e.far,this.focus=e.focus,this.aspect=e.aspect,this.view=e.view===null?null:Object.assign({},e.view),this.filmGauge=e.filmGauge,this.filmOffset=e.filmOffset,this}setFocalLength(e){const t=.5*this.getFilmHeight()/e;this.fov=uo*2*Math.atan(t),this.updateProjectionMatrix()}getFocalLength(){const e=Math.tan(js*.5*this.fov);return .5*this.getFilmHeight()/e}getEffectiveFOV(){return uo*2*Math.atan(Math.tan(js*.5*this.fov)/this.zoom)}getFilmWidth(){return this.filmGauge*Math.min(this.aspect,1)}getFilmHeight(){return this.filmGauge/Math.max(this.aspect,1)}setViewOffset(e,t,n,r,s,o){this.aspect=e/t,this.view===null&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=e,this.view.fullHeight=t,this.view.offsetX=n,this.view.offsetY=r,this.view.width=s,this.view.height=o,this.updateProjectionMatrix()}clearViewOffset(){this.view!==null&&(this.view.enabled=!1),this.updateProjectionMatrix()}updateProjectionMatrix(){const e=this.near;let t=e*Math.tan(js*.5*this.fov)/this.zoom,n=2*t,r=this.aspect*n,s=-.5*r;const o=this.view;if(this.view!==null&&this.view.enabled){const l=o.fullWidth,c=o.fullHeight;s+=o.offsetX*r/l,t-=o.offsetY*n/c,r*=o.width/l,n*=o.height/c}const a=this.filmOffset;a!==0&&(s+=e*a/this.getFilmWidth()),this.projectionMatrix.makePerspective(s,s+r,t,t-n,e,this.far),this.projectionMatrixInverse.copy(this.projectionMatrix).invert()}toJSON(e){const t=super.toJSON(e);return t.object.fov=this.fov,t.object.zoom=this.zoom,t.object.near=this.near,t.object.far=this.far,t.object.focus=this.focus,t.object.aspect=this.aspect,this.view!==null&&(t.object.view=Object.assign({},this.view)),t.object.filmGauge=this.filmGauge,t.object.filmOffset=this.filmOffset,t}};X0.prototype.isPerspectiveCamera=!0;const tr=90,nr=1;let _l=class extends t0{constructor(e,t,n){if(super(),this.type="CubeCamera",n.isWebGLCubeRenderTarget!==!0){console.error("THREE.CubeCamera: The constructor now expects an instance of WebGLCubeRenderTarget as third parameter.");return}this.renderTarget=n;const r=new X0(tr,nr,e,t);r.layers=this.layers,r.up.set(0,-1,0),r.lookAt(new P(1,0,0)),this.add(r);const s=new X0(tr,nr,e,t);s.layers=this.layers,s.up.set(0,-1,0),s.lookAt(new P(-1,0,0)),this.add(s);const o=new X0(tr,nr,e,t);o.layers=this.layers,o.up.set(0,0,1),o.lookAt(new P(0,1,0)),this.add(o);const a=new X0(tr,nr,e,t);a.layers=this.layers,a.up.set(0,0,-1),a.lookAt(new P(0,-1,0)),this.add(a);const l=new X0(tr,nr,e,t);l.layers=this.layers,l.up.set(0,-1,0),l.lookAt(new P(0,0,1)),this.add(l);const c=new X0(tr,nr,e,t);c.layers=this.layers,c.up.set(0,-1,0),c.lookAt(new P(0,0,-1)),this.add(c)}update(e,t){this.parent===null&&this.updateMatrixWorld();const n=this.renderTarget,[r,s,o,a,l,c]=this.children,u=e.xr.enabled,h=e.getRenderTarget();e.xr.enabled=!1;const f=n.texture.generateMipmaps;n.texture.generateMipmaps=!1,e.setRenderTarget(n,0),e.render(t,r),e.setRenderTarget(n,1),e.render(t,s),e.setRenderTarget(n,2),e.render(t,o),e.setRenderTarget(n,3),e.render(t,a),e.setRenderTarget(n,4),e.render(t,l),n.texture.generateMipmaps=f,e.setRenderTarget(n,5),e.render(t,c),e.setRenderTarget(h),e.xr.enabled=u}},bl=class extends A0{constructor(e,t,n,r,s,o,a,l,c,u){e=e!==void 0?e:[],t=t!==void 0?t:Zr,super(e,t,n,r,s,o,a,l,c,u),this.flipY=!1}get images(){return this.image}set images(e){this.image=e}};bl.prototype.isCubeTexture=!0;class e9 extends C0{constructor(e,t,n){Number.isInteger(t)&&(console.warn("THREE.WebGLCubeRenderTarget: constructor signature is now WebGLCubeRenderTarget( size, options )"),t=n),super(e,e,t),t=t||{},this.texture=new bl(void 0,t.mapping,t.wrapS,t.wrapT,t.magFilter,t.minFilter,t.format,t.type,t.anisotropy,t.encoding),this.texture.isRenderTargetTexture=!0,this.texture.generateMipmaps=t.generateMipmaps!==void 0?t.generateMipmaps:!1,this.texture.minFilter=t.minFilter!==void 0?t.minFilter:s0,this.texture._needsFlipEnvMap=!1}fromEquirectangularTexture(e,t){this.texture.type=t.type,this.texture.format=a0,this.texture.encoding=t.encoding,this.texture.generateMipmaps=t.generateMipmaps,this.texture.minFilter=t.minFilter,this.texture.magFilter=t.magFilter;const n={uniforms:{tEquirect:{value:null}},vertexShader:` +}`;let u0=class extends D0{constructor(e){super(),this.type="ShaderMaterial",this.defines={},this.uniforms={},this.vertexShader=jv,this.fragmentShader=Yv,this.linewidth=1,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.lights=!1,this.clipping=!1,this.extensions={derivatives:!1,fragDepth:!1,drawBuffers:!1,shaderTextureLOD:!1},this.defaultAttributeValues={color:[1,1,1],uv:[0,0],uv2:[0,0]},this.index0AttributeName=void 0,this.uniformsNeedUpdate=!1,this.glslVersion=null,e!==void 0&&(e.attributes!==void 0&&console.error("THREE.ShaderMaterial: attributes should now be defined in THREE.BufferGeometry instead."),this.setValues(e))}copy(e){return super.copy(e),this.fragmentShader=e.fragmentShader,this.vertexShader=e.vertexShader,this.uniforms=Ur(e.uniforms),this.defines=Object.assign({},e.defines),this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.lights=e.lights,this.clipping=e.clipping,this.extensions=Object.assign({},e.extensions),this.glslVersion=e.glslVersion,this}toJSON(e){const t=super.toJSON(e);t.glslVersion=this.glslVersion,t.uniforms={};for(const r in this.uniforms){const o=this.uniforms[r].value;o&&o.isTexture?t.uniforms[r]={type:"t",value:o.toJSON(e).uuid}:o&&o.isColor?t.uniforms[r]={type:"c",value:o.getHex()}:o&&o.isVector2?t.uniforms[r]={type:"v2",value:o.toArray()}:o&&o.isVector3?t.uniforms[r]={type:"v3",value:o.toArray()}:o&&o.isVector4?t.uniforms[r]={type:"v4",value:o.toArray()}:o&&o.isMatrix3?t.uniforms[r]={type:"m3",value:o.toArray()}:o&&o.isMatrix4?t.uniforms[r]={type:"m4",value:o.toArray()}:t.uniforms[r]={value:o}}Object.keys(this.defines).length>0&&(t.defines=this.defines),t.vertexShader=this.vertexShader,t.fragmentShader=this.fragmentShader;const n={};for(const r in this.extensions)this.extensions[r]===!0&&(n[r]=!0);return Object.keys(n).length>0&&(t.extensions=n),t}};u0.prototype.isShaderMaterial=!0;let $c=class extends t0{constructor(){super(),this.type="Camera",this.matrixWorldInverse=new Me,this.projectionMatrix=new Me,this.projectionMatrixInverse=new Me}copy(e,t){return super.copy(e,t),this.matrixWorldInverse.copy(e.matrixWorldInverse),this.projectionMatrix.copy(e.projectionMatrix),this.projectionMatrixInverse.copy(e.projectionMatrixInverse),this}getWorldDirection(e){this.updateWorldMatrix(!0,!1);const t=this.matrixWorld.elements;return e.set(-t[8],-t[9],-t[10]).normalize()}updateMatrixWorld(e){super.updateMatrixWorld(e),this.matrixWorldInverse.copy(this.matrixWorld).invert()}updateWorldMatrix(e,t){super.updateWorldMatrix(e,t),this.matrixWorldInverse.copy(this.matrixWorld).invert()}clone(){return new this.constructor().copy(this)}};$c.prototype.isCamera=!0;let X0=class extends $c{constructor(e=50,t=1,n=.1,r=2e3){super(),this.type="PerspectiveCamera",this.fov=e,this.zoom=1,this.near=n,this.far=r,this.focus=10,this.aspect=t,this.view=null,this.filmGauge=35,this.filmOffset=0,this.updateProjectionMatrix()}copy(e,t){return super.copy(e,t),this.fov=e.fov,this.zoom=e.zoom,this.near=e.near,this.far=e.far,this.focus=e.focus,this.aspect=e.aspect,this.view=e.view===null?null:Object.assign({},e.view),this.filmGauge=e.filmGauge,this.filmOffset=e.filmOffset,this}setFocalLength(e){const t=.5*this.getFilmHeight()/e;this.fov=uo*2*Math.atan(t),this.updateProjectionMatrix()}getFocalLength(){const e=Math.tan(js*.5*this.fov);return .5*this.getFilmHeight()/e}getEffectiveFOV(){return uo*2*Math.atan(Math.tan(js*.5*this.fov)/this.zoom)}getFilmWidth(){return this.filmGauge*Math.min(this.aspect,1)}getFilmHeight(){return this.filmGauge/Math.max(this.aspect,1)}setViewOffset(e,t,n,r,s,o){this.aspect=e/t,this.view===null&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=e,this.view.fullHeight=t,this.view.offsetX=n,this.view.offsetY=r,this.view.width=s,this.view.height=o,this.updateProjectionMatrix()}clearViewOffset(){this.view!==null&&(this.view.enabled=!1),this.updateProjectionMatrix()}updateProjectionMatrix(){const e=this.near;let t=e*Math.tan(js*.5*this.fov)/this.zoom,n=2*t,r=this.aspect*n,s=-.5*r;const o=this.view;if(this.view!==null&&this.view.enabled){const l=o.fullWidth,c=o.fullHeight;s+=o.offsetX*r/l,t-=o.offsetY*n/c,r*=o.width/l,n*=o.height/c}const a=this.filmOffset;a!==0&&(s+=e*a/this.getFilmWidth()),this.projectionMatrix.makePerspective(s,s+r,t,t-n,e,this.far),this.projectionMatrixInverse.copy(this.projectionMatrix).invert()}toJSON(e){const t=super.toJSON(e);return t.object.fov=this.fov,t.object.zoom=this.zoom,t.object.near=this.near,t.object.far=this.far,t.object.focus=this.focus,t.object.aspect=this.aspect,this.view!==null&&(t.object.view=Object.assign({},this.view)),t.object.filmGauge=this.filmGauge,t.object.filmOffset=this.filmOffset,t}};X0.prototype.isPerspectiveCamera=!0;const tr=90,nr=1;let bl=class extends t0{constructor(e,t,n){if(super(),this.type="CubeCamera",n.isWebGLCubeRenderTarget!==!0){console.error("THREE.CubeCamera: The constructor now expects an instance of WebGLCubeRenderTarget as third parameter.");return}this.renderTarget=n;const r=new X0(tr,nr,e,t);r.layers=this.layers,r.up.set(0,-1,0),r.lookAt(new P(1,0,0)),this.add(r);const s=new X0(tr,nr,e,t);s.layers=this.layers,s.up.set(0,-1,0),s.lookAt(new P(-1,0,0)),this.add(s);const o=new X0(tr,nr,e,t);o.layers=this.layers,o.up.set(0,0,1),o.lookAt(new P(0,1,0)),this.add(o);const a=new X0(tr,nr,e,t);a.layers=this.layers,a.up.set(0,0,-1),a.lookAt(new P(0,-1,0)),this.add(a);const l=new X0(tr,nr,e,t);l.layers=this.layers,l.up.set(0,-1,0),l.lookAt(new P(0,0,1)),this.add(l);const c=new X0(tr,nr,e,t);c.layers=this.layers,c.up.set(0,-1,0),c.lookAt(new P(0,0,-1)),this.add(c)}update(e,t){this.parent===null&&this.updateMatrixWorld();const n=this.renderTarget,[r,s,o,a,l,c]=this.children,u=e.xr.enabled,h=e.getRenderTarget();e.xr.enabled=!1;const f=n.texture.generateMipmaps;n.texture.generateMipmaps=!1,e.setRenderTarget(n,0),e.render(t,r),e.setRenderTarget(n,1),e.render(t,s),e.setRenderTarget(n,2),e.render(t,o),e.setRenderTarget(n,3),e.render(t,a),e.setRenderTarget(n,4),e.render(t,l),n.texture.generateMipmaps=f,e.setRenderTarget(n,5),e.render(t,c),e.setRenderTarget(h),e.xr.enabled=u}},wl=class extends A0{constructor(e,t,n,r,s,o,a,l,c,u){e=e!==void 0?e:[],t=t!==void 0?t:Zr,super(e,t,n,r,s,o,a,l,c,u),this.flipY=!1}get images(){return this.image}set images(e){this.image=e}};wl.prototype.isCubeTexture=!0;class e9 extends C0{constructor(e,t,n){Number.isInteger(t)&&(console.warn("THREE.WebGLCubeRenderTarget: constructor signature is now WebGLCubeRenderTarget( size, options )"),t=n),super(e,e,t),t=t||{},this.texture=new wl(void 0,t.mapping,t.wrapS,t.wrapT,t.magFilter,t.minFilter,t.format,t.type,t.anisotropy,t.encoding),this.texture.isRenderTargetTexture=!0,this.texture.generateMipmaps=t.generateMipmaps!==void 0?t.generateMipmaps:!1,this.texture.minFilter=t.minFilter!==void 0?t.minFilter:s0,this.texture._needsFlipEnvMap=!1}fromEquirectangularTexture(e,t){this.texture.type=t.type,this.texture.format=a0,this.texture.encoding=t.encoding,this.texture.generateMipmaps=t.generateMipmaps,this.texture.minFilter=t.minFilter,this.texture.magFilter=t.magFilter;const n={uniforms:{tEquirect:{value:null}},vertexShader:` varying vec3 vWorldDirection; @@ -49,7 +49,7 @@ gl_FragColor = texture2D( tEquirect, sampleUV ); } - `},r=new ho(5,5,5),s=new u0({name:"CubemapFromEquirect",uniforms:Or(n.uniforms),vertexShader:n.vertexShader,fragmentShader:n.fragmentShader,side:L0,blending:V0});s.uniforms.tEquirect.value=t;const o=new I0(r,s),a=t.minFilter;return t.minFilter===Ni&&(t.minFilter=s0),new _l(1,10,this).update(e,o),t.minFilter=a,o.geometry.dispose(),o.material.dispose(),this}clear(e,t,n,r){const s=e.getRenderTarget();for(let o=0;o<6;o++)e.setRenderTarget(this,o),e.clear(t,n,r);e.setRenderTarget(s)}}e9.prototype.isWebGLCubeRenderTarget=!0;const d1=new P,qv=new P,Qv=new B0;let Xt=class{constructor(e=new P(1,0,0),t=0){this.normal=e,this.constant=t}set(e,t){return this.normal.copy(e),this.constant=t,this}setComponents(e,t,n,r){return this.normal.set(e,t,n),this.constant=r,this}setFromNormalAndCoplanarPoint(e,t){return this.normal.copy(e),this.constant=-t.dot(this.normal),this}setFromCoplanarPoints(e,t,n){const r=d1.subVectors(n,t).cross(qv.subVectors(e,t)).normalize();return this.setFromNormalAndCoplanarPoint(r,e),this}copy(e){return this.normal.copy(e.normal),this.constant=e.constant,this}normalize(){const e=1/this.normal.length();return this.normal.multiplyScalar(e),this.constant*=e,this}negate(){return this.constant*=-1,this.normal.negate(),this}distanceToPoint(e){return this.normal.dot(e)+this.constant}distanceToSphere(e){return this.distanceToPoint(e.center)-e.radius}projectPoint(e,t){return t.copy(this.normal).multiplyScalar(-this.distanceToPoint(e)).add(e)}intersectLine(e,t){const n=e.delta(d1),r=this.normal.dot(n);if(r===0)return this.distanceToPoint(e.start)===0?t.copy(e.start):null;const s=-(e.start.dot(this.normal)+this.constant)/r;return s<0||s>1?null:t.copy(n).multiplyScalar(s).add(e.start)}intersectsLine(e){const t=this.distanceToPoint(e.start),n=this.distanceToPoint(e.end);return t<0&&n>0||n<0&&t>0}intersectsBox(e){return e.intersectsPlane(this)}intersectsSphere(e){return e.intersectsPlane(this)}coplanarPoint(e){return e.copy(this.normal).multiplyScalar(-this.constant)}applyMatrix4(e,t){const n=t||Qv.getNormalMatrix(e),r=this.coplanarPoint(d1).applyMatrix4(e),s=this.normal.applyMatrix3(n).normalize();return this.constant=-r.dot(s),this}translate(e){return this.constant-=e.dot(this.normal),this}equals(e){return e.normal.equals(this.normal)&&e.constant===this.constant}clone(){return new this.constructor().copy(this)}};Xt.prototype.isPlane=!0;const ir=new Ui,sa=new P;class wl{constructor(e=new Xt,t=new Xt,n=new Xt,r=new Xt,s=new Xt,o=new Xt){this.planes=[e,t,n,r,s,o]}set(e,t,n,r,s,o){const a=this.planes;return a[0].copy(e),a[1].copy(t),a[2].copy(n),a[3].copy(r),a[4].copy(s),a[5].copy(o),this}copy(e){const t=this.planes;for(let n=0;n<6;n++)t[n].copy(e.planes[n]);return this}setFromProjectionMatrix(e){const t=this.planes,n=e.elements,r=n[0],s=n[1],o=n[2],a=n[3],l=n[4],c=n[5],u=n[6],h=n[7],f=n[8],d=n[9],g=n[10],v=n[11],_=n[12],m=n[13],p=n[14],y=n[15];return t[0].setComponents(a-r,h-l,v-f,y-_).normalize(),t[1].setComponents(a+r,h+l,v+f,y+_).normalize(),t[2].setComponents(a+s,h+c,v+d,y+m).normalize(),t[3].setComponents(a-s,h-c,v-d,y-m).normalize(),t[4].setComponents(a-o,h-u,v-g,y-p).normalize(),t[5].setComponents(a+o,h+u,v+g,y+p).normalize(),this}intersectsObject(e){const t=e.geometry;return t.boundingSphere===null&&t.computeBoundingSphere(),ir.copy(t.boundingSphere).applyMatrix4(e.matrixWorld),this.intersectsSphere(ir)}intersectsSprite(e){return ir.center.set(0,0,0),ir.radius=.7071067811865476,ir.applyMatrix4(e.matrixWorld),this.intersectsSphere(ir)}intersectsSphere(e){const t=this.planes,n=e.center,r=-e.radius;for(let s=0;s<6;s++)if(t[s].distanceToPoint(n)0?e.max.x:e.min.x,sa.y=r.normal.y>0?e.max.y:e.min.y,sa.z=r.normal.z>0?e.max.z:e.min.z,r.distanceToPoint(sa)<0)return!1}return!0}containsPoint(e){const t=this.planes;for(let n=0;n<6;n++)if(t[n].distanceToPoint(e)<0)return!1;return!0}clone(){return new this.constructor().copy(this)}}function E4(){let i=null,e=!1,t=null,n=null;function r(s,o){t(s,o),n=i.requestAnimationFrame(r)}return{start:function(){e!==!0&&t!==null&&(n=i.requestAnimationFrame(r),e=!0)},stop:function(){i.cancelAnimationFrame(n),e=!1},setAnimationLoop:function(s){t=s},setContext:function(s){i=s}}}function Zv(i,e){const t=e.isWebGL2,n=new WeakMap;function r(c,u){const h=c.array,f=c.usage,d=i.createBuffer();i.bindBuffer(u,d),i.bufferData(u,h,f),c.onUploadCallback();let g=5126;return h instanceof Float32Array?g=5126:h instanceof Float64Array?console.warn("THREE.WebGLAttributes: Unsupported data buffer format: Float64Array."):h instanceof Uint16Array?c.isFloat16BufferAttribute?t?g=5131:console.warn("THREE.WebGLAttributes: Usage of Float16BufferAttribute requires WebGL2."):g=5123:h instanceof Int16Array?g=5122:h instanceof Uint32Array?g=5125:h instanceof Int32Array?g=5124:h instanceof Int8Array?g=5120:(h instanceof Uint8Array||h instanceof Uint8ClampedArray)&&(g=5121),{buffer:d,type:g,bytesPerElement:h.BYTES_PER_ELEMENT,version:c.version}}function s(c,u,h){const f=u.array,d=u.updateRange;i.bindBuffer(h,c),d.count===-1?i.bufferSubData(h,0,f):(t?i.bufferSubData(h,d.offset*f.BYTES_PER_ELEMENT,f,d.offset,d.count):i.bufferSubData(h,d.offset*f.BYTES_PER_ELEMENT,f.subarray(d.offset,d.offset+d.count)),d.count=-1)}function o(c){return c.isInterleavedBufferAttribute&&(c=c.data),n.get(c)}function a(c){c.isInterleavedBufferAttribute&&(c=c.data);const u=n.get(c);u&&(i.deleteBuffer(u.buffer),n.delete(c))}function l(c,u){if(c.isGLBufferAttribute){const f=n.get(c);(!f||f.version1?null:t.copy(n).multiplyScalar(s).add(e.start)}intersectsLine(e){const t=this.distanceToPoint(e.start),n=this.distanceToPoint(e.end);return t<0&&n>0||n<0&&t>0}intersectsBox(e){return e.intersectsPlane(this)}intersectsSphere(e){return e.intersectsPlane(this)}coplanarPoint(e){return e.copy(this.normal).multiplyScalar(-this.constant)}applyMatrix4(e,t){const n=t||Qv.getNormalMatrix(e),r=this.coplanarPoint(p1).applyMatrix4(e),s=this.normal.applyMatrix3(n).normalize();return this.constant=-r.dot(s),this}translate(e){return this.constant-=e.dot(this.normal),this}equals(e){return e.normal.equals(this.normal)&&e.constant===this.constant}clone(){return new this.constructor().copy(this)}};Xt.prototype.isPlane=!0;const ir=new Ui,sa=new P;class Ml{constructor(e=new Xt,t=new Xt,n=new Xt,r=new Xt,s=new Xt,o=new Xt){this.planes=[e,t,n,r,s,o]}set(e,t,n,r,s,o){const a=this.planes;return a[0].copy(e),a[1].copy(t),a[2].copy(n),a[3].copy(r),a[4].copy(s),a[5].copy(o),this}copy(e){const t=this.planes;for(let n=0;n<6;n++)t[n].copy(e.planes[n]);return this}setFromProjectionMatrix(e){const t=this.planes,n=e.elements,r=n[0],s=n[1],o=n[2],a=n[3],l=n[4],c=n[5],u=n[6],h=n[7],f=n[8],d=n[9],g=n[10],v=n[11],_=n[12],m=n[13],p=n[14],y=n[15];return t[0].setComponents(a-r,h-l,v-f,y-_).normalize(),t[1].setComponents(a+r,h+l,v+f,y+_).normalize(),t[2].setComponents(a+s,h+c,v+d,y+m).normalize(),t[3].setComponents(a-s,h-c,v-d,y-m).normalize(),t[4].setComponents(a-o,h-u,v-g,y-p).normalize(),t[5].setComponents(a+o,h+u,v+g,y+p).normalize(),this}intersectsObject(e){const t=e.geometry;return t.boundingSphere===null&&t.computeBoundingSphere(),ir.copy(t.boundingSphere).applyMatrix4(e.matrixWorld),this.intersectsSphere(ir)}intersectsSprite(e){return ir.center.set(0,0,0),ir.radius=.7071067811865476,ir.applyMatrix4(e.matrixWorld),this.intersectsSphere(ir)}intersectsSphere(e){const t=this.planes,n=e.center,r=-e.radius;for(let s=0;s<6;s++)if(t[s].distanceToPoint(n)0?e.max.x:e.min.x,sa.y=r.normal.y>0?e.max.y:e.min.y,sa.z=r.normal.z>0?e.max.z:e.min.z,r.distanceToPoint(sa)<0)return!1}return!0}containsPoint(e){const t=this.planes;for(let n=0;n<6;n++)if(t[n].distanceToPoint(e)<0)return!1;return!0}clone(){return new this.constructor().copy(this)}}function E4(){let i=null,e=!1,t=null,n=null;function r(s,o){t(s,o),n=i.requestAnimationFrame(r)}return{start:function(){e!==!0&&t!==null&&(n=i.requestAnimationFrame(r),e=!0)},stop:function(){i.cancelAnimationFrame(n),e=!1},setAnimationLoop:function(s){t=s},setContext:function(s){i=s}}}function Kv(i,e){const t=e.isWebGL2,n=new WeakMap;function r(c,u){const h=c.array,f=c.usage,d=i.createBuffer();i.bindBuffer(u,d),i.bufferData(u,h,f),c.onUploadCallback();let g=5126;return h instanceof Float32Array?g=5126:h instanceof Float64Array?console.warn("THREE.WebGLAttributes: Unsupported data buffer format: Float64Array."):h instanceof Uint16Array?c.isFloat16BufferAttribute?t?g=5131:console.warn("THREE.WebGLAttributes: Usage of Float16BufferAttribute requires WebGL2."):g=5123:h instanceof Int16Array?g=5122:h instanceof Uint32Array?g=5125:h instanceof Int32Array?g=5124:h instanceof Int8Array?g=5120:(h instanceof Uint8Array||h instanceof Uint8ClampedArray)&&(g=5121),{buffer:d,type:g,bytesPerElement:h.BYTES_PER_ELEMENT,version:c.version}}function s(c,u,h){const f=u.array,d=u.updateRange;i.bindBuffer(h,c),d.count===-1?i.bufferSubData(h,0,f):(t?i.bufferSubData(h,d.offset*f.BYTES_PER_ELEMENT,f,d.offset,d.count):i.bufferSubData(h,d.offset*f.BYTES_PER_ELEMENT,f.subarray(d.offset,d.offset+d.count)),d.count=-1)}function o(c){return c.isInterleavedBufferAttribute&&(c=c.data),n.get(c)}function a(c){c.isInterleavedBufferAttribute&&(c=c.data);const u=n.get(c);u&&(i.deleteBuffer(u.buffer),n.delete(c))}function l(c,u){if(c.isGLBufferAttribute){const f=n.get(c);(!f||f.version #include vHighPrecisionZW = gl_Position.zw; -}`,Zy=`#if DEPTH_PACKING == 3200 +}`,Ky=`#if DEPTH_PACKING == 3200 uniform float opacity; #endif #include @@ -1981,7 +1981,7 @@ void main() { #elif DEPTH_PACKING == 3201 gl_FragColor = packDepthToRGBA( fragCoordZ ); #endif -}`,Ky=`#define DISTANCE +}`,Zy=`#define DISTANCE varying vec3 vWorldPosition; #include #include @@ -2847,7 +2847,7 @@ void main() { #include #include #include -}`,De={alphamap_fragment:Kv,alphamap_pars_fragment:Jv,alphatest_fragment:$v,alphatest_pars_fragment:ex,aomap_fragment:tx,aomap_pars_fragment:nx,begin_vertex:ix,beginnormal_vertex:rx,bsdfs:sx,bumpmap_pars_fragment:ox,clipping_planes_fragment:ax,clipping_planes_pars_fragment:lx,clipping_planes_pars_vertex:cx,clipping_planes_vertex:ux,color_fragment:hx,color_pars_fragment:fx,color_pars_vertex:dx,color_vertex:px,common:mx,cube_uv_reflection_fragment:gx,defaultnormal_vertex:vx,displacementmap_pars_vertex:xx,displacementmap_vertex:yx,emissivemap_fragment:_x,emissivemap_pars_fragment:bx,encodings_fragment:wx,encodings_pars_fragment:Mx,envmap_fragment:Sx,envmap_common_pars_fragment:Tx,envmap_pars_fragment:Ax,envmap_pars_vertex:Ex,envmap_physical_pars_fragment:zx,envmap_vertex:Lx,fog_vertex:Px,fog_pars_vertex:Cx,fog_fragment:Rx,fog_pars_fragment:Fx,gradientmap_pars_fragment:Ix,lightmap_fragment:Dx,lightmap_pars_fragment:Nx,lights_lambert_vertex:Ox,lights_pars_begin:Ux,lights_toon_fragment:Bx,lights_toon_pars_fragment:kx,lights_phong_fragment:Gx,lights_phong_pars_fragment:Hx,lights_physical_fragment:Vx,lights_physical_pars_fragment:Wx,lights_fragment_begin:Xx,lights_fragment_maps:jx,lights_fragment_end:Yx,logdepthbuf_fragment:qx,logdepthbuf_pars_fragment:Qx,logdepthbuf_pars_vertex:Zx,logdepthbuf_vertex:Kx,map_fragment:Jx,map_pars_fragment:$x,map_particle_fragment:ey,map_particle_pars_fragment:ty,metalnessmap_fragment:ny,metalnessmap_pars_fragment:iy,morphnormal_vertex:ry,morphtarget_pars_vertex:sy,morphtarget_vertex:oy,normal_fragment_begin:ay,normal_fragment_maps:ly,normal_pars_fragment:cy,normal_pars_vertex:uy,normal_vertex:hy,normalmap_pars_fragment:fy,clearcoat_normal_fragment_begin:dy,clearcoat_normal_fragment_maps:py,clearcoat_pars_fragment:my,output_fragment:gy,packing:vy,premultiplied_alpha_fragment:xy,project_vertex:yy,dithering_fragment:_y,dithering_pars_fragment:by,roughnessmap_fragment:wy,roughnessmap_pars_fragment:My,shadowmap_pars_fragment:Sy,shadowmap_pars_vertex:Ty,shadowmap_vertex:Ay,shadowmask_pars_fragment:Ey,skinbase_vertex:Ly,skinning_pars_vertex:Py,skinning_vertex:Cy,skinnormal_vertex:Ry,specularmap_fragment:Fy,specularmap_pars_fragment:Iy,tonemapping_fragment:Dy,tonemapping_pars_fragment:Ny,transmission_fragment:Oy,transmission_pars_fragment:Uy,uv_pars_fragment:zy,uv_pars_vertex:By,uv_vertex:ky,uv2_pars_fragment:Gy,uv2_pars_vertex:Hy,uv2_vertex:Vy,worldpos_vertex:Wy,background_vert:Xy,background_frag:jy,cube_vert:Yy,cube_frag:qy,depth_vert:Qy,depth_frag:Zy,distanceRGBA_vert:Ky,distanceRGBA_frag:Jy,equirect_vert:$y,equirect_frag:e_,linedashed_vert:t_,linedashed_frag:n_,meshbasic_vert:i_,meshbasic_frag:r_,meshlambert_vert:s_,meshlambert_frag:o_,meshmatcap_vert:a_,meshmatcap_frag:l_,meshnormal_vert:c_,meshnormal_frag:u_,meshphong_vert:h_,meshphong_frag:f_,meshphysical_vert:d_,meshphysical_frag:p_,meshtoon_vert:m_,meshtoon_frag:g_,points_vert:v_,points_frag:x_,shadow_vert:y_,shadow_frag:__,sprite_vert:b_,sprite_frag:w_},Se={common:{diffuse:{value:new be(16777215)},opacity:{value:1},map:{value:null},uvTransform:{value:new B0},uv2Transform:{value:new B0},alphaMap:{value:null},alphaTest:{value:0}},specularmap:{specularMap:{value:null}},envmap:{envMap:{value:null},flipEnvMap:{value:-1},reflectivity:{value:1},ior:{value:1.5},refractionRatio:{value:.98},maxMipLevel:{value:0}},aomap:{aoMap:{value:null},aoMapIntensity:{value:1}},lightmap:{lightMap:{value:null},lightMapIntensity:{value:1}},emissivemap:{emissiveMap:{value:null}},bumpmap:{bumpMap:{value:null},bumpScale:{value:1}},normalmap:{normalMap:{value:null},normalScale:{value:new ee(1,1)}},displacementmap:{displacementMap:{value:null},displacementScale:{value:1},displacementBias:{value:0}},roughnessmap:{roughnessMap:{value:null}},metalnessmap:{metalnessMap:{value:null}},gradientmap:{gradientMap:{value:null}},fog:{fogDensity:{value:25e-5},fogNear:{value:1},fogFar:{value:2e3},fogColor:{value:new be(16777215)}},lights:{ambientLightColor:{value:[]},lightProbe:{value:[]},directionalLights:{value:[],properties:{direction:{},color:{}}},directionalLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{}}},directionalShadowMap:{value:[]},directionalShadowMatrix:{value:[]},spotLights:{value:[],properties:{color:{},position:{},direction:{},distance:{},coneCos:{},penumbraCos:{},decay:{}}},spotLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{}}},spotShadowMap:{value:[]},spotShadowMatrix:{value:[]},pointLights:{value:[],properties:{color:{},position:{},decay:{},distance:{}}},pointLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{},shadowCameraNear:{},shadowCameraFar:{}}},pointShadowMap:{value:[]},pointShadowMatrix:{value:[]},hemisphereLights:{value:[],properties:{direction:{},skyColor:{},groundColor:{}}},rectAreaLights:{value:[],properties:{color:{},position:{},width:{},height:{}}},ltc_1:{value:null},ltc_2:{value:null}},points:{diffuse:{value:new be(16777215)},opacity:{value:1},size:{value:1},scale:{value:1},map:{value:null},alphaMap:{value:null},alphaTest:{value:0},uvTransform:{value:new B0}},sprite:{diffuse:{value:new be(16777215)},opacity:{value:1},center:{value:new ee(.5,.5)},rotation:{value:0},map:{value:null},alphaMap:{value:null},alphaTest:{value:0},uvTransform:{value:new B0}}},Pt={basic:{uniforms:q0([Se.common,Se.specularmap,Se.envmap,Se.aomap,Se.lightmap,Se.fog]),vertexShader:De.meshbasic_vert,fragmentShader:De.meshbasic_frag},lambert:{uniforms:q0([Se.common,Se.specularmap,Se.envmap,Se.aomap,Se.lightmap,Se.emissivemap,Se.fog,Se.lights,{emissive:{value:new be(0)}}]),vertexShader:De.meshlambert_vert,fragmentShader:De.meshlambert_frag},phong:{uniforms:q0([Se.common,Se.specularmap,Se.envmap,Se.aomap,Se.lightmap,Se.emissivemap,Se.bumpmap,Se.normalmap,Se.displacementmap,Se.fog,Se.lights,{emissive:{value:new be(0)},specular:{value:new be(1118481)},shininess:{value:30}}]),vertexShader:De.meshphong_vert,fragmentShader:De.meshphong_frag},standard:{uniforms:q0([Se.common,Se.envmap,Se.aomap,Se.lightmap,Se.emissivemap,Se.bumpmap,Se.normalmap,Se.displacementmap,Se.roughnessmap,Se.metalnessmap,Se.fog,Se.lights,{emissive:{value:new be(0)},roughness:{value:1},metalness:{value:0},envMapIntensity:{value:1}}]),vertexShader:De.meshphysical_vert,fragmentShader:De.meshphysical_frag},toon:{uniforms:q0([Se.common,Se.aomap,Se.lightmap,Se.emissivemap,Se.bumpmap,Se.normalmap,Se.displacementmap,Se.gradientmap,Se.fog,Se.lights,{emissive:{value:new be(0)}}]),vertexShader:De.meshtoon_vert,fragmentShader:De.meshtoon_frag},matcap:{uniforms:q0([Se.common,Se.bumpmap,Se.normalmap,Se.displacementmap,Se.fog,{matcap:{value:null}}]),vertexShader:De.meshmatcap_vert,fragmentShader:De.meshmatcap_frag},points:{uniforms:q0([Se.points,Se.fog]),vertexShader:De.points_vert,fragmentShader:De.points_frag},dashed:{uniforms:q0([Se.common,Se.fog,{scale:{value:1},dashSize:{value:1},totalSize:{value:2}}]),vertexShader:De.linedashed_vert,fragmentShader:De.linedashed_frag},depth:{uniforms:q0([Se.common,Se.displacementmap]),vertexShader:De.depth_vert,fragmentShader:De.depth_frag},normal:{uniforms:q0([Se.common,Se.bumpmap,Se.normalmap,Se.displacementmap,{opacity:{value:1}}]),vertexShader:De.meshnormal_vert,fragmentShader:De.meshnormal_frag},sprite:{uniforms:q0([Se.sprite,Se.fog]),vertexShader:De.sprite_vert,fragmentShader:De.sprite_frag},background:{uniforms:{uvTransform:{value:new B0},t2D:{value:null}},vertexShader:De.background_vert,fragmentShader:De.background_frag},cube:{uniforms:q0([Se.envmap,{opacity:{value:1}}]),vertexShader:De.cube_vert,fragmentShader:De.cube_frag},equirect:{uniforms:{tEquirect:{value:null}},vertexShader:De.equirect_vert,fragmentShader:De.equirect_frag},distanceRGBA:{uniforms:q0([Se.common,Se.displacementmap,{referencePosition:{value:new P},nearDistance:{value:1},farDistance:{value:1e3}}]),vertexShader:De.distanceRGBA_vert,fragmentShader:De.distanceRGBA_frag},shadow:{uniforms:q0([Se.lights,Se.fog,{color:{value:new be(0)},opacity:{value:1}}]),vertexShader:De.shadow_vert,fragmentShader:De.shadow_frag}};Pt.physical={uniforms:q0([Pt.standard.uniforms,{clearcoat:{value:0},clearcoatMap:{value:null},clearcoatRoughness:{value:0},clearcoatRoughnessMap:{value:null},clearcoatNormalScale:{value:new ee(1,1)},clearcoatNormalMap:{value:null},sheen:{value:0},sheenColor:{value:new be(0)},sheenColorMap:{value:null},sheenRoughness:{value:0},sheenRoughnessMap:{value:null},transmission:{value:0},transmissionMap:{value:null},transmissionSamplerSize:{value:new ee},transmissionSamplerMap:{value:null},thickness:{value:0},thicknessMap:{value:null},attenuationDistance:{value:0},attenuationColor:{value:new be(0)},specularIntensity:{value:0},specularIntensityMap:{value:null},specularColor:{value:new be(1,1,1)},specularColorMap:{value:null}}]),vertexShader:De.meshphysical_vert,fragmentShader:De.meshphysical_frag};function M_(i,e,t,n,r){const s=new be(0);let o=0,a,l,c=null,u=0,h=null;function f(g,v){let _=!1,m=v.isScene===!0?v.background:null;m&&m.isTexture&&(m=e.get(m));const p=i.xr,y=p.getSession&&p.getSession();y&&y.environmentBlendMode==="additive"&&(m=null),m===null?d(s,o):m&&m.isColor&&(d(m,1),_=!0),(i.autoClear||_)&&i.clear(i.autoClearColor,i.autoClearDepth,i.autoClearStencil),m&&(m.isCubeTexture||m.mapping===xl)?(l===void 0&&(l=new I0(new ho(1,1,1),new u0({name:"BackgroundCubeMaterial",uniforms:Or(Pt.cube.uniforms),vertexShader:Pt.cube.vertexShader,fragmentShader:Pt.cube.fragmentShader,side:L0,depthTest:!1,depthWrite:!1,fog:!1})),l.geometry.deleteAttribute("normal"),l.geometry.deleteAttribute("uv"),l.onBeforeRender=function(x,w,A){this.matrixWorld.copyPosition(A.matrixWorld)},Object.defineProperty(l.material,"envMap",{get:function(){return this.uniforms.envMap.value}}),n.update(l)),l.material.uniforms.envMap.value=m,l.material.uniforms.flipEnvMap.value=m.isCubeTexture&&m.isRenderTargetTexture===!1?-1:1,(c!==m||u!==m.version||h!==i.toneMapping)&&(l.material.needsUpdate=!0,c=m,u=m.version,h=i.toneMapping),g.unshift(l,l.geometry,l.material,0,0,null)):m&&m.isTexture&&(a===void 0&&(a=new I0(new t9(2,2),new u0({name:"BackgroundMaterial",uniforms:Or(Pt.background.uniforms),vertexShader:Pt.background.vertexShader,fragmentShader:Pt.background.fragmentShader,side:Dr,depthTest:!1,depthWrite:!1,fog:!1})),a.geometry.deleteAttribute("normal"),Object.defineProperty(a.material,"map",{get:function(){return this.uniforms.t2D.value}}),n.update(a)),a.material.uniforms.t2D.value=m,m.matrixAutoUpdate===!0&&m.updateMatrix(),a.material.uniforms.uvTransform.value.copy(m.matrix),(c!==m||u!==m.version||h!==i.toneMapping)&&(a.material.needsUpdate=!0,c=m,u=m.version,h=i.toneMapping),g.unshift(a,a.geometry,a.material,0,0,null))}function d(g,v){t.buffers.color.setClear(g.r,g.g,g.b,v,r)}return{getClearColor:function(){return s},setClearColor:function(g,v=1){s.set(g),o=v,d(s,o)},getClearAlpha:function(){return o},setClearAlpha:function(g){o=g,d(s,o)},render:f}}function S_(i,e,t,n){const r=i.getParameter(34921),s=n.isWebGL2?null:e.get("OES_vertex_array_object"),o=n.isWebGL2||s!==null,a={},l=v(null);let c=l;function u(O,G,j,N,k){let Z=!1;if(o){const le=g(N,j,G);c!==le&&(c=le,f(c.object)),Z=_(N,k),Z&&m(N,k)}else{const le=G.wireframe===!0;(c.geometry!==N.id||c.program!==j.id||c.wireframe!==le)&&(c.geometry=N.id,c.program=j.id,c.wireframe=le,Z=!0)}O.isInstancedMesh===!0&&(Z=!0),k!==null&&t.update(k,34963),Z&&(b(O,G,j,N),k!==null&&i.bindBuffer(34963,t.get(k).buffer))}function h(){return n.isWebGL2?i.createVertexArray():s.createVertexArrayOES()}function f(O){return n.isWebGL2?i.bindVertexArray(O):s.bindVertexArrayOES(O)}function d(O){return n.isWebGL2?i.deleteVertexArray(O):s.deleteVertexArrayOES(O)}function g(O,G,j){const N=j.wireframe===!0;let k=a[O.id];k===void 0&&(k={},a[O.id]=k);let Z=k[G.id];Z===void 0&&(Z={},k[G.id]=Z);let le=Z[N];return le===void 0&&(le=v(h()),Z[N]=le),le}function v(O){const G=[],j=[],N=[];for(let k=0;k=0){let ye=k[ve];if(ye===void 0&&(ve==="instanceMatrix"&&O.instanceMatrix&&(ye=O.instanceMatrix),ve==="instanceColor"&&O.instanceColor&&(ye=O.instanceColor)),ye!==void 0){const $=ye.normalized,se=ye.itemSize,pe=t.get(ye);if(pe===void 0)continue;const K=pe.buffer,V=pe.type,te=pe.bytesPerElement;if(ye.isInterleavedBufferAttribute){const Q=ye.data,re=Q.stride,we=ye.offset;if(Q&&Q.isInstancedInterleavedBuffer){for(let M=0;M0&&i.getShaderPrecisionFormat(35632,36338).precision>0)return"highp";b="mediump"}return b==="mediump"&&i.getShaderPrecisionFormat(35633,36337).precision>0&&i.getShaderPrecisionFormat(35632,36337).precision>0?"mediump":"lowp"}const o=typeof WebGL2RenderingContext<"u"&&i instanceof WebGL2RenderingContext||typeof WebGL2ComputeRenderingContext<"u"&&i instanceof WebGL2ComputeRenderingContext;let a=t.precision!==void 0?t.precision:"highp";const l=s(a);l!==a&&(console.warn("THREE.WebGLRenderer:",a,"not supported, using",l,"instead."),a=l);const c=o||e.has("WEBGL_draw_buffers"),u=t.logarithmicDepthBuffer===!0,h=i.getParameter(34930),f=i.getParameter(35660),d=i.getParameter(3379),g=i.getParameter(34076),v=i.getParameter(34921),_=i.getParameter(36347),m=i.getParameter(36348),p=i.getParameter(36349),y=f>0,x=o||e.has("OES_texture_float"),w=y&&x,A=o?i.getParameter(36183):0;return{isWebGL2:o,drawBuffers:c,getMaxAnisotropy:r,getMaxPrecision:s,precision:a,logarithmicDepthBuffer:u,maxTextures:h,maxVertexTextures:f,maxTextureSize:d,maxCubemapSize:g,maxAttributes:v,maxVertexUniforms:_,maxVaryings:m,maxFragmentUniforms:p,vertexTextures:y,floatFragmentTextures:x,floatVertexTextures:w,maxSamples:A}}function E_(i){const e=this;let t=null,n=0,r=!1,s=!1;const o=new Xt,a=new B0,l={value:null,needsUpdate:!1};this.uniform=l,this.numPlanes=0,this.numIntersection=0,this.init=function(h,f,d){const g=h.length!==0||f||n!==0||r;return r=f,t=u(h,d,0),n=h.length,g},this.beginShadows=function(){s=!0,u(null)},this.endShadows=function(){s=!1,c()},this.setState=function(h,f,d){const g=h.clippingPlanes,v=h.clipIntersection,_=h.clipShadows,m=i.get(h);if(!r||g===null||g.length===0||s&&!_)s?u(null):c();else{const p=s?0:n,y=p*4;let x=m.clippingState||null;l.value=x,x=u(g,f,y,d);for(let w=0;w!==y;++w)x[w]=t[w];m.clippingState=x,this.numIntersection=v?this.numPlanes:0,this.numPlanes+=p}};function c(){l.value!==t&&(l.value=t,l.needsUpdate=n>0),e.numPlanes=n,e.numIntersection=0}function u(h,f,d,g){const v=h!==null?h.length:0;let _=null;if(v!==0){if(_=l.value,g!==!0||_===null){const m=d+v*4,p=f.matrixWorldInverse;a.getNormalMatrix(p),(_===null||_.length0){const c=i.getRenderTarget(),u=new e9(l.height/2);return u.fromEquirectangularTexture(i,o),e.set(o,u),i.setRenderTarget(c),o.addEventListener("dispose",r),t(u.texture,o.mapping)}else return null}}return o}function r(o){const a=o.target;a.removeEventListener("dispose",r);const l=e.get(a);l!==void 0&&(e.delete(a),l.dispose())}function s(){e=new WeakMap}return{get:n,dispose:s}}let ii=class extends $c{constructor(e=-1,t=1,n=1,r=-1,s=.1,o=2e3){super(),this.type="OrthographicCamera",this.zoom=1,this.view=null,this.left=e,this.right=t,this.top=n,this.bottom=r,this.near=s,this.far=o,this.updateProjectionMatrix()}copy(e,t){return super.copy(e,t),this.left=e.left,this.right=e.right,this.top=e.top,this.bottom=e.bottom,this.near=e.near,this.far=e.far,this.zoom=e.zoom,this.view=e.view===null?null:Object.assign({},e.view),this}setViewOffset(e,t,n,r,s,o){this.view===null&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=e,this.view.fullHeight=t,this.view.offsetX=n,this.view.offsetY=r,this.view.width=s,this.view.height=o,this.updateProjectionMatrix()}clearViewOffset(){this.view!==null&&(this.view.enabled=!1),this.updateProjectionMatrix()}updateProjectionMatrix(){const e=(this.right-this.left)/(2*this.zoom),t=(this.top-this.bottom)/(2*this.zoom),n=(this.right+this.left)/2,r=(this.top+this.bottom)/2;let s=n-e,o=n+e,a=r+t,l=r-t;if(this.view!==null&&this.view.enabled){const c=(this.right-this.left)/this.view.fullWidth/this.zoom,u=(this.top-this.bottom)/this.view.fullHeight/this.zoom;s+=c*this.view.offsetX,o=s+c*this.view.width,a-=u*this.view.offsetY,l=a-u*this.view.height}this.projectionMatrix.makeOrthographic(s,o,a,l,this.near,this.far),this.projectionMatrixInverse.copy(this.projectionMatrix).invert()}toJSON(e){const t=super.toJSON(e);return t.object.zoom=this.zoom,t.object.left=this.left,t.object.right=this.right,t.object.top=this.top,t.object.bottom=this.bottom,t.object.near=this.near,t.object.far=this.far,this.view!==null&&(t.object.view=Object.assign({},this.view)),t}};ii.prototype.isOrthographicCamera=!0;class Ml extends u0{constructor(e){super(e),this.type="RawShaderMaterial"}}Ml.prototype.isRawShaderMaterial=!0;const Ar=4,Wn=8,Vt=Math.pow(2,Wn),P4=[.125,.215,.35,.446,.526,.582],C4=Wn-Ar+1+P4.length,rr=20,Jn={[J0]:0,[at]:1,[Zc]:2,[m4]:3,[g4]:4,[v4]:5,[Qc]:6},p1=new ii,{_lodPlanes:Ms,_sizeLods:Su,_sigmas:oa}=R_(),Tu=new be;let m1=null;const _i=(1+Math.sqrt(5))/2,sr=1/_i,Au=[new P(1,1,1),new P(-1,1,1),new P(1,1,-1),new P(-1,1,-1),new P(0,_i,sr),new P(0,_i,-sr),new P(sr,0,_i),new P(-sr,0,_i),new P(_i,sr,0),new P(-_i,sr,0)];class P_{constructor(e){this._renderer=e,this._pingPongRenderTarget=null,this._blurMaterial=F_(rr),this._equirectShader=null,this._cubemapShader=null,this._compileMaterial(this._blurMaterial)}fromScene(e,t=0,n=.1,r=100){m1=this._renderer.getRenderTarget();const s=this._allocateTargets();return this._sceneToCubeUV(e,n,r,s),t>0&&this._blur(s,0,0,t),this._applyPMREM(s),this._cleanup(s),s}fromEquirectangular(e){return this._fromTexture(e)}fromCubemap(e){return this._fromTexture(e)}compileCubemapShader(){this._cubemapShader===null&&(this._cubemapShader=Pu(),this._compileMaterial(this._cubemapShader))}compileEquirectangularShader(){this._equirectShader===null&&(this._equirectShader=Lu(),this._compileMaterial(this._equirectShader))}dispose(){this._blurMaterial.dispose(),this._cubemapShader!==null&&this._cubemapShader.dispose(),this._equirectShader!==null&&this._equirectShader.dispose();for(let e=0;e2?Vt:0,Vt,Vt),u.setRenderTarget(r),_&&u.render(v,a),u.render(e,a)}v.geometry.dispose(),v.material.dispose(),u.toneMapping=d,u.outputEncoding=f,u.autoClear=h,e.background=m}_setEncoding(e,t){this._renderer.capabilities.isWebGL2===!0&&t.format===a0&&t.type===Kn&&t.encoding===at?e.value=Jn[J0]:e.value=Jn[t.encoding]}_textureToCubeUV(e,t){const n=this._renderer,r=e.mapping===Zr||e.mapping===Eo;r?this._cubemapShader==null&&(this._cubemapShader=Pu()):this._equirectShader==null&&(this._equirectShader=Lu());const s=r?this._cubemapShader:this._equirectShader,o=new I0(Ms[0],s),a=s.uniforms;a.envMap.value=e,r||a.texelSize.value.set(1/e.image.width,1/e.image.height),this._setEncoding(a.inputEncoding,e),this._setEncoding(a.outputEncoding,t.texture),aa(t,0,0,3*Vt,2*Vt),n.setRenderTarget(t),n.render(o,p1)}_applyPMREM(e){const t=this._renderer,n=t.autoClear;t.autoClear=!1;for(let r=1;rrr&&console.warn(`sigmaRadians, ${s}, is too large and will clip, as it requested ${_} samples when the maximum is set to ${rr}`);const m=[];let p=0;for(let A=0;AWn-Ar?r-Wn+Ar:0);aa(t,x,w,3*y,2*y),l.setRenderTarget(t),l.render(h,p1)}}function C_(i){return i===void 0||i.type!==Kn?!1:i.encoding===J0||i.encoding===at||i.encoding===Qc}function R_(){const i=[],e=[],t=[];let n=Wn;for(let r=0;rWn-Ar?o=P4[r-Wn+Ar-1]:r==0&&(o=0),t.push(o);const a=1/(s-1),l=-a/2,c=1+a/2,u=[l,l,c,l,c,c,l,l,c,c,l,c],h=6,f=6,d=3,g=2,v=1,_=new Float32Array(d*f*h),m=new Float32Array(g*f*h),p=new Float32Array(v*f*h);for(let x=0;x2?0:-1,b=[w,A,0,w+2/3,A,0,w+2/3,A+1,0,w,A,0,w+2/3,A+1,0,w,A+1,0];_.set(b,d*f*x),m.set(u,g*f*x);const L=[x,x,x,x,x,x];p.set(L,v*f*x)}const y=new Fe;y.setAttribute("position",new _0(_,d)),y.setAttribute("uv",new _0(m,g)),y.setAttribute("faceIndex",new _0(p,v)),i.push(y),n>Ar&&n--}return{_lodPlanes:i,_sizeLods:e,_sigmas:t}}function Eu(i){const e=new C0(3*Vt,3*Vt,i);return e.texture.mapping=xl,e.texture.name="PMREM.cubeUv",e.scissorTest=!0,e}function aa(i,e,t,n,r){i.viewport.set(e,t,n,r),i.scissor.set(e,t,n,r)}function F_(i){const e=new Float32Array(i),t=new P(0,1,0);return new Ml({name:"SphericalGaussianBlur",defines:{n:i},uniforms:{envMap:{value:null},samples:{value:1},weights:{value:e},latitudinal:{value:!1},dTheta:{value:0},mipInt:{value:0},poleAxis:{value:t},inputEncoding:{value:Jn[J0]},outputEncoding:{value:Jn[J0]}},vertexShader:n9(),fragmentShader:` +}`,De={alphamap_fragment:Zv,alphamap_pars_fragment:Jv,alphatest_fragment:$v,alphatest_pars_fragment:ex,aomap_fragment:tx,aomap_pars_fragment:nx,begin_vertex:ix,beginnormal_vertex:rx,bsdfs:sx,bumpmap_pars_fragment:ox,clipping_planes_fragment:ax,clipping_planes_pars_fragment:lx,clipping_planes_pars_vertex:cx,clipping_planes_vertex:ux,color_fragment:hx,color_pars_fragment:fx,color_pars_vertex:dx,color_vertex:px,common:mx,cube_uv_reflection_fragment:gx,defaultnormal_vertex:vx,displacementmap_pars_vertex:xx,displacementmap_vertex:yx,emissivemap_fragment:_x,emissivemap_pars_fragment:bx,encodings_fragment:wx,encodings_pars_fragment:Mx,envmap_fragment:Sx,envmap_common_pars_fragment:Tx,envmap_pars_fragment:Ax,envmap_pars_vertex:Ex,envmap_physical_pars_fragment:zx,envmap_vertex:Lx,fog_vertex:Px,fog_pars_vertex:Cx,fog_fragment:Rx,fog_pars_fragment:Fx,gradientmap_pars_fragment:Ix,lightmap_fragment:Dx,lightmap_pars_fragment:Nx,lights_lambert_vertex:Ox,lights_pars_begin:Ux,lights_toon_fragment:Bx,lights_toon_pars_fragment:kx,lights_phong_fragment:Gx,lights_phong_pars_fragment:Hx,lights_physical_fragment:Vx,lights_physical_pars_fragment:Wx,lights_fragment_begin:Xx,lights_fragment_maps:jx,lights_fragment_end:Yx,logdepthbuf_fragment:qx,logdepthbuf_pars_fragment:Qx,logdepthbuf_pars_vertex:Kx,logdepthbuf_vertex:Zx,map_fragment:Jx,map_pars_fragment:$x,map_particle_fragment:ey,map_particle_pars_fragment:ty,metalnessmap_fragment:ny,metalnessmap_pars_fragment:iy,morphnormal_vertex:ry,morphtarget_pars_vertex:sy,morphtarget_vertex:oy,normal_fragment_begin:ay,normal_fragment_maps:ly,normal_pars_fragment:cy,normal_pars_vertex:uy,normal_vertex:hy,normalmap_pars_fragment:fy,clearcoat_normal_fragment_begin:dy,clearcoat_normal_fragment_maps:py,clearcoat_pars_fragment:my,output_fragment:gy,packing:vy,premultiplied_alpha_fragment:xy,project_vertex:yy,dithering_fragment:_y,dithering_pars_fragment:by,roughnessmap_fragment:wy,roughnessmap_pars_fragment:My,shadowmap_pars_fragment:Sy,shadowmap_pars_vertex:Ty,shadowmap_vertex:Ay,shadowmask_pars_fragment:Ey,skinbase_vertex:Ly,skinning_pars_vertex:Py,skinning_vertex:Cy,skinnormal_vertex:Ry,specularmap_fragment:Fy,specularmap_pars_fragment:Iy,tonemapping_fragment:Dy,tonemapping_pars_fragment:Ny,transmission_fragment:Oy,transmission_pars_fragment:Uy,uv_pars_fragment:zy,uv_pars_vertex:By,uv_vertex:ky,uv2_pars_fragment:Gy,uv2_pars_vertex:Hy,uv2_vertex:Vy,worldpos_vertex:Wy,background_vert:Xy,background_frag:jy,cube_vert:Yy,cube_frag:qy,depth_vert:Qy,depth_frag:Ky,distanceRGBA_vert:Zy,distanceRGBA_frag:Jy,equirect_vert:$y,equirect_frag:e_,linedashed_vert:t_,linedashed_frag:n_,meshbasic_vert:i_,meshbasic_frag:r_,meshlambert_vert:s_,meshlambert_frag:o_,meshmatcap_vert:a_,meshmatcap_frag:l_,meshnormal_vert:c_,meshnormal_frag:u_,meshphong_vert:h_,meshphong_frag:f_,meshphysical_vert:d_,meshphysical_frag:p_,meshtoon_vert:m_,meshtoon_frag:g_,points_vert:v_,points_frag:x_,shadow_vert:y_,shadow_frag:__,sprite_vert:b_,sprite_frag:w_},Se={common:{diffuse:{value:new be(16777215)},opacity:{value:1},map:{value:null},uvTransform:{value:new k0},uv2Transform:{value:new k0},alphaMap:{value:null},alphaTest:{value:0}},specularmap:{specularMap:{value:null}},envmap:{envMap:{value:null},flipEnvMap:{value:-1},reflectivity:{value:1},ior:{value:1.5},refractionRatio:{value:.98},maxMipLevel:{value:0}},aomap:{aoMap:{value:null},aoMapIntensity:{value:1}},lightmap:{lightMap:{value:null},lightMapIntensity:{value:1}},emissivemap:{emissiveMap:{value:null}},bumpmap:{bumpMap:{value:null},bumpScale:{value:1}},normalmap:{normalMap:{value:null},normalScale:{value:new ee(1,1)}},displacementmap:{displacementMap:{value:null},displacementScale:{value:1},displacementBias:{value:0}},roughnessmap:{roughnessMap:{value:null}},metalnessmap:{metalnessMap:{value:null}},gradientmap:{gradientMap:{value:null}},fog:{fogDensity:{value:25e-5},fogNear:{value:1},fogFar:{value:2e3},fogColor:{value:new be(16777215)}},lights:{ambientLightColor:{value:[]},lightProbe:{value:[]},directionalLights:{value:[],properties:{direction:{},color:{}}},directionalLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{}}},directionalShadowMap:{value:[]},directionalShadowMatrix:{value:[]},spotLights:{value:[],properties:{color:{},position:{},direction:{},distance:{},coneCos:{},penumbraCos:{},decay:{}}},spotLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{}}},spotShadowMap:{value:[]},spotShadowMatrix:{value:[]},pointLights:{value:[],properties:{color:{},position:{},decay:{},distance:{}}},pointLightShadows:{value:[],properties:{shadowBias:{},shadowNormalBias:{},shadowRadius:{},shadowMapSize:{},shadowCameraNear:{},shadowCameraFar:{}}},pointShadowMap:{value:[]},pointShadowMatrix:{value:[]},hemisphereLights:{value:[],properties:{direction:{},skyColor:{},groundColor:{}}},rectAreaLights:{value:[],properties:{color:{},position:{},width:{},height:{}}},ltc_1:{value:null},ltc_2:{value:null}},points:{diffuse:{value:new be(16777215)},opacity:{value:1},size:{value:1},scale:{value:1},map:{value:null},alphaMap:{value:null},alphaTest:{value:0},uvTransform:{value:new k0}},sprite:{diffuse:{value:new be(16777215)},opacity:{value:1},center:{value:new ee(.5,.5)},rotation:{value:0},map:{value:null},alphaMap:{value:null},alphaTest:{value:0},uvTransform:{value:new k0}}},Pt={basic:{uniforms:q0([Se.common,Se.specularmap,Se.envmap,Se.aomap,Se.lightmap,Se.fog]),vertexShader:De.meshbasic_vert,fragmentShader:De.meshbasic_frag},lambert:{uniforms:q0([Se.common,Se.specularmap,Se.envmap,Se.aomap,Se.lightmap,Se.emissivemap,Se.fog,Se.lights,{emissive:{value:new be(0)}}]),vertexShader:De.meshlambert_vert,fragmentShader:De.meshlambert_frag},phong:{uniforms:q0([Se.common,Se.specularmap,Se.envmap,Se.aomap,Se.lightmap,Se.emissivemap,Se.bumpmap,Se.normalmap,Se.displacementmap,Se.fog,Se.lights,{emissive:{value:new be(0)},specular:{value:new be(1118481)},shininess:{value:30}}]),vertexShader:De.meshphong_vert,fragmentShader:De.meshphong_frag},standard:{uniforms:q0([Se.common,Se.envmap,Se.aomap,Se.lightmap,Se.emissivemap,Se.bumpmap,Se.normalmap,Se.displacementmap,Se.roughnessmap,Se.metalnessmap,Se.fog,Se.lights,{emissive:{value:new be(0)},roughness:{value:1},metalness:{value:0},envMapIntensity:{value:1}}]),vertexShader:De.meshphysical_vert,fragmentShader:De.meshphysical_frag},toon:{uniforms:q0([Se.common,Se.aomap,Se.lightmap,Se.emissivemap,Se.bumpmap,Se.normalmap,Se.displacementmap,Se.gradientmap,Se.fog,Se.lights,{emissive:{value:new be(0)}}]),vertexShader:De.meshtoon_vert,fragmentShader:De.meshtoon_frag},matcap:{uniforms:q0([Se.common,Se.bumpmap,Se.normalmap,Se.displacementmap,Se.fog,{matcap:{value:null}}]),vertexShader:De.meshmatcap_vert,fragmentShader:De.meshmatcap_frag},points:{uniforms:q0([Se.points,Se.fog]),vertexShader:De.points_vert,fragmentShader:De.points_frag},dashed:{uniforms:q0([Se.common,Se.fog,{scale:{value:1},dashSize:{value:1},totalSize:{value:2}}]),vertexShader:De.linedashed_vert,fragmentShader:De.linedashed_frag},depth:{uniforms:q0([Se.common,Se.displacementmap]),vertexShader:De.depth_vert,fragmentShader:De.depth_frag},normal:{uniforms:q0([Se.common,Se.bumpmap,Se.normalmap,Se.displacementmap,{opacity:{value:1}}]),vertexShader:De.meshnormal_vert,fragmentShader:De.meshnormal_frag},sprite:{uniforms:q0([Se.sprite,Se.fog]),vertexShader:De.sprite_vert,fragmentShader:De.sprite_frag},background:{uniforms:{uvTransform:{value:new k0},t2D:{value:null}},vertexShader:De.background_vert,fragmentShader:De.background_frag},cube:{uniforms:q0([Se.envmap,{opacity:{value:1}}]),vertexShader:De.cube_vert,fragmentShader:De.cube_frag},equirect:{uniforms:{tEquirect:{value:null}},vertexShader:De.equirect_vert,fragmentShader:De.equirect_frag},distanceRGBA:{uniforms:q0([Se.common,Se.displacementmap,{referencePosition:{value:new P},nearDistance:{value:1},farDistance:{value:1e3}}]),vertexShader:De.distanceRGBA_vert,fragmentShader:De.distanceRGBA_frag},shadow:{uniforms:q0([Se.lights,Se.fog,{color:{value:new be(0)},opacity:{value:1}}]),vertexShader:De.shadow_vert,fragmentShader:De.shadow_frag}};Pt.physical={uniforms:q0([Pt.standard.uniforms,{clearcoat:{value:0},clearcoatMap:{value:null},clearcoatRoughness:{value:0},clearcoatRoughnessMap:{value:null},clearcoatNormalScale:{value:new ee(1,1)},clearcoatNormalMap:{value:null},sheen:{value:0},sheenColor:{value:new be(0)},sheenColorMap:{value:null},sheenRoughness:{value:0},sheenRoughnessMap:{value:null},transmission:{value:0},transmissionMap:{value:null},transmissionSamplerSize:{value:new ee},transmissionSamplerMap:{value:null},thickness:{value:0},thicknessMap:{value:null},attenuationDistance:{value:0},attenuationColor:{value:new be(0)},specularIntensity:{value:0},specularIntensityMap:{value:null},specularColor:{value:new be(1,1,1)},specularColorMap:{value:null}}]),vertexShader:De.meshphysical_vert,fragmentShader:De.meshphysical_frag};function M_(i,e,t,n,r){const s=new be(0);let o=0,a,l,c=null,u=0,h=null;function f(g,v){let _=!1,m=v.isScene===!0?v.background:null;m&&m.isTexture&&(m=e.get(m));const p=i.xr,y=p.getSession&&p.getSession();y&&y.environmentBlendMode==="additive"&&(m=null),m===null?d(s,o):m&&m.isColor&&(d(m,1),_=!0),(i.autoClear||_)&&i.clear(i.autoClearColor,i.autoClearDepth,i.autoClearStencil),m&&(m.isCubeTexture||m.mapping===yl)?(l===void 0&&(l=new I0(new ho(1,1,1),new u0({name:"BackgroundCubeMaterial",uniforms:Ur(Pt.cube.uniforms),vertexShader:Pt.cube.vertexShader,fragmentShader:Pt.cube.fragmentShader,side:L0,depthTest:!1,depthWrite:!1,fog:!1})),l.geometry.deleteAttribute("normal"),l.geometry.deleteAttribute("uv"),l.onBeforeRender=function(x,w,A){this.matrixWorld.copyPosition(A.matrixWorld)},Object.defineProperty(l.material,"envMap",{get:function(){return this.uniforms.envMap.value}}),n.update(l)),l.material.uniforms.envMap.value=m,l.material.uniforms.flipEnvMap.value=m.isCubeTexture&&m.isRenderTargetTexture===!1?-1:1,(c!==m||u!==m.version||h!==i.toneMapping)&&(l.material.needsUpdate=!0,c=m,u=m.version,h=i.toneMapping),g.unshift(l,l.geometry,l.material,0,0,null)):m&&m.isTexture&&(a===void 0&&(a=new I0(new t9(2,2),new u0({name:"BackgroundMaterial",uniforms:Ur(Pt.background.uniforms),vertexShader:Pt.background.vertexShader,fragmentShader:Pt.background.fragmentShader,side:Nr,depthTest:!1,depthWrite:!1,fog:!1})),a.geometry.deleteAttribute("normal"),Object.defineProperty(a.material,"map",{get:function(){return this.uniforms.t2D.value}}),n.update(a)),a.material.uniforms.t2D.value=m,m.matrixAutoUpdate===!0&&m.updateMatrix(),a.material.uniforms.uvTransform.value.copy(m.matrix),(c!==m||u!==m.version||h!==i.toneMapping)&&(a.material.needsUpdate=!0,c=m,u=m.version,h=i.toneMapping),g.unshift(a,a.geometry,a.material,0,0,null))}function d(g,v){t.buffers.color.setClear(g.r,g.g,g.b,v,r)}return{getClearColor:function(){return s},setClearColor:function(g,v=1){s.set(g),o=v,d(s,o)},getClearAlpha:function(){return o},setClearAlpha:function(g){o=g,d(s,o)},render:f}}function S_(i,e,t,n){const r=i.getParameter(34921),s=n.isWebGL2?null:e.get("OES_vertex_array_object"),o=n.isWebGL2||s!==null,a={},l=v(null);let c=l;function u(O,G,j,N,k){let K=!1;if(o){const le=g(N,j,G);c!==le&&(c=le,f(c.object)),K=_(N,k),K&&m(N,k)}else{const le=G.wireframe===!0;(c.geometry!==N.id||c.program!==j.id||c.wireframe!==le)&&(c.geometry=N.id,c.program=j.id,c.wireframe=le,K=!0)}O.isInstancedMesh===!0&&(K=!0),k!==null&&t.update(k,34963),K&&(b(O,G,j,N),k!==null&&i.bindBuffer(34963,t.get(k).buffer))}function h(){return n.isWebGL2?i.createVertexArray():s.createVertexArrayOES()}function f(O){return n.isWebGL2?i.bindVertexArray(O):s.bindVertexArrayOES(O)}function d(O){return n.isWebGL2?i.deleteVertexArray(O):s.deleteVertexArrayOES(O)}function g(O,G,j){const N=j.wireframe===!0;let k=a[O.id];k===void 0&&(k={},a[O.id]=k);let K=k[G.id];K===void 0&&(K={},k[G.id]=K);let le=K[N];return le===void 0&&(le=v(h()),K[N]=le),le}function v(O){const G=[],j=[],N=[];for(let k=0;k=0){let ye=k[ve];if(ye===void 0&&(ve==="instanceMatrix"&&O.instanceMatrix&&(ye=O.instanceMatrix),ve==="instanceColor"&&O.instanceColor&&(ye=O.instanceColor)),ye!==void 0){const $=ye.normalized,se=ye.itemSize,me=t.get(ye);if(me===void 0)continue;const Z=me.buffer,V=me.type,te=me.bytesPerElement;if(ye.isInterleavedBufferAttribute){const Q=ye.data,re=Q.stride,we=ye.offset;if(Q&&Q.isInstancedInterleavedBuffer){for(let M=0;M0&&i.getShaderPrecisionFormat(35632,36338).precision>0)return"highp";b="mediump"}return b==="mediump"&&i.getShaderPrecisionFormat(35633,36337).precision>0&&i.getShaderPrecisionFormat(35632,36337).precision>0?"mediump":"lowp"}const o=typeof WebGL2RenderingContext<"u"&&i instanceof WebGL2RenderingContext||typeof WebGL2ComputeRenderingContext<"u"&&i instanceof WebGL2ComputeRenderingContext;let a=t.precision!==void 0?t.precision:"highp";const l=s(a);l!==a&&(console.warn("THREE.WebGLRenderer:",a,"not supported, using",l,"instead."),a=l);const c=o||e.has("WEBGL_draw_buffers"),u=t.logarithmicDepthBuffer===!0,h=i.getParameter(34930),f=i.getParameter(35660),d=i.getParameter(3379),g=i.getParameter(34076),v=i.getParameter(34921),_=i.getParameter(36347),m=i.getParameter(36348),p=i.getParameter(36349),y=f>0,x=o||e.has("OES_texture_float"),w=y&&x,A=o?i.getParameter(36183):0;return{isWebGL2:o,drawBuffers:c,getMaxAnisotropy:r,getMaxPrecision:s,precision:a,logarithmicDepthBuffer:u,maxTextures:h,maxVertexTextures:f,maxTextureSize:d,maxCubemapSize:g,maxAttributes:v,maxVertexUniforms:_,maxVaryings:m,maxFragmentUniforms:p,vertexTextures:y,floatFragmentTextures:x,floatVertexTextures:w,maxSamples:A}}function E_(i){const e=this;let t=null,n=0,r=!1,s=!1;const o=new Xt,a=new k0,l={value:null,needsUpdate:!1};this.uniform=l,this.numPlanes=0,this.numIntersection=0,this.init=function(h,f,d){const g=h.length!==0||f||n!==0||r;return r=f,t=u(h,d,0),n=h.length,g},this.beginShadows=function(){s=!0,u(null)},this.endShadows=function(){s=!1,c()},this.setState=function(h,f,d){const g=h.clippingPlanes,v=h.clipIntersection,_=h.clipShadows,m=i.get(h);if(!r||g===null||g.length===0||s&&!_)s?u(null):c();else{const p=s?0:n,y=p*4;let x=m.clippingState||null;l.value=x,x=u(g,f,y,d);for(let w=0;w!==y;++w)x[w]=t[w];m.clippingState=x,this.numIntersection=v?this.numPlanes:0,this.numPlanes+=p}};function c(){l.value!==t&&(l.value=t,l.needsUpdate=n>0),e.numPlanes=n,e.numIntersection=0}function u(h,f,d,g){const v=h!==null?h.length:0;let _=null;if(v!==0){if(_=l.value,g!==!0||_===null){const m=d+v*4,p=f.matrixWorldInverse;a.getNormalMatrix(p),(_===null||_.length0){const c=i.getRenderTarget(),u=new e9(l.height/2);return u.fromEquirectangularTexture(i,o),e.set(o,u),i.setRenderTarget(c),o.addEventListener("dispose",r),t(u.texture,o.mapping)}else return null}}return o}function r(o){const a=o.target;a.removeEventListener("dispose",r);const l=e.get(a);l!==void 0&&(e.delete(a),l.dispose())}function s(){e=new WeakMap}return{get:n,dispose:s}}let ii=class extends $c{constructor(e=-1,t=1,n=1,r=-1,s=.1,o=2e3){super(),this.type="OrthographicCamera",this.zoom=1,this.view=null,this.left=e,this.right=t,this.top=n,this.bottom=r,this.near=s,this.far=o,this.updateProjectionMatrix()}copy(e,t){return super.copy(e,t),this.left=e.left,this.right=e.right,this.top=e.top,this.bottom=e.bottom,this.near=e.near,this.far=e.far,this.zoom=e.zoom,this.view=e.view===null?null:Object.assign({},e.view),this}setViewOffset(e,t,n,r,s,o){this.view===null&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1}),this.view.enabled=!0,this.view.fullWidth=e,this.view.fullHeight=t,this.view.offsetX=n,this.view.offsetY=r,this.view.width=s,this.view.height=o,this.updateProjectionMatrix()}clearViewOffset(){this.view!==null&&(this.view.enabled=!1),this.updateProjectionMatrix()}updateProjectionMatrix(){const e=(this.right-this.left)/(2*this.zoom),t=(this.top-this.bottom)/(2*this.zoom),n=(this.right+this.left)/2,r=(this.top+this.bottom)/2;let s=n-e,o=n+e,a=r+t,l=r-t;if(this.view!==null&&this.view.enabled){const c=(this.right-this.left)/this.view.fullWidth/this.zoom,u=(this.top-this.bottom)/this.view.fullHeight/this.zoom;s+=c*this.view.offsetX,o=s+c*this.view.width,a-=u*this.view.offsetY,l=a-u*this.view.height}this.projectionMatrix.makeOrthographic(s,o,a,l,this.near,this.far),this.projectionMatrixInverse.copy(this.projectionMatrix).invert()}toJSON(e){const t=super.toJSON(e);return t.object.zoom=this.zoom,t.object.left=this.left,t.object.right=this.right,t.object.top=this.top,t.object.bottom=this.bottom,t.object.near=this.near,t.object.far=this.far,this.view!==null&&(t.object.view=Object.assign({},this.view)),t}};ii.prototype.isOrthographicCamera=!0;class Sl extends u0{constructor(e){super(e),this.type="RawShaderMaterial"}}Sl.prototype.isRawShaderMaterial=!0;const Er=4,Wn=8,Vt=Math.pow(2,Wn),P4=[.125,.215,.35,.446,.526,.582],C4=Wn-Er+1+P4.length,rr=20,Jn={[J0]:0,[at]:1,[Kc]:2,[m4]:3,[g4]:4,[v4]:5,[Qc]:6},m1=new ii,{_lodPlanes:Ss,_sizeLods:Su,_sigmas:oa}=R_(),Tu=new be;let g1=null;const _i=(1+Math.sqrt(5))/2,sr=1/_i,Au=[new P(1,1,1),new P(-1,1,1),new P(1,1,-1),new P(-1,1,-1),new P(0,_i,sr),new P(0,_i,-sr),new P(sr,0,_i),new P(-sr,0,_i),new P(_i,sr,0),new P(-_i,sr,0)];class P_{constructor(e){this._renderer=e,this._pingPongRenderTarget=null,this._blurMaterial=F_(rr),this._equirectShader=null,this._cubemapShader=null,this._compileMaterial(this._blurMaterial)}fromScene(e,t=0,n=.1,r=100){g1=this._renderer.getRenderTarget();const s=this._allocateTargets();return this._sceneToCubeUV(e,n,r,s),t>0&&this._blur(s,0,0,t),this._applyPMREM(s),this._cleanup(s),s}fromEquirectangular(e){return this._fromTexture(e)}fromCubemap(e){return this._fromTexture(e)}compileCubemapShader(){this._cubemapShader===null&&(this._cubemapShader=Pu(),this._compileMaterial(this._cubemapShader))}compileEquirectangularShader(){this._equirectShader===null&&(this._equirectShader=Lu(),this._compileMaterial(this._equirectShader))}dispose(){this._blurMaterial.dispose(),this._cubemapShader!==null&&this._cubemapShader.dispose(),this._equirectShader!==null&&this._equirectShader.dispose();for(let e=0;e2?Vt:0,Vt,Vt),u.setRenderTarget(r),_&&u.render(v,a),u.render(e,a)}v.geometry.dispose(),v.material.dispose(),u.toneMapping=d,u.outputEncoding=f,u.autoClear=h,e.background=m}_setEncoding(e,t){this._renderer.capabilities.isWebGL2===!0&&t.format===a0&&t.type===Zn&&t.encoding===at?e.value=Jn[J0]:e.value=Jn[t.encoding]}_textureToCubeUV(e,t){const n=this._renderer,r=e.mapping===Zr||e.mapping===Eo;r?this._cubemapShader==null&&(this._cubemapShader=Pu()):this._equirectShader==null&&(this._equirectShader=Lu());const s=r?this._cubemapShader:this._equirectShader,o=new I0(Ss[0],s),a=s.uniforms;a.envMap.value=e,r||a.texelSize.value.set(1/e.image.width,1/e.image.height),this._setEncoding(a.inputEncoding,e),this._setEncoding(a.outputEncoding,t.texture),aa(t,0,0,3*Vt,2*Vt),n.setRenderTarget(t),n.render(o,m1)}_applyPMREM(e){const t=this._renderer,n=t.autoClear;t.autoClear=!1;for(let r=1;rrr&&console.warn(`sigmaRadians, ${s}, is too large and will clip, as it requested ${_} samples when the maximum is set to ${rr}`);const m=[];let p=0;for(let A=0;AWn-Er?r-Wn+Er:0);aa(t,x,w,3*y,2*y),l.setRenderTarget(t),l.render(h,m1)}}function C_(i){return i===void 0||i.type!==Zn?!1:i.encoding===J0||i.encoding===at||i.encoding===Qc}function R_(){const i=[],e=[],t=[];let n=Wn;for(let r=0;rWn-Er?o=P4[r-Wn+Er-1]:r==0&&(o=0),t.push(o);const a=1/(s-1),l=-a/2,c=1+a/2,u=[l,l,c,l,c,c,l,l,c,c,l,c],h=6,f=6,d=3,g=2,v=1,_=new Float32Array(d*f*h),m=new Float32Array(g*f*h),p=new Float32Array(v*f*h);for(let x=0;x2?0:-1,b=[w,A,0,w+2/3,A,0,w+2/3,A+1,0,w,A,0,w+2/3,A+1,0,w,A+1,0];_.set(b,d*f*x),m.set(u,g*f*x);const L=[x,x,x,x,x,x];p.set(L,v*f*x)}const y=new Fe;y.setAttribute("position",new _0(_,d)),y.setAttribute("uv",new _0(m,g)),y.setAttribute("faceIndex",new _0(p,v)),i.push(y),n>Er&&n--}return{_lodPlanes:i,_sizeLods:e,_sigmas:t}}function Eu(i){const e=new C0(3*Vt,3*Vt,i);return e.texture.mapping=yl,e.texture.name="PMREM.cubeUv",e.scissorTest=!0,e}function aa(i,e,t,n,r){i.viewport.set(e,t,n,r),i.scissor.set(e,t,n,r)}function F_(i){const e=new Float32Array(i),t=new P(0,1,0);return new Sl({name:"SphericalGaussianBlur",defines:{n:i},uniforms:{envMap:{value:null},samples:{value:1},weights:{value:e},latitudinal:{value:!1},dTheta:{value:0},mipInt:{value:0},poleAxis:{value:t},inputEncoding:{value:Jn[J0]},outputEncoding:{value:Jn[J0]}},vertexShader:n9(),fragmentShader:` precision mediump float; precision mediump int; @@ -2911,7 +2911,7 @@ void main() { gl_FragColor = linearToOutputTexel( gl_FragColor ); } - `,blending:V0,depthTest:!1,depthWrite:!1})}function Lu(){const i=new ee(1,1);return new Ml({name:"EquirectangularToCubeUV",uniforms:{envMap:{value:null},texelSize:{value:i},inputEncoding:{value:Jn[J0]},outputEncoding:{value:Jn[J0]}},vertexShader:n9(),fragmentShader:` + `,blending:W0,depthTest:!1,depthWrite:!1})}function Lu(){const i=new ee(1,1);return new Sl({name:"EquirectangularToCubeUV",uniforms:{envMap:{value:null},texelSize:{value:i},inputEncoding:{value:Jn[J0]},outputEncoding:{value:Jn[J0]}},vertexShader:n9(),fragmentShader:` precision mediump float; precision mediump int; @@ -2949,7 +2949,7 @@ void main() { gl_FragColor = linearToOutputTexel( gl_FragColor ); } - `,blending:V0,depthTest:!1,depthWrite:!1})}function Pu(){return new Ml({name:"CubemapToCubeUV",uniforms:{envMap:{value:null},inputEncoding:{value:Jn[J0]},outputEncoding:{value:Jn[J0]}},vertexShader:n9(),fragmentShader:` + `,blending:W0,depthTest:!1,depthWrite:!1})}function Pu(){return new Sl({name:"CubemapToCubeUV",uniforms:{envMap:{value:null},inputEncoding:{value:Jn[J0]},outputEncoding:{value:Jn[J0]}},vertexShader:n9(),fragmentShader:` precision mediump float; precision mediump int; @@ -2967,7 +2967,7 @@ void main() { gl_FragColor = linearToOutputTexel( gl_FragColor ); } - `,blending:V0,depthTest:!1,depthWrite:!1})}function n9(){return` + `,blending:W0,depthTest:!1,depthWrite:!1})}function n9(){return` precision mediump float; precision mediump int; @@ -3104,28 +3104,28 @@ void main() { return inputTexelToLinear( color ); } - `}function I_(i){let e=new WeakMap,t=null;function n(a){if(a&&a.isTexture&&a.isRenderTargetTexture===!1){const l=a.mapping,c=l===Va||l===Z1,u=l===Zr||l===Eo;if(c||u){if(e.has(a))return e.get(a).texture;{const h=a.image;if(c&&h&&h.height>0||u&&h&&r(h)){const f=i.getRenderTarget();t===null&&(t=new P_(i));const d=c?t.fromEquirectangular(a):t.fromCubemap(a);return e.set(a,d),i.setRenderTarget(f),a.addEventListener("dispose",s),d.texture}else return null}}}return a}function r(a){let l=0;const c=6;for(let u=0;u65535?T4:Jc)(f,1);_.version=v;const m=s.get(h);m&&e.remove(m),s.set(h,_)}function u(h){const f=s.get(h);if(f){const d=h.index;d!==null&&f.versione.maxTextureSize&&(L=Math.ceil(b/e.maxTextureSize),b=e.maxTextureSize);const B=new Float32Array(b*L*4*g),I=new r9(B,b,L,g);I.format=a0,I.type=gt;const C=A*4;for(let Y=0;Y0)return i;const r=e*t;let s=Ru[r];if(s===void 0&&(s=new Float32Array(r),Ru[r]=s),e!==0){n.toArray(s,0);for(let o=1,a=0;o!==e;++o)a+=t,i[o].toArray(s,a)}return s}function it(i,e){if(i.length!==e.length)return!1;for(let t=0,n=i.length;t0||u&&h&&r(h)){const f=i.getRenderTarget();t===null&&(t=new P_(i));const d=c?t.fromEquirectangular(a):t.fromCubemap(a);return e.set(a,d),i.setRenderTarget(f),a.addEventListener("dispose",s),d.texture}else return null}}}return a}function r(a){let l=0;const c=6;for(let u=0;u65535?T4:Jc)(f,1);_.version=v;const m=s.get(h);m&&e.remove(m),s.set(h,_)}function u(h){const f=s.get(h);if(f){const d=h.index;d!==null&&f.versione.maxTextureSize&&(L=Math.ceil(b/e.maxTextureSize),b=e.maxTextureSize);const B=new Float32Array(b*L*4*g),I=new r9(B,b,L,g);I.format=a0,I.type=gt;const C=A*4;for(let Y=0;Y0)return i;const r=e*t;let s=Ru[r];if(s===void 0&&(s=new Float32Array(r),Ru[r]=s),e!==0){n.toArray(s,0);for(let o=1,a=0;o!==e;++o)a+=t,i[o].toArray(s,a)}return s}function it(i,e){if(i.length!==e.length)return!1;for(let t=0,n=i.length;t/gm;function nc(i){return i.replace(Ub,zb)}function zb(i,e){const t=De[e];if(t===void 0)throw new Error("Can not resolve #include <"+e+">");return nc(t)}const Bb=/#pragma unroll_loop[\s]+?for \( int i \= (\d+)\; i < (\d+)\; i \+\+ \) \{([\s\S]+?)(?=\})\}/g,kb=/#pragma unroll_loop_start\s+for\s*\(\s*int\s+i\s*=\s*(\d+)\s*;\s*i\s*<\s*(\d+)\s*;\s*i\s*\+\+\s*\)\s*{([\s\S]+?)}\s+#pragma unroll_loop_end/g;function Gu(i){return i.replace(kb,z4).replace(Bb,Gb)}function Gb(i,e,t,n){return console.warn("WebGLProgram: #pragma unroll_loop shader syntax is deprecated. Please use #pragma unroll_loop_start syntax instead."),z4(i,e,t,n)}function z4(i,e,t,n){let r="";for(let s=parseInt(e);s/gm;function ic(i){return i.replace(Ub,zb)}function zb(i,e){const t=De[e];if(t===void 0)throw new Error("Can not resolve #include <"+e+">");return ic(t)}const Bb=/#pragma unroll_loop[\s]+?for \( int i \= (\d+)\; i < (\d+)\; i \+\+ \) \{([\s\S]+?)(?=\})\}/g,kb=/#pragma unroll_loop_start\s+for\s*\(\s*int\s+i\s*=\s*(\d+)\s*;\s*i\s*<\s*(\d+)\s*;\s*i\s*\+\+\s*\)\s*{([\s\S]+?)}\s+#pragma unroll_loop_end/g;function Gu(i){return i.replace(kb,z4).replace(Bb,Gb)}function Gb(i,e,t,n){return console.warn("WebGLProgram: #pragma unroll_loop shader syntax is deprecated. Please use #pragma unroll_loop_start syntax instead."),z4(i,e,t,n)}function z4(i,e,t,n){let r="";for(let s=parseInt(e);s0?i.gammaFactor:1,d=t.isWebGL2?"":Db(t),g=Nb(s),v=r.createProgram();let _,m,p=t.glslVersion?"#version "+t.glslVersion+` -`:"";t.isRawShaderMaterial?(_=[g].filter(Us).join(` +#define LOW_PRECISION`),e}function Hb(i){let e="SHADOWMAP_TYPE_BASIC";return i.shadowMapType===s4?e="SHADOWMAP_TYPE_PCF":i.shadowMapType===Qm?e="SHADOWMAP_TYPE_PCF_SOFT":i.shadowMapType===Us&&(e="SHADOWMAP_TYPE_VSM"),e}function Vb(i){let e="ENVMAP_TYPE_CUBE";if(i.envMap)switch(i.envMapMode){case Zr:case Eo:e="ENVMAP_TYPE_CUBE";break;case yl:case Yc:e="ENVMAP_TYPE_CUBE_UV";break}return e}function Wb(i){let e="ENVMAP_MODE_REFLECTION";if(i.envMap)switch(i.envMapMode){case Eo:case Yc:e="ENVMAP_MODE_REFRACTION";break}return e}function Xb(i){let e="ENVMAP_BLENDING_NONE";if(i.envMap)switch(i.combine){case xl:e="ENVMAP_BLENDING_MULTIPLY";break;case hg:e="ENVMAP_BLENDING_MIX";break;case fg:e="ENVMAP_BLENDING_ADD";break}return e}function jb(i,e,t,n){const r=i.getContext(),s=t.defines;let o=t.vertexShader,a=t.fragmentShader;const l=Hb(t),c=Vb(t),u=Wb(t),h=Xb(t),f=i.gammaFactor>0?i.gammaFactor:1,d=t.isWebGL2?"":Db(t),g=Nb(s),v=r.createProgram();let _,m,p=t.glslVersion?"#version "+t.glslVersion+` +`:"";t.isRawShaderMaterial?(_=[g].filter(zs).join(` `),_.length>0&&(_+=` -`),m=[d,g].filter(Us).join(` +`),m=[d,g].filter(zs).join(` `),m.length>0&&(m+=` `)):(_=[Hu(t),"#define SHADER_NAME "+t.shaderName,g,t.instancing?"#define USE_INSTANCING":"",t.instancingColor?"#define USE_INSTANCING_COLOR":"",t.supportsVertexTextures?"#define VERTEX_TEXTURES":"","#define GAMMA_FACTOR "+f,"#define MAX_BONES "+t.maxBones,t.useFog&&t.fog?"#define USE_FOG":"",t.useFog&&t.fogExp2?"#define FOG_EXP2":"",t.map?"#define USE_MAP":"",t.envMap?"#define USE_ENVMAP":"",t.envMap?"#define "+u:"",t.lightMap?"#define USE_LIGHTMAP":"",t.aoMap?"#define USE_AOMAP":"",t.emissiveMap?"#define USE_EMISSIVEMAP":"",t.bumpMap?"#define USE_BUMPMAP":"",t.normalMap?"#define USE_NORMALMAP":"",t.normalMap&&t.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",t.normalMap&&t.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",t.clearcoatMap?"#define USE_CLEARCOATMAP":"",t.clearcoatRoughnessMap?"#define USE_CLEARCOAT_ROUGHNESSMAP":"",t.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",t.displacementMap&&t.supportsVertexTextures?"#define USE_DISPLACEMENTMAP":"",t.specularMap?"#define USE_SPECULARMAP":"",t.specularIntensityMap?"#define USE_SPECULARINTENSITYMAP":"",t.specularColorMap?"#define USE_SPECULARCOLORMAP":"",t.roughnessMap?"#define USE_ROUGHNESSMAP":"",t.metalnessMap?"#define USE_METALNESSMAP":"",t.alphaMap?"#define USE_ALPHAMAP":"",t.transmission?"#define USE_TRANSMISSION":"",t.transmissionMap?"#define USE_TRANSMISSIONMAP":"",t.thicknessMap?"#define USE_THICKNESSMAP":"",t.sheenColorMap?"#define USE_SHEENCOLORMAP":"",t.sheenRoughnessMap?"#define USE_SHEENROUGHNESSMAP":"",t.vertexTangents?"#define USE_TANGENT":"",t.vertexColors?"#define USE_COLOR":"",t.vertexAlphas?"#define USE_COLOR_ALPHA":"",t.vertexUvs?"#define USE_UV":"",t.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",t.flatShading?"#define FLAT_SHADED":"",t.skinning?"#define USE_SKINNING":"",t.useVertexTexture?"#define BONE_TEXTURE":"",t.morphTargets?"#define USE_MORPHTARGETS":"",t.morphNormals&&t.flatShading===!1?"#define USE_MORPHNORMALS":"",t.morphTargets&&t.isWebGL2?"#define MORPHTARGETS_TEXTURE":"",t.morphTargets&&t.isWebGL2?"#define MORPHTARGETS_COUNT "+t.morphTargetsCount:"",t.doubleSided?"#define DOUBLE_SIDED":"",t.flipSided?"#define FLIP_SIDED":"",t.shadowMapEnabled?"#define USE_SHADOWMAP":"",t.shadowMapEnabled?"#define "+l:"",t.sizeAttenuation?"#define USE_SIZEATTENUATION":"",t.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",t.logarithmicDepthBuffer&&t.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"","uniform mat4 modelMatrix;","uniform mat4 modelViewMatrix;","uniform mat4 projectionMatrix;","uniform mat4 viewMatrix;","uniform mat3 normalMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;","#ifdef USE_INSTANCING"," attribute mat4 instanceMatrix;","#endif","#ifdef USE_INSTANCING_COLOR"," attribute vec3 instanceColor;","#endif","attribute vec3 position;","attribute vec3 normal;","attribute vec2 uv;","#ifdef USE_TANGENT"," attribute vec4 tangent;","#endif","#if defined( USE_COLOR_ALPHA )"," attribute vec4 color;","#elif defined( USE_COLOR )"," attribute vec3 color;","#endif","#if ( defined( USE_MORPHTARGETS ) && ! defined( MORPHTARGETS_TEXTURE ) )"," attribute vec3 morphTarget0;"," attribute vec3 morphTarget1;"," attribute vec3 morphTarget2;"," attribute vec3 morphTarget3;"," #ifdef USE_MORPHNORMALS"," attribute vec3 morphNormal0;"," attribute vec3 morphNormal1;"," attribute vec3 morphNormal2;"," attribute vec3 morphNormal3;"," #else"," attribute vec3 morphTarget4;"," attribute vec3 morphTarget5;"," attribute vec3 morphTarget6;"," attribute vec3 morphTarget7;"," #endif","#endif","#ifdef USE_SKINNING"," attribute vec4 skinIndex;"," attribute vec4 skinWeight;","#endif",` -`].filter(Us).join(` +`].filter(zs).join(` `),m=[d,Hu(t),"#define SHADER_NAME "+t.shaderName,g,"#define GAMMA_FACTOR "+f,t.useFog&&t.fog?"#define USE_FOG":"",t.useFog&&t.fogExp2?"#define FOG_EXP2":"",t.map?"#define USE_MAP":"",t.matcap?"#define USE_MATCAP":"",t.envMap?"#define USE_ENVMAP":"",t.envMap?"#define "+c:"",t.envMap?"#define "+u:"",t.envMap?"#define "+h:"",t.lightMap?"#define USE_LIGHTMAP":"",t.aoMap?"#define USE_AOMAP":"",t.emissiveMap?"#define USE_EMISSIVEMAP":"",t.bumpMap?"#define USE_BUMPMAP":"",t.normalMap?"#define USE_NORMALMAP":"",t.normalMap&&t.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",t.normalMap&&t.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",t.clearcoat?"#define USE_CLEARCOAT":"",t.clearcoatMap?"#define USE_CLEARCOATMAP":"",t.clearcoatRoughnessMap?"#define USE_CLEARCOAT_ROUGHNESSMAP":"",t.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",t.specularMap?"#define USE_SPECULARMAP":"",t.specularIntensityMap?"#define USE_SPECULARINTENSITYMAP":"",t.specularColorMap?"#define USE_SPECULARCOLORMAP":"",t.roughnessMap?"#define USE_ROUGHNESSMAP":"",t.metalnessMap?"#define USE_METALNESSMAP":"",t.alphaMap?"#define USE_ALPHAMAP":"",t.alphaTest?"#define USE_ALPHATEST":"",t.sheen?"#define USE_SHEEN":"",t.sheenColorMap?"#define USE_SHEENCOLORMAP":"",t.sheenRoughnessMap?"#define USE_SHEENROUGHNESSMAP":"",t.transmission?"#define USE_TRANSMISSION":"",t.transmissionMap?"#define USE_TRANSMISSIONMAP":"",t.thicknessMap?"#define USE_THICKNESSMAP":"",t.vertexTangents?"#define USE_TANGENT":"",t.vertexColors||t.instancingColor?"#define USE_COLOR":"",t.vertexAlphas?"#define USE_COLOR_ALPHA":"",t.vertexUvs?"#define USE_UV":"",t.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",t.gradientMap?"#define USE_GRADIENTMAP":"",t.flatShading?"#define FLAT_SHADED":"",t.doubleSided?"#define DOUBLE_SIDED":"",t.flipSided?"#define FLIP_SIDED":"",t.shadowMapEnabled?"#define USE_SHADOWMAP":"",t.shadowMapEnabled?"#define "+l:"",t.premultipliedAlpha?"#define PREMULTIPLIED_ALPHA":"",t.physicallyCorrectLights?"#define PHYSICALLY_CORRECT_LIGHTS":"",t.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",t.logarithmicDepthBuffer&&t.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"",(t.extensionShaderTextureLOD||t.envMap)&&t.rendererExtensionShaderTextureLod?"#define TEXTURE_LOD_EXT":"","uniform mat4 viewMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;",t.toneMapping!==Pi?"#define TONE_MAPPING":"",t.toneMapping!==Pi?De.tonemapping_pars_fragment:"",t.toneMapping!==Pi?Ib("toneMapping",t.toneMapping):"",t.dithering?"#define DITHERING":"",t.format===Yt?"#define OPAQUE":"",De.encodings_pars_fragment,t.map?xi("mapTexelToLinear",t.mapEncoding):"",t.matcap?xi("matcapTexelToLinear",t.matcapEncoding):"",t.envMap?xi("envMapTexelToLinear",t.envMapEncoding):"",t.emissiveMap?xi("emissiveMapTexelToLinear",t.emissiveMapEncoding):"",t.specularColorMap?xi("specularColorMapTexelToLinear",t.specularColorMapEncoding):"",t.sheenColorMap?xi("sheenColorMapTexelToLinear",t.sheenColorMapEncoding):"",t.lightMap?xi("lightMapTexelToLinear",t.lightMapEncoding):"",Fb("linearToOutputTexel",t.outputEncoding),t.depthPacking?"#define DEPTH_PACKING "+t.depthPacking:"",` -`].filter(Us).join(` -`)),o=nc(o),o=Bu(o,t),o=ku(o,t),a=nc(a),a=Bu(a,t),a=ku(a,t),o=Gu(o),a=Gu(a),t.isWebGL2&&t.isRawShaderMaterial!==!0&&(p=`#version 300 es +`].filter(zs).join(` +`)),o=ic(o),o=Bu(o,t),o=ku(o,t),a=ic(a),a=Bu(a,t),a=ku(a,t),o=Gu(o),a=Gu(a),t.isWebGL2&&t.isRawShaderMaterial!==!0&&(p=`#version 300 es `,_=["precision mediump sampler2DArray;","#define attribute in","#define varying out","#define texture2D texture"].join(` `)+` `+_,m=["#define varying in",t.glslVersion===hu?"":"out highp vec4 pc_fragColor;",t.glslVersion===hu?"":"#define gl_FragColor pc_fragColor","#define gl_FragDepthEXT gl_FragDepth","#define texture2D texture","#define textureCube texture","#define texture2DProj textureProj","#define texture2DLodEXT textureLod","#define texture2DProjLodEXT textureProjLod","#define textureCubeLodEXT textureLod","#define texture2DGradEXT textureGrad","#define texture2DProjGradEXT textureProjGrad","#define textureCubeGradEXT textureGrad"].join(` @@ -3134,7 +3134,7 @@ precision `+i.precision+" int;";return i.precision==="highp"?e+=` Program Info Log: `+B+` `+G+` -`+j)}else B!==""?console.warn("THREE.WebGLProgram: Program Info Log:",B):(I===""||C==="")&&(O=!1);O&&(this.diagnostics={runnable:Y,programLog:B,vertexShader:{log:I,prefix:_},fragmentShader:{log:C,prefix:m}})}r.deleteShader(w),r.deleteShader(A);let b;this.getUniforms=function(){return b===void 0&&(b=new Xn(r,v)),b};let L;return this.getAttributes=function(){return L===void 0&&(L=Ob(r,v)),L},this.destroy=function(){n.releaseStatesOfProgram(this),r.deleteProgram(v),this.program=void 0},this.name=t.shaderName,this.id=Cb++,this.cacheKey=e,this.usedTimes=1,this.program=v,this.vertexShader=w,this.fragmentShader=A,this}function Yb(i,e,t,n,r,s,o){const a=[],l=r.isWebGL2,c=r.logarithmicDepthBuffer,u=r.floatVertexTextures,h=r.maxVertexUniforms,f=r.vertexTextures;let d=r.precision;const g={MeshDepthMaterial:"depth",MeshDistanceMaterial:"distanceRGBA",MeshNormalMaterial:"normal",MeshBasicMaterial:"basic",MeshLambertMaterial:"lambert",MeshPhongMaterial:"phong",MeshToonMaterial:"toon",MeshStandardMaterial:"physical",MeshPhysicalMaterial:"physical",MeshMatcapMaterial:"matcap",LineBasicMaterial:"basic",LineDashedMaterial:"dashed",PointsMaterial:"points",ShadowMaterial:"shadow",SpriteMaterial:"sprite"},v=["precision","isWebGL2","supportsVertexTextures","outputEncoding","instancing","instancingColor","map","mapEncoding","matcap","matcapEncoding","envMap","envMapMode","envMapEncoding","envMapCubeUV","lightMap","lightMapEncoding","aoMap","emissiveMap","emissiveMapEncoding","bumpMap","normalMap","objectSpaceNormalMap","tangentSpaceNormalMap","clearcoat","clearcoatMap","clearcoatRoughnessMap","clearcoatNormalMap","displacementMap","specularMap",,"roughnessMap","metalnessMap","gradientMap","alphaMap","alphaTest","combine","vertexColors","vertexAlphas","vertexTangents","vertexUvs","uvsVertexOnly","fog","useFog","fogExp2","flatShading","sizeAttenuation","logarithmicDepthBuffer","skinning","maxBones","useVertexTexture","morphTargets","morphNormals","morphTargetsCount","premultipliedAlpha","numDirLights","numPointLights","numSpotLights","numHemiLights","numRectAreaLights","numDirLightShadows","numPointLightShadows","numSpotLightShadows","shadowMapEnabled","shadowMapType","toneMapping","physicallyCorrectLights","doubleSided","flipSided","numClippingPlanes","numClipIntersection","depthPacking","dithering","format","specularIntensityMap","specularColorMap","specularColorMapEncoding","transmission","transmissionMap","thicknessMap","sheen","sheenColorMap","sheenColorMapEncoding","sheenRoughnessMap"];function _(b){const B=b.skeleton.bones;if(u)return 1024;{const C=Math.floor((h-20)/4),Y=Math.min(C,B.length);return Y0,ce=b.clearcoat>0;return{isWebGL2:l,shaderID:j,shaderName:b.type,vertexShader:k,fragmentShader:Z,defines:b.defines,isRawShaderMaterial:b.isRawShaderMaterial===!0,glslVersion:b.glslVersion,precision:d,instancing:C.isInstancedMesh===!0,instancingColor:C.isInstancedMesh===!0&&C.instanceColor!==null,supportsVertexTextures:f,outputEncoding:le!==null?m(le.texture):i.outputEncoding,map:!!b.map,mapEncoding:m(b.map),matcap:!!b.matcap,matcapEncoding:m(b.matcap),envMap:!!G,envMapMode:G&&G.mapping,envMapEncoding:m(G),envMapCubeUV:!!G&&(G.mapping===xl||G.mapping===Yc),lightMap:!!b.lightMap,lightMapEncoding:m(b.lightMap),aoMap:!!b.aoMap,emissiveMap:!!b.emissiveMap,emissiveMapEncoding:m(b.emissiveMap),bumpMap:!!b.bumpMap,normalMap:!!b.normalMap,objectSpaceNormalMap:b.normalMapType===vv,tangentSpaceNormalMap:b.normalMapType===Oi,clearcoat:ce,clearcoatMap:ce&&!!b.clearcoatMap,clearcoatRoughnessMap:ce&&!!b.clearcoatRoughnessMap,clearcoatNormalMap:ce&&!!b.clearcoatNormalMap,displacementMap:!!b.displacementMap,roughnessMap:!!b.roughnessMap,metalnessMap:!!b.metalnessMap,specularMap:!!b.specularMap,specularIntensityMap:!!b.specularIntensityMap,specularColorMap:!!b.specularColorMap,specularColorMapEncoding:m(b.specularColorMap),alphaMap:!!b.alphaMap,alphaTest:ve,gradientMap:!!b.gradientMap,sheen:b.sheen>0,sheenColorMap:!!b.sheenColorMap,sheenColorMapEncoding:m(b.sheenColorMap),sheenRoughnessMap:!!b.sheenRoughnessMap,transmission:b.transmission>0,transmissionMap:!!b.transmissionMap,thicknessMap:!!b.thicknessMap,combine:b.combine,vertexTangents:!!b.normalMap&&!!C.geometry&&!!C.geometry.attributes.tangent,vertexColors:b.vertexColors,vertexAlphas:b.vertexColors===!0&&!!C.geometry&&!!C.geometry.attributes.color&&C.geometry.attributes.color.itemSize===4,vertexUvs:!!b.map||!!b.bumpMap||!!b.normalMap||!!b.specularMap||!!b.alphaMap||!!b.emissiveMap||!!b.roughnessMap||!!b.metalnessMap||!!b.clearcoatMap||!!b.clearcoatRoughnessMap||!!b.clearcoatNormalMap||!!b.displacementMap||!!b.transmissionMap||!!b.thicknessMap||!!b.specularIntensityMap||!!b.specularColorMap||!!b.sheenColorMap||b.sheenRoughnessMap,uvsVertexOnly:!(b.map||b.bumpMap||b.normalMap||b.specularMap||b.alphaMap||b.emissiveMap||b.roughnessMap||b.metalnessMap||b.clearcoatNormalMap||b.transmission>0||b.transmissionMap||b.thicknessMap||b.specularIntensityMap||b.specularColorMap||!!b.sheen>0||b.sheenColorMap||b.sheenRoughnessMap)&&!!b.displacementMap,fog:!!Y,useFog:b.fog,fogExp2:Y&&Y.isFogExp2,flatShading:!!b.flatShading,sizeAttenuation:b.sizeAttenuation,logarithmicDepthBuffer:c,skinning:C.isSkinnedMesh===!0&&N>0,maxBones:N,useVertexTexture:u,morphTargets:!!C.geometry&&!!C.geometry.morphAttributes.position,morphNormals:!!C.geometry&&!!C.geometry.morphAttributes.normal,morphTargetsCount:C.geometry&&C.geometry.morphAttributes.position?C.geometry.morphAttributes.position.length:0,numDirLights:L.directional.length,numPointLights:L.point.length,numSpotLights:L.spot.length,numRectAreaLights:L.rectArea.length,numHemiLights:L.hemi.length,numDirLightShadows:L.directionalShadowMap.length,numPointLightShadows:L.pointShadowMap.length,numSpotLightShadows:L.spotShadowMap.length,numClippingPlanes:o.numPlanes,numClipIntersection:o.numIntersection,format:b.format,dithering:b.dithering,shadowMapEnabled:i.shadowMap.enabled&&B.length>0,shadowMapType:i.shadowMap.type,toneMapping:b.toneMapped?i.toneMapping:Pi,physicallyCorrectLights:i.physicallyCorrectLights,premultipliedAlpha:b.premultipliedAlpha,doubleSided:b.side===Zn,flipSided:b.side===L0,depthPacking:b.depthPacking!==void 0?b.depthPacking:!1,index0AttributeName:b.index0AttributeName,extensionDerivatives:b.extensions&&b.extensions.derivatives,extensionFragDepth:b.extensions&&b.extensions.fragDepth,extensionDrawBuffers:b.extensions&&b.extensions.drawBuffers,extensionShaderTextureLOD:b.extensions&&b.extensions.shaderTextureLOD,rendererExtensionFragDepth:l||n.has("EXT_frag_depth"),rendererExtensionDrawBuffers:l||n.has("WEBGL_draw_buffers"),rendererExtensionShaderTextureLod:l||n.has("EXT_shader_texture_lod"),customProgramCacheKey:b.customProgramCacheKey()}}function y(b){const L=[];if(b.shaderID?L.push(b.shaderID):(L.push(fu(b.fragmentShader)),L.push(fu(b.vertexShader))),b.defines!==void 0)for(const B in b.defines)L.push(B),L.push(b.defines[B]);if(b.isRawShaderMaterial===!1){for(let B=0;B0?r.push(y):v.transparent===!0?s.push(y):n.push(y)}function u(d,g,v,_,m,p){const y=l(d,g,v,_,m,p);v.transmission>0?r.unshift(y):v.transparent===!0?s.unshift(y):n.unshift(y)}function h(d,g){n.length>1&&n.sort(d||Qb),r.length>1&&r.sort(g||Vu),s.length>1&&s.sort(g||Vu)}function f(){for(let d=t,g=e.length;d=e.get(r).length?(o=new Wu(i),e.get(r).push(o)):o=e.get(r)[s],o}function n(){e=new WeakMap}return{get:t,dispose:n}}function Kb(){const i={};return{get:function(e){if(i[e.id]!==void 0)return i[e.id];let t;switch(e.type){case"DirectionalLight":t={direction:new P,color:new be};break;case"SpotLight":t={position:new P,direction:new P,color:new be,distance:0,coneCos:0,penumbraCos:0,decay:0};break;case"PointLight":t={position:new P,color:new be,distance:0,decay:0};break;case"HemisphereLight":t={direction:new P,skyColor:new be,groundColor:new be};break;case"RectAreaLight":t={color:new be,position:new P,halfWidth:new P,halfHeight:new P};break}return i[e.id]=t,t}}}function Jb(){const i={};return{get:function(e){if(i[e.id]!==void 0)return i[e.id];let t;switch(e.type){case"DirectionalLight":t={shadowBias:0,shadowNormalBias:0,shadowRadius:1,shadowMapSize:new ee};break;case"SpotLight":t={shadowBias:0,shadowNormalBias:0,shadowRadius:1,shadowMapSize:new ee};break;case"PointLight":t={shadowBias:0,shadowNormalBias:0,shadowRadius:1,shadowMapSize:new ee,shadowCameraNear:1,shadowCameraFar:1e3};break}return i[e.id]=t,t}}}let $b=0;function ew(i,e){return(e.castShadow?1:0)-(i.castShadow?1:0)}function tw(i,e){const t=new Kb,n=Jb(),r={version:0,hash:{directionalLength:-1,pointLength:-1,spotLength:-1,rectAreaLength:-1,hemiLength:-1,numDirectionalShadows:-1,numPointShadows:-1,numSpotShadows:-1},ambient:[0,0,0],probe:[],directional:[],directionalShadow:[],directionalShadowMap:[],directionalShadowMatrix:[],spot:[],spotShadow:[],spotShadowMap:[],spotShadowMatrix:[],rectArea:[],rectAreaLTC1:null,rectAreaLTC2:null,point:[],pointShadow:[],pointShadowMap:[],pointShadowMatrix:[],hemi:[]};for(let u=0;u<9;u++)r.probe.push(new P);const s=new P,o=new Me,a=new Me;function l(u,h){let f=0,d=0,g=0;for(let B=0;B<9;B++)r.probe[B].set(0,0,0);let v=0,_=0,m=0,p=0,y=0,x=0,w=0,A=0;u.sort(ew);const b=h!==!0?Math.PI:1;for(let B=0,I=u.length;B0&&(e.isWebGL2||i.has("OES_texture_float_linear")===!0?(r.rectAreaLTC1=Se.LTC_FLOAT_1,r.rectAreaLTC2=Se.LTC_FLOAT_2):i.has("OES_texture_half_float_linear")===!0?(r.rectAreaLTC1=Se.LTC_HALF_1,r.rectAreaLTC2=Se.LTC_HALF_2):console.error("THREE.WebGLRenderer: Unable to use RectAreaLight. Missing WebGL extensions.")),r.ambient[0]=f,r.ambient[1]=d,r.ambient[2]=g;const L=r.hash;(L.directionalLength!==v||L.pointLength!==_||L.spotLength!==m||L.rectAreaLength!==p||L.hemiLength!==y||L.numDirectionalShadows!==x||L.numPointShadows!==w||L.numSpotShadows!==A)&&(r.directional.length=v,r.spot.length=m,r.rectArea.length=p,r.point.length=_,r.hemi.length=y,r.directionalShadow.length=x,r.directionalShadowMap.length=x,r.pointShadow.length=w,r.pointShadowMap.length=w,r.spotShadow.length=A,r.spotShadowMap.length=A,r.directionalShadowMatrix.length=x,r.pointShadowMatrix.length=w,r.spotShadowMatrix.length=A,L.directionalLength=v,L.pointLength=_,L.spotLength=m,L.rectAreaLength=p,L.hemiLength=y,L.numDirectionalShadows=x,L.numPointShadows=w,L.numSpotShadows=A,r.version=$b++)}function c(u,h){let f=0,d=0,g=0,v=0,_=0;const m=h.matrixWorldInverse;for(let p=0,y=u.length;p=t.get(s).length?(a=new Xu(i,e),t.get(s).push(a)):a=t.get(s)[o],a}function r(){t=new WeakMap}return{get:n,dispose:r}}class s9 extends D0{constructor(e){super(),this.type="MeshDepthMaterial",this.depthPacking=gv,this.map=null,this.alphaMap=null,this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.setValues(e)}copy(e){return super.copy(e),this.depthPacking=e.depthPacking,this.map=e.map,this.alphaMap=e.alphaMap,this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this}}s9.prototype.isMeshDepthMaterial=!0;class B4 extends D0{constructor(e){super(),this.type="MeshDistanceMaterial",this.referencePosition=new P,this.nearDistance=1,this.farDistance=1e3,this.map=null,this.alphaMap=null,this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.fog=!1,this.setValues(e)}copy(e){return super.copy(e),this.referencePosition.copy(e.referencePosition),this.nearDistance=e.nearDistance,this.farDistance=e.farDistance,this.map=e.map,this.alphaMap=e.alphaMap,this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this}}B4.prototype.isMeshDistanceMaterial=!0;const iw=`void main() { +`+j)}else B!==""?console.warn("THREE.WebGLProgram: Program Info Log:",B):(I===""||C==="")&&(O=!1);O&&(this.diagnostics={runnable:Y,programLog:B,vertexShader:{log:I,prefix:_},fragmentShader:{log:C,prefix:m}})}r.deleteShader(w),r.deleteShader(A);let b;this.getUniforms=function(){return b===void 0&&(b=new Xn(r,v)),b};let L;return this.getAttributes=function(){return L===void 0&&(L=Ob(r,v)),L},this.destroy=function(){n.releaseStatesOfProgram(this),r.deleteProgram(v),this.program=void 0},this.name=t.shaderName,this.id=Cb++,this.cacheKey=e,this.usedTimes=1,this.program=v,this.vertexShader=w,this.fragmentShader=A,this}function Yb(i,e,t,n,r,s,o){const a=[],l=r.isWebGL2,c=r.logarithmicDepthBuffer,u=r.floatVertexTextures,h=r.maxVertexUniforms,f=r.vertexTextures;let d=r.precision;const g={MeshDepthMaterial:"depth",MeshDistanceMaterial:"distanceRGBA",MeshNormalMaterial:"normal",MeshBasicMaterial:"basic",MeshLambertMaterial:"lambert",MeshPhongMaterial:"phong",MeshToonMaterial:"toon",MeshStandardMaterial:"physical",MeshPhysicalMaterial:"physical",MeshMatcapMaterial:"matcap",LineBasicMaterial:"basic",LineDashedMaterial:"dashed",PointsMaterial:"points",ShadowMaterial:"shadow",SpriteMaterial:"sprite"},v=["precision","isWebGL2","supportsVertexTextures","outputEncoding","instancing","instancingColor","map","mapEncoding","matcap","matcapEncoding","envMap","envMapMode","envMapEncoding","envMapCubeUV","lightMap","lightMapEncoding","aoMap","emissiveMap","emissiveMapEncoding","bumpMap","normalMap","objectSpaceNormalMap","tangentSpaceNormalMap","clearcoat","clearcoatMap","clearcoatRoughnessMap","clearcoatNormalMap","displacementMap","specularMap",,"roughnessMap","metalnessMap","gradientMap","alphaMap","alphaTest","combine","vertexColors","vertexAlphas","vertexTangents","vertexUvs","uvsVertexOnly","fog","useFog","fogExp2","flatShading","sizeAttenuation","logarithmicDepthBuffer","skinning","maxBones","useVertexTexture","morphTargets","morphNormals","morphTargetsCount","premultipliedAlpha","numDirLights","numPointLights","numSpotLights","numHemiLights","numRectAreaLights","numDirLightShadows","numPointLightShadows","numSpotLightShadows","shadowMapEnabled","shadowMapType","toneMapping","physicallyCorrectLights","doubleSided","flipSided","numClippingPlanes","numClipIntersection","depthPacking","dithering","format","specularIntensityMap","specularColorMap","specularColorMapEncoding","transmission","transmissionMap","thicknessMap","sheen","sheenColorMap","sheenColorMapEncoding","sheenRoughnessMap"];function _(b){const B=b.skeleton.bones;if(u)return 1024;{const C=Math.floor((h-20)/4),Y=Math.min(C,B.length);return Y0,ce=b.clearcoat>0;return{isWebGL2:l,shaderID:j,shaderName:b.type,vertexShader:k,fragmentShader:K,defines:b.defines,isRawShaderMaterial:b.isRawShaderMaterial===!0,glslVersion:b.glslVersion,precision:d,instancing:C.isInstancedMesh===!0,instancingColor:C.isInstancedMesh===!0&&C.instanceColor!==null,supportsVertexTextures:f,outputEncoding:le!==null?m(le.texture):i.outputEncoding,map:!!b.map,mapEncoding:m(b.map),matcap:!!b.matcap,matcapEncoding:m(b.matcap),envMap:!!G,envMapMode:G&&G.mapping,envMapEncoding:m(G),envMapCubeUV:!!G&&(G.mapping===yl||G.mapping===Yc),lightMap:!!b.lightMap,lightMapEncoding:m(b.lightMap),aoMap:!!b.aoMap,emissiveMap:!!b.emissiveMap,emissiveMapEncoding:m(b.emissiveMap),bumpMap:!!b.bumpMap,normalMap:!!b.normalMap,objectSpaceNormalMap:b.normalMapType===vv,tangentSpaceNormalMap:b.normalMapType===Oi,clearcoat:ce,clearcoatMap:ce&&!!b.clearcoatMap,clearcoatRoughnessMap:ce&&!!b.clearcoatRoughnessMap,clearcoatNormalMap:ce&&!!b.clearcoatNormalMap,displacementMap:!!b.displacementMap,roughnessMap:!!b.roughnessMap,metalnessMap:!!b.metalnessMap,specularMap:!!b.specularMap,specularIntensityMap:!!b.specularIntensityMap,specularColorMap:!!b.specularColorMap,specularColorMapEncoding:m(b.specularColorMap),alphaMap:!!b.alphaMap,alphaTest:ve,gradientMap:!!b.gradientMap,sheen:b.sheen>0,sheenColorMap:!!b.sheenColorMap,sheenColorMapEncoding:m(b.sheenColorMap),sheenRoughnessMap:!!b.sheenRoughnessMap,transmission:b.transmission>0,transmissionMap:!!b.transmissionMap,thicknessMap:!!b.thicknessMap,combine:b.combine,vertexTangents:!!b.normalMap&&!!C.geometry&&!!C.geometry.attributes.tangent,vertexColors:b.vertexColors,vertexAlphas:b.vertexColors===!0&&!!C.geometry&&!!C.geometry.attributes.color&&C.geometry.attributes.color.itemSize===4,vertexUvs:!!b.map||!!b.bumpMap||!!b.normalMap||!!b.specularMap||!!b.alphaMap||!!b.emissiveMap||!!b.roughnessMap||!!b.metalnessMap||!!b.clearcoatMap||!!b.clearcoatRoughnessMap||!!b.clearcoatNormalMap||!!b.displacementMap||!!b.transmissionMap||!!b.thicknessMap||!!b.specularIntensityMap||!!b.specularColorMap||!!b.sheenColorMap||b.sheenRoughnessMap,uvsVertexOnly:!(b.map||b.bumpMap||b.normalMap||b.specularMap||b.alphaMap||b.emissiveMap||b.roughnessMap||b.metalnessMap||b.clearcoatNormalMap||b.transmission>0||b.transmissionMap||b.thicknessMap||b.specularIntensityMap||b.specularColorMap||!!b.sheen>0||b.sheenColorMap||b.sheenRoughnessMap)&&!!b.displacementMap,fog:!!Y,useFog:b.fog,fogExp2:Y&&Y.isFogExp2,flatShading:!!b.flatShading,sizeAttenuation:b.sizeAttenuation,logarithmicDepthBuffer:c,skinning:C.isSkinnedMesh===!0&&N>0,maxBones:N,useVertexTexture:u,morphTargets:!!C.geometry&&!!C.geometry.morphAttributes.position,morphNormals:!!C.geometry&&!!C.geometry.morphAttributes.normal,morphTargetsCount:C.geometry&&C.geometry.morphAttributes.position?C.geometry.morphAttributes.position.length:0,numDirLights:L.directional.length,numPointLights:L.point.length,numSpotLights:L.spot.length,numRectAreaLights:L.rectArea.length,numHemiLights:L.hemi.length,numDirLightShadows:L.directionalShadowMap.length,numPointLightShadows:L.pointShadowMap.length,numSpotLightShadows:L.spotShadowMap.length,numClippingPlanes:o.numPlanes,numClipIntersection:o.numIntersection,format:b.format,dithering:b.dithering,shadowMapEnabled:i.shadowMap.enabled&&B.length>0,shadowMapType:i.shadowMap.type,toneMapping:b.toneMapped?i.toneMapping:Pi,physicallyCorrectLights:i.physicallyCorrectLights,premultipliedAlpha:b.premultipliedAlpha,doubleSided:b.side===Kn,flipSided:b.side===L0,depthPacking:b.depthPacking!==void 0?b.depthPacking:!1,index0AttributeName:b.index0AttributeName,extensionDerivatives:b.extensions&&b.extensions.derivatives,extensionFragDepth:b.extensions&&b.extensions.fragDepth,extensionDrawBuffers:b.extensions&&b.extensions.drawBuffers,extensionShaderTextureLOD:b.extensions&&b.extensions.shaderTextureLOD,rendererExtensionFragDepth:l||n.has("EXT_frag_depth"),rendererExtensionDrawBuffers:l||n.has("WEBGL_draw_buffers"),rendererExtensionShaderTextureLod:l||n.has("EXT_shader_texture_lod"),customProgramCacheKey:b.customProgramCacheKey()}}function y(b){const L=[];if(b.shaderID?L.push(b.shaderID):(L.push(fu(b.fragmentShader)),L.push(fu(b.vertexShader))),b.defines!==void 0)for(const B in b.defines)L.push(B),L.push(b.defines[B]);if(b.isRawShaderMaterial===!1){for(let B=0;B0?r.push(y):v.transparent===!0?s.push(y):n.push(y)}function u(d,g,v,_,m,p){const y=l(d,g,v,_,m,p);v.transmission>0?r.unshift(y):v.transparent===!0?s.unshift(y):n.unshift(y)}function h(d,g){n.length>1&&n.sort(d||Qb),r.length>1&&r.sort(g||Vu),s.length>1&&s.sort(g||Vu)}function f(){for(let d=t,g=e.length;d=e.get(r).length?(o=new Wu(i),e.get(r).push(o)):o=e.get(r)[s],o}function n(){e=new WeakMap}return{get:t,dispose:n}}function Zb(){const i={};return{get:function(e){if(i[e.id]!==void 0)return i[e.id];let t;switch(e.type){case"DirectionalLight":t={direction:new P,color:new be};break;case"SpotLight":t={position:new P,direction:new P,color:new be,distance:0,coneCos:0,penumbraCos:0,decay:0};break;case"PointLight":t={position:new P,color:new be,distance:0,decay:0};break;case"HemisphereLight":t={direction:new P,skyColor:new be,groundColor:new be};break;case"RectAreaLight":t={color:new be,position:new P,halfWidth:new P,halfHeight:new P};break}return i[e.id]=t,t}}}function Jb(){const i={};return{get:function(e){if(i[e.id]!==void 0)return i[e.id];let t;switch(e.type){case"DirectionalLight":t={shadowBias:0,shadowNormalBias:0,shadowRadius:1,shadowMapSize:new ee};break;case"SpotLight":t={shadowBias:0,shadowNormalBias:0,shadowRadius:1,shadowMapSize:new ee};break;case"PointLight":t={shadowBias:0,shadowNormalBias:0,shadowRadius:1,shadowMapSize:new ee,shadowCameraNear:1,shadowCameraFar:1e3};break}return i[e.id]=t,t}}}let $b=0;function ew(i,e){return(e.castShadow?1:0)-(i.castShadow?1:0)}function tw(i,e){const t=new Zb,n=Jb(),r={version:0,hash:{directionalLength:-1,pointLength:-1,spotLength:-1,rectAreaLength:-1,hemiLength:-1,numDirectionalShadows:-1,numPointShadows:-1,numSpotShadows:-1},ambient:[0,0,0],probe:[],directional:[],directionalShadow:[],directionalShadowMap:[],directionalShadowMatrix:[],spot:[],spotShadow:[],spotShadowMap:[],spotShadowMatrix:[],rectArea:[],rectAreaLTC1:null,rectAreaLTC2:null,point:[],pointShadow:[],pointShadowMap:[],pointShadowMatrix:[],hemi:[]};for(let u=0;u<9;u++)r.probe.push(new P);const s=new P,o=new Me,a=new Me;function l(u,h){let f=0,d=0,g=0;for(let B=0;B<9;B++)r.probe[B].set(0,0,0);let v=0,_=0,m=0,p=0,y=0,x=0,w=0,A=0;u.sort(ew);const b=h!==!0?Math.PI:1;for(let B=0,I=u.length;B0&&(e.isWebGL2||i.has("OES_texture_float_linear")===!0?(r.rectAreaLTC1=Se.LTC_FLOAT_1,r.rectAreaLTC2=Se.LTC_FLOAT_2):i.has("OES_texture_half_float_linear")===!0?(r.rectAreaLTC1=Se.LTC_HALF_1,r.rectAreaLTC2=Se.LTC_HALF_2):console.error("THREE.WebGLRenderer: Unable to use RectAreaLight. Missing WebGL extensions.")),r.ambient[0]=f,r.ambient[1]=d,r.ambient[2]=g;const L=r.hash;(L.directionalLength!==v||L.pointLength!==_||L.spotLength!==m||L.rectAreaLength!==p||L.hemiLength!==y||L.numDirectionalShadows!==x||L.numPointShadows!==w||L.numSpotShadows!==A)&&(r.directional.length=v,r.spot.length=m,r.rectArea.length=p,r.point.length=_,r.hemi.length=y,r.directionalShadow.length=x,r.directionalShadowMap.length=x,r.pointShadow.length=w,r.pointShadowMap.length=w,r.spotShadow.length=A,r.spotShadowMap.length=A,r.directionalShadowMatrix.length=x,r.pointShadowMatrix.length=w,r.spotShadowMatrix.length=A,L.directionalLength=v,L.pointLength=_,L.spotLength=m,L.rectAreaLength=p,L.hemiLength=y,L.numDirectionalShadows=x,L.numPointShadows=w,L.numSpotShadows=A,r.version=$b++)}function c(u,h){let f=0,d=0,g=0,v=0,_=0;const m=h.matrixWorldInverse;for(let p=0,y=u.length;p=t.get(s).length?(a=new Xu(i,e),t.get(s).push(a)):a=t.get(s)[o],a}function r(){t=new WeakMap}return{get:n,dispose:r}}class s9 extends D0{constructor(e){super(),this.type="MeshDepthMaterial",this.depthPacking=gv,this.map=null,this.alphaMap=null,this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.setValues(e)}copy(e){return super.copy(e),this.depthPacking=e.depthPacking,this.map=e.map,this.alphaMap=e.alphaMap,this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this}}s9.prototype.isMeshDepthMaterial=!0;class B4 extends D0{constructor(e){super(),this.type="MeshDistanceMaterial",this.referencePosition=new P,this.nearDistance=1,this.farDistance=1e3,this.map=null,this.alphaMap=null,this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.fog=!1,this.setValues(e)}copy(e){return super.copy(e),this.referencePosition.copy(e.referencePosition),this.nearDistance=e.nearDistance,this.farDistance=e.farDistance,this.map=e.map,this.alphaMap=e.alphaMap,this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this}}B4.prototype.isMeshDistanceMaterial=!0;const iw=`void main() { gl_Position = vec4( position, 1.0 ); }`,rw=`uniform sampler2D shadow_pass; uniform vec2 resolution; @@ -3162,18 +3162,18 @@ void main() { squared_mean = squared_mean / samples; float std_dev = sqrt( squared_mean - mean * mean ); gl_FragColor = pack2HalfToRGBA( vec2( mean, std_dev ) ); -}`;function k4(i,e,t){let n=new wl;const r=new ee,s=new ee,o=new $e,a=new s9({depthPacking:x4}),l=new B4,c={},u=t.maxTextureSize,h={0:L0,1:Dr,2:Zn},f=new u0({defines:{VSM_SAMPLES:8},uniforms:{shadow_pass:{value:null},resolution:{value:new ee},radius:{value:4}},vertexShader:iw,fragmentShader:rw}),d=f.clone();d.defines.HORIZONTAL_PASS=1;const g=new Fe;g.setAttribute("position",new _0(new Float32Array([-1,-1,.5,3,-1,.5,-1,3,.5]),3));const v=new I0(g,f),_=this;this.enabled=!1,this.autoUpdate=!0,this.needsUpdate=!1,this.type=s4,this.render=function(x,w,A){if(_.enabled===!1||_.autoUpdate===!1&&_.needsUpdate===!1||x.length===0)return;const b=i.getRenderTarget(),L=i.getActiveCubeFace(),B=i.getActiveMipmapLevel(),I=i.state;I.setBlending(V0),I.buffers.color.setClear(1,1,1,1),I.buffers.depth.setTest(!0),I.setScissorTest(!1);for(let C=0,Y=x.length;Cu||r.y>u)&&(r.x>u&&(s.x=Math.floor(u/j.x),r.x=s.x*j.x,G.mapSize.x=s.x),r.y>u&&(s.y=Math.floor(u/j.y),r.y=s.y*j.y,G.mapSize.y=s.y)),G.map===null&&!G.isPointLightShadow&&this.type===Os){const k={minFilter:s0,magFilter:s0,format:a0};G.map=new C0(r.x,r.y,k),G.map.texture.name=O.name+".shadowMap",G.mapPass=new C0(r.x,r.y,k),G.camera.updateProjectionMatrix()}if(G.map===null){const k={minFilter:r0,magFilter:r0,format:a0};G.map=new C0(r.x,r.y,k),G.map.texture.name=O.name+".shadowMap",G.camera.updateProjectionMatrix()}i.setRenderTarget(G.map),i.clear();const N=G.getViewportCount();for(let k=0;k0){const O=C.uuid,G=A.uuid;let j=c[O];j===void 0&&(j={},c[O]=j);let N=j[G];N===void 0&&(N=C.clone(),j[G]=N),C=N}return C.visible=A.visible,C.wireframe=A.wireframe,I===Os?C.side=A.shadowSide!==null?A.shadowSide:A.side:C.side=A.shadowSide!==null?A.shadowSide:h[A.side],C.alphaMap=A.alphaMap,C.alphaTest=A.alphaTest,C.clipShadows=A.clipShadows,C.clippingPlanes=A.clippingPlanes,C.clipIntersection=A.clipIntersection,C.displacementMap=A.displacementMap,C.displacementScale=A.displacementScale,C.displacementBias=A.displacementBias,C.wireframeLinewidth=A.wireframeLinewidth,C.linewidth=A.linewidth,b.isPointLight===!0&&C.isMeshDistanceMaterial===!0&&(C.referencePosition.setFromMatrixPosition(b.matrixWorld),C.nearDistance=L,C.farDistance=B),C}function y(x,w,A,b,L){if(x.visible===!1)return;if(x.layers.test(w.layers)&&(x.isMesh||x.isLine||x.isPoints)&&(x.castShadow||x.receiveShadow&&L===Os)&&(!x.frustumCulled||n.intersectsObject(x))){x.modelViewMatrix.multiplyMatrices(A.matrixWorldInverse,x.matrixWorld);const C=e.update(x),Y=x.material;if(Array.isArray(Y)){const O=C.groups;for(let G=0,j=O.length;G=1):j.indexOf("OpenGL ES")!==-1&&(G=parseFloat(/^OpenGL ES (\d)/.exec(j)[1]),O=G>=2);let N=null,k={};const Z=i.getParameter(3088),le=i.getParameter(2978),ve=new $e().fromArray(Z),ce=new $e().fromArray(le);function ye(z,fe,ne){const Te=new Uint8Array(4),D=i.createTexture();i.bindTexture(z,D),i.texParameteri(z,10241,9728),i.texParameteri(z,10240,9728);for(let _e=0;_eq||T.height>q)&&(H=q/Math.max(T.width,T.height)),H<1||S===!0)if(typeof HTMLImageElement<"u"&&T instanceof HTMLImageElement||typeof HTMLCanvasElement<"u"&&T instanceof HTMLCanvasElement||typeof ImageBitmap<"u"&&T instanceof ImageBitmap){const oe=S?_4:Math.floor,ue=oe(H*T.width),he=oe(H*T.height);d===void 0&&(d=v(ue,he));const xe=U?v(ue,he):d;return xe.width=ue,xe.height=he,xe.getContext("2d").drawImage(T,0,0,ue,he),console.warn("THREE.WebGLRenderer: Texture has been resized from ("+T.width+"x"+T.height+") to ("+ue+"x"+he+")."),xe}else return"data"in T&&console.warn("THREE.WebGLRenderer: Image in DataTexture is too big ("+T.width+"x"+T.height+")."),T;return T}function m(T){return $1(T.width)&&$1(T.height)}function p(T){return a?!1:T.wrapS!==m0||T.wrapT!==m0||T.minFilter!==r0&&T.minFilter!==s0}function y(T,S){return T.generateMipmaps&&S&&T.minFilter!==r0&&T.minFilter!==s0}function x(T,S,U,q,H=1){i.generateMipmap(T);const oe=n.get(S);oe.__maxMipLevel=Math.log2(Math.max(U,q,H))}function w(T,S,U,q){if(a===!1)return S;if(T!==null){if(i[T]!==void 0)return i[T];console.warn("THREE.WebGLRenderer: Attempt to use non-existing WebGL internal format '"+T+"'")}let H=S;return S===6403&&(U===5126&&(H=33326),U===5131&&(H=33325),U===5121&&(H=33321)),S===6407&&(U===5126&&(H=34837),U===5131&&(H=34843),U===5121&&(H=32849)),S===6408&&(U===5126&&(H=34836),U===5131&&(H=34842),U===5121&&(H=q===at?35907:32856)),(H===33325||H===33326||H===34842||H===34836)&&e.get("EXT_color_buffer_float"),H}function A(T){return T===r0||T===K1||T===J1?9728:9729}function b(T){const S=T.target;S.removeEventListener("dispose",b),B(S),S.isVideoTexture&&f.delete(S),o.memory.textures--}function L(T){const S=T.target;S.removeEventListener("dispose",L),I(S)}function B(T){const S=n.get(T);S.__webglInit!==void 0&&(i.deleteTexture(S.__webglTexture),n.remove(T))}function I(T){const S=T.texture,U=n.get(T),q=n.get(S);if(T){if(q.__webglTexture!==void 0&&(i.deleteTexture(q.__webglTexture),o.memory.textures--),T.depthTexture&&T.depthTexture.dispose(),T.isWebGLCubeRenderTarget)for(let H=0;H<6;H++)i.deleteFramebuffer(U.__webglFramebuffer[H]),U.__webglDepthbuffer&&i.deleteRenderbuffer(U.__webglDepthbuffer[H]);else i.deleteFramebuffer(U.__webglFramebuffer),U.__webglDepthbuffer&&i.deleteRenderbuffer(U.__webglDepthbuffer),U.__webglMultisampledFramebuffer&&i.deleteFramebuffer(U.__webglMultisampledFramebuffer),U.__webglColorRenderbuffer&&i.deleteRenderbuffer(U.__webglColorRenderbuffer),U.__webglDepthRenderbuffer&&i.deleteRenderbuffer(U.__webglDepthRenderbuffer);if(T.isWebGLMultipleRenderTargets)for(let H=0,oe=S.length;H=l&&console.warn("THREE.WebGLTextures: Trying to use "+T+" texture units while this GPU supports only "+l),C+=1,T}function G(T,S){const U=n.get(T);if(T.isVideoTexture&&M(T),T.version>0&&U.__version!==T.version){const q=T.image;if(q===void 0)console.warn("THREE.WebGLRenderer: Texture marked for update but image is undefined");else if(q.complete===!1)console.warn("THREE.WebGLRenderer: Texture marked for update but image is incomplete");else{ye(U,T,S);return}}t.activeTexture(33984+S),t.bindTexture(3553,U.__webglTexture)}function j(T,S){const U=n.get(T);if(T.version>0&&U.__version!==T.version){ye(U,T,S);return}t.activeTexture(33984+S),t.bindTexture(35866,U.__webglTexture)}function N(T,S){const U=n.get(T);if(T.version>0&&U.__version!==T.version){ye(U,T,S);return}t.activeTexture(33984+S),t.bindTexture(32879,U.__webglTexture)}function k(T,S){const U=n.get(T);if(T.version>0&&U.__version!==T.version){$(U,T,S);return}t.activeTexture(33984+S),t.bindTexture(34067,U.__webglTexture)}const Z={[Qt]:10497,[m0]:33071,[Wa]:33648},le={[r0]:9728,[K1]:9984,[J1]:9986,[s0]:9729,[f4]:9985,[Ni]:9987};function ve(T,S,U){if(U?(i.texParameteri(T,10242,Z[S.wrapS]),i.texParameteri(T,10243,Z[S.wrapT]),(T===32879||T===35866)&&i.texParameteri(T,32882,Z[S.wrapR]),i.texParameteri(T,10240,le[S.magFilter]),i.texParameteri(T,10241,le[S.minFilter])):(i.texParameteri(T,10242,33071),i.texParameteri(T,10243,33071),(T===32879||T===35866)&&i.texParameteri(T,32882,33071),(S.wrapS!==m0||S.wrapT!==m0)&&console.warn("THREE.WebGLRenderer: Texture is not power of two. Texture.wrapS and Texture.wrapT should be set to THREE.ClampToEdgeWrapping."),i.texParameteri(T,10240,A(S.magFilter)),i.texParameteri(T,10241,A(S.minFilter)),S.minFilter!==r0&&S.minFilter!==s0&&console.warn("THREE.WebGLRenderer: Texture is not power of two. Texture.minFilter should be set to THREE.NearestFilter or THREE.LinearFilter.")),e.has("EXT_texture_filter_anisotropic")===!0){const q=e.get("EXT_texture_filter_anisotropic");if(S.type===gt&&e.has("OES_texture_float_linear")===!1||a===!1&&S.type===Vn&&e.has("OES_texture_half_float_linear")===!1)return;(S.anisotropy>1||n.get(S).__currentAnisotropy)&&(i.texParameterf(T,q.TEXTURE_MAX_ANISOTROPY_EXT,Math.min(S.anisotropy,r.getMaxAnisotropy())),n.get(S).__currentAnisotropy=S.anisotropy)}}function ce(T,S){T.__webglInit===void 0&&(T.__webglInit=!0,S.addEventListener("dispose",b),T.__webglTexture=i.createTexture(),o.memory.textures++)}function ye(T,S,U){let q=3553;S.isDataTexture2DArray&&(q=35866),S.isDataTexture3D&&(q=32879),ce(T,S),t.activeTexture(33984+U),t.bindTexture(q,T.__webglTexture),i.pixelStorei(37440,S.flipY),i.pixelStorei(37441,S.premultiplyAlpha),i.pixelStorei(3317,S.unpackAlignment),i.pixelStorei(37443,0);const H=p(S)&&m(S.image)===!1,oe=_(S.image,H,!1,u),ue=m(oe)||a,he=s.convert(S.format);let xe=s.convert(S.type),ge=w(S.internalFormat,he,xe,S.encoding);ve(q,S,ue);let z;const fe=S.mipmaps;if(S.isDepthTexture)ge=6402,a?S.type===gt?ge=36012:S.type===Ra?ge=33190:S.type===Xs?ge=35056:ge=33189:S.type===gt&&console.error("WebGLRenderer: Floating point depth texture requires WebGL2."),S.format===Tr&&ge===6402&&S.type!==oo&&S.type!==Ra&&(console.warn("THREE.WebGLRenderer: Use UnsignedShortType or UnsignedIntType for DepthFormat DepthTexture."),S.type=oo,xe=s.convert(S.type)),S.format===ao&&ge===6402&&(ge=34041,S.type!==Xs&&(console.warn("THREE.WebGLRenderer: Use UnsignedInt248Type for DepthStencilFormat DepthTexture."),S.type=Xs,xe=s.convert(S.type))),t.texImage2D(3553,0,ge,oe.width,oe.height,0,he,xe,null);else if(S.isDataTexture)if(fe.length>0&&ue){for(let ne=0,Te=fe.length;ne0&&ue){for(let ne=0,Te=fe.length;ned+g?(c.inputState.pinching=!1,this.dispatchEvent({type:"pinchend",handedness:e.handedness,target:this})):!c.inputState.pinching&&f<=d-g&&(c.inputState.pinching=!0,this.dispatchEvent({type:"pinchstart",handedness:e.handedness,target:this}))}else l!==null&&e.gripSpace&&(s=t.getPose(e.gripSpace,n),s!==null&&(l.matrix.fromArray(s.transform.matrix),l.matrix.decompose(l.position,l.rotation,l.scale),s.linearVelocity?(l.hasLinearVelocity=!0,l.linearVelocity.copy(s.linearVelocity)):l.hasLinearVelocity=!1,s.angularVelocity?(l.hasAngularVelocity=!0,l.angularVelocity.copy(s.angularVelocity)):l.hasAngularVelocity=!1));return a!==null&&(a.visible=r!==null),l!==null&&(l.visible=s!==null),c!==null&&(c.visible=o!==null),this}}class cw extends ni{constructor(e,t){super();const n=this,r=e.state;let s=null,o=1,a=null,l="local-floor",c=null,u=null,h=null,f=null,d=null,g=!1,v=null,_=null,m=null,p=null,y=null,x=null;const w=[],A=new Map,b=new X0;b.layers.enable(1),b.viewport=new $e;const L=new X0;L.layers.enable(2),L.viewport=new $e;const B=[b,L],I=new G4;I.layers.enable(1),I.layers.enable(2);let C=null,Y=null;this.cameraAutoUpdate=!0,this.enabled=!1,this.isPresenting=!1,this.getController=function($){let se=w[$];return se===void 0&&(se=new v1,w[$]=se),se.getTargetRaySpace()},this.getControllerGrip=function($){let se=w[$];return se===void 0&&(se=new v1,w[$]=se),se.getGripSpace()},this.getHand=function($){let se=w[$];return se===void 0&&(se=new v1,w[$]=se),se.getHandSpace()};function O($){const se=A.get($.inputSource);se&&se.dispatchEvent({type:$.type,data:$.inputSource})}function G(){A.forEach(function($,se){$.disconnect(se)}),A.clear(),C=null,Y=null,r.bindXRFramebuffer(null),e.setRenderTarget(e.getRenderTarget()),h&&t.deleteFramebuffer(h),v&&t.deleteFramebuffer(v),_&&t.deleteRenderbuffer(_),m&&t.deleteRenderbuffer(m),h=null,v=null,_=null,m=null,d=null,f=null,u=null,s=null,ye.stop(),n.isPresenting=!1,n.dispatchEvent({type:"sessionend"})}this.setFramebufferScaleFactor=function($){o=$,n.isPresenting===!0&&console.warn("THREE.WebXRManager: Cannot change framebuffer scale while presenting.")},this.setReferenceSpaceType=function($){l=$,n.isPresenting===!0&&console.warn("THREE.WebXRManager: Cannot change reference space type while presenting.")},this.getReferenceSpace=function(){return a},this.getBaseLayer=function(){return f!==null?f:d},this.getBinding=function(){return u},this.getFrame=function(){return p},this.getSession=function(){return s},this.setSession=async function($){if(s=$,s!==null){s.addEventListener("select",O),s.addEventListener("selectstart",O),s.addEventListener("selectend",O),s.addEventListener("squeeze",O),s.addEventListener("squeezestart",O),s.addEventListener("squeezeend",O),s.addEventListener("end",G),s.addEventListener("inputsourceschange",j);const se=t.getContextAttributes();if(se.xrCompatible!==!0&&await t.makeXRCompatible(),s.renderState.layers===void 0){const pe={antialias:se.antialias,alpha:se.alpha,depth:se.depth,stencil:se.stencil,framebufferScaleFactor:o};d=new XRWebGLLayer(s,t,pe),s.updateRenderState({baseLayer:d})}else if(t instanceof WebGLRenderingContext){const pe={antialias:!0,alpha:se.alpha,depth:se.depth,stencil:se.stencil,framebufferScaleFactor:o};d=new XRWebGLLayer(s,t,pe),s.updateRenderState({layers:[d]})}else{g=se.antialias;let pe=null;se.depth&&(x=256,se.stencil&&(x|=1024),y=se.stencil?33306:36096,pe=se.stencil?35056:33190);const K={colorFormat:se.alpha?32856:32849,depthFormat:pe,scaleFactor:o};u=new XRWebGLBinding(s,t),f=u.createProjectionLayer(K),h=t.createFramebuffer(),s.updateRenderState({layers:[f]}),g&&(v=t.createFramebuffer(),_=t.createRenderbuffer(),t.bindRenderbuffer(36161,_),t.renderbufferStorageMultisample(36161,4,32856,f.textureWidth,f.textureHeight),r.bindFramebuffer(36160,v),t.framebufferRenderbuffer(36160,36064,36161,_),t.bindRenderbuffer(36161,null),pe!==null&&(m=t.createRenderbuffer(),t.bindRenderbuffer(36161,m),t.renderbufferStorageMultisample(36161,4,pe,f.textureWidth,f.textureHeight),t.framebufferRenderbuffer(36160,y,36161,m),t.bindRenderbuffer(36161,null)),r.bindFramebuffer(36160,null))}a=await s.requestReferenceSpace(l),ye.setContext(s),ye.start(),n.isPresenting=!0,n.dispatchEvent({type:"sessionstart"})}};function j($){const se=s.inputSources;for(let pe=0;pe0&&(m.alphaTest.value=p.alphaTest);const y=i.get(p).envMap;if(y){m.envMap.value=y,m.flipEnvMap.value=y.isCubeTexture&&y.isRenderTargetTexture===!1?-1:1,m.reflectivity.value=p.reflectivity,m.ior.value=p.ior,m.refractionRatio.value=p.refractionRatio;const A=i.get(y).__maxMipLevel;A!==void 0&&(m.maxMipLevel.value=A)}p.lightMap&&(m.lightMap.value=p.lightMap,m.lightMapIntensity.value=p.lightMapIntensity),p.aoMap&&(m.aoMap.value=p.aoMap,m.aoMapIntensity.value=p.aoMapIntensity);let x;p.map?x=p.map:p.specularMap?x=p.specularMap:p.displacementMap?x=p.displacementMap:p.normalMap?x=p.normalMap:p.bumpMap?x=p.bumpMap:p.roughnessMap?x=p.roughnessMap:p.metalnessMap?x=p.metalnessMap:p.alphaMap?x=p.alphaMap:p.emissiveMap?x=p.emissiveMap:p.clearcoatMap?x=p.clearcoatMap:p.clearcoatNormalMap?x=p.clearcoatNormalMap:p.clearcoatRoughnessMap?x=p.clearcoatRoughnessMap:p.specularIntensityMap?x=p.specularIntensityMap:p.specularColorMap?x=p.specularColorMap:p.transmissionMap?x=p.transmissionMap:p.thicknessMap?x=p.thicknessMap:p.sheenColorMap?x=p.sheenColorMap:p.sheenRoughnessMap&&(x=p.sheenRoughnessMap),x!==void 0&&(x.isWebGLRenderTarget&&(x=x.texture),x.matrixAutoUpdate===!0&&x.updateMatrix(),m.uvTransform.value.copy(x.matrix));let w;p.aoMap?w=p.aoMap:p.lightMap&&(w=p.lightMap),w!==void 0&&(w.isWebGLRenderTarget&&(w=w.texture),w.matrixAutoUpdate===!0&&w.updateMatrix(),m.uv2Transform.value.copy(w.matrix))}function r(m,p){m.diffuse.value.copy(p.color),m.opacity.value=p.opacity}function s(m,p){m.dashSize.value=p.dashSize,m.totalSize.value=p.dashSize+p.gapSize,m.scale.value=p.scale}function o(m,p,y,x){m.diffuse.value.copy(p.color),m.opacity.value=p.opacity,m.size.value=p.size*y,m.scale.value=x*.5,p.map&&(m.map.value=p.map),p.alphaMap&&(m.alphaMap.value=p.alphaMap),p.alphaTest>0&&(m.alphaTest.value=p.alphaTest);let w;p.map?w=p.map:p.alphaMap&&(w=p.alphaMap),w!==void 0&&(w.matrixAutoUpdate===!0&&w.updateMatrix(),m.uvTransform.value.copy(w.matrix))}function a(m,p){m.diffuse.value.copy(p.color),m.opacity.value=p.opacity,m.rotation.value=p.rotation,p.map&&(m.map.value=p.map),p.alphaMap&&(m.alphaMap.value=p.alphaMap),p.alphaTest>0&&(m.alphaTest.value=p.alphaTest);let y;p.map?y=p.map:p.alphaMap&&(y=p.alphaMap),y!==void 0&&(y.matrixAutoUpdate===!0&&y.updateMatrix(),m.uvTransform.value.copy(y.matrix))}function l(m,p){p.emissiveMap&&(m.emissiveMap.value=p.emissiveMap)}function c(m,p){m.specular.value.copy(p.specular),m.shininess.value=Math.max(p.shininess,1e-4),p.emissiveMap&&(m.emissiveMap.value=p.emissiveMap),p.bumpMap&&(m.bumpMap.value=p.bumpMap,m.bumpScale.value=p.bumpScale,p.side===L0&&(m.bumpScale.value*=-1)),p.normalMap&&(m.normalMap.value=p.normalMap,m.normalScale.value.copy(p.normalScale),p.side===L0&&m.normalScale.value.negate()),p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias)}function u(m,p){p.gradientMap&&(m.gradientMap.value=p.gradientMap),p.emissiveMap&&(m.emissiveMap.value=p.emissiveMap),p.bumpMap&&(m.bumpMap.value=p.bumpMap,m.bumpScale.value=p.bumpScale,p.side===L0&&(m.bumpScale.value*=-1)),p.normalMap&&(m.normalMap.value=p.normalMap,m.normalScale.value.copy(p.normalScale),p.side===L0&&m.normalScale.value.negate()),p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias)}function h(m,p){m.roughness.value=p.roughness,m.metalness.value=p.metalness,p.roughnessMap&&(m.roughnessMap.value=p.roughnessMap),p.metalnessMap&&(m.metalnessMap.value=p.metalnessMap),p.emissiveMap&&(m.emissiveMap.value=p.emissiveMap),p.bumpMap&&(m.bumpMap.value=p.bumpMap,m.bumpScale.value=p.bumpScale,p.side===L0&&(m.bumpScale.value*=-1)),p.normalMap&&(m.normalMap.value=p.normalMap,m.normalScale.value.copy(p.normalScale),p.side===L0&&m.normalScale.value.negate()),p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias),i.get(p).envMap&&(m.envMapIntensity.value=p.envMapIntensity)}function f(m,p,y){h(m,p),m.ior.value=p.ior,p.sheen>0&&(m.sheenColor.value.copy(p.sheenColor).multiplyScalar(p.sheen),m.sheenRoughness.value=p.sheenRoughness,p.sheenColorMap&&(m.sheenColorMap.value=p.sheenColorMap),p.sheenRoughnessMap&&(m.sheenRoughnessMap.value=p.sheenRoughnessMap)),p.clearcoat>0&&(m.clearcoat.value=p.clearcoat,m.clearcoatRoughness.value=p.clearcoatRoughness,p.clearcoatMap&&(m.clearcoatMap.value=p.clearcoatMap),p.clearcoatRoughnessMap&&(m.clearcoatRoughnessMap.value=p.clearcoatRoughnessMap),p.clearcoatNormalMap&&(m.clearcoatNormalScale.value.copy(p.clearcoatNormalScale),m.clearcoatNormalMap.value=p.clearcoatNormalMap,p.side===L0&&m.clearcoatNormalScale.value.negate())),p.transmission>0&&(m.transmission.value=p.transmission,m.transmissionSamplerMap.value=y.texture,m.transmissionSamplerSize.value.set(y.width,y.height),p.transmissionMap&&(m.transmissionMap.value=p.transmissionMap),m.thickness.value=p.thickness,p.thicknessMap&&(m.thicknessMap.value=p.thicknessMap),m.attenuationDistance.value=p.attenuationDistance,m.attenuationColor.value.copy(p.attenuationColor)),m.specularIntensity.value=p.specularIntensity,m.specularColor.value.copy(p.specularColor),p.specularIntensityMap&&(m.specularIntensityMap.value=p.specularIntensityMap),p.specularColorMap&&(m.specularColorMap.value=p.specularColorMap)}function d(m,p){p.matcap&&(m.matcap.value=p.matcap),p.bumpMap&&(m.bumpMap.value=p.bumpMap,m.bumpScale.value=p.bumpScale,p.side===L0&&(m.bumpScale.value*=-1)),p.normalMap&&(m.normalMap.value=p.normalMap,m.normalScale.value.copy(p.normalScale),p.side===L0&&m.normalScale.value.negate()),p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias)}function g(m,p){p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias)}function v(m,p){p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias),m.referencePosition.value.copy(p.referencePosition),m.nearDistance.value=p.nearDistance,m.farDistance.value=p.farDistance}function _(m,p){p.bumpMap&&(m.bumpMap.value=p.bumpMap,m.bumpScale.value=p.bumpScale,p.side===L0&&(m.bumpScale.value*=-1)),p.normalMap&&(m.normalMap.value=p.normalMap,m.normalScale.value.copy(p.normalScale),p.side===L0&&m.normalScale.value.negate()),p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias)}return{refreshFogUniforms:e,refreshMaterialUniforms:t}}function hw(){const i=yl("canvas");return i.style.display="block",i}function o0(i={}){const e=i.canvas!==void 0?i.canvas:hw(),t=i.context!==void 0?i.context:null,n=i.alpha!==void 0?i.alpha:!1,r=i.depth!==void 0?i.depth:!0,s=i.stencil!==void 0?i.stencil:!0,o=i.antialias!==void 0?i.antialias:!1,a=i.premultipliedAlpha!==void 0?i.premultipliedAlpha:!0,l=i.preserveDrawingBuffer!==void 0?i.preserveDrawingBuffer:!1,c=i.powerPreference!==void 0?i.powerPreference:"default",u=i.failIfMajorPerformanceCaveat!==void 0?i.failIfMajorPerformanceCaveat:!1;let h=null,f=null;const d=[],g=[];this.domElement=e,this.debug={checkShaderErrors:!0},this.autoClear=!0,this.autoClearColor=!0,this.autoClearDepth=!0,this.autoClearStencil=!0,this.sortObjects=!0,this.clippingPlanes=[],this.localClippingEnabled=!1,this.gammaFactor=2,this.outputEncoding=J0,this.physicallyCorrectLights=!1,this.toneMapping=Pi,this.toneMappingExposure=1;const v=this;let _=!1,m=0,p=0,y=null,x=-1,w=null;const A=new $e,b=new $e;let L=null,B=e.width,I=e.height,C=1,Y=null,O=null;const G=new $e(0,0,B,I),j=new $e(0,0,B,I);let N=!1;const k=[],Z=new wl;let le=!1,ve=!1,ce=null;const ye=new Me,$=new P,se={background:null,fog:null,environment:null,overrideMaterial:null,isScene:!0};function pe(){return y===null?C:1}let K=t;function V(R,J){for(let ae=0;ae0?f=g[g.length-1]:f=null,d.pop(),d.length>0?h=d[d.length-1]:h=null};function H9(R,J,ae,ie){if(R.visible===!1)return;if(R.layers.test(J.layers)){if(R.isGroup)ae=R.renderOrder;else if(R.isLOD)R.autoUpdate===!0&&R.update(J);else if(R.isLight)f.pushLight(R),R.castShadow&&f.pushShadow(R);else if(R.isSprite){if(!R.frustumCulled||Z.intersectsSprite(R)){ie&&$.setFromMatrixPosition(R.matrixWorld).applyMatrix4(ye);const Ce=S.update(R),Pe=R.material;Pe.visible&&h.push(R,Ce,Pe,ae,$.z,null)}}else if((R.isMesh||R.isLine||R.isPoints)&&(R.isSkinnedMesh&&R.skeleton.frame!==we.render.frame&&(R.skeleton.update(),R.skeleton.frame=we.render.frame),!R.frustumCulled||Z.intersectsObject(R))){ie&&$.setFromMatrixPosition(R.matrixWorld).applyMatrix4(ye);const Ce=S.update(R),Pe=R.material;if(Array.isArray(Pe)){const ze=Ce.groups;for(let n0=0,He=ze.length;n00&&ud(de,J,ae),ie&&re.viewport(A.copy(ie)),de.length>0&&No(de,J,ae),Re.length>0&&No(Re,J,ae),Ce.length>0&&No(Ce,J,ae)}function ud(R,J,ae){if(ce===null){const Ce=o===!0&&Q.isWebGL2===!0?w4:C0;ce=new Ce(1024,1024,{generateMipmaps:!0,type:ne.convert(Vn)!==null?Vn:Kn,minFilter:Ni,magFilter:r0,wrapS:m0,wrapT:m0})}const ie=v.getRenderTarget();v.setRenderTarget(ce),v.clear();const de=v.toneMapping;v.toneMapping=Pi,No(R,J,ae),v.toneMapping=de,E.updateMultisampleRenderTarget(ce),E.updateRenderTargetMipmap(ce),v.setRenderTarget(ie)}function No(R,J,ae){const ie=J.isScene===!0?J.overrideMaterial:null;for(let de=0,Re=R.length;de=0&&J<=R.width-ie&&ae>=0&&ae<=R.height-de&&K.readPixels(J,ae,ie,de,ne.convert(n0),ne.convert(He),Re):console.error("THREE.WebGLRenderer.readRenderTargetPixels: readPixels from renderTarget failed. Framebuffer not complete.")}finally{const ze=y!==null?M.get(y).__webglFramebuffer:null;re.bindFramebuffer(36160,ze)}}},this.copyFramebufferToTexture=function(R,J,ae=0){const ie=Math.pow(2,-ae),de=Math.floor(J.image.width*ie),Re=Math.floor(J.image.height*ie);let Ce=ne.convert(J.format);Q.isWebGL2&&(Ce===6407&&(Ce=32849),Ce===6408&&(Ce=32856)),E.setTexture2D(J,0),K.copyTexImage2D(3553,ae,Ce,R.x,R.y,de,Re,0),re.unbindTexture()},this.copyTextureToTexture=function(R,J,ae,ie=0){const de=J.image.width,Re=J.image.height,Ce=ne.convert(ae.format),Pe=ne.convert(ae.type);E.setTexture2D(ae,0),K.pixelStorei(37440,ae.flipY),K.pixelStorei(37441,ae.premultiplyAlpha),K.pixelStorei(3317,ae.unpackAlignment),J.isDataTexture?K.texSubImage2D(3553,ie,R.x,R.y,de,Re,Ce,Pe,J.image.data):J.isCompressedTexture?K.compressedTexSubImage2D(3553,ie,R.x,R.y,J.mipmaps[0].width,J.mipmaps[0].height,Ce,J.mipmaps[0].data):K.texSubImage2D(3553,ie,R.x,R.y,Ce,Pe,J.image),ie===0&&ae.generateMipmaps&&K.generateMipmap(3553),re.unbindTexture()},this.copyTextureToTexture3D=function(R,J,ae,ie,de=0){if(v.isWebGL1Renderer){console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: can only be used with WebGL2.");return}const Re=R.max.x-R.min.x+1,Ce=R.max.y-R.min.y+1,Pe=R.max.z-R.min.z+1,ze=ne.convert(ie.format),n0=ne.convert(ie.type);let He;if(ie.isDataTexture3D)E.setTexture3D(ie,0),He=32879;else if(ie.isDataTexture2DArray)E.setTexture2DArray(ie,0),He=35866;else{console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: only supports THREE.DataTexture3D and THREE.DataTexture2DArray.");return}K.pixelStorei(37440,ie.flipY),K.pixelStorei(37441,ie.premultiplyAlpha),K.pixelStorei(3317,ie.unpackAlignment);const qe=K.getParameter(3314),x0=K.getParameter(32878),ui=K.getParameter(3316),Je=K.getParameter(3315),ms=K.getParameter(32877),h0=ae.isCompressedTexture?ae.mipmaps[0]:ae.image;K.pixelStorei(3314,h0.width),K.pixelStorei(32878,h0.height),K.pixelStorei(3316,R.min.x),K.pixelStorei(3315,R.min.y),K.pixelStorei(32877,R.min.z),ae.isDataTexture||ae.isDataTexture3D?K.texSubImage3D(He,de,J.x,J.y,J.z,Re,Ce,Pe,ze,n0,h0.data):ae.isCompressedTexture?(console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: untested support for compressed srcTexture."),K.compressedTexSubImage3D(He,de,J.x,J.y,J.z,Re,Ce,Pe,ze,h0.data)):K.texSubImage3D(He,de,J.x,J.y,J.z,Re,Ce,Pe,ze,n0,h0),K.pixelStorei(3314,qe),K.pixelStorei(32878,x0),K.pixelStorei(3316,ui),K.pixelStorei(3315,Je),K.pixelStorei(32877,ms),de===0&&ie.generateMipmaps&&K.generateMipmap(He),re.unbindTexture()},this.initTexture=function(R){E.setTexture2D(R,0),re.unbindTexture()},this.resetState=function(){m=0,p=0,y=null,re.reset(),Te.reset()},typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}o0.prototype.isWebGLRenderer=!0;class fw extends o0{}fw.prototype.isWebGL1Renderer=!0;let o9=class extends t0{constructor(){super(),this.type="Scene",this.background=null,this.environment=null,this.fog=null,this.overrideMaterial=null,this.autoUpdate=!0,typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}copy(e,t){return super.copy(e,t),e.background!==null&&(this.background=e.background.clone()),e.environment!==null&&(this.environment=e.environment.clone()),e.fog!==null&&(this.fog=e.fog.clone()),e.overrideMaterial!==null&&(this.overrideMaterial=e.overrideMaterial.clone()),this.autoUpdate=e.autoUpdate,this.matrixAutoUpdate=e.matrixAutoUpdate,this}toJSON(e){const t=super.toJSON(e);return this.fog!==null&&(t.object.fog=this.fog.toJSON()),t}};o9.prototype.isScene=!0;class $r{constructor(e,t){this.array=e,this.stride=t,this.count=e!==void 0?e.length/t:0,this.usage=co,this.updateRange={offset:0,count:-1},this.version=0,this.uuid=yt()}onUploadCallback(){}set needsUpdate(e){e===!0&&this.version++}setUsage(e){return this.usage=e,this}copy(e){return this.array=new e.array.constructor(e.array),this.count=e.count,this.stride=e.stride,this.usage=e.usage,this}copyAt(e,t,n){e*=this.stride,n*=t.stride;for(let r=0,s=this.stride;re.far||t.push({distance:l,point:Ss.clone(),uv:R0.getUV(Ss,la,As,ca,ju,x1,Yu,new ee),face:null,object:this})}copy(e){return super.copy(e),e.center!==void 0&&this.center.copy(e.center),this.material=e.material,this}};V4.prototype.isSprite=!0;function ua(i,e,t,n,r,s){cr.subVectors(i,t).addScalar(.5).multiply(n),r!==void 0?(Ts.x=s*cr.x-r*cr.y,Ts.y=r*cr.x+s*cr.y):Ts.copy(cr),i.copy(e),i.x+=Ts.x,i.y+=Ts.y,i.applyMatrix4(H4)}const qu=new P,Qu=new $e,Zu=new $e,dw=new P,Ku=new Me;class Sl extends I0{constructor(e,t){super(e,t),this.type="SkinnedMesh",this.bindMode="attached",this.bindMatrix=new Me,this.bindMatrixInverse=new Me}copy(e){return super.copy(e),this.bindMode=e.bindMode,this.bindMatrix.copy(e.bindMatrix),this.bindMatrixInverse.copy(e.bindMatrixInverse),this.skeleton=e.skeleton,this}bind(e,t){this.skeleton=e,t===void 0&&(this.updateMatrixWorld(!0),this.skeleton.calculateInverses(),t=this.matrixWorld),this.bindMatrix.copy(t),this.bindMatrixInverse.copy(t).invert()}pose(){this.skeleton.pose()}normalizeSkinWeights(){const e=new $e,t=this.geometry.attributes.skinWeight;for(let n=0,r=t.count;nl)continue;f.applyMatrix4(this.matrixWorld);const L=e.ray.origin.distanceTo(f);Le.far||t.push({distance:L,point:h.clone().applyMatrix4(this.matrixWorld),index:y,face:null,faceIndex:null,object:this})}}else{const m=Math.max(0,o.start),p=Math.min(_.count,o.start+o.count);for(let y=m,x=p-1;yl)continue;f.applyMatrix4(this.matrixWorld);const A=e.ray.origin.distanceTo(f);Ae.far||t.push({distance:A,point:h.clone().applyMatrix4(this.matrixWorld),index:y,face:null,faceIndex:null,object:this})}}}else n.isGeometry&&console.error("THREE.Line.raycast() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")}updateMorphTargets(){const e=this.geometry;if(e.isBufferGeometry){const t=e.morphAttributes,n=Object.keys(t);if(n.length>0){const r=t[n[0]];if(r!==void 0){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let s=0,o=r.length;s0&&console.error("THREE.Line.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.")}}}es.prototype.isLine=!0;const r3=new P,s3=new P;class Al extends es{constructor(e,t){super(e,t),this.type="LineSegments"}computeLineDistances(){const e=this.geometry;if(e.isBufferGeometry)if(e.index===null){const t=e.attributes.position,n=[];for(let r=0,s=t.count;r0){const r=t[n[0]];if(r!==void 0){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let s=0,o=r.length;s0&&console.error("THREE.Points.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.")}}};l9.prototype.isPoints=!0;function a3(i,e,t,n,r,s,o){const a=rc.distanceSqToPoint(i);if(ar.far)return;s.push({distance:c,distanceToRay:Math.sqrt(a),point:l,index:e,face:null,object:o})}}let X4=class extends A0{constructor(e,t,n,r,s,o,a,l,c){super(e,t,n,r,s,o,a,l,c),this.format=a!==void 0?a:Yt,this.minFilter=o!==void 0?o:s0,this.magFilter=s!==void 0?s:s0,this.generateMipmaps=!1;const u=this;function h(){u.needsUpdate=!0,e.requestVideoFrameCallback(h)}"requestVideoFrameCallback"in e&&e.requestVideoFrameCallback(h)}clone(){return new this.constructor(this.image).copy(this)}update(){const e=this.image;"requestVideoFrameCallback"in e===!1&&e.readyState>=e.HAVE_CURRENT_DATA&&(this.needsUpdate=!0)}};X4.prototype.isVideoTexture=!0;class mw extends A0{constructor(e,t,n,r,s,o,a,l,c,u,h,f){super(null,o,a,l,c,u,r,s,h,f),this.image={width:t,height:n},this.mipmaps=e,this.flipY=!1,this.generateMipmaps=!1}}mw.prototype.isCompressedTexture=!0;class gw extends A0{constructor(e,t,n,r,s,o,a,l,c){super(e,t,n,r,s,o,a,l,c),this.needsUpdate=!0}}gw.prototype.isCanvasTexture=!0;class j4 extends A0{constructor(e,t,n,r,s,o,a,l,c,u){if(u=u!==void 0?u:Tr,u!==Tr&&u!==ao)throw new Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");n===void 0&&u===Tr&&(n=oo),n===void 0&&u===ao&&(n=Xs),super(null,r,s,o,a,l,u,n,c),this.image={width:e,height:t},this.magFilter=a!==void 0?a:r0,this.minFilter=l!==void 0?l:r0,this.flipY=!1,this.generateMipmaps=!1}}j4.prototype.isDepthTexture=!0;let vw=class Y4 extends Fe{constructor(e=1,t=8,n=0,r=Math.PI*2){super(),this.type="CircleGeometry",this.parameters={radius:e,segments:t,thetaStart:n,thetaLength:r},t=Math.max(3,t);const s=[],o=[],a=[],l=[],c=new P,u=new ee;o.push(0,0,0),a.push(0,0,1),l.push(.5,.5);for(let h=0,f=3;h<=t;h++,f+=3){const d=n+h/t*r;c.x=e*Math.cos(d),c.y=e*Math.sin(d),o.push(c.x,c.y,c.z),a.push(0,0,1),u.x=(o[f]/e+1)/2,u.y=(o[f+1]/e+1)/2,l.push(u.x,u.y)}for(let h=1;h<=t;h++)s.push(h,h+1,0);this.setIndex(s),this.setAttribute("position",new Ae(o,3)),this.setAttribute("normal",new Ae(a,3)),this.setAttribute("uv",new Ae(l,2))}static fromJSON(e){return new Y4(e.radius,e.segments,e.thetaStart,e.thetaLength)}},q4=class Q4 extends Fe{constructor(e=1,t=1,n=1,r=8,s=1,o=!1,a=0,l=Math.PI*2){super(),this.type="CylinderGeometry",this.parameters={radiusTop:e,radiusBottom:t,height:n,radialSegments:r,heightSegments:s,openEnded:o,thetaStart:a,thetaLength:l};const c=this;r=Math.floor(r),s=Math.floor(s);const u=[],h=[],f=[],d=[];let g=0;const v=[],_=n/2;let m=0;p(),o===!1&&(e>0&&y(!0),t>0&&y(!1)),this.setIndex(u),this.setAttribute("position",new Ae(h,3)),this.setAttribute("normal",new Ae(f,3)),this.setAttribute("uv",new Ae(d,2));function p(){const x=new P,w=new P;let A=0;const b=(t-e)/n;for(let L=0;L<=s;L++){const B=[],I=L/s,C=I*(t-e)+e;for(let Y=0;Y<=r;Y++){const O=Y/r,G=O*l+a,j=Math.sin(G),N=Math.cos(G);w.x=C*j,w.y=-I*n+_,w.z=C*N,h.push(w.x,w.y,w.z),x.set(j,b,N).normalize(),f.push(x.x,x.y,x.z),d.push(O,1-I),B.push(g++)}v.push(B)}for(let L=0;L.9&&b<.1&&(y<.2&&(o[p+0]+=1),x<.2&&(o[p+2]+=1),w<.2&&(o[p+4]+=1))}}function f(p){s.push(p.x,p.y,p.z)}function d(p,y){const x=p*3;y.x=e[x+0],y.y=e[x+1],y.z=e[x+2]}function g(){const p=new P,y=new P,x=new P,w=new P,A=new ee,b=new ee,L=new ee;for(let B=0,I=0;B0)l=r-1;else{l=r;break}if(r=l,n[r]===o)return r/(s-1);const u=n[r],f=n[r+1]-u,d=(o-u)/f;return(r+d)/(s-1)}getTangent(e,t){let r=e-1e-4,s=e+1e-4;r<0&&(r=0),s>1&&(s=1);const o=this.getPoint(r),a=this.getPoint(s),l=t||(o.isVector2?new ee:new P);return l.copy(a).sub(o).normalize(),l}getTangentAt(e,t){const n=this.getUtoTmapping(e);return this.getTangent(n,t)}computeFrenetFrames(e,t){const n=new P,r=[],s=[],o=[],a=new P,l=new Me;for(let d=0;d<=e;d++){const g=d/e;r[d]=this.getTangentAt(g,new P)}s[0]=new P,o[0]=new P;let c=Number.MAX_VALUE;const u=Math.abs(r[0].x),h=Math.abs(r[0].y),f=Math.abs(r[0].z);u<=c&&(c=u,n.set(1,0,0)),h<=c&&(c=h,n.set(0,1,0)),f<=c&&n.set(0,0,1),a.crossVectors(r[0],n).normalize(),s[0].crossVectors(r[0],a),o[0].crossVectors(r[0],s[0]);for(let d=1;d<=e;d++){if(s[d]=s[d-1].clone(),o[d]=o[d-1].clone(),a.crossVectors(r[d-1],r[d]),a.length()>Number.EPSILON){a.normalize();const g=Math.acos(Q0(r[d-1].dot(r[d]),-1,1));s[d].applyMatrix4(l.makeRotationAxis(a,g))}o[d].crossVectors(r[d],s[d])}if(t===!0){let d=Math.acos(Q0(s[0].dot(s[e]),-1,1));d/=e,r[0].dot(a.crossVectors(s[0],s[e]))>0&&(d=-d);for(let g=1;g<=e;g++)s[g].applyMatrix4(l.makeRotationAxis(r[g],d*g)),o[g].crossVectors(r[g],s[g])}return{tangents:r,normals:s,binormals:o}}clone(){return new this.constructor().copy(this)}copy(e){return this.arcLengthDivisions=e.arcLengthDivisions,this}toJSON(){const e={metadata:{version:4.5,type:"Curve",generator:"Curve.toJSON"}};return e.arcLengthDivisions=this.arcLengthDivisions,e.type=this.type,e}fromJSON(e){return this.arcLengthDivisions=e.arcLengthDivisions,this}}class Ll extends ut{constructor(e=0,t=0,n=1,r=1,s=0,o=Math.PI*2,a=!1,l=0){super(),this.type="EllipseCurve",this.aX=e,this.aY=t,this.xRadius=n,this.yRadius=r,this.aStartAngle=s,this.aEndAngle=o,this.aClockwise=a,this.aRotation=l}getPoint(e,t){const n=t||new ee,r=Math.PI*2;let s=this.aEndAngle-this.aStartAngle;const o=Math.abs(s)r;)s-=r;s0?0:(Math.floor(Math.abs(a)/s)+1)*s:l===0&&a===s-1&&(a=s-2,l=1);let c,u;this.closed||a>0?c=r[(a-1)%s]:(ma.subVectors(r[0],r[1]).add(r[0]),c=ma);const h=r[a%s],f=r[(a+1)%s];if(this.closed||a+2r.length-2?r.length-1:o+1],h=r[o>r.length-3?r.length-1:o+2];return n.set(l3(a,l.x,c.x,u.x,h.x),l3(a,l.y,c.y,u.y,h.y)),n}copy(e){super.copy(e),this.points=[];for(let t=0,n=e.points.length;t=n){const o=r[s]-n,a=this.curves[s],l=a.getLength(),c=l===0?0:1-o/l;return a.getPointAt(c,t)}s++}return null}getLength(){const e=this.getCurveLengths();return e[e.length-1]}updateArcLengths(){this.needsUpdate=!0,this.cacheLengths=null,this.getCurveLengths()}getCurveLengths(){if(this.cacheLengths&&this.cacheLengths.length===this.curves.length)return this.cacheLengths;const e=[];let t=0;for(let n=0,r=this.curves.length;n1&&!t[t.length-1].equals(t[0])&&t.push(t[0]),t}copy(e){super.copy(e),this.curves=[];for(let t=0,n=e.curves.length;t0){const h=c.getPoint(0);h.equals(this.currentPoint)||this.lineTo(h.x,h.y)}this.curves.push(c);const u=c.getPoint(1);return this.currentPoint.copy(u),this}copy(e){return super.copy(e),this.currentPoint.copy(e.currentPoint),this}toJSON(){const e=super.toJSON();return e.currentPoint=this.currentPoint.toArray(),e}fromJSON(e){return super.fromJSON(e),this.currentPoint.fromArray(e.currentPoint),this}}class jn extends qa{constructor(e){super(e),this.uuid=yt(),this.type="Shape",this.holes=[]}getPointsHoles(e){const t=[];for(let n=0,r=this.holes.length;n80*t){a=c=i[0],l=u=i[1];for(let g=t;gc&&(c=h),f>u&&(u=f);d=Math.max(c-a,u-l),d=d!==0?1/d:0}return po(s,o,t,a,l,d),o}};function t5(i,e,t,n,r){let s,o;if(r===Xw(i,e,t,n)>0)for(s=e;s=e;s-=n)o=c3(s,i[s],i[s+1],o);return o&&Rl(o,o.next)&&(go(o),o=o.next),o}function $n(i,e){if(!i)return i;e||(e=i);let t=i,n;do if(n=!1,!t.steiner&&(Rl(t,t.next)||v0(t.prev,t,t.next)===0)){if(go(t),t=e=t.prev,t===t.next)break;n=!0}else t=t.next;while(n||t!==e);return e}function po(i,e,t,n,r,s,o){if(!i)return;!o&&s&&Bw(i,n,r,s);let a=i,l,c;for(;i.prev!==i.next;){if(l=i.prev,c=i.next,s?Rw(i,n,r,s):Cw(i)){e.push(l.i/t),e.push(i.i/t),e.push(c.i/t),go(i),i=c.next,a=c.next;continue}if(i=c,i===a){o?o===1?(i=Fw($n(i),e,t),po(i,e,t,n,r,s,2)):o===2&&Iw(i,e,t,n,r,s):po($n(i),e,t,n,r,s,1);break}}}function Cw(i){const e=i.prev,t=i,n=i.next;if(v0(e,t,n)>=0)return!1;let r=i.next.next;for(;r!==i.prev;){if(xr(e.x,e.y,t.x,t.y,n.x,n.y,r.x,r.y)&&v0(r.prev,r,r.next)>=0)return!1;r=r.next}return!0}function Rw(i,e,t,n){const r=i.prev,s=i,o=i.next;if(v0(r,s,o)>=0)return!1;const a=r.xs.x?r.x>o.x?r.x:o.x:s.x>o.x?s.x:o.x,u=r.y>s.y?r.y>o.y?r.y:o.y:s.y>o.y?s.y:o.y,h=sc(a,l,e,t,n),f=sc(c,u,e,t,n);let d=i.prevZ,g=i.nextZ;for(;d&&d.z>=h&&g&&g.z<=f;){if(d!==i.prev&&d!==i.next&&xr(r.x,r.y,s.x,s.y,o.x,o.y,d.x,d.y)&&v0(d.prev,d,d.next)>=0||(d=d.prevZ,g!==i.prev&&g!==i.next&&xr(r.x,r.y,s.x,s.y,o.x,o.y,g.x,g.y)&&v0(g.prev,g,g.next)>=0))return!1;g=g.nextZ}for(;d&&d.z>=h;){if(d!==i.prev&&d!==i.next&&xr(r.x,r.y,s.x,s.y,o.x,o.y,d.x,d.y)&&v0(d.prev,d,d.next)>=0)return!1;d=d.prevZ}for(;g&&g.z<=f;){if(g!==i.prev&&g!==i.next&&xr(r.x,r.y,s.x,s.y,o.x,o.y,g.x,g.y)&&v0(g.prev,g,g.next)>=0)return!1;g=g.nextZ}return!0}function Fw(i,e,t){let n=i;do{const r=n.prev,s=n.next.next;!Rl(r,s)&&n5(r,n,n.next,s)&&mo(r,s)&&mo(s,r)&&(e.push(r.i/t),e.push(n.i/t),e.push(s.i/t),go(n),go(n.next),n=i=s),n=n.next}while(n!==i);return $n(n)}function Iw(i,e,t,n,r,s){let o=i;do{let a=o.next.next;for(;a!==o.prev;){if(o.i!==a.i&&Hw(o,a)){let l=i5(o,a);o=$n(o,o.next),l=$n(l,l.next),po(o,e,t,n,r,s),po(l,e,t,n,r,s);return}a=a.next}o=o.next}while(o!==i)}function Dw(i,e,t,n){const r=[];let s,o,a,l,c;for(s=0,o=e.length;s=t.next.y&&t.next.y!==t.y){const f=t.x+(r-t.y)*(t.next.x-t.x)/(t.next.y-t.y);if(f<=n&&f>s){if(s=f,f===n){if(r===t.y)return t;if(r===t.next.y)return t.next}o=t.x=t.x&&t.x>=l&&n!==t.x&&xr(ro.x||t.x===o.x&&zw(o,t)))&&(o=t,u=h)),t=t.next;while(t!==a);return o}function zw(i,e){return v0(i.prev,i,e.prev)<0&&v0(e.next,i,i.next)<0}function Bw(i,e,t,n){let r=i;do r.z===null&&(r.z=sc(r.x,r.y,e,t,n)),r.prevZ=r.prev,r.nextZ=r.next,r=r.next;while(r!==i);r.prevZ.nextZ=null,r.prevZ=null,kw(r)}function kw(i){let e,t,n,r,s,o,a,l,c=1;do{for(t=i,i=null,s=null,o=0;t;){for(o++,n=t,a=0,e=0;e0||l>0&&n;)a!==0&&(l===0||!n||t.z<=n.z)?(r=t,t=t.nextZ,a--):(r=n,n=n.nextZ,l--),s?s.nextZ=r:i=r,r.prevZ=s,s=r;t=n}s.nextZ=null,c*=2}while(o>1);return i}function sc(i,e,t,n,r){return i=32767*(i-t)*r,e=32767*(e-n)*r,i=(i|i<<8)&16711935,i=(i|i<<4)&252645135,i=(i|i<<2)&858993459,i=(i|i<<1)&1431655765,e=(e|e<<8)&16711935,e=(e|e<<4)&252645135,e=(e|e<<2)&858993459,e=(e|e<<1)&1431655765,i|e<<1}function Gw(i){let e=i,t=i;do(e.x=0&&(i-o)*(n-a)-(t-o)*(e-a)>=0&&(t-o)*(s-a)-(r-o)*(n-a)>=0}function Hw(i,e){return i.next.i!==e.i&&i.prev.i!==e.i&&!Vw(i,e)&&(mo(i,e)&&mo(e,i)&&Ww(i,e)&&(v0(i.prev,i,e.prev)||v0(i,e.prev,e))||Rl(i,e)&&v0(i.prev,i,i.next)>0&&v0(e.prev,e,e.next)>0)}function v0(i,e,t){return(e.y-i.y)*(t.x-e.x)-(e.x-i.x)*(t.y-e.y)}function Rl(i,e){return i.x===e.x&&i.y===e.y}function n5(i,e,t,n){const r=va(v0(i,e,t)),s=va(v0(i,e,n)),o=va(v0(t,n,i)),a=va(v0(t,n,e));return!!(r!==s&&o!==a||r===0&&ga(i,t,e)||s===0&&ga(i,n,e)||o===0&&ga(t,i,n)||a===0&&ga(t,e,n))}function ga(i,e,t){return e.x<=Math.max(i.x,t.x)&&e.x>=Math.min(i.x,t.x)&&e.y<=Math.max(i.y,t.y)&&e.y>=Math.min(i.y,t.y)}function va(i){return i>0?1:i<0?-1:0}function Vw(i,e){let t=i;do{if(t.i!==i.i&&t.next.i!==i.i&&t.i!==e.i&&t.next.i!==e.i&&n5(t,t.next,i,e))return!0;t=t.next}while(t!==i);return!1}function mo(i,e){return v0(i.prev,i,i.next)<0?v0(i,e,i.next)>=0&&v0(i,i.prev,e)>=0:v0(i,e,i.prev)<0||v0(i,i.next,e)<0}function Ww(i,e){let t=i,n=!1;const r=(i.x+e.x)/2,s=(i.y+e.y)/2;do t.y>s!=t.next.y>s&&t.next.y!==t.y&&r<(t.next.x-t.x)*(s-t.y)/(t.next.y-t.y)+t.x&&(n=!n),t=t.next;while(t!==i);return n}function i5(i,e){const t=new oc(i.i,i.x,i.y),n=new oc(e.i,e.x,e.y),r=i.next,s=e.prev;return i.next=e,e.prev=i,t.next=r,r.prev=t,n.next=t,t.prev=n,s.next=n,n.prev=s,n}function c3(i,e,t,n){const r=new oc(i,e,t);return n?(r.next=n.next,r.prev=n,n.next.prev=r,n.next=r):(r.prev=r,r.next=r),r}function go(i){i.next.prev=i.prev,i.prev.next=i.next,i.prevZ&&(i.prevZ.nextZ=i.nextZ),i.nextZ&&(i.nextZ.prevZ=i.prevZ)}function oc(i,e,t){this.i=i,this.x=e,this.y=t,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function Xw(i,e,t,n){let r=0;for(let s=e,o=t-n;s2&&i[e-1].equals(i[0])&&i.pop()}function h3(i,e){for(let t=0;tNumber.EPSILON){const he=Math.sqrt(oe),xe=Math.sqrt(q*q+H*H),ge=E.x-U/he,z=E.y+S/he,fe=F.x-H/xe,ne=F.y+q/xe,Te=((fe-ge)*H-(ne-z)*q)/(S*H-U*q);W=ge+S*Te-M.x,X=z+U*Te-M.y;const D=W*W+X*X;if(D<=2)return new ee(W,X);T=Math.sqrt(D/2)}else{let he=!1;S>Number.EPSILON?q>Number.EPSILON&&(he=!0):S<-Number.EPSILON?q<-Number.EPSILON&&(he=!0):Math.sign(U)===Math.sign(H)&&(he=!0),he?(W=-U,X=S,T=Math.sqrt(oe)):(W=S,X=U,T=Math.sqrt(oe/2))}return new ee(W/T,X/T)}const le=[];for(let M=0,E=G.length,F=E-1,W=M+1;M=0;M--){const E=M/_,F=d*Math.cos(E*Math.PI/2),W=g*Math.sin(E*Math.PI/2)+v;for(let X=0,T=G.length;X=0;){const W=F;let X=F-1;X<0&&(X=M.length-1);for(let T=0,S=u+_*2;T0)&&d.push(y,x,A),(m!==n-1||l0!=e>0&&this.version++,this._sheen=e}get clearcoat(){return this._clearcoat}set clearcoat(e){this._clearcoat>0!=e>0&&this.version++,this._clearcoat=e}get transmission(){return this._transmission}set transmission(e){this._transmission>0!=e>0&&this.version++,this._transmission=e}copy(e){return super.copy(e),this.defines={STANDARD:"",PHYSICAL:""},this.clearcoat=e.clearcoat,this.clearcoatMap=e.clearcoatMap,this.clearcoatRoughness=e.clearcoatRoughness,this.clearcoatRoughnessMap=e.clearcoatRoughnessMap,this.clearcoatNormalMap=e.clearcoatNormalMap,this.clearcoatNormalScale.copy(e.clearcoatNormalScale),this.ior=e.ior,this.sheen=e.sheen,this.sheenColor.copy(e.sheenColor),this.sheenColorMap=e.sheenColorMap,this.sheenRoughness=e.sheenRoughness,this.sheenRoughnessMap=e.sheenRoughnessMap,this.transmission=e.transmission,this.transmissionMap=e.transmissionMap,this.thickness=e.thickness,this.thicknessMap=e.thicknessMap,this.attenuationDistance=e.attenuationDistance,this.attenuationColor.copy(e.attenuationColor),this.specularIntensity=e.specularIntensity,this.specularIntensityMap=e.specularIntensityMap,this.specularColor.copy(e.specularColor),this.specularColorMap=e.specularColorMap,this}}si.prototype.isMeshPhysicalMaterial=!0;class Zs extends D0{constructor(e){super(),this.type="MeshPhongMaterial",this.color=new be(16777215),this.specular=new be(1118481),this.shininess=30,this.map=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new be(0),this.emissiveIntensity=1,this.emissiveMap=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=Oi,this.normalScale=new ee(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.specularMap=null,this.alphaMap=null,this.envMap=null,this.combine=vl,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.flatShading=!1,this.setValues(e)}copy(e){return super.copy(e),this.color.copy(e.color),this.specular.copy(e.specular),this.shininess=e.shininess,this.map=e.map,this.lightMap=e.lightMap,this.lightMapIntensity=e.lightMapIntensity,this.aoMap=e.aoMap,this.aoMapIntensity=e.aoMapIntensity,this.emissive.copy(e.emissive),this.emissiveMap=e.emissiveMap,this.emissiveIntensity=e.emissiveIntensity,this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.specularMap=e.specularMap,this.alphaMap=e.alphaMap,this.envMap=e.envMap,this.combine=e.combine,this.reflectivity=e.reflectivity,this.refractionRatio=e.refractionRatio,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.wireframeLinecap=e.wireframeLinecap,this.wireframeLinejoin=e.wireframeLinejoin,this.flatShading=e.flatShading,this}}Zs.prototype.isMeshPhongMaterial=!0;class v5 extends D0{constructor(e){super(),this.defines={TOON:""},this.type="MeshToonMaterial",this.color=new be(16777215),this.map=null,this.gradientMap=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new be(0),this.emissiveIntensity=1,this.emissiveMap=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=Oi,this.normalScale=new ee(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.alphaMap=null,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.setValues(e)}copy(e){return super.copy(e),this.color.copy(e.color),this.map=e.map,this.gradientMap=e.gradientMap,this.lightMap=e.lightMap,this.lightMapIntensity=e.lightMapIntensity,this.aoMap=e.aoMap,this.aoMapIntensity=e.aoMapIntensity,this.emissive.copy(e.emissive),this.emissiveMap=e.emissiveMap,this.emissiveIntensity=e.emissiveIntensity,this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.alphaMap=e.alphaMap,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.wireframeLinecap=e.wireframeLinecap,this.wireframeLinejoin=e.wireframeLinejoin,this}}v5.prototype.isMeshToonMaterial=!0;class x5 extends D0{constructor(e){super(),this.type="MeshNormalMaterial",this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=Oi,this.normalScale=new ee(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.flatShading=!1,this.setValues(e)}copy(e){return super.copy(e),this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.flatShading=e.flatShading,this}}x5.prototype.isMeshNormalMaterial=!0;class m9 extends D0{constructor(e){super(),this.type="MeshLambertMaterial",this.color=new be(16777215),this.map=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new be(0),this.emissiveIntensity=1,this.emissiveMap=null,this.specularMap=null,this.alphaMap=null,this.envMap=null,this.combine=vl,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.setValues(e)}copy(e){return super.copy(e),this.color.copy(e.color),this.map=e.map,this.lightMap=e.lightMap,this.lightMapIntensity=e.lightMapIntensity,this.aoMap=e.aoMap,this.aoMapIntensity=e.aoMapIntensity,this.emissive.copy(e.emissive),this.emissiveMap=e.emissiveMap,this.emissiveIntensity=e.emissiveIntensity,this.specularMap=e.specularMap,this.alphaMap=e.alphaMap,this.envMap=e.envMap,this.combine=e.combine,this.reflectivity=e.reflectivity,this.refractionRatio=e.refractionRatio,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.wireframeLinecap=e.wireframeLinecap,this.wireframeLinejoin=e.wireframeLinejoin,this}}m9.prototype.isMeshLambertMaterial=!0;class y5 extends D0{constructor(e){super(),this.defines={MATCAP:""},this.type="MeshMatcapMaterial",this.color=new be(16777215),this.matcap=null,this.map=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=Oi,this.normalScale=new ee(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.alphaMap=null,this.flatShading=!1,this.setValues(e)}copy(e){return super.copy(e),this.defines={MATCAP:""},this.color.copy(e.color),this.matcap=e.matcap,this.map=e.map,this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.alphaMap=e.alphaMap,this.flatShading=e.flatShading,this}}y5.prototype.isMeshMatcapMaterial=!0;class rM extends ri{constructor(e){super(),this.type="LineDashedMaterial",this.scale=1,this.dashSize=3,this.gapSize=1,this.setValues(e)}copy(e){return super.copy(e),this.scale=e.scale,this.dashSize=e.dashSize,this.gapSize=e.gapSize,this}}rM.prototype.isLineDashedMaterial=!0;const p0={arraySlice:function(i,e,t){return p0.isTypedArray(i)?new i.constructor(i.subarray(e,t!==void 0?t:i.length)):i.slice(e,t)},convertArray:function(i,e,t){return!i||!t&&i.constructor===e?i:typeof e.BYTES_PER_ELEMENT=="number"?new e(i):Array.prototype.slice.call(i)},isTypedArray:function(i){return ArrayBuffer.isView(i)&&!(i instanceof DataView)},getKeyframeOrder:function(i){function e(r,s){return i[r]-i[s]}const t=i.length,n=new Array(t);for(let r=0;r!==t;++r)n[r]=r;return n.sort(e),n},sortedArray:function(i,e,t){const n=i.length,r=new i.constructor(n);for(let s=0,o=0;o!==n;++s){const a=t[s]*e;for(let l=0;l!==e;++l)r[o++]=i[a+l]}return r},flattenJSON:function(i,e,t,n){let r=1,s=i[0];for(;s!==void 0&&s[n]===void 0;)s=i[r++];if(s===void 0)return;let o=s[n];if(o!==void 0)if(Array.isArray(o))do o=s[n],o!==void 0&&(e.push(s.time),t.push.apply(t,o)),s=i[r++];while(s!==void 0);else if(o.toArray!==void 0)do o=s[n],o!==void 0&&(e.push(s.time),o.toArray(t,t.length)),s=i[r++];while(s!==void 0);else do o=s[n],o!==void 0&&(e.push(s.time),t.push(o)),s=i[r++];while(s!==void 0)},subclip:function(i,e,t,n,r=30){const s=i.clone();s.name=e;const o=[];for(let l=0;l=n)){h.push(c.times[d]);for(let v=0;vs.tracks[l].times[0]&&(a=s.tracks[l].times[0]);for(let l=0;l=a.times[g]){const m=g*h+u,p=m+h-u;v=p0.arraySlice(a.values,m,p)}else{const m=a.createInterpolant(),p=u,y=h-u;m.evaluate(s),v=p0.arraySlice(m.resultBuffer,p,y)}l==="quaternion"&&new S0().fromArray(v).normalize().conjugate().toArray(v);const _=c.times.length;for(let m=0;m<_;++m){const p=m*d+f;if(l==="quaternion")S0.multiplyQuaternionsFlat(c.values,p,v,0,c.values,p);else{const y=d-f*2;for(let x=0;x=s)){const a=t[1];e=s)break t}o=n,n=0;break n}break e}for(;n>>1;et;)--o;if(++o,s!==0||o!==r){s>=o&&(o=Math.max(o,1),s=o-1);const a=this.getValueSize();this.times=p0.arraySlice(n,s,o),this.values=p0.arraySlice(this.values,s*a,o*a)}return this}validate(){let e=!0;const t=this.getValueSize();t-Math.floor(t)!==0&&(console.error("THREE.KeyframeTrack: Invalid value size in track.",this),e=!1);const n=this.times,r=this.values,s=n.length;s===0&&(console.error("THREE.KeyframeTrack: Track is empty.",this),e=!1);let o=null;for(let a=0;a!==s;a++){const l=n[a];if(typeof l=="number"&&isNaN(l)){console.error("THREE.KeyframeTrack: Time is not a valid number.",this,a,l),e=!1;break}if(o!==null&&o>l){console.error("THREE.KeyframeTrack: Out of order keys.",this,a,l,o),e=!1;break}o=l}if(r!==void 0&&p0.isTypedArray(r))for(let a=0,l=r.length;a!==l;++a){const c=r[a];if(isNaN(c)){console.error("THREE.KeyframeTrack: Value is not a valid number.",this,a,c),e=!1;break}}return e}optimize(){const e=p0.arraySlice(this.times),t=p0.arraySlice(this.values),n=this.getValueSize(),r=this.getInterpolation()===Vl,s=e.length-1;let o=1;for(let a=1;a0){e[o]=e[s];for(let a=s*n,l=o*n,c=0;c!==n;++c)t[l+c]=t[a+c];++o}return o!==e.length?(this.times=p0.arraySlice(e,0,o),this.values=p0.arraySlice(t,0,o*n)):(this.times=e,this.values=t),this}clone(){const e=p0.arraySlice(this.times,0),t=p0.arraySlice(this.values,0),n=this.constructor,r=new n(this.name,e,t);return r.createInterpolant=this.createInterpolant,r}}Jt.prototype.TimeBufferType=Float32Array;Jt.prototype.ValueBufferType=Float32Array;Jt.prototype.DefaultInterpolation=Nr;class is extends Jt{}is.prototype.ValueTypeName="bool";is.prototype.ValueBufferType=Array;is.prototype.DefaultInterpolation=lo;is.prototype.InterpolantFactoryMethodLinear=void 0;is.prototype.InterpolantFactoryMethodSmooth=void 0;class b5 extends Jt{}b5.prototype.ValueTypeName="color";class zr extends Jt{}zr.prototype.ValueTypeName="number";class aM extends gn{constructor(e,t,n,r){super(e,t,n,r)}interpolate_(e,t,n,r){const s=this.resultBuffer,o=this.sampleValues,a=this.valueSize,l=(n-t)/(r-t);let c=e*a;for(let u=c+a;c!==u;c+=4)S0.slerpFlat(s,0,o,c-a,o,c,l);return s}}class ei extends Jt{InterpolantFactoryMethodLinear(e){return new aM(this.times,this.values,this.getValueSize(),e)}}ei.prototype.ValueTypeName="quaternion";ei.prototype.DefaultInterpolation=Nr;ei.prototype.InterpolantFactoryMethodSmooth=void 0;class rs extends Jt{}rs.prototype.ValueTypeName="string";rs.prototype.ValueBufferType=Array;rs.prototype.DefaultInterpolation=lo;rs.prototype.InterpolantFactoryMethodLinear=void 0;rs.prototype.InterpolantFactoryMethodSmooth=void 0;class Br extends Jt{}Br.prototype.ValueTypeName="vector";class Qa{constructor(e,t=-1,n,r=qc){this.name=e,this.tracks=n,this.duration=t,this.blendMode=r,this.uuid=yt(),this.duration<0&&this.resetDuration()}static parse(e){const t=[],n=e.tracks,r=1/(e.fps||1);for(let o=0,a=n.length;o!==a;++o)t.push(cM(n[o]).scale(r));const s=new this(e.name,e.duration,t,e.blendMode);return s.uuid=e.uuid,s}static toJSON(e){const t=[],n=e.tracks,r={name:e.name,duration:e.duration,tracks:t,uuid:e.uuid,blendMode:e.blendMode};for(let s=0,o=n.length;s!==o;++s)t.push(Jt.toJSON(n[s]));return r}static CreateFromMorphTargetSequence(e,t,n,r){const s=t.length,o=[];for(let a=0;a1){const h=u[1];let f=r[h];f||(r[h]=f=[]),f.push(c)}}const o=[];for(const a in r)o.push(this.CreateFromMorphTargetSequence(a,r[a],t,n));return o}static parseAnimation(e,t){if(!e)return console.error("THREE.AnimationClip: No animation in JSONLoader data."),null;const n=function(h,f,d,g,v){if(d.length!==0){const _=[],m=[];p0.flattenJSON(d,_,m,g),_.length!==0&&v.push(new h(f,_,m))}},r=[],s=e.name||"default",o=e.fps||30,a=e.blendMode;let l=e.length||-1;const c=e.hierarchy||[];for(let h=0;h{t&&t(s),this.manager.itemEnd(e)},0),s;if(cn[e]!==void 0){cn[e].push({onLoad:t,onProgress:n,onError:r});return}cn[e]=[],cn[e].push({onLoad:t,onProgress:n,onError:r});const o=new Request(e,{headers:new Headers(this.requestHeader),credentials:this.withCredentials?"include":"same-origin"});fetch(o).then(a=>{if(a.status===200||a.status===0){a.status===0&&console.warn("THREE.FileLoader: HTTP Status 0 received.");const l=cn[e],c=a.body.getReader(),u=a.headers.get("Content-Length"),h=u?parseInt(u):0,f=h!==0;let d=0;return new ReadableStream({start(g){v();function v(){c.read().then(({done:_,value:m})=>{if(_)g.close();else{d+=m.byteLength;const p=new ProgressEvent("progress",{lengthComputable:f,loaded:d,total:h});for(let y=0,x=l.length;y{const l=new Response(a);switch(this.responseType){case"arraybuffer":return l.arrayBuffer();case"blob":return l.blob();case"document":return l.text().then(c=>new DOMParser().parseFromString(c,this.mimeType));case"json":return l.json();default:return l.text()}}).then(a=>{kr.add(e,a);const l=cn[e];delete cn[e];for(let c=0,u=l.length;c{const l=cn[e];delete cn[e];for(let c=0,u=l.length;c"u"&&console.warn("THREE.ImageBitmapLoader: createImageBitmap() not supported."),typeof fetch>"u"&&console.warn("THREE.ImageBitmapLoader: fetch() not supported."),this.options={premultiplyAlpha:"none"}}setOptions(e){return this.options=e,this}load(e,t,n,r){e===void 0&&(e=""),this.path!==void 0&&(e=this.path+e),e=this.manager.resolveURL(e);const s=this,o=kr.get(e);if(o!==void 0)return s.manager.itemStart(e),setTimeout(function(){t&&t(o),s.manager.itemEnd(e)},0),o;const a={};a.credentials=this.crossOrigin==="anonymous"?"same-origin":"include",a.headers=this.requestHeader,fetch(e,a).then(function(l){return l.blob()}).then(function(l){return createImageBitmap(l,Object.assign(s.options,{colorSpaceConversion:"none"}))}).then(function(l){kr.add(e,l),t&&t(l),s.manager.itemEnd(e)}).catch(function(l){r&&r(l),s.manager.itemError(e),s.manager.itemEnd(e)}),s.manager.itemStart(e)}}C5.prototype.isImageBitmapLoader=!0;let xa;const dM={getContext:function(){return xa===void 0&&(xa=new(window.AudioContext||window.webkitAudioContext)),xa},setContext:function(i){xa=i}};class pM extends Bt{constructor(e){super(e)}load(e,t,n,r){const s=this,o=new Po(this.manager);o.setResponseType("arraybuffer"),o.setPath(this.path),o.setRequestHeader(this.requestHeader),o.setWithCredentials(this.withCredentials),o.load(e,function(a){try{const l=a.slice(0);dM.getContext().decodeAudioData(l,function(u){t(u)})}catch(l){r?r(l):console.error(l),s.manager.itemError(e)}},n,r)}}class mM extends x9{constructor(e,t,n=1){super(void 0,n);const r=new be().set(e),s=new be().set(t),o=new P(r.r,r.g,r.b),a=new P(s.r,s.g,s.b),l=Math.sqrt(Math.PI),c=l*Math.sqrt(.75);this.sh.coefficients[0].copy(o).add(a).multiplyScalar(l),this.sh.coefficients[1].copy(o).sub(a).multiplyScalar(c)}}mM.prototype.isHemisphereLightProbe=!0;class gM extends x9{constructor(e,t=1){super(void 0,t);const n=new be().set(e);this.sh.coefficients[0].set(n.r,n.g,n.b).multiplyScalar(2*Math.sqrt(Math.PI))}}gM.prototype.isAmbientLightProbe=!0;class vM{constructor(e=!0){this.autoStart=e,this.startTime=0,this.oldTime=0,this.elapsedTime=0,this.running=!1}start(){this.startTime=g3(),this.oldTime=this.startTime,this.elapsedTime=0,this.running=!0}stop(){this.getElapsedTime(),this.running=!1,this.autoStart=!1}getElapsedTime(){return this.getDelta(),this.elapsedTime}getDelta(){let e=0;if(this.autoStart&&!this.running)return this.start(),0;if(this.running){const t=g3();e=(t-this.oldTime)/1e3,this.oldTime=t,this.elapsedTime+=e}return e}}function g3(){return(typeof performance>"u"?Date:performance).now()}class xM extends t0{constructor(e){super(),this.type="Audio",this.listener=e,this.context=e.context,this.gain=this.context.createGain(),this.gain.connect(e.getInput()),this.autoplay=!1,this.buffer=null,this.detune=0,this.loop=!1,this.loopStart=0,this.loopEnd=0,this.offset=0,this.duration=void 0,this.playbackRate=1,this.isPlaying=!1,this.hasPlaybackControl=!0,this.source=null,this.sourceType="empty",this._startedAt=0,this._progress=0,this._connected=!1,this.filters=[]}getOutput(){return this.gain}setNodeSource(e){return this.hasPlaybackControl=!1,this.sourceType="audioNode",this.source=e,this.connect(),this}setMediaElementSource(e){return this.hasPlaybackControl=!1,this.sourceType="mediaNode",this.source=this.context.createMediaElementSource(e),this.connect(),this}setMediaStreamSource(e){return this.hasPlaybackControl=!1,this.sourceType="mediaStreamNode",this.source=this.context.createMediaStreamSource(e),this.connect(),this}setBuffer(e){return this.buffer=e,this.sourceType="buffer",this.autoplay&&this.play(),this}play(e=0){if(this.isPlaying===!0){console.warn("THREE.Audio: Audio is already playing.");return}if(this.hasPlaybackControl===!1){console.warn("THREE.Audio: this Audio has no playback control.");return}this._startedAt=this.context.currentTime+e;const t=this.context.createBufferSource();return t.buffer=this.buffer,t.loop=this.loop,t.loopStart=this.loopStart,t.loopEnd=this.loopEnd,t.onended=this.onEnded.bind(this),t.start(this._startedAt,this._progress+this.offset,this.duration),this.isPlaying=!0,this.source=t,this.setDetune(this.detune),this.setPlaybackRate(this.playbackRate),this.connect()}pause(){if(this.hasPlaybackControl===!1){console.warn("THREE.Audio: this Audio has no playback control.");return}return this.isPlaying===!0&&(this._progress+=Math.max(this.context.currentTime-this._startedAt,0)*this.playbackRate,this.loop===!0&&(this._progress=this._progress%(this.duration||this.buffer.duration)),this.source.stop(),this.source.onended=null,this.isPlaying=!1),this}stop(){if(this.hasPlaybackControl===!1){console.warn("THREE.Audio: this Audio has no playback control.");return}return this._progress=0,this.source.stop(),this.source.onended=null,this.isPlaying=!1,this}connect(){if(this.filters.length>0){this.source.connect(this.filters[0]);for(let e=1,t=this.filters.length;e0){this.source.disconnect(this.filters[0]);for(let e=1,t=this.filters.length;e0&&this._mixBufferRegionAdditive(n,r,this._addIndex*t,1,t);for(let l=t,c=t+t;l!==c;++l)if(n[l]!==n[l+t]){a.setValue(n,r);break}}saveOriginalState(){const e=this.binding,t=this.buffer,n=this.valueSize,r=n*this._origIndex;e.getValue(t,r);for(let s=n,o=r;s!==o;++s)t[s]=t[r+s%n];this._setIdentity(),this.cumulativeWeight=0,this.cumulativeWeightAdditive=0}restoreOriginalState(){const e=this.valueSize*3;this.binding.setValue(this.buffer,e)}_setAdditiveIdentityNumeric(){const e=this._addIndex*this.valueSize,t=e+this.valueSize;for(let n=e;n=.5)for(let o=0;o!==s;++o)e[t+o]=e[n+o]}_slerp(e,t,n,r){S0.slerpFlat(e,t,e,t,e,n,r)}_slerpAdditive(e,t,n,r,s){const o=this._workIndex*s;S0.multiplyQuaternionsFlat(e,o,e,t,e,n),S0.slerpFlat(e,t,e,t,e,o,r)}_lerp(e,t,n,r,s){const o=1-r;for(let a=0;a!==s;++a){const l=t+a;e[l]=e[l]*o+e[n+a]*r}}_lerpAdditive(e,t,n,r,s){for(let o=0;o!==s;++o){const a=t+o;e[a]=e[a]+e[n+o]*r}}}const y9="\\[\\]\\.:\\/",_M=new RegExp("["+y9+"]","g"),_9="[^"+y9+"]",bM="[^"+y9.replace("\\.","")+"]",wM=/((?:WC+[\/:])*)/.source.replace("WC",_9),MM=/(WCOD+)?/.source.replace("WCOD",bM),SM=/(?:\.(WC+)(?:\[(.+)\])?)?/.source.replace("WC",_9),TM=/\.(WC+)(?:\[(.+)\])?/.source.replace("WC",_9),AM=new RegExp("^"+wM+MM+SM+TM+"$"),EM=["material","materials","bones"];class LM{constructor(e,t,n){const r=n||Xe.parseTrackName(t);this._targetGroup=e,this._bindings=e.subscribe_(t,r)}getValue(e,t){this.bind();const n=this._targetGroup.nCachedObjects_,r=this._bindings[n];r!==void 0&&r.getValue(e,t)}setValue(e,t){const n=this._bindings;for(let r=this._targetGroup.nCachedObjects_,s=n.length;r!==s;++r)n[r].setValue(e,t)}bind(){const e=this._bindings;for(let t=this._targetGroup.nCachedObjects_,n=e.length;t!==n;++t)e[t].bind()}unbind(){const e=this._bindings;for(let t=this._targetGroup.nCachedObjects_,n=e.length;t!==n;++t)e[t].unbind()}}class Xe{constructor(e,t,n){this.path=t,this.parsedPath=n||Xe.parseTrackName(t),this.node=Xe.findNode(e,this.parsedPath.nodeName)||e,this.rootNode=e,this.getValue=this._getValue_unbound,this.setValue=this._setValue_unbound}static create(e,t,n){return e&&e.isAnimationObjectGroup?new Xe.Composite(e,t,n):new Xe(e,t,n)}static sanitizeNodeName(e){return e.replace(/\s/g,"_").replace(_M,"")}static parseTrackName(e){const t=AM.exec(e);if(!t)throw new Error("PropertyBinding: Cannot parse trackName: "+e);const n={nodeName:t[2],objectName:t[3],objectIndex:t[4],propertyName:t[5],propertyIndex:t[6]},r=n.nodeName&&n.nodeName.lastIndexOf(".");if(r!==void 0&&r!==-1){const s=n.nodeName.substring(r+1);EM.indexOf(s)!==-1&&(n.nodeName=n.nodeName.substring(0,r),n.objectName=s)}if(n.propertyName===null||n.propertyName.length===0)throw new Error("PropertyBinding: can not parse propertyName from trackName: "+e);return n}static findNode(e,t){if(!t||t===""||t==="."||t===-1||t===e.name||t===e.uuid)return e;if(e.skeleton){const n=e.skeleton.getBoneByName(t);if(n!==void 0)return n}if(e.children){const n=function(s){for(let o=0;o0){const l=this._interpolants,c=this._propertyBindings;switch(this.blendMode){case d4:for(let u=0,h=l.length;u!==h;++u)l[u].evaluate(o),c[u].accumulateAdditive(a);break;case qc:default:for(let u=0,h=l.length;u!==h;++u)l[u].evaluate(o),c[u].accumulate(r,a)}}}_updateWeight(e){let t=0;if(this.enabled){t=this.weight;const n=this._weightInterpolant;if(n!==null){const r=n.evaluate(e)[0];t*=r,e>n.parameterPositions[1]&&(this.stopFading(),r===0&&(this.enabled=!1))}}return this._effectiveWeight=t,t}_updateTimeScale(e){let t=0;if(!this.paused){t=this.timeScale;const n=this._timeScaleInterpolant;if(n!==null){const r=n.evaluate(e)[0];t*=r,e>n.parameterPositions[1]&&(this.stopWarping(),t===0?this.paused=!0:this.timeScale=t)}}return this._effectiveTimeScale=t,t}_updateTime(e){const t=this._clip.duration,n=this.loop;let r=this.time+e,s=this._loopCount;const o=n===fv;if(e===0)return s===-1?r:o&&(s&1)===1?t-r:r;if(n===uv){s===-1&&(this._loopCount=0,this._setEndings(!0,!0,!1));e:{if(r>=t)r=t;else if(r<0)r=0;else{this.time=r;break e}this.clampWhenFinished?this.paused=!0:this.enabled=!1,this.time=r,this._mixer.dispatchEvent({type:"finished",action:this,direction:e<0?-1:1})}}else{if(s===-1&&(e>=0?(s=0,this._setEndings(!0,this.repetitions===0,o)):this._setEndings(this.repetitions===0,!0,o)),r>=t||r<0){const a=Math.floor(r/t);r-=t*a,s+=Math.abs(a);const l=this.repetitions-s;if(l<=0)this.clampWhenFinished?this.paused=!0:this.enabled=!1,r=e>0?t:0,this.time=r,this._mixer.dispatchEvent({type:"finished",action:this,direction:e>0?1:-1});else{if(l===1){const c=e<0;this._setEndings(c,!c,o)}else this._setEndings(!1,!1,o);this._loopCount=s,this.time=r,this._mixer.dispatchEvent({type:"loop",action:this,loopDelta:a})}}else this.time=r;if(o&&(s&1)===1)return t-r}return r}_setEndings(e,t,n){const r=this._interpolantSettings;n?(r.endingStart=vr,r.endingEnd=vr):(e?r.endingStart=this.zeroSlopeAtStart?vr:gr:r.endingStart=Xa,t?r.endingEnd=this.zeroSlopeAtEnd?vr:gr:r.endingEnd=Xa)}_scheduleFading(e,t,n){const r=this._mixer,s=r.time;let o=this._weightInterpolant;o===null&&(o=r._lendControlInterpolant(),this._weightInterpolant=o);const a=o.parameterPositions,l=o.sampleValues;return a[0]=s,l[0]=t,a[1]=s+e,l[1]=n,this}}class CM extends ni{constructor(e){super(),this._root=e,this._initMemoryManager(),this._accuIndex=0,this.time=0,this.timeScale=1}_bindAction(e,t){const n=e._localRoot||this._root,r=e._clip.tracks,s=r.length,o=e._propertyBindings,a=e._interpolants,l=n.uuid,c=this._bindingsByRootAndName;let u=c[l];u===void 0&&(u={},c[l]=u);for(let h=0;h!==s;++h){const f=r[h],d=f.name;let g=u[d];if(g!==void 0)o[h]=g;else{if(g=o[h],g!==void 0){g._cacheIndex===null&&(++g.referenceCount,this._addInactiveBinding(g,l,d));continue}const v=t&&t._propertyBindings[h].binding.parsedPath;g=new yM(Xe.create(n,d,v),f.ValueTypeName,f.getValueSize()),++g.referenceCount,this._addInactiveBinding(g,l,d),o[h]=g}a[h].resultBuffer=g.buffer}}_activateAction(e){if(!this._isActiveAction(e)){if(e._cacheIndex===null){const n=(e._localRoot||this._root).uuid,r=e._clip.uuid,s=this._actionsByClip[r];this._bindAction(e,s&&s.knownActions[0]),this._addInactiveAction(e,r,n)}const t=e._propertyBindings;for(let n=0,r=t.length;n!==r;++n){const s=t[n];s.useCount++===0&&(this._lendBinding(s),s.saveOriginalState())}this._lendAction(e)}}_deactivateAction(e){if(this._isActiveAction(e)){const t=e._propertyBindings;for(let n=0,r=t.length;n!==r;++n){const s=t[n];--s.useCount===0&&(s.restoreOriginalState(),this._takeBackBinding(s))}this._takeBackAction(e)}}_initMemoryManager(){this._actions=[],this._nActiveActions=0,this._actionsByClip={},this._bindings=[],this._nActiveBindings=0,this._bindingsByRootAndName={},this._controlInterpolants=[],this._nActiveControlInterpolants=0;const e=this;this.stats={actions:{get total(){return e._actions.length},get inUse(){return e._nActiveActions}},bindings:{get total(){return e._bindings.length},get inUse(){return e._nActiveBindings}},controlInterpolants:{get total(){return e._controlInterpolants.length},get inUse(){return e._nActiveControlInterpolants}}}}_isActiveAction(e){const t=e._cacheIndex;return t!==null&&t=0;--n)e[n].stop();return this}update(e){e*=this.timeScale;const t=this._actions,n=this._nActiveActions,r=this.time+=e,s=Math.sign(e),o=this._accuIndex^=1;for(let c=0;c!==n;++c)t[c]._update(r,e,s,o);const a=this._bindings,l=this._nActiveBindings;for(let c=0;c!==l;++c)a[c].apply(o);return this}setTime(e){this.time=0;for(let t=0;tNumber.EPSILON){if(C<0&&(L=y[b],I=-I,B=y[A],C=-C),p.yB.y)continue;if(p.y===L.y){if(p.x===L.x)return!0}else{const Y=C*(p.x-L.x)-I*(p.y-L.y);if(Y===0)return!0;if(Y<0)continue;w=!w}}else{if(p.y!==L.y)continue;if(B.x<=p.x&&p.x<=L.x||L.x<=p.x&&p.x<=B.x)return!0}}return w}const s=mn.isClockWise,o=this.subPaths;if(o.length===0)return[];if(t===!0)return n(o);let a,l,c;const u=[];if(o.length===1)return l=o[0],c=new jn,c.curves=l.curves,u.push(c),u;let h=!s(o[0].getPoints());h=e?!h:h;const f=[],d=[];let g=[],v=0,_;d[v]=void 0,g[v]=[];for(let p=0,y=o.length;p1){let p=!1;const y=[];for(let x=0,w=d.length;x0&&(p||(g=f))}let m;for(let p=0,y=d.length;p65504&&(console.warn("THREE.DataUtils.toHalfFloat(): value exceeds 65504."),e=65504),F5[0]=e;const t=OM[0];let n=t>>16&32768,r=t>>12&2047;const s=t>>23&255;return s<103?n:s>142?(n|=31744,n|=(s==255?0:1)&&t&8388607,n):s<113?(r|=2048,n|=(r>>114-s)+(r>>113-s&1),n):(n|=s-112<<10|r>>1,n+=r&1,n)}}ut.create=function(i,e){return console.log("THREE.Curve.create() has been deprecated"),i.prototype=Object.create(ut.prototype),i.prototype.constructor=i,i.prototype.getPoint=e,i};qa.prototype.fromPoints=function(i){return console.warn("THREE.Path: .fromPoints() has been renamed to .setFromPoints()."),this.setFromPoints(i)};DM.prototype.setColors=function(){console.error("THREE.GridHelper: setColors() has been deprecated, pass them in the constructor instead.")};IM.prototype.update=function(){console.error("THREE.SkeletonHelper: update() no longer needs to be called.")};Bt.prototype.extractUrlBase=function(i){return console.warn("THREE.Loader: .extractUrlBase() has been deprecated. Use THREE.LoaderUtils.extractUrlBase() instead."),Ut.extractUrlBase(i)};Bt.Handlers={add:function(){console.error("THREE.Loader: Handlers.add() has been removed. Use LoadingManager.addHandler() instead.")},get:function(){console.error("THREE.Loader: Handlers.get() has been removed. Use LoadingManager.getHandler() instead.")}};Mt.prototype.center=function(i){return console.warn("THREE.Box3: .center() has been renamed to .getCenter()."),this.getCenter(i)};Mt.prototype.empty=function(){return console.warn("THREE.Box3: .empty() has been renamed to .isEmpty()."),this.isEmpty()};Mt.prototype.isIntersectionBox=function(i){return console.warn("THREE.Box3: .isIntersectionBox() has been renamed to .intersectsBox()."),this.intersectsBox(i)};Mt.prototype.isIntersectionSphere=function(i){return console.warn("THREE.Box3: .isIntersectionSphere() has been renamed to .intersectsSphere()."),this.intersectsSphere(i)};Mt.prototype.size=function(i){return console.warn("THREE.Box3: .size() has been renamed to .getSize()."),this.getSize(i)};Ui.prototype.empty=function(){return console.warn("THREE.Sphere: .empty() has been renamed to .isEmpty()."),this.isEmpty()};wl.prototype.setFromMatrix=function(i){return console.warn("THREE.Frustum: .setFromMatrix() has been renamed to .setFromProjectionMatrix()."),this.setFromProjectionMatrix(i)};B0.prototype.flattenToArrayOffset=function(i,e){return console.warn("THREE.Matrix3: .flattenToArrayOffset() has been deprecated. Use .toArray() instead."),this.toArray(i,e)};B0.prototype.multiplyVector3=function(i){return console.warn("THREE.Matrix3: .multiplyVector3() has been removed. Use vector.applyMatrix3( matrix ) instead."),i.applyMatrix3(this)};B0.prototype.multiplyVector3Array=function(){console.error("THREE.Matrix3: .multiplyVector3Array() has been removed.")};B0.prototype.applyToBufferAttribute=function(i){return console.warn("THREE.Matrix3: .applyToBufferAttribute() has been removed. Use attribute.applyMatrix3( matrix ) instead."),i.applyMatrix3(this)};B0.prototype.applyToVector3Array=function(){console.error("THREE.Matrix3: .applyToVector3Array() has been removed.")};B0.prototype.getInverse=function(i){return console.warn("THREE.Matrix3: .getInverse() has been removed. Use matrixInv.copy( matrix ).invert(); instead."),this.copy(i).invert()};Me.prototype.extractPosition=function(i){return console.warn("THREE.Matrix4: .extractPosition() has been renamed to .copyPosition()."),this.copyPosition(i)};Me.prototype.flattenToArrayOffset=function(i,e){return console.warn("THREE.Matrix4: .flattenToArrayOffset() has been deprecated. Use .toArray() instead."),this.toArray(i,e)};Me.prototype.getPosition=function(){return console.warn("THREE.Matrix4: .getPosition() has been removed. Use Vector3.setFromMatrixPosition( matrix ) instead."),new P().setFromMatrixColumn(this,3)};Me.prototype.setRotationFromQuaternion=function(i){return console.warn("THREE.Matrix4: .setRotationFromQuaternion() has been renamed to .makeRotationFromQuaternion()."),this.makeRotationFromQuaternion(i)};Me.prototype.multiplyToArray=function(){console.warn("THREE.Matrix4: .multiplyToArray() has been removed.")};Me.prototype.multiplyVector3=function(i){return console.warn("THREE.Matrix4: .multiplyVector3() has been removed. Use vector.applyMatrix4( matrix ) instead."),i.applyMatrix4(this)};Me.prototype.multiplyVector4=function(i){return console.warn("THREE.Matrix4: .multiplyVector4() has been removed. Use vector.applyMatrix4( matrix ) instead."),i.applyMatrix4(this)};Me.prototype.multiplyVector3Array=function(){console.error("THREE.Matrix4: .multiplyVector3Array() has been removed.")};Me.prototype.rotateAxis=function(i){console.warn("THREE.Matrix4: .rotateAxis() has been removed. Use Vector3.transformDirection( matrix ) instead."),i.transformDirection(this)};Me.prototype.crossVector=function(i){return console.warn("THREE.Matrix4: .crossVector() has been removed. Use vector.applyMatrix4( matrix ) instead."),i.applyMatrix4(this)};Me.prototype.translate=function(){console.error("THREE.Matrix4: .translate() has been removed.")};Me.prototype.rotateX=function(){console.error("THREE.Matrix4: .rotateX() has been removed.")};Me.prototype.rotateY=function(){console.error("THREE.Matrix4: .rotateY() has been removed.")};Me.prototype.rotateZ=function(){console.error("THREE.Matrix4: .rotateZ() has been removed.")};Me.prototype.rotateByAxis=function(){console.error("THREE.Matrix4: .rotateByAxis() has been removed.")};Me.prototype.applyToBufferAttribute=function(i){return console.warn("THREE.Matrix4: .applyToBufferAttribute() has been removed. Use attribute.applyMatrix4( matrix ) instead."),i.applyMatrix4(this)};Me.prototype.applyToVector3Array=function(){console.error("THREE.Matrix4: .applyToVector3Array() has been removed.")};Me.prototype.makeFrustum=function(i,e,t,n,r,s){return console.warn("THREE.Matrix4: .makeFrustum() has been removed. Use .makePerspective( left, right, top, bottom, near, far ) instead."),this.makePerspective(i,e,n,t,r,s)};Me.prototype.getInverse=function(i){return console.warn("THREE.Matrix4: .getInverse() has been removed. Use matrixInv.copy( matrix ).invert(); instead."),this.copy(i).invert()};Xt.prototype.isIntersectionLine=function(i){return console.warn("THREE.Plane: .isIntersectionLine() has been renamed to .intersectsLine()."),this.intersectsLine(i)};S0.prototype.multiplyVector3=function(i){return console.warn("THREE.Quaternion: .multiplyVector3() has been removed. Use is now vector.applyQuaternion( quaternion ) instead."),i.applyQuaternion(this)};S0.prototype.inverse=function(){return console.warn("THREE.Quaternion: .inverse() has been renamed to invert()."),this.invert()};zi.prototype.isIntersectionBox=function(i){return console.warn("THREE.Ray: .isIntersectionBox() has been renamed to .intersectsBox()."),this.intersectsBox(i)};zi.prototype.isIntersectionPlane=function(i){return console.warn("THREE.Ray: .isIntersectionPlane() has been renamed to .intersectsPlane()."),this.intersectsPlane(i)};zi.prototype.isIntersectionSphere=function(i){return console.warn("THREE.Ray: .isIntersectionSphere() has been renamed to .intersectsSphere()."),this.intersectsSphere(i)};R0.prototype.area=function(){return console.warn("THREE.Triangle: .area() has been renamed to .getArea()."),this.getArea()};R0.prototype.barycoordFromPoint=function(i,e){return console.warn("THREE.Triangle: .barycoordFromPoint() has been renamed to .getBarycoord()."),this.getBarycoord(i,e)};R0.prototype.midpoint=function(i){return console.warn("THREE.Triangle: .midpoint() has been renamed to .getMidpoint()."),this.getMidpoint(i)};R0.prototypenormal=function(i){return console.warn("THREE.Triangle: .normal() has been renamed to .getNormal()."),this.getNormal(i)};R0.prototype.plane=function(i){return console.warn("THREE.Triangle: .plane() has been renamed to .getPlane()."),this.getPlane(i)};R0.barycoordFromPoint=function(i,e,t,n,r){return console.warn("THREE.Triangle: .barycoordFromPoint() has been renamed to .getBarycoord()."),R0.getBarycoord(i,e,t,n,r)};R0.normal=function(i,e,t,n){return console.warn("THREE.Triangle: .normal() has been renamed to .getNormal()."),R0.getNormal(i,e,t,n)};jn.prototype.extractAllPoints=function(i){return console.warn("THREE.Shape: .extractAllPoints() has been removed. Use .extractPoints() instead."),this.extractPoints(i)};jn.prototype.extrude=function(i){return console.warn("THREE.Shape: .extrude() has been removed. Use ExtrudeGeometry() instead."),new ts(this,i)};jn.prototype.makeGeometry=function(i){return console.warn("THREE.Shape: .makeGeometry() has been removed. Use ShapeGeometry() instead."),new c5(this,i)};ee.prototype.fromAttribute=function(i,e,t){return console.warn("THREE.Vector2: .fromAttribute() has been renamed to .fromBufferAttribute()."),this.fromBufferAttribute(i,e,t)};ee.prototype.distanceToManhattan=function(i){return console.warn("THREE.Vector2: .distanceToManhattan() has been renamed to .manhattanDistanceTo()."),this.manhattanDistanceTo(i)};ee.prototype.lengthManhattan=function(){return console.warn("THREE.Vector2: .lengthManhattan() has been renamed to .manhattanLength()."),this.manhattanLength()};P.prototype.setEulerFromRotationMatrix=function(){console.error("THREE.Vector3: .setEulerFromRotationMatrix() has been removed. Use Euler.setFromRotationMatrix() instead.")};P.prototype.setEulerFromQuaternion=function(){console.error("THREE.Vector3: .setEulerFromQuaternion() has been removed. Use Euler.setFromQuaternion() instead.")};P.prototype.getPositionFromMatrix=function(i){return console.warn("THREE.Vector3: .getPositionFromMatrix() has been renamed to .setFromMatrixPosition()."),this.setFromMatrixPosition(i)};P.prototype.getScaleFromMatrix=function(i){return console.warn("THREE.Vector3: .getScaleFromMatrix() has been renamed to .setFromMatrixScale()."),this.setFromMatrixScale(i)};P.prototype.getColumnFromMatrix=function(i,e){return console.warn("THREE.Vector3: .getColumnFromMatrix() has been renamed to .setFromMatrixColumn()."),this.setFromMatrixColumn(e,i)};P.prototype.applyProjection=function(i){return console.warn("THREE.Vector3: .applyProjection() has been removed. Use .applyMatrix4( m ) instead."),this.applyMatrix4(i)};P.prototype.fromAttribute=function(i,e,t){return console.warn("THREE.Vector3: .fromAttribute() has been renamed to .fromBufferAttribute()."),this.fromBufferAttribute(i,e,t)};P.prototype.distanceToManhattan=function(i){return console.warn("THREE.Vector3: .distanceToManhattan() has been renamed to .manhattanDistanceTo()."),this.manhattanDistanceTo(i)};P.prototype.lengthManhattan=function(){return console.warn("THREE.Vector3: .lengthManhattan() has been renamed to .manhattanLength()."),this.manhattanLength()};$e.prototype.fromAttribute=function(i,e,t){return console.warn("THREE.Vector4: .fromAttribute() has been renamed to .fromBufferAttribute()."),this.fromBufferAttribute(i,e,t)};$e.prototype.lengthManhattan=function(){return console.warn("THREE.Vector4: .lengthManhattan() has been renamed to .manhattanLength()."),this.manhattanLength()};t0.prototype.getChildByName=function(i){return console.warn("THREE.Object3D: .getChildByName() has been renamed to .getObjectByName()."),this.getObjectByName(i)};t0.prototype.renderDepth=function(){console.warn("THREE.Object3D: .renderDepth has been removed. Use .renderOrder, instead.")};t0.prototype.translate=function(i,e){return console.warn("THREE.Object3D: .translate() has been removed. Use .translateOnAxis( axis, distance ) instead."),this.translateOnAxis(e,i)};t0.prototype.getWorldRotation=function(){console.error("THREE.Object3D: .getWorldRotation() has been removed. Use THREE.Object3D.getWorldQuaternion( target ) instead.")};t0.prototype.applyMatrix=function(i){return console.warn("THREE.Object3D: .applyMatrix() has been renamed to .applyMatrix4()."),this.applyMatrix4(i)};Object.defineProperties(t0.prototype,{eulerOrder:{get:function(){return console.warn("THREE.Object3D: .eulerOrder is now .rotation.order."),this.rotation.order},set:function(i){console.warn("THREE.Object3D: .eulerOrder is now .rotation.order."),this.rotation.order=i}},useQuaternion:{get:function(){console.warn("THREE.Object3D: .useQuaternion has been removed. The library now uses quaternions by default.")},set:function(){console.warn("THREE.Object3D: .useQuaternion has been removed. The library now uses quaternions by default.")}}});I0.prototype.setDrawMode=function(){console.error("THREE.Mesh: .setDrawMode() has been removed. The renderer now always assumes THREE.TrianglesDrawMode. Transform your geometry via BufferGeometryUtils.toTrianglesDrawMode() if necessary.")};Object.defineProperties(I0.prototype,{drawMode:{get:function(){return console.error("THREE.Mesh: .drawMode has been removed. The renderer now always assumes THREE.TrianglesDrawMode."),dv},set:function(){console.error("THREE.Mesh: .drawMode has been removed. The renderer now always assumes THREE.TrianglesDrawMode. Transform your geometry via BufferGeometryUtils.toTrianglesDrawMode() if necessary.")}}});Sl.prototype.initBones=function(){console.error("THREE.SkinnedMesh: initBones() has been removed.")};X0.prototype.setLens=function(i,e){console.warn("THREE.PerspectiveCamera.setLens is deprecated. Use .setFocalLength and .filmGauge for a photographic setup."),e!==void 0&&(this.filmGauge=e),this.setFocalLength(i)};Object.defineProperties(Zt.prototype,{onlyShadow:{set:function(){console.warn("THREE.Light: .onlyShadow has been removed.")}},shadowCameraFov:{set:function(i){console.warn("THREE.Light: .shadowCameraFov is now .shadow.camera.fov."),this.shadow.camera.fov=i}},shadowCameraLeft:{set:function(i){console.warn("THREE.Light: .shadowCameraLeft is now .shadow.camera.left."),this.shadow.camera.left=i}},shadowCameraRight:{set:function(i){console.warn("THREE.Light: .shadowCameraRight is now .shadow.camera.right."),this.shadow.camera.right=i}},shadowCameraTop:{set:function(i){console.warn("THREE.Light: .shadowCameraTop is now .shadow.camera.top."),this.shadow.camera.top=i}},shadowCameraBottom:{set:function(i){console.warn("THREE.Light: .shadowCameraBottom is now .shadow.camera.bottom."),this.shadow.camera.bottom=i}},shadowCameraNear:{set:function(i){console.warn("THREE.Light: .shadowCameraNear is now .shadow.camera.near."),this.shadow.camera.near=i}},shadowCameraFar:{set:function(i){console.warn("THREE.Light: .shadowCameraFar is now .shadow.camera.far."),this.shadow.camera.far=i}},shadowCameraVisible:{set:function(){console.warn("THREE.Light: .shadowCameraVisible has been removed. Use new THREE.CameraHelper( light.shadow.camera ) instead.")}},shadowBias:{set:function(i){console.warn("THREE.Light: .shadowBias is now .shadow.bias."),this.shadow.bias=i}},shadowDarkness:{set:function(){console.warn("THREE.Light: .shadowDarkness has been removed.")}},shadowMapWidth:{set:function(i){console.warn("THREE.Light: .shadowMapWidth is now .shadow.mapSize.width."),this.shadow.mapSize.width=i}},shadowMapHeight:{set:function(i){console.warn("THREE.Light: .shadowMapHeight is now .shadow.mapSize.height."),this.shadow.mapSize.height=i}}});Object.defineProperties(_0.prototype,{length:{get:function(){return console.warn("THREE.BufferAttribute: .length has been deprecated. Use .count instead."),this.array.length}},dynamic:{get:function(){return console.warn("THREE.BufferAttribute: .dynamic has been deprecated. Use .usage instead."),this.usage===ja},set:function(){console.warn("THREE.BufferAttribute: .dynamic has been deprecated. Use .usage instead."),this.setUsage(ja)}}});_0.prototype.setDynamic=function(i){return console.warn("THREE.BufferAttribute: .setDynamic() has been deprecated. Use .setUsage() instead."),this.setUsage(i===!0?ja:co),this};_0.prototype.copyIndicesArray=function(){console.error("THREE.BufferAttribute: .copyIndicesArray() has been removed.")},_0.prototype.setArray=function(){console.error("THREE.BufferAttribute: .setArray has been removed. Use BufferGeometry .setAttribute to replace/resize attribute buffers")};Fe.prototype.addIndex=function(i){console.warn("THREE.BufferGeometry: .addIndex() has been renamed to .setIndex()."),this.setIndex(i)};Fe.prototype.addAttribute=function(i,e){return console.warn("THREE.BufferGeometry: .addAttribute() has been renamed to .setAttribute()."),!(e&&e.isBufferAttribute)&&!(e&&e.isInterleavedBufferAttribute)?(console.warn("THREE.BufferGeometry: .addAttribute() now expects ( name, attribute )."),this.setAttribute(i,new _0(arguments[1],arguments[2]))):i==="index"?(console.warn("THREE.BufferGeometry.addAttribute: Use .setIndex() for index attribute."),this.setIndex(e),this):this.setAttribute(i,e)};Fe.prototype.addDrawCall=function(i,e,t){t!==void 0&&console.warn("THREE.BufferGeometry: .addDrawCall() no longer supports indexOffset."),console.warn("THREE.BufferGeometry: .addDrawCall() is now .addGroup()."),this.addGroup(i,e)};Fe.prototype.clearDrawCalls=function(){console.warn("THREE.BufferGeometry: .clearDrawCalls() is now .clearGroups()."),this.clearGroups()};Fe.prototype.computeOffsets=function(){console.warn("THREE.BufferGeometry: .computeOffsets() has been removed.")};Fe.prototype.removeAttribute=function(i){return console.warn("THREE.BufferGeometry: .removeAttribute() has been renamed to .deleteAttribute()."),this.deleteAttribute(i)};Fe.prototype.applyMatrix=function(i){return console.warn("THREE.BufferGeometry: .applyMatrix() has been renamed to .applyMatrix4()."),this.applyMatrix4(i)};Object.defineProperties(Fe.prototype,{drawcalls:{get:function(){return console.error("THREE.BufferGeometry: .drawcalls has been renamed to .groups."),this.groups}},offsets:{get:function(){return console.warn("THREE.BufferGeometry: .offsets has been renamed to .groups."),this.groups}}});$r.prototype.setDynamic=function(i){return console.warn("THREE.InterleavedBuffer: .setDynamic() has been deprecated. Use .setUsage() instead."),this.setUsage(i===!0?ja:co),this};$r.prototype.setArray=function(){console.error("THREE.InterleavedBuffer: .setArray has been removed. Use BufferGeometry .setAttribute to replace/resize attribute buffers")};ts.prototype.getArrays=function(){console.error("THREE.ExtrudeGeometry: .getArrays() has been removed.")};ts.prototype.addShapeList=function(){console.error("THREE.ExtrudeGeometry: .addShapeList() has been removed.")};ts.prototype.addShape=function(){console.error("THREE.ExtrudeGeometry: .addShape() has been removed.")};o9.prototype.dispose=function(){console.error("THREE.Scene: .dispose() has been removed.")};Object.defineProperties(D0.prototype,{wrapAround:{get:function(){console.warn("THREE.Material: .wrapAround has been removed.")},set:function(){console.warn("THREE.Material: .wrapAround has been removed.")}},overdraw:{get:function(){console.warn("THREE.Material: .overdraw has been removed.")},set:function(){console.warn("THREE.Material: .overdraw has been removed.")}},wrapRGB:{get:function(){return console.warn("THREE.Material: .wrapRGB has been removed."),new be}},shading:{get:function(){console.error("THREE."+this.type+": .shading has been removed. Use the boolean .flatShading instead.")},set:function(i){console.warn("THREE."+this.type+": .shading has been removed. Use the boolean .flatShading instead."),this.flatShading=i===o4}},stencilMask:{get:function(){return console.warn("THREE."+this.type+": .stencilMask has been removed. Use .stencilFuncMask instead."),this.stencilFuncMask},set:function(i){console.warn("THREE."+this.type+": .stencilMask has been removed. Use .stencilFuncMask instead."),this.stencilFuncMask=i}},vertexTangents:{get:function(){console.warn("THREE."+this.type+": .vertexTangents has been removed.")},set:function(){console.warn("THREE."+this.type+": .vertexTangents has been removed.")}}});Object.defineProperties(u0.prototype,{derivatives:{get:function(){return console.warn("THREE.ShaderMaterial: .derivatives has been moved to .extensions.derivatives."),this.extensions.derivatives},set:function(i){console.warn("THREE. ShaderMaterial: .derivatives has been moved to .extensions.derivatives."),this.extensions.derivatives=i}}});o0.prototype.clearTarget=function(i,e,t,n){console.warn("THREE.WebGLRenderer: .clearTarget() has been deprecated. Use .setRenderTarget() and .clear() instead."),this.setRenderTarget(i),this.clear(e,t,n)};o0.prototype.animate=function(i){console.warn("THREE.WebGLRenderer: .animate() is now .setAnimationLoop()."),this.setAnimationLoop(i)};o0.prototype.getCurrentRenderTarget=function(){return console.warn("THREE.WebGLRenderer: .getCurrentRenderTarget() is now .getRenderTarget()."),this.getRenderTarget()};o0.prototype.getMaxAnisotropy=function(){return console.warn("THREE.WebGLRenderer: .getMaxAnisotropy() is now .capabilities.getMaxAnisotropy()."),this.capabilities.getMaxAnisotropy()};o0.prototype.getPrecision=function(){return console.warn("THREE.WebGLRenderer: .getPrecision() is now .capabilities.precision."),this.capabilities.precision};o0.prototype.resetGLState=function(){return console.warn("THREE.WebGLRenderer: .resetGLState() is now .state.reset()."),this.state.reset()};o0.prototype.supportsFloatTextures=function(){return console.warn("THREE.WebGLRenderer: .supportsFloatTextures() is now .extensions.get( 'OES_texture_float' )."),this.extensions.get("OES_texture_float")};o0.prototype.supportsHalfFloatTextures=function(){return console.warn("THREE.WebGLRenderer: .supportsHalfFloatTextures() is now .extensions.get( 'OES_texture_half_float' )."),this.extensions.get("OES_texture_half_float")};o0.prototype.supportsStandardDerivatives=function(){return console.warn("THREE.WebGLRenderer: .supportsStandardDerivatives() is now .extensions.get( 'OES_standard_derivatives' )."),this.extensions.get("OES_standard_derivatives")};o0.prototype.supportsCompressedTextureS3TC=function(){return console.warn("THREE.WebGLRenderer: .supportsCompressedTextureS3TC() is now .extensions.get( 'WEBGL_compressed_texture_s3tc' )."),this.extensions.get("WEBGL_compressed_texture_s3tc")};o0.prototype.supportsCompressedTexturePVRTC=function(){return console.warn("THREE.WebGLRenderer: .supportsCompressedTexturePVRTC() is now .extensions.get( 'WEBGL_compressed_texture_pvrtc' )."),this.extensions.get("WEBGL_compressed_texture_pvrtc")};o0.prototype.supportsBlendMinMax=function(){return console.warn("THREE.WebGLRenderer: .supportsBlendMinMax() is now .extensions.get( 'EXT_blend_minmax' )."),this.extensions.get("EXT_blend_minmax")};o0.prototype.supportsVertexTextures=function(){return console.warn("THREE.WebGLRenderer: .supportsVertexTextures() is now .capabilities.vertexTextures."),this.capabilities.vertexTextures};o0.prototype.supportsInstancedArrays=function(){return console.warn("THREE.WebGLRenderer: .supportsInstancedArrays() is now .extensions.get( 'ANGLE_instanced_arrays' )."),this.extensions.get("ANGLE_instanced_arrays")};o0.prototype.enableScissorTest=function(i){console.warn("THREE.WebGLRenderer: .enableScissorTest() is now .setScissorTest()."),this.setScissorTest(i)};o0.prototype.initMaterial=function(){console.warn("THREE.WebGLRenderer: .initMaterial() has been removed.")};o0.prototype.addPrePlugin=function(){console.warn("THREE.WebGLRenderer: .addPrePlugin() has been removed.")};o0.prototype.addPostPlugin=function(){console.warn("THREE.WebGLRenderer: .addPostPlugin() has been removed.")};o0.prototype.updateShadowMap=function(){console.warn("THREE.WebGLRenderer: .updateShadowMap() has been removed.")};o0.prototype.setFaceCulling=function(){console.warn("THREE.WebGLRenderer: .setFaceCulling() has been removed.")};o0.prototype.allocTextureUnit=function(){console.warn("THREE.WebGLRenderer: .allocTextureUnit() has been removed.")};o0.prototype.setTexture=function(){console.warn("THREE.WebGLRenderer: .setTexture() has been removed.")};o0.prototype.setTexture2D=function(){console.warn("THREE.WebGLRenderer: .setTexture2D() has been removed.")};o0.prototype.setTextureCube=function(){console.warn("THREE.WebGLRenderer: .setTextureCube() has been removed.")};o0.prototype.getActiveMipMapLevel=function(){return console.warn("THREE.WebGLRenderer: .getActiveMipMapLevel() is now .getActiveMipmapLevel()."),this.getActiveMipmapLevel()};Object.defineProperties(o0.prototype,{shadowMapEnabled:{get:function(){return this.shadowMap.enabled},set:function(i){console.warn("THREE.WebGLRenderer: .shadowMapEnabled is now .shadowMap.enabled."),this.shadowMap.enabled=i}},shadowMapType:{get:function(){return this.shadowMap.type},set:function(i){console.warn("THREE.WebGLRenderer: .shadowMapType is now .shadowMap.type."),this.shadowMap.type=i}},shadowMapCullFace:{get:function(){console.warn("THREE.WebGLRenderer: .shadowMapCullFace has been removed. Set Material.shadowSide instead.")},set:function(){console.warn("THREE.WebGLRenderer: .shadowMapCullFace has been removed. Set Material.shadowSide instead.")}},context:{get:function(){return console.warn("THREE.WebGLRenderer: .context has been removed. Use .getContext() instead."),this.getContext()}},vr:{get:function(){return console.warn("THREE.WebGLRenderer: .vr has been renamed to .xr"),this.xr}},gammaInput:{get:function(){return console.warn("THREE.WebGLRenderer: .gammaInput has been removed. Set the encoding for textures via Texture.encoding instead."),!1},set:function(){console.warn("THREE.WebGLRenderer: .gammaInput has been removed. Set the encoding for textures via Texture.encoding instead.")}},gammaOutput:{get:function(){return console.warn("THREE.WebGLRenderer: .gammaOutput has been removed. Set WebGLRenderer.outputEncoding instead."),!1},set:function(i){console.warn("THREE.WebGLRenderer: .gammaOutput has been removed. Set WebGLRenderer.outputEncoding instead."),this.outputEncoding=i===!0?at:J0}},toneMappingWhitePoint:{get:function(){return console.warn("THREE.WebGLRenderer: .toneMappingWhitePoint has been removed."),1},set:function(){console.warn("THREE.WebGLRenderer: .toneMappingWhitePoint has been removed.")}}});Object.defineProperties(k4.prototype,{cullFace:{get:function(){console.warn("THREE.WebGLRenderer: .shadowMap.cullFace has been removed. Set Material.shadowSide instead.")},set:function(){console.warn("THREE.WebGLRenderer: .shadowMap.cullFace has been removed. Set Material.shadowSide instead.")}},renderReverseSided:{get:function(){console.warn("THREE.WebGLRenderer: .shadowMap.renderReverseSided has been removed. Set Material.shadowSide instead.")},set:function(){console.warn("THREE.WebGLRenderer: .shadowMap.renderReverseSided has been removed. Set Material.shadowSide instead.")}},renderSingleSided:{get:function(){console.warn("THREE.WebGLRenderer: .shadowMap.renderSingleSided has been removed. Set Material.shadowSide instead.")},set:function(){console.warn("THREE.WebGLRenderer: .shadowMap.renderSingleSided has been removed. Set Material.shadowSide instead.")}}});Object.defineProperties(C0.prototype,{wrapS:{get:function(){return console.warn("THREE.WebGLRenderTarget: .wrapS is now .texture.wrapS."),this.texture.wrapS},set:function(i){console.warn("THREE.WebGLRenderTarget: .wrapS is now .texture.wrapS."),this.texture.wrapS=i}},wrapT:{get:function(){return console.warn("THREE.WebGLRenderTarget: .wrapT is now .texture.wrapT."),this.texture.wrapT},set:function(i){console.warn("THREE.WebGLRenderTarget: .wrapT is now .texture.wrapT."),this.texture.wrapT=i}},magFilter:{get:function(){return console.warn("THREE.WebGLRenderTarget: .magFilter is now .texture.magFilter."),this.texture.magFilter},set:function(i){console.warn("THREE.WebGLRenderTarget: .magFilter is now .texture.magFilter."),this.texture.magFilter=i}},minFilter:{get:function(){return console.warn("THREE.WebGLRenderTarget: .minFilter is now .texture.minFilter."),this.texture.minFilter},set:function(i){console.warn("THREE.WebGLRenderTarget: .minFilter is now .texture.minFilter."),this.texture.minFilter=i}},anisotropy:{get:function(){return console.warn("THREE.WebGLRenderTarget: .anisotropy is now .texture.anisotropy."),this.texture.anisotropy},set:function(i){console.warn("THREE.WebGLRenderTarget: .anisotropy is now .texture.anisotropy."),this.texture.anisotropy=i}},offset:{get:function(){return console.warn("THREE.WebGLRenderTarget: .offset is now .texture.offset."),this.texture.offset},set:function(i){console.warn("THREE.WebGLRenderTarget: .offset is now .texture.offset."),this.texture.offset=i}},repeat:{get:function(){return console.warn("THREE.WebGLRenderTarget: .repeat is now .texture.repeat."),this.texture.repeat},set:function(i){console.warn("THREE.WebGLRenderTarget: .repeat is now .texture.repeat."),this.texture.repeat=i}},format:{get:function(){return console.warn("THREE.WebGLRenderTarget: .format is now .texture.format."),this.texture.format},set:function(i){console.warn("THREE.WebGLRenderTarget: .format is now .texture.format."),this.texture.format=i}},type:{get:function(){return console.warn("THREE.WebGLRenderTarget: .type is now .texture.type."),this.texture.type},set:function(i){console.warn("THREE.WebGLRenderTarget: .type is now .texture.type."),this.texture.type=i}},generateMipmaps:{get:function(){return console.warn("THREE.WebGLRenderTarget: .generateMipmaps is now .texture.generateMipmaps."),this.texture.generateMipmaps},set:function(i){console.warn("THREE.WebGLRenderTarget: .generateMipmaps is now .texture.generateMipmaps."),this.texture.generateMipmaps=i}}});xM.prototype.load=function(i){console.warn("THREE.Audio: .load has been deprecated. Use THREE.AudioLoader instead.");const e=this;return new pM().load(i,function(n){e.setBuffer(n)}),this};_l.prototype.updateCubeMap=function(i,e){return console.warn("THREE.CubeCamera: .updateCubeMap() is now .update()."),this.update(i,e)};_l.prototype.clear=function(i,e,t,n){return console.warn("THREE.CubeCamera: .clear() is now .renderTarget.clear()."),this.renderTarget.clear(i,e,t,n)};Kr.crossOrigin=void 0;Kr.loadTexture=function(i,e,t,n){console.warn("THREE.ImageUtils.loadTexture has been deprecated. Use THREE.TextureLoader() instead.");const r=new Bi;r.setCrossOrigin(this.crossOrigin);const s=r.load(i,t,void 0,n);return e&&(s.mapping=e),s};Kr.loadTextureCube=function(i,e,t,n){console.warn("THREE.ImageUtils.loadTextureCube has been deprecated. Use THREE.CubeTextureLoader() instead.");const r=new M5;r.setCrossOrigin(this.crossOrigin);const s=r.load(i,t,void 0,n);return e&&(s.mapping=e),s};Kr.loadCompressedTexture=function(){console.error("THREE.ImageUtils.loadCompressedTexture has been removed. Use THREE.DDSLoader instead.")};Kr.loadCompressedTextureCube=function(){console.error("THREE.ImageUtils.loadCompressedTextureCube has been removed. Use THREE.DDSLoader instead.")};typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("register",{detail:{revision:r4}}));typeof window<"u"&&(window.__THREE__?console.warn("WARNING: Multiple instances of Three.js being imported."):window.__THREE__=r4);const _3={type:"change"},T1={type:"start"},A1={type:"end"};class UM extends ni{constructor(e,t){super(),t===void 0&&console.warn('THREE.OrbitControls: The second parameter "domElement" is now mandatory.'),t===document&&console.error('THREE.OrbitControls: "document" should not be used as the target "domElement". Please use "renderer.domElement" instead.'),this.object=e,this.domElement=t,this.domElement.style.touchAction="none",this.enabled=!0,this.target=new P,this.minDistance=0,this.maxDistance=1/0,this.minZoom=0,this.maxZoom=1/0,this.minPolarAngle=0,this.maxPolarAngle=Math.PI,this.minAzimuthAngle=-1/0,this.maxAzimuthAngle=1/0,this.enableDamping=!1,this.dampingFactor=.05,this.enableZoom=!0,this.zoomSpeed=1,this.enableRotate=!0,this.rotateSpeed=1,this.enablePan=!0,this.panSpeed=1,this.screenSpacePanning=!0,this.keyPanSpeed=7,this.autoRotate=!1,this.autoRotateSpeed=2,this.keys={LEFT:"ArrowLeft",UP:"ArrowUp",RIGHT:"ArrowRight",BOTTOM:"ArrowDown"},this.mouseButtons={LEFT:Vi.ROTATE,MIDDLE:Vi.DOLLY,RIGHT:Vi.PAN},this.touches={ONE:Wi.ROTATE,TWO:Wi.DOLLY_PAN},this.target0=this.target.clone(),this.position0=this.object.position.clone(),this.zoom0=this.object.zoom,this._domElementKeyEvents=null,this.getPolarAngle=function(){return a.phi},this.getAzimuthalAngle=function(){return a.theta},this.getDistance=function(){return this.object.position.distanceTo(this.target)},this.listenToKeyEvents=function(D){D.addEventListener("keydown",oe),this._domElementKeyEvents=D},this.saveState=function(){n.target0.copy(n.target),n.position0.copy(n.object.position),n.zoom0=n.object.zoom},this.reset=function(){n.target.copy(n.target0),n.object.position.copy(n.position0),n.object.zoom=n.zoom0,n.object.updateProjectionMatrix(),n.dispatchEvent(_3),n.update(),s=r.NONE},this.update=function(){const D=new P,_e=new S0().setFromUnitVectors(e.up,new P(0,1,0)),Ie=_e.clone().invert(),Ue=new P,ke=new S0,Oe=2*Math.PI;return function(){const E0=n.object.position;D.copy(E0).sub(n.target),D.applyQuaternion(_e),a.setFromVector3(D),n.autoRotate&&s===r.NONE&&B(b()),n.enableDamping?(a.theta+=l.theta*n.dampingFactor,a.phi+=l.phi*n.dampingFactor):(a.theta+=l.theta,a.phi+=l.phi);let G0=n.minAzimuthAngle,N0=n.maxAzimuthAngle;return isFinite(G0)&&isFinite(N0)&&(G0<-Math.PI?G0+=Oe:G0>Math.PI&&(G0-=Oe),N0<-Math.PI?N0+=Oe:N0>Math.PI&&(N0-=Oe),G0<=N0?a.theta=Math.max(G0,Math.min(N0,a.theta)):a.theta=a.theta>(G0+N0)/2?Math.max(G0,a.theta):Math.min(N0,a.theta)),a.phi=Math.max(n.minPolarAngle,Math.min(n.maxPolarAngle,a.phi)),a.makeSafe(),a.radius*=c,a.radius=Math.max(n.minDistance,Math.min(n.maxDistance,a.radius)),n.enableDamping===!0?n.target.addScaledVector(u,n.dampingFactor):n.target.add(u),D.setFromSpherical(a),D.applyQuaternion(Ie),E0.copy(n.target).add(D),n.object.lookAt(n.target),n.enableDamping===!0?(l.theta*=1-n.dampingFactor,l.phi*=1-n.dampingFactor,u.multiplyScalar(1-n.dampingFactor)):(l.set(0,0,0),u.set(0,0,0)),c=1,h||Ue.distanceToSquared(n.object.position)>o||8*(1-ke.dot(n.object.quaternion))>o?(n.dispatchEvent(_3),Ue.copy(n.object.position),ke.copy(n.object.quaternion),h=!1,!0):!1}}(),this.dispose=function(){n.domElement.removeEventListener("contextmenu",ge),n.domElement.removeEventListener("pointerdown",F),n.domElement.removeEventListener("pointercancel",T),n.domElement.removeEventListener("wheel",H),n.domElement.removeEventListener("pointermove",W),n.domElement.removeEventListener("pointerup",X),n._domElementKeyEvents!==null&&n._domElementKeyEvents.removeEventListener("keydown",oe)};const n=this,r={NONE:-1,ROTATE:0,DOLLY:1,PAN:2,TOUCH_ROTATE:3,TOUCH_PAN:4,TOUCH_DOLLY_PAN:5,TOUCH_DOLLY_ROTATE:6};let s=r.NONE;const o=1e-6,a=new x3,l=new x3;let c=1;const u=new P;let h=!1;const f=new ee,d=new ee,g=new ee,v=new ee,_=new ee,m=new ee,p=new ee,y=new ee,x=new ee,w=[],A={};function b(){return 2*Math.PI/60/60*n.autoRotateSpeed}function L(){return Math.pow(.95,n.zoomSpeed)}function B(D){l.theta-=D}function I(D){l.phi-=D}const C=function(){const D=new P;return function(Ie,Ue){D.setFromMatrixColumn(Ue,0),D.multiplyScalar(-Ie),u.add(D)}}(),Y=function(){const D=new P;return function(Ie,Ue){n.screenSpacePanning===!0?D.setFromMatrixColumn(Ue,1):(D.setFromMatrixColumn(Ue,0),D.crossVectors(n.object.up,D)),D.multiplyScalar(Ie),u.add(D)}}(),O=function(){const D=new P;return function(Ie,Ue){const ke=n.domElement;if(n.object.isPerspectiveCamera){const Oe=n.object.position;D.copy(Oe).sub(n.target);let g0=D.length();g0*=Math.tan(n.object.fov/2*Math.PI/180),C(2*Ie*g0/ke.clientHeight,n.object.matrix),Y(2*Ue*g0/ke.clientHeight,n.object.matrix)}else n.object.isOrthographicCamera?(C(Ie*(n.object.right-n.object.left)/n.object.zoom/ke.clientWidth,n.object.matrix),Y(Ue*(n.object.top-n.object.bottom)/n.object.zoom/ke.clientHeight,n.object.matrix)):(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - pan disabled."),n.enablePan=!1)}}();function G(D){n.object.isPerspectiveCamera?c/=D:n.object.isOrthographicCamera?(n.object.zoom=Math.max(n.minZoom,Math.min(n.maxZoom,n.object.zoom*D)),n.object.updateProjectionMatrix(),h=!0):(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."),n.enableZoom=!1)}function j(D){n.object.isPerspectiveCamera?c*=D:n.object.isOrthographicCamera?(n.object.zoom=Math.max(n.minZoom,Math.min(n.maxZoom,n.object.zoom/D)),n.object.updateProjectionMatrix(),h=!0):(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."),n.enableZoom=!1)}function N(D){f.set(D.clientX,D.clientY)}function k(D){p.set(D.clientX,D.clientY)}function Z(D){v.set(D.clientX,D.clientY)}function le(D){d.set(D.clientX,D.clientY),g.subVectors(d,f).multiplyScalar(n.rotateSpeed);const _e=n.domElement;B(2*Math.PI*g.x/_e.clientHeight),I(2*Math.PI*g.y/_e.clientHeight),f.copy(d),n.update()}function ve(D){y.set(D.clientX,D.clientY),x.subVectors(y,p),x.y>0?G(L()):x.y<0&&j(L()),p.copy(y),n.update()}function ce(D){_.set(D.clientX,D.clientY),m.subVectors(_,v).multiplyScalar(n.panSpeed),O(m.x,m.y),v.copy(_),n.update()}function ye(D){D.deltaY<0?j(L()):D.deltaY>0&&G(L()),n.update()}function $(D){let _e=!1;switch(D.code){case n.keys.UP:O(0,n.keyPanSpeed),_e=!0;break;case n.keys.BOTTOM:O(0,-n.keyPanSpeed),_e=!0;break;case n.keys.LEFT:O(n.keyPanSpeed,0),_e=!0;break;case n.keys.RIGHT:O(-n.keyPanSpeed,0),_e=!0;break}_e&&(D.preventDefault(),n.update())}function se(){if(w.length===1)f.set(w[0].pageX,w[0].pageY);else{const D=.5*(w[0].pageX+w[1].pageX),_e=.5*(w[0].pageY+w[1].pageY);f.set(D,_e)}}function pe(){if(w.length===1)v.set(w[0].pageX,w[0].pageY);else{const D=.5*(w[0].pageX+w[1].pageX),_e=.5*(w[0].pageY+w[1].pageY);v.set(D,_e)}}function K(){const D=w[0].pageX-w[1].pageX,_e=w[0].pageY-w[1].pageY,Ie=Math.sqrt(D*D+_e*_e);p.set(0,Ie)}function V(){n.enableZoom&&K(),n.enablePan&&pe()}function te(){n.enableZoom&&K(),n.enableRotate&&se()}function Q(D){if(w.length==1)d.set(D.pageX,D.pageY);else{const Ie=Te(D),Ue=.5*(D.pageX+Ie.x),ke=.5*(D.pageY+Ie.y);d.set(Ue,ke)}g.subVectors(d,f).multiplyScalar(n.rotateSpeed);const _e=n.domElement;B(2*Math.PI*g.x/_e.clientHeight),I(2*Math.PI*g.y/_e.clientHeight),f.copy(d)}function re(D){if(w.length===1)_.set(D.pageX,D.pageY);else{const _e=Te(D),Ie=.5*(D.pageX+_e.x),Ue=.5*(D.pageY+_e.y);_.set(Ie,Ue)}m.subVectors(_,v).multiplyScalar(n.panSpeed),O(m.x,m.y),v.copy(_)}function we(D){const _e=Te(D),Ie=D.pageX-_e.x,Ue=D.pageY-_e.y,ke=Math.sqrt(Ie*Ie+Ue*Ue);y.set(0,ke),x.set(0,Math.pow(y.y/p.y,n.zoomSpeed)),G(x.y),p.copy(y)}function M(D){n.enableZoom&&we(D),n.enablePan&&re(D)}function E(D){n.enableZoom&&we(D),n.enableRotate&&Q(D)}function F(D){n.enabled!==!1&&(w.length===0&&(n.domElement.setPointerCapture(D.pointerId),n.domElement.addEventListener("pointermove",W),n.domElement.addEventListener("pointerup",X)),z(D),D.pointerType==="touch"?ue(D):S(D))}function W(D){n.enabled!==!1&&(D.pointerType==="touch"?he(D):U(D))}function X(D){n.enabled!==!1&&(D.pointerType==="touch"?xe():q(),fe(D),w.length===0&&(n.domElement.releasePointerCapture(D.pointerId),n.domElement.removeEventListener("pointermove",W),n.domElement.removeEventListener("pointerup",X)))}function T(D){fe(D)}function S(D){let _e;switch(D.button){case 0:_e=n.mouseButtons.LEFT;break;case 1:_e=n.mouseButtons.MIDDLE;break;case 2:_e=n.mouseButtons.RIGHT;break;default:_e=-1}switch(_e){case Vi.DOLLY:if(n.enableZoom===!1)return;k(D),s=r.DOLLY;break;case Vi.ROTATE:if(D.ctrlKey||D.metaKey||D.shiftKey){if(n.enablePan===!1)return;Z(D),s=r.PAN}else{if(n.enableRotate===!1)return;N(D),s=r.ROTATE}break;case Vi.PAN:if(D.ctrlKey||D.metaKey||D.shiftKey){if(n.enableRotate===!1)return;N(D),s=r.ROTATE}else{if(n.enablePan===!1)return;Z(D),s=r.PAN}break;default:s=r.NONE}s!==r.NONE&&n.dispatchEvent(T1)}function U(D){if(n.enabled!==!1)switch(s){case r.ROTATE:if(n.enableRotate===!1)return;le(D);break;case r.DOLLY:if(n.enableZoom===!1)return;ve(D);break;case r.PAN:if(n.enablePan===!1)return;ce(D);break}}function q(D){n.dispatchEvent(A1),s=r.NONE}function H(D){n.enabled===!1||n.enableZoom===!1||s!==r.NONE||(D.preventDefault(),n.dispatchEvent(T1),ye(D),n.dispatchEvent(A1))}function oe(D){n.enabled===!1||n.enablePan===!1||$(D)}function ue(D){switch(ne(D),w.length){case 1:switch(n.touches.ONE){case Wi.ROTATE:if(n.enableRotate===!1)return;se(),s=r.TOUCH_ROTATE;break;case Wi.PAN:if(n.enablePan===!1)return;pe(),s=r.TOUCH_PAN;break;default:s=r.NONE}break;case 2:switch(n.touches.TWO){case Wi.DOLLY_PAN:if(n.enableZoom===!1&&n.enablePan===!1)return;V(),s=r.TOUCH_DOLLY_PAN;break;case Wi.DOLLY_ROTATE:if(n.enableZoom===!1&&n.enableRotate===!1)return;te(),s=r.TOUCH_DOLLY_ROTATE;break;default:s=r.NONE}break;default:s=r.NONE}s!==r.NONE&&n.dispatchEvent(T1)}function he(D){switch(ne(D),s){case r.TOUCH_ROTATE:if(n.enableRotate===!1)return;Q(D),n.update();break;case r.TOUCH_PAN:if(n.enablePan===!1)return;re(D),n.update();break;case r.TOUCH_DOLLY_PAN:if(n.enableZoom===!1&&n.enablePan===!1)return;M(D),n.update();break;case r.TOUCH_DOLLY_ROTATE:if(n.enableZoom===!1&&n.enableRotate===!1)return;E(D),n.update();break;default:s=r.NONE}}function xe(D){n.dispatchEvent(A1),s=r.NONE}function ge(D){n.enabled!==!1&&D.preventDefault()}function z(D){w.push(D)}function fe(D){delete A[D.pointerId];for(let _e=0;_e1&&e.multiplyScalar(1/t),this.children[0].material.color.copy(this.material.color)}this.matrixWorld.extractRotation(this.light.matrixWorld).scale(this.scale).copyPosition(this.light.matrixWorld),this.children[0].matrixWorld.copy(this.matrixWorld)}dispose(){this.geometry.dispose(),this.material.dispose(),this.children[0].geometry.dispose(),this.children[0].material.dispose()}}class kM extends ts{constructor(e,t={}){const n=t.font;if(!(n&&n.isFont))return console.error("THREE.TextGeometry: font parameter is not an instance of THREE.Font."),new Fe;const r=n.generateShapes(e,t.size);t.depth=t.height!==void 0?t.height:50,t.bevelThickness===void 0&&(t.bevelThickness=10),t.bevelSize===void 0&&(t.bevelSize=8),t.bevelEnabled===void 0&&(t.bevelEnabled=!1),super(r,t),this.type="TextGeometry"}}class GM extends Bt{constructor(e){super(e)}load(e,t,n,r){const s=this,o=new Po(this.manager);o.setPath(this.path),o.setRequestHeader(this.requestHeader),o.setWithCredentials(s.withCredentials),o.load(e,function(a){let l;try{l=JSON.parse(a)}catch{console.warn("THREE.FontLoader: typeface.js support is being deprecated. Use typeface.json instead."),l=JSON.parse(a.substring(65,a.length-2))}const c=s.parse(l);t&&t(c)},n,r)}parse(e){return new I5(e)}}class I5{constructor(e){this.type="Font",this.data=e}generateShapes(e,t=100){const n=[],r=HM(e,t,this.data);for(let s=0,o=r.length;s=2.0 are supported."));return}const c=new mS(l,{path:t||this.resourcePath||"",crossOrigin:this.crossOrigin,requestHeader:this.requestHeader,manager:this.manager,ktx2Loader:this.ktx2Loader,meshoptDecoder:this.meshoptDecoder});c.fileLoader.setRequestHeader(this.requestHeader);for(let u=0;u=0&&a[h]===void 0&&console.warn('THREE.GLTFLoader: Unknown extension "'+h+'".')}}c.setExtensions(o),c.setPlugins(a),c.parse(n,r)}}function XM(){let i={};return{get:function(e){return i[e]},add:function(e,t){i[e]=t},remove:function(e){delete i[e]},removeAll:function(){i={}}}}const Ve={KHR_BINARY_GLTF:"KHR_binary_glTF",KHR_DRACO_MESH_COMPRESSION:"KHR_draco_mesh_compression",KHR_LIGHTS_PUNCTUAL:"KHR_lights_punctual",KHR_MATERIALS_CLEARCOAT:"KHR_materials_clearcoat",KHR_MATERIALS_IOR:"KHR_materials_ior",KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS:"KHR_materials_pbrSpecularGlossiness",KHR_MATERIALS_SHEEN:"KHR_materials_sheen",KHR_MATERIALS_SPECULAR:"KHR_materials_specular",KHR_MATERIALS_TRANSMISSION:"KHR_materials_transmission",KHR_MATERIALS_UNLIT:"KHR_materials_unlit",KHR_MATERIALS_VOLUME:"KHR_materials_volume",KHR_TEXTURE_BASISU:"KHR_texture_basisu",KHR_TEXTURE_TRANSFORM:"KHR_texture_transform",KHR_MESH_QUANTIZATION:"KHR_mesh_quantization",EXT_TEXTURE_WEBP:"EXT_texture_webp",EXT_MESHOPT_COMPRESSION:"EXT_meshopt_compression"};class jM{constructor(e){this.parser=e,this.name=Ve.KHR_LIGHTS_PUNCTUAL,this.cache={refs:{},uses:{}}}_markDefs(){const e=this.parser,t=this.parser.json.nodes||[];for(let n=0,r=t.length;n=0)throw new Error("THREE.GLTFLoader: setKTX2Loader must be called before loading KTX2 textures");return null}return t.loadTextureImage(e,o,a)}}class tS{constructor(e){this.parser=e,this.name=Ve.EXT_TEXTURE_WEBP,this.isSupported=null}loadTexture(e){const t=this.name,n=this.parser,r=n.json,s=r.textures[e];if(!s.extensions||!s.extensions[t])return null;const o=s.extensions[t],a=r.images[o.source];let l=n.textureLoader;if(a.uri){const c=n.options.manager.getHandler(a.uri);c!==null&&(l=c)}return this.detectSupport().then(function(c){if(c)return n.loadTextureImage(e,a,l);if(r.extensionsRequired&&r.extensionsRequired.indexOf(t)>=0)throw new Error("THREE.GLTFLoader: WebP required by asset but unsupported.");return n.loadTexture(e)})}detectSupport(){return this.isSupported||(this.isSupported=new Promise(function(e){const t=new Image;t.src="data:image/webp;base64,UklGRiIAAABXRUJQVlA4IBYAAAAwAQCdASoBAAEADsD+JaQAA3AAAAAA",t.onload=t.onerror=function(){e(t.height===1)}})),this.isSupported}}class nS{constructor(e){this.name=Ve.EXT_MESHOPT_COMPRESSION,this.parser=e}loadBufferView(e){const t=this.parser.json,n=t.bufferViews[e];if(n.extensions&&n.extensions[this.name]){const r=n.extensions[this.name],s=this.parser.getDependency("buffer",r.buffer),o=this.parser.options.meshoptDecoder;if(!o||!o.supported){if(t.extensionsRequired&&t.extensionsRequired.indexOf(this.name)>=0)throw new Error("THREE.GLTFLoader: setMeshoptDecoder must be called before loading compressed files");return null}return Promise.all([s,o.ready]).then(function(a){const l=r.byteOffset||0,c=r.byteLength||0,u=r.count,h=r.byteStride,f=new ArrayBuffer(u*h),d=new Uint8Array(a[0],l,c);return o.decodeGltfBuffer(new Uint8Array(f),u,h,d,r.mode,r.filter),f})}else return null}}const D5="glTF",Ps=12,b3={JSON:1313821514,BIN:5130562};class iS{constructor(e){this.name=Ve.KHR_BINARY_GLTF,this.content=null,this.body=null;const t=new DataView(e,0,Ps);if(this.header={magic:Ut.decodeText(new Uint8Array(e.slice(0,4))),version:t.getUint32(4,!0),length:t.getUint32(8,!0)},this.header.magic!==D5)throw new Error("THREE.GLTFLoader: Unsupported glTF-Binary header.");if(this.header.version<2)throw new Error("THREE.GLTFLoader: Legacy binary file detected.");const n=this.header.length-Ps,r=new DataView(e,Ps);let s=0;for(;su||r.y>u)&&(r.x>u&&(s.x=Math.floor(u/j.x),r.x=s.x*j.x,G.mapSize.x=s.x),r.y>u&&(s.y=Math.floor(u/j.y),r.y=s.y*j.y,G.mapSize.y=s.y)),G.map===null&&!G.isPointLightShadow&&this.type===Us){const k={minFilter:s0,magFilter:s0,format:a0};G.map=new C0(r.x,r.y,k),G.map.texture.name=O.name+".shadowMap",G.mapPass=new C0(r.x,r.y,k),G.camera.updateProjectionMatrix()}if(G.map===null){const k={minFilter:r0,magFilter:r0,format:a0};G.map=new C0(r.x,r.y,k),G.map.texture.name=O.name+".shadowMap",G.camera.updateProjectionMatrix()}i.setRenderTarget(G.map),i.clear();const N=G.getViewportCount();for(let k=0;k0){const O=C.uuid,G=A.uuid;let j=c[O];j===void 0&&(j={},c[O]=j);let N=j[G];N===void 0&&(N=C.clone(),j[G]=N),C=N}return C.visible=A.visible,C.wireframe=A.wireframe,I===Us?C.side=A.shadowSide!==null?A.shadowSide:A.side:C.side=A.shadowSide!==null?A.shadowSide:h[A.side],C.alphaMap=A.alphaMap,C.alphaTest=A.alphaTest,C.clipShadows=A.clipShadows,C.clippingPlanes=A.clippingPlanes,C.clipIntersection=A.clipIntersection,C.displacementMap=A.displacementMap,C.displacementScale=A.displacementScale,C.displacementBias=A.displacementBias,C.wireframeLinewidth=A.wireframeLinewidth,C.linewidth=A.linewidth,b.isPointLight===!0&&C.isMeshDistanceMaterial===!0&&(C.referencePosition.setFromMatrixPosition(b.matrixWorld),C.nearDistance=L,C.farDistance=B),C}function y(x,w,A,b,L){if(x.visible===!1)return;if(x.layers.test(w.layers)&&(x.isMesh||x.isLine||x.isPoints)&&(x.castShadow||x.receiveShadow&&L===Us)&&(!x.frustumCulled||n.intersectsObject(x))){x.modelViewMatrix.multiplyMatrices(A.matrixWorldInverse,x.matrixWorld);const C=e.update(x),Y=x.material;if(Array.isArray(Y)){const O=C.groups;for(let G=0,j=O.length;G=1):j.indexOf("OpenGL ES")!==-1&&(G=parseFloat(/^OpenGL ES (\d)/.exec(j)[1]),O=G>=2);let N=null,k={};const K=i.getParameter(3088),le=i.getParameter(2978),ve=new $e().fromArray(K),ce=new $e().fromArray(le);function ye(z,fe,ne){const Te=new Uint8Array(4),D=i.createTexture();i.bindTexture(z,D),i.texParameteri(z,10241,9728),i.texParameteri(z,10240,9728);for(let _e=0;_eq||T.height>q)&&(H=q/Math.max(T.width,T.height)),H<1||S===!0)if(typeof HTMLImageElement<"u"&&T instanceof HTMLImageElement||typeof HTMLCanvasElement<"u"&&T instanceof HTMLCanvasElement||typeof ImageBitmap<"u"&&T instanceof ImageBitmap){const oe=S?_4:Math.floor,ue=oe(H*T.width),he=oe(H*T.height);d===void 0&&(d=v(ue,he));const xe=U?v(ue,he):d;return xe.width=ue,xe.height=he,xe.getContext("2d").drawImage(T,0,0,ue,he),console.warn("THREE.WebGLRenderer: Texture has been resized from ("+T.width+"x"+T.height+") to ("+ue+"x"+he+")."),xe}else return"data"in T&&console.warn("THREE.WebGLRenderer: Image in DataTexture is too big ("+T.width+"x"+T.height+")."),T;return T}function m(T){return ec(T.width)&&ec(T.height)}function p(T){return a?!1:T.wrapS!==m0||T.wrapT!==m0||T.minFilter!==r0&&T.minFilter!==s0}function y(T,S){return T.generateMipmaps&&S&&T.minFilter!==r0&&T.minFilter!==s0}function x(T,S,U,q,H=1){i.generateMipmap(T);const oe=n.get(S);oe.__maxMipLevel=Math.log2(Math.max(U,q,H))}function w(T,S,U,q){if(a===!1)return S;if(T!==null){if(i[T]!==void 0)return i[T];console.warn("THREE.WebGLRenderer: Attempt to use non-existing WebGL internal format '"+T+"'")}let H=S;return S===6403&&(U===5126&&(H=33326),U===5131&&(H=33325),U===5121&&(H=33321)),S===6407&&(U===5126&&(H=34837),U===5131&&(H=34843),U===5121&&(H=32849)),S===6408&&(U===5126&&(H=34836),U===5131&&(H=34842),U===5121&&(H=q===at?35907:32856)),(H===33325||H===33326||H===34842||H===34836)&&e.get("EXT_color_buffer_float"),H}function A(T){return T===r0||T===J1||T===$1?9728:9729}function b(T){const S=T.target;S.removeEventListener("dispose",b),B(S),S.isVideoTexture&&f.delete(S),o.memory.textures--}function L(T){const S=T.target;S.removeEventListener("dispose",L),I(S)}function B(T){const S=n.get(T);S.__webglInit!==void 0&&(i.deleteTexture(S.__webglTexture),n.remove(T))}function I(T){const S=T.texture,U=n.get(T),q=n.get(S);if(T){if(q.__webglTexture!==void 0&&(i.deleteTexture(q.__webglTexture),o.memory.textures--),T.depthTexture&&T.depthTexture.dispose(),T.isWebGLCubeRenderTarget)for(let H=0;H<6;H++)i.deleteFramebuffer(U.__webglFramebuffer[H]),U.__webglDepthbuffer&&i.deleteRenderbuffer(U.__webglDepthbuffer[H]);else i.deleteFramebuffer(U.__webglFramebuffer),U.__webglDepthbuffer&&i.deleteRenderbuffer(U.__webglDepthbuffer),U.__webglMultisampledFramebuffer&&i.deleteFramebuffer(U.__webglMultisampledFramebuffer),U.__webglColorRenderbuffer&&i.deleteRenderbuffer(U.__webglColorRenderbuffer),U.__webglDepthRenderbuffer&&i.deleteRenderbuffer(U.__webglDepthRenderbuffer);if(T.isWebGLMultipleRenderTargets)for(let H=0,oe=S.length;H=l&&console.warn("THREE.WebGLTextures: Trying to use "+T+" texture units while this GPU supports only "+l),C+=1,T}function G(T,S){const U=n.get(T);if(T.isVideoTexture&&M(T),T.version>0&&U.__version!==T.version){const q=T.image;if(q===void 0)console.warn("THREE.WebGLRenderer: Texture marked for update but image is undefined");else if(q.complete===!1)console.warn("THREE.WebGLRenderer: Texture marked for update but image is incomplete");else{ye(U,T,S);return}}t.activeTexture(33984+S),t.bindTexture(3553,U.__webglTexture)}function j(T,S){const U=n.get(T);if(T.version>0&&U.__version!==T.version){ye(U,T,S);return}t.activeTexture(33984+S),t.bindTexture(35866,U.__webglTexture)}function N(T,S){const U=n.get(T);if(T.version>0&&U.__version!==T.version){ye(U,T,S);return}t.activeTexture(33984+S),t.bindTexture(32879,U.__webglTexture)}function k(T,S){const U=n.get(T);if(T.version>0&&U.__version!==T.version){$(U,T,S);return}t.activeTexture(33984+S),t.bindTexture(34067,U.__webglTexture)}const K={[Qt]:10497,[m0]:33071,[Wa]:33648},le={[r0]:9728,[J1]:9984,[$1]:9986,[s0]:9729,[f4]:9985,[Ni]:9987};function ve(T,S,U){if(U?(i.texParameteri(T,10242,K[S.wrapS]),i.texParameteri(T,10243,K[S.wrapT]),(T===32879||T===35866)&&i.texParameteri(T,32882,K[S.wrapR]),i.texParameteri(T,10240,le[S.magFilter]),i.texParameteri(T,10241,le[S.minFilter])):(i.texParameteri(T,10242,33071),i.texParameteri(T,10243,33071),(T===32879||T===35866)&&i.texParameteri(T,32882,33071),(S.wrapS!==m0||S.wrapT!==m0)&&console.warn("THREE.WebGLRenderer: Texture is not power of two. Texture.wrapS and Texture.wrapT should be set to THREE.ClampToEdgeWrapping."),i.texParameteri(T,10240,A(S.magFilter)),i.texParameteri(T,10241,A(S.minFilter)),S.minFilter!==r0&&S.minFilter!==s0&&console.warn("THREE.WebGLRenderer: Texture is not power of two. Texture.minFilter should be set to THREE.NearestFilter or THREE.LinearFilter.")),e.has("EXT_texture_filter_anisotropic")===!0){const q=e.get("EXT_texture_filter_anisotropic");if(S.type===gt&&e.has("OES_texture_float_linear")===!1||a===!1&&S.type===Vn&&e.has("OES_texture_half_float_linear")===!1)return;(S.anisotropy>1||n.get(S).__currentAnisotropy)&&(i.texParameterf(T,q.TEXTURE_MAX_ANISOTROPY_EXT,Math.min(S.anisotropy,r.getMaxAnisotropy())),n.get(S).__currentAnisotropy=S.anisotropy)}}function ce(T,S){T.__webglInit===void 0&&(T.__webglInit=!0,S.addEventListener("dispose",b),T.__webglTexture=i.createTexture(),o.memory.textures++)}function ye(T,S,U){let q=3553;S.isDataTexture2DArray&&(q=35866),S.isDataTexture3D&&(q=32879),ce(T,S),t.activeTexture(33984+U),t.bindTexture(q,T.__webglTexture),i.pixelStorei(37440,S.flipY),i.pixelStorei(37441,S.premultiplyAlpha),i.pixelStorei(3317,S.unpackAlignment),i.pixelStorei(37443,0);const H=p(S)&&m(S.image)===!1,oe=_(S.image,H,!1,u),ue=m(oe)||a,he=s.convert(S.format);let xe=s.convert(S.type),ge=w(S.internalFormat,he,xe,S.encoding);ve(q,S,ue);let z;const fe=S.mipmaps;if(S.isDepthTexture)ge=6402,a?S.type===gt?ge=36012:S.type===Ra?ge=33190:S.type===Xs?ge=35056:ge=33189:S.type===gt&&console.error("WebGLRenderer: Floating point depth texture requires WebGL2."),S.format===Ar&&ge===6402&&S.type!==oo&&S.type!==Ra&&(console.warn("THREE.WebGLRenderer: Use UnsignedShortType or UnsignedIntType for DepthFormat DepthTexture."),S.type=oo,xe=s.convert(S.type)),S.format===ao&&ge===6402&&(ge=34041,S.type!==Xs&&(console.warn("THREE.WebGLRenderer: Use UnsignedInt248Type for DepthStencilFormat DepthTexture."),S.type=Xs,xe=s.convert(S.type))),t.texImage2D(3553,0,ge,oe.width,oe.height,0,he,xe,null);else if(S.isDataTexture)if(fe.length>0&&ue){for(let ne=0,Te=fe.length;ne0&&ue){for(let ne=0,Te=fe.length;ned+g?(c.inputState.pinching=!1,this.dispatchEvent({type:"pinchend",handedness:e.handedness,target:this})):!c.inputState.pinching&&f<=d-g&&(c.inputState.pinching=!0,this.dispatchEvent({type:"pinchstart",handedness:e.handedness,target:this}))}else l!==null&&e.gripSpace&&(s=t.getPose(e.gripSpace,n),s!==null&&(l.matrix.fromArray(s.transform.matrix),l.matrix.decompose(l.position,l.rotation,l.scale),s.linearVelocity?(l.hasLinearVelocity=!0,l.linearVelocity.copy(s.linearVelocity)):l.hasLinearVelocity=!1,s.angularVelocity?(l.hasAngularVelocity=!0,l.angularVelocity.copy(s.angularVelocity)):l.hasAngularVelocity=!1));return a!==null&&(a.visible=r!==null),l!==null&&(l.visible=s!==null),c!==null&&(c.visible=o!==null),this}}class cw extends ni{constructor(e,t){super();const n=this,r=e.state;let s=null,o=1,a=null,l="local-floor",c=null,u=null,h=null,f=null,d=null,g=!1,v=null,_=null,m=null,p=null,y=null,x=null;const w=[],A=new Map,b=new X0;b.layers.enable(1),b.viewport=new $e;const L=new X0;L.layers.enable(2),L.viewport=new $e;const B=[b,L],I=new G4;I.layers.enable(1),I.layers.enable(2);let C=null,Y=null;this.cameraAutoUpdate=!0,this.enabled=!1,this.isPresenting=!1,this.getController=function($){let se=w[$];return se===void 0&&(se=new x1,w[$]=se),se.getTargetRaySpace()},this.getControllerGrip=function($){let se=w[$];return se===void 0&&(se=new x1,w[$]=se),se.getGripSpace()},this.getHand=function($){let se=w[$];return se===void 0&&(se=new x1,w[$]=se),se.getHandSpace()};function O($){const se=A.get($.inputSource);se&&se.dispatchEvent({type:$.type,data:$.inputSource})}function G(){A.forEach(function($,se){$.disconnect(se)}),A.clear(),C=null,Y=null,r.bindXRFramebuffer(null),e.setRenderTarget(e.getRenderTarget()),h&&t.deleteFramebuffer(h),v&&t.deleteFramebuffer(v),_&&t.deleteRenderbuffer(_),m&&t.deleteRenderbuffer(m),h=null,v=null,_=null,m=null,d=null,f=null,u=null,s=null,ye.stop(),n.isPresenting=!1,n.dispatchEvent({type:"sessionend"})}this.setFramebufferScaleFactor=function($){o=$,n.isPresenting===!0&&console.warn("THREE.WebXRManager: Cannot change framebuffer scale while presenting.")},this.setReferenceSpaceType=function($){l=$,n.isPresenting===!0&&console.warn("THREE.WebXRManager: Cannot change reference space type while presenting.")},this.getReferenceSpace=function(){return a},this.getBaseLayer=function(){return f!==null?f:d},this.getBinding=function(){return u},this.getFrame=function(){return p},this.getSession=function(){return s},this.setSession=async function($){if(s=$,s!==null){s.addEventListener("select",O),s.addEventListener("selectstart",O),s.addEventListener("selectend",O),s.addEventListener("squeeze",O),s.addEventListener("squeezestart",O),s.addEventListener("squeezeend",O),s.addEventListener("end",G),s.addEventListener("inputsourceschange",j);const se=t.getContextAttributes();if(se.xrCompatible!==!0&&await t.makeXRCompatible(),s.renderState.layers===void 0){const me={antialias:se.antialias,alpha:se.alpha,depth:se.depth,stencil:se.stencil,framebufferScaleFactor:o};d=new XRWebGLLayer(s,t,me),s.updateRenderState({baseLayer:d})}else if(t instanceof WebGLRenderingContext){const me={antialias:!0,alpha:se.alpha,depth:se.depth,stencil:se.stencil,framebufferScaleFactor:o};d=new XRWebGLLayer(s,t,me),s.updateRenderState({layers:[d]})}else{g=se.antialias;let me=null;se.depth&&(x=256,se.stencil&&(x|=1024),y=se.stencil?33306:36096,me=se.stencil?35056:33190);const Z={colorFormat:se.alpha?32856:32849,depthFormat:me,scaleFactor:o};u=new XRWebGLBinding(s,t),f=u.createProjectionLayer(Z),h=t.createFramebuffer(),s.updateRenderState({layers:[f]}),g&&(v=t.createFramebuffer(),_=t.createRenderbuffer(),t.bindRenderbuffer(36161,_),t.renderbufferStorageMultisample(36161,4,32856,f.textureWidth,f.textureHeight),r.bindFramebuffer(36160,v),t.framebufferRenderbuffer(36160,36064,36161,_),t.bindRenderbuffer(36161,null),me!==null&&(m=t.createRenderbuffer(),t.bindRenderbuffer(36161,m),t.renderbufferStorageMultisample(36161,4,me,f.textureWidth,f.textureHeight),t.framebufferRenderbuffer(36160,y,36161,m),t.bindRenderbuffer(36161,null)),r.bindFramebuffer(36160,null))}a=await s.requestReferenceSpace(l),ye.setContext(s),ye.start(),n.isPresenting=!0,n.dispatchEvent({type:"sessionstart"})}};function j($){const se=s.inputSources;for(let me=0;me0&&(m.alphaTest.value=p.alphaTest);const y=i.get(p).envMap;if(y){m.envMap.value=y,m.flipEnvMap.value=y.isCubeTexture&&y.isRenderTargetTexture===!1?-1:1,m.reflectivity.value=p.reflectivity,m.ior.value=p.ior,m.refractionRatio.value=p.refractionRatio;const A=i.get(y).__maxMipLevel;A!==void 0&&(m.maxMipLevel.value=A)}p.lightMap&&(m.lightMap.value=p.lightMap,m.lightMapIntensity.value=p.lightMapIntensity),p.aoMap&&(m.aoMap.value=p.aoMap,m.aoMapIntensity.value=p.aoMapIntensity);let x;p.map?x=p.map:p.specularMap?x=p.specularMap:p.displacementMap?x=p.displacementMap:p.normalMap?x=p.normalMap:p.bumpMap?x=p.bumpMap:p.roughnessMap?x=p.roughnessMap:p.metalnessMap?x=p.metalnessMap:p.alphaMap?x=p.alphaMap:p.emissiveMap?x=p.emissiveMap:p.clearcoatMap?x=p.clearcoatMap:p.clearcoatNormalMap?x=p.clearcoatNormalMap:p.clearcoatRoughnessMap?x=p.clearcoatRoughnessMap:p.specularIntensityMap?x=p.specularIntensityMap:p.specularColorMap?x=p.specularColorMap:p.transmissionMap?x=p.transmissionMap:p.thicknessMap?x=p.thicknessMap:p.sheenColorMap?x=p.sheenColorMap:p.sheenRoughnessMap&&(x=p.sheenRoughnessMap),x!==void 0&&(x.isWebGLRenderTarget&&(x=x.texture),x.matrixAutoUpdate===!0&&x.updateMatrix(),m.uvTransform.value.copy(x.matrix));let w;p.aoMap?w=p.aoMap:p.lightMap&&(w=p.lightMap),w!==void 0&&(w.isWebGLRenderTarget&&(w=w.texture),w.matrixAutoUpdate===!0&&w.updateMatrix(),m.uv2Transform.value.copy(w.matrix))}function r(m,p){m.diffuse.value.copy(p.color),m.opacity.value=p.opacity}function s(m,p){m.dashSize.value=p.dashSize,m.totalSize.value=p.dashSize+p.gapSize,m.scale.value=p.scale}function o(m,p,y,x){m.diffuse.value.copy(p.color),m.opacity.value=p.opacity,m.size.value=p.size*y,m.scale.value=x*.5,p.map&&(m.map.value=p.map),p.alphaMap&&(m.alphaMap.value=p.alphaMap),p.alphaTest>0&&(m.alphaTest.value=p.alphaTest);let w;p.map?w=p.map:p.alphaMap&&(w=p.alphaMap),w!==void 0&&(w.matrixAutoUpdate===!0&&w.updateMatrix(),m.uvTransform.value.copy(w.matrix))}function a(m,p){m.diffuse.value.copy(p.color),m.opacity.value=p.opacity,m.rotation.value=p.rotation,p.map&&(m.map.value=p.map),p.alphaMap&&(m.alphaMap.value=p.alphaMap),p.alphaTest>0&&(m.alphaTest.value=p.alphaTest);let y;p.map?y=p.map:p.alphaMap&&(y=p.alphaMap),y!==void 0&&(y.matrixAutoUpdate===!0&&y.updateMatrix(),m.uvTransform.value.copy(y.matrix))}function l(m,p){p.emissiveMap&&(m.emissiveMap.value=p.emissiveMap)}function c(m,p){m.specular.value.copy(p.specular),m.shininess.value=Math.max(p.shininess,1e-4),p.emissiveMap&&(m.emissiveMap.value=p.emissiveMap),p.bumpMap&&(m.bumpMap.value=p.bumpMap,m.bumpScale.value=p.bumpScale,p.side===L0&&(m.bumpScale.value*=-1)),p.normalMap&&(m.normalMap.value=p.normalMap,m.normalScale.value.copy(p.normalScale),p.side===L0&&m.normalScale.value.negate()),p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias)}function u(m,p){p.gradientMap&&(m.gradientMap.value=p.gradientMap),p.emissiveMap&&(m.emissiveMap.value=p.emissiveMap),p.bumpMap&&(m.bumpMap.value=p.bumpMap,m.bumpScale.value=p.bumpScale,p.side===L0&&(m.bumpScale.value*=-1)),p.normalMap&&(m.normalMap.value=p.normalMap,m.normalScale.value.copy(p.normalScale),p.side===L0&&m.normalScale.value.negate()),p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias)}function h(m,p){m.roughness.value=p.roughness,m.metalness.value=p.metalness,p.roughnessMap&&(m.roughnessMap.value=p.roughnessMap),p.metalnessMap&&(m.metalnessMap.value=p.metalnessMap),p.emissiveMap&&(m.emissiveMap.value=p.emissiveMap),p.bumpMap&&(m.bumpMap.value=p.bumpMap,m.bumpScale.value=p.bumpScale,p.side===L0&&(m.bumpScale.value*=-1)),p.normalMap&&(m.normalMap.value=p.normalMap,m.normalScale.value.copy(p.normalScale),p.side===L0&&m.normalScale.value.negate()),p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias),i.get(p).envMap&&(m.envMapIntensity.value=p.envMapIntensity)}function f(m,p,y){h(m,p),m.ior.value=p.ior,p.sheen>0&&(m.sheenColor.value.copy(p.sheenColor).multiplyScalar(p.sheen),m.sheenRoughness.value=p.sheenRoughness,p.sheenColorMap&&(m.sheenColorMap.value=p.sheenColorMap),p.sheenRoughnessMap&&(m.sheenRoughnessMap.value=p.sheenRoughnessMap)),p.clearcoat>0&&(m.clearcoat.value=p.clearcoat,m.clearcoatRoughness.value=p.clearcoatRoughness,p.clearcoatMap&&(m.clearcoatMap.value=p.clearcoatMap),p.clearcoatRoughnessMap&&(m.clearcoatRoughnessMap.value=p.clearcoatRoughnessMap),p.clearcoatNormalMap&&(m.clearcoatNormalScale.value.copy(p.clearcoatNormalScale),m.clearcoatNormalMap.value=p.clearcoatNormalMap,p.side===L0&&m.clearcoatNormalScale.value.negate())),p.transmission>0&&(m.transmission.value=p.transmission,m.transmissionSamplerMap.value=y.texture,m.transmissionSamplerSize.value.set(y.width,y.height),p.transmissionMap&&(m.transmissionMap.value=p.transmissionMap),m.thickness.value=p.thickness,p.thicknessMap&&(m.thicknessMap.value=p.thicknessMap),m.attenuationDistance.value=p.attenuationDistance,m.attenuationColor.value.copy(p.attenuationColor)),m.specularIntensity.value=p.specularIntensity,m.specularColor.value.copy(p.specularColor),p.specularIntensityMap&&(m.specularIntensityMap.value=p.specularIntensityMap),p.specularColorMap&&(m.specularColorMap.value=p.specularColorMap)}function d(m,p){p.matcap&&(m.matcap.value=p.matcap),p.bumpMap&&(m.bumpMap.value=p.bumpMap,m.bumpScale.value=p.bumpScale,p.side===L0&&(m.bumpScale.value*=-1)),p.normalMap&&(m.normalMap.value=p.normalMap,m.normalScale.value.copy(p.normalScale),p.side===L0&&m.normalScale.value.negate()),p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias)}function g(m,p){p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias)}function v(m,p){p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias),m.referencePosition.value.copy(p.referencePosition),m.nearDistance.value=p.nearDistance,m.farDistance.value=p.farDistance}function _(m,p){p.bumpMap&&(m.bumpMap.value=p.bumpMap,m.bumpScale.value=p.bumpScale,p.side===L0&&(m.bumpScale.value*=-1)),p.normalMap&&(m.normalMap.value=p.normalMap,m.normalScale.value.copy(p.normalScale),p.side===L0&&m.normalScale.value.negate()),p.displacementMap&&(m.displacementMap.value=p.displacementMap,m.displacementScale.value=p.displacementScale,m.displacementBias.value=p.displacementBias)}return{refreshFogUniforms:e,refreshMaterialUniforms:t}}function hw(){const i=_l("canvas");return i.style.display="block",i}function o0(i={}){const e=i.canvas!==void 0?i.canvas:hw(),t=i.context!==void 0?i.context:null,n=i.alpha!==void 0?i.alpha:!1,r=i.depth!==void 0?i.depth:!0,s=i.stencil!==void 0?i.stencil:!0,o=i.antialias!==void 0?i.antialias:!1,a=i.premultipliedAlpha!==void 0?i.premultipliedAlpha:!0,l=i.preserveDrawingBuffer!==void 0?i.preserveDrawingBuffer:!1,c=i.powerPreference!==void 0?i.powerPreference:"default",u=i.failIfMajorPerformanceCaveat!==void 0?i.failIfMajorPerformanceCaveat:!1;let h=null,f=null;const d=[],g=[];this.domElement=e,this.debug={checkShaderErrors:!0},this.autoClear=!0,this.autoClearColor=!0,this.autoClearDepth=!0,this.autoClearStencil=!0,this.sortObjects=!0,this.clippingPlanes=[],this.localClippingEnabled=!1,this.gammaFactor=2,this.outputEncoding=J0,this.physicallyCorrectLights=!1,this.toneMapping=Pi,this.toneMappingExposure=1;const v=this;let _=!1,m=0,p=0,y=null,x=-1,w=null;const A=new $e,b=new $e;let L=null,B=e.width,I=e.height,C=1,Y=null,O=null;const G=new $e(0,0,B,I),j=new $e(0,0,B,I);let N=!1;const k=[],K=new Ml;let le=!1,ve=!1,ce=null;const ye=new Me,$=new P,se={background:null,fog:null,environment:null,overrideMaterial:null,isScene:!0};function me(){return y===null?C:1}let Z=t;function V(R,J){for(let ae=0;ae0?f=g[g.length-1]:f=null,d.pop(),d.length>0?h=d[d.length-1]:h=null};function H9(R,J,ae,ie){if(R.visible===!1)return;if(R.layers.test(J.layers)){if(R.isGroup)ae=R.renderOrder;else if(R.isLOD)R.autoUpdate===!0&&R.update(J);else if(R.isLight)f.pushLight(R),R.castShadow&&f.pushShadow(R);else if(R.isSprite){if(!R.frustumCulled||K.intersectsSprite(R)){ie&&$.setFromMatrixPosition(R.matrixWorld).applyMatrix4(ye);const Ce=S.update(R),Pe=R.material;Pe.visible&&h.push(R,Ce,Pe,ae,$.z,null)}}else if((R.isMesh||R.isLine||R.isPoints)&&(R.isSkinnedMesh&&R.skeleton.frame!==we.render.frame&&(R.skeleton.update(),R.skeleton.frame=we.render.frame),!R.frustumCulled||K.intersectsObject(R))){ie&&$.setFromMatrixPosition(R.matrixWorld).applyMatrix4(ye);const Ce=S.update(R),Pe=R.material;if(Array.isArray(Pe)){const ze=Ce.groups;for(let n0=0,Ve=ze.length;n00&&ud(pe,J,ae),ie&&re.viewport(A.copy(ie)),pe.length>0&&No(pe,J,ae),Re.length>0&&No(Re,J,ae),Ce.length>0&&No(Ce,J,ae)}function ud(R,J,ae){if(ce===null){const Ce=o===!0&&Q.isWebGL2===!0?w4:C0;ce=new Ce(1024,1024,{generateMipmaps:!0,type:ne.convert(Vn)!==null?Vn:Zn,minFilter:Ni,magFilter:r0,wrapS:m0,wrapT:m0})}const ie=v.getRenderTarget();v.setRenderTarget(ce),v.clear();const pe=v.toneMapping;v.toneMapping=Pi,No(R,J,ae),v.toneMapping=pe,E.updateMultisampleRenderTarget(ce),E.updateRenderTargetMipmap(ce),v.setRenderTarget(ie)}function No(R,J,ae){const ie=J.isScene===!0?J.overrideMaterial:null;for(let pe=0,Re=R.length;pe=0&&J<=R.width-ie&&ae>=0&&ae<=R.height-pe&&Z.readPixels(J,ae,ie,pe,ne.convert(n0),ne.convert(Ve),Re):console.error("THREE.WebGLRenderer.readRenderTargetPixels: readPixels from renderTarget failed. Framebuffer not complete.")}finally{const ze=y!==null?M.get(y).__webglFramebuffer:null;re.bindFramebuffer(36160,ze)}}},this.copyFramebufferToTexture=function(R,J,ae=0){const ie=Math.pow(2,-ae),pe=Math.floor(J.image.width*ie),Re=Math.floor(J.image.height*ie);let Ce=ne.convert(J.format);Q.isWebGL2&&(Ce===6407&&(Ce=32849),Ce===6408&&(Ce=32856)),E.setTexture2D(J,0),Z.copyTexImage2D(3553,ae,Ce,R.x,R.y,pe,Re,0),re.unbindTexture()},this.copyTextureToTexture=function(R,J,ae,ie=0){const pe=J.image.width,Re=J.image.height,Ce=ne.convert(ae.format),Pe=ne.convert(ae.type);E.setTexture2D(ae,0),Z.pixelStorei(37440,ae.flipY),Z.pixelStorei(37441,ae.premultiplyAlpha),Z.pixelStorei(3317,ae.unpackAlignment),J.isDataTexture?Z.texSubImage2D(3553,ie,R.x,R.y,pe,Re,Ce,Pe,J.image.data):J.isCompressedTexture?Z.compressedTexSubImage2D(3553,ie,R.x,R.y,J.mipmaps[0].width,J.mipmaps[0].height,Ce,J.mipmaps[0].data):Z.texSubImage2D(3553,ie,R.x,R.y,Ce,Pe,J.image),ie===0&&ae.generateMipmaps&&Z.generateMipmap(3553),re.unbindTexture()},this.copyTextureToTexture3D=function(R,J,ae,ie,pe=0){if(v.isWebGL1Renderer){console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: can only be used with WebGL2.");return}const Re=R.max.x-R.min.x+1,Ce=R.max.y-R.min.y+1,Pe=R.max.z-R.min.z+1,ze=ne.convert(ie.format),n0=ne.convert(ie.type);let Ve;if(ie.isDataTexture3D)E.setTexture3D(ie,0),Ve=32879;else if(ie.isDataTexture2DArray)E.setTexture2DArray(ie,0),Ve=35866;else{console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: only supports THREE.DataTexture3D and THREE.DataTexture2DArray.");return}Z.pixelStorei(37440,ie.flipY),Z.pixelStorei(37441,ie.premultiplyAlpha),Z.pixelStorei(3317,ie.unpackAlignment);const Qe=Z.getParameter(3314),x0=Z.getParameter(32878),ui=Z.getParameter(3316),Je=Z.getParameter(3315),gs=Z.getParameter(32877),h0=ae.isCompressedTexture?ae.mipmaps[0]:ae.image;Z.pixelStorei(3314,h0.width),Z.pixelStorei(32878,h0.height),Z.pixelStorei(3316,R.min.x),Z.pixelStorei(3315,R.min.y),Z.pixelStorei(32877,R.min.z),ae.isDataTexture||ae.isDataTexture3D?Z.texSubImage3D(Ve,pe,J.x,J.y,J.z,Re,Ce,Pe,ze,n0,h0.data):ae.isCompressedTexture?(console.warn("THREE.WebGLRenderer.copyTextureToTexture3D: untested support for compressed srcTexture."),Z.compressedTexSubImage3D(Ve,pe,J.x,J.y,J.z,Re,Ce,Pe,ze,h0.data)):Z.texSubImage3D(Ve,pe,J.x,J.y,J.z,Re,Ce,Pe,ze,n0,h0),Z.pixelStorei(3314,Qe),Z.pixelStorei(32878,x0),Z.pixelStorei(3316,ui),Z.pixelStorei(3315,Je),Z.pixelStorei(32877,gs),pe===0&&ie.generateMipmaps&&Z.generateMipmap(Ve),re.unbindTexture()},this.initTexture=function(R){E.setTexture2D(R,0),re.unbindTexture()},this.resetState=function(){m=0,p=0,y=null,re.reset(),Te.reset()},typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}o0.prototype.isWebGLRenderer=!0;class fw extends o0{}fw.prototype.isWebGL1Renderer=!0;let o9=class extends t0{constructor(){super(),this.type="Scene",this.background=null,this.environment=null,this.fog=null,this.overrideMaterial=null,this.autoUpdate=!0,typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}copy(e,t){return super.copy(e,t),e.background!==null&&(this.background=e.background.clone()),e.environment!==null&&(this.environment=e.environment.clone()),e.fog!==null&&(this.fog=e.fog.clone()),e.overrideMaterial!==null&&(this.overrideMaterial=e.overrideMaterial.clone()),this.autoUpdate=e.autoUpdate,this.matrixAutoUpdate=e.matrixAutoUpdate,this}toJSON(e){const t=super.toJSON(e);return this.fog!==null&&(t.object.fog=this.fog.toJSON()),t}};o9.prototype.isScene=!0;class es{constructor(e,t){this.array=e,this.stride=t,this.count=e!==void 0?e.length/t:0,this.usage=co,this.updateRange={offset:0,count:-1},this.version=0,this.uuid=yt()}onUploadCallback(){}set needsUpdate(e){e===!0&&this.version++}setUsage(e){return this.usage=e,this}copy(e){return this.array=new e.array.constructor(e.array),this.count=e.count,this.stride=e.stride,this.usage=e.usage,this}copyAt(e,t,n){e*=this.stride,n*=t.stride;for(let r=0,s=this.stride;re.far||t.push({distance:l,point:Ts.clone(),uv:R0.getUV(Ts,la,Es,ca,ju,y1,Yu,new ee),face:null,object:this})}copy(e){return super.copy(e),e.center!==void 0&&this.center.copy(e.center),this.material=e.material,this}};V4.prototype.isSprite=!0;function ua(i,e,t,n,r,s){cr.subVectors(i,t).addScalar(.5).multiply(n),r!==void 0?(As.x=s*cr.x-r*cr.y,As.y=r*cr.x+s*cr.y):As.copy(cr),i.copy(e),i.x+=As.x,i.y+=As.y,i.applyMatrix4(H4)}const qu=new P,Qu=new $e,Ku=new $e,dw=new P,Zu=new Me;class Tl extends I0{constructor(e,t){super(e,t),this.type="SkinnedMesh",this.bindMode="attached",this.bindMatrix=new Me,this.bindMatrixInverse=new Me}copy(e){return super.copy(e),this.bindMode=e.bindMode,this.bindMatrix.copy(e.bindMatrix),this.bindMatrixInverse.copy(e.bindMatrixInverse),this.skeleton=e.skeleton,this}bind(e,t){this.skeleton=e,t===void 0&&(this.updateMatrixWorld(!0),this.skeleton.calculateInverses(),t=this.matrixWorld),this.bindMatrix.copy(t),this.bindMatrixInverse.copy(t).invert()}pose(){this.skeleton.pose()}normalizeSkinWeights(){const e=new $e,t=this.geometry.attributes.skinWeight;for(let n=0,r=t.count;nl)continue;f.applyMatrix4(this.matrixWorld);const L=e.ray.origin.distanceTo(f);Le.far||t.push({distance:L,point:h.clone().applyMatrix4(this.matrixWorld),index:y,face:null,faceIndex:null,object:this})}}else{const m=Math.max(0,o.start),p=Math.min(_.count,o.start+o.count);for(let y=m,x=p-1;yl)continue;f.applyMatrix4(this.matrixWorld);const A=e.ray.origin.distanceTo(f);Ae.far||t.push({distance:A,point:h.clone().applyMatrix4(this.matrixWorld),index:y,face:null,faceIndex:null,object:this})}}}else n.isGeometry&&console.error("THREE.Line.raycast() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")}updateMorphTargets(){const e=this.geometry;if(e.isBufferGeometry){const t=e.morphAttributes,n=Object.keys(t);if(n.length>0){const r=t[n[0]];if(r!==void 0){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let s=0,o=r.length;s0&&console.error("THREE.Line.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.")}}}ts.prototype.isLine=!0;const r3=new P,s3=new P;class El extends ts{constructor(e,t){super(e,t),this.type="LineSegments"}computeLineDistances(){const e=this.geometry;if(e.isBufferGeometry)if(e.index===null){const t=e.attributes.position,n=[];for(let r=0,s=t.count;r0){const r=t[n[0]];if(r!==void 0){this.morphTargetInfluences=[],this.morphTargetDictionary={};for(let s=0,o=r.length;s0&&console.error("THREE.Points.updateMorphTargets() does not support THREE.Geometry. Use THREE.BufferGeometry instead.")}}};l9.prototype.isPoints=!0;function a3(i,e,t,n,r,s,o){const a=sc.distanceSqToPoint(i);if(ar.far)return;s.push({distance:c,distanceToRay:Math.sqrt(a),point:l,index:e,face:null,object:o})}}let X4=class extends A0{constructor(e,t,n,r,s,o,a,l,c){super(e,t,n,r,s,o,a,l,c),this.format=a!==void 0?a:Yt,this.minFilter=o!==void 0?o:s0,this.magFilter=s!==void 0?s:s0,this.generateMipmaps=!1;const u=this;function h(){u.needsUpdate=!0,e.requestVideoFrameCallback(h)}"requestVideoFrameCallback"in e&&e.requestVideoFrameCallback(h)}clone(){return new this.constructor(this.image).copy(this)}update(){const e=this.image;"requestVideoFrameCallback"in e===!1&&e.readyState>=e.HAVE_CURRENT_DATA&&(this.needsUpdate=!0)}};X4.prototype.isVideoTexture=!0;class mw extends A0{constructor(e,t,n,r,s,o,a,l,c,u,h,f){super(null,o,a,l,c,u,r,s,h,f),this.image={width:t,height:n},this.mipmaps=e,this.flipY=!1,this.generateMipmaps=!1}}mw.prototype.isCompressedTexture=!0;class gw extends A0{constructor(e,t,n,r,s,o,a,l,c){super(e,t,n,r,s,o,a,l,c),this.needsUpdate=!0}}gw.prototype.isCanvasTexture=!0;class j4 extends A0{constructor(e,t,n,r,s,o,a,l,c,u){if(u=u!==void 0?u:Ar,u!==Ar&&u!==ao)throw new Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");n===void 0&&u===Ar&&(n=oo),n===void 0&&u===ao&&(n=Xs),super(null,r,s,o,a,l,u,n,c),this.image={width:e,height:t},this.magFilter=a!==void 0?a:r0,this.minFilter=l!==void 0?l:r0,this.flipY=!1,this.generateMipmaps=!1}}j4.prototype.isDepthTexture=!0;let vw=class Y4 extends Fe{constructor(e=1,t=8,n=0,r=Math.PI*2){super(),this.type="CircleGeometry",this.parameters={radius:e,segments:t,thetaStart:n,thetaLength:r},t=Math.max(3,t);const s=[],o=[],a=[],l=[],c=new P,u=new ee;o.push(0,0,0),a.push(0,0,1),l.push(.5,.5);for(let h=0,f=3;h<=t;h++,f+=3){const d=n+h/t*r;c.x=e*Math.cos(d),c.y=e*Math.sin(d),o.push(c.x,c.y,c.z),a.push(0,0,1),u.x=(o[f]/e+1)/2,u.y=(o[f+1]/e+1)/2,l.push(u.x,u.y)}for(let h=1;h<=t;h++)s.push(h,h+1,0);this.setIndex(s),this.setAttribute("position",new Ae(o,3)),this.setAttribute("normal",new Ae(a,3)),this.setAttribute("uv",new Ae(l,2))}static fromJSON(e){return new Y4(e.radius,e.segments,e.thetaStart,e.thetaLength)}},q4=class Q4 extends Fe{constructor(e=1,t=1,n=1,r=8,s=1,o=!1,a=0,l=Math.PI*2){super(),this.type="CylinderGeometry",this.parameters={radiusTop:e,radiusBottom:t,height:n,radialSegments:r,heightSegments:s,openEnded:o,thetaStart:a,thetaLength:l};const c=this;r=Math.floor(r),s=Math.floor(s);const u=[],h=[],f=[],d=[];let g=0;const v=[],_=n/2;let m=0;p(),o===!1&&(e>0&&y(!0),t>0&&y(!1)),this.setIndex(u),this.setAttribute("position",new Ae(h,3)),this.setAttribute("normal",new Ae(f,3)),this.setAttribute("uv",new Ae(d,2));function p(){const x=new P,w=new P;let A=0;const b=(t-e)/n;for(let L=0;L<=s;L++){const B=[],I=L/s,C=I*(t-e)+e;for(let Y=0;Y<=r;Y++){const O=Y/r,G=O*l+a,j=Math.sin(G),N=Math.cos(G);w.x=C*j,w.y=-I*n+_,w.z=C*N,h.push(w.x,w.y,w.z),x.set(j,b,N).normalize(),f.push(x.x,x.y,x.z),d.push(O,1-I),B.push(g++)}v.push(B)}for(let L=0;L.9&&b<.1&&(y<.2&&(o[p+0]+=1),x<.2&&(o[p+2]+=1),w<.2&&(o[p+4]+=1))}}function f(p){s.push(p.x,p.y,p.z)}function d(p,y){const x=p*3;y.x=e[x+0],y.y=e[x+1],y.z=e[x+2]}function g(){const p=new P,y=new P,x=new P,w=new P,A=new ee,b=new ee,L=new ee;for(let B=0,I=0;B0)l=r-1;else{l=r;break}if(r=l,n[r]===o)return r/(s-1);const u=n[r],f=n[r+1]-u,d=(o-u)/f;return(r+d)/(s-1)}getTangent(e,t){let r=e-1e-4,s=e+1e-4;r<0&&(r=0),s>1&&(s=1);const o=this.getPoint(r),a=this.getPoint(s),l=t||(o.isVector2?new ee:new P);return l.copy(a).sub(o).normalize(),l}getTangentAt(e,t){const n=this.getUtoTmapping(e);return this.getTangent(n,t)}computeFrenetFrames(e,t){const n=new P,r=[],s=[],o=[],a=new P,l=new Me;for(let d=0;d<=e;d++){const g=d/e;r[d]=this.getTangentAt(g,new P)}s[0]=new P,o[0]=new P;let c=Number.MAX_VALUE;const u=Math.abs(r[0].x),h=Math.abs(r[0].y),f=Math.abs(r[0].z);u<=c&&(c=u,n.set(1,0,0)),h<=c&&(c=h,n.set(0,1,0)),f<=c&&n.set(0,0,1),a.crossVectors(r[0],n).normalize(),s[0].crossVectors(r[0],a),o[0].crossVectors(r[0],s[0]);for(let d=1;d<=e;d++){if(s[d]=s[d-1].clone(),o[d]=o[d-1].clone(),a.crossVectors(r[d-1],r[d]),a.length()>Number.EPSILON){a.normalize();const g=Math.acos(Q0(r[d-1].dot(r[d]),-1,1));s[d].applyMatrix4(l.makeRotationAxis(a,g))}o[d].crossVectors(r[d],s[d])}if(t===!0){let d=Math.acos(Q0(s[0].dot(s[e]),-1,1));d/=e,r[0].dot(a.crossVectors(s[0],s[e]))>0&&(d=-d);for(let g=1;g<=e;g++)s[g].applyMatrix4(l.makeRotationAxis(r[g],d*g)),o[g].crossVectors(r[g],s[g])}return{tangents:r,normals:s,binormals:o}}clone(){return new this.constructor().copy(this)}copy(e){return this.arcLengthDivisions=e.arcLengthDivisions,this}toJSON(){const e={metadata:{version:4.5,type:"Curve",generator:"Curve.toJSON"}};return e.arcLengthDivisions=this.arcLengthDivisions,e.type=this.type,e}fromJSON(e){return this.arcLengthDivisions=e.arcLengthDivisions,this}}class Pl extends ut{constructor(e=0,t=0,n=1,r=1,s=0,o=Math.PI*2,a=!1,l=0){super(),this.type="EllipseCurve",this.aX=e,this.aY=t,this.xRadius=n,this.yRadius=r,this.aStartAngle=s,this.aEndAngle=o,this.aClockwise=a,this.aRotation=l}getPoint(e,t){const n=t||new ee,r=Math.PI*2;let s=this.aEndAngle-this.aStartAngle;const o=Math.abs(s)r;)s-=r;s0?0:(Math.floor(Math.abs(a)/s)+1)*s:l===0&&a===s-1&&(a=s-2,l=1);let c,u;this.closed||a>0?c=r[(a-1)%s]:(ma.subVectors(r[0],r[1]).add(r[0]),c=ma);const h=r[a%s],f=r[(a+1)%s];if(this.closed||a+2r.length-2?r.length-1:o+1],h=r[o>r.length-3?r.length-1:o+2];return n.set(l3(a,l.x,c.x,u.x,h.x),l3(a,l.y,c.y,u.y,h.y)),n}copy(e){super.copy(e),this.points=[];for(let t=0,n=e.points.length;t=n){const o=r[s]-n,a=this.curves[s],l=a.getLength(),c=l===0?0:1-o/l;return a.getPointAt(c,t)}s++}return null}getLength(){const e=this.getCurveLengths();return e[e.length-1]}updateArcLengths(){this.needsUpdate=!0,this.cacheLengths=null,this.getCurveLengths()}getCurveLengths(){if(this.cacheLengths&&this.cacheLengths.length===this.curves.length)return this.cacheLengths;const e=[];let t=0;for(let n=0,r=this.curves.length;n1&&!t[t.length-1].equals(t[0])&&t.push(t[0]),t}copy(e){super.copy(e),this.curves=[];for(let t=0,n=e.curves.length;t0){const h=c.getPoint(0);h.equals(this.currentPoint)||this.lineTo(h.x,h.y)}this.curves.push(c);const u=c.getPoint(1);return this.currentPoint.copy(u),this}copy(e){return super.copy(e),this.currentPoint.copy(e.currentPoint),this}toJSON(){const e=super.toJSON();return e.currentPoint=this.currentPoint.toArray(),e}fromJSON(e){return super.fromJSON(e),this.currentPoint.fromArray(e.currentPoint),this}}class jn extends qa{constructor(e){super(e),this.uuid=yt(),this.type="Shape",this.holes=[]}getPointsHoles(e){const t=[];for(let n=0,r=this.holes.length;n80*t){a=c=i[0],l=u=i[1];for(let g=t;gc&&(c=h),f>u&&(u=f);d=Math.max(c-a,u-l),d=d!==0?1/d:0}return po(s,o,t,a,l,d),o}};function t5(i,e,t,n,r){let s,o;if(r===Xw(i,e,t,n)>0)for(s=e;s=e;s-=n)o=c3(s,i[s],i[s+1],o);return o&&Fl(o,o.next)&&(go(o),o=o.next),o}function $n(i,e){if(!i)return i;e||(e=i);let t=i,n;do if(n=!1,!t.steiner&&(Fl(t,t.next)||v0(t.prev,t,t.next)===0)){if(go(t),t=e=t.prev,t===t.next)break;n=!0}else t=t.next;while(n||t!==e);return e}function po(i,e,t,n,r,s,o){if(!i)return;!o&&s&&Bw(i,n,r,s);let a=i,l,c;for(;i.prev!==i.next;){if(l=i.prev,c=i.next,s?Rw(i,n,r,s):Cw(i)){e.push(l.i/t),e.push(i.i/t),e.push(c.i/t),go(i),i=c.next,a=c.next;continue}if(i=c,i===a){o?o===1?(i=Fw($n(i),e,t),po(i,e,t,n,r,s,2)):o===2&&Iw(i,e,t,n,r,s):po($n(i),e,t,n,r,s,1);break}}}function Cw(i){const e=i.prev,t=i,n=i.next;if(v0(e,t,n)>=0)return!1;let r=i.next.next;for(;r!==i.prev;){if(xr(e.x,e.y,t.x,t.y,n.x,n.y,r.x,r.y)&&v0(r.prev,r,r.next)>=0)return!1;r=r.next}return!0}function Rw(i,e,t,n){const r=i.prev,s=i,o=i.next;if(v0(r,s,o)>=0)return!1;const a=r.xs.x?r.x>o.x?r.x:o.x:s.x>o.x?s.x:o.x,u=r.y>s.y?r.y>o.y?r.y:o.y:s.y>o.y?s.y:o.y,h=oc(a,l,e,t,n),f=oc(c,u,e,t,n);let d=i.prevZ,g=i.nextZ;for(;d&&d.z>=h&&g&&g.z<=f;){if(d!==i.prev&&d!==i.next&&xr(r.x,r.y,s.x,s.y,o.x,o.y,d.x,d.y)&&v0(d.prev,d,d.next)>=0||(d=d.prevZ,g!==i.prev&&g!==i.next&&xr(r.x,r.y,s.x,s.y,o.x,o.y,g.x,g.y)&&v0(g.prev,g,g.next)>=0))return!1;g=g.nextZ}for(;d&&d.z>=h;){if(d!==i.prev&&d!==i.next&&xr(r.x,r.y,s.x,s.y,o.x,o.y,d.x,d.y)&&v0(d.prev,d,d.next)>=0)return!1;d=d.prevZ}for(;g&&g.z<=f;){if(g!==i.prev&&g!==i.next&&xr(r.x,r.y,s.x,s.y,o.x,o.y,g.x,g.y)&&v0(g.prev,g,g.next)>=0)return!1;g=g.nextZ}return!0}function Fw(i,e,t){let n=i;do{const r=n.prev,s=n.next.next;!Fl(r,s)&&n5(r,n,n.next,s)&&mo(r,s)&&mo(s,r)&&(e.push(r.i/t),e.push(n.i/t),e.push(s.i/t),go(n),go(n.next),n=i=s),n=n.next}while(n!==i);return $n(n)}function Iw(i,e,t,n,r,s){let o=i;do{let a=o.next.next;for(;a!==o.prev;){if(o.i!==a.i&&Hw(o,a)){let l=i5(o,a);o=$n(o,o.next),l=$n(l,l.next),po(o,e,t,n,r,s),po(l,e,t,n,r,s);return}a=a.next}o=o.next}while(o!==i)}function Dw(i,e,t,n){const r=[];let s,o,a,l,c;for(s=0,o=e.length;s=t.next.y&&t.next.y!==t.y){const f=t.x+(r-t.y)*(t.next.x-t.x)/(t.next.y-t.y);if(f<=n&&f>s){if(s=f,f===n){if(r===t.y)return t;if(r===t.next.y)return t.next}o=t.x=t.x&&t.x>=l&&n!==t.x&&xr(ro.x||t.x===o.x&&zw(o,t)))&&(o=t,u=h)),t=t.next;while(t!==a);return o}function zw(i,e){return v0(i.prev,i,e.prev)<0&&v0(e.next,i,i.next)<0}function Bw(i,e,t,n){let r=i;do r.z===null&&(r.z=oc(r.x,r.y,e,t,n)),r.prevZ=r.prev,r.nextZ=r.next,r=r.next;while(r!==i);r.prevZ.nextZ=null,r.prevZ=null,kw(r)}function kw(i){let e,t,n,r,s,o,a,l,c=1;do{for(t=i,i=null,s=null,o=0;t;){for(o++,n=t,a=0,e=0;e0||l>0&&n;)a!==0&&(l===0||!n||t.z<=n.z)?(r=t,t=t.nextZ,a--):(r=n,n=n.nextZ,l--),s?s.nextZ=r:i=r,r.prevZ=s,s=r;t=n}s.nextZ=null,c*=2}while(o>1);return i}function oc(i,e,t,n,r){return i=32767*(i-t)*r,e=32767*(e-n)*r,i=(i|i<<8)&16711935,i=(i|i<<4)&252645135,i=(i|i<<2)&858993459,i=(i|i<<1)&1431655765,e=(e|e<<8)&16711935,e=(e|e<<4)&252645135,e=(e|e<<2)&858993459,e=(e|e<<1)&1431655765,i|e<<1}function Gw(i){let e=i,t=i;do(e.x=0&&(i-o)*(n-a)-(t-o)*(e-a)>=0&&(t-o)*(s-a)-(r-o)*(n-a)>=0}function Hw(i,e){return i.next.i!==e.i&&i.prev.i!==e.i&&!Vw(i,e)&&(mo(i,e)&&mo(e,i)&&Ww(i,e)&&(v0(i.prev,i,e.prev)||v0(i,e.prev,e))||Fl(i,e)&&v0(i.prev,i,i.next)>0&&v0(e.prev,e,e.next)>0)}function v0(i,e,t){return(e.y-i.y)*(t.x-e.x)-(e.x-i.x)*(t.y-e.y)}function Fl(i,e){return i.x===e.x&&i.y===e.y}function n5(i,e,t,n){const r=va(v0(i,e,t)),s=va(v0(i,e,n)),o=va(v0(t,n,i)),a=va(v0(t,n,e));return!!(r!==s&&o!==a||r===0&&ga(i,t,e)||s===0&&ga(i,n,e)||o===0&&ga(t,i,n)||a===0&&ga(t,e,n))}function ga(i,e,t){return e.x<=Math.max(i.x,t.x)&&e.x>=Math.min(i.x,t.x)&&e.y<=Math.max(i.y,t.y)&&e.y>=Math.min(i.y,t.y)}function va(i){return i>0?1:i<0?-1:0}function Vw(i,e){let t=i;do{if(t.i!==i.i&&t.next.i!==i.i&&t.i!==e.i&&t.next.i!==e.i&&n5(t,t.next,i,e))return!0;t=t.next}while(t!==i);return!1}function mo(i,e){return v0(i.prev,i,i.next)<0?v0(i,e,i.next)>=0&&v0(i,i.prev,e)>=0:v0(i,e,i.prev)<0||v0(i,i.next,e)<0}function Ww(i,e){let t=i,n=!1;const r=(i.x+e.x)/2,s=(i.y+e.y)/2;do t.y>s!=t.next.y>s&&t.next.y!==t.y&&r<(t.next.x-t.x)*(s-t.y)/(t.next.y-t.y)+t.x&&(n=!n),t=t.next;while(t!==i);return n}function i5(i,e){const t=new ac(i.i,i.x,i.y),n=new ac(e.i,e.x,e.y),r=i.next,s=e.prev;return i.next=e,e.prev=i,t.next=r,r.prev=t,n.next=t,t.prev=n,s.next=n,n.prev=s,n}function c3(i,e,t,n){const r=new ac(i,e,t);return n?(r.next=n.next,r.prev=n,n.next.prev=r,n.next=r):(r.prev=r,r.next=r),r}function go(i){i.next.prev=i.prev,i.prev.next=i.next,i.prevZ&&(i.prevZ.nextZ=i.nextZ),i.nextZ&&(i.nextZ.prevZ=i.prevZ)}function ac(i,e,t){this.i=i,this.x=e,this.y=t,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function Xw(i,e,t,n){let r=0;for(let s=e,o=t-n;s2&&i[e-1].equals(i[0])&&i.pop()}function h3(i,e){for(let t=0;tNumber.EPSILON){const he=Math.sqrt(oe),xe=Math.sqrt(q*q+H*H),ge=E.x-U/he,z=E.y+S/he,fe=F.x-H/xe,ne=F.y+q/xe,Te=((fe-ge)*H-(ne-z)*q)/(S*H-U*q);W=ge+S*Te-M.x,X=z+U*Te-M.y;const D=W*W+X*X;if(D<=2)return new ee(W,X);T=Math.sqrt(D/2)}else{let he=!1;S>Number.EPSILON?q>Number.EPSILON&&(he=!0):S<-Number.EPSILON?q<-Number.EPSILON&&(he=!0):Math.sign(U)===Math.sign(H)&&(he=!0),he?(W=-U,X=S,T=Math.sqrt(oe)):(W=S,X=U,T=Math.sqrt(oe/2))}return new ee(W/T,X/T)}const le=[];for(let M=0,E=G.length,F=E-1,W=M+1;M=0;M--){const E=M/_,F=d*Math.cos(E*Math.PI/2),W=g*Math.sin(E*Math.PI/2)+v;for(let X=0,T=G.length;X=0;){const W=F;let X=F-1;X<0&&(X=M.length-1);for(let T=0,S=u+_*2;T0)&&d.push(y,x,A),(m!==n-1||l0!=e>0&&this.version++,this._sheen=e}get clearcoat(){return this._clearcoat}set clearcoat(e){this._clearcoat>0!=e>0&&this.version++,this._clearcoat=e}get transmission(){return this._transmission}set transmission(e){this._transmission>0!=e>0&&this.version++,this._transmission=e}copy(e){return super.copy(e),this.defines={STANDARD:"",PHYSICAL:""},this.clearcoat=e.clearcoat,this.clearcoatMap=e.clearcoatMap,this.clearcoatRoughness=e.clearcoatRoughness,this.clearcoatRoughnessMap=e.clearcoatRoughnessMap,this.clearcoatNormalMap=e.clearcoatNormalMap,this.clearcoatNormalScale.copy(e.clearcoatNormalScale),this.ior=e.ior,this.sheen=e.sheen,this.sheenColor.copy(e.sheenColor),this.sheenColorMap=e.sheenColorMap,this.sheenRoughness=e.sheenRoughness,this.sheenRoughnessMap=e.sheenRoughnessMap,this.transmission=e.transmission,this.transmissionMap=e.transmissionMap,this.thickness=e.thickness,this.thicknessMap=e.thicknessMap,this.attenuationDistance=e.attenuationDistance,this.attenuationColor.copy(e.attenuationColor),this.specularIntensity=e.specularIntensity,this.specularIntensityMap=e.specularIntensityMap,this.specularColor.copy(e.specularColor),this.specularColorMap=e.specularColorMap,this}}si.prototype.isMeshPhysicalMaterial=!0;class Ks extends D0{constructor(e){super(),this.type="MeshPhongMaterial",this.color=new be(16777215),this.specular=new be(1118481),this.shininess=30,this.map=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new be(0),this.emissiveIntensity=1,this.emissiveMap=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=Oi,this.normalScale=new ee(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.specularMap=null,this.alphaMap=null,this.envMap=null,this.combine=xl,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.flatShading=!1,this.setValues(e)}copy(e){return super.copy(e),this.color.copy(e.color),this.specular.copy(e.specular),this.shininess=e.shininess,this.map=e.map,this.lightMap=e.lightMap,this.lightMapIntensity=e.lightMapIntensity,this.aoMap=e.aoMap,this.aoMapIntensity=e.aoMapIntensity,this.emissive.copy(e.emissive),this.emissiveMap=e.emissiveMap,this.emissiveIntensity=e.emissiveIntensity,this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.specularMap=e.specularMap,this.alphaMap=e.alphaMap,this.envMap=e.envMap,this.combine=e.combine,this.reflectivity=e.reflectivity,this.refractionRatio=e.refractionRatio,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.wireframeLinecap=e.wireframeLinecap,this.wireframeLinejoin=e.wireframeLinejoin,this.flatShading=e.flatShading,this}}Ks.prototype.isMeshPhongMaterial=!0;class v5 extends D0{constructor(e){super(),this.defines={TOON:""},this.type="MeshToonMaterial",this.color=new be(16777215),this.map=null,this.gradientMap=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new be(0),this.emissiveIntensity=1,this.emissiveMap=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=Oi,this.normalScale=new ee(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.alphaMap=null,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.setValues(e)}copy(e){return super.copy(e),this.color.copy(e.color),this.map=e.map,this.gradientMap=e.gradientMap,this.lightMap=e.lightMap,this.lightMapIntensity=e.lightMapIntensity,this.aoMap=e.aoMap,this.aoMapIntensity=e.aoMapIntensity,this.emissive.copy(e.emissive),this.emissiveMap=e.emissiveMap,this.emissiveIntensity=e.emissiveIntensity,this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.alphaMap=e.alphaMap,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.wireframeLinecap=e.wireframeLinecap,this.wireframeLinejoin=e.wireframeLinejoin,this}}v5.prototype.isMeshToonMaterial=!0;class x5 extends D0{constructor(e){super(),this.type="MeshNormalMaterial",this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=Oi,this.normalScale=new ee(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.wireframe=!1,this.wireframeLinewidth=1,this.fog=!1,this.flatShading=!1,this.setValues(e)}copy(e){return super.copy(e),this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.flatShading=e.flatShading,this}}x5.prototype.isMeshNormalMaterial=!0;class m9 extends D0{constructor(e){super(),this.type="MeshLambertMaterial",this.color=new be(16777215),this.map=null,this.lightMap=null,this.lightMapIntensity=1,this.aoMap=null,this.aoMapIntensity=1,this.emissive=new be(0),this.emissiveIntensity=1,this.emissiveMap=null,this.specularMap=null,this.alphaMap=null,this.envMap=null,this.combine=xl,this.reflectivity=1,this.refractionRatio=.98,this.wireframe=!1,this.wireframeLinewidth=1,this.wireframeLinecap="round",this.wireframeLinejoin="round",this.setValues(e)}copy(e){return super.copy(e),this.color.copy(e.color),this.map=e.map,this.lightMap=e.lightMap,this.lightMapIntensity=e.lightMapIntensity,this.aoMap=e.aoMap,this.aoMapIntensity=e.aoMapIntensity,this.emissive.copy(e.emissive),this.emissiveMap=e.emissiveMap,this.emissiveIntensity=e.emissiveIntensity,this.specularMap=e.specularMap,this.alphaMap=e.alphaMap,this.envMap=e.envMap,this.combine=e.combine,this.reflectivity=e.reflectivity,this.refractionRatio=e.refractionRatio,this.wireframe=e.wireframe,this.wireframeLinewidth=e.wireframeLinewidth,this.wireframeLinecap=e.wireframeLinecap,this.wireframeLinejoin=e.wireframeLinejoin,this}}m9.prototype.isMeshLambertMaterial=!0;class y5 extends D0{constructor(e){super(),this.defines={MATCAP:""},this.type="MeshMatcapMaterial",this.color=new be(16777215),this.matcap=null,this.map=null,this.bumpMap=null,this.bumpScale=1,this.normalMap=null,this.normalMapType=Oi,this.normalScale=new ee(1,1),this.displacementMap=null,this.displacementScale=1,this.displacementBias=0,this.alphaMap=null,this.flatShading=!1,this.setValues(e)}copy(e){return super.copy(e),this.defines={MATCAP:""},this.color.copy(e.color),this.matcap=e.matcap,this.map=e.map,this.bumpMap=e.bumpMap,this.bumpScale=e.bumpScale,this.normalMap=e.normalMap,this.normalMapType=e.normalMapType,this.normalScale.copy(e.normalScale),this.displacementMap=e.displacementMap,this.displacementScale=e.displacementScale,this.displacementBias=e.displacementBias,this.alphaMap=e.alphaMap,this.flatShading=e.flatShading,this}}y5.prototype.isMeshMatcapMaterial=!0;class rM extends ri{constructor(e){super(),this.type="LineDashedMaterial",this.scale=1,this.dashSize=3,this.gapSize=1,this.setValues(e)}copy(e){return super.copy(e),this.scale=e.scale,this.dashSize=e.dashSize,this.gapSize=e.gapSize,this}}rM.prototype.isLineDashedMaterial=!0;const p0={arraySlice:function(i,e,t){return p0.isTypedArray(i)?new i.constructor(i.subarray(e,t!==void 0?t:i.length)):i.slice(e,t)},convertArray:function(i,e,t){return!i||!t&&i.constructor===e?i:typeof e.BYTES_PER_ELEMENT=="number"?new e(i):Array.prototype.slice.call(i)},isTypedArray:function(i){return ArrayBuffer.isView(i)&&!(i instanceof DataView)},getKeyframeOrder:function(i){function e(r,s){return i[r]-i[s]}const t=i.length,n=new Array(t);for(let r=0;r!==t;++r)n[r]=r;return n.sort(e),n},sortedArray:function(i,e,t){const n=i.length,r=new i.constructor(n);for(let s=0,o=0;o!==n;++s){const a=t[s]*e;for(let l=0;l!==e;++l)r[o++]=i[a+l]}return r},flattenJSON:function(i,e,t,n){let r=1,s=i[0];for(;s!==void 0&&s[n]===void 0;)s=i[r++];if(s===void 0)return;let o=s[n];if(o!==void 0)if(Array.isArray(o))do o=s[n],o!==void 0&&(e.push(s.time),t.push.apply(t,o)),s=i[r++];while(s!==void 0);else if(o.toArray!==void 0)do o=s[n],o!==void 0&&(e.push(s.time),o.toArray(t,t.length)),s=i[r++];while(s!==void 0);else do o=s[n],o!==void 0&&(e.push(s.time),t.push(o)),s=i[r++];while(s!==void 0)},subclip:function(i,e,t,n,r=30){const s=i.clone();s.name=e;const o=[];for(let l=0;l=n)){h.push(c.times[d]);for(let v=0;vs.tracks[l].times[0]&&(a=s.tracks[l].times[0]);for(let l=0;l=a.times[g]){const m=g*h+u,p=m+h-u;v=p0.arraySlice(a.values,m,p)}else{const m=a.createInterpolant(),p=u,y=h-u;m.evaluate(s),v=p0.arraySlice(m.resultBuffer,p,y)}l==="quaternion"&&new S0().fromArray(v).normalize().conjugate().toArray(v);const _=c.times.length;for(let m=0;m<_;++m){const p=m*d+f;if(l==="quaternion")S0.multiplyQuaternionsFlat(c.values,p,v,0,c.values,p);else{const y=d-f*2;for(let x=0;x=s)){const a=t[1];e=s)break t}o=n,n=0;break n}break e}for(;n>>1;et;)--o;if(++o,s!==0||o!==r){s>=o&&(o=Math.max(o,1),s=o-1);const a=this.getValueSize();this.times=p0.arraySlice(n,s,o),this.values=p0.arraySlice(this.values,s*a,o*a)}return this}validate(){let e=!0;const t=this.getValueSize();t-Math.floor(t)!==0&&(console.error("THREE.KeyframeTrack: Invalid value size in track.",this),e=!1);const n=this.times,r=this.values,s=n.length;s===0&&(console.error("THREE.KeyframeTrack: Track is empty.",this),e=!1);let o=null;for(let a=0;a!==s;a++){const l=n[a];if(typeof l=="number"&&isNaN(l)){console.error("THREE.KeyframeTrack: Time is not a valid number.",this,a,l),e=!1;break}if(o!==null&&o>l){console.error("THREE.KeyframeTrack: Out of order keys.",this,a,l,o),e=!1;break}o=l}if(r!==void 0&&p0.isTypedArray(r))for(let a=0,l=r.length;a!==l;++a){const c=r[a];if(isNaN(c)){console.error("THREE.KeyframeTrack: Value is not a valid number.",this,a,c),e=!1;break}}return e}optimize(){const e=p0.arraySlice(this.times),t=p0.arraySlice(this.values),n=this.getValueSize(),r=this.getInterpolation()===Wl,s=e.length-1;let o=1;for(let a=1;a0){e[o]=e[s];for(let a=s*n,l=o*n,c=0;c!==n;++c)t[l+c]=t[a+c];++o}return o!==e.length?(this.times=p0.arraySlice(e,0,o),this.values=p0.arraySlice(t,0,o*n)):(this.times=e,this.values=t),this}clone(){const e=p0.arraySlice(this.times,0),t=p0.arraySlice(this.values,0),n=this.constructor,r=new n(this.name,e,t);return r.createInterpolant=this.createInterpolant,r}}Jt.prototype.TimeBufferType=Float32Array;Jt.prototype.ValueBufferType=Float32Array;Jt.prototype.DefaultInterpolation=Or;class rs extends Jt{}rs.prototype.ValueTypeName="bool";rs.prototype.ValueBufferType=Array;rs.prototype.DefaultInterpolation=lo;rs.prototype.InterpolantFactoryMethodLinear=void 0;rs.prototype.InterpolantFactoryMethodSmooth=void 0;class b5 extends Jt{}b5.prototype.ValueTypeName="color";class Br extends Jt{}Br.prototype.ValueTypeName="number";class aM extends gn{constructor(e,t,n,r){super(e,t,n,r)}interpolate_(e,t,n,r){const s=this.resultBuffer,o=this.sampleValues,a=this.valueSize,l=(n-t)/(r-t);let c=e*a;for(let u=c+a;c!==u;c+=4)S0.slerpFlat(s,0,o,c-a,o,c,l);return s}}class ei extends Jt{InterpolantFactoryMethodLinear(e){return new aM(this.times,this.values,this.getValueSize(),e)}}ei.prototype.ValueTypeName="quaternion";ei.prototype.DefaultInterpolation=Or;ei.prototype.InterpolantFactoryMethodSmooth=void 0;class ss extends Jt{}ss.prototype.ValueTypeName="string";ss.prototype.ValueBufferType=Array;ss.prototype.DefaultInterpolation=lo;ss.prototype.InterpolantFactoryMethodLinear=void 0;ss.prototype.InterpolantFactoryMethodSmooth=void 0;class kr extends Jt{}kr.prototype.ValueTypeName="vector";class Qa{constructor(e,t=-1,n,r=qc){this.name=e,this.tracks=n,this.duration=t,this.blendMode=r,this.uuid=yt(),this.duration<0&&this.resetDuration()}static parse(e){const t=[],n=e.tracks,r=1/(e.fps||1);for(let o=0,a=n.length;o!==a;++o)t.push(cM(n[o]).scale(r));const s=new this(e.name,e.duration,t,e.blendMode);return s.uuid=e.uuid,s}static toJSON(e){const t=[],n=e.tracks,r={name:e.name,duration:e.duration,tracks:t,uuid:e.uuid,blendMode:e.blendMode};for(let s=0,o=n.length;s!==o;++s)t.push(Jt.toJSON(n[s]));return r}static CreateFromMorphTargetSequence(e,t,n,r){const s=t.length,o=[];for(let a=0;a1){const h=u[1];let f=r[h];f||(r[h]=f=[]),f.push(c)}}const o=[];for(const a in r)o.push(this.CreateFromMorphTargetSequence(a,r[a],t,n));return o}static parseAnimation(e,t){if(!e)return console.error("THREE.AnimationClip: No animation in JSONLoader data."),null;const n=function(h,f,d,g,v){if(d.length!==0){const _=[],m=[];p0.flattenJSON(d,_,m,g),_.length!==0&&v.push(new h(f,_,m))}},r=[],s=e.name||"default",o=e.fps||30,a=e.blendMode;let l=e.length||-1;const c=e.hierarchy||[];for(let h=0;h{t&&t(s),this.manager.itemEnd(e)},0),s;if(cn[e]!==void 0){cn[e].push({onLoad:t,onProgress:n,onError:r});return}cn[e]=[],cn[e].push({onLoad:t,onProgress:n,onError:r});const o=new Request(e,{headers:new Headers(this.requestHeader),credentials:this.withCredentials?"include":"same-origin"});fetch(o).then(a=>{if(a.status===200||a.status===0){a.status===0&&console.warn("THREE.FileLoader: HTTP Status 0 received.");const l=cn[e],c=a.body.getReader(),u=a.headers.get("Content-Length"),h=u?parseInt(u):0,f=h!==0;let d=0;return new ReadableStream({start(g){v();function v(){c.read().then(({done:_,value:m})=>{if(_)g.close();else{d+=m.byteLength;const p=new ProgressEvent("progress",{lengthComputable:f,loaded:d,total:h});for(let y=0,x=l.length;y{const l=new Response(a);switch(this.responseType){case"arraybuffer":return l.arrayBuffer();case"blob":return l.blob();case"document":return l.text().then(c=>new DOMParser().parseFromString(c,this.mimeType));case"json":return l.json();default:return l.text()}}).then(a=>{Gr.add(e,a);const l=cn[e];delete cn[e];for(let c=0,u=l.length;c{const l=cn[e];delete cn[e];for(let c=0,u=l.length;c"u"&&console.warn("THREE.ImageBitmapLoader: createImageBitmap() not supported."),typeof fetch>"u"&&console.warn("THREE.ImageBitmapLoader: fetch() not supported."),this.options={premultiplyAlpha:"none"}}setOptions(e){return this.options=e,this}load(e,t,n,r){e===void 0&&(e=""),this.path!==void 0&&(e=this.path+e),e=this.manager.resolveURL(e);const s=this,o=Gr.get(e);if(o!==void 0)return s.manager.itemStart(e),setTimeout(function(){t&&t(o),s.manager.itemEnd(e)},0),o;const a={};a.credentials=this.crossOrigin==="anonymous"?"same-origin":"include",a.headers=this.requestHeader,fetch(e,a).then(function(l){return l.blob()}).then(function(l){return createImageBitmap(l,Object.assign(s.options,{colorSpaceConversion:"none"}))}).then(function(l){Gr.add(e,l),t&&t(l),s.manager.itemEnd(e)}).catch(function(l){r&&r(l),s.manager.itemError(e),s.manager.itemEnd(e)}),s.manager.itemStart(e)}}C5.prototype.isImageBitmapLoader=!0;let xa;const dM={getContext:function(){return xa===void 0&&(xa=new(window.AudioContext||window.webkitAudioContext)),xa},setContext:function(i){xa=i}};class pM extends Bt{constructor(e){super(e)}load(e,t,n,r){const s=this,o=new Po(this.manager);o.setResponseType("arraybuffer"),o.setPath(this.path),o.setRequestHeader(this.requestHeader),o.setWithCredentials(this.withCredentials),o.load(e,function(a){try{const l=a.slice(0);dM.getContext().decodeAudioData(l,function(u){t(u)})}catch(l){r?r(l):console.error(l),s.manager.itemError(e)}},n,r)}}class mM extends x9{constructor(e,t,n=1){super(void 0,n);const r=new be().set(e),s=new be().set(t),o=new P(r.r,r.g,r.b),a=new P(s.r,s.g,s.b),l=Math.sqrt(Math.PI),c=l*Math.sqrt(.75);this.sh.coefficients[0].copy(o).add(a).multiplyScalar(l),this.sh.coefficients[1].copy(o).sub(a).multiplyScalar(c)}}mM.prototype.isHemisphereLightProbe=!0;class gM extends x9{constructor(e,t=1){super(void 0,t);const n=new be().set(e);this.sh.coefficients[0].set(n.r,n.g,n.b).multiplyScalar(2*Math.sqrt(Math.PI))}}gM.prototype.isAmbientLightProbe=!0;class vM{constructor(e=!0){this.autoStart=e,this.startTime=0,this.oldTime=0,this.elapsedTime=0,this.running=!1}start(){this.startTime=g3(),this.oldTime=this.startTime,this.elapsedTime=0,this.running=!0}stop(){this.getElapsedTime(),this.running=!1,this.autoStart=!1}getElapsedTime(){return this.getDelta(),this.elapsedTime}getDelta(){let e=0;if(this.autoStart&&!this.running)return this.start(),0;if(this.running){const t=g3();e=(t-this.oldTime)/1e3,this.oldTime=t,this.elapsedTime+=e}return e}}function g3(){return(typeof performance>"u"?Date:performance).now()}class xM extends t0{constructor(e){super(),this.type="Audio",this.listener=e,this.context=e.context,this.gain=this.context.createGain(),this.gain.connect(e.getInput()),this.autoplay=!1,this.buffer=null,this.detune=0,this.loop=!1,this.loopStart=0,this.loopEnd=0,this.offset=0,this.duration=void 0,this.playbackRate=1,this.isPlaying=!1,this.hasPlaybackControl=!0,this.source=null,this.sourceType="empty",this._startedAt=0,this._progress=0,this._connected=!1,this.filters=[]}getOutput(){return this.gain}setNodeSource(e){return this.hasPlaybackControl=!1,this.sourceType="audioNode",this.source=e,this.connect(),this}setMediaElementSource(e){return this.hasPlaybackControl=!1,this.sourceType="mediaNode",this.source=this.context.createMediaElementSource(e),this.connect(),this}setMediaStreamSource(e){return this.hasPlaybackControl=!1,this.sourceType="mediaStreamNode",this.source=this.context.createMediaStreamSource(e),this.connect(),this}setBuffer(e){return this.buffer=e,this.sourceType="buffer",this.autoplay&&this.play(),this}play(e=0){if(this.isPlaying===!0){console.warn("THREE.Audio: Audio is already playing.");return}if(this.hasPlaybackControl===!1){console.warn("THREE.Audio: this Audio has no playback control.");return}this._startedAt=this.context.currentTime+e;const t=this.context.createBufferSource();return t.buffer=this.buffer,t.loop=this.loop,t.loopStart=this.loopStart,t.loopEnd=this.loopEnd,t.onended=this.onEnded.bind(this),t.start(this._startedAt,this._progress+this.offset,this.duration),this.isPlaying=!0,this.source=t,this.setDetune(this.detune),this.setPlaybackRate(this.playbackRate),this.connect()}pause(){if(this.hasPlaybackControl===!1){console.warn("THREE.Audio: this Audio has no playback control.");return}return this.isPlaying===!0&&(this._progress+=Math.max(this.context.currentTime-this._startedAt,0)*this.playbackRate,this.loop===!0&&(this._progress=this._progress%(this.duration||this.buffer.duration)),this.source.stop(),this.source.onended=null,this.isPlaying=!1),this}stop(){if(this.hasPlaybackControl===!1){console.warn("THREE.Audio: this Audio has no playback control.");return}return this._progress=0,this.source.stop(),this.source.onended=null,this.isPlaying=!1,this}connect(){if(this.filters.length>0){this.source.connect(this.filters[0]);for(let e=1,t=this.filters.length;e0){this.source.disconnect(this.filters[0]);for(let e=1,t=this.filters.length;e0&&this._mixBufferRegionAdditive(n,r,this._addIndex*t,1,t);for(let l=t,c=t+t;l!==c;++l)if(n[l]!==n[l+t]){a.setValue(n,r);break}}saveOriginalState(){const e=this.binding,t=this.buffer,n=this.valueSize,r=n*this._origIndex;e.getValue(t,r);for(let s=n,o=r;s!==o;++s)t[s]=t[r+s%n];this._setIdentity(),this.cumulativeWeight=0,this.cumulativeWeightAdditive=0}restoreOriginalState(){const e=this.valueSize*3;this.binding.setValue(this.buffer,e)}_setAdditiveIdentityNumeric(){const e=this._addIndex*this.valueSize,t=e+this.valueSize;for(let n=e;n=.5)for(let o=0;o!==s;++o)e[t+o]=e[n+o]}_slerp(e,t,n,r){S0.slerpFlat(e,t,e,t,e,n,r)}_slerpAdditive(e,t,n,r,s){const o=this._workIndex*s;S0.multiplyQuaternionsFlat(e,o,e,t,e,n),S0.slerpFlat(e,t,e,t,e,o,r)}_lerp(e,t,n,r,s){const o=1-r;for(let a=0;a!==s;++a){const l=t+a;e[l]=e[l]*o+e[n+a]*r}}_lerpAdditive(e,t,n,r,s){for(let o=0;o!==s;++o){const a=t+o;e[a]=e[a]+e[n+o]*r}}}const y9="\\[\\]\\.:\\/",_M=new RegExp("["+y9+"]","g"),_9="[^"+y9+"]",bM="[^"+y9.replace("\\.","")+"]",wM=/((?:WC+[\/:])*)/.source.replace("WC",_9),MM=/(WCOD+)?/.source.replace("WCOD",bM),SM=/(?:\.(WC+)(?:\[(.+)\])?)?/.source.replace("WC",_9),TM=/\.(WC+)(?:\[(.+)\])?/.source.replace("WC",_9),AM=new RegExp("^"+wM+MM+SM+TM+"$"),EM=["material","materials","bones"];class LM{constructor(e,t,n){const r=n||Xe.parseTrackName(t);this._targetGroup=e,this._bindings=e.subscribe_(t,r)}getValue(e,t){this.bind();const n=this._targetGroup.nCachedObjects_,r=this._bindings[n];r!==void 0&&r.getValue(e,t)}setValue(e,t){const n=this._bindings;for(let r=this._targetGroup.nCachedObjects_,s=n.length;r!==s;++r)n[r].setValue(e,t)}bind(){const e=this._bindings;for(let t=this._targetGroup.nCachedObjects_,n=e.length;t!==n;++t)e[t].bind()}unbind(){const e=this._bindings;for(let t=this._targetGroup.nCachedObjects_,n=e.length;t!==n;++t)e[t].unbind()}}class Xe{constructor(e,t,n){this.path=t,this.parsedPath=n||Xe.parseTrackName(t),this.node=Xe.findNode(e,this.parsedPath.nodeName)||e,this.rootNode=e,this.getValue=this._getValue_unbound,this.setValue=this._setValue_unbound}static create(e,t,n){return e&&e.isAnimationObjectGroup?new Xe.Composite(e,t,n):new Xe(e,t,n)}static sanitizeNodeName(e){return e.replace(/\s/g,"_").replace(_M,"")}static parseTrackName(e){const t=AM.exec(e);if(!t)throw new Error("PropertyBinding: Cannot parse trackName: "+e);const n={nodeName:t[2],objectName:t[3],objectIndex:t[4],propertyName:t[5],propertyIndex:t[6]},r=n.nodeName&&n.nodeName.lastIndexOf(".");if(r!==void 0&&r!==-1){const s=n.nodeName.substring(r+1);EM.indexOf(s)!==-1&&(n.nodeName=n.nodeName.substring(0,r),n.objectName=s)}if(n.propertyName===null||n.propertyName.length===0)throw new Error("PropertyBinding: can not parse propertyName from trackName: "+e);return n}static findNode(e,t){if(!t||t===""||t==="."||t===-1||t===e.name||t===e.uuid)return e;if(e.skeleton){const n=e.skeleton.getBoneByName(t);if(n!==void 0)return n}if(e.children){const n=function(s){for(let o=0;o0){const l=this._interpolants,c=this._propertyBindings;switch(this.blendMode){case d4:for(let u=0,h=l.length;u!==h;++u)l[u].evaluate(o),c[u].accumulateAdditive(a);break;case qc:default:for(let u=0,h=l.length;u!==h;++u)l[u].evaluate(o),c[u].accumulate(r,a)}}}_updateWeight(e){let t=0;if(this.enabled){t=this.weight;const n=this._weightInterpolant;if(n!==null){const r=n.evaluate(e)[0];t*=r,e>n.parameterPositions[1]&&(this.stopFading(),r===0&&(this.enabled=!1))}}return this._effectiveWeight=t,t}_updateTimeScale(e){let t=0;if(!this.paused){t=this.timeScale;const n=this._timeScaleInterpolant;if(n!==null){const r=n.evaluate(e)[0];t*=r,e>n.parameterPositions[1]&&(this.stopWarping(),t===0?this.paused=!0:this.timeScale=t)}}return this._effectiveTimeScale=t,t}_updateTime(e){const t=this._clip.duration,n=this.loop;let r=this.time+e,s=this._loopCount;const o=n===fv;if(e===0)return s===-1?r:o&&(s&1)===1?t-r:r;if(n===uv){s===-1&&(this._loopCount=0,this._setEndings(!0,!0,!1));e:{if(r>=t)r=t;else if(r<0)r=0;else{this.time=r;break e}this.clampWhenFinished?this.paused=!0:this.enabled=!1,this.time=r,this._mixer.dispatchEvent({type:"finished",action:this,direction:e<0?-1:1})}}else{if(s===-1&&(e>=0?(s=0,this._setEndings(!0,this.repetitions===0,o)):this._setEndings(this.repetitions===0,!0,o)),r>=t||r<0){const a=Math.floor(r/t);r-=t*a,s+=Math.abs(a);const l=this.repetitions-s;if(l<=0)this.clampWhenFinished?this.paused=!0:this.enabled=!1,r=e>0?t:0,this.time=r,this._mixer.dispatchEvent({type:"finished",action:this,direction:e>0?1:-1});else{if(l===1){const c=e<0;this._setEndings(c,!c,o)}else this._setEndings(!1,!1,o);this._loopCount=s,this.time=r,this._mixer.dispatchEvent({type:"loop",action:this,loopDelta:a})}}else this.time=r;if(o&&(s&1)===1)return t-r}return r}_setEndings(e,t,n){const r=this._interpolantSettings;n?(r.endingStart=vr,r.endingEnd=vr):(e?r.endingStart=this.zeroSlopeAtStart?vr:gr:r.endingStart=Xa,t?r.endingEnd=this.zeroSlopeAtEnd?vr:gr:r.endingEnd=Xa)}_scheduleFading(e,t,n){const r=this._mixer,s=r.time;let o=this._weightInterpolant;o===null&&(o=r._lendControlInterpolant(),this._weightInterpolant=o);const a=o.parameterPositions,l=o.sampleValues;return a[0]=s,l[0]=t,a[1]=s+e,l[1]=n,this}}class CM extends ni{constructor(e){super(),this._root=e,this._initMemoryManager(),this._accuIndex=0,this.time=0,this.timeScale=1}_bindAction(e,t){const n=e._localRoot||this._root,r=e._clip.tracks,s=r.length,o=e._propertyBindings,a=e._interpolants,l=n.uuid,c=this._bindingsByRootAndName;let u=c[l];u===void 0&&(u={},c[l]=u);for(let h=0;h!==s;++h){const f=r[h],d=f.name;let g=u[d];if(g!==void 0)o[h]=g;else{if(g=o[h],g!==void 0){g._cacheIndex===null&&(++g.referenceCount,this._addInactiveBinding(g,l,d));continue}const v=t&&t._propertyBindings[h].binding.parsedPath;g=new yM(Xe.create(n,d,v),f.ValueTypeName,f.getValueSize()),++g.referenceCount,this._addInactiveBinding(g,l,d),o[h]=g}a[h].resultBuffer=g.buffer}}_activateAction(e){if(!this._isActiveAction(e)){if(e._cacheIndex===null){const n=(e._localRoot||this._root).uuid,r=e._clip.uuid,s=this._actionsByClip[r];this._bindAction(e,s&&s.knownActions[0]),this._addInactiveAction(e,r,n)}const t=e._propertyBindings;for(let n=0,r=t.length;n!==r;++n){const s=t[n];s.useCount++===0&&(this._lendBinding(s),s.saveOriginalState())}this._lendAction(e)}}_deactivateAction(e){if(this._isActiveAction(e)){const t=e._propertyBindings;for(let n=0,r=t.length;n!==r;++n){const s=t[n];--s.useCount===0&&(s.restoreOriginalState(),this._takeBackBinding(s))}this._takeBackAction(e)}}_initMemoryManager(){this._actions=[],this._nActiveActions=0,this._actionsByClip={},this._bindings=[],this._nActiveBindings=0,this._bindingsByRootAndName={},this._controlInterpolants=[],this._nActiveControlInterpolants=0;const e=this;this.stats={actions:{get total(){return e._actions.length},get inUse(){return e._nActiveActions}},bindings:{get total(){return e._bindings.length},get inUse(){return e._nActiveBindings}},controlInterpolants:{get total(){return e._controlInterpolants.length},get inUse(){return e._nActiveControlInterpolants}}}}_isActiveAction(e){const t=e._cacheIndex;return t!==null&&t=0;--n)e[n].stop();return this}update(e){e*=this.timeScale;const t=this._actions,n=this._nActiveActions,r=this.time+=e,s=Math.sign(e),o=this._accuIndex^=1;for(let c=0;c!==n;++c)t[c]._update(r,e,s,o);const a=this._bindings,l=this._nActiveBindings;for(let c=0;c!==l;++c)a[c].apply(o);return this}setTime(e){this.time=0;for(let t=0;tNumber.EPSILON){if(C<0&&(L=y[b],I=-I,B=y[A],C=-C),p.yB.y)continue;if(p.y===L.y){if(p.x===L.x)return!0}else{const Y=C*(p.x-L.x)-I*(p.y-L.y);if(Y===0)return!0;if(Y<0)continue;w=!w}}else{if(p.y!==L.y)continue;if(B.x<=p.x&&p.x<=L.x||L.x<=p.x&&p.x<=B.x)return!0}}return w}const s=mn.isClockWise,o=this.subPaths;if(o.length===0)return[];if(t===!0)return n(o);let a,l,c;const u=[];if(o.length===1)return l=o[0],c=new jn,c.curves=l.curves,u.push(c),u;let h=!s(o[0].getPoints());h=e?!h:h;const f=[],d=[];let g=[],v=0,_;d[v]=void 0,g[v]=[];for(let p=0,y=o.length;p1){let p=!1;const y=[];for(let x=0,w=d.length;x0&&(p||(g=f))}let m;for(let p=0,y=d.length;p65504&&(console.warn("THREE.DataUtils.toHalfFloat(): value exceeds 65504."),e=65504),F5[0]=e;const t=OM[0];let n=t>>16&32768,r=t>>12&2047;const s=t>>23&255;return s<103?n:s>142?(n|=31744,n|=(s==255?0:1)&&t&8388607,n):s<113?(r|=2048,n|=(r>>114-s)+(r>>113-s&1),n):(n|=s-112<<10|r>>1,n+=r&1,n)}}ut.create=function(i,e){return console.log("THREE.Curve.create() has been deprecated"),i.prototype=Object.create(ut.prototype),i.prototype.constructor=i,i.prototype.getPoint=e,i};qa.prototype.fromPoints=function(i){return console.warn("THREE.Path: .fromPoints() has been renamed to .setFromPoints()."),this.setFromPoints(i)};DM.prototype.setColors=function(){console.error("THREE.GridHelper: setColors() has been deprecated, pass them in the constructor instead.")};IM.prototype.update=function(){console.error("THREE.SkeletonHelper: update() no longer needs to be called.")};Bt.prototype.extractUrlBase=function(i){return console.warn("THREE.Loader: .extractUrlBase() has been deprecated. Use THREE.LoaderUtils.extractUrlBase() instead."),Ut.extractUrlBase(i)};Bt.Handlers={add:function(){console.error("THREE.Loader: Handlers.add() has been removed. Use LoadingManager.addHandler() instead.")},get:function(){console.error("THREE.Loader: Handlers.get() has been removed. Use LoadingManager.getHandler() instead.")}};Mt.prototype.center=function(i){return console.warn("THREE.Box3: .center() has been renamed to .getCenter()."),this.getCenter(i)};Mt.prototype.empty=function(){return console.warn("THREE.Box3: .empty() has been renamed to .isEmpty()."),this.isEmpty()};Mt.prototype.isIntersectionBox=function(i){return console.warn("THREE.Box3: .isIntersectionBox() has been renamed to .intersectsBox()."),this.intersectsBox(i)};Mt.prototype.isIntersectionSphere=function(i){return console.warn("THREE.Box3: .isIntersectionSphere() has been renamed to .intersectsSphere()."),this.intersectsSphere(i)};Mt.prototype.size=function(i){return console.warn("THREE.Box3: .size() has been renamed to .getSize()."),this.getSize(i)};Ui.prototype.empty=function(){return console.warn("THREE.Sphere: .empty() has been renamed to .isEmpty()."),this.isEmpty()};Ml.prototype.setFromMatrix=function(i){return console.warn("THREE.Frustum: .setFromMatrix() has been renamed to .setFromProjectionMatrix()."),this.setFromProjectionMatrix(i)};k0.prototype.flattenToArrayOffset=function(i,e){return console.warn("THREE.Matrix3: .flattenToArrayOffset() has been deprecated. Use .toArray() instead."),this.toArray(i,e)};k0.prototype.multiplyVector3=function(i){return console.warn("THREE.Matrix3: .multiplyVector3() has been removed. Use vector.applyMatrix3( matrix ) instead."),i.applyMatrix3(this)};k0.prototype.multiplyVector3Array=function(){console.error("THREE.Matrix3: .multiplyVector3Array() has been removed.")};k0.prototype.applyToBufferAttribute=function(i){return console.warn("THREE.Matrix3: .applyToBufferAttribute() has been removed. Use attribute.applyMatrix3( matrix ) instead."),i.applyMatrix3(this)};k0.prototype.applyToVector3Array=function(){console.error("THREE.Matrix3: .applyToVector3Array() has been removed.")};k0.prototype.getInverse=function(i){return console.warn("THREE.Matrix3: .getInverse() has been removed. Use matrixInv.copy( matrix ).invert(); instead."),this.copy(i).invert()};Me.prototype.extractPosition=function(i){return console.warn("THREE.Matrix4: .extractPosition() has been renamed to .copyPosition()."),this.copyPosition(i)};Me.prototype.flattenToArrayOffset=function(i,e){return console.warn("THREE.Matrix4: .flattenToArrayOffset() has been deprecated. Use .toArray() instead."),this.toArray(i,e)};Me.prototype.getPosition=function(){return console.warn("THREE.Matrix4: .getPosition() has been removed. Use Vector3.setFromMatrixPosition( matrix ) instead."),new P().setFromMatrixColumn(this,3)};Me.prototype.setRotationFromQuaternion=function(i){return console.warn("THREE.Matrix4: .setRotationFromQuaternion() has been renamed to .makeRotationFromQuaternion()."),this.makeRotationFromQuaternion(i)};Me.prototype.multiplyToArray=function(){console.warn("THREE.Matrix4: .multiplyToArray() has been removed.")};Me.prototype.multiplyVector3=function(i){return console.warn("THREE.Matrix4: .multiplyVector3() has been removed. Use vector.applyMatrix4( matrix ) instead."),i.applyMatrix4(this)};Me.prototype.multiplyVector4=function(i){return console.warn("THREE.Matrix4: .multiplyVector4() has been removed. Use vector.applyMatrix4( matrix ) instead."),i.applyMatrix4(this)};Me.prototype.multiplyVector3Array=function(){console.error("THREE.Matrix4: .multiplyVector3Array() has been removed.")};Me.prototype.rotateAxis=function(i){console.warn("THREE.Matrix4: .rotateAxis() has been removed. Use Vector3.transformDirection( matrix ) instead."),i.transformDirection(this)};Me.prototype.crossVector=function(i){return console.warn("THREE.Matrix4: .crossVector() has been removed. Use vector.applyMatrix4( matrix ) instead."),i.applyMatrix4(this)};Me.prototype.translate=function(){console.error("THREE.Matrix4: .translate() has been removed.")};Me.prototype.rotateX=function(){console.error("THREE.Matrix4: .rotateX() has been removed.")};Me.prototype.rotateY=function(){console.error("THREE.Matrix4: .rotateY() has been removed.")};Me.prototype.rotateZ=function(){console.error("THREE.Matrix4: .rotateZ() has been removed.")};Me.prototype.rotateByAxis=function(){console.error("THREE.Matrix4: .rotateByAxis() has been removed.")};Me.prototype.applyToBufferAttribute=function(i){return console.warn("THREE.Matrix4: .applyToBufferAttribute() has been removed. Use attribute.applyMatrix4( matrix ) instead."),i.applyMatrix4(this)};Me.prototype.applyToVector3Array=function(){console.error("THREE.Matrix4: .applyToVector3Array() has been removed.")};Me.prototype.makeFrustum=function(i,e,t,n,r,s){return console.warn("THREE.Matrix4: .makeFrustum() has been removed. Use .makePerspective( left, right, top, bottom, near, far ) instead."),this.makePerspective(i,e,n,t,r,s)};Me.prototype.getInverse=function(i){return console.warn("THREE.Matrix4: .getInverse() has been removed. Use matrixInv.copy( matrix ).invert(); instead."),this.copy(i).invert()};Xt.prototype.isIntersectionLine=function(i){return console.warn("THREE.Plane: .isIntersectionLine() has been renamed to .intersectsLine()."),this.intersectsLine(i)};S0.prototype.multiplyVector3=function(i){return console.warn("THREE.Quaternion: .multiplyVector3() has been removed. Use is now vector.applyQuaternion( quaternion ) instead."),i.applyQuaternion(this)};S0.prototype.inverse=function(){return console.warn("THREE.Quaternion: .inverse() has been renamed to invert()."),this.invert()};zi.prototype.isIntersectionBox=function(i){return console.warn("THREE.Ray: .isIntersectionBox() has been renamed to .intersectsBox()."),this.intersectsBox(i)};zi.prototype.isIntersectionPlane=function(i){return console.warn("THREE.Ray: .isIntersectionPlane() has been renamed to .intersectsPlane()."),this.intersectsPlane(i)};zi.prototype.isIntersectionSphere=function(i){return console.warn("THREE.Ray: .isIntersectionSphere() has been renamed to .intersectsSphere()."),this.intersectsSphere(i)};R0.prototype.area=function(){return console.warn("THREE.Triangle: .area() has been renamed to .getArea()."),this.getArea()};R0.prototype.barycoordFromPoint=function(i,e){return console.warn("THREE.Triangle: .barycoordFromPoint() has been renamed to .getBarycoord()."),this.getBarycoord(i,e)};R0.prototype.midpoint=function(i){return console.warn("THREE.Triangle: .midpoint() has been renamed to .getMidpoint()."),this.getMidpoint(i)};R0.prototypenormal=function(i){return console.warn("THREE.Triangle: .normal() has been renamed to .getNormal()."),this.getNormal(i)};R0.prototype.plane=function(i){return console.warn("THREE.Triangle: .plane() has been renamed to .getPlane()."),this.getPlane(i)};R0.barycoordFromPoint=function(i,e,t,n,r){return console.warn("THREE.Triangle: .barycoordFromPoint() has been renamed to .getBarycoord()."),R0.getBarycoord(i,e,t,n,r)};R0.normal=function(i,e,t,n){return console.warn("THREE.Triangle: .normal() has been renamed to .getNormal()."),R0.getNormal(i,e,t,n)};jn.prototype.extractAllPoints=function(i){return console.warn("THREE.Shape: .extractAllPoints() has been removed. Use .extractPoints() instead."),this.extractPoints(i)};jn.prototype.extrude=function(i){return console.warn("THREE.Shape: .extrude() has been removed. Use ExtrudeGeometry() instead."),new ns(this,i)};jn.prototype.makeGeometry=function(i){return console.warn("THREE.Shape: .makeGeometry() has been removed. Use ShapeGeometry() instead."),new c5(this,i)};ee.prototype.fromAttribute=function(i,e,t){return console.warn("THREE.Vector2: .fromAttribute() has been renamed to .fromBufferAttribute()."),this.fromBufferAttribute(i,e,t)};ee.prototype.distanceToManhattan=function(i){return console.warn("THREE.Vector2: .distanceToManhattan() has been renamed to .manhattanDistanceTo()."),this.manhattanDistanceTo(i)};ee.prototype.lengthManhattan=function(){return console.warn("THREE.Vector2: .lengthManhattan() has been renamed to .manhattanLength()."),this.manhattanLength()};P.prototype.setEulerFromRotationMatrix=function(){console.error("THREE.Vector3: .setEulerFromRotationMatrix() has been removed. Use Euler.setFromRotationMatrix() instead.")};P.prototype.setEulerFromQuaternion=function(){console.error("THREE.Vector3: .setEulerFromQuaternion() has been removed. Use Euler.setFromQuaternion() instead.")};P.prototype.getPositionFromMatrix=function(i){return console.warn("THREE.Vector3: .getPositionFromMatrix() has been renamed to .setFromMatrixPosition()."),this.setFromMatrixPosition(i)};P.prototype.getScaleFromMatrix=function(i){return console.warn("THREE.Vector3: .getScaleFromMatrix() has been renamed to .setFromMatrixScale()."),this.setFromMatrixScale(i)};P.prototype.getColumnFromMatrix=function(i,e){return console.warn("THREE.Vector3: .getColumnFromMatrix() has been renamed to .setFromMatrixColumn()."),this.setFromMatrixColumn(e,i)};P.prototype.applyProjection=function(i){return console.warn("THREE.Vector3: .applyProjection() has been removed. Use .applyMatrix4( m ) instead."),this.applyMatrix4(i)};P.prototype.fromAttribute=function(i,e,t){return console.warn("THREE.Vector3: .fromAttribute() has been renamed to .fromBufferAttribute()."),this.fromBufferAttribute(i,e,t)};P.prototype.distanceToManhattan=function(i){return console.warn("THREE.Vector3: .distanceToManhattan() has been renamed to .manhattanDistanceTo()."),this.manhattanDistanceTo(i)};P.prototype.lengthManhattan=function(){return console.warn("THREE.Vector3: .lengthManhattan() has been renamed to .manhattanLength()."),this.manhattanLength()};$e.prototype.fromAttribute=function(i,e,t){return console.warn("THREE.Vector4: .fromAttribute() has been renamed to .fromBufferAttribute()."),this.fromBufferAttribute(i,e,t)};$e.prototype.lengthManhattan=function(){return console.warn("THREE.Vector4: .lengthManhattan() has been renamed to .manhattanLength()."),this.manhattanLength()};t0.prototype.getChildByName=function(i){return console.warn("THREE.Object3D: .getChildByName() has been renamed to .getObjectByName()."),this.getObjectByName(i)};t0.prototype.renderDepth=function(){console.warn("THREE.Object3D: .renderDepth has been removed. Use .renderOrder, instead.")};t0.prototype.translate=function(i,e){return console.warn("THREE.Object3D: .translate() has been removed. Use .translateOnAxis( axis, distance ) instead."),this.translateOnAxis(e,i)};t0.prototype.getWorldRotation=function(){console.error("THREE.Object3D: .getWorldRotation() has been removed. Use THREE.Object3D.getWorldQuaternion( target ) instead.")};t0.prototype.applyMatrix=function(i){return console.warn("THREE.Object3D: .applyMatrix() has been renamed to .applyMatrix4()."),this.applyMatrix4(i)};Object.defineProperties(t0.prototype,{eulerOrder:{get:function(){return console.warn("THREE.Object3D: .eulerOrder is now .rotation.order."),this.rotation.order},set:function(i){console.warn("THREE.Object3D: .eulerOrder is now .rotation.order."),this.rotation.order=i}},useQuaternion:{get:function(){console.warn("THREE.Object3D: .useQuaternion has been removed. The library now uses quaternions by default.")},set:function(){console.warn("THREE.Object3D: .useQuaternion has been removed. The library now uses quaternions by default.")}}});I0.prototype.setDrawMode=function(){console.error("THREE.Mesh: .setDrawMode() has been removed. The renderer now always assumes THREE.TrianglesDrawMode. Transform your geometry via BufferGeometryUtils.toTrianglesDrawMode() if necessary.")};Object.defineProperties(I0.prototype,{drawMode:{get:function(){return console.error("THREE.Mesh: .drawMode has been removed. The renderer now always assumes THREE.TrianglesDrawMode."),dv},set:function(){console.error("THREE.Mesh: .drawMode has been removed. The renderer now always assumes THREE.TrianglesDrawMode. Transform your geometry via BufferGeometryUtils.toTrianglesDrawMode() if necessary.")}}});Tl.prototype.initBones=function(){console.error("THREE.SkinnedMesh: initBones() has been removed.")};X0.prototype.setLens=function(i,e){console.warn("THREE.PerspectiveCamera.setLens is deprecated. Use .setFocalLength and .filmGauge for a photographic setup."),e!==void 0&&(this.filmGauge=e),this.setFocalLength(i)};Object.defineProperties(Kt.prototype,{onlyShadow:{set:function(){console.warn("THREE.Light: .onlyShadow has been removed.")}},shadowCameraFov:{set:function(i){console.warn("THREE.Light: .shadowCameraFov is now .shadow.camera.fov."),this.shadow.camera.fov=i}},shadowCameraLeft:{set:function(i){console.warn("THREE.Light: .shadowCameraLeft is now .shadow.camera.left."),this.shadow.camera.left=i}},shadowCameraRight:{set:function(i){console.warn("THREE.Light: .shadowCameraRight is now .shadow.camera.right."),this.shadow.camera.right=i}},shadowCameraTop:{set:function(i){console.warn("THREE.Light: .shadowCameraTop is now .shadow.camera.top."),this.shadow.camera.top=i}},shadowCameraBottom:{set:function(i){console.warn("THREE.Light: .shadowCameraBottom is now .shadow.camera.bottom."),this.shadow.camera.bottom=i}},shadowCameraNear:{set:function(i){console.warn("THREE.Light: .shadowCameraNear is now .shadow.camera.near."),this.shadow.camera.near=i}},shadowCameraFar:{set:function(i){console.warn("THREE.Light: .shadowCameraFar is now .shadow.camera.far."),this.shadow.camera.far=i}},shadowCameraVisible:{set:function(){console.warn("THREE.Light: .shadowCameraVisible has been removed. Use new THREE.CameraHelper( light.shadow.camera ) instead.")}},shadowBias:{set:function(i){console.warn("THREE.Light: .shadowBias is now .shadow.bias."),this.shadow.bias=i}},shadowDarkness:{set:function(){console.warn("THREE.Light: .shadowDarkness has been removed.")}},shadowMapWidth:{set:function(i){console.warn("THREE.Light: .shadowMapWidth is now .shadow.mapSize.width."),this.shadow.mapSize.width=i}},shadowMapHeight:{set:function(i){console.warn("THREE.Light: .shadowMapHeight is now .shadow.mapSize.height."),this.shadow.mapSize.height=i}}});Object.defineProperties(_0.prototype,{length:{get:function(){return console.warn("THREE.BufferAttribute: .length has been deprecated. Use .count instead."),this.array.length}},dynamic:{get:function(){return console.warn("THREE.BufferAttribute: .dynamic has been deprecated. Use .usage instead."),this.usage===ja},set:function(){console.warn("THREE.BufferAttribute: .dynamic has been deprecated. Use .usage instead."),this.setUsage(ja)}}});_0.prototype.setDynamic=function(i){return console.warn("THREE.BufferAttribute: .setDynamic() has been deprecated. Use .setUsage() instead."),this.setUsage(i===!0?ja:co),this};_0.prototype.copyIndicesArray=function(){console.error("THREE.BufferAttribute: .copyIndicesArray() has been removed.")},_0.prototype.setArray=function(){console.error("THREE.BufferAttribute: .setArray has been removed. Use BufferGeometry .setAttribute to replace/resize attribute buffers")};Fe.prototype.addIndex=function(i){console.warn("THREE.BufferGeometry: .addIndex() has been renamed to .setIndex()."),this.setIndex(i)};Fe.prototype.addAttribute=function(i,e){return console.warn("THREE.BufferGeometry: .addAttribute() has been renamed to .setAttribute()."),!(e&&e.isBufferAttribute)&&!(e&&e.isInterleavedBufferAttribute)?(console.warn("THREE.BufferGeometry: .addAttribute() now expects ( name, attribute )."),this.setAttribute(i,new _0(arguments[1],arguments[2]))):i==="index"?(console.warn("THREE.BufferGeometry.addAttribute: Use .setIndex() for index attribute."),this.setIndex(e),this):this.setAttribute(i,e)};Fe.prototype.addDrawCall=function(i,e,t){t!==void 0&&console.warn("THREE.BufferGeometry: .addDrawCall() no longer supports indexOffset."),console.warn("THREE.BufferGeometry: .addDrawCall() is now .addGroup()."),this.addGroup(i,e)};Fe.prototype.clearDrawCalls=function(){console.warn("THREE.BufferGeometry: .clearDrawCalls() is now .clearGroups()."),this.clearGroups()};Fe.prototype.computeOffsets=function(){console.warn("THREE.BufferGeometry: .computeOffsets() has been removed.")};Fe.prototype.removeAttribute=function(i){return console.warn("THREE.BufferGeometry: .removeAttribute() has been renamed to .deleteAttribute()."),this.deleteAttribute(i)};Fe.prototype.applyMatrix=function(i){return console.warn("THREE.BufferGeometry: .applyMatrix() has been renamed to .applyMatrix4()."),this.applyMatrix4(i)};Object.defineProperties(Fe.prototype,{drawcalls:{get:function(){return console.error("THREE.BufferGeometry: .drawcalls has been renamed to .groups."),this.groups}},offsets:{get:function(){return console.warn("THREE.BufferGeometry: .offsets has been renamed to .groups."),this.groups}}});es.prototype.setDynamic=function(i){return console.warn("THREE.InterleavedBuffer: .setDynamic() has been deprecated. Use .setUsage() instead."),this.setUsage(i===!0?ja:co),this};es.prototype.setArray=function(){console.error("THREE.InterleavedBuffer: .setArray has been removed. Use BufferGeometry .setAttribute to replace/resize attribute buffers")};ns.prototype.getArrays=function(){console.error("THREE.ExtrudeGeometry: .getArrays() has been removed.")};ns.prototype.addShapeList=function(){console.error("THREE.ExtrudeGeometry: .addShapeList() has been removed.")};ns.prototype.addShape=function(){console.error("THREE.ExtrudeGeometry: .addShape() has been removed.")};o9.prototype.dispose=function(){console.error("THREE.Scene: .dispose() has been removed.")};Object.defineProperties(D0.prototype,{wrapAround:{get:function(){console.warn("THREE.Material: .wrapAround has been removed.")},set:function(){console.warn("THREE.Material: .wrapAround has been removed.")}},overdraw:{get:function(){console.warn("THREE.Material: .overdraw has been removed.")},set:function(){console.warn("THREE.Material: .overdraw has been removed.")}},wrapRGB:{get:function(){return console.warn("THREE.Material: .wrapRGB has been removed."),new be}},shading:{get:function(){console.error("THREE."+this.type+": .shading has been removed. Use the boolean .flatShading instead.")},set:function(i){console.warn("THREE."+this.type+": .shading has been removed. Use the boolean .flatShading instead."),this.flatShading=i===o4}},stencilMask:{get:function(){return console.warn("THREE."+this.type+": .stencilMask has been removed. Use .stencilFuncMask instead."),this.stencilFuncMask},set:function(i){console.warn("THREE."+this.type+": .stencilMask has been removed. Use .stencilFuncMask instead."),this.stencilFuncMask=i}},vertexTangents:{get:function(){console.warn("THREE."+this.type+": .vertexTangents has been removed.")},set:function(){console.warn("THREE."+this.type+": .vertexTangents has been removed.")}}});Object.defineProperties(u0.prototype,{derivatives:{get:function(){return console.warn("THREE.ShaderMaterial: .derivatives has been moved to .extensions.derivatives."),this.extensions.derivatives},set:function(i){console.warn("THREE. ShaderMaterial: .derivatives has been moved to .extensions.derivatives."),this.extensions.derivatives=i}}});o0.prototype.clearTarget=function(i,e,t,n){console.warn("THREE.WebGLRenderer: .clearTarget() has been deprecated. Use .setRenderTarget() and .clear() instead."),this.setRenderTarget(i),this.clear(e,t,n)};o0.prototype.animate=function(i){console.warn("THREE.WebGLRenderer: .animate() is now .setAnimationLoop()."),this.setAnimationLoop(i)};o0.prototype.getCurrentRenderTarget=function(){return console.warn("THREE.WebGLRenderer: .getCurrentRenderTarget() is now .getRenderTarget()."),this.getRenderTarget()};o0.prototype.getMaxAnisotropy=function(){return console.warn("THREE.WebGLRenderer: .getMaxAnisotropy() is now .capabilities.getMaxAnisotropy()."),this.capabilities.getMaxAnisotropy()};o0.prototype.getPrecision=function(){return console.warn("THREE.WebGLRenderer: .getPrecision() is now .capabilities.precision."),this.capabilities.precision};o0.prototype.resetGLState=function(){return console.warn("THREE.WebGLRenderer: .resetGLState() is now .state.reset()."),this.state.reset()};o0.prototype.supportsFloatTextures=function(){return console.warn("THREE.WebGLRenderer: .supportsFloatTextures() is now .extensions.get( 'OES_texture_float' )."),this.extensions.get("OES_texture_float")};o0.prototype.supportsHalfFloatTextures=function(){return console.warn("THREE.WebGLRenderer: .supportsHalfFloatTextures() is now .extensions.get( 'OES_texture_half_float' )."),this.extensions.get("OES_texture_half_float")};o0.prototype.supportsStandardDerivatives=function(){return console.warn("THREE.WebGLRenderer: .supportsStandardDerivatives() is now .extensions.get( 'OES_standard_derivatives' )."),this.extensions.get("OES_standard_derivatives")};o0.prototype.supportsCompressedTextureS3TC=function(){return console.warn("THREE.WebGLRenderer: .supportsCompressedTextureS3TC() is now .extensions.get( 'WEBGL_compressed_texture_s3tc' )."),this.extensions.get("WEBGL_compressed_texture_s3tc")};o0.prototype.supportsCompressedTexturePVRTC=function(){return console.warn("THREE.WebGLRenderer: .supportsCompressedTexturePVRTC() is now .extensions.get( 'WEBGL_compressed_texture_pvrtc' )."),this.extensions.get("WEBGL_compressed_texture_pvrtc")};o0.prototype.supportsBlendMinMax=function(){return console.warn("THREE.WebGLRenderer: .supportsBlendMinMax() is now .extensions.get( 'EXT_blend_minmax' )."),this.extensions.get("EXT_blend_minmax")};o0.prototype.supportsVertexTextures=function(){return console.warn("THREE.WebGLRenderer: .supportsVertexTextures() is now .capabilities.vertexTextures."),this.capabilities.vertexTextures};o0.prototype.supportsInstancedArrays=function(){return console.warn("THREE.WebGLRenderer: .supportsInstancedArrays() is now .extensions.get( 'ANGLE_instanced_arrays' )."),this.extensions.get("ANGLE_instanced_arrays")};o0.prototype.enableScissorTest=function(i){console.warn("THREE.WebGLRenderer: .enableScissorTest() is now .setScissorTest()."),this.setScissorTest(i)};o0.prototype.initMaterial=function(){console.warn("THREE.WebGLRenderer: .initMaterial() has been removed.")};o0.prototype.addPrePlugin=function(){console.warn("THREE.WebGLRenderer: .addPrePlugin() has been removed.")};o0.prototype.addPostPlugin=function(){console.warn("THREE.WebGLRenderer: .addPostPlugin() has been removed.")};o0.prototype.updateShadowMap=function(){console.warn("THREE.WebGLRenderer: .updateShadowMap() has been removed.")};o0.prototype.setFaceCulling=function(){console.warn("THREE.WebGLRenderer: .setFaceCulling() has been removed.")};o0.prototype.allocTextureUnit=function(){console.warn("THREE.WebGLRenderer: .allocTextureUnit() has been removed.")};o0.prototype.setTexture=function(){console.warn("THREE.WebGLRenderer: .setTexture() has been removed.")};o0.prototype.setTexture2D=function(){console.warn("THREE.WebGLRenderer: .setTexture2D() has been removed.")};o0.prototype.setTextureCube=function(){console.warn("THREE.WebGLRenderer: .setTextureCube() has been removed.")};o0.prototype.getActiveMipMapLevel=function(){return console.warn("THREE.WebGLRenderer: .getActiveMipMapLevel() is now .getActiveMipmapLevel()."),this.getActiveMipmapLevel()};Object.defineProperties(o0.prototype,{shadowMapEnabled:{get:function(){return this.shadowMap.enabled},set:function(i){console.warn("THREE.WebGLRenderer: .shadowMapEnabled is now .shadowMap.enabled."),this.shadowMap.enabled=i}},shadowMapType:{get:function(){return this.shadowMap.type},set:function(i){console.warn("THREE.WebGLRenderer: .shadowMapType is now .shadowMap.type."),this.shadowMap.type=i}},shadowMapCullFace:{get:function(){console.warn("THREE.WebGLRenderer: .shadowMapCullFace has been removed. Set Material.shadowSide instead.")},set:function(){console.warn("THREE.WebGLRenderer: .shadowMapCullFace has been removed. Set Material.shadowSide instead.")}},context:{get:function(){return console.warn("THREE.WebGLRenderer: .context has been removed. Use .getContext() instead."),this.getContext()}},vr:{get:function(){return console.warn("THREE.WebGLRenderer: .vr has been renamed to .xr"),this.xr}},gammaInput:{get:function(){return console.warn("THREE.WebGLRenderer: .gammaInput has been removed. Set the encoding for textures via Texture.encoding instead."),!1},set:function(){console.warn("THREE.WebGLRenderer: .gammaInput has been removed. Set the encoding for textures via Texture.encoding instead.")}},gammaOutput:{get:function(){return console.warn("THREE.WebGLRenderer: .gammaOutput has been removed. Set WebGLRenderer.outputEncoding instead."),!1},set:function(i){console.warn("THREE.WebGLRenderer: .gammaOutput has been removed. Set WebGLRenderer.outputEncoding instead."),this.outputEncoding=i===!0?at:J0}},toneMappingWhitePoint:{get:function(){return console.warn("THREE.WebGLRenderer: .toneMappingWhitePoint has been removed."),1},set:function(){console.warn("THREE.WebGLRenderer: .toneMappingWhitePoint has been removed.")}}});Object.defineProperties(k4.prototype,{cullFace:{get:function(){console.warn("THREE.WebGLRenderer: .shadowMap.cullFace has been removed. Set Material.shadowSide instead.")},set:function(){console.warn("THREE.WebGLRenderer: .shadowMap.cullFace has been removed. Set Material.shadowSide instead.")}},renderReverseSided:{get:function(){console.warn("THREE.WebGLRenderer: .shadowMap.renderReverseSided has been removed. Set Material.shadowSide instead.")},set:function(){console.warn("THREE.WebGLRenderer: .shadowMap.renderReverseSided has been removed. Set Material.shadowSide instead.")}},renderSingleSided:{get:function(){console.warn("THREE.WebGLRenderer: .shadowMap.renderSingleSided has been removed. Set Material.shadowSide instead.")},set:function(){console.warn("THREE.WebGLRenderer: .shadowMap.renderSingleSided has been removed. Set Material.shadowSide instead.")}}});Object.defineProperties(C0.prototype,{wrapS:{get:function(){return console.warn("THREE.WebGLRenderTarget: .wrapS is now .texture.wrapS."),this.texture.wrapS},set:function(i){console.warn("THREE.WebGLRenderTarget: .wrapS is now .texture.wrapS."),this.texture.wrapS=i}},wrapT:{get:function(){return console.warn("THREE.WebGLRenderTarget: .wrapT is now .texture.wrapT."),this.texture.wrapT},set:function(i){console.warn("THREE.WebGLRenderTarget: .wrapT is now .texture.wrapT."),this.texture.wrapT=i}},magFilter:{get:function(){return console.warn("THREE.WebGLRenderTarget: .magFilter is now .texture.magFilter."),this.texture.magFilter},set:function(i){console.warn("THREE.WebGLRenderTarget: .magFilter is now .texture.magFilter."),this.texture.magFilter=i}},minFilter:{get:function(){return console.warn("THREE.WebGLRenderTarget: .minFilter is now .texture.minFilter."),this.texture.minFilter},set:function(i){console.warn("THREE.WebGLRenderTarget: .minFilter is now .texture.minFilter."),this.texture.minFilter=i}},anisotropy:{get:function(){return console.warn("THREE.WebGLRenderTarget: .anisotropy is now .texture.anisotropy."),this.texture.anisotropy},set:function(i){console.warn("THREE.WebGLRenderTarget: .anisotropy is now .texture.anisotropy."),this.texture.anisotropy=i}},offset:{get:function(){return console.warn("THREE.WebGLRenderTarget: .offset is now .texture.offset."),this.texture.offset},set:function(i){console.warn("THREE.WebGLRenderTarget: .offset is now .texture.offset."),this.texture.offset=i}},repeat:{get:function(){return console.warn("THREE.WebGLRenderTarget: .repeat is now .texture.repeat."),this.texture.repeat},set:function(i){console.warn("THREE.WebGLRenderTarget: .repeat is now .texture.repeat."),this.texture.repeat=i}},format:{get:function(){return console.warn("THREE.WebGLRenderTarget: .format is now .texture.format."),this.texture.format},set:function(i){console.warn("THREE.WebGLRenderTarget: .format is now .texture.format."),this.texture.format=i}},type:{get:function(){return console.warn("THREE.WebGLRenderTarget: .type is now .texture.type."),this.texture.type},set:function(i){console.warn("THREE.WebGLRenderTarget: .type is now .texture.type."),this.texture.type=i}},generateMipmaps:{get:function(){return console.warn("THREE.WebGLRenderTarget: .generateMipmaps is now .texture.generateMipmaps."),this.texture.generateMipmaps},set:function(i){console.warn("THREE.WebGLRenderTarget: .generateMipmaps is now .texture.generateMipmaps."),this.texture.generateMipmaps=i}}});xM.prototype.load=function(i){console.warn("THREE.Audio: .load has been deprecated. Use THREE.AudioLoader instead.");const e=this;return new pM().load(i,function(n){e.setBuffer(n)}),this};bl.prototype.updateCubeMap=function(i,e){return console.warn("THREE.CubeCamera: .updateCubeMap() is now .update()."),this.update(i,e)};bl.prototype.clear=function(i,e,t,n){return console.warn("THREE.CubeCamera: .clear() is now .renderTarget.clear()."),this.renderTarget.clear(i,e,t,n)};Jr.crossOrigin=void 0;Jr.loadTexture=function(i,e,t,n){console.warn("THREE.ImageUtils.loadTexture has been deprecated. Use THREE.TextureLoader() instead.");const r=new Bi;r.setCrossOrigin(this.crossOrigin);const s=r.load(i,t,void 0,n);return e&&(s.mapping=e),s};Jr.loadTextureCube=function(i,e,t,n){console.warn("THREE.ImageUtils.loadTextureCube has been deprecated. Use THREE.CubeTextureLoader() instead.");const r=new M5;r.setCrossOrigin(this.crossOrigin);const s=r.load(i,t,void 0,n);return e&&(s.mapping=e),s};Jr.loadCompressedTexture=function(){console.error("THREE.ImageUtils.loadCompressedTexture has been removed. Use THREE.DDSLoader instead.")};Jr.loadCompressedTextureCube=function(){console.error("THREE.ImageUtils.loadCompressedTextureCube has been removed. Use THREE.DDSLoader instead.")};typeof __THREE_DEVTOOLS__<"u"&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("register",{detail:{revision:r4}}));typeof window<"u"&&(window.__THREE__?console.warn("WARNING: Multiple instances of Three.js being imported."):window.__THREE__=r4);const _3={type:"change"},A1={type:"start"},E1={type:"end"};class UM extends ni{constructor(e,t){super(),t===void 0&&console.warn('THREE.OrbitControls: The second parameter "domElement" is now mandatory.'),t===document&&console.error('THREE.OrbitControls: "document" should not be used as the target "domElement". Please use "renderer.domElement" instead.'),this.object=e,this.domElement=t,this.domElement.style.touchAction="none",this.enabled=!0,this.target=new P,this.minDistance=0,this.maxDistance=1/0,this.minZoom=0,this.maxZoom=1/0,this.minPolarAngle=0,this.maxPolarAngle=Math.PI,this.minAzimuthAngle=-1/0,this.maxAzimuthAngle=1/0,this.enableDamping=!1,this.dampingFactor=.05,this.enableZoom=!0,this.zoomSpeed=1,this.enableRotate=!0,this.rotateSpeed=1,this.enablePan=!0,this.panSpeed=1,this.screenSpacePanning=!0,this.keyPanSpeed=7,this.autoRotate=!1,this.autoRotateSpeed=2,this.keys={LEFT:"ArrowLeft",UP:"ArrowUp",RIGHT:"ArrowRight",BOTTOM:"ArrowDown"},this.mouseButtons={LEFT:Vi.ROTATE,MIDDLE:Vi.DOLLY,RIGHT:Vi.PAN},this.touches={ONE:Wi.ROTATE,TWO:Wi.DOLLY_PAN},this.target0=this.target.clone(),this.position0=this.object.position.clone(),this.zoom0=this.object.zoom,this._domElementKeyEvents=null,this.getPolarAngle=function(){return a.phi},this.getAzimuthalAngle=function(){return a.theta},this.getDistance=function(){return this.object.position.distanceTo(this.target)},this.listenToKeyEvents=function(D){D.addEventListener("keydown",oe),this._domElementKeyEvents=D},this.saveState=function(){n.target0.copy(n.target),n.position0.copy(n.object.position),n.zoom0=n.object.zoom},this.reset=function(){n.target.copy(n.target0),n.object.position.copy(n.position0),n.object.zoom=n.zoom0,n.object.updateProjectionMatrix(),n.dispatchEvent(_3),n.update(),s=r.NONE},this.update=function(){const D=new P,_e=new S0().setFromUnitVectors(e.up,new P(0,1,0)),Ie=_e.clone().invert(),Ue=new P,ke=new S0,Oe=2*Math.PI;return function(){const E0=n.object.position;D.copy(E0).sub(n.target),D.applyQuaternion(_e),a.setFromVector3(D),n.autoRotate&&s===r.NONE&&B(b()),n.enableDamping?(a.theta+=l.theta*n.dampingFactor,a.phi+=l.phi*n.dampingFactor):(a.theta+=l.theta,a.phi+=l.phi);let H0=n.minAzimuthAngle,N0=n.maxAzimuthAngle;return isFinite(H0)&&isFinite(N0)&&(H0<-Math.PI?H0+=Oe:H0>Math.PI&&(H0-=Oe),N0<-Math.PI?N0+=Oe:N0>Math.PI&&(N0-=Oe),H0<=N0?a.theta=Math.max(H0,Math.min(N0,a.theta)):a.theta=a.theta>(H0+N0)/2?Math.max(H0,a.theta):Math.min(N0,a.theta)),a.phi=Math.max(n.minPolarAngle,Math.min(n.maxPolarAngle,a.phi)),a.makeSafe(),a.radius*=c,a.radius=Math.max(n.minDistance,Math.min(n.maxDistance,a.radius)),n.enableDamping===!0?n.target.addScaledVector(u,n.dampingFactor):n.target.add(u),D.setFromSpherical(a),D.applyQuaternion(Ie),E0.copy(n.target).add(D),n.object.lookAt(n.target),n.enableDamping===!0?(l.theta*=1-n.dampingFactor,l.phi*=1-n.dampingFactor,u.multiplyScalar(1-n.dampingFactor)):(l.set(0,0,0),u.set(0,0,0)),c=1,h||Ue.distanceToSquared(n.object.position)>o||8*(1-ke.dot(n.object.quaternion))>o?(n.dispatchEvent(_3),Ue.copy(n.object.position),ke.copy(n.object.quaternion),h=!1,!0):!1}}(),this.dispose=function(){n.domElement.removeEventListener("contextmenu",ge),n.domElement.removeEventListener("pointerdown",F),n.domElement.removeEventListener("pointercancel",T),n.domElement.removeEventListener("wheel",H),n.domElement.removeEventListener("pointermove",W),n.domElement.removeEventListener("pointerup",X),n._domElementKeyEvents!==null&&n._domElementKeyEvents.removeEventListener("keydown",oe)};const n=this,r={NONE:-1,ROTATE:0,DOLLY:1,PAN:2,TOUCH_ROTATE:3,TOUCH_PAN:4,TOUCH_DOLLY_PAN:5,TOUCH_DOLLY_ROTATE:6};let s=r.NONE;const o=1e-6,a=new x3,l=new x3;let c=1;const u=new P;let h=!1;const f=new ee,d=new ee,g=new ee,v=new ee,_=new ee,m=new ee,p=new ee,y=new ee,x=new ee,w=[],A={};function b(){return 2*Math.PI/60/60*n.autoRotateSpeed}function L(){return Math.pow(.95,n.zoomSpeed)}function B(D){l.theta-=D}function I(D){l.phi-=D}const C=function(){const D=new P;return function(Ie,Ue){D.setFromMatrixColumn(Ue,0),D.multiplyScalar(-Ie),u.add(D)}}(),Y=function(){const D=new P;return function(Ie,Ue){n.screenSpacePanning===!0?D.setFromMatrixColumn(Ue,1):(D.setFromMatrixColumn(Ue,0),D.crossVectors(n.object.up,D)),D.multiplyScalar(Ie),u.add(D)}}(),O=function(){const D=new P;return function(Ie,Ue){const ke=n.domElement;if(n.object.isPerspectiveCamera){const Oe=n.object.position;D.copy(Oe).sub(n.target);let g0=D.length();g0*=Math.tan(n.object.fov/2*Math.PI/180),C(2*Ie*g0/ke.clientHeight,n.object.matrix),Y(2*Ue*g0/ke.clientHeight,n.object.matrix)}else n.object.isOrthographicCamera?(C(Ie*(n.object.right-n.object.left)/n.object.zoom/ke.clientWidth,n.object.matrix),Y(Ue*(n.object.top-n.object.bottom)/n.object.zoom/ke.clientHeight,n.object.matrix)):(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - pan disabled."),n.enablePan=!1)}}();function G(D){n.object.isPerspectiveCamera?c/=D:n.object.isOrthographicCamera?(n.object.zoom=Math.max(n.minZoom,Math.min(n.maxZoom,n.object.zoom*D)),n.object.updateProjectionMatrix(),h=!0):(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."),n.enableZoom=!1)}function j(D){n.object.isPerspectiveCamera?c*=D:n.object.isOrthographicCamera?(n.object.zoom=Math.max(n.minZoom,Math.min(n.maxZoom,n.object.zoom/D)),n.object.updateProjectionMatrix(),h=!0):(console.warn("WARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled."),n.enableZoom=!1)}function N(D){f.set(D.clientX,D.clientY)}function k(D){p.set(D.clientX,D.clientY)}function K(D){v.set(D.clientX,D.clientY)}function le(D){d.set(D.clientX,D.clientY),g.subVectors(d,f).multiplyScalar(n.rotateSpeed);const _e=n.domElement;B(2*Math.PI*g.x/_e.clientHeight),I(2*Math.PI*g.y/_e.clientHeight),f.copy(d),n.update()}function ve(D){y.set(D.clientX,D.clientY),x.subVectors(y,p),x.y>0?G(L()):x.y<0&&j(L()),p.copy(y),n.update()}function ce(D){_.set(D.clientX,D.clientY),m.subVectors(_,v).multiplyScalar(n.panSpeed),O(m.x,m.y),v.copy(_),n.update()}function ye(D){D.deltaY<0?j(L()):D.deltaY>0&&G(L()),n.update()}function $(D){let _e=!1;switch(D.code){case n.keys.UP:O(0,n.keyPanSpeed),_e=!0;break;case n.keys.BOTTOM:O(0,-n.keyPanSpeed),_e=!0;break;case n.keys.LEFT:O(n.keyPanSpeed,0),_e=!0;break;case n.keys.RIGHT:O(-n.keyPanSpeed,0),_e=!0;break}_e&&(D.preventDefault(),n.update())}function se(){if(w.length===1)f.set(w[0].pageX,w[0].pageY);else{const D=.5*(w[0].pageX+w[1].pageX),_e=.5*(w[0].pageY+w[1].pageY);f.set(D,_e)}}function me(){if(w.length===1)v.set(w[0].pageX,w[0].pageY);else{const D=.5*(w[0].pageX+w[1].pageX),_e=.5*(w[0].pageY+w[1].pageY);v.set(D,_e)}}function Z(){const D=w[0].pageX-w[1].pageX,_e=w[0].pageY-w[1].pageY,Ie=Math.sqrt(D*D+_e*_e);p.set(0,Ie)}function V(){n.enableZoom&&Z(),n.enablePan&&me()}function te(){n.enableZoom&&Z(),n.enableRotate&&se()}function Q(D){if(w.length==1)d.set(D.pageX,D.pageY);else{const Ie=Te(D),Ue=.5*(D.pageX+Ie.x),ke=.5*(D.pageY+Ie.y);d.set(Ue,ke)}g.subVectors(d,f).multiplyScalar(n.rotateSpeed);const _e=n.domElement;B(2*Math.PI*g.x/_e.clientHeight),I(2*Math.PI*g.y/_e.clientHeight),f.copy(d)}function re(D){if(w.length===1)_.set(D.pageX,D.pageY);else{const _e=Te(D),Ie=.5*(D.pageX+_e.x),Ue=.5*(D.pageY+_e.y);_.set(Ie,Ue)}m.subVectors(_,v).multiplyScalar(n.panSpeed),O(m.x,m.y),v.copy(_)}function we(D){const _e=Te(D),Ie=D.pageX-_e.x,Ue=D.pageY-_e.y,ke=Math.sqrt(Ie*Ie+Ue*Ue);y.set(0,ke),x.set(0,Math.pow(y.y/p.y,n.zoomSpeed)),G(x.y),p.copy(y)}function M(D){n.enableZoom&&we(D),n.enablePan&&re(D)}function E(D){n.enableZoom&&we(D),n.enableRotate&&Q(D)}function F(D){n.enabled!==!1&&(w.length===0&&(n.domElement.setPointerCapture(D.pointerId),n.domElement.addEventListener("pointermove",W),n.domElement.addEventListener("pointerup",X)),z(D),D.pointerType==="touch"?ue(D):S(D))}function W(D){n.enabled!==!1&&(D.pointerType==="touch"?he(D):U(D))}function X(D){n.enabled!==!1&&(D.pointerType==="touch"?xe():q(),fe(D),w.length===0&&(n.domElement.releasePointerCapture(D.pointerId),n.domElement.removeEventListener("pointermove",W),n.domElement.removeEventListener("pointerup",X)))}function T(D){fe(D)}function S(D){let _e;switch(D.button){case 0:_e=n.mouseButtons.LEFT;break;case 1:_e=n.mouseButtons.MIDDLE;break;case 2:_e=n.mouseButtons.RIGHT;break;default:_e=-1}switch(_e){case Vi.DOLLY:if(n.enableZoom===!1)return;k(D),s=r.DOLLY;break;case Vi.ROTATE:if(D.ctrlKey||D.metaKey||D.shiftKey){if(n.enablePan===!1)return;K(D),s=r.PAN}else{if(n.enableRotate===!1)return;N(D),s=r.ROTATE}break;case Vi.PAN:if(D.ctrlKey||D.metaKey||D.shiftKey){if(n.enableRotate===!1)return;N(D),s=r.ROTATE}else{if(n.enablePan===!1)return;K(D),s=r.PAN}break;default:s=r.NONE}s!==r.NONE&&n.dispatchEvent(A1)}function U(D){if(n.enabled!==!1)switch(s){case r.ROTATE:if(n.enableRotate===!1)return;le(D);break;case r.DOLLY:if(n.enableZoom===!1)return;ve(D);break;case r.PAN:if(n.enablePan===!1)return;ce(D);break}}function q(D){n.dispatchEvent(E1),s=r.NONE}function H(D){n.enabled===!1||n.enableZoom===!1||s!==r.NONE||(D.preventDefault(),n.dispatchEvent(A1),ye(D),n.dispatchEvent(E1))}function oe(D){n.enabled===!1||n.enablePan===!1||$(D)}function ue(D){switch(ne(D),w.length){case 1:switch(n.touches.ONE){case Wi.ROTATE:if(n.enableRotate===!1)return;se(),s=r.TOUCH_ROTATE;break;case Wi.PAN:if(n.enablePan===!1)return;me(),s=r.TOUCH_PAN;break;default:s=r.NONE}break;case 2:switch(n.touches.TWO){case Wi.DOLLY_PAN:if(n.enableZoom===!1&&n.enablePan===!1)return;V(),s=r.TOUCH_DOLLY_PAN;break;case Wi.DOLLY_ROTATE:if(n.enableZoom===!1&&n.enableRotate===!1)return;te(),s=r.TOUCH_DOLLY_ROTATE;break;default:s=r.NONE}break;default:s=r.NONE}s!==r.NONE&&n.dispatchEvent(A1)}function he(D){switch(ne(D),s){case r.TOUCH_ROTATE:if(n.enableRotate===!1)return;Q(D),n.update();break;case r.TOUCH_PAN:if(n.enablePan===!1)return;re(D),n.update();break;case r.TOUCH_DOLLY_PAN:if(n.enableZoom===!1&&n.enablePan===!1)return;M(D),n.update();break;case r.TOUCH_DOLLY_ROTATE:if(n.enableZoom===!1&&n.enableRotate===!1)return;E(D),n.update();break;default:s=r.NONE}}function xe(D){n.dispatchEvent(E1),s=r.NONE}function ge(D){n.enabled!==!1&&D.preventDefault()}function z(D){w.push(D)}function fe(D){delete A[D.pointerId];for(let _e=0;_e1&&e.multiplyScalar(1/t),this.children[0].material.color.copy(this.material.color)}this.matrixWorld.extractRotation(this.light.matrixWorld).scale(this.scale).copyPosition(this.light.matrixWorld),this.children[0].matrixWorld.copy(this.matrixWorld)}dispose(){this.geometry.dispose(),this.material.dispose(),this.children[0].geometry.dispose(),this.children[0].material.dispose()}}class kM extends ns{constructor(e,t={}){const n=t.font;if(!(n&&n.isFont))return console.error("THREE.TextGeometry: font parameter is not an instance of THREE.Font."),new Fe;const r=n.generateShapes(e,t.size);t.depth=t.height!==void 0?t.height:50,t.bevelThickness===void 0&&(t.bevelThickness=10),t.bevelSize===void 0&&(t.bevelSize=8),t.bevelEnabled===void 0&&(t.bevelEnabled=!1),super(r,t),this.type="TextGeometry"}}class GM extends Bt{constructor(e){super(e)}load(e,t,n,r){const s=this,o=new Po(this.manager);o.setPath(this.path),o.setRequestHeader(this.requestHeader),o.setWithCredentials(s.withCredentials),o.load(e,function(a){let l;try{l=JSON.parse(a)}catch{console.warn("THREE.FontLoader: typeface.js support is being deprecated. Use typeface.json instead."),l=JSON.parse(a.substring(65,a.length-2))}const c=s.parse(l);t&&t(c)},n,r)}parse(e){return new I5(e)}}class I5{constructor(e){this.type="Font",this.data=e}generateShapes(e,t=100){const n=[],r=HM(e,t,this.data);for(let s=0,o=r.length;s=2.0 are supported."));return}const c=new mS(l,{path:t||this.resourcePath||"",crossOrigin:this.crossOrigin,requestHeader:this.requestHeader,manager:this.manager,ktx2Loader:this.ktx2Loader,meshoptDecoder:this.meshoptDecoder});c.fileLoader.setRequestHeader(this.requestHeader);for(let u=0;u=0&&a[h]===void 0&&console.warn('THREE.GLTFLoader: Unknown extension "'+h+'".')}}c.setExtensions(o),c.setPlugins(a),c.parse(n,r)}}function XM(){let i={};return{get:function(e){return i[e]},add:function(e,t){i[e]=t},remove:function(e){delete i[e]},removeAll:function(){i={}}}}const We={KHR_BINARY_GLTF:"KHR_binary_glTF",KHR_DRACO_MESH_COMPRESSION:"KHR_draco_mesh_compression",KHR_LIGHTS_PUNCTUAL:"KHR_lights_punctual",KHR_MATERIALS_CLEARCOAT:"KHR_materials_clearcoat",KHR_MATERIALS_IOR:"KHR_materials_ior",KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS:"KHR_materials_pbrSpecularGlossiness",KHR_MATERIALS_SHEEN:"KHR_materials_sheen",KHR_MATERIALS_SPECULAR:"KHR_materials_specular",KHR_MATERIALS_TRANSMISSION:"KHR_materials_transmission",KHR_MATERIALS_UNLIT:"KHR_materials_unlit",KHR_MATERIALS_VOLUME:"KHR_materials_volume",KHR_TEXTURE_BASISU:"KHR_texture_basisu",KHR_TEXTURE_TRANSFORM:"KHR_texture_transform",KHR_MESH_QUANTIZATION:"KHR_mesh_quantization",EXT_TEXTURE_WEBP:"EXT_texture_webp",EXT_MESHOPT_COMPRESSION:"EXT_meshopt_compression"};class jM{constructor(e){this.parser=e,this.name=We.KHR_LIGHTS_PUNCTUAL,this.cache={refs:{},uses:{}}}_markDefs(){const e=this.parser,t=this.parser.json.nodes||[];for(let n=0,r=t.length;n=0)throw new Error("THREE.GLTFLoader: setKTX2Loader must be called before loading KTX2 textures");return null}return t.loadTextureImage(e,o,a)}}class tS{constructor(e){this.parser=e,this.name=We.EXT_TEXTURE_WEBP,this.isSupported=null}loadTexture(e){const t=this.name,n=this.parser,r=n.json,s=r.textures[e];if(!s.extensions||!s.extensions[t])return null;const o=s.extensions[t],a=r.images[o.source];let l=n.textureLoader;if(a.uri){const c=n.options.manager.getHandler(a.uri);c!==null&&(l=c)}return this.detectSupport().then(function(c){if(c)return n.loadTextureImage(e,a,l);if(r.extensionsRequired&&r.extensionsRequired.indexOf(t)>=0)throw new Error("THREE.GLTFLoader: WebP required by asset but unsupported.");return n.loadTexture(e)})}detectSupport(){return this.isSupported||(this.isSupported=new Promise(function(e){const t=new Image;t.src="data:image/webp;base64,UklGRiIAAABXRUJQVlA4IBYAAAAwAQCdASoBAAEADsD+JaQAA3AAAAAA",t.onload=t.onerror=function(){e(t.height===1)}})),this.isSupported}}class nS{constructor(e){this.name=We.EXT_MESHOPT_COMPRESSION,this.parser=e}loadBufferView(e){const t=this.parser.json,n=t.bufferViews[e];if(n.extensions&&n.extensions[this.name]){const r=n.extensions[this.name],s=this.parser.getDependency("buffer",r.buffer),o=this.parser.options.meshoptDecoder;if(!o||!o.supported){if(t.extensionsRequired&&t.extensionsRequired.indexOf(this.name)>=0)throw new Error("THREE.GLTFLoader: setMeshoptDecoder must be called before loading compressed files");return null}return Promise.all([s,o.ready]).then(function(a){const l=r.byteOffset||0,c=r.byteLength||0,u=r.count,h=r.byteStride,f=new ArrayBuffer(u*h),d=new Uint8Array(a[0],l,c);return o.decodeGltfBuffer(new Uint8Array(f),u,h,d,r.mode,r.filter),f})}else return null}}const D5="glTF",Cs=12,b3={JSON:1313821514,BIN:5130562};class iS{constructor(e){this.name=We.KHR_BINARY_GLTF,this.content=null,this.body=null;const t=new DataView(e,0,Cs);if(this.header={magic:Ut.decodeText(new Uint8Array(e.slice(0,4))),version:t.getUint32(4,!0),length:t.getUint32(8,!0)},this.header.magic!==D5)throw new Error("THREE.GLTFLoader: Unsupported glTF-Binary header.");if(this.header.version<2)throw new Error("THREE.GLTFLoader: Legacy binary file detected.");const n=this.header.length-Cs,r=new DataView(e,Cs);let s=0;for(;s",t).replace("#include ",n).replace("#include ",r).replace("#include ",s).replace("#include ",o)},Object.defineProperties(this,{specular:{get:function(){return a.specular.value},set:function(l){a.specular.value=l}},specularMap:{get:function(){return a.specularMap.value},set:function(l){a.specularMap.value=l,l?this.defines.USE_SPECULARMAP="":delete this.defines.USE_SPECULARMAP}},glossiness:{get:function(){return a.glossiness.value},set:function(l){a.glossiness.value=l}},glossinessMap:{get:function(){return a.glossinessMap.value},set:function(l){a.glossinessMap.value=l,l?(this.defines.USE_GLOSSINESSMAP="",this.defines.USE_UV=""):(delete this.defines.USE_GLOSSINESSMAP,delete this.defines.USE_UV)}}}),delete this.metalness,delete this.roughness,delete this.metalnessMap,delete this.roughnessMap,this.setValues(e)}copy(e){return super.copy(e),this.specularMap=e.specularMap,this.specular.copy(e.specular),this.glossinessMap=e.glossinessMap,this.glossiness=e.glossiness,delete this.metalness,delete this.roughness,delete this.metalnessMap,delete this.roughnessMap,this}}class oS{constructor(){this.name=Ve.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS,this.specularGlossinessParams=["color","map","lightMap","lightMapIntensity","aoMap","aoMapIntensity","emissive","emissiveIntensity","emissiveMap","bumpMap","bumpScale","normalMap","normalMapType","displacementMap","displacementScale","displacementBias","specularMap","specular","glossinessMap","glossiness","alphaMap","envMap","envMapIntensity","refractionRatio"]}getMaterialType(){return lc}extendParams(e,t,n){const r=t.extensions[this.name];e.color=new be(1,1,1),e.opacity=1;const s=[];if(Array.isArray(r.diffuseFactor)){const o=r.diffuseFactor;e.color.fromArray(o),e.opacity=o[3]}if(r.diffuseTexture!==void 0&&s.push(n.assignTexture(e,"map",r.diffuseTexture)),e.emissive=new be(0,0,0),e.glossiness=r.glossinessFactor!==void 0?r.glossinessFactor:1,e.specular=new be(1,1,1),Array.isArray(r.specularFactor)&&e.specular.fromArray(r.specularFactor),r.specularGlossinessTexture!==void 0){const o=r.specularGlossinessTexture;s.push(n.assignTexture(e,"glossinessMap",o)),s.push(n.assignTexture(e,"specularMap",o))}return Promise.all(s)}createMaterial(e){const t=new lc(e);return t.fog=!0,t.color=e.color,t.map=e.map===void 0?null:e.map,t.lightMap=null,t.lightMapIntensity=1,t.aoMap=e.aoMap===void 0?null:e.aoMap,t.aoMapIntensity=1,t.emissive=e.emissive,t.emissiveIntensity=1,t.emissiveMap=e.emissiveMap===void 0?null:e.emissiveMap,t.bumpMap=e.bumpMap===void 0?null:e.bumpMap,t.bumpScale=1,t.normalMap=e.normalMap===void 0?null:e.normalMap,t.normalMapType=Oi,e.normalScale&&(t.normalScale=e.normalScale),t.displacementMap=null,t.displacementScale=1,t.displacementBias=0,t.specularMap=e.specularMap===void 0?null:e.specularMap,t.specular=e.specular,t.glossinessMap=e.glossinessMap===void 0?null:e.glossinessMap,t.glossiness=e.glossiness,t.alphaMap=null,t.envMap=e.envMap===void 0?null:e.envMap,t.envMapIntensity=1,t.refractionRatio=.98,t}}class aS{constructor(){this.name=Ve.KHR_MESH_QUANTIZATION}}class Di extends gn{constructor(e,t,n,r){super(e,t,n,r)}copySampleValue_(e){const t=this.resultBuffer,n=this.sampleValues,r=this.valueSize,s=e*r*3+r;for(let o=0;o!==r;o++)t[o]=n[s+o];return t}}Di.prototype.beforeStart_=Di.prototype.copySampleValue_;Di.prototype.afterEnd_=Di.prototype.copySampleValue_;Di.prototype.interpolate_=function(i,e,t,n){const r=this.resultBuffer,s=this.sampleValues,o=this.valueSize,a=o*2,l=o*3,c=n-e,u=(t-e)/c,h=u*u,f=h*u,d=i*l,g=d-l,v=-2*f+3*h,_=f-h,m=1-v,p=_-h+u;for(let y=0;y!==o;y++){const x=s[g+y+o],w=s[g+y+a]*c,A=s[d+y+o],b=s[d+y]*c;r[y]=m*x+p*w+v*A+_*b}return r};const lS=new S0;class cS extends Di{interpolate_(e,t,n,r){const s=super.interpolate_(e,t,n,r);return lS.fromArray(s).normalize().toArray(s),s}}const un={FLOAT:5126,FLOAT_MAT3:35675,FLOAT_MAT4:35676,FLOAT_VEC2:35664,FLOAT_VEC3:35665,FLOAT_VEC4:35666,LINEAR:9729,REPEAT:10497,SAMPLER_2D:35678,POINTS:0,LINES:1,LINE_LOOP:2,LINE_STRIP:3,TRIANGLES:4,TRIANGLE_STRIP:5,TRIANGLE_FAN:6,UNSIGNED_BYTE:5121,UNSIGNED_SHORT:5123},xo={5120:Int8Array,5121:Uint8Array,5122:Int16Array,5123:Uint16Array,5125:Uint32Array,5126:Float32Array},w3={9728:r0,9729:s0,9984:K1,9985:f4,9986:J1,9987:Ni},M3={33071:m0,33648:Wa,10497:Qt},S3={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},cc={POSITION:"position",NORMAL:"normal",TANGENT:"tangent",TEXCOORD_0:"uv",TEXCOORD_1:"uv2",COLOR_0:"color",WEIGHTS_0:"skinWeight",JOINTS_0:"skinIndex"},In={scale:"scale",translation:"position",rotation:"quaternion",weights:"morphTargetInfluences"},uS={CUBICSPLINE:void 0,LINEAR:Nr,STEP:lo},E1={OPAQUE:"OPAQUE",MASK:"MASK",BLEND:"BLEND"};function hS(i){return i.DefaultMaterial===void 0&&(i.DefaultMaterial=new ns({color:16777215,emissive:0,metalness:1,roughness:1,transparent:!1,depthTest:!0,side:Dr})),i.DefaultMaterial}function Cs(i,e,t){for(const n in t.extensions)i[n]===void 0&&(e.userData.gltfExtensions=e.userData.gltfExtensions||{},e.userData.gltfExtensions[n]=t.extensions[n])}function bi(i,e){e.extras!==void 0&&(typeof e.extras=="object"?Object.assign(i.userData,e.extras):console.warn("THREE.GLTFLoader: Ignoring primitive type .extras, "+e.extras))}function fS(i,e,t){let n=!1,r=!1;for(let a=0,l=e.length;a{const l=this.associations.get(o);l!=null&&this.associations.set(a,l);for(const[c,u]of o.children.entries())s(u,a.children[c])};return s(n,r),r.name+="_instance_"+e.uses[t]++,r}_invokeOne(e){const t=Object.values(this.plugins);t.push(this);for(let n=0;n=2&&_.setY(B,A[b*l+1]),l>=3&&_.setZ(B,A[b*l+2]),l>=4&&_.setW(B,A[b*l+3]),l>=5)throw new Error("THREE.GLTFLoader: Unsupported itemSize in sparse BufferAttribute.")}}return _})}loadTexture(e){const t=this.json,n=this.options,r=t.textures[e],s=t.images[r.source];let o=this.textureLoader;if(s.uri){const a=n.manager.getHandler(s.uri);a!==null&&(o=a)}return this.loadTextureImage(e,s,o)}loadTextureImage(e,t,n){const r=this,s=this.json,o=this.options,a=s.textures[e],l=(t.uri||t.bufferView)+":"+a.sampler;if(this.textureCache[l])return this.textureCache[l];const c=self.URL||self.webkitURL;let u=t.uri||"",h=!1;if(t.bufferView!==void 0)u=r.getDependency("bufferView",t.bufferView).then(function(d){h=!0;const g=new Blob([d],{type:t.mimeType});return u=c.createObjectURL(g),u});else if(t.uri===void 0)throw new Error("THREE.GLTFLoader: Image "+e+" is missing URI and bufferView");const f=Promise.resolve(u).then(function(d){return new Promise(function(g,v){let _=g;n.isImageBitmapLoader===!0&&(_=function(m){const p=new A0(m);p.needsUpdate=!0,g(p)}),n.load(Ut.resolveURL(d,o.path),_,void 0,v)})}).then(function(d){h===!0&&c.revokeObjectURL(u),d.flipY=!1,a.name&&(d.name=a.name);const v=(s.samplers||{})[a.sampler]||{};return d.magFilter=w3[v.magFilter]||s0,d.minFilter=w3[v.minFilter]||Ni,d.wrapS=M3[v.wrapS]||Qt,d.wrapT=M3[v.wrapT]||Qt,r.associations.set(d,{textures:e}),d}).catch(function(){return console.error("THREE.GLTFLoader: Couldn't load texture",u),null});return this.textureCache[l]=f,f}assignTexture(e,t,n){const r=this;return this.getDependency("texture",n.index).then(function(s){if(n.texCoord!==void 0&&n.texCoord!=0&&!(t==="aoMap"&&n.texCoord==1)&&console.warn("THREE.GLTFLoader: Custom UV set "+n.texCoord+" for texture "+t+" not yet supported."),r.extensions[Ve.KHR_TEXTURE_TRANSFORM]){const o=n.extensions!==void 0?n.extensions[Ve.KHR_TEXTURE_TRANSFORM]:void 0;if(o){const a=r.associations.get(s);s=r.extensions[Ve.KHR_TEXTURE_TRANSFORM].extendTexture(s,o),r.associations.set(s,a)}}return e[t]=s,s})}assignFinalMaterial(e){const t=e.geometry;let n=e.material;const r=t.attributes.tangent===void 0,s=t.attributes.color!==void 0,o=t.attributes.normal===void 0;if(e.isPoints){const a="PointsMaterial:"+n.uuid;let l=this.cache.get(a);l||(l=new El,D0.prototype.copy.call(l,n),l.color.copy(n.color),l.map=n.map,l.sizeAttenuation=!1,this.cache.add(a,l)),n=l}else if(e.isLine){const a="LineBasicMaterial:"+n.uuid;let l=this.cache.get(a);l||(l=new ri,D0.prototype.copy.call(l,n),l.color.copy(n.color),this.cache.add(a,l)),n=l}if(r||s||o){let a="ClonedMaterial:"+n.uuid+":";n.isGLTFSpecularGlossinessMaterial&&(a+="specular-glossiness:"),r&&(a+="derivative-tangents:"),s&&(a+="vertex-colors:"),o&&(a+="flat-shading:");let l=this.cache.get(a);l||(l=n.clone(),s&&(l.vertexColors=!0),o&&(l.flatShading=!0),r&&(l.normalScale&&(l.normalScale.y*=-1),l.clearcoatNormalScale&&(l.clearcoatNormalScale.y*=-1)),this.cache.add(a,l),this.associations.set(l,this.associations.get(n))),n=l}n.aoMap&&t.attributes.uv2===void 0&&t.attributes.uv!==void 0&&t.setAttribute("uv2",t.attributes.uv),e.material=n}getMaterialType(){return ns}loadMaterial(e){const t=this,n=this.json,r=this.extensions,s=n.materials[e];let o;const a={},l=s.extensions||{},c=[];if(l[Ve.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS]){const h=r[Ve.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS];o=h.getMaterialType(),c.push(h.extendParams(a,s,t))}else if(l[Ve.KHR_MATERIALS_UNLIT]){const h=r[Ve.KHR_MATERIALS_UNLIT];o=h.getMaterialType(),c.push(h.extendParams(a,s,t))}else{const h=s.pbrMetallicRoughness||{};if(a.color=new be(1,1,1),a.opacity=1,Array.isArray(h.baseColorFactor)){const f=h.baseColorFactor;a.color.fromArray(f),a.opacity=f[3]}h.baseColorTexture!==void 0&&c.push(t.assignTexture(a,"map",h.baseColorTexture)),a.metalness=h.metallicFactor!==void 0?h.metallicFactor:1,a.roughness=h.roughnessFactor!==void 0?h.roughnessFactor:1,h.metallicRoughnessTexture!==void 0&&(c.push(t.assignTexture(a,"metalnessMap",h.metallicRoughnessTexture)),c.push(t.assignTexture(a,"roughnessMap",h.metallicRoughnessTexture))),o=this._invokeOne(function(f){return f.getMaterialType&&f.getMaterialType(e)}),c.push(Promise.all(this._invokeAll(function(f){return f.extendMaterialParams&&f.extendMaterialParams(e,a)})))}s.doubleSided===!0&&(a.side=Zn);const u=s.alphaMode||E1.OPAQUE;if(u===E1.BLEND?(a.transparent=!0,a.depthWrite=!1):(a.format=Yt,a.transparent=!1,u===E1.MASK&&(a.alphaTest=s.alphaCutoff!==void 0?s.alphaCutoff:.5)),s.normalTexture!==void 0&&o!==xt&&(c.push(t.assignTexture(a,"normalMap",s.normalTexture)),a.normalScale=new ee(1,1),s.normalTexture.scale!==void 0)){const h=s.normalTexture.scale;a.normalScale.set(h,h)}return s.occlusionTexture!==void 0&&o!==xt&&(c.push(t.assignTexture(a,"aoMap",s.occlusionTexture)),s.occlusionTexture.strength!==void 0&&(a.aoMapIntensity=s.occlusionTexture.strength)),s.emissiveFactor!==void 0&&o!==xt&&(a.emissive=new be().fromArray(s.emissiveFactor)),s.emissiveTexture!==void 0&&o!==xt&&c.push(t.assignTexture(a,"emissiveMap",s.emissiveTexture)),Promise.all(c).then(function(){let h;return o===lc?h=r[Ve.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS].createMaterial(a):h=new o(a),s.name&&(h.name=s.name),h.map&&(h.map.encoding=at),h.emissiveMap&&(h.emissiveMap.encoding=at),bi(h,s),t.associations.set(h,{materials:e}),s.extensions&&Cs(r,h,s),h})}createUniqueName(e){const t=Xe.sanitizeNodeName(e||"");let n=t;for(let r=1;this.nodeNamesUsed[n];++r)n=t+"_"+r;return this.nodeNamesUsed[n]=!0,n}loadGeometries(e){const t=this,n=this.extensions,r=this.primitiveCache;function s(a){return n[Ve.KHR_DRACO_MESH_COMPRESSION].decodePrimitive(a,t).then(function(l){return A3(l,a,t)})}const o=[];for(let a=0,l=e.length;a0&&dS(m,s),m.name=t.createUniqueName(s.name||"mesh_"+e),bi(m,s),_.extensions&&Cs(r,m,_),t.assignFinalMaterial(m),h.push(m)}for(let d=0,g=h.length;d1?l=new Dt:a.length===1?l=a[0]:l=new t0,l!==a[0])for(let c=0,u=a.length;c{const h=new Map;for(const[f,d]of s.associations)(f instanceof D0||f instanceof A0)&&h.set(f,d);return u.traverse(f=>{const d=s.associations.get(f);d!=null&&h.set(f,d)}),h};return s.associations=c(o),o})}}function N5(i,e,t,n){const r=t.nodes[i];return n.getDependency("node",i).then(function(s){if(r.skin===void 0)return s;let o;return n.getDependency("skin",r.skin).then(function(a){o=a;const l=[];for(let c=0,u=o.joints.length;c",t).replace("#include ",n).replace("#include ",r).replace("#include ",s).replace("#include ",o)},Object.defineProperties(this,{specular:{get:function(){return a.specular.value},set:function(l){a.specular.value=l}},specularMap:{get:function(){return a.specularMap.value},set:function(l){a.specularMap.value=l,l?this.defines.USE_SPECULARMAP="":delete this.defines.USE_SPECULARMAP}},glossiness:{get:function(){return a.glossiness.value},set:function(l){a.glossiness.value=l}},glossinessMap:{get:function(){return a.glossinessMap.value},set:function(l){a.glossinessMap.value=l,l?(this.defines.USE_GLOSSINESSMAP="",this.defines.USE_UV=""):(delete this.defines.USE_GLOSSINESSMAP,delete this.defines.USE_UV)}}}),delete this.metalness,delete this.roughness,delete this.metalnessMap,delete this.roughnessMap,this.setValues(e)}copy(e){return super.copy(e),this.specularMap=e.specularMap,this.specular.copy(e.specular),this.glossinessMap=e.glossinessMap,this.glossiness=e.glossiness,delete this.metalness,delete this.roughness,delete this.metalnessMap,delete this.roughnessMap,this}}class oS{constructor(){this.name=We.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS,this.specularGlossinessParams=["color","map","lightMap","lightMapIntensity","aoMap","aoMapIntensity","emissive","emissiveIntensity","emissiveMap","bumpMap","bumpScale","normalMap","normalMapType","displacementMap","displacementScale","displacementBias","specularMap","specular","glossinessMap","glossiness","alphaMap","envMap","envMapIntensity","refractionRatio"]}getMaterialType(){return cc}extendParams(e,t,n){const r=t.extensions[this.name];e.color=new be(1,1,1),e.opacity=1;const s=[];if(Array.isArray(r.diffuseFactor)){const o=r.diffuseFactor;e.color.fromArray(o),e.opacity=o[3]}if(r.diffuseTexture!==void 0&&s.push(n.assignTexture(e,"map",r.diffuseTexture)),e.emissive=new be(0,0,0),e.glossiness=r.glossinessFactor!==void 0?r.glossinessFactor:1,e.specular=new be(1,1,1),Array.isArray(r.specularFactor)&&e.specular.fromArray(r.specularFactor),r.specularGlossinessTexture!==void 0){const o=r.specularGlossinessTexture;s.push(n.assignTexture(e,"glossinessMap",o)),s.push(n.assignTexture(e,"specularMap",o))}return Promise.all(s)}createMaterial(e){const t=new cc(e);return t.fog=!0,t.color=e.color,t.map=e.map===void 0?null:e.map,t.lightMap=null,t.lightMapIntensity=1,t.aoMap=e.aoMap===void 0?null:e.aoMap,t.aoMapIntensity=1,t.emissive=e.emissive,t.emissiveIntensity=1,t.emissiveMap=e.emissiveMap===void 0?null:e.emissiveMap,t.bumpMap=e.bumpMap===void 0?null:e.bumpMap,t.bumpScale=1,t.normalMap=e.normalMap===void 0?null:e.normalMap,t.normalMapType=Oi,e.normalScale&&(t.normalScale=e.normalScale),t.displacementMap=null,t.displacementScale=1,t.displacementBias=0,t.specularMap=e.specularMap===void 0?null:e.specularMap,t.specular=e.specular,t.glossinessMap=e.glossinessMap===void 0?null:e.glossinessMap,t.glossiness=e.glossiness,t.alphaMap=null,t.envMap=e.envMap===void 0?null:e.envMap,t.envMapIntensity=1,t.refractionRatio=.98,t}}class aS{constructor(){this.name=We.KHR_MESH_QUANTIZATION}}class Di extends gn{constructor(e,t,n,r){super(e,t,n,r)}copySampleValue_(e){const t=this.resultBuffer,n=this.sampleValues,r=this.valueSize,s=e*r*3+r;for(let o=0;o!==r;o++)t[o]=n[s+o];return t}}Di.prototype.beforeStart_=Di.prototype.copySampleValue_;Di.prototype.afterEnd_=Di.prototype.copySampleValue_;Di.prototype.interpolate_=function(i,e,t,n){const r=this.resultBuffer,s=this.sampleValues,o=this.valueSize,a=o*2,l=o*3,c=n-e,u=(t-e)/c,h=u*u,f=h*u,d=i*l,g=d-l,v=-2*f+3*h,_=f-h,m=1-v,p=_-h+u;for(let y=0;y!==o;y++){const x=s[g+y+o],w=s[g+y+a]*c,A=s[d+y+o],b=s[d+y]*c;r[y]=m*x+p*w+v*A+_*b}return r};const lS=new S0;class cS extends Di{interpolate_(e,t,n,r){const s=super.interpolate_(e,t,n,r);return lS.fromArray(s).normalize().toArray(s),s}}const un={FLOAT:5126,FLOAT_MAT3:35675,FLOAT_MAT4:35676,FLOAT_VEC2:35664,FLOAT_VEC3:35665,FLOAT_VEC4:35666,LINEAR:9729,REPEAT:10497,SAMPLER_2D:35678,POINTS:0,LINES:1,LINE_LOOP:2,LINE_STRIP:3,TRIANGLES:4,TRIANGLE_STRIP:5,TRIANGLE_FAN:6,UNSIGNED_BYTE:5121,UNSIGNED_SHORT:5123},xo={5120:Int8Array,5121:Uint8Array,5122:Int16Array,5123:Uint16Array,5125:Uint32Array,5126:Float32Array},w3={9728:r0,9729:s0,9984:J1,9985:f4,9986:$1,9987:Ni},M3={33071:m0,33648:Wa,10497:Qt},S3={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},uc={POSITION:"position",NORMAL:"normal",TANGENT:"tangent",TEXCOORD_0:"uv",TEXCOORD_1:"uv2",COLOR_0:"color",WEIGHTS_0:"skinWeight",JOINTS_0:"skinIndex"},In={scale:"scale",translation:"position",rotation:"quaternion",weights:"morphTargetInfluences"},uS={CUBICSPLINE:void 0,LINEAR:Or,STEP:lo},L1={OPAQUE:"OPAQUE",MASK:"MASK",BLEND:"BLEND"};function hS(i){return i.DefaultMaterial===void 0&&(i.DefaultMaterial=new is({color:16777215,emissive:0,metalness:1,roughness:1,transparent:!1,depthTest:!0,side:Nr})),i.DefaultMaterial}function Rs(i,e,t){for(const n in t.extensions)i[n]===void 0&&(e.userData.gltfExtensions=e.userData.gltfExtensions||{},e.userData.gltfExtensions[n]=t.extensions[n])}function bi(i,e){e.extras!==void 0&&(typeof e.extras=="object"?Object.assign(i.userData,e.extras):console.warn("THREE.GLTFLoader: Ignoring primitive type .extras, "+e.extras))}function fS(i,e,t){let n=!1,r=!1;for(let a=0,l=e.length;a{const l=this.associations.get(o);l!=null&&this.associations.set(a,l);for(const[c,u]of o.children.entries())s(u,a.children[c])};return s(n,r),r.name+="_instance_"+e.uses[t]++,r}_invokeOne(e){const t=Object.values(this.plugins);t.push(this);for(let n=0;n=2&&_.setY(B,A[b*l+1]),l>=3&&_.setZ(B,A[b*l+2]),l>=4&&_.setW(B,A[b*l+3]),l>=5)throw new Error("THREE.GLTFLoader: Unsupported itemSize in sparse BufferAttribute.")}}return _})}loadTexture(e){const t=this.json,n=this.options,r=t.textures[e],s=t.images[r.source];let o=this.textureLoader;if(s.uri){const a=n.manager.getHandler(s.uri);a!==null&&(o=a)}return this.loadTextureImage(e,s,o)}loadTextureImage(e,t,n){const r=this,s=this.json,o=this.options,a=s.textures[e],l=(t.uri||t.bufferView)+":"+a.sampler;if(this.textureCache[l])return this.textureCache[l];const c=self.URL||self.webkitURL;let u=t.uri||"",h=!1;if(t.bufferView!==void 0)u=r.getDependency("bufferView",t.bufferView).then(function(d){h=!0;const g=new Blob([d],{type:t.mimeType});return u=c.createObjectURL(g),u});else if(t.uri===void 0)throw new Error("THREE.GLTFLoader: Image "+e+" is missing URI and bufferView");const f=Promise.resolve(u).then(function(d){return new Promise(function(g,v){let _=g;n.isImageBitmapLoader===!0&&(_=function(m){const p=new A0(m);p.needsUpdate=!0,g(p)}),n.load(Ut.resolveURL(d,o.path),_,void 0,v)})}).then(function(d){h===!0&&c.revokeObjectURL(u),d.flipY=!1,a.name&&(d.name=a.name);const v=(s.samplers||{})[a.sampler]||{};return d.magFilter=w3[v.magFilter]||s0,d.minFilter=w3[v.minFilter]||Ni,d.wrapS=M3[v.wrapS]||Qt,d.wrapT=M3[v.wrapT]||Qt,r.associations.set(d,{textures:e}),d}).catch(function(){return console.error("THREE.GLTFLoader: Couldn't load texture",u),null});return this.textureCache[l]=f,f}assignTexture(e,t,n){const r=this;return this.getDependency("texture",n.index).then(function(s){if(n.texCoord!==void 0&&n.texCoord!=0&&!(t==="aoMap"&&n.texCoord==1)&&console.warn("THREE.GLTFLoader: Custom UV set "+n.texCoord+" for texture "+t+" not yet supported."),r.extensions[We.KHR_TEXTURE_TRANSFORM]){const o=n.extensions!==void 0?n.extensions[We.KHR_TEXTURE_TRANSFORM]:void 0;if(o){const a=r.associations.get(s);s=r.extensions[We.KHR_TEXTURE_TRANSFORM].extendTexture(s,o),r.associations.set(s,a)}}return e[t]=s,s})}assignFinalMaterial(e){const t=e.geometry;let n=e.material;const r=t.attributes.tangent===void 0,s=t.attributes.color!==void 0,o=t.attributes.normal===void 0;if(e.isPoints){const a="PointsMaterial:"+n.uuid;let l=this.cache.get(a);l||(l=new Ll,D0.prototype.copy.call(l,n),l.color.copy(n.color),l.map=n.map,l.sizeAttenuation=!1,this.cache.add(a,l)),n=l}else if(e.isLine){const a="LineBasicMaterial:"+n.uuid;let l=this.cache.get(a);l||(l=new ri,D0.prototype.copy.call(l,n),l.color.copy(n.color),this.cache.add(a,l)),n=l}if(r||s||o){let a="ClonedMaterial:"+n.uuid+":";n.isGLTFSpecularGlossinessMaterial&&(a+="specular-glossiness:"),r&&(a+="derivative-tangents:"),s&&(a+="vertex-colors:"),o&&(a+="flat-shading:");let l=this.cache.get(a);l||(l=n.clone(),s&&(l.vertexColors=!0),o&&(l.flatShading=!0),r&&(l.normalScale&&(l.normalScale.y*=-1),l.clearcoatNormalScale&&(l.clearcoatNormalScale.y*=-1)),this.cache.add(a,l),this.associations.set(l,this.associations.get(n))),n=l}n.aoMap&&t.attributes.uv2===void 0&&t.attributes.uv!==void 0&&t.setAttribute("uv2",t.attributes.uv),e.material=n}getMaterialType(){return is}loadMaterial(e){const t=this,n=this.json,r=this.extensions,s=n.materials[e];let o;const a={},l=s.extensions||{},c=[];if(l[We.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS]){const h=r[We.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS];o=h.getMaterialType(),c.push(h.extendParams(a,s,t))}else if(l[We.KHR_MATERIALS_UNLIT]){const h=r[We.KHR_MATERIALS_UNLIT];o=h.getMaterialType(),c.push(h.extendParams(a,s,t))}else{const h=s.pbrMetallicRoughness||{};if(a.color=new be(1,1,1),a.opacity=1,Array.isArray(h.baseColorFactor)){const f=h.baseColorFactor;a.color.fromArray(f),a.opacity=f[3]}h.baseColorTexture!==void 0&&c.push(t.assignTexture(a,"map",h.baseColorTexture)),a.metalness=h.metallicFactor!==void 0?h.metallicFactor:1,a.roughness=h.roughnessFactor!==void 0?h.roughnessFactor:1,h.metallicRoughnessTexture!==void 0&&(c.push(t.assignTexture(a,"metalnessMap",h.metallicRoughnessTexture)),c.push(t.assignTexture(a,"roughnessMap",h.metallicRoughnessTexture))),o=this._invokeOne(function(f){return f.getMaterialType&&f.getMaterialType(e)}),c.push(Promise.all(this._invokeAll(function(f){return f.extendMaterialParams&&f.extendMaterialParams(e,a)})))}s.doubleSided===!0&&(a.side=Kn);const u=s.alphaMode||L1.OPAQUE;if(u===L1.BLEND?(a.transparent=!0,a.depthWrite=!1):(a.format=Yt,a.transparent=!1,u===L1.MASK&&(a.alphaTest=s.alphaCutoff!==void 0?s.alphaCutoff:.5)),s.normalTexture!==void 0&&o!==xt&&(c.push(t.assignTexture(a,"normalMap",s.normalTexture)),a.normalScale=new ee(1,1),s.normalTexture.scale!==void 0)){const h=s.normalTexture.scale;a.normalScale.set(h,h)}return s.occlusionTexture!==void 0&&o!==xt&&(c.push(t.assignTexture(a,"aoMap",s.occlusionTexture)),s.occlusionTexture.strength!==void 0&&(a.aoMapIntensity=s.occlusionTexture.strength)),s.emissiveFactor!==void 0&&o!==xt&&(a.emissive=new be().fromArray(s.emissiveFactor)),s.emissiveTexture!==void 0&&o!==xt&&c.push(t.assignTexture(a,"emissiveMap",s.emissiveTexture)),Promise.all(c).then(function(){let h;return o===cc?h=r[We.KHR_MATERIALS_PBR_SPECULAR_GLOSSINESS].createMaterial(a):h=new o(a),s.name&&(h.name=s.name),h.map&&(h.map.encoding=at),h.emissiveMap&&(h.emissiveMap.encoding=at),bi(h,s),t.associations.set(h,{materials:e}),s.extensions&&Rs(r,h,s),h})}createUniqueName(e){const t=Xe.sanitizeNodeName(e||"");let n=t;for(let r=1;this.nodeNamesUsed[n];++r)n=t+"_"+r;return this.nodeNamesUsed[n]=!0,n}loadGeometries(e){const t=this,n=this.extensions,r=this.primitiveCache;function s(a){return n[We.KHR_DRACO_MESH_COMPRESSION].decodePrimitive(a,t).then(function(l){return A3(l,a,t)})}const o=[];for(let a=0,l=e.length;a0&&dS(m,s),m.name=t.createUniqueName(s.name||"mesh_"+e),bi(m,s),_.extensions&&Rs(r,m,_),t.assignFinalMaterial(m),h.push(m)}for(let d=0,g=h.length;d1?l=new Dt:a.length===1?l=a[0]:l=new t0,l!==a[0])for(let c=0,u=a.length;c{const h=new Map;for(const[f,d]of s.associations)(f instanceof D0||f instanceof A0)&&h.set(f,d);return u.traverse(f=>{const d=s.associations.get(f);d!=null&&h.set(f,d)}),h};return s.associations=c(o),o})}}function N5(i,e,t,n){const r=t.nodes[i];return n.getDependency("node",i).then(function(s){if(r.skin===void 0)return s;let o;return n.getDependency("skin",r.skin).then(function(a){o=a;const l=[];for(let c=0,u=o.joints.length;c Licensed under MIT. https://github.com/101arrowz/fflate/blob/master/LICENSE version 0.6.9 -*/var L3={},hc=function(i){return URL.createObjectURL(new Blob([i],{type:"text/javascript"}))},O5=function(i){return new Worker(i)};try{URL.revokeObjectURL(hc(""))}catch{hc=function(e){return"data:application/javascript;charset=UTF-8,"+encodeURI(e)},O5=function(e){return new Worker(e,{type:"module"})}}var vS=function(i,e,t,n,r){var s=O5(L3[e]||(L3[e]=hc(i)));return s.onerror=function(o){return r(o.error,null)},s.onmessage=function(o){return r(null,o.data)},s.postMessage(t,n),s},Ge=Uint8Array,k0=Uint16Array,vn=Uint32Array,ss=new Ge([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),os=new Ge([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),yo=new Ge([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),U5=function(i,e){for(var t=new k0(31),n=0;n<31;++n)t[n]=e+=1<>>1|(d0&21845)<<1;Dn=(Dn&52428)>>>2|(Dn&13107)<<2,Dn=(Dn&61680)>>>4|(Dn&3855)<<4,_o[d0]=((Dn&65280)>>>8|(Dn&255)<<8)>>>1}var _t=function(i,e,t){for(var n=i.length,r=0,s=new k0(e);r>>l]=c}else for(a=new k0(n),r=0;r>>15-i[r]);return a},xn=new Ge(288);for(var d0=0;d0<144;++d0)xn[d0]=8;for(var d0=144;d0<256;++d0)xn[d0]=9;for(var d0=256;d0<280;++d0)xn[d0]=7;for(var d0=280;d0<288;++d0)xn[d0]=8;var Vr=new Ge(32);for(var d0=0;d0<32;++d0)Vr[d0]=5;var G5=_t(xn,9,0),H5=_t(xn,9,1),V5=_t(Vr,5,0),W5=_t(Vr,5,1),Fa=function(i){for(var e=i[0],t=1;te&&(e=i[t]);return e},mt=function(i,e,t){var n=e/8|0;return(i[n]|i[n+1]<<8)>>(e&7)&t},Ia=function(i,e){var t=e/8|0;return(i[t]|i[t+1]<<8|i[t+2]<<16)>>(e&7)},Co=function(i){return(i/8|0)+(i&7&&1)},bt=function(i,e,t){(e==null||e<0)&&(e=0),(t==null||t>i.length)&&(t=i.length);var n=new(i instanceof k0?k0:i instanceof vn?vn:Ge)(t-e);return n.set(i.subarray(e,t)),n},Ro=function(i,e,t){var n=i.length;if(!n||t&&!t.l&&n<5)return e||new Ge(0);var r=!e||t,s=!t||t.i;t||(t={}),e||(e=new Ge(n*3));var o=function(K){var V=e.length;if(K>V){var te=new Ge(Math.max(V*2,K));te.set(e),e=te}},a=t.f||0,l=t.p||0,c=t.b||0,u=t.l,h=t.d,f=t.m,d=t.n,g=n*8;do{if(!u){t.f=a=mt(i,l,1);var v=mt(i,l+1,3);if(l+=3,v)if(v==1)u=H5,h=W5,f=9,d=5;else if(v==2){var y=mt(i,l,31)+257,x=mt(i,l+10,15)+4,w=y+mt(i,l+5,31)+1;l+=14;for(var A=new Ge(w),b=new Ge(19),L=0;L>>4;if(_<16)A[L++]=_;else{var O=0,G=0;for(_==16?(G=3+mt(i,l,3),l+=2,O=A[L-1]):_==17?(G=3+mt(i,l,7),l+=3):_==18&&(G=11+mt(i,l,127),l+=7);G--;)A[L++]=O}}var j=A.subarray(0,y),N=A.subarray(y);f=Fa(j),d=Fa(N),u=_t(j,f,1),h=_t(N,d,1)}else throw"invalid block type";else{var _=Co(l)+4,m=i[_-4]|i[_-3]<<8,p=_+m;if(p>n){if(s)throw"unexpected EOF";break}r&&o(c+m),e.set(i.subarray(_,p),c),t.b=c+=m,t.p=l=p*8;continue}if(l>g){if(s)throw"unexpected EOF";break}}r&&o(c+131072);for(var k=(1<>>4;if(l+=O&15,l>g){if(s)throw"unexpected EOF";break}if(!O)throw"invalid length/literal";if(ve<256)e[c++]=ve;else if(ve==256){le=l,u=null;break}else{var ce=ve-254;if(ve>264){var L=ve-257,ye=ss[L];ce=mt(i,l,(1<>>4;if(!$)throw"invalid distance";l+=$&15;var N=k5[se];if(se>3){var ye=os[se];N+=Ia(i,l)&(1<g){if(s)throw"unexpected EOF";break}r&&o(c+131072);for(var pe=c+ce;c>>8},fr=function(i,e,t){t<<=e&7;var n=e/8|0;i[n]|=t,i[n+1]|=t>>>8,i[n+2]|=t>>>16},Da=function(i,e){for(var t=[],n=0;nf&&(f=s[n].s);var d=new k0(f+1),g=Ka(t[u-1],d,0);if(g>e){var n=0,v=0,_=g-e,m=1<<_;for(s.sort(function(A,b){return d[b.s]-d[A.s]||A.f-b.f});ne)v+=m-(1<>>=_;v>0;){var y=s[n].s;d[y]=0&&v;--n){var x=s[n].s;d[x]==e&&(--d[x],++v)}g=e}return[new Ge(d),g]},Ka=function(i,e,t){return i.s==-1?Math.max(Ka(i.l,e,t+1),Ka(i.r,e,t+1)):e[i.s]=t},dc=function(i){for(var e=i.length;e&&!i[--e];);for(var t=new k0(++e),n=0,r=i[0],s=1,o=function(l){t[n++]=l},a=1;a<=e;++a)if(i[a]==r&&a!=e)++s;else{if(!r&&s>2){for(;s>138;s-=138)o(32754);s>2&&(o(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(o(r),--s;s>6;s-=6)o(8304);s>2&&(o(s-3<<5|8208),s=0)}for(;s--;)o(r);s=1,r=i[a]}return[t.subarray(0,n),e]},dr=function(i,e){for(var t=0,n=0;n>>8,i[r+2]=i[r]^255,i[r+3]=i[r+1]^255;for(var s=0;s4&&!I[yo[Y-1]];--Y);var O=c+5<<3,G=dr(r,xn)+dr(s,Vr)+o,j=dr(r,f)+dr(s,v)+o+14+3*Y+dr(b,I)+(2*b[16]+3*b[17]+7*b[18]);if(O<=G&&O<=j)return Ks(e,u,i.subarray(l,l+c));var N,k,Z,le;if(Ht(e,u,1+(j15&&(Ht(e,u,$[L]>>>5&127),u+=$[L]>>>12)}}else N=G5,k=xn,Z=V5,le=Vr;for(var L=0;L255){var se=n[L]>>>18&31;fr(e,u,N[se+257]),u+=k[se+257],se>7&&(Ht(e,u,n[L]>>>23&31),u+=ss[se]);var pe=n[L]&31;fr(e,u,Z[pe]),u+=le[pe],pe>3&&(fr(e,u,n[L]>>>5&8191),u+=os[pe])}else fr(e,u,N[n[L]]),u+=k[n[L]];return fr(e,u,N[256]),u+k[256]},X5=new vn([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),fn=new Ge(0),j5=function(i,e,t,n,r,s){var o=i.length,a=new Ge(n+o+5*(1+Math.ceil(o/7e3))+r),l=a.subarray(n,a.length-r),c=0;if(!e||o<8)for(var u=0;u<=o;u+=65535){var h=u+65535;h>>13,g=f&8191,v=(1<7e3||I>24576)&&N>423){c=pc(i,l,0,w,A,b,B,I,Y,u-Y,c),I=L=B=0,Y=u;for(var k=0;k<286;++k)A[k]=0;for(var k=0;k<30;++k)b[k]=0}var Z=2,le=0,ve=g,ce=G-j&32767;if(N>2&&O==x(u-ce))for(var ye=Math.min(d,N)-1,$=Math.min(32767,u),se=Math.min(258,N);ce<=$&&--ve&&G!=j;){if(i[u+Z]==i[u+Z-ce]){for(var pe=0;peZ){if(Z=pe,le=ce,pe>ye)break;for(var K=Math.min(ce,pe-2),V=0,k=0;kV&&(V=re,j=te)}}}G=j,j=_[G],ce+=G-j+32768&32767}if(le){w[I++]=268435456|Za[Z]<<18|fc[le];var we=Za[Z]&31,M=fc[le]&31;B+=ss[we]+os[M],++A[257+we],++b[M],C=u+Z,++L}else w[I++]=i[u],++A[i[u]]}}c=pc(i,l,s,w,A,b,B,I,Y,u-Y,c),!s&&c&7&&(c=Ks(l,c+1,fn))}return bt(a,0,n+Co(c)+r)},Y5=function(){for(var i=new vn(256),e=0;e<256;++e){for(var t=e,n=9;--n;)t=(t&1&&3988292384)^t>>>1;i[e]=t}return i}(),as=function(){var i=-1;return{p:function(e){for(var t=i,n=0;n>>8;i=t},d:function(){return~i}}},w9=function(){var i=1,e=0;return{p:function(t){for(var n=i,r=e,s=t.length,o=0;o!=s;){for(var a=Math.min(o+2655,s);o>16),r=(r&65535)+15*(r>>16)}i=n,e=r},d:function(){return i%=65521,e%=65521,(i&255)<<24|i>>>8<<16|(e&255)<<8|e>>>8}}},ki=function(i,e,t,n,r){return j5(i,e.level==null?6:e.level,e.mem==null?Math.ceil(Math.max(8,Math.min(13,Math.log(i.length)))*1.5):12+e.mem,t,n,!r)},Fo=function(i,e){var t={};for(var n in i)t[n]=i[n];for(var n in e)t[n]=e[n];return t},P3=function(i,e,t){for(var n=i(),r=i.toString(),s=r.slice(r.indexOf("[")+1,r.lastIndexOf("]")).replace(/ /g,"").split(","),o=0;o>>0},L1=function(i,e){return M0(i,e)+M0(i,e+4)*4294967296},e0=function(i,e,t){for(;t;++e)i[e]=t,t>>>=8},S9=function(i,e){var t=e.filename;if(i[0]=31,i[1]=139,i[2]=8,i[8]=e.level<2?4:e.level==9?2:0,i[9]=3,e.mtime!=0&&e0(i,4,Math.floor(new Date(e.mtime||Date.now())/1e3)),t){i[3]=8;for(var n=0;n<=t.length;++n)i[n+10]=t.charCodeAt(n)}},T9=function(i){if(i[0]!=31||i[1]!=139||i[2]!=8)throw"invalid gzip data";var e=i[3],t=10;e&4&&(t+=i[10]|(i[11]<<8)+2);for(var n=(e>>3&1)+(e>>4&1);n>0;n-=!i[t++]);return t+(e&2)},$5=function(i){var e=i.length;return(i[e-4]|i[e-3]<<8|i[e-2]<<16|i[e-1]<<24)>>>0},A9=function(i){return 10+(i.filename&&i.filename.length+1||0)},E9=function(i,e){var t=e.level,n=t==0?0:t<6?1:t==9?3:2;i[0]=120,i[1]=n<<6|(n?32-2*n:1)},ef=function(i){if((i[0]&15)!=8||i[0]>>>4>7||(i[0]<<8|i[1])%31)throw"invalid zlib data";if(i[1]&32)throw"invalid zlib data: preset dictionaries not supported"};function L9(i,e){return!e&&typeof i=="function"&&(e=i,i={}),this.ondata=e,i}var Kt=function(){function i(e,t){!t&&typeof e=="function"&&(t=e,e={}),this.ondata=t,this.o=e||{}}return i.prototype.p=function(e,t){this.ondata(ki(e,this.o,0,0,!t),t)},i.prototype.push=function(e,t){if(this.d)throw"stream finished";if(!this.ondata)throw"no stream handler";this.d=t,this.p(e,t||!1)},i}(),tf=function(){function i(e,t){hs([cs,function(){return[wt,Kt]}],this,L9.call(this,e,t),function(n){var r=new Kt(n.data);onmessage=wt(r)},6)}return i}();function nf(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return us(i,e,[cs],function(n){return oi(Io(n.data[0],n.data[1]))},0,t)}function Io(i,e){return ki(i,e||{},0,0)}var lt=function(){function i(e){this.s={},this.p=new Ge(0),this.ondata=e}return i.prototype.e=function(e){if(this.d)throw"stream finished";if(!this.ondata)throw"no stream handler";var t=this.p.length,n=new Ge(t+e.length);n.set(this.p),n.set(e,t),this.p=n},i.prototype.c=function(e){this.d=this.s.i=e||!1;var t=this.s.b,n=Ro(this.p,this.o,this.s);this.ondata(bt(n,t,this.s.b),this.d),this.o=bt(n,this.s.b-32768),this.s.b=this.o.length,this.p=bt(this.p,this.s.p/8|0),this.s.p&=7},i.prototype.push=function(e,t){this.e(e),this.c(t)},i}(),P9=function(){function i(e){this.ondata=e,hs([ls,function(){return[wt,lt]}],this,0,function(){var t=new lt;onmessage=wt(t)},7)}return i}();function C9(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return us(i,e,[ls],function(n){return oi(fs(n.data[0],M9(n.data[1])))},1,t)}function fs(i,e){return Ro(i,e)}var Ja=function(){function i(e,t){this.c=as(),this.l=0,this.v=1,Kt.call(this,e,t)}return i.prototype.push=function(e,t){Kt.prototype.push.call(this,e,t)},i.prototype.p=function(e,t){this.c.p(e),this.l+=e.length;var n=ki(e,this.o,this.v&&A9(this.o),t&&8,!t);this.v&&(S9(n,this.o),this.v=0),t&&(e0(n,n.length-8,this.c.d()),e0(n,n.length-4,this.l)),this.ondata(n,t)},i}(),C3=function(){function i(e,t){hs([cs,Q5,function(){return[wt,Kt,Ja]}],this,L9.call(this,e,t),function(n){var r=new Ja(n.data);onmessage=wt(r)},8)}return i}();function R3(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return us(i,e,[cs,Q5,function(){return[$a]}],function(n){return oi($a(n.data[0],n.data[1]))},2,t)}function $a(i,e){e||(e={});var t=as(),n=i.length;t.p(i);var r=ki(i,e,A9(e),8),s=r.length;return S9(r,e),e0(r,s-8,t.d()),e0(r,s-4,n),r}var el=function(){function i(e){this.v=1,lt.call(this,e)}return i.prototype.push=function(e,t){if(lt.prototype.e.call(this,e),this.v){var n=this.p.length>3?T9(this.p):4;if(n>=this.p.length&&!t)return;this.p=this.p.subarray(n),this.v=0}if(t){if(this.p.length<8)throw"invalid gzip stream";this.p=this.p.subarray(0,-8)}lt.prototype.c.call(this,t)},i}(),rf=function(){function i(e){this.ondata=e,hs([ls,Z5,function(){return[wt,lt,el]}],this,0,function(){var t=new el;onmessage=wt(t)},9)}return i}();function sf(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return us(i,e,[ls,Z5,function(){return[tl]}],function(n){return oi(tl(n.data[0]))},3,t)}function tl(i,e){return Ro(i.subarray(T9(i),-8),e||new Ge($5(i)))}var mc=function(){function i(e,t){this.c=w9(),this.v=1,Kt.call(this,e,t)}return i.prototype.push=function(e,t){Kt.prototype.push.call(this,e,t)},i.prototype.p=function(e,t){this.c.p(e);var n=ki(e,this.o,this.v&&2,t&&4,!t);this.v&&(E9(n,this.o),this.v=0),t&&e0(n,n.length-4,this.c.d()),this.ondata(n,t)},i}(),yS=function(){function i(e,t){hs([cs,K5,function(){return[wt,Kt,mc]}],this,L9.call(this,e,t),function(n){var r=new mc(n.data);onmessage=wt(r)},10)}return i}();function _S(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return us(i,e,[cs,K5,function(){return[gc]}],function(n){return oi(gc(n.data[0],n.data[1]))},4,t)}function gc(i,e){e||(e={});var t=w9();t.p(i);var n=ki(i,e,2,4);return E9(n,e),e0(n,n.length-4,t.d()),n}var nl=function(){function i(e){this.v=1,lt.call(this,e)}return i.prototype.push=function(e,t){if(lt.prototype.e.call(this,e),this.v){if(this.p.length<2&&!t)return;this.p=this.p.subarray(2),this.v=0}if(t){if(this.p.length<4)throw"invalid zlib stream";this.p=this.p.subarray(0,-4)}lt.prototype.c.call(this,t)},i}(),of=function(){function i(e){this.ondata=e,hs([ls,J5,function(){return[wt,lt,nl]}],this,0,function(){var t=new nl;onmessage=wt(t)},11)}return i}();function af(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return us(i,e,[ls,J5,function(){return[bo]}],function(n){return oi(bo(n.data[0],M9(n.data[1])))},5,t)}function bo(i,e){return Ro((ef(i),i.subarray(2,-4)),e)}var lf=function(){function i(e){this.G=el,this.I=lt,this.Z=nl,this.ondata=e}return i.prototype.push=function(e,t){if(!this.ondata)throw"no stream handler";if(this.s)this.s.push(e,t);else{if(this.p&&this.p.length){var n=new Ge(this.p.length+e.length);n.set(this.p),n.set(e,this.p.length)}else this.p=e;if(this.p.length>2){var r=this,s=function(){r.ondata.apply(r,arguments)};this.s=this.p[0]==31&&this.p[1]==139&&this.p[2]==8?new this.G(s):(this.p[0]&15)!=8||this.p[0]>>4>7||(this.p[0]<<8|this.p[1])%31?new this.I(s):new this.Z(s),this.s.push(this.p,t),this.p=null}}},i}(),bS=function(){function i(e){this.G=rf,this.I=P9,this.Z=of,this.ondata=e}return i.prototype.push=function(e,t){lf.prototype.push.call(this,e,t)},i}();function wS(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return i[0]==31&&i[1]==139&&i[2]==8?sf(i,e,t):(i[0]&15)!=8||i[0]>>4>7||(i[0]<<8|i[1])%31?C9(i,e,t):af(i,e,t)}function MS(i,e){return i[0]==31&&i[1]==139&&i[2]==8?tl(i,e):(i[0]&15)!=8||i[0]>>4>7||(i[0]<<8|i[1])%31?fs(i,e):bo(i,e)}var R9=function(i,e,t,n){for(var r in i){var s=i[r],o=e+r;s instanceof Ge?t[o]=[s,n]:Array.isArray(s)?t[o]=[s[0],Fo(n,s[1])]:R9(s,o+"/",t,n)}},F3=typeof TextEncoder<"u"&&new TextEncoder,vc=typeof TextDecoder<"u"&&new TextDecoder,cf=0;try{vc.decode(fn,{stream:!0}),cf=1}catch{}var uf=function(i){for(var e="",t=0;;){var n=i[t++],r=(n>127)+(n>223)+(n>239);if(t+r>i.length)return[e,bt(i,t-1)];r?r==3?(n=((n&15)<<18|(i[t++]&63)<<12|(i[t++]&63)<<6|i[t++]&63)-65536,e+=String.fromCharCode(55296|n>>10,56320|n&1023)):r&1?e+=String.fromCharCode((n&31)<<6|i[t++]&63):e+=String.fromCharCode((n&15)<<12|(i[t++]&63)<<6|i[t++]&63):e+=String.fromCharCode(n)}},SS=function(){function i(e){this.ondata=e,cf?this.t=new TextDecoder:this.p=fn}return i.prototype.push=function(e,t){if(!this.ondata)throw"no callback";if(t=!!t,this.t){if(this.ondata(this.t.decode(e,{stream:!0}),t),t){if(this.t.decode().length)throw"invalid utf-8 data";this.t=null}return}if(!this.p)throw"stream finished";var n=new Ge(this.p.length+e.length);n.set(this.p),n.set(e,this.p.length);var r=uf(n),s=r[0],o=r[1];if(t){if(o.length)throw"invalid utf-8 data";this.p=null}else this.p=o;this.ondata(s,t)},i}(),TS=function(){function i(e){this.ondata=e}return i.prototype.push=function(e,t){if(!this.ondata)throw"no callback";if(this.d)throw"stream finished";this.ondata(ti(e),this.d=t||!1)},i}();function ti(i,e){if(e){for(var t=new Ge(i.length),n=0;n>1)),o=0,a=function(u){s[o++]=u},n=0;ns.length){var l=new Ge(o+8+(r-n<<1));l.set(s),s=l}var c=i.charCodeAt(n);c<128||e?a(c):c<2048?(a(192|c>>6),a(128|c&63)):c>55295&&c<57344?(c=65536+(c&1047552)|i.charCodeAt(++n)&1023,a(240|c>>18),a(128|c>>12&63),a(128|c>>6&63),a(128|c&63)):(a(224|c>>12),a(128|c>>6&63),a(128|c&63))}return bt(s,0,o)}function F9(i,e){if(e){for(var t="",n=0;n65535)throw"extra field too long";e+=n+4}return e},Wr=function(i,e,t,n,r,s,o,a){var l=n.length,c=t.extra,u=a&&a.length,h=Yn(c);e0(i,e,o!=null?33639248:67324752),e+=4,o!=null&&(i[e++]=20,i[e++]=t.os),i[e]=20,e+=2,i[e++]=t.flag<<1|(s==null&&8),i[e++]=r&&8,i[e++]=t.compression&255,i[e++]=t.compression>>8;var f=new Date(t.mtime==null?Date.now():t.mtime),d=f.getFullYear()-1980;if(d<0||d>119)throw"date not in range 1980-2099";if(e0(i,e,d<<25|f.getMonth()+1<<21|f.getDate()<<16|f.getHours()<<11|f.getMinutes()<<5|f.getSeconds()>>>1),e+=4,s!=null&&(e0(i,e,t.crc),e0(i,e+4,s),e0(i,e+8,t.size)),e0(i,e+12,l),e0(i,e+14,h),e+=16,o!=null&&(e0(i,e,u),e0(i,e+6,t.attrs),e0(i,e+10,o),e+=14),i.set(n,e),e+=l,h)for(var g in c){var v=c[g],_=v.length;e0(i,e,+g),e0(i,e+2,_),i.set(v,e+4),e+=4+_}return u&&(i.set(a,e),e+=u),e},I9=function(i,e,t,n,r){e0(i,e,101010256),e0(i,e+8,t),e0(i,e+10,t),e0(i,e+12,n),e0(i,e+16,r)},wo=function(){function i(e){this.filename=e,this.c=as(),this.size=0,this.compression=0}return i.prototype.process=function(e,t){this.ondata(null,e,t)},i.prototype.push=function(e,t){if(!this.ondata)throw"no callback - add to ZIP archive before pushing";this.c.p(e),this.size+=e.length,t&&(this.crc=this.c.d()),this.process(e,t||!1)},i}(),AS=function(){function i(e,t){var n=this;t||(t={}),wo.call(this,e),this.d=new Kt(t,function(r,s){n.ondata(null,r,s)}),this.compression=8,this.flag=hf(t.level)}return i.prototype.process=function(e,t){try{this.d.push(e,t)}catch(n){this.ondata(n,null,t)}},i.prototype.push=function(e,t){wo.prototype.push.call(this,e,t)},i}(),ES=function(){function i(e,t){var n=this;t||(t={}),wo.call(this,e),this.d=new tf(t,function(r,s,o){n.ondata(r,s,o)}),this.compression=8,this.flag=hf(t.level),this.terminate=this.d.terminate}return i.prototype.process=function(e,t){this.d.push(e,t)},i.prototype.push=function(e,t){wo.prototype.push.call(this,e,t)},i}(),LS=function(){function i(e){this.ondata=e,this.u=[],this.d=1}return i.prototype.add=function(e){var t=this;if(this.d&2)throw"stream finished";var n=ti(e.filename),r=n.length,s=e.comment,o=s&&ti(s),a=r!=e.filename.length||o&&s.length!=o.length,l=r+Yn(e.extra)+30;if(r>65535)throw"filename too long";var c=new Ge(l);Wr(c,0,e,n,a);var u=[c],h=function(){for(var _=0,m=u;_65535&&O("filename too long",null),!Y)O(null,p);else if(w<16e4)try{O(null,Io(p,y))}catch(G){O(G,null)}else u.push(nf(p,y,O))},g=0;g65535)throw"filename too long";var m=u?Io(l,c):l,p=m.length,y=as();y.p(l),n.push(Fo(c,{size:l.length,crc:y.d(),c:m,f:h,m:g,u:f!=o.length||g&&d.length!=v,o:r,compression:u})),r+=30+f+_+p,s+=76+2*(f+_)+(v||0)+p}for(var x=new Ge(s+22),w=r,A=s-r,b=0;b0){var r=Math.min(this.c,e.length),s=e.subarray(0,r);if(this.c-=r,this.d?this.d.push(s,!this.c):this.k[0].push(s),e=e.subarray(r),e.length)return this.push(e,t)}else{var o=0,a=0,l=void 0,c=void 0;this.p.length?e.length?(c=new Ge(this.p.length+e.length),c.set(this.p),c.set(e,this.p.length)):c=this.p:c=e;for(var u=c.length,h=this.c,f=h&&this.d,d=function(){var m,p=M0(c,a);if(p==67324752){o=1,l=a,g.d=null,g.c=0;var y=tt(c,a+6),x=tt(c,a+8),w=y&2048,A=y&8,b=tt(c,a+26),L=tt(c,a+28);if(u>a+30+b+L){var B=[];g.k.unshift(B),o=2;var I=M0(c,a+18),C=M0(c,a+22),Y=F9(c.subarray(a+30,a+=30+b),!w);I==4294967295?(m=A?[-2]:pf(c,a),I=m[0],C=m[1]):A&&(I=-1),a+=L,g.c=I;var O,G={name:Y,compression:x,start:function(){if(!G.ondata)throw"no callback";if(!I)G.ondata(null,fn,!0);else{var j=n.o[x];if(!j)throw"unknown compression type "+x;O=I<0?new j(Y):new j(Y,I,C),O.ondata=function(le,ve,ce){G.ondata(le,ve,ce)};for(var N=0,k=B;N=0&&(G.size=I,G.originalSize=C),g.onfile(G)}return"break"}else if(h){if(p==134695760)return l=a+=12+(h==-2&&8),o=3,g.c=0,"break";if(p==33639248)return l=a-=4,o=3,g.c=0,"break"}},g=this;a65558){e("invalid zip file",null);return}var o=tt(i,s+8);o||e(null,{});var a=o,l=M0(i,s+16),c=l==4294967295;if(c){if(s=M0(i,s-12),M0(i,s)!=101075792){e("invalid zip file",null);return}a=o=M0(i,s+32),l=M0(i,s+48)}for(var u=function(f){var d=df(i,l,c),g=d[0],v=d[1],_=d[2],m=d[3],p=d[4],y=d[5],x=ff(i,y);l=p;var w=function(b,L){b?(n(),e(b,null)):(r[m]=L,--o||e(null,r))};if(!g)w(null,bt(i,x,x+v));else if(g==8){var A=i.subarray(x,x+v);if(v<32e4)try{w(null,fs(A,new Ge(_)))}catch(b){w(b,null)}else t.push(C9(A,{size:_},w))}else w("unknown compression type "+g,null)},h=0;h65558)throw"invalid zip file";var n=tt(i,t+8);if(!n)return{};var r=M0(i,t+16),s=r==4294967295;if(s){if(t=M0(i,t-12),M0(i,t)!=101075792)throw"invalid zip file";n=M0(i,t+32),r=M0(i,t+48)}for(var o=0;o=t[n])return n-1;if(e<=t[i])return i;let r=i,s=n,o=Math.floor((r+s)/2);for(;e=t[o+1];)e=v&&(g[d][0]=g[f][0]/a[p+1][m],_=g[d][0]*a[m][p]);const y=m>=-1?1:-m,x=h-1<=p?v-1:t-h;for(let A=y;A<=x;++A)g[d][A]=(g[f][A]-g[f][A-1])/a[p+1][m+A],_+=g[d][A]*a[m+A][p];h<=p&&(g[d][v]=-g[f][v-1]/a[p+1][h],_+=g[d][v]*a[h][p]),o[v][h]=_;const w=f;f=d,d=w}}let u=t;for(let h=1;h<=n;++h){for(let f=0;f<=t;++f)o[h][f]*=u;u*=t-h}return o}function kS(i,e,t,n,r){const s=r0,l=typeof s.Content=="string"&&s.Content!=="";if(a||l){const c=this.parseImage(n[r]);t[s.RelativeFilename||s.Filename]=c}}}}for(const n in e){const r=e[n];t[r]!==void 0?e[n]=t[r]:e[n]=e[n].split("\\").pop()}return e}parseImage(e){const t=e.Content,n=e.RelativeFilename||e.Filename,r=n.slice(n.lastIndexOf(".")+1).toLowerCase();let s;switch(r){case"bmp":s="image/bmp";break;case"jpg":case"jpeg":s="image/jpeg";break;case"png":s="image/png";break;case"tif":s="image/tiff";break;case"tga":this.manager.getHandler(".tga")===null&&console.warn("FBXLoader: TGA loader not found, skipping ",n),s="image/tga";break;default:console.warn('FBXLoader: Image type "'+r+'" is not supported.');return}if(typeof t=="string")return"data:"+s+";base64,"+t;{const o=new Uint8Array(t);return window.URL.createObjectURL(new Blob([o],{type:s}))}}parseTextures(e){const t=new Map;if("Texture"in Be.Objects){const n=Be.Objects.Texture;for(const r in n){const s=this.parseTexture(n[r],e);t.set(parseInt(r),s)}}return t}parseTexture(e,t){const n=this.loadTexture(e,t);n.ID=e.id,n.name=e.attrName;const r=e.WrapModeU,s=e.WrapModeV,o=r!==void 0?r.value:0,a=s!==void 0?s.value:0;if(n.wrapS=o===0?Qt:m0,n.wrapT=a===0?Qt:m0,"Scaling"in e){const l=e.Scaling.value;n.repeat.x=l[0],n.repeat.y=l[1]}return n}loadTexture(e,t){let n;const r=this.textureLoader.path,s=w0.get(e.id).children;s!==void 0&&s.length>0&&t[s[0].ID]!==void 0&&(n=t[s[0].ID],(n.indexOf("blob:")===0||n.indexOf("data:")===0)&&this.textureLoader.setPath(void 0));let o;const a=e.FileName.slice(-3).toLowerCase();if(a==="tga"){const l=this.manager.getHandler(".tga");l===null?(console.warn("FBXLoader: TGA loader not found, creating placeholder texture for",e.RelativeFilename),o=new A0):(l.setPath(this.textureLoader.path),o=l.load(n))}else a==="psd"?(console.warn("FBXLoader: PSD textures are not supported, creating placeholder texture for",e.RelativeFilename),o=new A0):o=this.textureLoader.load(n);return this.textureLoader.setPath(r),o}parseMaterials(e){const t=new Map;if("Material"in Be.Objects){const n=Be.Objects.Material;for(const r in n){const s=this.parseMaterial(n[r],e);s!==null&&t.set(parseInt(r),s)}}return t}parseMaterial(e,t){const n=e.id,r=e.attrName;let s=e.ShadingModel;if(typeof s=="object"&&(s=s.value),!w0.has(n))return null;const o=this.parseParameters(e,t,n);let a;switch(s.toLowerCase()){case"phong":a=new Zs;break;case"lambert":a=new m9;break;default:console.warn('THREE.FBXLoader: unknown material type "%s". Defaulting to MeshPhongMaterial.',s),a=new Zs;break}return a.setValues(o),a.name=r,a}parseParameters(e,t,n){const r={};e.BumpFactor&&(r.bumpScale=e.BumpFactor.value),e.Diffuse?r.color=new be().fromArray(e.Diffuse.value):e.DiffuseColor&&(e.DiffuseColor.type==="Color"||e.DiffuseColor.type==="ColorRGB")&&(r.color=new be().fromArray(e.DiffuseColor.value)),e.DisplacementFactor&&(r.displacementScale=e.DisplacementFactor.value),e.Emissive?r.emissive=new be().fromArray(e.Emissive.value):e.EmissiveColor&&(e.EmissiveColor.type==="Color"||e.EmissiveColor.type==="ColorRGB")&&(r.emissive=new be().fromArray(e.EmissiveColor.value)),e.EmissiveFactor&&(r.emissiveIntensity=parseFloat(e.EmissiveFactor.value)),e.Opacity&&(r.opacity=parseFloat(e.Opacity.value)),r.opacity<1&&(r.transparent=!0),e.ReflectionFactor&&(r.reflectivity=e.ReflectionFactor.value),e.Shininess&&(r.shininess=e.Shininess.value),e.Specular?r.specular=new be().fromArray(e.Specular.value):e.SpecularColor&&e.SpecularColor.type==="Color"&&(r.specular=new be().fromArray(e.SpecularColor.value));const s=this;return w0.get(n).children.forEach(function(o){const a=o.relationship;switch(a){case"Bump":r.bumpMap=s.getTexture(t,o.ID);break;case"Maya|TEX_ao_map":r.aoMap=s.getTexture(t,o.ID);break;case"DiffuseColor":case"Maya|TEX_color_map":r.map=s.getTexture(t,o.ID),r.map!==void 0&&(r.map.encoding=at);break;case"DisplacementColor":r.displacementMap=s.getTexture(t,o.ID);break;case"EmissiveColor":r.emissiveMap=s.getTexture(t,o.ID),r.emissiveMap!==void 0&&(r.emissiveMap.encoding=at);break;case"NormalMap":case"Maya|TEX_normal_map":r.normalMap=s.getTexture(t,o.ID);break;case"ReflectionColor":r.envMap=s.getTexture(t,o.ID),r.envMap!==void 0&&(r.envMap.mapping=Va,r.envMap.encoding=at);break;case"SpecularColor":r.specularMap=s.getTexture(t,o.ID),r.specularMap!==void 0&&(r.specularMap.encoding=at);break;case"TransparentColor":case"TransparencyFactor":r.alphaMap=s.getTexture(t,o.ID),r.transparent=!0;break;case"AmbientColor":case"ShininessExponent":case"SpecularFactor":case"VectorDisplacementColor":default:console.warn("THREE.FBXLoader: %s map is not supported in three.js, skipping texture.",a);break}}),r}getTexture(e,t){return"LayeredTexture"in Be.Objects&&t in Be.Objects.LayeredTexture&&(console.warn("THREE.FBXLoader: layered textures are not supported in three.js. Discarding all but first layer."),t=w0.get(t).children[0].ID),e.get(t)}parseDeformers(){const e={},t={};if("Deformer"in Be.Objects){const n=Be.Objects.Deformer;for(const r in n){const s=n[r],o=w0.get(parseInt(r));if(s.attrType==="Skin"){const a=this.parseSkeleton(o,n);a.ID=r,o.parents.length>1&&console.warn("THREE.FBXLoader: skeleton attached to more than one geometry is not supported."),a.geometryID=o.parents[0].ID,e[r]=a}else if(s.attrType==="BlendShape"){const a={id:r};a.rawTargets=this.parseMorphTargets(o,n),a.id=r,o.parents.length>1&&console.warn("THREE.FBXLoader: morph target attached to more than one geometry is not supported."),t[r]=a}}}return{skeletons:e,morphTargets:t}}parseSkeleton(e,t){const n=[];return e.children.forEach(function(r){const s=t[r.ID];if(s.attrType!=="Cluster")return;const o={ID:r.ID,indices:[],weights:[],transformLink:new Me().fromArray(s.TransformLink.a)};"Indexes"in s&&(o.indices=s.Indexes.a,o.weights=s.Weights.a),n.push(o)}),{rawBones:n,bones:[]}}parseMorphTargets(e,t){const n=[];for(let r=0;r1?o=a:a.length>0?o=a[0]:(o=new Zs({color:13421772}),a.push(o)),"color"in s.attributes&&a.forEach(function(l){l.vertexColors=!0}),s.FBX_Deformer?(r=new Sl(s,o),r.normalizeSkinWeights()):r=new I0(s,o),r}createCurve(e,t){const n=e.children.reduce(function(s,o){return t.has(o.ID)&&(s=t.get(o.ID)),s},null),r=new ri({color:3342591,linewidth:1});return new es(n,r)}getTransformData(e,t){const n={};"InheritType"in t&&(n.inheritType=parseInt(t.InheritType.value)),"RotationOrder"in t?n.eulerOrder=yf(t.RotationOrder.value):n.eulerOrder="ZYX","Lcl_Translation"in t&&(n.translation=t.Lcl_Translation.value),"PreRotation"in t&&(n.preRotation=t.PreRotation.value),"Lcl_Rotation"in t&&(n.rotation=t.Lcl_Rotation.value),"PostRotation"in t&&(n.postRotation=t.PostRotation.value),"Lcl_Scaling"in t&&(n.scale=t.Lcl_Scaling.value),"ScalingOffset"in t&&(n.scalingOffset=t.ScalingOffset.value),"ScalingPivot"in t&&(n.scalingPivot=t.ScalingPivot.value),"RotationOffset"in t&&(n.rotationOffset=t.RotationOffset.value),"RotationPivot"in t&&(n.rotationPivot=t.RotationPivot.value),e.userData.transformData=n}setLookAtProperties(e,t){"LookAtProperty"in t&&w0.get(e.ID).children.forEach(function(r){if(r.relationship==="LookAtProperty"){const s=Be.Objects.Model[r.ID];if("Lcl_Translation"in s){const o=s.Lcl_Translation.value;e.target!==void 0?(e.target.position.fromArray(o),st.add(e.target)):e.lookAt(new P().fromArray(o))}}})}bindSkeleton(e,t,n){const r=this.parsePoseNodes();for(const s in e){const o=e[s];w0.get(parseInt(o.ID)).parents.forEach(function(l){if(t.has(l.ID)){const c=l.ID;w0.get(c).parents.forEach(function(h){n.has(h.ID)&&n.get(h.ID).bind(new Tl(o.bones),r[h.ID])})}})}}parsePoseNodes(){const e={};if("Pose"in Be.Objects){const t=Be.Objects.Pose;for(const n in t)if(t[n].attrType==="BindPose"&&t[n].NbPoseNodes>0){const r=t[n].PoseNode;Array.isArray(r)?r.forEach(function(s){e[s.Node]=new Me().fromArray(s.Matrix.a)}):e[r.Node]=new Me().fromArray(r.Matrix.a)}}return e}createAmbientLight(){if("GlobalSettings"in Be&&"AmbientColor"in Be.GlobalSettings){const e=Be.GlobalSettings.AmbientColor.value,t=e[0],n=e[1],r=e[2];if(t!==0||n!==0||r!==0){const s=new be(t,n,r);st.add(new v9(s,1))}}}}class jS{parse(e){const t=new Map;if("Geometry"in Be.Objects){const n=Be.Objects.Geometry;for(const r in n){const s=w0.get(parseInt(r)),o=this.parseGeometry(s,n[r],e);t.set(parseInt(r),o)}}return t}parseGeometry(e,t,n){switch(t.attrType){case"Mesh":return this.parseMeshGeometry(e,t,n);case"NurbsCurve":return this.parseNurbsGeometry(t)}}parseMeshGeometry(e,t,n){const r=n.skeletons,s=[],o=e.parents.map(function(h){return Be.Objects.Model[h.ID]});if(o.length===0)return;const a=e.children.reduce(function(h,f){return r[f.ID]!==void 0&&(h=r[f.ID]),h},null);e.children.forEach(function(h){n.morphTargets[h.ID]!==void 0&&s.push(n.morphTargets[h.ID])});const l=o[0],c={};"RotationOrder"in l&&(c.eulerOrder=yf(l.RotationOrder.value)),"InheritType"in l&&(c.inheritType=parseInt(l.InheritType.value)),"GeometricTranslation"in l&&(c.translation=l.GeometricTranslation.value),"GeometricRotation"in l&&(c.rotation=l.GeometricRotation.value),"GeometricScaling"in l&&(c.scale=l.GeometricScaling.value);const u=xf(c);return this.genGeometry(t,a,s,u)}genGeometry(e,t,n,r){const s=new Fe;e.attrName&&(s.name=e.attrName);const o=this.parseGeoNode(e,t),a=this.genBuffers(o),l=new Ae(a.vertex,3);if(l.applyMatrix4(r),s.setAttribute("position",l),a.colors.length>0&&s.setAttribute("color",new Ae(a.colors,3)),t&&(s.setAttribute("skinIndex",new Jc(a.weightsIndices,4)),s.setAttribute("skinWeight",new Ae(a.vertexWeights,4)),s.FBX_Deformer=t),a.normal.length>0){const c=new B0().getNormalMatrix(r),u=new Ae(a.normal,3);u.applyNormalMatrix(c),s.setAttribute("normal",u)}if(a.uvs.forEach(function(c,u){let h="uv"+(u+1).toString();u===0&&(h="uv"),s.setAttribute(h,new Ae(a.uvs[u],2))}),o.material&&o.material.mappingType!=="AllSame"){let c=a.materialIndex[0],u=0;if(a.materialIndex.forEach(function(h,f){h!==c&&(s.addGroup(u,f-u,c),c=h,u=f)}),s.groups.length>0){const h=s.groups[s.groups.length-1],f=h.start+h.count;f!==a.materialIndex.length&&s.addGroup(f,a.materialIndex.length-f,c)}s.groups.length===0&&s.addGroup(0,a.materialIndex.length,a.materialIndex[0])}return this.addMorphTargets(s,e,n,r),s}parseGeoNode(e,t){const n={};if(n.vertexPositions=e.Vertices!==void 0?e.Vertices.a:[],n.vertexIndices=e.PolygonVertexIndex!==void 0?e.PolygonVertexIndex.a:[],e.LayerElementColor&&(n.color=this.parseVertexColors(e.LayerElementColor[0])),e.LayerElementMaterial&&(n.material=this.parseMaterialIndices(e.LayerElementMaterial[0])),e.LayerElementNormal&&(n.normal=this.parseNormals(e.LayerElementNormal[0])),e.LayerElementUV){n.uv=[];let r=0;for(;e.LayerElementUV[r];)e.LayerElementUV[r].UV&&n.uv.push(this.parseUVs(e.LayerElementUV[r])),r++}return n.weightTable={},t!==null&&(n.skeleton=t,t.rawBones.forEach(function(r,s){r.indices.forEach(function(o,a){n.weightTable[o]===void 0&&(n.weightTable[o]=[]),n.weightTable[o].push({id:s,weight:r.weights[a]})})})),n}genBuffers(e){const t={vertex:[],normal:[],colors:[],uvs:[],materialIndex:[],vertexWeights:[],weightsIndices:[]};let n=0,r=0,s=!1,o=[],a=[],l=[],c=[],u=[],h=[];const f=this;return e.vertexIndices.forEach(function(d,g){let v,_=!1;d<0&&(d=d^-1,_=!0);let m=[],p=[];if(o.push(d*3,d*3+1,d*3+2),e.color){const y=ba(g,n,d,e.color);l.push(y[0],y[1],y[2])}if(e.skeleton){if(e.weightTable[d]!==void 0&&e.weightTable[d].forEach(function(y){p.push(y.weight),m.push(y.id)}),p.length>4){s||(console.warn("THREE.FBXLoader: Vertex has more than 4 skinning weights assigned to vertex. Deleting additional weights."),s=!0);const y=[0,0,0,0],x=[0,0,0,0];p.forEach(function(w,A){let b=w,L=m[A];x.forEach(function(B,I,C){if(b>B){C[I]=b,b=B;const Y=y[I];y[I]=L,L=Y}})}),m=y,p=x}for(;p.length<4;)p.push(0),m.push(0);for(let y=0;y<4;++y)u.push(p[y]),h.push(m[y])}if(e.normal){const y=ba(g,n,d,e.normal);a.push(y[0],y[1],y[2])}e.material&&e.material.mappingType!=="AllSame"&&(v=ba(g,n,d,e.material)[0]),e.uv&&e.uv.forEach(function(y,x){const w=ba(g,n,d,y);c[x]===void 0&&(c[x]=[]),c[x].push(w[0]),c[x].push(w[1])}),r++,_&&(f.genFace(t,e,o,v,a,l,c,u,h,r),n++,r=0,o=[],a=[],l=[],c=[],u=[],h=[])}),t}genFace(e,t,n,r,s,o,a,l,c,u){for(let h=2;h1&&console.warn("THREE.FBXLoader: Encountered an animation stack with multiple layers, this is currently not supported. Ignoring subsequent layers.");const o=e.get(s[0].ID);n[r]={name:t[r].attrName,layer:o}}return n}addClip(e){let t=[];const n=this;return e.layer.forEach(function(r){t=t.concat(n.generateTracks(r))}),new Qa(e.name,-1,t)}generateTracks(e){const t=[];let n=new P,r=new S0,s=new P;if(e.transform&&e.transform.decompose(n,r,s),n=n.toArray(),r=new It().setFromQuaternion(r,e.eulerOrder).toArray(),s=s.toArray(),e.T!==void 0&&Object.keys(e.T.curves).length>0){const o=this.generateVectorTrack(e.modelName,e.T.curves,n,"position");o!==void 0&&t.push(o)}if(e.R!==void 0&&Object.keys(e.R.curves).length>0){const o=this.generateRotationTrack(e.modelName,e.R.curves,r,e.preRotation,e.postRotation,e.eulerOrder);o!==void 0&&t.push(o)}if(e.S!==void 0&&Object.keys(e.S.curves).length>0){const o=this.generateVectorTrack(e.modelName,e.S.curves,s,"scale");o!==void 0&&t.push(o)}if(e.DeformPercent!==void 0){const o=this.generateMorphTrack(e);o!==void 0&&t.push(o)}return t}generateVectorTrack(e,t,n,r){const s=this.getTimesForAllAxes(t),o=this.getKeyframeTrackValues(s,t,n);return new Br(e+"."+r,s,o)}generateRotationTrack(e,t,n,r,s,o){t.x!==void 0&&(this.interpolateRotations(t.x),t.x.values=t.x.values.map(vt.degToRad)),t.y!==void 0&&(this.interpolateRotations(t.y),t.y.values=t.y.values.map(vt.degToRad)),t.z!==void 0&&(this.interpolateRotations(t.z),t.z.values=t.z.values.map(vt.degToRad));const a=this.getTimesForAllAxes(t),l=this.getKeyframeTrackValues(a,t,n);r!==void 0&&(r=r.map(vt.degToRad),r.push(o),r=new It().fromArray(r),r=new S0().setFromEuler(r)),s!==void 0&&(s=s.map(vt.degToRad),s.push(o),s=new It().fromArray(s),s=new S0().setFromEuler(s).invert());const c=new S0,u=new It,h=[];for(let f=0;f1){let n=1,r=t[0];for(let s=1;s=180){const o=s/180,a=r/o;let l=n+a;const c=e.times[t-1],h=(e.times[t]-c)/o;let f=c+h;const d=[],g=[];for(;f1&&(n=e[1].replace(/^(\w+)::/,""),r=e[2]),{id:t,name:n,type:r}}parseNodeProperty(e,t,n){let r=t[1].replace(/^"/,"").replace(/"$/,"").trim(),s=t[2].replace(/^"/,"").replace(/"$/,"").trim();r==="Content"&&s===","&&(s=n.replace(/"/g,"").replace(/,$/,"").trim());const o=this.getCurrentNode();if(o.name==="Properties70"){this.parseNodeSpecialProperty(e,r,s);return}if(r==="C"){const l=s.split(",").slice(1),c=parseInt(l[0]),u=parseInt(l[1]);let h=s.split(",").slice(3);h=h.map(function(f){return f.trim().replace(/^"/,"")}),r="connections",s=[c,u],eT(s,h),o[r]===void 0&&(o[r]=[])}r==="Node"&&(o.id=s),r in o&&Array.isArray(o[r])?o[r].push(s):r!=="a"?o[r]=s:o.a=s,this.setCurrentProp(o,r),r==="a"&&s.slice(-1)!==","&&(o.a=C1(s))}parseNodePropertyContinued(e){const t=this.getCurrentNode();t.a+=e,e.slice(-1)!==","&&(t.a=C1(t.a))}parseNodeSpecialProperty(e,t,n){const r=n.split('",').map(function(u){return u.trim().replace(/^\"/,"").replace(/\s/,"_")}),s=r[0],o=r[1],a=r[2],l=r[3];let c=r[4];switch(o){case"int":case"enum":case"bool":case"ULongLong":case"double":case"Number":case"FieldOfView":c=parseFloat(c);break;case"Color":case"ColorRGB":case"Vector3D":case"Lcl_Translation":case"Lcl_Rotation":case"Lcl_Scaling":c=C1(c);break}this.getPrevNode()[s]={type:o,type2:a,flag:l,value:c},this.setCurrentProp(this.getPrevNode(),s)}}class QS{parse(e){const t=new D3(e);t.skip(23);const n=t.getUint32();if(n<6400)throw new Error("THREE.FBXLoader: FBX version not supported, FileVersion: "+n);const r=new vf;for(;!this.endOfContent(t);){const s=this.parseNode(t,n);s!==null&&r.add(s.name,s)}return r}endOfContent(e){return e.size()%16===0?(e.getOffset()+160+16&-16)>=e.size():e.getOffset()+160+16>=e.size()}parseNode(e,t){const n={},r=t>=7500?e.getUint64():e.getUint32(),s=t>=7500?e.getUint64():e.getUint32();t>=7500?e.getUint64():e.getUint32();const o=e.getUint8(),a=e.getString(o);if(r===0)return null;const l=[];for(let f=0;f0?l[0]:"",u=l.length>1?l[1]:"",h=l.length>2?l[2]:"";for(n.singleProperty=s===1&&e.getOffset()===r;r>e.getOffset();){const f=this.parseNode(e,t);f!==null&&this.parseSubNode(a,n,f)}return n.propertyList=l,typeof c=="number"&&(n.id=c),u!==""&&(n.attrName=u),h!==""&&(n.attrType=h),a!==""&&(n.name=a),n}parseSubNode(e,t,n){if(n.singleProperty===!0){const r=n.propertyList[0];Array.isArray(r)?(t[n.name]=n,n.a=r):t[n.name]=r}else if(e==="Connections"&&n.name==="C"){const r=[];n.propertyList.forEach(function(s,o){o!==0&&r.push(s)}),t.connections===void 0&&(t.connections=[]),t.connections.push(r)}else if(n.name==="Properties70")Object.keys(n).forEach(function(s){t[s]=n[s]});else if(e==="Properties70"&&n.name==="P"){let r=n.propertyList[0],s=n.propertyList[1];const o=n.propertyList[2],a=n.propertyList[3];let l;r.indexOf("Lcl ")===0&&(r=r.replace("Lcl ","Lcl_")),s.indexOf("Lcl ")===0&&(s=s.replace("Lcl ","Lcl_")),s==="Color"||s==="ColorRGB"||s==="Vector"||s==="Vector3D"||s.indexOf("Lcl_")===0?l=[n.propertyList[4],n.propertyList[5],n.propertyList[6]]:l=n.propertyList[4],t[r]={type:s,type2:o,flag:a,value:l}}else t[n.name]===void 0?typeof n.id=="number"?(t[n.name]={},t[n.name][n.id]=n):t[n.name]=n:n.name==="PoseNode"?(Array.isArray(t[n.name])||(t[n.name]=[t[n.name]]),t[n.name].push(n)):t[n.name][n.id]===void 0&&(t[n.name][n.id]=n)}parseProperty(e){const t=e.getString(1);let n;switch(t){case"C":return e.getBoolean();case"D":return e.getFloat64();case"F":return e.getFloat32();case"I":return e.getInt32();case"L":return e.getInt64();case"R":return n=e.getUint32(),e.getArrayBuffer(n);case"S":return n=e.getUint32(),e.getString(n);case"Y":return e.getInt16();case"b":case"c":case"d":case"f":case"i":case"l":const r=e.getUint32(),s=e.getUint32(),o=e.getUint32();if(s===0)switch(t){case"b":case"c":return e.getBooleanArray(r);case"d":return e.getFloat64Array(r);case"f":return e.getFloat32Array(r);case"i":return e.getInt32Array(r);case"l":return e.getInt64Array(r)}typeof OS>"u"&&console.error("THREE.FBXLoader: External library fflate.min.js required.");const a=bo(new Uint8Array(e.getArrayBuffer(o))),l=new D3(a.buffer);switch(t){case"b":case"c":return l.getBooleanArray(r);case"d":return l.getFloat64Array(r);case"f":return l.getFloat32Array(r);case"i":return l.getInt32Array(r);case"l":return l.getInt64Array(r)}default:throw new Error("THREE.FBXLoader: Unknown property type "+t)}}}class D3{constructor(e,t){this.dv=new DataView(e),this.offset=0,this.littleEndian=t!==void 0?t:!0}getOffset(){return this.offset}size(){return this.dv.buffer.byteLength}skip(e){this.offset+=e}getBoolean(){return(this.getUint8()&1)===1}getBooleanArray(e){const t=[];for(let n=0;n=0&&(t=t.slice(0,n)),Ut.decodeText(new Uint8Array(t))}}class vf{add(e,t){this[e]=t}}function ZS(i){const e="Kaydara FBX Binary \0";return i.byteLength>=e.length&&e===_f(i,0,e.length)}function KS(i){const e=["K","a","y","d","a","r","a","\\","F","B","X","\\","B","i","n","a","r","y","\\","\\"];let t=0;function n(r){const s=i[r-1];return i=i.slice(t+r),t++,s}for(let r=0;r>>1|(d0&21845)<<1;Dn=(Dn&52428)>>>2|(Dn&13107)<<2,Dn=(Dn&61680)>>>4|(Dn&3855)<<4,_o[d0]=((Dn&65280)>>>8|(Dn&255)<<8)>>>1}var _t=function(i,e,t){for(var n=i.length,r=0,s=new G0(e);r>>l]=c}else for(a=new G0(n),r=0;r>>15-i[r]);return a},xn=new He(288);for(var d0=0;d0<144;++d0)xn[d0]=8;for(var d0=144;d0<256;++d0)xn[d0]=9;for(var d0=256;d0<280;++d0)xn[d0]=7;for(var d0=280;d0<288;++d0)xn[d0]=8;var Wr=new He(32);for(var d0=0;d0<32;++d0)Wr[d0]=5;var G5=_t(xn,9,0),H5=_t(xn,9,1),V5=_t(Wr,5,0),W5=_t(Wr,5,1),Fa=function(i){for(var e=i[0],t=1;te&&(e=i[t]);return e},mt=function(i,e,t){var n=e/8|0;return(i[n]|i[n+1]<<8)>>(e&7)&t},Ia=function(i,e){var t=e/8|0;return(i[t]|i[t+1]<<8|i[t+2]<<16)>>(e&7)},Co=function(i){return(i/8|0)+(i&7&&1)},bt=function(i,e,t){(e==null||e<0)&&(e=0),(t==null||t>i.length)&&(t=i.length);var n=new(i instanceof G0?G0:i instanceof vn?vn:He)(t-e);return n.set(i.subarray(e,t)),n},Ro=function(i,e,t){var n=i.length;if(!n||t&&!t.l&&n<5)return e||new He(0);var r=!e||t,s=!t||t.i;t||(t={}),e||(e=new He(n*3));var o=function(Z){var V=e.length;if(Z>V){var te=new He(Math.max(V*2,Z));te.set(e),e=te}},a=t.f||0,l=t.p||0,c=t.b||0,u=t.l,h=t.d,f=t.m,d=t.n,g=n*8;do{if(!u){t.f=a=mt(i,l,1);var v=mt(i,l+1,3);if(l+=3,v)if(v==1)u=H5,h=W5,f=9,d=5;else if(v==2){var y=mt(i,l,31)+257,x=mt(i,l+10,15)+4,w=y+mt(i,l+5,31)+1;l+=14;for(var A=new He(w),b=new He(19),L=0;L>>4;if(_<16)A[L++]=_;else{var O=0,G=0;for(_==16?(G=3+mt(i,l,3),l+=2,O=A[L-1]):_==17?(G=3+mt(i,l,7),l+=3):_==18&&(G=11+mt(i,l,127),l+=7);G--;)A[L++]=O}}var j=A.subarray(0,y),N=A.subarray(y);f=Fa(j),d=Fa(N),u=_t(j,f,1),h=_t(N,d,1)}else throw"invalid block type";else{var _=Co(l)+4,m=i[_-4]|i[_-3]<<8,p=_+m;if(p>n){if(s)throw"unexpected EOF";break}r&&o(c+m),e.set(i.subarray(_,p),c),t.b=c+=m,t.p=l=p*8;continue}if(l>g){if(s)throw"unexpected EOF";break}}r&&o(c+131072);for(var k=(1<>>4;if(l+=O&15,l>g){if(s)throw"unexpected EOF";break}if(!O)throw"invalid length/literal";if(ve<256)e[c++]=ve;else if(ve==256){le=l,u=null;break}else{var ce=ve-254;if(ve>264){var L=ve-257,ye=os[L];ce=mt(i,l,(1<>>4;if(!$)throw"invalid distance";l+=$&15;var N=k5[se];if(se>3){var ye=as[se];N+=Ia(i,l)&(1<g){if(s)throw"unexpected EOF";break}r&&o(c+131072);for(var me=c+ce;c>>8},fr=function(i,e,t){t<<=e&7;var n=e/8|0;i[n]|=t,i[n+1]|=t>>>8,i[n+2]|=t>>>16},Da=function(i,e){for(var t=[],n=0;nf&&(f=s[n].s);var d=new G0(f+1),g=Za(t[u-1],d,0);if(g>e){var n=0,v=0,_=g-e,m=1<<_;for(s.sort(function(A,b){return d[b.s]-d[A.s]||A.f-b.f});ne)v+=m-(1<>>=_;v>0;){var y=s[n].s;d[y]=0&&v;--n){var x=s[n].s;d[x]==e&&(--d[x],++v)}g=e}return[new He(d),g]},Za=function(i,e,t){return i.s==-1?Math.max(Za(i.l,e,t+1),Za(i.r,e,t+1)):e[i.s]=t},pc=function(i){for(var e=i.length;e&&!i[--e];);for(var t=new G0(++e),n=0,r=i[0],s=1,o=function(l){t[n++]=l},a=1;a<=e;++a)if(i[a]==r&&a!=e)++s;else{if(!r&&s>2){for(;s>138;s-=138)o(32754);s>2&&(o(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(o(r),--s;s>6;s-=6)o(8304);s>2&&(o(s-3<<5|8208),s=0)}for(;s--;)o(r);s=1,r=i[a]}return[t.subarray(0,n),e]},dr=function(i,e){for(var t=0,n=0;n>>8,i[r+2]=i[r]^255,i[r+3]=i[r+1]^255;for(var s=0;s4&&!I[yo[Y-1]];--Y);var O=c+5<<3,G=dr(r,xn)+dr(s,Wr)+o,j=dr(r,f)+dr(s,v)+o+14+3*Y+dr(b,I)+(2*b[16]+3*b[17]+7*b[18]);if(O<=G&&O<=j)return Zs(e,u,i.subarray(l,l+c));var N,k,K,le;if(Ht(e,u,1+(j15&&(Ht(e,u,$[L]>>>5&127),u+=$[L]>>>12)}}else N=G5,k=xn,K=V5,le=Wr;for(var L=0;L255){var se=n[L]>>>18&31;fr(e,u,N[se+257]),u+=k[se+257],se>7&&(Ht(e,u,n[L]>>>23&31),u+=os[se]);var me=n[L]&31;fr(e,u,K[me]),u+=le[me],me>3&&(fr(e,u,n[L]>>>5&8191),u+=as[me])}else fr(e,u,N[n[L]]),u+=k[n[L]];return fr(e,u,N[256]),u+k[256]},X5=new vn([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),fn=new He(0),j5=function(i,e,t,n,r,s){var o=i.length,a=new He(n+o+5*(1+Math.ceil(o/7e3))+r),l=a.subarray(n,a.length-r),c=0;if(!e||o<8)for(var u=0;u<=o;u+=65535){var h=u+65535;h>>13,g=f&8191,v=(1<7e3||I>24576)&&N>423){c=mc(i,l,0,w,A,b,B,I,Y,u-Y,c),I=L=B=0,Y=u;for(var k=0;k<286;++k)A[k]=0;for(var k=0;k<30;++k)b[k]=0}var K=2,le=0,ve=g,ce=G-j&32767;if(N>2&&O==x(u-ce))for(var ye=Math.min(d,N)-1,$=Math.min(32767,u),se=Math.min(258,N);ce<=$&&--ve&&G!=j;){if(i[u+K]==i[u+K-ce]){for(var me=0;meK){if(K=me,le=ce,me>ye)break;for(var Z=Math.min(ce,me-2),V=0,k=0;kV&&(V=re,j=te)}}}G=j,j=_[G],ce+=G-j+32768&32767}if(le){w[I++]=268435456|Ka[K]<<18|dc[le];var we=Ka[K]&31,M=dc[le]&31;B+=os[we]+as[M],++A[257+we],++b[M],C=u+K,++L}else w[I++]=i[u],++A[i[u]]}}c=mc(i,l,s,w,A,b,B,I,Y,u-Y,c),!s&&c&7&&(c=Zs(l,c+1,fn))}return bt(a,0,n+Co(c)+r)},Y5=function(){for(var i=new vn(256),e=0;e<256;++e){for(var t=e,n=9;--n;)t=(t&1&&3988292384)^t>>>1;i[e]=t}return i}(),ls=function(){var i=-1;return{p:function(e){for(var t=i,n=0;n>>8;i=t},d:function(){return~i}}},w9=function(){var i=1,e=0;return{p:function(t){for(var n=i,r=e,s=t.length,o=0;o!=s;){for(var a=Math.min(o+2655,s);o>16),r=(r&65535)+15*(r>>16)}i=n,e=r},d:function(){return i%=65521,e%=65521,(i&255)<<24|i>>>8<<16|(e&255)<<8|e>>>8}}},ki=function(i,e,t,n,r){return j5(i,e.level==null?6:e.level,e.mem==null?Math.ceil(Math.max(8,Math.min(13,Math.log(i.length)))*1.5):12+e.mem,t,n,!r)},Fo=function(i,e){var t={};for(var n in i)t[n]=i[n];for(var n in e)t[n]=e[n];return t},P3=function(i,e,t){for(var n=i(),r=i.toString(),s=r.slice(r.indexOf("[")+1,r.lastIndexOf("]")).replace(/ /g,"").split(","),o=0;o>>0},P1=function(i,e){return M0(i,e)+M0(i,e+4)*4294967296},e0=function(i,e,t){for(;t;++e)i[e]=t,t>>>=8},S9=function(i,e){var t=e.filename;if(i[0]=31,i[1]=139,i[2]=8,i[8]=e.level<2?4:e.level==9?2:0,i[9]=3,e.mtime!=0&&e0(i,4,Math.floor(new Date(e.mtime||Date.now())/1e3)),t){i[3]=8;for(var n=0;n<=t.length;++n)i[n+10]=t.charCodeAt(n)}},T9=function(i){if(i[0]!=31||i[1]!=139||i[2]!=8)throw"invalid gzip data";var e=i[3],t=10;e&4&&(t+=i[10]|(i[11]<<8)+2);for(var n=(e>>3&1)+(e>>4&1);n>0;n-=!i[t++]);return t+(e&2)},$5=function(i){var e=i.length;return(i[e-4]|i[e-3]<<8|i[e-2]<<16|i[e-1]<<24)>>>0},A9=function(i){return 10+(i.filename&&i.filename.length+1||0)},E9=function(i,e){var t=e.level,n=t==0?0:t<6?1:t==9?3:2;i[0]=120,i[1]=n<<6|(n?32-2*n:1)},ef=function(i){if((i[0]&15)!=8||i[0]>>>4>7||(i[0]<<8|i[1])%31)throw"invalid zlib data";if(i[1]&32)throw"invalid zlib data: preset dictionaries not supported"};function L9(i,e){return!e&&typeof i=="function"&&(e=i,i={}),this.ondata=e,i}var Zt=function(){function i(e,t){!t&&typeof e=="function"&&(t=e,e={}),this.ondata=t,this.o=e||{}}return i.prototype.p=function(e,t){this.ondata(ki(e,this.o,0,0,!t),t)},i.prototype.push=function(e,t){if(this.d)throw"stream finished";if(!this.ondata)throw"no stream handler";this.d=t,this.p(e,t||!1)},i}(),tf=function(){function i(e,t){fs([us,function(){return[wt,Zt]}],this,L9.call(this,e,t),function(n){var r=new Zt(n.data);onmessage=wt(r)},6)}return i}();function nf(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return hs(i,e,[us],function(n){return oi(Io(n.data[0],n.data[1]))},0,t)}function Io(i,e){return ki(i,e||{},0,0)}var lt=function(){function i(e){this.s={},this.p=new He(0),this.ondata=e}return i.prototype.e=function(e){if(this.d)throw"stream finished";if(!this.ondata)throw"no stream handler";var t=this.p.length,n=new He(t+e.length);n.set(this.p),n.set(e,t),this.p=n},i.prototype.c=function(e){this.d=this.s.i=e||!1;var t=this.s.b,n=Ro(this.p,this.o,this.s);this.ondata(bt(n,t,this.s.b),this.d),this.o=bt(n,this.s.b-32768),this.s.b=this.o.length,this.p=bt(this.p,this.s.p/8|0),this.s.p&=7},i.prototype.push=function(e,t){this.e(e),this.c(t)},i}(),P9=function(){function i(e){this.ondata=e,fs([cs,function(){return[wt,lt]}],this,0,function(){var t=new lt;onmessage=wt(t)},7)}return i}();function C9(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return hs(i,e,[cs],function(n){return oi(ds(n.data[0],M9(n.data[1])))},1,t)}function ds(i,e){return Ro(i,e)}var Ja=function(){function i(e,t){this.c=ls(),this.l=0,this.v=1,Zt.call(this,e,t)}return i.prototype.push=function(e,t){Zt.prototype.push.call(this,e,t)},i.prototype.p=function(e,t){this.c.p(e),this.l+=e.length;var n=ki(e,this.o,this.v&&A9(this.o),t&&8,!t);this.v&&(S9(n,this.o),this.v=0),t&&(e0(n,n.length-8,this.c.d()),e0(n,n.length-4,this.l)),this.ondata(n,t)},i}(),C3=function(){function i(e,t){fs([us,Q5,function(){return[wt,Zt,Ja]}],this,L9.call(this,e,t),function(n){var r=new Ja(n.data);onmessage=wt(r)},8)}return i}();function R3(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return hs(i,e,[us,Q5,function(){return[$a]}],function(n){return oi($a(n.data[0],n.data[1]))},2,t)}function $a(i,e){e||(e={});var t=ls(),n=i.length;t.p(i);var r=ki(i,e,A9(e),8),s=r.length;return S9(r,e),e0(r,s-8,t.d()),e0(r,s-4,n),r}var el=function(){function i(e){this.v=1,lt.call(this,e)}return i.prototype.push=function(e,t){if(lt.prototype.e.call(this,e),this.v){var n=this.p.length>3?T9(this.p):4;if(n>=this.p.length&&!t)return;this.p=this.p.subarray(n),this.v=0}if(t){if(this.p.length<8)throw"invalid gzip stream";this.p=this.p.subarray(0,-8)}lt.prototype.c.call(this,t)},i}(),rf=function(){function i(e){this.ondata=e,fs([cs,K5,function(){return[wt,lt,el]}],this,0,function(){var t=new el;onmessage=wt(t)},9)}return i}();function sf(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return hs(i,e,[cs,K5,function(){return[tl]}],function(n){return oi(tl(n.data[0]))},3,t)}function tl(i,e){return Ro(i.subarray(T9(i),-8),e||new He($5(i)))}var gc=function(){function i(e,t){this.c=w9(),this.v=1,Zt.call(this,e,t)}return i.prototype.push=function(e,t){Zt.prototype.push.call(this,e,t)},i.prototype.p=function(e,t){this.c.p(e);var n=ki(e,this.o,this.v&&2,t&&4,!t);this.v&&(E9(n,this.o),this.v=0),t&&e0(n,n.length-4,this.c.d()),this.ondata(n,t)},i}(),yS=function(){function i(e,t){fs([us,Z5,function(){return[wt,Zt,gc]}],this,L9.call(this,e,t),function(n){var r=new gc(n.data);onmessage=wt(r)},10)}return i}();function _S(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return hs(i,e,[us,Z5,function(){return[vc]}],function(n){return oi(vc(n.data[0],n.data[1]))},4,t)}function vc(i,e){e||(e={});var t=w9();t.p(i);var n=ki(i,e,2,4);return E9(n,e),e0(n,n.length-4,t.d()),n}var nl=function(){function i(e){this.v=1,lt.call(this,e)}return i.prototype.push=function(e,t){if(lt.prototype.e.call(this,e),this.v){if(this.p.length<2&&!t)return;this.p=this.p.subarray(2),this.v=0}if(t){if(this.p.length<4)throw"invalid zlib stream";this.p=this.p.subarray(0,-4)}lt.prototype.c.call(this,t)},i}(),of=function(){function i(e){this.ondata=e,fs([cs,J5,function(){return[wt,lt,nl]}],this,0,function(){var t=new nl;onmessage=wt(t)},11)}return i}();function af(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return hs(i,e,[cs,J5,function(){return[bo]}],function(n){return oi(bo(n.data[0],M9(n.data[1])))},5,t)}function bo(i,e){return Ro((ef(i),i.subarray(2,-4)),e)}var lf=function(){function i(e){this.G=el,this.I=lt,this.Z=nl,this.ondata=e}return i.prototype.push=function(e,t){if(!this.ondata)throw"no stream handler";if(this.s)this.s.push(e,t);else{if(this.p&&this.p.length){var n=new He(this.p.length+e.length);n.set(this.p),n.set(e,this.p.length)}else this.p=e;if(this.p.length>2){var r=this,s=function(){r.ondata.apply(r,arguments)};this.s=this.p[0]==31&&this.p[1]==139&&this.p[2]==8?new this.G(s):(this.p[0]&15)!=8||this.p[0]>>4>7||(this.p[0]<<8|this.p[1])%31?new this.I(s):new this.Z(s),this.s.push(this.p,t),this.p=null}}},i}(),bS=function(){function i(e){this.G=rf,this.I=P9,this.Z=of,this.ondata=e}return i.prototype.push=function(e,t){lf.prototype.push.call(this,e,t)},i}();function wS(i,e,t){if(t||(t=e,e={}),typeof t!="function")throw"no callback";return i[0]==31&&i[1]==139&&i[2]==8?sf(i,e,t):(i[0]&15)!=8||i[0]>>4>7||(i[0]<<8|i[1])%31?C9(i,e,t):af(i,e,t)}function MS(i,e){return i[0]==31&&i[1]==139&&i[2]==8?tl(i,e):(i[0]&15)!=8||i[0]>>4>7||(i[0]<<8|i[1])%31?ds(i,e):bo(i,e)}var R9=function(i,e,t,n){for(var r in i){var s=i[r],o=e+r;s instanceof He?t[o]=[s,n]:Array.isArray(s)?t[o]=[s[0],Fo(n,s[1])]:R9(s,o+"/",t,n)}},F3=typeof TextEncoder<"u"&&new TextEncoder,xc=typeof TextDecoder<"u"&&new TextDecoder,cf=0;try{xc.decode(fn,{stream:!0}),cf=1}catch{}var uf=function(i){for(var e="",t=0;;){var n=i[t++],r=(n>127)+(n>223)+(n>239);if(t+r>i.length)return[e,bt(i,t-1)];r?r==3?(n=((n&15)<<18|(i[t++]&63)<<12|(i[t++]&63)<<6|i[t++]&63)-65536,e+=String.fromCharCode(55296|n>>10,56320|n&1023)):r&1?e+=String.fromCharCode((n&31)<<6|i[t++]&63):e+=String.fromCharCode((n&15)<<12|(i[t++]&63)<<6|i[t++]&63):e+=String.fromCharCode(n)}},SS=function(){function i(e){this.ondata=e,cf?this.t=new TextDecoder:this.p=fn}return i.prototype.push=function(e,t){if(!this.ondata)throw"no callback";if(t=!!t,this.t){if(this.ondata(this.t.decode(e,{stream:!0}),t),t){if(this.t.decode().length)throw"invalid utf-8 data";this.t=null}return}if(!this.p)throw"stream finished";var n=new He(this.p.length+e.length);n.set(this.p),n.set(e,this.p.length);var r=uf(n),s=r[0],o=r[1];if(t){if(o.length)throw"invalid utf-8 data";this.p=null}else this.p=o;this.ondata(s,t)},i}(),TS=function(){function i(e){this.ondata=e}return i.prototype.push=function(e,t){if(!this.ondata)throw"no callback";if(this.d)throw"stream finished";this.ondata(ti(e),this.d=t||!1)},i}();function ti(i,e){if(e){for(var t=new He(i.length),n=0;n>1)),o=0,a=function(u){s[o++]=u},n=0;ns.length){var l=new He(o+8+(r-n<<1));l.set(s),s=l}var c=i.charCodeAt(n);c<128||e?a(c):c<2048?(a(192|c>>6),a(128|c&63)):c>55295&&c<57344?(c=65536+(c&1047552)|i.charCodeAt(++n)&1023,a(240|c>>18),a(128|c>>12&63),a(128|c>>6&63),a(128|c&63)):(a(224|c>>12),a(128|c>>6&63),a(128|c&63))}return bt(s,0,o)}function F9(i,e){if(e){for(var t="",n=0;n65535)throw"extra field too long";e+=n+4}return e},Xr=function(i,e,t,n,r,s,o,a){var l=n.length,c=t.extra,u=a&&a.length,h=Yn(c);e0(i,e,o!=null?33639248:67324752),e+=4,o!=null&&(i[e++]=20,i[e++]=t.os),i[e]=20,e+=2,i[e++]=t.flag<<1|(s==null&&8),i[e++]=r&&8,i[e++]=t.compression&255,i[e++]=t.compression>>8;var f=new Date(t.mtime==null?Date.now():t.mtime),d=f.getFullYear()-1980;if(d<0||d>119)throw"date not in range 1980-2099";if(e0(i,e,d<<25|f.getMonth()+1<<21|f.getDate()<<16|f.getHours()<<11|f.getMinutes()<<5|f.getSeconds()>>>1),e+=4,s!=null&&(e0(i,e,t.crc),e0(i,e+4,s),e0(i,e+8,t.size)),e0(i,e+12,l),e0(i,e+14,h),e+=16,o!=null&&(e0(i,e,u),e0(i,e+6,t.attrs),e0(i,e+10,o),e+=14),i.set(n,e),e+=l,h)for(var g in c){var v=c[g],_=v.length;e0(i,e,+g),e0(i,e+2,_),i.set(v,e+4),e+=4+_}return u&&(i.set(a,e),e+=u),e},I9=function(i,e,t,n,r){e0(i,e,101010256),e0(i,e+8,t),e0(i,e+10,t),e0(i,e+12,n),e0(i,e+16,r)},wo=function(){function i(e){this.filename=e,this.c=ls(),this.size=0,this.compression=0}return i.prototype.process=function(e,t){this.ondata(null,e,t)},i.prototype.push=function(e,t){if(!this.ondata)throw"no callback - add to ZIP archive before pushing";this.c.p(e),this.size+=e.length,t&&(this.crc=this.c.d()),this.process(e,t||!1)},i}(),AS=function(){function i(e,t){var n=this;t||(t={}),wo.call(this,e),this.d=new Zt(t,function(r,s){n.ondata(null,r,s)}),this.compression=8,this.flag=hf(t.level)}return i.prototype.process=function(e,t){try{this.d.push(e,t)}catch(n){this.ondata(n,null,t)}},i.prototype.push=function(e,t){wo.prototype.push.call(this,e,t)},i}(),ES=function(){function i(e,t){var n=this;t||(t={}),wo.call(this,e),this.d=new tf(t,function(r,s,o){n.ondata(r,s,o)}),this.compression=8,this.flag=hf(t.level),this.terminate=this.d.terminate}return i.prototype.process=function(e,t){this.d.push(e,t)},i.prototype.push=function(e,t){wo.prototype.push.call(this,e,t)},i}(),LS=function(){function i(e){this.ondata=e,this.u=[],this.d=1}return i.prototype.add=function(e){var t=this;if(this.d&2)throw"stream finished";var n=ti(e.filename),r=n.length,s=e.comment,o=s&&ti(s),a=r!=e.filename.length||o&&s.length!=o.length,l=r+Yn(e.extra)+30;if(r>65535)throw"filename too long";var c=new He(l);Xr(c,0,e,n,a);var u=[c],h=function(){for(var _=0,m=u;_65535&&O("filename too long",null),!Y)O(null,p);else if(w<16e4)try{O(null,Io(p,y))}catch(G){O(G,null)}else u.push(nf(p,y,O))},g=0;g65535)throw"filename too long";var m=u?Io(l,c):l,p=m.length,y=ls();y.p(l),n.push(Fo(c,{size:l.length,crc:y.d(),c:m,f:h,m:g,u:f!=o.length||g&&d.length!=v,o:r,compression:u})),r+=30+f+_+p,s+=76+2*(f+_)+(v||0)+p}for(var x=new He(s+22),w=r,A=s-r,b=0;b0){var r=Math.min(this.c,e.length),s=e.subarray(0,r);if(this.c-=r,this.d?this.d.push(s,!this.c):this.k[0].push(s),e=e.subarray(r),e.length)return this.push(e,t)}else{var o=0,a=0,l=void 0,c=void 0;this.p.length?e.length?(c=new He(this.p.length+e.length),c.set(this.p),c.set(e,this.p.length)):c=this.p:c=e;for(var u=c.length,h=this.c,f=h&&this.d,d=function(){var m,p=M0(c,a);if(p==67324752){o=1,l=a,g.d=null,g.c=0;var y=tt(c,a+6),x=tt(c,a+8),w=y&2048,A=y&8,b=tt(c,a+26),L=tt(c,a+28);if(u>a+30+b+L){var B=[];g.k.unshift(B),o=2;var I=M0(c,a+18),C=M0(c,a+22),Y=F9(c.subarray(a+30,a+=30+b),!w);I==4294967295?(m=A?[-2]:pf(c,a),I=m[0],C=m[1]):A&&(I=-1),a+=L,g.c=I;var O,G={name:Y,compression:x,start:function(){if(!G.ondata)throw"no callback";if(!I)G.ondata(null,fn,!0);else{var j=n.o[x];if(!j)throw"unknown compression type "+x;O=I<0?new j(Y):new j(Y,I,C),O.ondata=function(le,ve,ce){G.ondata(le,ve,ce)};for(var N=0,k=B;N=0&&(G.size=I,G.originalSize=C),g.onfile(G)}return"break"}else if(h){if(p==134695760)return l=a+=12+(h==-2&&8),o=3,g.c=0,"break";if(p==33639248)return l=a-=4,o=3,g.c=0,"break"}},g=this;a65558){e("invalid zip file",null);return}var o=tt(i,s+8);o||e(null,{});var a=o,l=M0(i,s+16),c=l==4294967295;if(c){if(s=M0(i,s-12),M0(i,s)!=101075792){e("invalid zip file",null);return}a=o=M0(i,s+32),l=M0(i,s+48)}for(var u=function(f){var d=df(i,l,c),g=d[0],v=d[1],_=d[2],m=d[3],p=d[4],y=d[5],x=ff(i,y);l=p;var w=function(b,L){b?(n(),e(b,null)):(r[m]=L,--o||e(null,r))};if(!g)w(null,bt(i,x,x+v));else if(g==8){var A=i.subarray(x,x+v);if(v<32e4)try{w(null,ds(A,new He(_)))}catch(b){w(b,null)}else t.push(C9(A,{size:_},w))}else w("unknown compression type "+g,null)},h=0;h65558)throw"invalid zip file";var n=tt(i,t+8);if(!n)return{};var r=M0(i,t+16),s=r==4294967295;if(s){if(t=M0(i,t-12),M0(i,t)!=101075792)throw"invalid zip file";n=M0(i,t+32),r=M0(i,t+48)}for(var o=0;o=t[n])return n-1;if(e<=t[i])return i;let r=i,s=n,o=Math.floor((r+s)/2);for(;e=t[o+1];)e=v&&(g[d][0]=g[f][0]/a[p+1][m],_=g[d][0]*a[m][p]);const y=m>=-1?1:-m,x=h-1<=p?v-1:t-h;for(let A=y;A<=x;++A)g[d][A]=(g[f][A]-g[f][A-1])/a[p+1][m+A],_+=g[d][A]*a[m+A][p];h<=p&&(g[d][v]=-g[f][v-1]/a[p+1][h],_+=g[d][v]*a[h][p]),o[v][h]=_;const w=f;f=d,d=w}}let u=t;for(let h=1;h<=n;++h){for(let f=0;f<=t;++f)o[h][f]*=u;u*=t-h}return o}function kS(i,e,t,n,r){const s=r0,l=typeof s.Content=="string"&&s.Content!=="";if(a||l){const c=this.parseImage(n[r]);t[s.RelativeFilename||s.Filename]=c}}}}for(const n in e){const r=e[n];t[r]!==void 0?e[n]=t[r]:e[n]=e[n].split("\\").pop()}return e}parseImage(e){const t=e.Content,n=e.RelativeFilename||e.Filename,r=n.slice(n.lastIndexOf(".")+1).toLowerCase();let s;switch(r){case"bmp":s="image/bmp";break;case"jpg":case"jpeg":s="image/jpeg";break;case"png":s="image/png";break;case"tif":s="image/tiff";break;case"tga":this.manager.getHandler(".tga")===null&&console.warn("FBXLoader: TGA loader not found, skipping ",n),s="image/tga";break;default:console.warn('FBXLoader: Image type "'+r+'" is not supported.');return}if(typeof t=="string")return"data:"+s+";base64,"+t;{const o=new Uint8Array(t);return window.URL.createObjectURL(new Blob([o],{type:s}))}}parseTextures(e){const t=new Map;if("Texture"in Be.Objects){const n=Be.Objects.Texture;for(const r in n){const s=this.parseTexture(n[r],e);t.set(parseInt(r),s)}}return t}parseTexture(e,t){const n=this.loadTexture(e,t);n.ID=e.id,n.name=e.attrName;const r=e.WrapModeU,s=e.WrapModeV,o=r!==void 0?r.value:0,a=s!==void 0?s.value:0;if(n.wrapS=o===0?Qt:m0,n.wrapT=a===0?Qt:m0,"Scaling"in e){const l=e.Scaling.value;n.repeat.x=l[0],n.repeat.y=l[1]}return n}loadTexture(e,t){let n;const r=this.textureLoader.path,s=w0.get(e.id).children;s!==void 0&&s.length>0&&t[s[0].ID]!==void 0&&(n=t[s[0].ID],(n.indexOf("blob:")===0||n.indexOf("data:")===0)&&this.textureLoader.setPath(void 0));let o;const a=e.FileName.slice(-3).toLowerCase();if(a==="tga"){const l=this.manager.getHandler(".tga");l===null?(console.warn("FBXLoader: TGA loader not found, creating placeholder texture for",e.RelativeFilename),o=new A0):(l.setPath(this.textureLoader.path),o=l.load(n))}else a==="psd"?(console.warn("FBXLoader: PSD textures are not supported, creating placeholder texture for",e.RelativeFilename),o=new A0):o=this.textureLoader.load(n);return this.textureLoader.setPath(r),o}parseMaterials(e){const t=new Map;if("Material"in Be.Objects){const n=Be.Objects.Material;for(const r in n){const s=this.parseMaterial(n[r],e);s!==null&&t.set(parseInt(r),s)}}return t}parseMaterial(e,t){const n=e.id,r=e.attrName;let s=e.ShadingModel;if(typeof s=="object"&&(s=s.value),!w0.has(n))return null;const o=this.parseParameters(e,t,n);let a;switch(s.toLowerCase()){case"phong":a=new Ks;break;case"lambert":a=new m9;break;default:console.warn('THREE.FBXLoader: unknown material type "%s". Defaulting to MeshPhongMaterial.',s),a=new Ks;break}return a.setValues(o),a.name=r,a}parseParameters(e,t,n){const r={};e.BumpFactor&&(r.bumpScale=e.BumpFactor.value),e.Diffuse?r.color=new be().fromArray(e.Diffuse.value):e.DiffuseColor&&(e.DiffuseColor.type==="Color"||e.DiffuseColor.type==="ColorRGB")&&(r.color=new be().fromArray(e.DiffuseColor.value)),e.DisplacementFactor&&(r.displacementScale=e.DisplacementFactor.value),e.Emissive?r.emissive=new be().fromArray(e.Emissive.value):e.EmissiveColor&&(e.EmissiveColor.type==="Color"||e.EmissiveColor.type==="ColorRGB")&&(r.emissive=new be().fromArray(e.EmissiveColor.value)),e.EmissiveFactor&&(r.emissiveIntensity=parseFloat(e.EmissiveFactor.value)),e.Opacity&&(r.opacity=parseFloat(e.Opacity.value)),r.opacity<1&&(r.transparent=!0),e.ReflectionFactor&&(r.reflectivity=e.ReflectionFactor.value),e.Shininess&&(r.shininess=e.Shininess.value),e.Specular?r.specular=new be().fromArray(e.Specular.value):e.SpecularColor&&e.SpecularColor.type==="Color"&&(r.specular=new be().fromArray(e.SpecularColor.value));const s=this;return w0.get(n).children.forEach(function(o){const a=o.relationship;switch(a){case"Bump":r.bumpMap=s.getTexture(t,o.ID);break;case"Maya|TEX_ao_map":r.aoMap=s.getTexture(t,o.ID);break;case"DiffuseColor":case"Maya|TEX_color_map":r.map=s.getTexture(t,o.ID),r.map!==void 0&&(r.map.encoding=at);break;case"DisplacementColor":r.displacementMap=s.getTexture(t,o.ID);break;case"EmissiveColor":r.emissiveMap=s.getTexture(t,o.ID),r.emissiveMap!==void 0&&(r.emissiveMap.encoding=at);break;case"NormalMap":case"Maya|TEX_normal_map":r.normalMap=s.getTexture(t,o.ID);break;case"ReflectionColor":r.envMap=s.getTexture(t,o.ID),r.envMap!==void 0&&(r.envMap.mapping=Va,r.envMap.encoding=at);break;case"SpecularColor":r.specularMap=s.getTexture(t,o.ID),r.specularMap!==void 0&&(r.specularMap.encoding=at);break;case"TransparentColor":case"TransparencyFactor":r.alphaMap=s.getTexture(t,o.ID),r.transparent=!0;break;case"AmbientColor":case"ShininessExponent":case"SpecularFactor":case"VectorDisplacementColor":default:console.warn("THREE.FBXLoader: %s map is not supported in three.js, skipping texture.",a);break}}),r}getTexture(e,t){return"LayeredTexture"in Be.Objects&&t in Be.Objects.LayeredTexture&&(console.warn("THREE.FBXLoader: layered textures are not supported in three.js. Discarding all but first layer."),t=w0.get(t).children[0].ID),e.get(t)}parseDeformers(){const e={},t={};if("Deformer"in Be.Objects){const n=Be.Objects.Deformer;for(const r in n){const s=n[r],o=w0.get(parseInt(r));if(s.attrType==="Skin"){const a=this.parseSkeleton(o,n);a.ID=r,o.parents.length>1&&console.warn("THREE.FBXLoader: skeleton attached to more than one geometry is not supported."),a.geometryID=o.parents[0].ID,e[r]=a}else if(s.attrType==="BlendShape"){const a={id:r};a.rawTargets=this.parseMorphTargets(o,n),a.id=r,o.parents.length>1&&console.warn("THREE.FBXLoader: morph target attached to more than one geometry is not supported."),t[r]=a}}}return{skeletons:e,morphTargets:t}}parseSkeleton(e,t){const n=[];return e.children.forEach(function(r){const s=t[r.ID];if(s.attrType!=="Cluster")return;const o={ID:r.ID,indices:[],weights:[],transformLink:new Me().fromArray(s.TransformLink.a)};"Indexes"in s&&(o.indices=s.Indexes.a,o.weights=s.Weights.a),n.push(o)}),{rawBones:n,bones:[]}}parseMorphTargets(e,t){const n=[];for(let r=0;r1?o=a:a.length>0?o=a[0]:(o=new Ks({color:13421772}),a.push(o)),"color"in s.attributes&&a.forEach(function(l){l.vertexColors=!0}),s.FBX_Deformer?(r=new Tl(s,o),r.normalizeSkinWeights()):r=new I0(s,o),r}createCurve(e,t){const n=e.children.reduce(function(s,o){return t.has(o.ID)&&(s=t.get(o.ID)),s},null),r=new ri({color:3342591,linewidth:1});return new ts(n,r)}getTransformData(e,t){const n={};"InheritType"in t&&(n.inheritType=parseInt(t.InheritType.value)),"RotationOrder"in t?n.eulerOrder=yf(t.RotationOrder.value):n.eulerOrder="ZYX","Lcl_Translation"in t&&(n.translation=t.Lcl_Translation.value),"PreRotation"in t&&(n.preRotation=t.PreRotation.value),"Lcl_Rotation"in t&&(n.rotation=t.Lcl_Rotation.value),"PostRotation"in t&&(n.postRotation=t.PostRotation.value),"Lcl_Scaling"in t&&(n.scale=t.Lcl_Scaling.value),"ScalingOffset"in t&&(n.scalingOffset=t.ScalingOffset.value),"ScalingPivot"in t&&(n.scalingPivot=t.ScalingPivot.value),"RotationOffset"in t&&(n.rotationOffset=t.RotationOffset.value),"RotationPivot"in t&&(n.rotationPivot=t.RotationPivot.value),e.userData.transformData=n}setLookAtProperties(e,t){"LookAtProperty"in t&&w0.get(e.ID).children.forEach(function(r){if(r.relationship==="LookAtProperty"){const s=Be.Objects.Model[r.ID];if("Lcl_Translation"in s){const o=s.Lcl_Translation.value;e.target!==void 0?(e.target.position.fromArray(o),st.add(e.target)):e.lookAt(new P().fromArray(o))}}})}bindSkeleton(e,t,n){const r=this.parsePoseNodes();for(const s in e){const o=e[s];w0.get(parseInt(o.ID)).parents.forEach(function(l){if(t.has(l.ID)){const c=l.ID;w0.get(c).parents.forEach(function(h){n.has(h.ID)&&n.get(h.ID).bind(new Al(o.bones),r[h.ID])})}})}}parsePoseNodes(){const e={};if("Pose"in Be.Objects){const t=Be.Objects.Pose;for(const n in t)if(t[n].attrType==="BindPose"&&t[n].NbPoseNodes>0){const r=t[n].PoseNode;Array.isArray(r)?r.forEach(function(s){e[s.Node]=new Me().fromArray(s.Matrix.a)}):e[r.Node]=new Me().fromArray(r.Matrix.a)}}return e}createAmbientLight(){if("GlobalSettings"in Be&&"AmbientColor"in Be.GlobalSettings){const e=Be.GlobalSettings.AmbientColor.value,t=e[0],n=e[1],r=e[2];if(t!==0||n!==0||r!==0){const s=new be(t,n,r);st.add(new v9(s,1))}}}}class jS{parse(e){const t=new Map;if("Geometry"in Be.Objects){const n=Be.Objects.Geometry;for(const r in n){const s=w0.get(parseInt(r)),o=this.parseGeometry(s,n[r],e);t.set(parseInt(r),o)}}return t}parseGeometry(e,t,n){switch(t.attrType){case"Mesh":return this.parseMeshGeometry(e,t,n);case"NurbsCurve":return this.parseNurbsGeometry(t)}}parseMeshGeometry(e,t,n){const r=n.skeletons,s=[],o=e.parents.map(function(h){return Be.Objects.Model[h.ID]});if(o.length===0)return;const a=e.children.reduce(function(h,f){return r[f.ID]!==void 0&&(h=r[f.ID]),h},null);e.children.forEach(function(h){n.morphTargets[h.ID]!==void 0&&s.push(n.morphTargets[h.ID])});const l=o[0],c={};"RotationOrder"in l&&(c.eulerOrder=yf(l.RotationOrder.value)),"InheritType"in l&&(c.inheritType=parseInt(l.InheritType.value)),"GeometricTranslation"in l&&(c.translation=l.GeometricTranslation.value),"GeometricRotation"in l&&(c.rotation=l.GeometricRotation.value),"GeometricScaling"in l&&(c.scale=l.GeometricScaling.value);const u=xf(c);return this.genGeometry(t,a,s,u)}genGeometry(e,t,n,r){const s=new Fe;e.attrName&&(s.name=e.attrName);const o=this.parseGeoNode(e,t),a=this.genBuffers(o),l=new Ae(a.vertex,3);if(l.applyMatrix4(r),s.setAttribute("position",l),a.colors.length>0&&s.setAttribute("color",new Ae(a.colors,3)),t&&(s.setAttribute("skinIndex",new Jc(a.weightsIndices,4)),s.setAttribute("skinWeight",new Ae(a.vertexWeights,4)),s.FBX_Deformer=t),a.normal.length>0){const c=new k0().getNormalMatrix(r),u=new Ae(a.normal,3);u.applyNormalMatrix(c),s.setAttribute("normal",u)}if(a.uvs.forEach(function(c,u){let h="uv"+(u+1).toString();u===0&&(h="uv"),s.setAttribute(h,new Ae(a.uvs[u],2))}),o.material&&o.material.mappingType!=="AllSame"){let c=a.materialIndex[0],u=0;if(a.materialIndex.forEach(function(h,f){h!==c&&(s.addGroup(u,f-u,c),c=h,u=f)}),s.groups.length>0){const h=s.groups[s.groups.length-1],f=h.start+h.count;f!==a.materialIndex.length&&s.addGroup(f,a.materialIndex.length-f,c)}s.groups.length===0&&s.addGroup(0,a.materialIndex.length,a.materialIndex[0])}return this.addMorphTargets(s,e,n,r),s}parseGeoNode(e,t){const n={};if(n.vertexPositions=e.Vertices!==void 0?e.Vertices.a:[],n.vertexIndices=e.PolygonVertexIndex!==void 0?e.PolygonVertexIndex.a:[],e.LayerElementColor&&(n.color=this.parseVertexColors(e.LayerElementColor[0])),e.LayerElementMaterial&&(n.material=this.parseMaterialIndices(e.LayerElementMaterial[0])),e.LayerElementNormal&&(n.normal=this.parseNormals(e.LayerElementNormal[0])),e.LayerElementUV){n.uv=[];let r=0;for(;e.LayerElementUV[r];)e.LayerElementUV[r].UV&&n.uv.push(this.parseUVs(e.LayerElementUV[r])),r++}return n.weightTable={},t!==null&&(n.skeleton=t,t.rawBones.forEach(function(r,s){r.indices.forEach(function(o,a){n.weightTable[o]===void 0&&(n.weightTable[o]=[]),n.weightTable[o].push({id:s,weight:r.weights[a]})})})),n}genBuffers(e){const t={vertex:[],normal:[],colors:[],uvs:[],materialIndex:[],vertexWeights:[],weightsIndices:[]};let n=0,r=0,s=!1,o=[],a=[],l=[],c=[],u=[],h=[];const f=this;return e.vertexIndices.forEach(function(d,g){let v,_=!1;d<0&&(d=d^-1,_=!0);let m=[],p=[];if(o.push(d*3,d*3+1,d*3+2),e.color){const y=ba(g,n,d,e.color);l.push(y[0],y[1],y[2])}if(e.skeleton){if(e.weightTable[d]!==void 0&&e.weightTable[d].forEach(function(y){p.push(y.weight),m.push(y.id)}),p.length>4){s||(console.warn("THREE.FBXLoader: Vertex has more than 4 skinning weights assigned to vertex. Deleting additional weights."),s=!0);const y=[0,0,0,0],x=[0,0,0,0];p.forEach(function(w,A){let b=w,L=m[A];x.forEach(function(B,I,C){if(b>B){C[I]=b,b=B;const Y=y[I];y[I]=L,L=Y}})}),m=y,p=x}for(;p.length<4;)p.push(0),m.push(0);for(let y=0;y<4;++y)u.push(p[y]),h.push(m[y])}if(e.normal){const y=ba(g,n,d,e.normal);a.push(y[0],y[1],y[2])}e.material&&e.material.mappingType!=="AllSame"&&(v=ba(g,n,d,e.material)[0]),e.uv&&e.uv.forEach(function(y,x){const w=ba(g,n,d,y);c[x]===void 0&&(c[x]=[]),c[x].push(w[0]),c[x].push(w[1])}),r++,_&&(f.genFace(t,e,o,v,a,l,c,u,h,r),n++,r=0,o=[],a=[],l=[],c=[],u=[],h=[])}),t}genFace(e,t,n,r,s,o,a,l,c,u){for(let h=2;h1&&console.warn("THREE.FBXLoader: Encountered an animation stack with multiple layers, this is currently not supported. Ignoring subsequent layers.");const o=e.get(s[0].ID);n[r]={name:t[r].attrName,layer:o}}return n}addClip(e){let t=[];const n=this;return e.layer.forEach(function(r){t=t.concat(n.generateTracks(r))}),new Qa(e.name,-1,t)}generateTracks(e){const t=[];let n=new P,r=new S0,s=new P;if(e.transform&&e.transform.decompose(n,r,s),n=n.toArray(),r=new It().setFromQuaternion(r,e.eulerOrder).toArray(),s=s.toArray(),e.T!==void 0&&Object.keys(e.T.curves).length>0){const o=this.generateVectorTrack(e.modelName,e.T.curves,n,"position");o!==void 0&&t.push(o)}if(e.R!==void 0&&Object.keys(e.R.curves).length>0){const o=this.generateRotationTrack(e.modelName,e.R.curves,r,e.preRotation,e.postRotation,e.eulerOrder);o!==void 0&&t.push(o)}if(e.S!==void 0&&Object.keys(e.S.curves).length>0){const o=this.generateVectorTrack(e.modelName,e.S.curves,s,"scale");o!==void 0&&t.push(o)}if(e.DeformPercent!==void 0){const o=this.generateMorphTrack(e);o!==void 0&&t.push(o)}return t}generateVectorTrack(e,t,n,r){const s=this.getTimesForAllAxes(t),o=this.getKeyframeTrackValues(s,t,n);return new kr(e+"."+r,s,o)}generateRotationTrack(e,t,n,r,s,o){t.x!==void 0&&(this.interpolateRotations(t.x),t.x.values=t.x.values.map(vt.degToRad)),t.y!==void 0&&(this.interpolateRotations(t.y),t.y.values=t.y.values.map(vt.degToRad)),t.z!==void 0&&(this.interpolateRotations(t.z),t.z.values=t.z.values.map(vt.degToRad));const a=this.getTimesForAllAxes(t),l=this.getKeyframeTrackValues(a,t,n);r!==void 0&&(r=r.map(vt.degToRad),r.push(o),r=new It().fromArray(r),r=new S0().setFromEuler(r)),s!==void 0&&(s=s.map(vt.degToRad),s.push(o),s=new It().fromArray(s),s=new S0().setFromEuler(s).invert());const c=new S0,u=new It,h=[];for(let f=0;f1){let n=1,r=t[0];for(let s=1;s=180){const o=s/180,a=r/o;let l=n+a;const c=e.times[t-1],h=(e.times[t]-c)/o;let f=c+h;const d=[],g=[];for(;f1&&(n=e[1].replace(/^(\w+)::/,""),r=e[2]),{id:t,name:n,type:r}}parseNodeProperty(e,t,n){let r=t[1].replace(/^"/,"").replace(/"$/,"").trim(),s=t[2].replace(/^"/,"").replace(/"$/,"").trim();r==="Content"&&s===","&&(s=n.replace(/"/g,"").replace(/,$/,"").trim());const o=this.getCurrentNode();if(o.name==="Properties70"){this.parseNodeSpecialProperty(e,r,s);return}if(r==="C"){const l=s.split(",").slice(1),c=parseInt(l[0]),u=parseInt(l[1]);let h=s.split(",").slice(3);h=h.map(function(f){return f.trim().replace(/^"/,"")}),r="connections",s=[c,u],eT(s,h),o[r]===void 0&&(o[r]=[])}r==="Node"&&(o.id=s),r in o&&Array.isArray(o[r])?o[r].push(s):r!=="a"?o[r]=s:o.a=s,this.setCurrentProp(o,r),r==="a"&&s.slice(-1)!==","&&(o.a=R1(s))}parseNodePropertyContinued(e){const t=this.getCurrentNode();t.a+=e,e.slice(-1)!==","&&(t.a=R1(t.a))}parseNodeSpecialProperty(e,t,n){const r=n.split('",').map(function(u){return u.trim().replace(/^\"/,"").replace(/\s/,"_")}),s=r[0],o=r[1],a=r[2],l=r[3];let c=r[4];switch(o){case"int":case"enum":case"bool":case"ULongLong":case"double":case"Number":case"FieldOfView":c=parseFloat(c);break;case"Color":case"ColorRGB":case"Vector3D":case"Lcl_Translation":case"Lcl_Rotation":case"Lcl_Scaling":c=R1(c);break}this.getPrevNode()[s]={type:o,type2:a,flag:l,value:c},this.setCurrentProp(this.getPrevNode(),s)}}class QS{parse(e){const t=new D3(e);t.skip(23);const n=t.getUint32();if(n<6400)throw new Error("THREE.FBXLoader: FBX version not supported, FileVersion: "+n);const r=new vf;for(;!this.endOfContent(t);){const s=this.parseNode(t,n);s!==null&&r.add(s.name,s)}return r}endOfContent(e){return e.size()%16===0?(e.getOffset()+160+16&-16)>=e.size():e.getOffset()+160+16>=e.size()}parseNode(e,t){const n={},r=t>=7500?e.getUint64():e.getUint32(),s=t>=7500?e.getUint64():e.getUint32();t>=7500?e.getUint64():e.getUint32();const o=e.getUint8(),a=e.getString(o);if(r===0)return null;const l=[];for(let f=0;f0?l[0]:"",u=l.length>1?l[1]:"",h=l.length>2?l[2]:"";for(n.singleProperty=s===1&&e.getOffset()===r;r>e.getOffset();){const f=this.parseNode(e,t);f!==null&&this.parseSubNode(a,n,f)}return n.propertyList=l,typeof c=="number"&&(n.id=c),u!==""&&(n.attrName=u),h!==""&&(n.attrType=h),a!==""&&(n.name=a),n}parseSubNode(e,t,n){if(n.singleProperty===!0){const r=n.propertyList[0];Array.isArray(r)?(t[n.name]=n,n.a=r):t[n.name]=r}else if(e==="Connections"&&n.name==="C"){const r=[];n.propertyList.forEach(function(s,o){o!==0&&r.push(s)}),t.connections===void 0&&(t.connections=[]),t.connections.push(r)}else if(n.name==="Properties70")Object.keys(n).forEach(function(s){t[s]=n[s]});else if(e==="Properties70"&&n.name==="P"){let r=n.propertyList[0],s=n.propertyList[1];const o=n.propertyList[2],a=n.propertyList[3];let l;r.indexOf("Lcl ")===0&&(r=r.replace("Lcl ","Lcl_")),s.indexOf("Lcl ")===0&&(s=s.replace("Lcl ","Lcl_")),s==="Color"||s==="ColorRGB"||s==="Vector"||s==="Vector3D"||s.indexOf("Lcl_")===0?l=[n.propertyList[4],n.propertyList[5],n.propertyList[6]]:l=n.propertyList[4],t[r]={type:s,type2:o,flag:a,value:l}}else t[n.name]===void 0?typeof n.id=="number"?(t[n.name]={},t[n.name][n.id]=n):t[n.name]=n:n.name==="PoseNode"?(Array.isArray(t[n.name])||(t[n.name]=[t[n.name]]),t[n.name].push(n)):t[n.name][n.id]===void 0&&(t[n.name][n.id]=n)}parseProperty(e){const t=e.getString(1);let n;switch(t){case"C":return e.getBoolean();case"D":return e.getFloat64();case"F":return e.getFloat32();case"I":return e.getInt32();case"L":return e.getInt64();case"R":return n=e.getUint32(),e.getArrayBuffer(n);case"S":return n=e.getUint32(),e.getString(n);case"Y":return e.getInt16();case"b":case"c":case"d":case"f":case"i":case"l":const r=e.getUint32(),s=e.getUint32(),o=e.getUint32();if(s===0)switch(t){case"b":case"c":return e.getBooleanArray(r);case"d":return e.getFloat64Array(r);case"f":return e.getFloat32Array(r);case"i":return e.getInt32Array(r);case"l":return e.getInt64Array(r)}typeof OS>"u"&&console.error("THREE.FBXLoader: External library fflate.min.js required.");const a=bo(new Uint8Array(e.getArrayBuffer(o))),l=new D3(a.buffer);switch(t){case"b":case"c":return l.getBooleanArray(r);case"d":return l.getFloat64Array(r);case"f":return l.getFloat32Array(r);case"i":return l.getInt32Array(r);case"l":return l.getInt64Array(r)}default:throw new Error("THREE.FBXLoader: Unknown property type "+t)}}}class D3{constructor(e,t){this.dv=new DataView(e),this.offset=0,this.littleEndian=t!==void 0?t:!0}getOffset(){return this.offset}size(){return this.dv.buffer.byteLength}skip(e){this.offset+=e}getBoolean(){return(this.getUint8()&1)===1}getBooleanArray(e){const t=[];for(let n=0;n=0&&(t=t.slice(0,n)),Ut.decodeText(new Uint8Array(t))}}class vf{add(e,t){this[e]=t}}function KS(i){const e="Kaydara FBX Binary \0";return i.byteLength>=e.length&&e===_f(i,0,e.length)}function ZS(i){const e=["K","a","y","d","a","r","a","\\","F","B","X","\\","B","i","n","a","r","y","\\","\\"];let t=0;function n(r){const s=i[r-1];return i=i.slice(t+r),t++,s}for(let r=0;rv?(_=1,m=0):(_=0,m=1);const p=g-_+u,y=v-m+u,x=g-1+2*u,w=v-1+2*u,A=l&255,b=c&255,L=this.perm[A+this.perm[b]]%12,B=this.perm[A+_+this.perm[b+m]]%12,I=this.perm[A+1+this.perm[b+1]]%12;let C=.5-g*g-v*v;C<0?n=0:(C*=C,n=C*C*this.dot(this.grad3[L],g,v));let Y=.5-p*p-y*y;Y<0?r=0:(Y*=Y,r=Y*Y*this.dot(this.grad3[B],p,y));let O=.5-x*x-w*w;return O<0?s=0:(O*=O,s=O*O*this.dot(this.grad3[I],x,w)),70*(n+r+s)}noise3d(e,t,n){let r,s,o,a;const l=.3333333333333333,c=(e+t+n)*l,u=Math.floor(e+c),h=Math.floor(t+c),f=Math.floor(n+c),d=1/6,g=(u+h+f)*d,v=u-g,_=h-g,m=f-g,p=e-v,y=t-_,x=n-m;let w,A,b,L,B,I;p>=y?y>=x?(w=1,A=0,b=0,L=1,B=1,I=0):p>=x?(w=1,A=0,b=0,L=1,B=0,I=1):(w=0,A=0,b=1,L=1,B=0,I=1):yI?32:0,G=B>C?16:0,j=I>C?8:0,N=B>Y?4:0,k=I>Y?2:0,Z=C>Y?1:0,le=O+G+j+N+k+Z,ve=o[le][0]>=3?1:0,ce=o[le][1]>=3?1:0,ye=o[le][2]>=3?1:0,$=o[le][3]>=3?1:0,se=o[le][0]>=2?1:0,pe=o[le][1]>=2?1:0,K=o[le][2]>=2?1:0,V=o[le][3]>=2?1:0,te=o[le][0]>=1?1:0,Q=o[le][1]>=1?1:0,re=o[le][2]>=1?1:0,we=o[le][3]>=1?1:0,M=B-ve+c,E=I-ce+c,F=C-ye+c,W=Y-$+c,X=B-se+2*c,T=I-pe+2*c,S=C-K+2*c,U=Y-V+2*c,q=B-te+3*c,H=I-Q+3*c,oe=C-re+3*c,ue=Y-we+3*c,he=B-1+4*c,xe=I-1+4*c,ge=C-1+4*c,z=Y-1+4*c,fe=_&255,ne=m&255,Te=p&255,D=y&255,_e=a[fe+a[ne+a[Te+a[D]]]]%32,Ie=a[fe+ve+a[ne+ce+a[Te+ye+a[D+$]]]]%32,Ue=a[fe+se+a[ne+pe+a[Te+K+a[D+V]]]]%32,ke=a[fe+te+a[ne+Q+a[Te+re+a[D+we]]]]%32,Oe=a[fe+1+a[ne+1+a[Te+1+a[D+1]]]]%32;let g0=.6-B*B-I*I-C*C-Y*Y;g0<0?u=0:(g0*=g0,u=g0*g0*this.dot4(s[_e],B,I,C,Y));let E0=.6-M*M-E*E-F*F-W*W;E0<0?h=0:(E0*=E0,h=E0*E0*this.dot4(s[Ie],M,E,F,W));let G0=.6-X*X-T*T-S*S-U*U;G0<0?f=0:(G0*=G0,f=G0*G0*this.dot4(s[Ue],X,T,S,U));let N0=.6-q*q-H*H-oe*oe-ue*ue;N0<0?d=0:(N0*=N0,d=N0*N0*this.dot4(s[ke],q,H,oe,ue));let bn=.6-he*he-xe*xe-ge*ge-z*z;return bn<0?g=0:(bn*=bn,g=bn*bn*this.dot4(s[Oe],he,xe,ge,z)),27*(u+h+f+d+g)}}const Fs={defines:{PERSPECTIVE_CAMERA:1,KERNEL_SIZE:32},uniforms:{tDiffuse:{value:null},tNormal:{value:null},tDepth:{value:null},tNoise:{value:null},kernel:{value:null},cameraNear:{value:null},cameraFar:{value:null},resolution:{value:new ee},cameraProjectionMatrix:{value:new Me},cameraInverseProjectionMatrix:{value:new Me},kernelRadius:{value:8},minDistance:{value:.005},maxDistance:{value:.05}},vertexShader:` + }`};let uT=class extends $t{constructor(e,t){super(),this.edgesRT=new C0(e,t,{depthBuffer:!1,generateMipmaps:!1,minFilter:s0,format:Yt}),this.edgesRT.texture.name="SMAAPass.edges",this.weightsRT=new C0(e,t,{depthBuffer:!1,generateMipmaps:!1,minFilter:s0,format:a0}),this.weightsRT.texture.name="SMAAPass.weights";const n=this,r=new Image;r.src=this.getAreaTexture(),r.onload=function(){n.areaTexture.needsUpdate=!0},this.areaTexture=new A0,this.areaTexture.name="SMAAPass.area",this.areaTexture.image=r,this.areaTexture.format=Yt,this.areaTexture.minFilter=s0,this.areaTexture.generateMipmaps=!1,this.areaTexture.flipY=!1;const s=new Image;s.src=this.getSearchTexture(),s.onload=function(){n.searchTexture.needsUpdate=!0},this.searchTexture=new A0,this.searchTexture.name="SMAAPass.search",this.searchTexture.image=s,this.searchTexture.magFilter=r0,this.searchTexture.minFilter=r0,this.searchTexture.generateMipmaps=!1,this.searchTexture.flipY=!1,Fs===void 0&&console.error("THREE.SMAAPass relies on SMAAShader"),this.uniformsEdges=Z0.clone(Fs.uniforms),this.uniformsEdges.resolution.value.set(1/e,1/t),this.materialEdges=new u0({defines:Object.assign({},Fs.defines),uniforms:this.uniformsEdges,vertexShader:Fs.vertexShader,fragmentShader:Fs.fragmentShader}),this.uniformsWeights=Z0.clone(Ma.uniforms),this.uniformsWeights.resolution.value.set(1/e,1/t),this.uniformsWeights.tDiffuse.value=this.edgesRT.texture,this.uniformsWeights.tArea.value=this.areaTexture,this.uniformsWeights.tSearch.value=this.searchTexture,this.materialWeights=new u0({defines:Object.assign({},Ma.defines),uniforms:this.uniformsWeights,vertexShader:Ma.vertexShader,fragmentShader:Ma.fragmentShader}),this.uniformsBlend=Z0.clone(F1.uniforms),this.uniformsBlend.resolution.value.set(1/e,1/t),this.uniformsBlend.tDiffuse.value=this.weightsRT.texture,this.materialBlend=new u0({uniforms:this.uniformsBlend,vertexShader:F1.vertexShader,fragmentShader:F1.fragmentShader}),this.needsSwap=!1,this.fsQuad=new Gi(null)}render(e,t,n){this.uniformsEdges.tDiffuse.value=n.texture,this.fsQuad.material=this.materialEdges,e.setRenderTarget(this.edgesRT),this.clear&&e.clear(),this.fsQuad.render(e),this.fsQuad.material=this.materialWeights,e.setRenderTarget(this.weightsRT),this.clear&&e.clear(),this.fsQuad.render(e),this.uniformsBlend.tColor.value=n.texture,this.fsQuad.material=this.materialBlend,this.renderToScreen?(e.setRenderTarget(null),this.fsQuad.render(e)):(e.setRenderTarget(t),this.clear&&e.clear(),this.fsQuad.render(e))}setSize(e,t){this.edgesRT.setSize(e,t),this.weightsRT.setSize(e,t),this.materialEdges.uniforms.resolution.value.set(1/e,1/t),this.materialWeights.uniforms.resolution.value.set(1/e,1/t),this.materialBlend.uniforms.resolution.value.set(1/e,1/t)}getAreaTexture(){return"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAKAAAAIwCAIAAACOVPcQAACBeklEQVR42u39W4xlWXrnh/3WWvuciIzMrKxrV8/0rWbY0+SQFKcb4owIkSIFCjY9AC1BT/LYBozRi+EX+cV+8IMsYAaCwRcBwjzMiw2jAWtgwC8WR5Q8mDFHZLNHTarZGrLJJllt1W2qKrsumZWZcTvn7L3W54e1vrXX3vuciLPPORFR1XE2EomorB0nVuz//r71re/y/1eMvb4Cb3N11xV/PP/2v4UBAwJG/7H8urx6/25/Gf8O5hypMQ0EEEQwAqLfoN/Z+97f/SW+/NvcgQk4sGBJK6H7N4PFVL+K+e0N11yNfkKvwUdwdlUAXPHHL38oa15f/i/46Ih6SuMSPmLAYAwyRKn7dfMGH97jaMFBYCJUgotIC2YAdu+LyW9vvubxAP8kAL8H/koAuOKP3+q6+xGnd5kdYCeECnGIJViwGJMAkQKfDvB3WZxjLKGh8VSCCzhwEWBpMc5/kBbjawT4HnwJfhr+pPBIu7uu+OOTo9vsmtQcniMBGkKFd4jDWMSCRUpLjJYNJkM+IRzQ+PQvIeAMTrBS2LEiaiR9b/5PuT6Ap/AcfAFO4Y3dA3DFH7/VS+M8k4baEAQfMI4QfbVDDGIRg7GKaIY52qAjTAgTvGBAPGIIghOCYAUrGFNgzA7Q3QhgCwfwAnwe5vDejgG44o/fbm1C5ZlYQvQDARPAIQGxCWBM+wWl37ZQESb4gImexGMDouhGLx1Cst0Saa4b4AqO4Hk4gxo+3DHAV/nx27p3JziPM2pVgoiia5MdEzCGULprIN7gEEeQ5IQxEBBBQnxhsDb5auGmAAYcHMA9eAAz8PBol8/xij9+C4Djlim4gJjWcwZBhCBgMIIYxGAVIkH3ZtcBuLdtRFMWsPGoY9rN+HoBji9VBYdwD2ZQg4cnO7OSq/z4rU5KKdwVbFAjNojCQzTlCLPFSxtamwh2jMUcEgg2Wm/6XgErIBhBckQtGN3CzbVacERgCnfgLswhnvqf7QyAq/z4rRZm1YglYE3affGITaZsdIe2FmMIpnOCap25I6jt2kCwCW0D1uAD9sZctNGXcQIHCkINDQgc78aCr+zjtw3BU/ijdpw3zhCwcaONwBvdeS2YZKkJNJsMPf2JKEvC28RXxxI0ASJyzQCjCEQrO4Q7sFArEzjZhaFc4cdv+/JFdKULM4px0DfUBI2hIsy06BqLhGTQEVdbfAIZXYMPesq6VoCHICzUyjwInO4Y411//LYLs6TDa9wvg2CC2rElgAnpTBziThxaL22MYhzfkghz6GAs2VHbbdM91VZu1MEEpupMMwKyVTb5ij9+u4VJG/5EgEMMmFF01cFai3isRbKbzb+YaU/MQbAm2XSMoUPAmvZzbuKYRIFApbtlrfFuUGd6vq2hXNnH78ZLh/iFhsQG3T4D1ib7k5CC6vY0DCbtrohgLEIClXiGtl10zc0CnEGIhhatLBva7NP58Tvw0qE8yWhARLQ8h4+AhQSP+I4F5xoU+VilGRJs6wnS7ruti/4KvAY/CfdgqjsMy4pf8fodQO8/gnuX3f/3xi3om1/h7THr+co3x93PP9+FBUfbNUjcjEmhcrkT+8K7ml7V10Jo05mpIEFy1NmCJWx9SIKKt+EjAL4Ez8EBVOB6havuT/rByPvHXK+9zUcfcbb254+9fydJknYnRr1oGfdaiAgpxu1Rx/Rek8KISftx3L+DfsLWAANn8Hvw0/AFeAGO9DFV3c6D+CcWbL8Dj9e7f+T1k8AZv/d7+PXWM/Z+VvdCrIvuAKO09RpEEQJM0Ci6+B4xhTWr4cZNOvhktabw0ta0rSJmqz3Yw5/AKXwenod7cAhTmBSPKf6JBdvH8IP17h95pXqw50/+BFnj88fev4NchyaK47OPhhtI8RFSvAfDSNh0Ck0p2gLxGkib5NJj/JWCr90EWQJvwBzO4AHcgztwAFN1evHPUVGwfXON+0debT1YeGON9Yy9/63X+OguiwmhIhQhD7l4sMqlG3D86Suc3qWZ4rWjI1X7u0Ytw6x3rIMeIOPDprfe2XzNgyj6PahhBjO4C3e6puDgXrdg+/5l948vF3bqwZetZ+z9Rx9zdIY5pInPK4Nk0t+l52xdK2B45Qd87nM8fsD5EfUhIcJcERw4RdqqH7Yde5V7m1vhNmtedkz6EDzUMF/2jJYWbC+4fzzA/Y+/8PPH3j9dcBAPIRP8JLXd5BpAu03aziOL3VVHZzz3CXWDPWd+SH2AnxIqQoTZpo9Ckc6HIrFbAbzNmlcg8Ag8NFDDAhbJvTBZXbC94P7t68EXfv6o+21gUtPETU7bbkLxvNKRFG2+KXzvtObonPP4rBvsgmaKj404DlshFole1Glfh02fE7bYR7dZ82oTewIBGn1Md6CG6YUF26X376oevOLzx95vhUmgblI6LBZwTCDY7vMq0op5WVXgsObOXJ+1x3qaBl9j1FeLxbhU9w1F+Wiba6s1X/TBz1LnUfuYDi4r2C69f1f14BWfP+p+W2GFKuC9phcELMYRRLur9DEZTUdEH+iEqWdaM7X4WOoPGI+ZYD2+wcQ+y+ioHUZ9dTDbArzxmi/bJI9BND0Ynd6lBdve/butBw8+f/T9D3ABa3AG8W3VPX4hBin+bj8dMMmSpp5pg7fJ6xrBFE2WQQEWnV8Qg3FbAWzYfM1rREEnmvkN2o1+acG2d/9u68GDzx91v3mAjb1zkpqT21OipPKO0b9TO5W0nTdOmAQm0TObts3aBKgwARtoPDiCT0gHgwnbArzxmtcLc08HgF1asN0C4Ms/fvD5I+7PhfqyXE/b7RbbrGyRQRT9ARZcwAUmgdoz0ehJ9Fn7QAhUjhDAQSw0bV3T3WbNa59jzmiP6GsWbGXDX2ytjy8+f9T97fiBPq9YeLdBmyuizZHaqXITnXiMUEEVcJ7K4j3BFPurtB4bixW8wTpweL8DC95szWMOqucFYGsWbGU7p3TxxxefP+r+oTVktxY0v5hbq3KiOKYnY8ddJVSBxuMMVffNbxwIOERShst73HZ78DZrHpmJmH3K6sGz0fe3UUj0eyRrSCGTTc+rjVNoGzNSv05srAxUBh8IhqChiQgVNIIBH3AVPnrsnXQZbLTm8ammv8eVXn/vWpaTem5IXRlt+U/LA21zhSb9cye6jcOfCnOwhIAYXAMVTUNV0QhVha9xjgA27ODJbLbmitt3tRN80lqG6N/khgot4ZVlOyO4WNg3OIMzhIZQpUEHieg2im6F91hB3I2tubql6BYNN9Hj5S7G0G2tahslBWKDnOiIvuAEDzakDQKDNFQT6gbn8E2y4BBubM230YIpBnDbMa+y3dx0n1S0BtuG62lCCXwcY0F72T1VRR3t2ONcsmDjbmzNt9RFs2LO2hQNyb022JisaI8rAWuw4HI3FuAIhZdOGIcdjLJvvObqlpqvWTJnnQbyi/1M9O8UxWhBs//H42I0q1Yb/XPGONzcmm+ri172mHKvZBpHkJaNJz6v9jxqiklDj3U4CA2ugpAaYMWqNXsdXbmJNd9egCnJEsphXNM+MnK3m0FCJ5S1kmJpa3DgPVbnQnPGWIDspW9ozbcO4K/9LkfaQO2KHuqlfFXSbdNzcEcwoqNEFE9zcIXu9/6n/ym/BC/C3aJLzEKPuYVlbFnfhZ8kcWxV3dbv4bKl28566wD+8C53aw49lTABp9PWbsB+knfc/Li3eVizf5vv/xmvnPKg5ihwKEwlrcHqucuVcVOxEv8aH37E3ZqpZypUulrHEtIWKUr+txHg+ojZDGlwnqmkGlzcVi1dLiNSJiHjfbRNOPwKpx9TVdTn3K05DBx4psIk4Ei8aCkJahRgffk4YnEXe07T4H2RR1u27E6wfQsBDofUgjFUFnwC2AiVtA+05J2zpiDK2Oa0c5fmAecN1iJzmpqFZxqYBCYhFTCsUNEmUnIcZ6aEA5rQVhEywG6w7HSW02XfOoBlQmjwulOFQAg66SvJblrTEX1YtJ3uG15T/BH1OfOQeuR8g/c0gdpT5fx2SKbs9EfHTKdM8A1GaJRHLVIwhcGyydZsbifAFVKl5EMKNU2Hryo+06BeTgqnxzYjThVySDikbtJPieco75lYfKAJOMEZBTjoITuWHXXZVhcUDIS2hpiXHV9Ku4u44bN5OYLDOkJo8w+xJSMbhBRHEdEs9JZUCkQrPMAvaHyLkxgkEHxiNkx/x2YB0mGsQ8EUWj/stW5YLhtS5SMu+/YBbNPDCkGTUybN8krRLBGPlZkVOA0j+a1+rkyQKWGaPHPLZOkJhioQYnVZ2hS3zVxMtgC46KuRwbJNd9nV2PHgb36F194ecf/Yeu2vAFe5nm/bRBFrnY4BauE8ERmZRFUn0k8hbftiVYSKMEme2dJCJSCGYAlNqh87bXOPdUkGy24P6d1ll21MBqqx48Fvv8ZHH8HZFY7j/uAq1xMJUFqCSUlJPmNbIiNsmwuMs/q9CMtsZsFO6SprzCS1Z7QL8xCQClEelpjTduDMsmWD8S1PT152BtvmIGvUeDA/yRn83u/x0/4qxoPHjx+PXY9pqX9bgMvh/Nz9kpP4pOe1/fYf3axUiMdHLlPpZCNjgtNFAhcHEDxTumNONhHrBduW+vOyY++70WWnPXj98eA4kOt/mj/5E05l9+O4o8ePx67HFqyC+qSSnyselqjZGaVK2TadbFLPWAQ4NBhHqDCCV7OTpo34AlSSylPtIdd2AJZlyzYQrDJ5lcWGNceD80CunPLGGzsfD+7wRb95NevJI5docQ3tgCyr5bGnyaPRlmwNsFELViOOx9loebGNq2moDOKpHLVP5al2cymWHbkfzGXL7kfRl44H9wZy33tvt+PB/Xnf93e+nh5ZlU18wCiRUa9m7kib9LYuOk+hudQNbxwm0AQqbfloimaB2lM5fChex+ylMwuTbfmXQtmWlenZljbdXTLuOxjI/fDDHY4Hjx8/Hrse0zXfPFxbUN1kKqSCCSk50m0Ajtx3ub9XHBKHXESb8iO6E+qGytF4nO0OG3SXzbJlhxBnKtKyl0NwybjvYCD30aMdjgePHz8eu56SVTBbgxJMliQ3Oauwg0QHxXE2Ez/EIReLdQj42Gzb4CLS0YJD9xUx7bsi0vJi5mUbW1QzL0h0PFk17rtiIPfJk52MB48fPx67npJJwyrBa2RCCQRTbGZSPCxTPOiND4G2pYyOQ4h4jINIJh5wFU1NFZt+IsZ59LSnDqBjZ2awbOku+yInunLcd8VA7rNnOxkPHj9+PGY9B0MWJJNozOJmlglvDMXDEozdhQWbgs/U6oBanGzLrdSNNnZFjOkmbi5bNt1lX7JLLhn3vXAg9/h4y/Hg8ePHI9dzQMEkWCgdRfYykYKnkP7D4rIujsujaKPBsB54vE2TS00ccvFY/Tth7JXeq1hz+qgVy04sAJawTsvOknHfCwdyT062HA8eP348Zj0vdoXF4pilKa2BROed+9fyw9rWRXeTFXESMOanvDZfJuJaSXouQdMdDJZtekZcLLvEeK04d8m474UDuaenW44Hjx8/Xns9YYqZpszGWB3AN/4VHw+k7WSFtJ3Qicuqb/NlVmgXWsxh570xg2UwxUw3WfO6B5nOuO8aA7lnZxuPB48fPx6znm1i4bsfcbaptF3zNT78eFPtwi1OaCNOqp1x3zUGcs/PN++AGD1+fMXrSVm2baTtPhPahbPhA71wIHd2bXzRa69nG+3CraTtPivahV/55tXWg8fyRY/9AdsY8VbSdp8V7cKrrgdfM//z6ILQFtJ2nxHtwmuoB4/kf74+gLeRtvvMaBdeSz34+vifx0YG20jbfTa0C6+tHrwe//NmOG0L8EbSdp8R7cLrrQe/996O+ai3ujQOskpTNULa7jOjXXj99eCd8lHvoFiwsbTdZ0a78PrrwTvlo966pLuRtB2fFe3Cm6oHP9kNH/W2FryxtN1nTLvwRurBO+Kj3pWXHidtx2dFu/Bm68Fb81HvykuPlrb7LGkX3mw9eGs+6h1Y8MbSdjegXcguQLjmevDpTQLMxtJ2N6NdyBZu9AbrwVvwUW+LbteULUpCdqm0HTelXbhNPe8G68Gb8lFvVfYfSNuxvrTdTWoXbozAzdaDZzfkorOj1oxVxlIMlpSIlpLrt8D4hrQL17z+c3h6hU/wv4Q/utps4+bm+6P/hIcf0JwQ5oQGPBL0eKPTYEXTW+eL/2DKn73J9BTXYANG57hz1cEMviVf/4tf5b/6C5pTQkMIWoAq7hTpOJjtAM4pxKu5vg5vXeUrtI09/Mo/5H+4z+Mp5xULh7cEm2QbRP2tFIKR7WM3fPf/jZ3SWCqLM2l4NxID5zB72HQXv3jj/8mLR5xXNA5v8EbFQEz7PpRfl1+MB/hlAN65qgDn3wTgH13hK7T59bmP+NIx1SHHU84nLOITt3iVz8mNO+lPrjGAnBFqmioNn1mTyk1ta47R6d4MrX7tjrnjYUpdUbv2rVr6YpVfsGG58AG8Ah9eyUN8CX4WfgV+G8LVWPDGb+Zd4cU584CtqSbMKxauxTg+dyn/LkVgA+IR8KHtejeFKRtTmLLpxN6mYVLjYxwXf5x2VofiZcp/lwKk4wGOpYDnoIZPdg/AAbwMfx0+ge9dgZvYjuqKe4HnGnykYo5TvJbG0Vj12JagRhwKa44H95ShkZa5RyLGGdfYvG7aw1TsF6iapPAS29mNS3NmsTQZCmgTzFwgL3upCTgtBTRwvGMAKrgLn4evwin8+afJRcff+8izUGUM63GOOuAs3tJkw7J4kyoNreqrpO6cYLQeFUd7TTpr5YOTLc9RUUogUOVJQ1GYJaFLAW0oTmKyYS46ZooP4S4EON3xQ5zC8/CX4CnM4c1PE8ApexpoYuzqlP3d4S3OJP8ZDK7cKWNaTlqmgDiiHwl1YsE41w1zT4iRTm3DBqxvOUsbMKKDa/EHxagtnta072ejc3DOIh5ojvh8l3tk1JF/AV6FU6jh3U8HwEazLgdCLYSQ+MYiAI2ltomkzttUb0gGHdSUUgsIYjTzLG3mObX4FBRaYtpDVNZrih9TgTeYOBxsEnN1gOCTM8Bsw/ieMc75w9kuAT6A+/AiHGvN/+Gn4KRkiuzpNNDYhDGFndWRpE6SVfm8U5bxnSgVV2jrg6JCKmneqey8VMFgq2+AM/i4L4RUbfSi27lNXZ7R7W9RTcq/q9fk4Xw3AMQd4I5ifAZz8FcVtm9SAom/dyN4lczJQW/kC42ZrHgcCoIf1oVMKkVItmMBi9cOeNHGLqOZk+QqQmrbc5YmYgxELUUN35z2iohstgfLIFmcMV7s4CFmI74L9+EFmGsi+tGnAOD4Yk9gIpo01Y4cA43BWGygMdr4YZekG3OBIUXXNukvJS8tqa06e+lSDCtnqqMFu6hWHXCF+WaYt64m9QBmNxi7Ioy7D+fa1yHw+FMAcPt7SysFLtoG4PXAk7JOA3aAxBRqUiAdU9Yp5lK3HLSRFtOim0sa8euEt08xvKjYjzeJ2GU7YawexrnKI9tmobInjFXCewpwriY9+RR4aaezFhMhGCppKwom0ChrgFlKzyPKkGlTW1YQrE9HJqu8hKGgMc6hVi5QRq0PZxNfrYNgE64utmRv6KKHRpxf6VDUaOvNP5jCEx5q185My/7RKz69UQu2im5k4/eownpxZxNLwiZ1AZTO2ZjWjkU9uaB2HFn6Q3u0JcsSx/qV9hTEApRzeBLDJQXxYmTnq7bdLa3+uqFrxLJ5w1TehnNHx5ECvCh2g2c3hHH5YsfdaSKddztfjQ6imKFGSyFwlLzxEGPp6r5IevVjk1AMx3wMqi1NxDVjLBiPs9tbsCkIY5we5/ML22zrCScFxnNtzsr9Wcc3CnD+pYO+4VXXiDE0oc/vQQ/fDK3oPESJMYXNmJa/DuloJZkcTpcYE8lIH8Dz8DJMiynNC86Mb2lNaaqP/+L7f2fcE/yP7/Lde8xfgSOdMxvOixZf/9p3+M4hT1+F+zApxg9XfUvYjc8qX2lfOOpK2gNRtB4flpFu9FTKCp2XJRgXnX6olp1zyYjTKJSkGmLE2NjUr1bxFM4AeAAHBUFIeSLqXR+NvH/M9fOnfHzOD2vCSyQJKzfgsCh+yi/Mmc35F2fUrw7miW33W9hBD1vpuUojFphIyvg7aTeoymDkIkeW3XLHmguMzbIAJejN6B5MDrhipE2y6SoFRO/AK/AcHHZHNIfiWrEe/C6cr3f/yOvrQKB+zMM55/GQdLDsR+ifr5Fiuu+/y+M78LzOE5dsNuXC3PYvYWd8NXvphLSkJIasrlD2/HOqQ+RjcRdjKTGWYhhVUm4yxlyiGPuMsZR7sMCHUBeTuNWA7if+ifXgc/hovftHXs/DV+Fvwe+f8shzMiMcweFgBly3//vwJfg5AN4450fn1Hd1Rm1aBLu22Dy3y3H2+OqMemkbGZ4jozcDjJf6596xOLpC0eMTHbKnxLxH27uZ/bMTGs2jOaMOY4m87CfQwF0dw53oa1k80JRuz/XgS+8fX3N9Af4qPIMfzKgCp4H5TDGe9GGeFPzSsZz80SlPTxXjgwJmC45njzgt2vbQ4b4OAdUK4/vWhO8d8v6EE8fMUsfakXbPpFJeLs2ubM/qdm/la3WP91uWhxXHjoWhyRUq2iJ/+5mA73zwIIo+LoZ/SgvIRjAd1IMvvn98PfgOvAJfhhm8scAKVWDuaRaK8aQ9f7vuPDH6Bj47ZXau7rqYJ66mTDwEDU6lLbCjCK0qTXyl5mnDoeNRxanj3FJbaksTk0faXxHxLrssgPkWB9LnA/MFleXcJozzjwsUvUG0X/QCve51qkMDXp9mtcyOy3rwBfdvVJK7D6/ACSzg3RoruIq5UDeESfEmVclDxnniU82vxMLtceD0hGZWzBNPMM/jSPne2OVatiTKUpY5vY7gc0LdUAWeWM5tH+O2I66AOWw9xT2BuyRVLGdoDHUsVRXOo/c+ZdRXvFfnxWyIV4upFLCl9eAL7h8Zv0QH8Ry8pA2cHzQpGesctVA37ZtklBTgHjyvdSeKY/RZw/kJMk0Y25cSNRWSigQtlULPTw+kzuJPeYEkXjQRpoGZobYsLF79pyd1dMRHInbgFTZqNLhDqiIsTNpoex2WLcy0/X6rHcdMMQvFSd5dWA++4P7xv89deACnmr36uGlL69bRCL6BSZsS6c0TU2TKK5gtWCzgAOOwQcurqk9j8whvziZSMLcq5hbuwBEsYjopUBkqw1yYBGpLA97SRElEmx5MCInBY5vgLk94iKqSWmhIGmkJ4Bi9m4L645J68LyY4wsFYBfUg5feP/6gWWm58IEmKQM89hq7KsZNaKtP5TxxrUZZVkNmMJtjbKrGxLNEbHPJxhqy7lAmbC32ZqeF6lTaknRWcYaFpfLUBh/rwaQycCCJmW15Kstv6jRHyJFry2C1ahkkIW0LO75s61+owxK1y3XqweX9m5YLM2DPFeOjn/iiqCKJ+yKXF8t5Yl/kNsqaSCryxPq5xWTFIaP8KSW0RYxqupaUf0RcTNSSdJZGcKYdYA6kdtrtmyBckfKXwqk0pHpUHlwWaffjNRBYFPUDWa8e3Lt/o0R0CdisKDM89cX0pvRHEfM8ca4t0s2Xx4kgo91MPQJ/0c9MQYq0co8MBh7bz1fio0UUHLR4aAIOvOmoYO6kwlEVODSSTliWtOtH6sPkrtctF9ZtJ9GIerBskvhdVS5cFNv9s1BU0AbdUgdK4FG+dRnjFmDTzniRMdZO1QhzMK355vigbdkpz9P6qjUGE5J2qAcXmwJ20cZUiAD0z+pGMx6xkzJkmEf40Hr4qZfVg2XzF9YOyoV5BjzVkUJngKf8lgNYwKECEHrCNDrWZzMlflS3yBhr/InyoUgBc/lKT4pxVrrC6g1YwcceK3BmNxZcAtz3j5EIpqguh9H6wc011YN75cKDLpFDxuwkrPQmUwW4KTbj9mZTwBwLq4aQMUZbHm1rylJ46dzR0dua2n3RYCWZsiHROeywyJGR7mXKlpryyCiouY56sFkBWEnkEB/raeh/Sw4162KeuAxMQpEkzy5alMY5wamMsWKKrtW2WpEWNnReZWONKWjrdsKZarpFjqCslq773PLmEhM448Pc3+FKr1+94vv/rfw4tEcu+lKTBe4kZSdijBrykwv9vbCMPcLQTygBjzVckSLPRVGslqdunwJ4oegtFOYb4SwxNgWLCmD7T9kVjTv5YDgpo0XBmN34Z/rEHp0sgyz7lngsrm4lvMm2Mr1zNOJYJ5cuxuQxwMGJq/TP5emlb8fsQBZviK4t8hFL+zbhtlpwaRSxQRWfeETjuauPsdGxsBVdO7nmP4xvzSoT29pRl7kGqz+k26B3Oy0YNV+SXbbQas1ctC/GarskRdFpKczVAF1ZXnLcpaMuzVe6lZ2g/1ndcvOVgRG3sdUAY1bKD6achijMPdMxV4muKVorSpiDHituH7rSTs7n/4y5DhRXo4FVBN4vO/zbAcxhENzGbHCzU/98Mcx5e7a31kWjw9FCe/zNeYyQjZsWb1uc7U33pN4Mji6hCLhivqfa9Ss6xLg031AgfesA/l99m9fgvnaF9JoE6bYKmkGNK3aPbHB96w3+DnxFm4hs0drLsk7U8kf/N/CvwQNtllna0rjq61sH8L80HAuvwH1tvBy2ChqWSCaYTaGN19sTvlfzFD6n+iKTbvtayfrfe9ueWh6GJFoxLdr7V72a5ZpvHcCPDzma0wTO4EgbLyedxstO81n57LYBOBzyfsOhUKsW1J1BB5vr/tz8RyqOFylQP9Tvst2JALsC5lsH8PyQ40DV4ANzYa4dedNiKNR1s+x2wwbR7q4/4cTxqEk4LWDebfisuo36JXLiWFjOtLrlNWh3K1rRS4xvHcDNlFnNmWBBAl5SWaL3oPOfnvbr5pdjVnEaeBJSYjuLEkyLLsWhKccadmOphZkOPgVdalj2QpSmfOsADhMWE2ZBu4+EEJI4wKTAuCoC4xwQbWXBltpxbjkXJtKxxabo9e7tyhlgb6gNlSbUpMh+l/FaqzVwewGu8BW1Zx7pTpQDJUjb8tsUTW6+GDXbMn3mLbXlXJiGdggxFAoUrtPS3wE4Nk02UZG2OOzlk7fRs7i95QCLo3E0jtrjnM7SR3uS1p4qtS2nJ5OwtQVHgOvArLBFijZUV9QtSl8dAY5d0E0hM0w3HS2DpIeB6m/A1+HfhJcGUq4sOxH+x3f5+VO+Ds9rYNI7zPXOYWPrtf8bYMx6fuOAX5jzNR0PdsuON+X1f7EERxMJJoU6GkTEWBvVolVlb5lh3tKCg6Wx1IbaMDdJ+9sUCc5KC46hKGCk3IVOS4TCqdBNfUs7Kd4iXf2RjnT/LLysJy3XDcHLh/vde3x8DoGvwgsa67vBk91G5Pe/HbOe7xwym0NXbtiuuDkGO2IJDh9oQvJ4cY4vdoqLDuoH9Zl2F/ofsekn8lkuhIlhQcffUtSjytFyp++p6NiE7Rqx/lodgKVoceEp/CP4FfjrquZaTtj2AvH5K/ywpn7M34K/SsoYDAdIN448I1/0/wveW289T1/lX5xBzc8N5IaHr0XMOQdHsIkDuJFifj20pBm5jzwUv9e2FhwRsvhAbalCIuIw3bhJihY3p6nTFFIZgiSYjfTf3aXuOjmeGn4bPoGvwl+CFzTRczBIuHBEeImHc37/lGfwZR0cXzVDOvaKfNHvwe+suZ771K/y/XcBlsoN996JpBhoE2toYxOznNEOS5TJc6Id5GEXLjrWo+LEWGNpPDU4WAwsIRROu+1vM+0oW37z/MBN9kqHnSArwPfgFJ7Cq/Ai3Ie7g7ncmI09v8sjzw9mzOAEXoIHxURueaAce5V80f/DOuuZwHM8vsMb5wBzOFWM7wymTXPAEvm4vcFpZ2ut0VZRjkiP2MlmLd6DIpbGSiHOjdnUHN90hRYmhTnmvhzp1iKDNj+b7t5hi79lWGwQ+HN9RsfFMy0FXbEwhfuczKgCbyxYwBmcFhhvo/7a44v+i3XWcwDP86PzpGQYdWh7csP5dBvZ1jNzdxC8pBGuxqSW5vw40nBpj5JhMwvOzN0RWqERHMr4Lv1kWX84xLR830G3j6yqZ1a8UstTlW+qJPOZ+sZ7xZPKTJLhiNOAFd6tk+jrTH31ncLOxid8+nzRb128HhUcru/y0Wn6iT254YPC6FtVSIMoW2sk727AhvTtrWKZTvgsmckfXYZWeNRXx/3YQ2OUxLDrbHtN11IwrgXT6c8dATDwLniYwxzO4RzuQqTKSC5gAofMZ1QBK3zQ4JWobFbcvJm87FK+6JXrKahLn54m3p+McXzzYtP8VF/QpJuh1OwieElEoI1pRxPS09FBrkq2tWCU59+HdhNtTIqKm8EBrw2RTOEDpG3IKo2Y7mFdLm3ZeVjYwVw11o/oznceMve4CgMfNym/utA/d/ILMR7gpXzRy9eDsgLcgbs8O2Va1L0zzIdwGGemTBuwROHeoMShkUc7P+ISY3KH5ZZeWqO8mFTxQYeXTNuzvvK5FGPdQfuu00DwYFY9dyhctEt+OJDdnucfpmyhzUJzfsJjr29l8S0bXBfwRS9ZT26tmMIdZucch5ZboMz3Nio3nIOsYHCGoDT4kUA9MiXEp9Xsui1S8th/kbWIrMBxDGLodWUQIWcvnXy+9M23xPiSMOiRPqM+YMXkUN3gXFrZJwXGzUaMpJfyRS9ZT0lPe8TpScuRlbMHeUmlaKDoNuy62iWNTWNFYjoxFzuJs8oR+RhRx7O4SVNSXpa0ZJQ0K1LAHDQ+D9IepkMXpcsq5EVCvClBUIzDhDoyKwDw1Lc59GbTeORivugw1IcuaEOaGWdNm+Ps5fQ7/tm0DjMegq3yM3vb5j12qUId5UZD2oxDSEWOZMSqFl/W+5oynWDa/aI04tJRQ2eTXusg86SQVu/nwSYwpW6wLjlqIzwLuxGIvoAvul0PS+ZNz0/akp/pniO/8JDnGyaCkzbhl6YcqmK/69prxPqtpx2+Km9al9sjL+rwMgHw4jE/C8/HQ3m1vBuL1fldbzd8mOueVJ92syqdEY4KJjSCde3mcRw2TA6szxedn+zwhZMps0XrqEsiUjnC1hw0TELC2Ek7uAAdzcheXv1BYLagspxpzSAoZZUsIzIq35MnFQ9DOrlNB30jq3L4pkhccKUAA8/ocvN1Rzx9QyOtERs4CVsJRK/DF71kPYrxYsGsm6RMh4cps5g1DOmM54Ly1ii0Hd3Y/BMk8VWFgBVmhqrkJCPBHAolwZaWzLR9Vb7bcWdX9NyUYE+uB2BKfuaeBUcjDljbYVY4DdtsVWvzRZdWnyUzDpjNl1Du3aloAjVJTNDpcIOVVhrHFF66lLfJL1zJr9PQ2nFJSBaKoDe+sAvLufZVHVzYh7W0h/c6AAZ+7Tvj6q9j68G/cTCS/3n1vLKHZwNi+P+pS0WkZNMBMUl+LDLuiE4omZy71r3UFMwNJV+VJ/GC5ixVUkBStsT4gGKh0Gm4Oy3qvq7Lbmq24nPdDuDR9deR11XzP4vFu3TYzfnIyiSVmgizUYGqkIXNdKTY9pgb9D2Ix5t0+NHkVzCdU03suWkkVZAoCONCn0T35gAeW38de43mf97sMOpSvj4aa1KYUm58USI7Wxxes03bAZdRzk6UtbzMaCQ6IxO0dy7X+XsjoD16hpsBeGz9dfzHj+R/Hp8nCxZRqkEDTaCKCSywjiaoMJ1TITE9eg7Jqnq8HL6gDwiZb0u0V0Rr/rmvqjxKuaLCX7ZWXTvAY+uvm3z8CP7nzVpngqrJpZKwWnCUjIviYVlirlGOzPLI3SMVyp/elvBUjjDkNhrtufFFErQ8pmdSlbK16toBHlt/HV8uHMX/vEGALkV3RJREiSlopxwdMXOZPLZ+ix+kAHpMKIk8UtE1ygtquttwxNhphrIZ1IBzjGF3IIGxGcBj6q8bHJBG8T9vdsoWrTFEuebEZuVxhhClH6P5Zo89OG9fwHNjtNQTpD0TG9PJLEYqvEY6Rlxy+ZZGfL0Aj62/bnQCXp//eeM4KzfQVJbgMQbUjlMFIm6TpcfWlZje7NBSV6IsEVmumWIbjiloUzQX9OzYdo8L1wjw2PrrpimONfmfNyzKklrgnEkSzT5QWYQW40YShyzqsRmMXbvVxKtGuYyMKaU1ugenLDm5Ily4iT14fP11Mx+xJv+zZ3MvnfdFqxU3a1W/FTB4m3Qfsyc1XUcdVhDeUDZXSFHHLQj/Y5jtC7ZqM0CXGwB4bP11i3LhOvzPGygYtiUBiwQV/4wFO0majijGsafHyRLu0yG6q35cL1rOpVxr2s5cM2jJYMCdc10Aj6q/blRpWJ//+dmm5psMl0KA2+AFRx9jMe2WbC4jQxnikd4DU8TwUjRVacgdlhmr3bpddzuJ9zXqr2xnxJfzP29RexdtjDVZqzkqa6PyvcojGrfkXiJ8SEtml/nYskicv0ivlxbqjemwUjMw5evdg8fUX9nOiC/lf94Q2i7MURk9nW1MSj5j8eAyV6y5CN2S6qbnw3vdA1Iwq+XOSCl663udN3IzLnrt+us25cI1+Z83SXQUldqQq0b5XOT17bGpLd6ssN1VMPf8c+jG8L3NeCnMdF+Ra3fRa9dft39/LuZ/3vwHoHrqGmQFafmiQw6eyzMxS05K4bL9uA+SKUQzCnSDkqOGokXyJvbgJ/BHI+qvY69//4rl20NsmK2ou2dTsyIALv/91/8n3P2Aao71WFGi8KKv1fRC5+J67Q/507/E/SOshqN5TsmYIjVt+kcjAx98iz/4SaojbIV1rexE7/C29HcYD/DX4a0rBOF5VTu7omsb11L/AWcVlcVZHSsqGuXLLp9ha8I//w3Mv+T4Ew7nTBsmgapoCrNFObIcN4pf/Ob/mrvHTGqqgAupL8qWjWPS9m/31jAe4DjA+4+uCoQoT/zOzlrNd3qd4SdphFxsUvYwGWbTWtISc3wNOWH+kHBMfc6kpmpwPgHWwqaSUG2ZWWheYOGQGaHB+eQ/kn6b3pOgLV+ODSn94wDvr8Bvb70/LLuiPPEr8OGVWfDmr45PZyccEmsVXZGe1pRNX9SU5+AVQkNTIVPCHF/jGmyDC9j4R9LfWcQvfiETmgMMUCMN1uNCakkweZsowdYobiMSlnKA93u7NzTXlSfe+SVbfnPQXmg9LpYAQxpwEtONyEyaueWM4FPjjyjG3uOaFmBTWDNgBXGEiQpsaWhnAqIijB07Dlsy3fUGeP989xbWkyf+FF2SNEtT1E0f4DYYVlxFlbaSMPIRMk/3iMU5pME2SIWJvjckciebkQuIRRyhUvkHg/iUljG5kzVog5hV7vIlCuBrmlhvgPfNHQM8lCf+FEGsYbMIBC0qC9a0uuy2wLXVbLBaP5kjHokCRxapkQyzI4QEcwgYHRZBp+XEFTqXFuNVzMtjXLJgX4gAid24Hjwc4N3dtVSe+NNiwTrzH4WVUOlDobUqr1FuAgYllc8pmzoVrELRHSIW8ViPxNy4xwjBpyR55I6J220qQTZYR4guvUICJiSpr9gFFle4RcF/OMB7BRiX8sSfhpNSO3lvEZCQfLUVTKT78Ek1LRLhWN+yLyTnp8qWUZ46b6vxdRGXfHVqx3eI75YaLa4iNNiK4NOW7wPW6lhbSOF9/M9qw8e/aoB3d156qTzxp8pXx5BKAsYSTOIIiPkp68GmTq7sZtvyzBQaRLNxIZ+paozHWoLFeExIhRBrWitHCAHrCF7/thhD8JhYz84wg93QRV88wLuLY8zF8sQ36qF1J455bOlgnELfshKVxYOXKVuKx0jaj22sczTQqPqtV/XDgpswmGTWWMSDw3ssyUunLLrVPGjYRsH5ggHeHSWiV8kT33ycFSfMgkoOK8apCye0J6VW6GOYvffgU9RWsukEi2kUV2nl4dOYUzRik9p7bcA4ggdJ53LxKcEe17B1R8eqAd7dOepV8sTXf5lhejoL85hUdhDdknPtKHFhljOT+bdq0hxbm35p2nc8+Ja1Iw+tJykgp0EWuAAZYwMVwac5KzYMslhvgHdHRrxKnvhTYcfKsxTxtTETkjHO7rr3zjoV25lAQHrqpV7bTiy2aXMmUhTBnKS91jhtR3GEoF0oLnWhWNnYgtcc4N0FxlcgT7yz3TgNIKkscx9jtV1ZKpWW+Ub1tc1eOv5ucdgpx+FJy9pgbLE7xDyXb/f+hLHVGeitHOi6A7ybo3sF8sS7w7cgdk0nJaOn3hLj3uyD0Zp5pazFIUXUpuTTU18d1EPkDoX8SkmWTnVIozEdbTcZjoqxhNHf1JrSS/AcvHjZ/SMHhL/7i5z+POsTUh/8BvNfYMTA8n+yU/MlTZxSJDRStqvEuLQKWwDctMTQogUDyQRoTQG5Kc6oQRE1yV1jCA7ri7jdZyK0sYTRjCR0Hnnd+y7nHxNgTULqw+8wj0mQKxpYvhjm9uSUxg+TTy7s2GtLUGcywhXSKZN275GsqlclX90J6bRI1aouxmgL7Q0Nen5ziM80SqMIo8cSOo+8XplT/5DHNWsSUr/6lLN/QQ3rDyzLruEW5enpf7KqZoShEduuSFOV7DLX7Ye+GmXb6/hnNNqKsVXuMDFpb9Y9eH3C6NGEzuOuI3gpMH/I6e+zDiH1fXi15t3vA1czsLws0TGEtmPEJdiiFPwlwKbgLHAFk4P6ZyPdymYYHGE0dutsChQBl2JcBFlrEkY/N5bQeXQ18gjunuMfMfsBlxJSx3niO485fwO4fGD5T/+3fPQqkneWVdwnw/3bMPkW9Wbqg+iC765Zk+xcT98ibKZc2EdgHcLoF8cSOo/Oc8fS+OyEULF4g4sJqXVcmfMfsc7A8v1/yfGXmL9I6Fn5pRwZhsPv0TxFNlAfZCvG+Oohi82UC5f/2IsJo0cTOm9YrDoKhFPEUr/LBYTUNht9zelHXDqwfPCIw4owp3mOcIQcLttWXFe3VZ/j5H3cIc0G6oPbCR+6Y2xF2EC5cGUm6wKC5tGEzhsWqw5hNidUiKX5gFWE1GXh4/Qplw4sVzOmx9QxU78g3EF6wnZlEN4FzJ1QPSLEZz1KfXC7vd8ssGdIbNUYpVx4UapyFUHzJoTOo1McSkeNn1M5MDQfs4qQuhhX5vQZFw8suwWTcyYTgioISk2YdmkhehG4PkE7w51inyAGGaU+uCXADabGzJR1fn3lwkty0asIo8cROm9Vy1g0yDxxtPvHDAmpu+PKnM8Ix1wwsGw91YJqhteaWgjYBmmQiebmSpwKKzE19hx7jkzSWOm66oPbzZ8Yj6kxVSpYjVAuvLzYMCRo3oTQecOOjjgi3NQ4l9K5/hOGhNTdcWVOTrlgYNkEXINbpCkBRyqhp+LdRB3g0OU6rMfW2HPCFFMV9nSp+uB2woepdbLBuJQyaw/ZFysXrlXwHxI0b0LovEkiOpXGA1Ijagf+KUNC6rKNa9bQnLFqYNkEnMc1uJrg2u64ELPBHpkgWbmwKpJoDhMwNbbGzAp7Yg31wS2T5rGtzit59PrKhesWG550CZpHEzpv2NGRaxlNjbMqpmEIzygJqQfjypycs2pg2cS2RY9r8HUqkqdEgKTWtWTKoRvOBPDYBltja2SO0RGjy9UHtxwRjA11ujbKF+ti5cIR9eCnxUg6owidtyoU5tK4NLji5Q3HCtiyF2IqLGYsHViOXTXOYxucDqG0HyttqYAKqYo3KTY1ekyDXRAm2AWh9JmsVh/ccg9WJ2E8YjG201sPq5ULxxX8n3XLXuMInbft2mk80rRGjCGctJ8/GFdmEQ9Ug4FlE1ll1Y7jtiraqm5Fe04VV8lvSVBL8hiPrfFVd8+7QH3Qbu2ipTVi8cvSGivc9cj8yvH11YMHdNSERtuOslM97feYFOPKzGcsI4zW0YGAbTAOaxCnxdfiYUmVWslxiIblCeAYr9VYR1gM7GmoPrilunSxxeT3DN/2eBQ9H11+nk1adn6VK71+5+Jfct4/el10/7KBZfNryUunWSCPxPECk1rdOv1WVSrQmpC+Tl46YD3ikQYcpunSQgzVB2VHFhxHVGKDgMEY5GLlQnP7FMDzw7IacAWnO6sBr12u+XanW2AO0wQ8pknnFhsL7KYIqhkEPmEXFkwaN5KQphbkUmG72wgw7WSm9RiL9QT925hkjiVIIhphFS9HKI6/8QAjlpXqg9W2C0apyaVDwKQwrwLY3j6ADR13ZyUNByQXHQu6RY09Hu6zMqXRaNZGS/KEJs0cJEe9VH1QdvBSJv9h09eiRmy0V2uJcqHcShcdvbSNg5fxkenkVprXM9rDVnX24/y9MVtncvbKY706anNl3ASll9a43UiacVquXGhvq4s2FP62NGKfQLIQYu9q1WmdMfmUrDGt8eDS0cXozH/fjmUH6Jruvm50hBDSaEU/2Ru2LEN/dl006TSc/g7tfJERxGMsgDUEr104pfWH9lQaN+M4KWQjwZbVc2rZVNHsyHal23wZtIs2JJqtIc/WLXXRFCpJkfE9jvWlfFbsNQ9pP5ZBS0zKh4R0aMFj1IjTcTnvi0Zz2rt7NdvQb2mgbju1plsH8MmbnEk7KbK0b+wC2iy3aX3szW8xeZvDwET6hWZYwqTXSSG+wMETKum0Dq/q+x62gt2ua2ppAo309TRk9TPazfV3qL9H8z7uhGqGqxNVg/FKx0HBl9OVUORn8Q8Jx9gFttGQUDr3tzcXX9xGgN0EpzN9mdZ3GATtPhL+CjxFDmkeEU6x56kqZRusLzALXVqkCN7zMEcqwjmywDQ6OhyUe0Xao1Qpyncrg6wKp9XfWDsaZplElvQ/b3sdweeghorwBDlHzgk1JmMc/wiERICVy2VJFdMjFuLQSp3S0W3+sngt2njwNgLssFGVQdJ0tu0KH4ky1LW4yrbkuaA6Iy9oz/qEMMXMMDWyIHhsAyFZc2peV9hc7kiKvfULxCl9iddfRK1f8kk9qvbdOoBtOg7ZkOZ5MsGrSHsokgLXUp9y88smniwWyuFSIRVmjplga3yD8Uij5QS1ZiM4U3Qw5QlSm2bXjFe6jzzBFtpg+/YBbLAWG7OPynNjlCw65fukGNdkJRf7yM1fOxVzbxOJVocFoYIaGwH22mIQkrvu1E2nGuebxIgW9U9TSiukPGU+Lt++c3DJPKhyhEEbXCQLUpae2exiKy6tMPe9mDRBFCEMTWrtwxN8qvuGnt6MoihKWS5NSyBhbH8StXoAz8PLOrRgLtOT/+4vcu+7vDLnqNvztOq7fmd8sMmY9Xzn1zj8Dq8+XVdu2Nv0IIySgEdQo3xVHps3Q5i3fLFsV4aiqzAiBhbgMDEd1uh8qZZ+lwhjkgokkOIv4xNJmyncdfUUzgB4oFMBtiu71Xumpz/P+cfUP+SlwFExwWW62r7b+LSPxqxn/gvMZ5z9C16t15UbNlq+jbGJtco7p8wbYlL4alSyfWdeuu0j7JA3JFNuVAwtst7F7FhWBbPFNKIUORndWtLraFLmMu7KFVDDOzqkeaiN33YAW/r76wR4XDN/yN1z7hejPau06EddkS/6XThfcz1fI/4K736fO48vlxt2PXJYFaeUkFS8U15XE3428xdtn2kc8GQlf1vkIaNRRnOMvLTWrZbElEHeLWi1o0dlKPAh1MVgbbVquPJ5+Cr8LU5/H/+I2QlHIU2ClXM9G8v7Rr7oc/hozfUUgsPnb3D+I+7WF8kNO92GY0SNvuxiE+2Bt8prVJTkzE64sfOstxuwfxUUoyk8VjcTlsqe2qITSFoSj6Epd4KsT6BZOWmtgE3hBfir8IzZDwgV4ZTZvD8VvPHERo8v+vL1DASHTz/i9OlKueHDjK5Rnx/JB1Vb1ioXdBra16dmt7dgik10yA/FwJSVY6XjA3oy4SqM2frqDPPSRMex9qs3XQtoWxMj7/Er8GWYsXgjaVz4OYumP2+9kbxvny/6kvWsEBw+fcb5bInc8APdhpOSs01tEqIkoiZjbAqKMruLbJYddHuHFRIyJcbdEdbl2sVLaySygunutBg96Y2/JjKRCdyHV+AEFtTvIpbKIXOamknYSiB6KV/0JetZITgcjjk5ZdaskBtWO86UF0ap6ozGXJk2WNiRUlCPFir66lzdm/SLSuK7EUdPz8f1z29Skq6F1fXg8+5UVR6bszncP4Tn4KUkkdJ8UFCY1zR1i8RmL/qQL3rlei4THG7OODlnKko4oI01kd3CaM08Ia18kC3GNoVaO9iDh+hWxSyTXFABXoau7Q6q9OxYg/OVEMw6jdbtSrJ9cBcewGmaZmg+bvkUnUUaGr+ZfnMH45Ivevl61hMcXsxYLFTu1hTm2zViCp7u0o5l+2PSUh9bDj6FgYypufBDhqK2+oXkiuHFHR3zfj+9PtA8oR0xnqX8qn+sx3bFODSbbF0X8EUvWQ8jBIcjo5bRmLOljDNtcqNtOe756h3l0VhKa9hDd2l1eqmsnh0MNMT/Cqnx6BInumhLT8luljzQ53RiJeA/0dxe5NK0o2fA1+GLXr6eNQWHNUOJssQaTRlGpLHKL9fD+IrQzTOMZS9fNQD4AnRNVxvTdjC+fJdcDDWQcyB00B0t9BDwTxXgaAfzDZ/DBXzRnfWMFRwuNqocOmX6OKNkY63h5n/fFcB28McVHqnXZVI27K0i4rDLNE9lDKV/rT+udVbD8dFFu2GGZ8mOt0kAXcoX3ZkIWVtw+MNf5NjR2FbivROHmhV1/pj2egv/fMGIOWTIWrV3Av8N9imV9IWml36H6cUjqEWNv9aNc+veb2sH46PRaHSuMBxvtW+twxctq0z+QsHhux8Q7rCY4Ct8lqsx7c6Sy0dl5T89rIeEuZKoVctIk1hNpfavER6yyH1Vvm3MbsUHy4ab4hWr/OZPcsRBphnaV65/ZcdYPNNwsjN/djlf9NqCw9U5ExCPcdhKxUgLSmfROpLp4WSUr8ojdwbncbvCf+a/YzRaEc6QOvXcGO256TXc5Lab9POvB+AWY7PigWYjzhifbovuunzRawsO24ZqQQAqguBtmpmPB7ysXJfyDDaV/aPGillgz1MdQg4u5MYaEtBNNHFjkRlSpd65lp4hd2AVPTfbV7FGpyIOfmNc/XVsPfg7vzaS/3nkvLL593ANLvMuRMGpQIhiF7kUEW9QDpAUbTWYBcbp4WpacHHY1aacqQyjGZS9HI3yCBT9kUZJhVOD+zUDvEH9ddR11fzPcTDQ5TlgB0KwqdXSavk9BC0pKp0WmcuowSw07VXmXC5guzSa4p0UvRw2lbDiYUx0ExJJRzWzi6Gm8cnEkfXXsdcG/M/jAJa0+bmCgdmQ9CYlNlSYZOKixmRsgiFxkrmW4l3KdFKv1DM8tk6WxPYJZhUUzcd8Kdtgrw/gkfXXDT7+avmfVak32qhtkg6NVdUS5wgkru1YzIkSduTW1FDwVWV3JQVJVuieTc0y4iDpFwc7/BvSalvKdQM8sv662cevz/+8sQVnjVAT0W2wLllw1JiMhJRxgDjCjLQsOzSFSgZqx7lAW1JW0e03yAD3asC+GD3NbQhbe+mN5GXH1F83KDOM4n/e5JIuH4NpdQARrFPBVptUNcjj4cVMcFSRTE2NpR1LEYbYMmfWpXgP9KejaPsLUhuvLCsVXznAG9dfx9SR1ud/3hZdCLHb1GMdPqRJgqDmm76mHbvOXDtiO2QPUcKo/TWkQ0i2JFXpBoo7vij1i1Lp3ADAo+qvG3V0rM//vFnnTE4hxd5Ka/Cor5YEdsLVJyKtDgVoHgtW11pWSjolPNMnrlrVj9Fv2Qn60twMwKPqr+N/wvr8z5tZcDsDrv06tkqyzESM85Ycv6XBWA2birlNCXrI6VbD2lx2L0vQO0QVTVVLH4SE67fgsfVXv8n7sz7/85Z7cMtbE6f088wSaR4kCkCm10s6pKbJhfqiUNGLq+0gLWC6eUAZFPnLjwqtKd8EwGvWX59t7iPW4X/eAN1svgRVSY990YZg06BD1ohLMtyFTI4pKTJsS9xREq9EOaPWiO2gpms7397x6nQJkbh+Fz2q/rqRROX6/M8bJrqlVW4l6JEptKeUFuMYUbtCQ7CIttpGc6MY93x1r1vgAnRXvY5cvwWPqb9uWQm+lP95QxdNMeWhOq1x0Db55C7GcUv2ZUuN6n8iKzsvOxibC//Yfs9Na8r2Rlz02vXXDT57FP/zJi66/EJSmsJKa8QxnoqW3VLQ+jZVUtJwJ8PNX1NQCwfNgdhhHD9on7PdRdrdGPF28rJr1F+3LBdeyv+8yYfLoMYet1vX4upNAjVvwOUWnlNXJXlkzk5Il6kqeoiL0C07qno+/CYBXq/+utlnsz7/Mzvy0tmI4zm4ag23PRN3t/CWryoUVJGm+5+K8RJ0V8Hc88/XHUX/HfiAq7t+BH+x6v8t438enWmdJwFA6ZINriLGKv/95f8lT9/FnyA1NMVEvQyaXuu+gz36f/DD73E4pwqpLcvm/o0Vle78n//+L/NPvoefp1pTJye6e4A/D082FERa5/opeH9zpvh13cNm19/4v/LDe5xMWTi8I0Ta0qKlK27AS/v3/r+/x/2GO9K2c7kVMonDpq7//jc5PKCxeNPpFVzaRr01wF8C4Pu76hXuX18H4LduTr79guuFD3n5BHfI+ZRFhY8w29TYhbbLi/bvBdqKE4fUgg1pBKnV3FEaCWOWyA+m3WpORZr/j+9TKJtW8yBTF2/ZEODI9/QavHkVdGFp/Pjn4Q+u5hXapsP5sOH+OXXA1LiKuqJxiMNbhTkbdJTCy4llEt6NnqRT4dhg1V3nbdrm6dYMecA1yTOL4PWTE9L5VzPFlLBCvlG58AhehnN4uHsAYinyJ+AZ/NkVvELbfOBUuOO5syBIEtiqHU1k9XeISX5bsimrkUUhnGDxourN8SgUsCZVtKyGbyGzHXdjOhsAvOAswSRyIBddRdEZWP6GZhNK/yjwew9ehBo+3jEADu7Ay2n8mDc+TS7awUHg0OMzR0LABhqLD4hJEh/BEGyBdGlSJoXYXtr+3HS4ijzVpgi0paWXtdruGTknXBz+11qT1Q2inxaTzQCO46P3lfLpyS4fou2PH/PupwZgCxNhGlj4IvUuWEsTkqMWm6i4xCSMc9N1RDQoCVcuGItJ/MRWefais+3synowi/dESgJjkilnWnBTGvRWmaw8oR15257t7CHmCf8HOn7cwI8+NQBXMBEmAa8PMRemrNCEhLGEhDQKcGZWS319BX9PFBEwGTbRBhLbDcaV3drFcDqk5kCTd2JF1Wp0HraqBx8U0wwBTnbpCadwBA/gTH/CDrcCs93LV8E0YlmmcyQRQnjBa8JESmGUfIjK/7fkaDJpmD2QptFNVJU1bbtIAjjWQizepOKptRjbzR9Kag6xZmMLLjHOtcLT3Tx9o/0EcTT1XN3E45u24AiwEypDJXihKjQxjLprEwcmRKclaDNZCVqr/V8mYWyFADbusiY5hvgFoU2vio49RgJLn5OsReRFN6tabeetiiy0V7KFHT3HyZLx491u95sn4K1QQSPKM9hNT0wMVvAWbzDSVdrKw4zRjZMyJIHkfq1VAVCDl/bUhNKlGq0zGr05+YAceXVPCttVk0oqjVwMPt+BBefx4yPtGVkUsqY3CHDPiCM5ngupUwCdbkpd8kbPrCWHhkmtIKLEetF2499eS1jZlIPGYnlcPXeM2KD9vLS0bW3ktYNqUllpKLn5ZrsxlIzxvDu5eHxzGLctkZLEY4PgSOg2IUVVcUONzUDBEpRaMoXNmUc0tFZrTZquiLyKxrSm3DvIW9Fil+AkhXu5PhEPx9mUNwqypDvZWdKlhIJQY7vn2OsnmBeOWnYZ0m1iwbbw1U60by5om47iHRV6fOgzjMf/DAZrlP40Z7syxpLK0lJ0gqaAK1c2KQKu7tabTXkLFz0sCftuwX++MyNeNn68k5Buq23YQhUh0SNTJa1ioQ0p4nUG2y0XilF1JqODqdImloPS4Bp111DEWT0jJjVv95uX9BBV7eB3bUWcu0acSVM23YZdd8R8UbQUxJ9wdu3oMuhdt929ME+mh6JXJ8di2RxbTi6TbrDquqV4aUKR2iwT6aZbyOwEXN3DUsWr8Hn4EhwNyHuXHh7/pdaUjtR7vnDh/d8c9xD/s5f501eQ1+CuDiCvGhk1AN/4Tf74RfxPwD3toLarR0zNtsnPzmS64KIRk861dMWCU8ArasG9T9H0ZBpsDGnjtAOM2+/LuIb2iIUGXNgl5ZmKD/Tw8TlaAuihaFP5yrw18v4x1898zIdP+DDAX1bM3GAMvPgRP/cJn3zCW013nrhHkrITyvYuwOUkcHuKlRSW5C6rzIdY4ppnF7J8aAJbQepgbJYBjCY9usGXDKQxq7RZfh9eg5d1UHMVATRaD/4BHK93/1iAgYZ/+jqPn8Dn4UExmWrpa3+ZOK6MvM3bjwfzxNWA2dhs8+51XHSPJiaAhGSpWevEs5xHLXcEGFXYiCONySH3fPWq93JIsBiSWvWyc3CAN+EcXoT7rCSANloPPoa31rt/5PUA/gp8Q/jDD3hyrjzlR8VkanfOvB1XPubt17vzxAfdSVbD1pzAnfgyF3ycadOTOTXhpEUoLC1HZyNGW3dtmjeXgr2r56JNmRwdNNWaQVBddd6rh4MhviEB9EFRD/7RGvePvCbwAL4Mx/D6M541hHO4D3e7g6PafdcZVw689z7NGTwo5om7A8sPhccT6qKcl9NJl9aM/9kX+e59Hh1yPqGuCCZxuITcsmNaJ5F7d0q6J3H48TO1/+M57085q2icdu2U+W36Ldllz9Agiv4YGljoEN908EzvDOrBF98/vtJwCC/BF2AG75xxEmjmMIcjxbjoaxqOK3/4hPOZzhMPBpYPG44CM0dTVm1LjLtUWWVz1Bcf8tEx0zs8O2A2YVHRxKYOiy/aOVoAaMu0i7ubu43njjmd4ibMHU1sIDHaQNKrZND/FZYdk54oCXetjq7E7IVl9eAL7t+oHnwXXtLx44czzoRFHBztYVwtH1d+NOMkupZ5MTM+gUmq90X+Bh9zjRlmaQ+m7YMqUL/veemcecAtOJ0yq1JnVlN27di2E0+Klp1tAJ4KRw1eMI7aJjsO3R8kPSI3fUFXnIOfdQe86sIIVtWDL7h//Ok6vj8vwDk08NEcI8zz7OhBy+WwalzZeZ4+0XniRfst9pAJqQHDGLzVQ2pheZnnv1OWhwO43/AgcvAEXEVVpa4db9sGvNK8wjaENHkfFQ4Ci5i7dqnQlPoLQrHXZDvO3BIXZbJOBrOaEbML6sFL798I4FhKihjHMsPjBUZYCMFr6nvaArxqXPn4lCa+cHfSa2cP27g3Z3ziYTRrcbQNGLQmGF3F3cBdzzzX7AILx0IB9rbwn9kx2G1FW3Inic+ZLIsVvKR8Zwfj0l1fkqo8LWY1M3IX14OX3r9RKTIO+d9XzAI8qRPGPn/4NC2n6o4rN8XJ82TOIvuVA8zLKUHRFgBCetlDZlqR1gLKjS39xoE7Bt8UvA6BxuEDjU3tFsEijgA+615tmZkXKqiEENrh41iLDDZNq4pKTWR3LZfnos81LOuNa15cD956vLMsJd1rqYp51gDUQqMYm2XsxnUhD2jg1DM7SeuJxxgrmpfISSXVIJIS5qJJSvJPEQ49DQTVIbYWJ9QWa/E2+c/oPK1drmC7WSfJRNKBO5Yjvcp7Gc3dmmI/Xh1kDTEuiSnWqQf37h+fTMhGnDf6dsS8SQfQWlqqwXXGlc/PEZ/SC5mtzIV0nAshlQdM/LvUtYutrEZ/Y+EAFtq1k28zQhOwLr1AIeANzhF8t9qzTdZf2qRKO6MWE9ohBYwibbOmrFtNmg3mcS+tB28xv2uKd/agYCvOP+GkSc+0lr7RXzyufL7QbkUpjLjEWFLqOIkAGu2B0tNlO9Eau2W1qcOUvVRgKzypKIQZ5KI3q0MLzqTNRYqiZOqmtqloIRlmkBHVpHmRYV6/HixbO6UC47KOFJnoMrVyr7wYz+SlW6GUaghYbY1I6kkxA2W1fSJokUdSh2LQ1GAimRGm0MT+uu57H5l7QgOWxERpO9moLRPgTtquWCfFlGlIjQaRly9odmzMOWY+IBO5tB4sW/0+VWGUh32qYk79EidWKrjWuiLpiVNGFWFRJVktyeXWmbgBBzVl8anPuXyNJlBJOlKLTgAbi/EYHVHxWiDaVR06GnHQNpJcWcK2jJtiCfG2sEHLzuI66sGrMK47nPIInPnu799935aOK2cvmvubrE38ZzZjrELCmXM2hM7UcpXD2oC3+ECVp7xtIuxptJ0jUr3sBmBS47TVxlvJ1Sqb/E0uLdvLj0lLr29ypdd/eMX3f6lrxGlKwKQxEGvw0qHbkbwrF3uHKwVENbIV2wZ13kNEF6zD+x24aLNMfDTCbDPnEikZFyTNttxWBXDaBuM8KtI2rmaMdUY7cXcUPstqTGvBGSrFWIpNMfbdea990bvAOC1YX0qbc6smDS1mPxSJoW4fwEXvjMmhlijDRq6qale6aJEuFGoppYDoBELQzLBuh/mZNx7jkinv0EtnUp50lO9hbNK57lZaMAWuWR5Yo9/kYwcYI0t4gWM47Umnl3YmpeBPqSyNp3K7s2DSAS/39KRuEN2bS4xvowV3dFRMx/VFcp2Yp8w2nTO9hCXtHG1kF1L4KlrJr2wKfyq77R7MKpFKzWlY9UkhYxyHWW6nBWPaudvEAl3CGcNpSXPZ6R9BbBtIl6cHL3gIBi+42CYXqCx1gfGWe7Ap0h3luyXdt1MKy4YUT9xSF01G16YEdWsouW9mgDHd3veyA97H+Ya47ZmEbqMY72oPztCGvK0onL44AvgC49saZKkWRz4veWljE1FHjbRJaWv6ZKKtl875h4CziFCZhG5rx7tefsl0aRT1bMHZjm8dwL/6u7wCRysaQblQoG5yAQN5zpatMNY/+yf8z+GLcH/Qn0iX2W2oEfXP4GvwQHuIL9AYGnaO3zqAX6946nkgqZNnUhx43DIdQtMFeOPrgy/y3Yd85HlJWwjLFkU3kFwq28xPnuPhMWeS+tDLV9Otllq7pQCf3uXJDN9wFDiUTgefHaiYbdfi3b3u8+iY6TnzhgehI1LTe8lcd7s1wJSzKbahCRxKKztTLXstGAiu3a6rPuQs5pk9TWAan5f0BZmGf7Ylxzzk/A7PAs4QPPPAHeFQ2hbFHszlgZuKZsJcUmbDC40sEU403cEjczstOEypa+YxevL4QBC8oRYqWdK6b7sK25tfE+oDZgtOQ2Jg8T41HGcBE6fTWHn4JtHcu9S7uYgU5KSCkl/mcnq+5/YBXOEr6lCUCwOTOM1taOI8mSxx1NsCXBEmLKbMAg5MkwbLmpBaFOPrNSlO2HnLiEqW3tHEwd8AeiQLmn+2gxjC3k6AxREqvKcJbTEzlpLiw4rNZK6oJdidbMMGX9FULKr0AkW+2qDEPBNNm5QAt2Ik2nftNWHetubosHLo2nG4vQA7GkcVCgVCgaDixHqo9UUn1A6OshapaNR/LPRYFV8siT1cCtJE0k/3WtaNSuUZYKPnsVIW0xXWnMUxq5+En4Kvw/MqQmVXnAXj9Z+9zM98zM/Agy7F/qqj2Nh67b8HjFnPP3iBn/tkpdzwEJX/whIcQUXOaikeliCRGUk7tiwF0rItwMEhjkZ309hikFoRAmLTpEXWuHS6y+am/KB/fM50aLEhGnSMwkpxzOov4H0AvgovwJ1iGzDLtJn/9BU+fAINfwUe6FHSLhu83viV/+/HrOePX+STT2B9uWGbrMHHLldRBlhS/CJQmcRxJFqZica01XixAZsYiH1uolZxLrR/SgxVIJjkpQP4PE9sE59LKLr7kltSBogS5tyszzH8Fvw8/AS8rNOg0xUS9fIaHwb+6et8Q/gyvKRjf5OusOzGx8evA/BP4IP11uN/grca5O0lcsPLJ5YjwI4QkJBOHa0WdMZYGxPbh2W2nR9v3WxEWqgp/G3+6VZbRLSAAZ3BhdhAaUL33VUSw9yjEsvbaQ9u4A/gGXwZXoEHOuU1GSj2chf+Mo+f8IcfcAxfIKVmyunRbYQVnoevwgfw3TXXcw++xNuP4fhyueEUNttEduRVaDttddoP0eSxLe2LENk6itYxlrxBNBYrNNKSQmeaLcm9c8UsaB5WyO6675yyQIAWSDpBVoA/gxmcwEvwoDv0m58UE7gHn+fJOa8/Ywan8EKRfjsopF83eCglX/Sfr7OeaRoQfvt1CGvIDccH5BCvw1sWIzRGC/66t0VTcLZQZtm6PlAasbOJ9iwWtUo7biktTSIPxnR24jxP1ZKaqq+2RcXM9OrBAm/AAs7hDJ5bNmGb+KIfwCs8a3jnjBrOFeMjHSCdbKr+2uOLfnOd9eiA8Hvvwwq54VbP2OqwkB48Ytc4YEOiH2vTXqodabfWEOzso4qxdbqD5L6tbtNPECqbhnA708DZH4QOJUXqScmUlks7Ot6FBuZw3n2mEbaUX7kDzxHOOQk8nKWMzAzu6ZZ8sOFw4RK+6PcuXo9tB4SbMz58ApfKDXf3szjNIIbGpD5TKTRxGkEMLjLl+K3wlWXBsCUxIDU+jbOiysESqAy1MGUJpXgwbTWzNOVEziIXZrJ+VIztl1PUBxTSo0dwn2bOmfDRPD3TRTGlfbCJvO9KvuhL1hMHhB9wPuPRLGHcdOWG2xc0U+5bQtAJT0nRTewXL1pgk2+rZAdeWmz3jxAqfNQQdzTlbF8uJ5ecEIWvTkevAHpwz7w78QujlD/Lr491bD8/1vhM2yrUQRrWXNQY4fGilfctMWYjL72UL/qS9eiA8EmN88nbNdour+PBbbAjOjIa4iBhfFg6rxeKdEGcL6p3EWR1Qq2Qkhs2DrnkRnmN9tG2EAqmgPw6hoL7Oza7B+3SCrR9tRftko+Lsf2F/mkTndN2LmzuMcKTuj/mX2+4Va3ki16+nnJY+S7MefpkidxwnV+4wkXH8TKnX0tsYzYp29DOOoSW1nf7nTh2akYiWmcJOuTidSaqESrTYpwjJJNVGQr+rLI7WsqerHW6Kp/oM2pKuV7T1QY9gjqlZp41/WfKpl56FV/0kvXQFRyeQ83xaTu5E8p5dNP3dUF34ihyI3GSpeCsywSh22ZJdWto9winhqifb7VRvgktxp13vyjrS0EjvrRfZ62uyqddSWaWYlwTPAtJZ2oZ3j/Sgi/mi+6vpzesfAcWNA0n8xVyw90GVFGuZjTXEQy+6GfLGLMLL523f5E0OmxVjDoOuRiH91RKU+vtoCtH7TgmvBLvtFXWLW15H9GTdVw8ow4IlRLeHECN9ym1e9K0I+Cbnhgv4Yu+aD2HaQJ80XDqOzSGAV4+4yCqBxrsJAX6ZTIoX36QnvzhhzzMfFW2dZVLOJfo0zbce5OvwXMFaZ81mOnlTVXpDZsQNuoYWveketKb5+6JOOsgX+NTm7H49fUTlx+WLuWL7qxnOFh4BxpmJx0p2gDzA/BUARuS6phR+pUsY7MMboAHx5xNsSVfVZcYSwqCKrqon7zM+8ecCkeS4nm3rINuaWvVNnMRI1IRpxTqx8PZUZ0Br/UEduo3B3hNvmgZfs9gQPj8vIOxd2kndir3awvJ6BLvoUuOfFWNYB0LR1OQJoUySKb9IlOBx74q1+ADC2G6rOdmFdJcD8BkfualA+BdjOOzP9uUhGUEX/TwhZsUduwRr8wNuXKurCixLBgpQI0mDbJr9dIqUuV+92ngkJZ7xduCk2yZKbfWrH1VBiTg9VdzsgRjW3CVXCvAwDd+c1z9dWw9+B+8MJL/eY15ZQ/HqvTwVdsZn5WQsgRRnMaWaecu3jFvMBEmgg+FJFZsnSl0zjB9OqPYaBD7qmoVyImFvzi41usesV0julaAR9dfR15Xzv9sEruRDyk1nb+QaLU67T885GTls6YgcY+UiMa25M/pwGrbCfzkvR3e0jjtuaFtnwuagHTSb5y7boBH119HXhvwP487jJLsLJ4XnUkHX5sLbS61dpiAXRoZSCrFJ+EjpeU3puVfitngYNo6PJrAigKktmwjyQdZpfq30mmtulaAx9Zfx15Xzv+cyeuiBFUs9zq8Kq+XB9a4PVvph3GV4E3y8HENJrN55H1X2p8VyqSKwVusJDKzXOZzplWdzBUFK9e+B4+uv468xvI/b5xtSAkBHQaPvtqWzllVvEOxPbuiE6+j2pvjcKsbvI7txnRErgfH7LdXqjq0IokKzga14GzQ23SSbCQvO6r+Or7SMIr/efOkkqSdMnj9mBx2DRsiY29Uj6+qK9ZrssCKaptR6HKURdwUYeUWA2kPzVKQO8ku2nU3Anhs/XWkBx3F/7wJtCTTTIKftthue1ty9xvNYLY/zo5KSbIuKbXpbEdSyeRyYdAIwKY2neyoc3+k1XUaufYga3T9daMUx/r8z1s10ITknIO0kuoMt+TB8jK0lpayqqjsJ2qtXAYwBU932zinimgmd6mTRDnQfr88q36NAI+tv24E8Pr8zxtasBqx0+xHH9HhlrwsxxNUfKOHQaZBITNf0uccj8GXiVmXAuPEAKSdN/4GLHhs/XWj92dN/uetNuBMnVR+XWDc25JLjo5Mg5IZIq226tmCsip2zZliL213YrTlL2hcFjpCduyim3M7/eB16q/blQsv5X/esDRbtJeabLIosWy3ycavwLhtxdWzbMmHiBTiVjJo6lCLjXZsi7p9PEPnsq6X6wd4bP11i0rD5fzPm/0A6brrIsllenZs0lCJlU4abakR59enZKrKe3BZihbTxlyZ2zl1+g0wvgmA166/bhwDrcn/7Ddz0eWZuJvfSESug6NzZsox3Z04FIxz0mUjMwVOOVTq1CQ0AhdbBGVdjG/CgsfUX7esJl3K/7ytWHRv683praW/8iDOCqWLLhpljDY1ZpzK75QiaZoOTpLKl60auHS/97oBXrv+umU9+FL+5+NtLFgjqVLCdbmj7pY5zPCPLOHNCwXGOcLquOhi8CmCWvbcuO73XmMUPab+ug3A6/A/78Bwe0bcS2+tgHn4J5pyS2WbOck0F51Vq3LcjhLvZ67p1ABbaL2H67bg78BfjKi/jr3+T/ABV3ilLmNXTI2SpvxWBtt6/Z//D0z/FXaGbSBgylzlsEGp+5//xrd4/ae4d8DUUjlslfIYS3t06HZpvfQtvv0N7AHWqtjP2pW08QD/FLy//da38vo8PNlKHf5y37Dxdfe/oj4kVIgFq3koLReSR76W/bx//n9k8jonZxzWTANVwEniDsg87sOSd/z7//PvMp3jQiptGVWFX2caezzAXwfgtzYUvbr0iozs32c3Uge7varH+CNE6cvEYmzbPZ9hMaYDdjK4V2iecf6EcEbdUDVUARda2KzO/JtCuDbNQB/iTeL0EG1JSO1jbXS+nLxtPMDPw1fh5+EPrgSEKE/8Gry5A73ui87AmxwdatyMEBCPNOCSKUeRZ2P6Myb5MRvgCHmA9ywsMifU+AYXcB6Xa5GibUC5TSyerxyh0j6QgLVpdyhfArRTTLqQjwe4HOD9s92D4Ap54odXAPBWLAwB02igG5Kkc+piN4lvODIFGAZgT+EO4Si1s7fjSR7vcQETUkRm9O+MXyo9OYhfe4xt9STQ2pcZRLayCV90b4D3jR0DYAfyxJ+eywg2IL7NTMXna7S/RpQ63JhWEM8U41ZyQGjwsVS0QBrEKLu8xwZsbi4wLcCT+OGidPIOCe1PiSc9Qt+go+vYqB7cG+B9d8cAD+WJPz0Am2gxXgU9IneOqDpAAXOsOltVuMzpdakJXrdPCzXiNVUpCeOos5cxnpQT39G+XVLhs1osQVvJKPZyNq8HDwd4d7pNDuWJPxVX7MSzqUDU6gfadKiNlUFTzLeFHHDlzO4kpa7aiKhBPGKwOqxsBAmYkOIpipyXcQSPlRTf+Tii0U3EJGaZsDER2qoB3h2hu0qe+NNwUooYU8y5mILbJe6OuX+2FTKy7bieTDAemaQyQ0CPthljSWO+xmFDIYiESjM5xKd6Ik5lvLq5GrQ3aCMLvmCA9wowLuWJb9xF59hVVP6O0CrBi3ZjZSNOvRy+I6klNVRJYRBaEzdN+imiUXQ8iVF8fsp+W4JXw7WISW7fDh7lptWkCwZ4d7QTXyBPfJMYK7SijjFppGnlIVJBJBYj7eUwtiP1IBXGI1XCsjNpbjENVpSAJ2hq2LTywEly3hUYazt31J8w2+aiLx3g3fohXixPfOMYm6zCGs9LVo9MoW3MCJE7R5u/WsOIjrqBoHUO0bJE9vxBpbhsd3+Nb4/vtPCZ4oZYCitNeYuC/8UDvDvy0qvkiW/cgqNqRyzqSZa/s0mqNGjtKOoTm14zZpUauiQgVfqtQiZjq7Q27JNaSK5ExRcrGCXO1FJYh6jR6CFqK7bZdQZ4t8g0rSlPfP1RdBtqaa9diqtzJkQ9duSryi2brQXbxDwbRUpFMBHjRj8+Nt7GDKgvph9okW7LX47gu0SpGnnFQ1S1lYldOsC7hYteR574ZuKs7Ei1lBsfdz7IZoxzzCVmmVqaSySzQbBVAWDek+N4jh9E/4VqZrJjPwiv9BC1XcvOWgO8275CVyBPvAtTVlDJfZkaZGU7NpqBogAj/xEHkeAuJihWYCxGN6e8+9JtSegFXF1TrhhLGP1fak3pebgPz192/8gB4d/6WT7+GdYnpH7hH/DJzzFiYPn/vjW0SgNpTNuPIZoAEZv8tlGw4+RLxy+ZjnKa5NdFoC7UaW0aduoYse6+bXg1DLg6UfRYwmhGEjqPvF75U558SANrElK/+MdpXvmqBpaXOa/MTZaa1DOcSiLaw9j0NNNst3c+63c7EKTpkvKHzu6bPbP0RkuHAVcbRY8ijP46MIbQeeT1mhA+5PV/inyDdQipf8LTvMXbwvoDy7IruDNVZKTfV4CTSRUYdybUCnGU7KUTDxLgCknqUm5aAW6/1p6eMsOYsphLzsHrE0Y/P5bQedx1F/4yPHnMB3/IOoTU9+BL8PhtjuFKBpZXnYNJxTuv+2XqolKR2UQgHhS5novuxVySJhBNRF3SoKK1XZbbXjVwWNyOjlqWJjrWJIy+P5bQedyldNScP+HZ61xKSK3jyrz+NiHG1hcOLL/+P+PDF2gOkekKGiNWKgJ+8Z/x8Iv4DdQHzcpZyF4v19I27w9/yPGDFQvmEpKtqv/TLiWMfn4sofMm9eAH8Ao0zzh7h4sJqYtxZd5/D7hkYPneDzl5idlzNHcIB0jVlQ+8ULzw/nc5/ojzl2juE0apD7LRnJxe04dMz2iOCFNtGFpTuXA5AhcTRo8mdN4kz30nVjEC4YTZQy4gpC7GlTlrePKhGsKKgeXpCYeO0MAd/GH7yKQUlXPLOasOH3FnSphjHuDvEu4gB8g66oNbtr6eMbFIA4fIBJkgayoXriw2XEDQPJrQeROAlY6aeYOcMf+IVYTU3XFlZufMHinGywaW3YLpObVBAsbjF4QJMsVUSayjk4voPsHJOQfPWDhCgDnmDl6XIRerD24HsGtw86RMHOLvVSHrKBdeVE26gKB5NKHzaIwLOmrqBWJYZDLhASG16c0Tn+CdRhWDgWXnqRZUTnPIHuMJTfLVpkoYy5CzylHVTGZMTwkGAo2HBlkQplrJX6U+uF1wZz2uwS1SQ12IqWaPuO4baZaEFBdukksJmkcTOm+YJSvoqPFzxFA/YUhIvWxcmSdPWTWwbAKVp6rxTtPFUZfKIwpzm4IoMfaYQLWgmlG5FME2gdBgm+J7J+rtS/XBbaVLsR7bpPQnpMFlo2doWaVceHk9+MkyguZNCJ1He+kuHTWyQAzNM5YSUg/GlTk9ZunAsg1qELVOhUSAK0LABIJHLKbqaEbHZLL1VA3VgqoiOKXYiS+HRyaEKgsfIqX64HYWbLRXy/qWoylIV9gudL1OWBNgBgTNmxA6b4txDT4gi3Ri7xFSLxtXpmmYnzAcWDZgY8d503LFogz5sbonDgkKcxGsWsE1OI+rcQtlgBBCSOKD1mtqYpIU8cTvBmAT0yZe+zUzeY92fYjTtGipXLhuR0ePoHk0ofNWBX+lo8Z7pAZDk8mEw5L7dVyZZoE/pTewbI6SNbiAL5xeygW4xPRuLCGbhcO4RIeTMFYHEJkYyEO9HmJfXMDEj/LaH781wHHZEtqSQ/69UnGpzH7LKIAZEDSPJnTesJTUa+rwTepI9dLJEawYV+ZkRn9g+QirD8vF8Mq0jFQ29js6kCS3E1+jZIhgPNanHdHFqFvPJLHqFwQqbIA4jhDxcNsOCCQLDomaL/dr5lyJaJU6FxPFjO3JOh3kVMcROo8u+C+jo05GjMF3P3/FuDLn5x2M04xXULPwaS6hBYki+MrMdZJSgPHlcB7nCR5bJ9Kr5ACUn9jk5kivdd8tk95SOGrtqu9lr2IhK65ZtEl7ZKrp7DrqwZfRUSN1el7+7NJxZbywOC8neNKTch5vsTEMNsoCCqHBCqIPRjIPkm0BjvFODGtto99rCl+d3wmHkW0FPdpZtC7MMcVtGFQjJLX5bdQ2+x9ypdc313uj8xlsrfuLgWXz1cRhZvJYX0iNVBRcVcmCXZs6aEf3RQF2WI/TcCbKmGU3IOoDJGDdDub0+hYckt6PlGu2BcxmhbTdj/klhccLGJMcqRjMJP1jW2ETqLSWJ/29MAoORluJ+6LPffBZbi5gqi5h6catQpmOT7/OFf5UorRpLzCqcMltBLhwd1are3kztrSzXO0LUbXRQcdLh/RdSZ+swRm819REDrtqzC4es6Gw4JCKlSnjYVpo0xeq33PrADbFLL3RuCmObVmPN+24kfa+AojDuM4umKe2QwCf6EN906HwjujaitDs5o0s1y+k3lgbT2W2i7FJdnwbLXhJUBq/9liTctSmFC/0OqUinb0QddTWamtjbHRFuWJJ6NpqZ8vO3fZJ37Db+2GkaPYLGHs7XTTdiFQJ68SkVJFVmY6McR5UycflNCsccHFaV9FNbR4NttLxw4pQ7wJd066Z0ohVbzihaxHVExd/ay04oxUKWt+AsdiQ9OUyZ2krzN19IZIwafSTFgIBnMV73ADj7V/K8u1MaY2sJp2HWm0f41tqwajEvdHWOJs510MaAqN4aoSiPCXtN2KSi46dUxHdaMquar82O1x5jqhDGvqmoE9LfxcY3zqA7/x3HA67r9ZG4O6Cuxu12/+TP+eLP+I+HErqDDCDVmBDO4larujNe7x8om2rMug0MX0rL1+IWwdwfR+p1TNTyNmVJ85ljWzbWuGv8/C7HD/izjkHNZNYlhZcUOKVzKFUxsxxN/kax+8zPWPSFKw80rJr9Tizyj3o1gEsdwgWGoxPezDdZ1TSENE1dLdNvuKL+I84nxKesZgxXVA1VA1OcL49dFlpFV5yJMhzyCmNQ+a4BqusPJ2bB+xo8V9u3x48VVIEPS/mc3DvAbXyoYr6VgDfh5do5hhHOCXMqBZUPhWYbWZECwVJljLgMUWOCB4MUuMaxGNUQDVI50TQ+S3kFgIcu2qKkNSHVoM0SHsgoZxP2d5HH8B9woOk4x5bPkKtAHucZsdykjxuIpbUrSILgrT8G7G5oCW+K0990o7E3T6AdW4TilH5kDjds+H64kS0mz24grtwlzDHBJqI8YJQExotPvoC4JBq0lEjjQkyBZ8oH2LnRsQ4Hu1QsgDTJbO8fQDnllitkxuVskoiKbRF9VwzMDvxHAdwB7mD9yCplhHFEyUWHx3WtwCbSMMTCUCcEmSGlg4gTXkHpZXWQ7kpznK3EmCHiXInqndkQjunG5kxTKEeGye7jWz9cyMR2mGiFQ15ENRBTbCp+Gh86vAyASdgmJq2MC6hoADQ3GosP0QHbnMHjyBQvQqfhy/BUbeHd5WY/G/9LK/8Ka8Jd7UFeNWEZvzPb458Dn8DGLOe3/wGL/4xP+HXlRt+M1PE2iLhR8t+lfgxsuh7AfO2AOf+owWhSZRYQbd622hbpKWKuU+XuvNzP0OseRDa+mObgDHJUSc/pKx31QdKffQ5OIJpt8GWjlgTwMc/w5MPCR/yl1XC2a2Yut54SvOtMev55Of45BOat9aWG27p2ZVORRvnEk1hqWMVUmqa7S2YtvlIpspuF1pt0syuZS2NV14mUidCSfzQzg+KqvIYCMljIx2YK2AO34fX4GWdu5xcIAb8MzTw+j/lyWM+Dw/gjs4GD6ehNgA48kX/AI7XXM/XAN4WHr+9ntywqoCakCqmKP0rmQrJJEErG2Upg1JObr01lKQy4jskWalKYfJ/EDLMpjNSHFEUAde2fltaDgmrNaWQ9+AAb8I5vKjz3L1n1LriB/BXkG/wwR9y/oRX4LlioHA4LzP2inzRx/DWmutRweFjeP3tNeSGlaE1Fde0OS11yOpmbIp2u/jF1n2RRZviJM0yBT3IZl2HWImKjQOxIyeU325b/qWyU9Moj1o07tS0G7qJDoGHg5m8yeCxMoEH8GU45tnrNM84D2l297DQ9t1YP7jki/7RmutRweEA77/HWXOh3HCxkRgldDQkAjNTMl2Iloc1qN5JfJeeTlyTRzxURTdn1Ixv2uKjs12AbdEWlBtmVdk2k7FFwj07PCZ9XAwW3dG+8xKzNFr4EnwBZpy9Qzhh3jDXebBpYcpuo4fQ44u+fD1dweEnHzI7v0xuuOALRUV8rXpFyfSTQYkhd7IHm07jpyhlkCmI0ALYqPTpUxXS+z4jgDj1Pflvmz5ecuItpIBxyTHpSTGWd9g1ApfD/bvwUhL4nT1EzqgX7cxfCcNmb3mPL/qi9SwTHJ49oj5ZLjccbTG3pRmlYi6JCG0mQrAt1+i2UXTZ2dv9IlQpN5naMYtviaXlTrFpoMsl3bOAFEa8sqPj2WCMrx3Yjx99qFwO59Aw/wgx+HlqNz8oZvA3exRDvuhL1jMQHPaOJ0+XyA3fp1OfM3qObEVdhxjvynxNMXQV4+GJyvOEFqeQBaIbbO7i63rpxCltdZShPFxkjM2FPVkn3TG+Rp9pO3l2RzFegGfxGDHIAh8SteR0C4HopXzRF61nheDw6TFN05Ebvq8M3VKKpGjjO6r7nhudTEGMtYM92HTDaR1FDMXJ1eThsbKfywyoWwrzRSXkc51flG3vIid62h29bIcFbTGhfV+faaB+ohj7dPN0C2e2lC96+XouFByen9AsunLDJZ9z7NExiUc0OuoYW6UZkIyx2YUR2z6/TiRjyKMx5GbbjLHvHuf7YmtKghf34LJfx63Yg8vrvN2zC7lY0x0tvKezo4HmGYDU+Gab6dFL+KI761lDcNifcjLrrr9LWZJctG1FfU1uwhoQE22ObjdfkSzY63CbU5hzs21WeTddH2BaL11Gi7lVdlxP1nkxqhnKhVY6knS3EPgVGg1JpN5cP/hivujOelhXcPj8HC/LyI6MkteVjlolBdMmF3a3DbsuAYhL44dxzthWSN065xxUd55Lmf0wRbOYOqH09/o9WbO2VtFdaMb4qBgtFJoT1SqoN8wPXMoXLb3p1PUEhxfnnLzGzBI0Ku7FxrKsNJj/8bn/H8fPIVOd3rfrklUB/DOeO+nkghgSPzrlPxluCMtOnDL4Yml6dK1r3vsgMxgtPOrMFUZbEUbTdIzii5beq72G4PD0DKnwjmBULUVFmy8t+k7fZ3pKc0Q4UC6jpVRqS9Umv8bxw35flZVOU1X7qkjnhZlsMbk24qQ6Hz7QcuL6sDC0iHHki96Uh2UdvmgZnjIvExy2TeJdMDZNSbdZyAHe/Yd1xsQhHiKzjh7GxQ4yqMPaywPkjMamvqrYpmO7Knad+ZQC5msCuAPWUoxrxVhrGv7a+KLXFhyONdTMrZ7ke23qiO40ZJUyzgYyX5XyL0mV7NiUzEs9mjtbMN0dERqwyAJpigad0B3/zRV7s4PIfXSu6YV/MK7+OrYe/JvfGMn/PHJe2fyUdtnFrKRNpXV0Y2559aWPt/G4BlvjTMtXlVIWCnNyA3YQBDmYIodFz41PvXPSa6rq9lWZawZ4dP115HXV/M/tnFkkrBOdzg6aP4pID+MZnTJ1SuuB6iZlyiox4HT2y3YBtkUKWooacBQUDTpjwaDt5poBHl1/HXltwP887lKKXxNUEyPqpGTyA699UqY/lt9yGdlUKra0fFWS+36iylVWrAyd7Uw0CZM0z7xKTOduznLIjG2Hx8cDPLb+OvK6Bv7n1DYci4CxUuRxrjBc0bb4vD3rN5Zz36ntLb83eVJIB8LiIzCmn6SMPjlX+yNlTjvIGjs+QzHPf60Aj62/jrzG8j9vYMFtm1VoRWCJdmw7z9N0t+c8cxZpPeK4aTRicS25QhrVtUp7U578chk4q04Wx4YoQSjFryUlpcQ1AbxZ/XVMknIU//OGl7Q6z9Zpxi0+3yFhSkjUDpnCIUhLWVX23KQ+L9vKvFKI0ZWFQgkDLvBoylrHNVmaw10zwCPrr5tlodfnf94EWnQ0lFRWy8pW9LbkLsyUVDc2NSTHGDtnD1uMtchjbCeb1mpxFP0YbcClhzdLu6lfO8Bj6q+bdT2sz/+8SZCV7VIxtt0DUn9L7r4cLYWDSXnseEpOGFuty0qbOVlS7NNzs5FOGJUqQpl2Q64/yBpZf90sxbE+//PGdZ02HSipCbmD6NItmQ4Lk5XUrGpDMkhbMm2ZVheNYV+VbUWTcv99+2NyX1VoafSuC+AN6q9bFIMv5X/eagNWXZxEa9JjlMwNWb00akGUkSoepp1/yRuuqHGbUn3UdBSTxBU6SEVklzWRUkPndVvw2PrrpjvxOvzPmwHc0hpmq82npi7GRro8dXp0KXnUQmhZbRL7NEVp1uuZmO45vuzKsHrktS3GLWXODVjw+vXXLYx4Hf7njRPd0i3aoAGX6W29GnaV5YdyDj9TFkakje7GHYzDoObfddHtOSpoi2SmzJHrB3hM/XUDDEbxP2/oosszcRlehWXUvzHv4TpBVktHqwenFo8uLVmy4DKLa5d3RtLrmrM3aMFr1183E4sewf+85VWeg1c5ag276NZrM9IJVNcmLEvDNaV62aq+14IAOGFsBt973Ra8Xv11YzXwNfmft7Jg2oS+XOyoC8/cwzi66Dhmgk38kUmP1CUiYWOX1bpD2zWXt2FCp7uq8703APAa9dfNdscR/M/bZLIyouVxqJfeWvG9Je+JVckHQ9+CI9NWxz+blX/KYYvO5n2tAP/vrlZ7+8/h9y+9qeB/Hnt967e5mevX10rALDWK//FaAT5MXdBXdP0C/BAes792c40H+AiAp1e1oH8HgH94g/Lttx1gp63op1eyoM/Bvw5/G/7xFbqJPcCXnmBiwDPb/YKO4FX4OjyCb289db2/Noqicw4i7N6TVtoz8tNwDH+8x/i6Ae7lmaQVENzJFb3Di/BFeAwz+Is9SjeQySpPqbLFlNmyz47z5a/AF+AYFvDmHqibSXTEzoT4Gc3OALaqAP4KPFUJ6n+1x+rGAM6Zd78bgJ0a8QN4GU614vxwD9e1Amy6CcskNrczLx1JIp6HE5UZD/DBHrFr2oNlgG4Odv226BodoryjGJ9q2T/AR3vQrsOCS0ctXZi3ruLlhpFDJYl4HmYtjQCP9rhdn4suySLKDt6wLcC52h8xPlcjju1fn+yhuw4LZsAGUuo2b4Fx2UwQu77uqRHXGtg92aN3tQCbFexc0uk93vhTXbct6y7MulLycoUljx8ngDMBg1tvJjAazpEmOtxlzclvj1vQf1Tx7QlPDpGpqgtdSKz/d9/hdy1vTfFHSmC9dGDZbLiezz7Ac801HirGZsWjydfZyPvHXL/Y8Mjzg8BxTZiuwKz4Eb8sBE9zznszmjvFwHKPIWUnwhqfVRcd4Ck0K6ate48m1oOfrX3/yOtvAsJ8zsPAM89sjnddmuLuDPjX9Bu/L7x7xpMzFk6nWtyQfPg278Gn4Aekz2ZgOmU9eJ37R14vwE/BL8G3aibCiWMWWDQ0ZtkPMnlcGeAu/Ag+8ZyecU5BPuy2ILD+sQqyZhAKmn7XZd+jIMTN9eBL7x95xVLSX4On8EcNlXDqmBlqS13jG4LpmGbkF/0CnOi3H8ETOIXzmnmtb0a16Tzxj1sUvQCBiXZGDtmB3KAefPH94xcUa/6vwRn80GOFyjEXFpba4A1e8KQfFF+259tx5XS4egYn8fQsLGrqGrHbztr+uByTahWuL1NUGbDpsnrwBfePPwHHIf9X4RnM4Z2ABWdxUBlqQ2PwhuDxoS0vvqB1JzS0P4h2nA/QgTrsJFn+Y3AOjs9JFC07CGWX1oNX3T/yHOzgDjwPn1PM3g9Jk9lZrMEpxnlPmBbjyo2+KFXRU52TJM/2ALcY57RUzjObbjqxVw++4P6RAOf58pcVsw9Daje3htriYrpDOonre3CudSe6bfkTEgHBHuDiyu5MCsc7BHhYDx7ePxLjqigXZsw+ijMHFhuwBmtoTPtOxOrTvYJDnC75dnUbhfwu/ZW9AgYd+peL68HD+0emKquiXHhWjJg/UrkJYzuiaL3E9aI/ytrCvAd4GcYZMCkSQxfUg3v3j8c4e90j5ZTPdvmJJGHnOCI2nHS8081X013pHuBlV1gB2MX1YNmWLHqqGN/TWmG0y6clJWthxNUl48q38Bi8vtMKyzzpFdSDhxZ5WBA5ZLt8Jv3895DduBlgbPYAj8C4B8hO68FDkoh5lydC4FiWvBOVqjYdqjiLv92t8yPDjrDaiHdUD15qkSURSGmXJwOMSxWAXYwr3zaAufJ66l+94vv3AO+vPcD7aw/w/toDvL/2AO+vPcD7aw/wHuD9tQd4f+0B3l97gPfXHuD9tQd4f+0B3l97gG8LwP8G/AL8O/A5OCq0Ys2KIdv/qOIXG/4mvFAMF16gZD+2Xvu/B8as5+8bfllWyg0zaNO5bfXj6vfhhwD86/Aq3NfRS9t9WPnhfnvCIw/CT8GLcFTMnpntdF/z9V+PWc/vWoIH+FL3Znv57PitcdGP4R/C34avw5fgRVUInCwbsn1yyA8C8zm/BH8NXoXnVE6wVPjdeCI38kX/3+Ct9dbz1pTmHFRu+Hm4O9Ch3clr99negxfwj+ER/DR8EV6B5+DuQOnTgUw5rnkY+FbNU3gNXh0o/JYTuWOvyBf9FvzX663HH/HejO8LwAl8Hl5YLTd8q7sqA3wbjuExfAFegQdwfyDoSkWY8swzEf6o4Qyewefg+cHNbqMQruSL/u/WWc+E5g7vnnEXgDmcDeSGb/F4cBcCgT+GGRzDU3hZYburAt9TEtHgbM6JoxJ+6NMzzTcf6c2bycv2+KK/f+l6LBzw5IwfqZJhA3M472pWT/ajKxnjv4AFnMEpnBTPND6s2J7qHbPAqcMK74T2mZ4VGB9uJA465It+/eL1WKhYOD7xHOkr1ajK7d0C4+ke4Hy9qXZwpgLr+Znm/uNFw8xQOSy8H9IzjUrd9+BIfenYaylf9FsXr8fBAadnPIEDna8IBcwlxnuA0/Wv6GAWPd7dDIKjMdSWueAsBj4M7TOd06qBbwDwKr7oleuxMOEcTuEZTHWvDYUO7aHqAe0Bbq+HEFRzOz7WVoTDQkVds7A4sIIxfCQdCefFRoIOF/NFL1mPab/nvOakSL/Q1aFtNpUb/nFOVX6gzyg/1nISyDfUhsokIzaBR9Kxm80s5mK+6P56il1jXic7nhQxsxSm3OwBHl4fFdLqi64nDQZvqE2at7cWAp/IVvrN6/BFL1mPhYrGMBfOi4PyjuSGf6wBBh7p/FZTghCNWGgMzlBbrNJoPJX2mW5mwZfyRffXo7OFi5pZcS4qZUrlViptrXtw+GQoyhDPS+ANjcGBNRiLCQDPZPMHuiZfdFpPSTcQwwKYdRNqpkjm7AFeeT0pJzALgo7g8YYGrMHS0iocy+YTm2vyRUvvpXCIpQ5pe666TJrcygnScUf/p0NDs/iAI/nqDHC8TmQT8x3NF91l76oDdQGwu61Z6E0ABv7uO1dbf/37Zlv+Zw/Pbh8f1s4Avur6657/+YYBvur6657/+YYBvur6657/+YYBvur6657/+aYBvuL6657/+VMA8FXWX/f8zzcN8BXXX/f8zzcNMFdbf93zP38KLPiK6697/uebtuArrr/u+Z9vGmCusP6653/+1FjwVdZf9/zPN7oHX339dc//fNMu+irrr3v+50+Bi+Zq6697/uebA/jz8Pudf9ht/fWv517J/XUzAP8C/BAeX9WCDrUpZ3/dEMBxgPcfbtTVvsYV5Yn32u03B3Ac4P3b8I+vxNBKeeL9dRMAlwO83959qGO78sT769oB7g3w/vGVYFzKE++v6wV4OMD7F7tckFkmT7y/rhHgpQO8b+4Y46XyxPvrugBeNcB7BRiX8sT767oAvmCA9woAHsoT76+rBJjLBnh3txOvkifeX1dswZcO8G6N7sXyxPvr6i340gHe3TnqVfLE++uKAb50gHcXLnrX8sR7gNdPRqwzwLu7Y/FO5Yn3AK9jXCMGeHdgxDuVJ75VAI8ljP7PAb3/RfjcZfePHBB+79dpfpH1CanN30d+mT1h9GqAxxJGM5LQeeQ1+Tb+EQJrElLb38VHQ94TRq900aMIo8cSOo+8Dp8QfsB8zpqE1NO3OI9Zrj1h9EV78PqE0WMJnUdeU6E+Jjyk/hbrEFIfeWbvId8H9oTRFwdZaxJGvziW0Hn0gqYB/wyZ0PwRlxJST+BOw9m77Amj14ii1yGM/txYQudN0qDzGe4EqfA/5GJCagsHcPaEPWH0esekSwmjRxM6b5JEcZ4ww50ilvAOFxBSx4yLW+A/YU8YvfY5+ALC6NGEzhtmyZoFZoarwBLeZxUhtY4rc3bKnjB6TKJjFUHzJoTOozF2YBpsjcyxDgzhQ1YRUse8+J4wenwmaylB82hC5w0zoRXUNXaRBmSMQUqiWSWkLsaVqc/ZE0aPTFUuJWgeTei8SfLZQeMxNaZSIzbII4aE1Nmr13P2hNHjc9E9guYNCZ032YlNwESMLcZiLQHkE4aE1BFg0yAR4z1h9AiAGRA0jyZ03tyIxWMajMPWBIsxYJCnlITU5ShiHYdZ94TR4wCmSxg9jtB5KyPGYzymAYexWEMwAPIsAdYdV6aObmNPGD0aYLoEzaMJnTc0Ygs+YDw0GAtqxBjkuP38bMRWCHn73xNGjz75P73WenCEJnhwyVe3AEe8TtKdJcYhBl97wuhNAObK66lvD/9J9NS75v17wuitAN5fe4D31x7g/bUHeH/tAd5fe4D3AO+vPcD7aw/w/toDvL/2AO+vPcD7aw/w/toDvAd4f/24ABzZ8o+KLsSLS+Pv/TqTb3P4hKlQrTGh+fbIBT0Axqznnb+L/V2mb3HkN5Mb/nEHeK7d4IcDld6lmDW/iH9E+AH1MdOw/Jlu2T1xNmY98sv4wHnD7D3uNHu54WUuOsBTbQuvBsPT/UfzNxGYzwkP8c+Yz3C+r/i6DcyRL/rZ+utRwWH5PmfvcvYEt9jLDS/bg0/B64DWKrQM8AL8FPwS9beQCe6EMKNZYJol37jBMy35otdaz0Bw2H/C2Smc7+WGB0HWDELBmOByA3r5QONo4V+DpzR/hFS4U8wMW1PXNB4TOqYz9urxRV++ntWCw/U59Ty9ebdWbrgfRS9AYKKN63ZokZVygr8GZ/gfIhZXIXPsAlNjPOLBby5c1eOLvmQ9lwkOy5x6QV1j5TYqpS05JtUgUHUp5toHGsVfn4NX4RnMCe+AxTpwmApTYxqMxwfCeJGjpXzRF61nbcHhUBPqWze9svwcHJ+S6NPscKrEjug78Dx8Lj3T8D4YxGIdxmJcwhi34fzZUr7olevZCw5vkOhoClq5zBPZAnygD/Tl9EzDh6kl3VhsHYcDEb+hCtJSvuiV69kLDm+WycrOTArHmB5/VYyP6jOVjwgGawk2zQOaTcc1L+aLXrKeveDwZqlKrw8U9Y1p66uK8dEzdYwBeUQAY7DbyYNezBfdWQ97weEtAKYQg2xJIkuveAT3dYeLGH+ShrWNwZgN0b2YL7qznr3g8JYAo5bQBziPjx7BPZ0d9RCQp4UZbnFdzBddor4XHN4KYMrB2qHFRIzzcLAHQZ5the5ovui94PCWAPefaYnxIdzRwdHCbuR4B+tbiy96Lzi8E4D7z7S0mEPd+eqO3cT53Z0Y8SV80XvB4Z0ADJi/f7X113f+7p7/+UYBvur6657/+YYBvur6657/+aYBvuL6657/+aYBvuL6657/+aYBvuL6657/+aYBvuL6657/+VMA8FXWX/f8z58OgK+y/rrnf75RgLna+uue//lTA/CV1V/3/M837aKvvv6653++UQvmauuve/7nTwfAV1N/3fM/fzr24Cuuv+75nz8FFnxl9dc9//MOr/8/glixwRuUfM4AAAAASUVORK5CYII="}getSearchTexture(){return"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEIAAAAhCAAAAABIXyLAAAAAOElEQVRIx2NgGAWjYBSMglEwEICREYRgFBZBqDCSLA2MGPUIVQETE9iNUAqLR5gIeoQKRgwXjwAAGn4AtaFeYLEAAAAASUVORK5CYII="}};class k3{constructor(e=Math){this.grad3=[[1,1,0],[-1,1,0],[1,-1,0],[-1,-1,0],[1,0,1],[-1,0,1],[1,0,-1],[-1,0,-1],[0,1,1],[0,-1,1],[0,1,-1],[0,-1,-1]],this.grad4=[[0,1,1,1],[0,1,1,-1],[0,1,-1,1],[0,1,-1,-1],[0,-1,1,1],[0,-1,1,-1],[0,-1,-1,1],[0,-1,-1,-1],[1,0,1,1],[1,0,1,-1],[1,0,-1,1],[1,0,-1,-1],[-1,0,1,1],[-1,0,1,-1],[-1,0,-1,1],[-1,0,-1,-1],[1,1,0,1],[1,1,0,-1],[1,-1,0,1],[1,-1,0,-1],[-1,1,0,1],[-1,1,0,-1],[-1,-1,0,1],[-1,-1,0,-1],[1,1,1,0],[1,1,-1,0],[1,-1,1,0],[1,-1,-1,0],[-1,1,1,0],[-1,1,-1,0],[-1,-1,1,0],[-1,-1,-1,0]],this.p=[];for(let t=0;t<256;t++)this.p[t]=Math.floor(e.random()*256);this.perm=[];for(let t=0;t<512;t++)this.perm[t]=this.p[t&255];this.simplex=[[0,1,2,3],[0,1,3,2],[0,0,0,0],[0,2,3,1],[0,0,0,0],[0,0,0,0],[0,0,0,0],[1,2,3,0],[0,2,1,3],[0,0,0,0],[0,3,1,2],[0,3,2,1],[0,0,0,0],[0,0,0,0],[0,0,0,0],[1,3,2,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[1,2,0,3],[0,0,0,0],[1,3,0,2],[0,0,0,0],[0,0,0,0],[0,0,0,0],[2,3,0,1],[2,3,1,0],[1,0,2,3],[1,0,3,2],[0,0,0,0],[0,0,0,0],[0,0,0,0],[2,0,3,1],[0,0,0,0],[2,1,3,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[0,0,0,0],[2,0,1,3],[0,0,0,0],[0,0,0,0],[0,0,0,0],[3,0,1,2],[3,0,2,1],[0,0,0,0],[3,1,2,0],[2,1,0,3],[0,0,0,0],[0,0,0,0],[0,0,0,0],[3,1,0,2],[0,0,0,0],[3,2,0,1],[3,2,1,0]]}dot(e,t,n){return e[0]*t+e[1]*n}dot3(e,t,n,r){return e[0]*t+e[1]*n+e[2]*r}dot4(e,t,n,r,s){return e[0]*t+e[1]*n+e[2]*r+e[3]*s}noise(e,t){let n,r,s;const o=.5*(Math.sqrt(3)-1),a=(e+t)*o,l=Math.floor(e+a),c=Math.floor(t+a),u=(3-Math.sqrt(3))/6,h=(l+c)*u,f=l-h,d=c-h,g=e-f,v=t-d;let _,m;g>v?(_=1,m=0):(_=0,m=1);const p=g-_+u,y=v-m+u,x=g-1+2*u,w=v-1+2*u,A=l&255,b=c&255,L=this.perm[A+this.perm[b]]%12,B=this.perm[A+_+this.perm[b+m]]%12,I=this.perm[A+1+this.perm[b+1]]%12;let C=.5-g*g-v*v;C<0?n=0:(C*=C,n=C*C*this.dot(this.grad3[L],g,v));let Y=.5-p*p-y*y;Y<0?r=0:(Y*=Y,r=Y*Y*this.dot(this.grad3[B],p,y));let O=.5-x*x-w*w;return O<0?s=0:(O*=O,s=O*O*this.dot(this.grad3[I],x,w)),70*(n+r+s)}noise3d(e,t,n){let r,s,o,a;const l=.3333333333333333,c=(e+t+n)*l,u=Math.floor(e+c),h=Math.floor(t+c),f=Math.floor(n+c),d=1/6,g=(u+h+f)*d,v=u-g,_=h-g,m=f-g,p=e-v,y=t-_,x=n-m;let w,A,b,L,B,I;p>=y?y>=x?(w=1,A=0,b=0,L=1,B=1,I=0):p>=x?(w=1,A=0,b=0,L=1,B=0,I=1):(w=0,A=0,b=1,L=1,B=0,I=1):yI?32:0,G=B>C?16:0,j=I>C?8:0,N=B>Y?4:0,k=I>Y?2:0,K=C>Y?1:0,le=O+G+j+N+k+K,ve=o[le][0]>=3?1:0,ce=o[le][1]>=3?1:0,ye=o[le][2]>=3?1:0,$=o[le][3]>=3?1:0,se=o[le][0]>=2?1:0,me=o[le][1]>=2?1:0,Z=o[le][2]>=2?1:0,V=o[le][3]>=2?1:0,te=o[le][0]>=1?1:0,Q=o[le][1]>=1?1:0,re=o[le][2]>=1?1:0,we=o[le][3]>=1?1:0,M=B-ve+c,E=I-ce+c,F=C-ye+c,W=Y-$+c,X=B-se+2*c,T=I-me+2*c,S=C-Z+2*c,U=Y-V+2*c,q=B-te+3*c,H=I-Q+3*c,oe=C-re+3*c,ue=Y-we+3*c,he=B-1+4*c,xe=I-1+4*c,ge=C-1+4*c,z=Y-1+4*c,fe=_&255,ne=m&255,Te=p&255,D=y&255,_e=a[fe+a[ne+a[Te+a[D]]]]%32,Ie=a[fe+ve+a[ne+ce+a[Te+ye+a[D+$]]]]%32,Ue=a[fe+se+a[ne+me+a[Te+Z+a[D+V]]]]%32,ke=a[fe+te+a[ne+Q+a[Te+re+a[D+we]]]]%32,Oe=a[fe+1+a[ne+1+a[Te+1+a[D+1]]]]%32;let g0=.6-B*B-I*I-C*C-Y*Y;g0<0?u=0:(g0*=g0,u=g0*g0*this.dot4(s[_e],B,I,C,Y));let E0=.6-M*M-E*E-F*F-W*W;E0<0?h=0:(E0*=E0,h=E0*E0*this.dot4(s[Ie],M,E,F,W));let H0=.6-X*X-T*T-S*S-U*U;H0<0?f=0:(H0*=H0,f=H0*H0*this.dot4(s[Ue],X,T,S,U));let N0=.6-q*q-H*H-oe*oe-ue*ue;N0<0?d=0:(N0*=N0,d=N0*N0*this.dot4(s[ke],q,H,oe,ue));let bn=.6-he*he-xe*xe-ge*ge-z*z;return bn<0?g=0:(bn*=bn,g=bn*bn*this.dot4(s[Oe],he,xe,ge,z)),27*(u+h+f+d+g)}}const Is={defines:{PERSPECTIVE_CAMERA:1,KERNEL_SIZE:32},uniforms:{tDiffuse:{value:null},tNormal:{value:null},tDepth:{value:null},tNoise:{value:null},kernel:{value:null},cameraNear:{value:null},cameraFar:{value:null},resolution:{value:new ee},cameraProjectionMatrix:{value:new Me},cameraInverseProjectionMatrix:{value:new Me},kernelRadius:{value:8},minDistance:{value:.005},maxDistance:{value:.05}},vertexShader:` varying vec2 vUv; @@ -5283,7 +5283,7 @@ version 0.6.9 gl_FragColor = vec4( vec3( result / ( 5.0 * 5.0 ) ), 1.0 ); - }`};let wf=class wi extends $t{constructor(e,t,n,r){super(),this.width=n!==void 0?n:512,this.height=r!==void 0?r:512,this.clear=!0,this.camera=t,this.scene=e,this.kernelRadius=8,this.kernelSize=32,this.kernel=[],this.noiseTexture=null,this.output=0,this.minDistance=.005,this.maxDistance=.1,this._visibilityCache=new Map,this.generateSampleKernel(),this.generateRandomKernelRotations();const s=new j4;s.type=oo,this.beautyRenderTarget=new C0(this.width,this.height,{minFilter:s0,magFilter:s0,format:a0}),this.normalRenderTarget=new C0(this.width,this.height,{minFilter:r0,magFilter:r0,format:a0,depthTexture:s}),this.ssaoRenderTarget=new C0(this.width,this.height,{minFilter:s0,magFilter:s0,format:a0}),this.blurRenderTarget=this.ssaoRenderTarget.clone(),Fs===void 0&&console.error("THREE.SSAOPass: The pass relies on SSAOShader."),this.ssaoMaterial=new u0({defines:Object.assign({},Fs.defines),uniforms:K0.clone(Fs.uniforms),vertexShader:Fs.vertexShader,fragmentShader:Fs.fragmentShader,blending:V0}),this.ssaoMaterial.uniforms.tDiffuse.value=this.beautyRenderTarget.texture,this.ssaoMaterial.uniforms.tNormal.value=this.normalRenderTarget.texture,this.ssaoMaterial.uniforms.tDepth.value=this.normalRenderTarget.depthTexture,this.ssaoMaterial.uniforms.tNoise.value=this.noiseTexture,this.ssaoMaterial.uniforms.kernel.value=this.kernel,this.ssaoMaterial.uniforms.cameraNear.value=this.camera.near,this.ssaoMaterial.uniforms.cameraFar.value=this.camera.far,this.ssaoMaterial.uniforms.resolution.value.set(this.width,this.height),this.ssaoMaterial.uniforms.cameraProjectionMatrix.value.copy(this.camera.projectionMatrix),this.ssaoMaterial.uniforms.cameraInverseProjectionMatrix.value.copy(this.camera.projectionMatrixInverse),this.normalMaterial=new x5,this.normalMaterial.blending=V0,this.blurMaterial=new u0({defines:Object.assign({},Ta.defines),uniforms:K0.clone(Ta.uniforms),vertexShader:Ta.vertexShader,fragmentShader:Ta.fragmentShader}),this.blurMaterial.uniforms.tDiffuse.value=this.ssaoRenderTarget.texture,this.blurMaterial.uniforms.resolution.value.set(this.width,this.height),this.depthRenderMaterial=new u0({defines:Object.assign({},Sa.defines),uniforms:K0.clone(Sa.uniforms),vertexShader:Sa.vertexShader,fragmentShader:Sa.fragmentShader,blending:V0}),this.depthRenderMaterial.uniforms.tDepth.value=this.normalRenderTarget.depthTexture,this.depthRenderMaterial.uniforms.cameraNear.value=this.camera.near,this.depthRenderMaterial.uniforms.cameraFar.value=this.camera.far,this.copyMaterial=new u0({uniforms:K0.clone(Ci.uniforms),vertexShader:Ci.vertexShader,fragmentShader:Ci.fragmentShader,transparent:!0,depthTest:!1,depthWrite:!1,blendSrc:h4,blendDst:q1,blendEquation:zn,blendSrcAlpha:u4,blendDstAlpha:q1,blendEquationAlpha:zn}),this.fsQuad=new Gi(null),this.originalClearColor=new be}dispose(){this.beautyRenderTarget.dispose(),this.normalRenderTarget.dispose(),this.ssaoRenderTarget.dispose(),this.blurRenderTarget.dispose(),this.normalMaterial.dispose(),this.blurMaterial.dispose(),this.copyMaterial.dispose(),this.depthRenderMaterial.dispose(),this.fsQuad.dispose()}render(e,t){switch(e.setRenderTarget(this.beautyRenderTarget),e.clear(),e.render(this.scene,this.camera),this.overrideVisibility(),this.renderOverride(e,this.normalMaterial,this.normalRenderTarget,7829503,1),this.restoreVisibility(),this.ssaoMaterial.uniforms.kernelRadius.value=this.kernelRadius,this.ssaoMaterial.uniforms.minDistance.value=this.minDistance,this.ssaoMaterial.uniforms.maxDistance.value=this.maxDistance,this.renderPass(e,this.ssaoMaterial,this.ssaoRenderTarget),this.renderPass(e,this.blurMaterial,this.blurRenderTarget),this.output){case wi.OUTPUT.SSAO:this.copyMaterial.uniforms.tDiffuse.value=this.ssaoRenderTarget.texture,this.copyMaterial.blending=V0,this.renderPass(e,this.copyMaterial,this.renderToScreen?null:t);break;case wi.OUTPUT.Blur:this.copyMaterial.uniforms.tDiffuse.value=this.blurRenderTarget.texture,this.copyMaterial.blending=V0,this.renderPass(e,this.copyMaterial,this.renderToScreen?null:t);break;case wi.OUTPUT.Beauty:this.copyMaterial.uniforms.tDiffuse.value=this.beautyRenderTarget.texture,this.copyMaterial.blending=V0,this.renderPass(e,this.copyMaterial,this.renderToScreen?null:t);break;case wi.OUTPUT.Depth:this.renderPass(e,this.depthRenderMaterial,this.renderToScreen?null:t);break;case wi.OUTPUT.Normal:this.copyMaterial.uniforms.tDiffuse.value=this.normalRenderTarget.texture,this.copyMaterial.blending=V0,this.renderPass(e,this.copyMaterial,this.renderToScreen?null:t);break;case wi.OUTPUT.Default:this.copyMaterial.uniforms.tDiffuse.value=this.beautyRenderTarget.texture,this.copyMaterial.blending=V0,this.renderPass(e,this.copyMaterial,this.renderToScreen?null:t),this.copyMaterial.uniforms.tDiffuse.value=this.blurRenderTarget.texture,this.copyMaterial.blending=a4,this.renderPass(e,this.copyMaterial,this.renderToScreen?null:t);break;default:console.warn("THREE.SSAOPass: Unknown output type.")}}renderPass(e,t,n,r,s){e.getClearColor(this.originalClearColor);const o=e.getClearAlpha(),a=e.autoClear;e.setRenderTarget(n),e.autoClear=!1,r!=null&&(e.setClearColor(r),e.setClearAlpha(s||0),e.clear()),this.fsQuad.material=t,this.fsQuad.render(e),e.autoClear=a,e.setClearColor(this.originalClearColor),e.setClearAlpha(o)}renderOverride(e,t,n,r,s){e.getClearColor(this.originalClearColor);const o=e.getClearAlpha(),a=e.autoClear;e.setRenderTarget(n),e.autoClear=!1,r=t.clearColor||r,s=t.clearAlpha||s,r!=null&&(e.setClearColor(r),e.setClearAlpha(s||0),e.clear()),this.scene.overrideMaterial=t,e.render(this.scene,this.camera),this.scene.overrideMaterial=null,e.autoClear=a,e.setClearColor(this.originalClearColor),e.setClearAlpha(o)}setSize(e,t){this.width=e,this.height=t,this.beautyRenderTarget.setSize(e,t),this.ssaoRenderTarget.setSize(e,t),this.normalRenderTarget.setSize(e,t),this.blurRenderTarget.setSize(e,t),this.ssaoMaterial.uniforms.resolution.value.set(e,t),this.ssaoMaterial.uniforms.cameraProjectionMatrix.value.copy(this.camera.projectionMatrix),this.ssaoMaterial.uniforms.cameraInverseProjectionMatrix.value.copy(this.camera.projectionMatrixInverse),this.blurMaterial.uniforms.resolution.value.set(e,t)}generateSampleKernel(){const e=this.kernelSize,t=this.kernel;for(let n=0;n{t?t(i,n,r):i[n]=r})}function ai(i,e,t,n=!0,r){n&&Mo(t,i[e],r);const s=xh(i,e);return Ke(s,o=>{Mo(t,o,r)})}function hT(i,e,t=!0,n){t&&Mo(e,i,n);const r=P0(i);return Ke(r,s=>{Mo(e,s,n)},{deep:!0})}function So(i,e){e instanceof Object&&Object.entries(e).forEach(([t,n])=>{i[t]=n})}function fT(i,e,t){e.forEach(n=>{z0(i,n,t,n)})}function z0(i,e,t,n){const r=n||e,s=xh(i,e);s.value instanceof Object?(So(t[r],s.value),Ke(s,o=>{So(t[r],o)},{deep:!0})):(s.value!==void 0&&(t[r]=i[e]),Ke(s,o=>{t[r]=o}))}function Fl(i,e=[]){const t={};return Object.entries(i).forEach(([n,r])=>{(!e||!e.includes(n))&&(t[n]=r)}),t}function dT(i,e,t){return t=t<0?0:t,t=t>1?1:t,i+(e-i)*t}function pT(i,e,t){return it?t:i}const mT="https://rawcdn.githack.com/emmelleppi/matcaps/9b36ccaaf0a24881a39062d05566c9e92be4aa0d",gT="0404E8_0404B5_0404CB_3333FC";function Mf(i=gT,e=1024){const t=`${i}${vT(e)}.png`;return`${mT}/${e}/${t}`}function vT(i){switch(i){case 64:return"-64px";case 128:return"-128px";case 256:return"-256px";case 512:return"-512px";default:return""}}function xT(i){const{camera:e,resetPosition:t=new P(0,0,0)}=i,n=new FM,r=t.clone(),s=new Xt(new P(0,0,1),0);return{position:r,updatePosition:l=>{n.setFromCamera(l,e),e.getWorldDirection(s.normal),n.ray.intersectPlane(s,r)},intersect:(l,c,u=!1)=>(n.setFromCamera(l,e),n.intersectObjects(c,u))}}function Sf(i){const{camera:e,domElement:t,intersectObjects:n,intersectRecursive:r=!1,touch:s=!0,resetOnEnd:o=!1,onEnter:a=()=>{},onMove:l=()=>{},onLeave:c=()=>{},onClick:u=()=>{},onIntersectEnter:h=()=>{},onIntersectOver:f=()=>{},onIntersectMove:d=()=>{},onIntersectLeave:g=()=>{},onIntersectClick:v=()=>{}}=i,_=new ee(0,0),m=new ee(0,0),p=xT({camera:e}),y=p.position,x={position:_,positionN:m,positionV3:y,intersectObjects:n,listeners:!1,addListeners:G,removeListeners:j,intersect:b};return x;function w(){_.set(0,0),m.set(0,0),y.set(0,0,0)}function A(N){let k,Z;N.touches&&N.touches.length>0?(k=N.touches[0].clientX,Z=N.touches[0].clientY):(k=N.clientX,Z=N.clientY);const le=t.getBoundingClientRect();_.x=k-le.left,_.y=Z-le.top,m.x=_.x/le.width*2-1,m.y=-(_.y/le.height)*2+1,p.updatePosition(m)}function b(){const N=O();if(N.length){const k=p.intersect(m,N,r),Z=[...N],le=[];k.forEach(ve=>{var ce,ye,$;const{object:se}=ve,pe=Y(se);if(se instanceof Ya){if(le.indexOf(se)!==-1)return;le.push(se)}if(!se.userData.over){se.userData.over=!0;const V={type:"pointerover",over:!0,component:pe,intersect:ve},te={...V,type:"pointerenter"};f(V),h(te),(ce=pe==null?void 0:pe.onPointerOver)==null||ce.call(pe,V),(ye=pe==null?void 0:pe.onPointerEnter)==null||ye.call(pe,te)}const K={type:"pointermove",component:pe,intersect:ve};d(K),($=pe==null?void 0:pe.onPointerMove)==null||$.call(pe,K),Z.splice(Z.indexOf(se),1)}),Z.forEach(ve=>{var ce,ye;const $=Y(ve);if(ve.userData.over){ve.userData.over=!1;const se={type:"pointerover",over:!1,component:$},pe={...se,type:"pointerleave"};f(se),g(pe),(ce=$==null?void 0:$.onPointerOver)==null||ce.call($,se),(ye=$==null?void 0:$.onPointerLeave)==null||ye.call($,pe)}})}}function L(N){A(N),a({type:"pointerenter",position:_,positionN:m,positionV3:y})}function B(N){A(N),l({type:"pointermove",position:_,positionN:m,positionV3:y}),b()}function I(N){A(N);const k=O();if(k.length){const Z=p.intersect(m,k,r),le=[];Z.forEach(ve=>{var ce;const{object:ye}=ve,$=Y(ye);if(ye instanceof Ya){if(le.indexOf(ye)!==-1)return;le.push(ye)}const se={type:"click",component:$,intersect:ve};v(se),(ce=$==null?void 0:$.onClick)==null||ce.call($,se)})}u({type:"click",position:_,positionN:m,positionV3:y})}function C(){o&&w(),c({type:"pointerleave"})}function Y(N){if(N.userData.component)return N.userData.component;let k=N.parent;for(;k;){if(k.userData.component)return k.userData.component;k=k.parent}}function O(){return typeof n=="function"?n():n}function G(){t.addEventListener("mouseenter",L),t.addEventListener("mousemove",B),t.addEventListener("mouseleave",C),t.addEventListener("click",I),s&&(t.addEventListener("touchstart",L),t.addEventListener("touchmove",B),t.addEventListener("touchend",C)),x.listeners=!0}function j(){t.removeEventListener("mouseenter",L),t.removeEventListener("mousemove",B),t.removeEventListener("mouseleave",C),t.removeEventListener("click",I),t.removeEventListener("touchstart",L),t.removeEventListener("touchmove",B),t.removeEventListener("touchend",C),x.listeners=!1}}function yT(i){const e={antialias:!0,alpha:!1,autoClear:!0,orbitCtrl:!1,pointer:!1,resize:!1,width:300,height:150};i&&Object.entries(i).forEach(([y,x])=>{e[y]=x});const t={width:1,height:1,wWidth:1,wHeight:1,ratio:1},n=[],r=[],s=a(),o={config:e,renderer:s,size:t,init:l,dispose:v,render:h,renderC:f,setSize:m,addIntersectObject:d,removeIntersectObject:g};return o;function a(){const y=new o0({canvas:e.canvas,antialias:e.antialias,alpha:e.alpha,...e.params});return y.autoClear=e.autoClear,y}function l(){if(!o.scene)return console.error("Missing Scene"),!1;if(!o.camera)return console.error("Missing Camera"),!1;if(e.resize?(_(),window.addEventListener("resize",_)):e.width&&e.height&&m(e.width,e.height),c(),e.orbitCtrl){const y=new UM(o.camera,o.renderer.domElement);e.orbitCtrl instanceof Object&&Object.entries(e.orbitCtrl).forEach(([x,w])=>{y[x]=w}),u(()=>{y.update()}),o.cameraCtrl=y}return!0}function c(){let y={camera:o.camera,domElement:o.renderer.domElement,intersectObjects:r};e.pointer&&e.pointer instanceof Object&&(y={...y,...e.pointer});const x=o.pointer=Sf(y);(e.pointer||r.length)&&(x.addListeners(),y.intersectMode==="frame"&&u(x.intersect))}function u(y){n.push(y)}function h(){n.forEach(y=>y()),o.renderer.render(o.scene,o.camera)}function f(){n.forEach(y=>y()),o.composer.render()}function d(y){r.indexOf(y)===-1&&r.push(y),o.pointer&&!o.pointer.listeners&&o.pointer.addListeners()}function g(y){const x=r.indexOf(y);x!==-1&&r.splice(x,1),o.pointer&&!e.pointer&&r.length===0&&o.pointer.removeListeners()}function v(){window.removeEventListener("resize",_),o.pointer&&o.pointer.removeListeners(),o.cameraCtrl&&o.cameraCtrl.dispose(),o.renderer&&o.renderer.dispose()}function _(){var y;if(e.resize==="window")m(window.innerWidth,window.innerHeight);else{const x=o.renderer.domElement.parentNode;x&&m(x.clientWidth,x.clientHeight)}(y=e.onResize)==null||y.call(e,t)}function m(y,x){t.width=y,t.height=x,t.ratio=y/x,o.renderer.setSize(y,x,!1);const w=o.camera;if(w.type==="PerspectiveCamera"){const A=w;A.aspect=t.ratio,A.updateProjectionMatrix()}if(w.type==="OrthographicCamera"){const A=w;t.wWidth=A.right-A.left,t.wHeight=A.top-A.bottom}else{const A=p();t.wWidth=A[0],t.wHeight=A[1]}}function p(){const y=o.camera,x=y.fov*Math.PI/180,w=2*Math.tan(x/2)*Math.abs(y.position.z);return[w*y.aspect,w]}}const en=Symbol("Renderer");var Tf=Le({name:"Renderer",props:{params:{type:Object,default:()=>({})},antialias:Boolean,alpha:Boolean,autoClear:{type:Boolean,default:!0},orbitCtrl:{type:[Boolean,Object],default:!1},pointer:{type:[Boolean,Object],default:!1},resize:{type:[Boolean,String],default:!1},shadow:Boolean,width:String,height:String,pixelRatio:Number,xr:Boolean,props:{type:Object,default:()=>({})},onReady:Function},inheritAttrs:!1,setup(i,{attrs:e}){const t=[],n=[],r=[],s=[],o=[],a=document.createElement("canvas");Object.entries(e).forEach(([h,f])=>{const d=h.match(/^on([A-Z][a-zA-Z]*)$/);d?a.addEventListener(d[1].toLowerCase(),f):a.setAttribute(h,f)});const l={canvas:a,params:i.params,antialias:i.antialias,alpha:i.alpha,autoClear:i.autoClear,orbitCtrl:i.orbitCtrl,pointer:i.pointer,resize:i.resize};i.width&&(l.width=parseInt(i.width)),i.height&&(l.height=parseInt(i.height));const c=yT(l);ai(i,"props",c.renderer),w8(()=>{i.pixelRatio&&c.renderer.setPixelRatio(i.pixelRatio)});const u=()=>{};return{canvas:a,three:c,renderer:c.renderer,size:c.size,renderFn:u,raf:!0,initCallbacks:t,mountedCallbacks:n,beforeRenderCallbacks:r,afterRenderCallbacks:s,resizeCallbacks:o}},computed:{camera:{get:function(){return this.three.camera},set:function(i){this.three.camera=i}},scene:{get:function(){return this.three.scene},set:function(i){this.three.scene=i}},composer:{get:function(){return this.three.composer},set:function(i){this.three.composer=i}}},provide(){return{[en]:this}},mounted(){var i;this.$el.parentNode.insertBefore(this.canvas,this.$el),this.three.init()&&(this.three.pointer&&(this.$pointer=this.three.pointer),this.three.config.onResize=e=>{this.resizeCallbacks.forEach(t=>t({type:"resize",renderer:this,size:e}))},this.shadow&&(this.renderer.shadowMap.enabled=!0),this.renderFn=this.three.composer?this.three.renderC:this.three.render,this.initCallbacks.forEach(e=>e({type:"init",renderer:this})),(i=this.onReady)==null||i.call(this,this),this.xr?(this.renderer.xr.enabled=!0,this.renderer.setAnimationLoop(this.render)):requestAnimationFrame(this.renderLoop)),this.mountedCallbacks.forEach(e=>e({type:"mounted",renderer:this}))},beforeUnmount(){this.canvas.remove(),this.beforeRenderCallbacks=[],this.afterRenderCallbacks=[],this.raf=!1,this.three.dispose()},methods:{onInit(i){this.addListener("init",i)},onMounted(i){this.addListener("mounted",i)},onBeforeRender(i){this.addListener("beforerender",i)},offBeforeRender(i){this.removeListener("beforerender",i)},onAfterRender(i){this.addListener("afterrender",i)},offAfterRender(i){this.removeListener("afterrender",i)},onResize(i){this.addListener("resize",i)},offResize(i){this.removeListener("resize",i)},addListener(i,e){this.getCallbacks(i).push(e)},removeListener(i,e){const t=this.getCallbacks(i),n=t.indexOf(e);n!==-1&&t.splice(n,1)},getCallbacks(i){return i==="init"?this.initCallbacks:i==="mounted"?this.mountedCallbacks:i==="beforerender"?this.beforeRenderCallbacks:i==="afterrender"?this.afterRenderCallbacks:this.resizeCallbacks},render(i){this.beforeRenderCallbacks.forEach(e=>e({type:"beforerender",renderer:this,time:i})),this.renderFn({renderer:this,time:i}),this.afterRenderCallbacks.forEach(e=>e({type:"afterrender",renderer:this,time:i}))},renderLoop(i){this.raf&&requestAnimationFrame(this.renderLoop),this.render(i)}},render(){return this.$slots.default?this.$slots.default():[]},__hmrId:"Renderer"}),Af=Le({props:{props:{type:Object,default:()=>({})}},render(){return this.$slots.default?this.$slots.default():[]}});function il(i,e,t,n=!0){i[e]=t,n&&i.updateProjectionMatrix()}var _T=Le({extends:Af,name:"OrthographicCamera",props:{left:{type:Number,default:-1},right:{type:Number,default:1},top:{type:Number,default:1},bottom:{type:Number,default:-1},near:{type:Number,default:.1},far:{type:Number,default:2e3},zoom:{type:Number,default:1},position:{type:Object,default:()=>({x:0,y:0,z:0})}},setup(i){const e=nt(en);if(!e){console.error("Renderer not found");return}const t=new ii(i.left,i.right,i.top,i.bottom,i.near,i.far);return e.camera=t,z0(i,"position",t),ai(i,"props",t,!0,il),["left","right","top","bottom","near","far","zoom"].forEach(n=>{Ke(()=>i[n],r=>{il(t,n,r)})}),{renderer:e,camera:t}},__hmrId:"OrthographicCamera"}),yc=Le({extends:Af,name:"PerspectiveCamera",props:{aspect:{type:Number,default:1},far:{type:Number,default:2e3},fov:{type:Number,default:50},near:{type:Number,default:.1},position:{type:Object,default:()=>({x:0,y:0,z:0})},lookAt:{type:Object,default:null}},setup(i){var e;const t=nt(en);if(!t){console.error("Renderer not found");return}const n=new X0(i.fov,i.aspect,i.near,i.far);return t.camera=n,z0(i,"position",n),i.lookAt&&n.lookAt((e=i.lookAt.x)!=null?e:0,i.lookAt.y,i.lookAt.z),Ke(()=>i.lookAt,r=>{var s;n.lookAt((s=r.x)!=null?s:0,r.y,r.z)},{deep:!0}),ai(i,"props",n,!0,il),["aspect","far","fov","near"].forEach(r=>{Ke(()=>i[r],s=>{il(n,r,s)})}),{renderer:t,camera:n}},__hmrId:"PerspectiveCamera"});const O9=Symbol("Scene");var Ef=Le({name:"Scene",props:{background:[String,Number,Object]},setup(i){const e=nt(en),t=new o9;if(!e){console.error("Renderer not found");return}e.scene=t,Bs(O9,t);const n=o=>{o&&(typeof o=="string"||typeof o=="number"?t.background instanceof be?t.background.set(o):t.background=new be(o):o instanceof A0&&(t.background=o))};return n(i.background),Ke(()=>i.background,n),{scene:t,add:o=>{t.add(o)},remove:o=>{t.remove(o)}}},render(){return this.$slots.default?this.$slots.default():[]},__hmrId:"Scene"});const bT={onPointerEnter:Function,onPointerOver:Function,onPointerMove:Function,onPointerLeave:Function,onPointerDown:Function,onPointerUp:Function,onClick:Function};var li=Le({name:"Object3D",inject:{renderer:en,scene:O9},emits:["created","ready"],props:{position:{type:Object,default:()=>({x:0,y:0,z:0})},rotation:{type:Object,default:()=>({x:0,y:0,z:0})},scale:{type:Object,default:()=>({x:1,y:1,z:1,order:"XYZ"})},lookAt:{type:Object,default:null},userData:{type:Object,default:()=>({})},visible:{type:Boolean,default:!0},props:{type:Object,default:()=>({})},disableAdd:{type:Boolean,default:!1},disableRemove:{type:Boolean,default:!1},...bT},setup(){return{}},created(){this.renderer||console.error("Missing parent Renderer"),this.scene||console.error("Missing parent Scene")},unmounted(){this.disableRemove||this.removeFromParent(),this.o3d&&this.renderer&&this.renderer.three.removeIntersectObject(this.o3d)},methods:{initObject3D(i){var e;this.o3d=i,i.userData.component=this,(this.onPointerEnter||this.onPointerOver||this.onPointerMove||this.onPointerLeave||this.onPointerDown||this.onPointerUp||this.onClick)&&this.renderer&&this.renderer.three.addIntersectObject(i),z0(this,"position",i),z0(this,"rotation",i),z0(this,"scale",i),z0(this,"userData",i.userData),z0(this,"visible",i),ai(this,"props",i),this.$emit("created",i),this.lookAt&&i.lookAt((e=this.lookAt.x)!=null?e:0,this.lookAt.y,this.lookAt.z),Ke(()=>this.lookAt,t=>{var n;i.lookAt((n=t.x)!=null?n:0,t.y,t.z)},{deep:!0}),this.parent=this.getParent(),this.disableAdd||(this.addToParent()?this.$emit("ready",this):console.error("Missing parent (Scene, Group...)"))},getParent(){let i=this.$parent;if(!i){const e=a6();e&&e.parent&&(i=e.parent.ctx)}for(;i;){if(i.add)return i;i=i.$parent}},addToParent(i){const e=i||this.o3d;return this.parent?(this.parent.add(e),!0):!1},removeFromParent(i){const e=i||this.o3d;return this.parent?(this.parent.remove(e),!0):!1},add(i){var e;(e=this.o3d)==null||e.add(i)},remove(i){var e;(e=this.o3d)==null||e.remove(i)}},render(){return this.$slots.default?this.$slots.default():[]},__hmrId:"Object3D"}),wT=Le({name:"Group",extends:li,setup(){return{group:new Dt}},created(){this.initObject3D(this.group)},__hmrId:"Group"});const Is=()=>{};var MT=Le({name:"Raycaster",props:{onPointerEnter:{type:Function,default:Is},onPointerOver:{type:Function,default:Is},onPointerMove:{type:Function,default:Is},onPointerLeave:{type:Function,default:Is},onClick:{type:Function,default:Is},intersectMode:{type:String,default:"move"},intersectRecursive:{type:Boolean,default:!1}},setup(){return{renderer:nt(en)}},mounted(){if(!this.renderer){console.error("Renderer not found");return}const i=this.renderer;this.renderer.onMounted(()=>{i.camera&&(this.pointer=Sf({camera:i.camera,domElement:i.canvas,intersectObjects:()=>i.scene?i.scene.children:[],intersectRecursive:this.intersectRecursive,onIntersectEnter:this.onPointerEnter,onIntersectOver:this.onPointerOver,onIntersectMove:this.onPointerMove,onIntersectLeave:this.onPointerLeave,onIntersectClick:this.onClick}),this.pointer.addListeners(),this.intersectMode==="frame"&&i.onBeforeRender(this.pointer.intersect))})},unmounted(){var i;this.pointer&&(this.pointer.removeListeners(),(i=this.renderer)==null||i.offBeforeRender(this.pointer.intersect))},render(){return[]},__hmrId:"Raycaster"}),ST=Le({extends:li,props:{cubeRTSize:{type:Number,default:256},cubeCameraNear:{type:Number,default:.1},cubeCameraFar:{type:Number,default:2e3},autoUpdate:Boolean,hideMeshes:{type:Array,default:()=>[]}},setup(i){const e=nt(en);if(!e||!e.scene)return console.error("Missing Renderer / Scene"),{};const t=e.renderer,n=e.scene,r=new e9(i.cubeRTSize,{format:Yt,generateMipmaps:!0,minFilter:Ni}),s=new _l(i.cubeCameraNear,i.cubeCameraFar,r),o=()=>{i.hideMeshes.forEach(a=>{a.visible=!1}),s.update(t,n),i.hideMeshes.forEach(a=>{a.visible=!0})};return i.autoUpdate?(e.onBeforeRender(o),Uc(()=>{e.offBeforeRender(o)})):e.onMounted(o),{cubeRT:r,cubeCamera:s,updateRT:o}},created(){this.cubeCamera&&this.initObject3D(this.cubeCamera)},render(){return[]},__hmrId:"CubeCamera"});const Do=Symbol("Mesh"),ds=Le({name:"Mesh",extends:li,props:{castShadow:Boolean,receiveShadow:Boolean},setup(){return{}},provide(){return{[Do]:this}},mounted(){!this.mesh&&!this.loading&&this.initMesh()},methods:{initMesh(){const i=new I0(this.geometry,this.material);z0(this,"castShadow",i),z0(this,"receiveShadow",i),this.mesh=i,this.initObject3D(i)},createGeometry(){},addGeometryWatchers(i){Object.keys(i).forEach(e=>{Ke(()=>this[e],()=>{this.refreshGeometry()})})},setGeometry(i){this.geometry=i,this.mesh&&(this.mesh.geometry=i)},setMaterial(i){this.material=i,this.mesh&&(this.mesh.material=i)},refreshGeometry(){const i=this.geometry;this.createGeometry(),this.mesh&&this.geometry&&(this.mesh.geometry=this.geometry),i==null||i.dispose()}},unmounted(){this.geometry&&this.geometry.dispose(),this.material&&this.material.dispose()},__hmrId:"Mesh"});function rt(i,e,t){return Le({name:i,extends:ds,props:e,created(){this.createGeometry(),this.addGeometryWatchers(e)},methods:{createGeometry(){this.geometry=t(this)}}})}const U9=Le({emits:["created"],props:{rotateX:Number,rotateY:Number,rotateZ:Number,attributes:{type:Array,default:()=>[]}},inject:{mesh:Do},setup(){return{}},created(){if(!this.mesh){console.error("Missing parent Mesh");return}this.createGeometry(),this.rotateGeometry(),this.geometry&&this.mesh.setGeometry(this.geometry),Object.keys(this.$props).forEach(i=>{Ke(()=>this[i],this.refreshGeometry)})},unmounted(){var i;(i=this.geometry)==null||i.dispose()},methods:{createGeometry(){const i={},e=new Fe;this.attributes.forEach(t=>{if(t.name&&t.itemSize&&t.array){const n=i[t.name]=new _0(t.array,t.itemSize,t.normalized);e.setAttribute(t.name,n)}}),e.computeBoundingBox(),e.userData.component=this,this.geometry=e,this.$emit("created",e)},rotateGeometry(){this.geometry&&(this.rotateX&&this.geometry.rotateX(this.rotateX),this.rotateY&&this.geometry.rotateY(this.rotateY),this.rotateZ&&this.geometry.rotateZ(this.rotateZ))},refreshGeometry(){const i=this.geometry;this.createGeometry(),this.rotateGeometry(),this.geometry&&this.mesh&&this.mesh.setGeometry(this.geometry),i==null||i.dispose()}},render(){return[]}});function Y0(i,e,t){return Le({name:i,extends:U9,props:e,methods:{createGeometry(){this.geometry=t(this),this.geometry.userData.component=this,this.$emit("created",this.geometry)}}})}const Lf={size:Number,width:{type:Number,default:1},height:{type:Number,default:1},depth:{type:Number,default:1},widthSegments:{type:Number,default:1},heightSegments:{type:Number,default:1},depthSegments:{type:Number,default:1}};function Pf(i){return i.size?new ho(i.size,i.size,i.size,i.widthSegments,i.heightSegments,i.depthSegments):new ho(i.width,i.height,i.depth,i.widthSegments,i.heightSegments,i.depthSegments)}var TT=Y0("BoxGeometry",Lf,Pf);const Cf={radius:{type:Number,default:1},segments:{type:Number,default:8},thetaStart:{type:Number,default:0},thetaLength:{type:Number,default:Math.PI*2}};function Rf(i){return new vw(i.radius,i.segments,i.thetaStart,i.thetaLength)}var AT=Y0("CircleGeometry",Cf,Rf);const Ff={radius:{type:Number,default:1},height:{type:Number,default:1},radialSegments:{type:Number,default:8},heightSegments:{type:Number,default:1},openEnded:{type:Boolean,default:!1},thetaStart:{type:Number,default:0},thetaLength:{type:Number,default:Math.PI*2}};function If(i){return new xw(i.radius,i.height,i.radialSegments,i.heightSegments,i.openEnded,i.thetaStart,i.thetaLength)}var ET=Y0("ConeGeometry",Ff,If);const Df={radiusTop:{type:Number,default:1},radiusBottom:{type:Number,default:1},height:{type:Number,default:1},radialSegments:{type:Number,default:8},heightSegments:{type:Number,default:1},openEnded:{type:Boolean,default:!1},thetaStart:{type:Number,default:0},thetaLength:{type:Number,default:Math.PI*2}};function Nf(i){return new q4(i.radiusTop,i.radiusBottom,i.height,i.radialSegments,i.heightSegments,i.openEnded,i.thetaStart,i.thetaLength)}var LT=Y0("CylinderGeometry",Df,Nf);const Of={radius:{type:Number,default:1},detail:{type:Number,default:0}};function Uf(i){return new yw(i.radius,i.detail)}var PT=Y0("DodecahedronGeometry",Of,Uf);const CT={shapes:{type:[Object,Array]},options:{type:Object}};function RT(i){return new ts(i.shapes,i.options)}var FT=Y0("ExtrudeGeometry",CT,RT);const zf={radius:{type:Number,default:1},detail:{type:Number,default:0}};function Bf(i){return new qw(i.radius,i.detail)}var IT=Y0("IcosahedronGeometry",zf,Bf);const kf={points:Array,segments:{type:Number,default:12},phiStart:{type:Number,default:0},phiLength:{type:Number,default:Math.PI*2}};function Gf(i){return new Qw(i.points,i.segments,i.phiStart,i.phiLength)}var DT=Y0("LatheGeometry",kf,Gf);const Hf={radius:{type:Number,default:1},detail:{type:Number,default:0}};function Vf(i){return new Zw(i.radius,i.detail)}var NT=Y0("OctahedronGeometry",Hf,Vf);const Wf={width:{type:Number,default:1},height:{type:Number,default:1},widthSegments:{type:Number,default:1},heightSegments:{type:Number,default:1}};function Xf(i){return new t9(i.width,i.height,i.widthSegments,i.heightSegments)}var OT=Y0("PlaneGeometry",Wf,Xf);const jf={vertices:Array,indices:Array,radius:{type:Number,default:1},detail:{type:Number,default:0}};function Yf(i){return new Lo(i.vertices,i.indices,i.radius,i.detail)}var UT=Y0("PolyhedronGeometry",jf,Yf);const qf={innerRadius:{type:Number,default:.5},outerRadius:{type:Number,default:1},thetaSegments:{type:Number,default:8},phiSegments:{type:Number,default:1},thetaStart:{type:Number,default:0},thetaLength:{type:Number,default:Math.PI*2}};function Qf(i){return new Kw(i.innerRadius,i.outerRadius,i.thetaSegments,i.phiSegments,i.thetaStart,i.thetaLength)}var zT=Y0("RingGeometry",qf,Qf);const Zf={radius:{type:Number,default:1},widthSegments:{type:Number,default:12},heightSegments:{type:Number,default:12},phiStart:{type:Number,default:0},phiLength:{type:Number,default:Math.PI*2},thetaStart:{type:Number,default:0},thetaLength:{type:Number,default:Math.PI}};function Kf(i){return new $w(i.radius,i.widthSegments,i.heightSegments,i.phiStart,i.phiLength,i.thetaStart,i.thetaLength)}var BT=Y0("SphereGeometry",Zf,Kf);const kT={shapes:{type:[Object,Array]},curveSegments:{type:Number}};function GT(i){return new c5(i.shapes,i.curveSegments)}var HT=Y0("ShapeGeometry",kT,GT);const Jf={radius:{type:Number,default:1},detail:{type:Number,default:0}};function $f(i){return new eM(i.radius,i.detail)}var VT=Y0("TetrahedronGeometry",Jf,$f);const ed={radius:{type:Number,default:1},tube:{type:Number,default:.4},radialSegments:{type:Number,default:8},tubularSegments:{type:Number,default:6},arc:{type:Number,default:Math.PI*2}};function td(i){return new tM(i.radius,i.tube,i.radialSegments,i.tubularSegments,i.arc)}var WT=Y0("TorusGeometry",ed,td);const nd={radius:{type:Number,default:1},tube:{type:Number,default:.4},tubularSegments:{type:Number,default:64},radialSegments:{type:Number,default:8},p:{type:Number,default:2},q:{type:Number,default:3}};function id(i){return new nM(i.radius,i.tube,i.tubularSegments,i.radialSegments,i.p,i.q)}var XT=Y0("TorusKnotGeometry",nd,id);const _c={points:Array,path:ut,tubularSegments:{type:Number,default:64},radius:{type:Number,default:1},radialSegments:{type:Number,default:8},closed:{type:Boolean,default:!1}};function rd(i){let e;return i.points?e=new Pl(i.points):i.path?e=i.path:console.error("Missing path curve or points."),new iM(e,i.tubularSegments,i.radius,i.radiusSegments,i.closed)}var jT=Le({extends:U9,props:_c,methods:{createGeometry(){this.geometry=rd(this)},updatePoints(i){sd(this.geometry,i)}}});function sd(i,e){const t=new Pl(e),{radialSegments:n,radius:r,tubularSegments:s,closed:o}=i.parameters,a=t.computeFrenetFrames(s,o);i.tangents=a.tangents,i.normals=a.normals,i.binormals=a.binormals,i.parameters.path=t;const l=i.getAttribute("position"),c=i.getAttribute("normal"),u=new P,h=new P;for(let d=0;d({x:512,y:512})},shadowCamera:{type:Object,default:()=>({})}},setup(){return{}},unmounted(){(this.light instanceof Gr||this.light instanceof Hr)&&this.removeFromParent(this.light.target)},methods:{initLight(i){this.light=i,i.shadow&&(i.castShadow=this.castShadow,So(i.shadow.mapSize,this.shadowMapSize),So(i.shadow.camera,this.shadowCamera)),["color","intensity","castShadow"].forEach(e=>{Ke(()=>this[e],t=>{e==="color"?i.color.set(t):i[e]=t})}),this.initObject3D(i),(i instanceof Gr||i instanceof Hr)&&(z0(this,"target",i.target,"position"),this.addToParent(i.target))}},__hmrId:"Light"}),od=Le({extends:ps,created(){this.initLight(new v9(this.color,this.intensity))},__hmrId:"AmbientLight"}),YT=Le({extends:ps,props:{target:{type:Object,default:()=>({x:0,y:0,z:0})}},created(){this.initLight(new Hr(this.color,this.intensity))},__hmrId:"DirectionalLight"}),qT=Le({extends:ps,props:{groundColor:{type:String,default:"#444444"}},created(){const i=new S5(this.color,this.groundColor,this.intensity);Ke(()=>this.groundColor,e=>{i.groundColor.set(e)}),this.initLight(i)},__hmrId:"HemisphereLight"}),QT=Le({extends:ps,props:{distance:{type:Number,default:0},decay:{type:Number,default:1}},created(){this.initLight(new vo(this.color,this.intensity,this.distance,this.decay))},__hmrId:"PointLight"}),ZT=Le({extends:ps,props:{width:{type:Number,default:10},height:{type:Number,default:10},helper:Boolean},created(){zM.init();const i=new L5(this.color,this.intensity,this.width,this.height);if(["width","height"].forEach(t=>{Ke(()=>this[t],n=>{i[t]=n})}),this.helper){const t=new BM(i);i.add(t)}this.initLight(i)},__hmrId:"RectAreaLight"}),KT=Le({extends:ps,props:{angle:{type:Number,default:Math.PI/3},decay:{type:Number,default:1},distance:{type:Number,default:0},penumbra:{type:Number,default:0},target:Object},created(){const i=new Gr(this.color,this.intensity,this.distance,this.angle,this.penumbra,this.decay);["angle","decay","distance","penumbra"].forEach(t=>{Ke(()=>this[t],n=>{i[t]=n})}),this.initLight(i)},__hmrId:"SpotLight"});const z9=Symbol("Material"),B9=Le({emits:["created"],props:{color:{type:String,default:"#ffffff"},props:{type:Object,default:()=>({})}},inject:{mesh:Do},setup(){return{}},provide(){return{[z9]:this}},created(){if(!this.mesh){console.error("Missing parent Mesh");return}if(this.createMaterial){const i=this.material=this.createMaterial();Ke(()=>this.color,e=>{i.color.set(e)}),ai(this,"props",i,!1,this.setProp),this.$emit("created",i),this.mesh.setMaterial(i)}},unmounted(){var i;(i=this.material)==null||i.dispose()},methods:{getMaterialParams(){return{...Fl(this.$props,["props"]),...this.props}},setProp(i,e,t,n=!1){const r=i[e];r instanceof be?r.set(t):i[e]=t,i.needsUpdate=n},setTexture(i,e="map"){this.setProp(this.material,e,i,!0)}},render(){return this.$slots.default?this.$slots.default():[]},__hmrId:"Material"});function tn(i,e,t){return Le({name:i,extends:B9,props:e,methods:{createMaterial(){return t(this.getMaterialParams())}}})}const JT=tn("BasicMaterial",{props:{type:Object,default:()=>({})}},i=>new xt(i)),$T=tn("LambertMaterial",{props:{type:Object,default:()=>({})}},i=>new m9(i)),eA=tn("PhongMaterial",{props:{type:Object,default:()=>({})}},i=>new Zs(i)),tA=tn("PhysicalMaterial",{props:{type:Object,default:()=>({})}},i=>new si(i)),nA=tn("PointsMaterial",{props:{type:Object,default:()=>({})}},i=>new El(i)),iA=tn("ShadowMaterial",{color:{type:String,default:"#000000"},props:{type:Object,default:()=>({})}},i=>new g5(i)),rA=tn("StandardMaterial",{props:{type:Object,default:()=>({})}},i=>new ns(i)),sA=tn("ToonMaterial",{props:{type:Object,default:()=>({})}},i=>new v5(i));var oA=tn("MatcapMaterial",{src:String,name:{type:String,default:"0404E8_0404B5_0404CB_3333FC"}},i=>{const e=i.src?i.src:Mf(i.name),t=Fl(i,["src","name"]);return t.matcap=new Bi().load(e),new y5(t)});const aA=` + }`})}};N9.BlurDirectionX=new ee(1,0);N9.BlurDirectionY=new ee(0,1);function Mo(i,e,t){e instanceof Object&&Object.entries(e).forEach(([n,r])=>{t?t(i,n,r):i[n]=r})}function ai(i,e,t,n=!0,r){n&&Mo(t,i[e],r);const s=xh(i,e);return Ze(s,o=>{Mo(t,o,r)})}function hT(i,e,t=!0,n){t&&Mo(e,i,n);const r=P0(i);return Ze(r,s=>{Mo(e,s,n)},{deep:!0})}function So(i,e){e instanceof Object&&Object.entries(e).forEach(([t,n])=>{i[t]=n})}function fT(i,e,t){e.forEach(n=>{B0(i,n,t,n)})}function B0(i,e,t,n){const r=n||e,s=xh(i,e);s.value instanceof Object?(So(t[r],s.value),Ze(s,o=>{So(t[r],o)},{deep:!0})):(s.value!==void 0&&(t[r]=i[e]),Ze(s,o=>{t[r]=o}))}function Il(i,e=[]){const t={};return Object.entries(i).forEach(([n,r])=>{(!e||!e.includes(n))&&(t[n]=r)}),t}function dT(i,e,t){return t=t<0?0:t,t=t>1?1:t,i+(e-i)*t}function pT(i,e,t){return it?t:i}const mT="https://rawcdn.githack.com/emmelleppi/matcaps/9b36ccaaf0a24881a39062d05566c9e92be4aa0d",gT="0404E8_0404B5_0404CB_3333FC";function Mf(i=gT,e=1024){const t=`${i}${vT(e)}.png`;return`${mT}/${e}/${t}`}function vT(i){switch(i){case 64:return"-64px";case 128:return"-128px";case 256:return"-256px";case 512:return"-512px";default:return""}}function xT(i){const{camera:e,resetPosition:t=new P(0,0,0)}=i,n=new FM,r=t.clone(),s=new Xt(new P(0,0,1),0);return{position:r,updatePosition:l=>{n.setFromCamera(l,e),e.getWorldDirection(s.normal),n.ray.intersectPlane(s,r)},intersect:(l,c,u=!1)=>(n.setFromCamera(l,e),n.intersectObjects(c,u))}}function Sf(i){const{camera:e,domElement:t,intersectObjects:n,intersectRecursive:r=!1,touch:s=!0,resetOnEnd:o=!1,onEnter:a=()=>{},onMove:l=()=>{},onLeave:c=()=>{},onClick:u=()=>{},onIntersectEnter:h=()=>{},onIntersectOver:f=()=>{},onIntersectMove:d=()=>{},onIntersectLeave:g=()=>{},onIntersectClick:v=()=>{}}=i,_=new ee(0,0),m=new ee(0,0),p=xT({camera:e}),y=p.position,x={position:_,positionN:m,positionV3:y,intersectObjects:n,listeners:!1,addListeners:G,removeListeners:j,intersect:b};return x;function w(){_.set(0,0),m.set(0,0),y.set(0,0,0)}function A(N){let k,K;N.touches&&N.touches.length>0?(k=N.touches[0].clientX,K=N.touches[0].clientY):(k=N.clientX,K=N.clientY);const le=t.getBoundingClientRect();_.x=k-le.left,_.y=K-le.top,m.x=_.x/le.width*2-1,m.y=-(_.y/le.height)*2+1,p.updatePosition(m)}function b(){const N=O();if(N.length){const k=p.intersect(m,N,r),K=[...N],le=[];k.forEach(ve=>{var ce,ye,$;const{object:se}=ve,me=Y(se);if(se instanceof Ya){if(le.indexOf(se)!==-1)return;le.push(se)}if(!se.userData.over){se.userData.over=!0;const V={type:"pointerover",over:!0,component:me,intersect:ve},te={...V,type:"pointerenter"};f(V),h(te),(ce=me==null?void 0:me.onPointerOver)==null||ce.call(me,V),(ye=me==null?void 0:me.onPointerEnter)==null||ye.call(me,te)}const Z={type:"pointermove",component:me,intersect:ve};d(Z),($=me==null?void 0:me.onPointerMove)==null||$.call(me,Z),K.splice(K.indexOf(se),1)}),K.forEach(ve=>{var ce,ye;const $=Y(ve);if(ve.userData.over){ve.userData.over=!1;const se={type:"pointerover",over:!1,component:$},me={...se,type:"pointerleave"};f(se),g(me),(ce=$==null?void 0:$.onPointerOver)==null||ce.call($,se),(ye=$==null?void 0:$.onPointerLeave)==null||ye.call($,me)}})}}function L(N){A(N),a({type:"pointerenter",position:_,positionN:m,positionV3:y})}function B(N){A(N),l({type:"pointermove",position:_,positionN:m,positionV3:y}),b()}function I(N){A(N);const k=O();if(k.length){const K=p.intersect(m,k,r),le=[];K.forEach(ve=>{var ce;const{object:ye}=ve,$=Y(ye);if(ye instanceof Ya){if(le.indexOf(ye)!==-1)return;le.push(ye)}const se={type:"click",component:$,intersect:ve};v(se),(ce=$==null?void 0:$.onClick)==null||ce.call($,se)})}u({type:"click",position:_,positionN:m,positionV3:y})}function C(){o&&w(),c({type:"pointerleave"})}function Y(N){if(N.userData.component)return N.userData.component;let k=N.parent;for(;k;){if(k.userData.component)return k.userData.component;k=k.parent}}function O(){return typeof n=="function"?n():n}function G(){t.addEventListener("mouseenter",L),t.addEventListener("mousemove",B),t.addEventListener("mouseleave",C),t.addEventListener("click",I),s&&(t.addEventListener("touchstart",L),t.addEventListener("touchmove",B),t.addEventListener("touchend",C)),x.listeners=!0}function j(){t.removeEventListener("mouseenter",L),t.removeEventListener("mousemove",B),t.removeEventListener("mouseleave",C),t.removeEventListener("click",I),t.removeEventListener("touchstart",L),t.removeEventListener("touchmove",B),t.removeEventListener("touchend",C),x.listeners=!1}}function yT(i){const e={antialias:!0,alpha:!1,autoClear:!0,orbitCtrl:!1,pointer:!1,resize:!1,width:300,height:150};i&&Object.entries(i).forEach(([y,x])=>{e[y]=x});const t={width:1,height:1,wWidth:1,wHeight:1,ratio:1},n=[],r=[],s=a(),o={config:e,renderer:s,size:t,init:l,dispose:v,render:h,renderC:f,setSize:m,addIntersectObject:d,removeIntersectObject:g};return o;function a(){const y=new o0({canvas:e.canvas,antialias:e.antialias,alpha:e.alpha,...e.params});return y.autoClear=e.autoClear,y}function l(){if(!o.scene)return console.error("Missing Scene"),!1;if(!o.camera)return console.error("Missing Camera"),!1;if(e.resize?(_(),window.addEventListener("resize",_)):e.width&&e.height&&m(e.width,e.height),c(),e.orbitCtrl){const y=new UM(o.camera,o.renderer.domElement);e.orbitCtrl instanceof Object&&Object.entries(e.orbitCtrl).forEach(([x,w])=>{y[x]=w}),u(()=>{y.update()}),o.cameraCtrl=y}return!0}function c(){let y={camera:o.camera,domElement:o.renderer.domElement,intersectObjects:r};e.pointer&&e.pointer instanceof Object&&(y={...y,...e.pointer});const x=o.pointer=Sf(y);(e.pointer||r.length)&&(x.addListeners(),y.intersectMode==="frame"&&u(x.intersect))}function u(y){n.push(y)}function h(){n.forEach(y=>y()),o.renderer.render(o.scene,o.camera)}function f(){n.forEach(y=>y()),o.composer.render()}function d(y){r.indexOf(y)===-1&&r.push(y),o.pointer&&!o.pointer.listeners&&o.pointer.addListeners()}function g(y){const x=r.indexOf(y);x!==-1&&r.splice(x,1),o.pointer&&!e.pointer&&r.length===0&&o.pointer.removeListeners()}function v(){window.removeEventListener("resize",_),o.pointer&&o.pointer.removeListeners(),o.cameraCtrl&&o.cameraCtrl.dispose(),o.renderer&&o.renderer.dispose()}function _(){var y;if(e.resize==="window")m(window.innerWidth,window.innerHeight);else{const x=o.renderer.domElement.parentNode;x&&m(x.clientWidth,x.clientHeight)}(y=e.onResize)==null||y.call(e,t)}function m(y,x){t.width=y,t.height=x,t.ratio=y/x,o.renderer.setSize(y,x,!1);const w=o.camera;if(w.type==="PerspectiveCamera"){const A=w;A.aspect=t.ratio,A.updateProjectionMatrix()}if(w.type==="OrthographicCamera"){const A=w;t.wWidth=A.right-A.left,t.wHeight=A.top-A.bottom}else{const A=p();t.wWidth=A[0],t.wHeight=A[1]}}function p(){const y=o.camera,x=y.fov*Math.PI/180,w=2*Math.tan(x/2)*Math.abs(y.position.z);return[w*y.aspect,w]}}const en=Symbol("Renderer");var Tf=Le({name:"Renderer",props:{params:{type:Object,default:()=>({})},antialias:Boolean,alpha:Boolean,autoClear:{type:Boolean,default:!0},orbitCtrl:{type:[Boolean,Object],default:!1},pointer:{type:[Boolean,Object],default:!1},resize:{type:[Boolean,String],default:!1},shadow:Boolean,width:String,height:String,pixelRatio:Number,xr:Boolean,props:{type:Object,default:()=>({})},onReady:Function},inheritAttrs:!1,setup(i,{attrs:e}){const t=[],n=[],r=[],s=[],o=[],a=document.createElement("canvas");Object.entries(e).forEach(([h,f])=>{const d=h.match(/^on([A-Z][a-zA-Z]*)$/);d?a.addEventListener(d[1].toLowerCase(),f):a.setAttribute(h,f)});const l={canvas:a,params:i.params,antialias:i.antialias,alpha:i.alpha,autoClear:i.autoClear,orbitCtrl:i.orbitCtrl,pointer:i.pointer,resize:i.resize};i.width&&(l.width=parseInt(i.width)),i.height&&(l.height=parseInt(i.height));const c=yT(l);ai(i,"props",c.renderer),w8(()=>{i.pixelRatio&&c.renderer.setPixelRatio(i.pixelRatio)});const u=()=>{};return{canvas:a,three:c,renderer:c.renderer,size:c.size,renderFn:u,raf:!0,initCallbacks:t,mountedCallbacks:n,beforeRenderCallbacks:r,afterRenderCallbacks:s,resizeCallbacks:o}},computed:{camera:{get:function(){return this.three.camera},set:function(i){this.three.camera=i}},scene:{get:function(){return this.three.scene},set:function(i){this.three.scene=i}},composer:{get:function(){return this.three.composer},set:function(i){this.three.composer=i}}},provide(){return{[en]:this}},mounted(){var i;this.$el.parentNode.insertBefore(this.canvas,this.$el),this.three.init()&&(this.three.pointer&&(this.$pointer=this.three.pointer),this.three.config.onResize=e=>{this.resizeCallbacks.forEach(t=>t({type:"resize",renderer:this,size:e}))},this.shadow&&(this.renderer.shadowMap.enabled=!0),this.renderFn=this.three.composer?this.three.renderC:this.three.render,this.initCallbacks.forEach(e=>e({type:"init",renderer:this})),(i=this.onReady)==null||i.call(this,this),this.xr?(this.renderer.xr.enabled=!0,this.renderer.setAnimationLoop(this.render)):requestAnimationFrame(this.renderLoop)),this.mountedCallbacks.forEach(e=>e({type:"mounted",renderer:this}))},beforeUnmount(){this.canvas.remove(),this.beforeRenderCallbacks=[],this.afterRenderCallbacks=[],this.raf=!1,this.three.dispose()},methods:{onInit(i){this.addListener("init",i)},onMounted(i){this.addListener("mounted",i)},onBeforeRender(i){this.addListener("beforerender",i)},offBeforeRender(i){this.removeListener("beforerender",i)},onAfterRender(i){this.addListener("afterrender",i)},offAfterRender(i){this.removeListener("afterrender",i)},onResize(i){this.addListener("resize",i)},offResize(i){this.removeListener("resize",i)},addListener(i,e){this.getCallbacks(i).push(e)},removeListener(i,e){const t=this.getCallbacks(i),n=t.indexOf(e);n!==-1&&t.splice(n,1)},getCallbacks(i){return i==="init"?this.initCallbacks:i==="mounted"?this.mountedCallbacks:i==="beforerender"?this.beforeRenderCallbacks:i==="afterrender"?this.afterRenderCallbacks:this.resizeCallbacks},render(i){this.beforeRenderCallbacks.forEach(e=>e({type:"beforerender",renderer:this,time:i})),this.renderFn({renderer:this,time:i}),this.afterRenderCallbacks.forEach(e=>e({type:"afterrender",renderer:this,time:i}))},renderLoop(i){this.raf&&requestAnimationFrame(this.renderLoop),this.render(i)}},render(){return this.$slots.default?this.$slots.default():[]},__hmrId:"Renderer"}),Af=Le({props:{props:{type:Object,default:()=>({})}},render(){return this.$slots.default?this.$slots.default():[]}});function il(i,e,t,n=!0){i[e]=t,n&&i.updateProjectionMatrix()}var _T=Le({extends:Af,name:"OrthographicCamera",props:{left:{type:Number,default:-1},right:{type:Number,default:1},top:{type:Number,default:1},bottom:{type:Number,default:-1},near:{type:Number,default:.1},far:{type:Number,default:2e3},zoom:{type:Number,default:1},position:{type:Object,default:()=>({x:0,y:0,z:0})}},setup(i){const e=nt(en);if(!e){console.error("Renderer not found");return}const t=new ii(i.left,i.right,i.top,i.bottom,i.near,i.far);return e.camera=t,B0(i,"position",t),ai(i,"props",t,!0,il),["left","right","top","bottom","near","far","zoom"].forEach(n=>{Ze(()=>i[n],r=>{il(t,n,r)})}),{renderer:e,camera:t}},__hmrId:"OrthographicCamera"}),_c=Le({extends:Af,name:"PerspectiveCamera",props:{aspect:{type:Number,default:1},far:{type:Number,default:2e3},fov:{type:Number,default:50},near:{type:Number,default:.1},position:{type:Object,default:()=>({x:0,y:0,z:0})},lookAt:{type:Object,default:null}},setup(i){var e;const t=nt(en);if(!t){console.error("Renderer not found");return}const n=new X0(i.fov,i.aspect,i.near,i.far);return t.camera=n,B0(i,"position",n),i.lookAt&&n.lookAt((e=i.lookAt.x)!=null?e:0,i.lookAt.y,i.lookAt.z),Ze(()=>i.lookAt,r=>{var s;n.lookAt((s=r.x)!=null?s:0,r.y,r.z)},{deep:!0}),ai(i,"props",n,!0,il),["aspect","far","fov","near"].forEach(r=>{Ze(()=>i[r],s=>{il(n,r,s)})}),{renderer:t,camera:n}},__hmrId:"PerspectiveCamera"});const O9=Symbol("Scene");var Ef=Le({name:"Scene",props:{background:[String,Number,Object]},setup(i){const e=nt(en),t=new o9;if(!e){console.error("Renderer not found");return}e.scene=t,ks(O9,t);const n=o=>{o&&(typeof o=="string"||typeof o=="number"?t.background instanceof be?t.background.set(o):t.background=new be(o):o instanceof A0&&(t.background=o))};return n(i.background),Ze(()=>i.background,n),{scene:t,add:o=>{t.add(o)},remove:o=>{t.remove(o)}}},render(){return this.$slots.default?this.$slots.default():[]},__hmrId:"Scene"});const bT={onPointerEnter:Function,onPointerOver:Function,onPointerMove:Function,onPointerLeave:Function,onPointerDown:Function,onPointerUp:Function,onClick:Function};var li=Le({name:"Object3D",inject:{renderer:en,scene:O9},emits:["created","ready"],props:{position:{type:Object,default:()=>({x:0,y:0,z:0})},rotation:{type:Object,default:()=>({x:0,y:0,z:0})},scale:{type:Object,default:()=>({x:1,y:1,z:1,order:"XYZ"})},lookAt:{type:Object,default:null},userData:{type:Object,default:()=>({})},visible:{type:Boolean,default:!0},props:{type:Object,default:()=>({})},disableAdd:{type:Boolean,default:!1},disableRemove:{type:Boolean,default:!1},...bT},setup(){return{}},created(){this.renderer||console.error("Missing parent Renderer"),this.scene||console.error("Missing parent Scene")},unmounted(){this.disableRemove||this.removeFromParent(),this.o3d&&this.renderer&&this.renderer.three.removeIntersectObject(this.o3d)},methods:{initObject3D(i){var e;this.o3d=i,i.userData.component=this,(this.onPointerEnter||this.onPointerOver||this.onPointerMove||this.onPointerLeave||this.onPointerDown||this.onPointerUp||this.onClick)&&this.renderer&&this.renderer.three.addIntersectObject(i),B0(this,"position",i),B0(this,"rotation",i),B0(this,"scale",i),B0(this,"userData",i.userData),B0(this,"visible",i),ai(this,"props",i),this.$emit("created",i),this.lookAt&&i.lookAt((e=this.lookAt.x)!=null?e:0,this.lookAt.y,this.lookAt.z),Ze(()=>this.lookAt,t=>{var n;i.lookAt((n=t.x)!=null?n:0,t.y,t.z)},{deep:!0}),this.parent=this.getParent(),this.disableAdd||(this.addToParent()?this.$emit("ready",this):console.error("Missing parent (Scene, Group...)"))},getParent(){let i=this.$parent;if(!i){const e=a6();e&&e.parent&&(i=e.parent.ctx)}for(;i;){if(i.add)return i;i=i.$parent}},addToParent(i){const e=i||this.o3d;return this.parent?(this.parent.add(e),!0):!1},removeFromParent(i){const e=i||this.o3d;return this.parent?(this.parent.remove(e),!0):!1},add(i){var e;(e=this.o3d)==null||e.add(i)},remove(i){var e;(e=this.o3d)==null||e.remove(i)}},render(){return this.$slots.default?this.$slots.default():[]},__hmrId:"Object3D"}),wT=Le({name:"Group",extends:li,setup(){return{group:new Dt}},created(){this.initObject3D(this.group)},__hmrId:"Group"});const Ds=()=>{};var MT=Le({name:"Raycaster",props:{onPointerEnter:{type:Function,default:Ds},onPointerOver:{type:Function,default:Ds},onPointerMove:{type:Function,default:Ds},onPointerLeave:{type:Function,default:Ds},onClick:{type:Function,default:Ds},intersectMode:{type:String,default:"move"},intersectRecursive:{type:Boolean,default:!1}},setup(){return{renderer:nt(en)}},mounted(){if(!this.renderer){console.error("Renderer not found");return}const i=this.renderer;this.renderer.onMounted(()=>{i.camera&&(this.pointer=Sf({camera:i.camera,domElement:i.canvas,intersectObjects:()=>i.scene?i.scene.children:[],intersectRecursive:this.intersectRecursive,onIntersectEnter:this.onPointerEnter,onIntersectOver:this.onPointerOver,onIntersectMove:this.onPointerMove,onIntersectLeave:this.onPointerLeave,onIntersectClick:this.onClick}),this.pointer.addListeners(),this.intersectMode==="frame"&&i.onBeforeRender(this.pointer.intersect))})},unmounted(){var i;this.pointer&&(this.pointer.removeListeners(),(i=this.renderer)==null||i.offBeforeRender(this.pointer.intersect))},render(){return[]},__hmrId:"Raycaster"}),ST=Le({extends:li,props:{cubeRTSize:{type:Number,default:256},cubeCameraNear:{type:Number,default:.1},cubeCameraFar:{type:Number,default:2e3},autoUpdate:Boolean,hideMeshes:{type:Array,default:()=>[]}},setup(i){const e=nt(en);if(!e||!e.scene)return console.error("Missing Renderer / Scene"),{};const t=e.renderer,n=e.scene,r=new e9(i.cubeRTSize,{format:Yt,generateMipmaps:!0,minFilter:Ni}),s=new bl(i.cubeCameraNear,i.cubeCameraFar,r),o=()=>{i.hideMeshes.forEach(a=>{a.visible=!1}),s.update(t,n),i.hideMeshes.forEach(a=>{a.visible=!0})};return i.autoUpdate?(e.onBeforeRender(o),zc(()=>{e.offBeforeRender(o)})):e.onMounted(o),{cubeRT:r,cubeCamera:s,updateRT:o}},created(){this.cubeCamera&&this.initObject3D(this.cubeCamera)},render(){return[]},__hmrId:"CubeCamera"});const Do=Symbol("Mesh"),ps=Le({name:"Mesh",extends:li,props:{castShadow:Boolean,receiveShadow:Boolean},setup(){return{}},provide(){return{[Do]:this}},mounted(){!this.mesh&&!this.loading&&this.initMesh()},methods:{initMesh(){const i=new I0(this.geometry,this.material);B0(this,"castShadow",i),B0(this,"receiveShadow",i),this.mesh=i,this.initObject3D(i)},createGeometry(){},addGeometryWatchers(i){Object.keys(i).forEach(e=>{Ze(()=>this[e],()=>{this.refreshGeometry()})})},setGeometry(i){this.geometry=i,this.mesh&&(this.mesh.geometry=i)},setMaterial(i){this.material=i,this.mesh&&(this.mesh.material=i)},refreshGeometry(){const i=this.geometry;this.createGeometry(),this.mesh&&this.geometry&&(this.mesh.geometry=this.geometry),i==null||i.dispose()}},unmounted(){this.geometry&&this.geometry.dispose(),this.material&&this.material.dispose()},__hmrId:"Mesh"});function rt(i,e,t){return Le({name:i,extends:ps,props:e,created(){this.createGeometry(),this.addGeometryWatchers(e)},methods:{createGeometry(){this.geometry=t(this)}}})}const U9=Le({emits:["created"],props:{rotateX:Number,rotateY:Number,rotateZ:Number,attributes:{type:Array,default:()=>[]}},inject:{mesh:Do},setup(){return{}},created(){if(!this.mesh){console.error("Missing parent Mesh");return}this.createGeometry(),this.rotateGeometry(),this.geometry&&this.mesh.setGeometry(this.geometry),Object.keys(this.$props).forEach(i=>{Ze(()=>this[i],this.refreshGeometry)})},unmounted(){var i;(i=this.geometry)==null||i.dispose()},methods:{createGeometry(){const i={},e=new Fe;this.attributes.forEach(t=>{if(t.name&&t.itemSize&&t.array){const n=i[t.name]=new _0(t.array,t.itemSize,t.normalized);e.setAttribute(t.name,n)}}),e.computeBoundingBox(),e.userData.component=this,this.geometry=e,this.$emit("created",e)},rotateGeometry(){this.geometry&&(this.rotateX&&this.geometry.rotateX(this.rotateX),this.rotateY&&this.geometry.rotateY(this.rotateY),this.rotateZ&&this.geometry.rotateZ(this.rotateZ))},refreshGeometry(){const i=this.geometry;this.createGeometry(),this.rotateGeometry(),this.geometry&&this.mesh&&this.mesh.setGeometry(this.geometry),i==null||i.dispose()}},render(){return[]}});function Y0(i,e,t){return Le({name:i,extends:U9,props:e,methods:{createGeometry(){this.geometry=t(this),this.geometry.userData.component=this,this.$emit("created",this.geometry)}}})}const Lf={size:Number,width:{type:Number,default:1},height:{type:Number,default:1},depth:{type:Number,default:1},widthSegments:{type:Number,default:1},heightSegments:{type:Number,default:1},depthSegments:{type:Number,default:1}};function Pf(i){return i.size?new ho(i.size,i.size,i.size,i.widthSegments,i.heightSegments,i.depthSegments):new ho(i.width,i.height,i.depth,i.widthSegments,i.heightSegments,i.depthSegments)}var TT=Y0("BoxGeometry",Lf,Pf);const Cf={radius:{type:Number,default:1},segments:{type:Number,default:8},thetaStart:{type:Number,default:0},thetaLength:{type:Number,default:Math.PI*2}};function Rf(i){return new vw(i.radius,i.segments,i.thetaStart,i.thetaLength)}var AT=Y0("CircleGeometry",Cf,Rf);const Ff={radius:{type:Number,default:1},height:{type:Number,default:1},radialSegments:{type:Number,default:8},heightSegments:{type:Number,default:1},openEnded:{type:Boolean,default:!1},thetaStart:{type:Number,default:0},thetaLength:{type:Number,default:Math.PI*2}};function If(i){return new xw(i.radius,i.height,i.radialSegments,i.heightSegments,i.openEnded,i.thetaStart,i.thetaLength)}var ET=Y0("ConeGeometry",Ff,If);const Df={radiusTop:{type:Number,default:1},radiusBottom:{type:Number,default:1},height:{type:Number,default:1},radialSegments:{type:Number,default:8},heightSegments:{type:Number,default:1},openEnded:{type:Boolean,default:!1},thetaStart:{type:Number,default:0},thetaLength:{type:Number,default:Math.PI*2}};function Nf(i){return new q4(i.radiusTop,i.radiusBottom,i.height,i.radialSegments,i.heightSegments,i.openEnded,i.thetaStart,i.thetaLength)}var LT=Y0("CylinderGeometry",Df,Nf);const Of={radius:{type:Number,default:1},detail:{type:Number,default:0}};function Uf(i){return new yw(i.radius,i.detail)}var PT=Y0("DodecahedronGeometry",Of,Uf);const CT={shapes:{type:[Object,Array]},options:{type:Object}};function RT(i){return new ns(i.shapes,i.options)}var FT=Y0("ExtrudeGeometry",CT,RT);const zf={radius:{type:Number,default:1},detail:{type:Number,default:0}};function Bf(i){return new qw(i.radius,i.detail)}var IT=Y0("IcosahedronGeometry",zf,Bf);const kf={points:Array,segments:{type:Number,default:12},phiStart:{type:Number,default:0},phiLength:{type:Number,default:Math.PI*2}};function Gf(i){return new Qw(i.points,i.segments,i.phiStart,i.phiLength)}var DT=Y0("LatheGeometry",kf,Gf);const Hf={radius:{type:Number,default:1},detail:{type:Number,default:0}};function Vf(i){return new Kw(i.radius,i.detail)}var NT=Y0("OctahedronGeometry",Hf,Vf);const Wf={width:{type:Number,default:1},height:{type:Number,default:1},widthSegments:{type:Number,default:1},heightSegments:{type:Number,default:1}};function Xf(i){return new t9(i.width,i.height,i.widthSegments,i.heightSegments)}var OT=Y0("PlaneGeometry",Wf,Xf);const jf={vertices:Array,indices:Array,radius:{type:Number,default:1},detail:{type:Number,default:0}};function Yf(i){return new Lo(i.vertices,i.indices,i.radius,i.detail)}var UT=Y0("PolyhedronGeometry",jf,Yf);const qf={innerRadius:{type:Number,default:.5},outerRadius:{type:Number,default:1},thetaSegments:{type:Number,default:8},phiSegments:{type:Number,default:1},thetaStart:{type:Number,default:0},thetaLength:{type:Number,default:Math.PI*2}};function Qf(i){return new Zw(i.innerRadius,i.outerRadius,i.thetaSegments,i.phiSegments,i.thetaStart,i.thetaLength)}var zT=Y0("RingGeometry",qf,Qf);const Kf={radius:{type:Number,default:1},widthSegments:{type:Number,default:12},heightSegments:{type:Number,default:12},phiStart:{type:Number,default:0},phiLength:{type:Number,default:Math.PI*2},thetaStart:{type:Number,default:0},thetaLength:{type:Number,default:Math.PI}};function Zf(i){return new $w(i.radius,i.widthSegments,i.heightSegments,i.phiStart,i.phiLength,i.thetaStart,i.thetaLength)}var BT=Y0("SphereGeometry",Kf,Zf);const kT={shapes:{type:[Object,Array]},curveSegments:{type:Number}};function GT(i){return new c5(i.shapes,i.curveSegments)}var HT=Y0("ShapeGeometry",kT,GT);const Jf={radius:{type:Number,default:1},detail:{type:Number,default:0}};function $f(i){return new eM(i.radius,i.detail)}var VT=Y0("TetrahedronGeometry",Jf,$f);const ed={radius:{type:Number,default:1},tube:{type:Number,default:.4},radialSegments:{type:Number,default:8},tubularSegments:{type:Number,default:6},arc:{type:Number,default:Math.PI*2}};function td(i){return new tM(i.radius,i.tube,i.radialSegments,i.tubularSegments,i.arc)}var WT=Y0("TorusGeometry",ed,td);const nd={radius:{type:Number,default:1},tube:{type:Number,default:.4},tubularSegments:{type:Number,default:64},radialSegments:{type:Number,default:8},p:{type:Number,default:2},q:{type:Number,default:3}};function id(i){return new nM(i.radius,i.tube,i.tubularSegments,i.radialSegments,i.p,i.q)}var XT=Y0("TorusKnotGeometry",nd,id);const bc={points:Array,path:ut,tubularSegments:{type:Number,default:64},radius:{type:Number,default:1},radialSegments:{type:Number,default:8},closed:{type:Boolean,default:!1}};function rd(i){let e;return i.points?e=new Cl(i.points):i.path?e=i.path:console.error("Missing path curve or points."),new iM(e,i.tubularSegments,i.radius,i.radiusSegments,i.closed)}var jT=Le({extends:U9,props:bc,methods:{createGeometry(){this.geometry=rd(this)},updatePoints(i){sd(this.geometry,i)}}});function sd(i,e){const t=new Cl(e),{radialSegments:n,radius:r,tubularSegments:s,closed:o}=i.parameters,a=t.computeFrenetFrames(s,o);i.tangents=a.tangents,i.normals=a.normals,i.binormals=a.binormals,i.parameters.path=t;const l=i.getAttribute("position"),c=i.getAttribute("normal"),u=new P,h=new P;for(let d=0;d({x:512,y:512})},shadowCamera:{type:Object,default:()=>({})}},setup(){return{}},unmounted(){(this.light instanceof Hr||this.light instanceof Vr)&&this.removeFromParent(this.light.target)},methods:{initLight(i){this.light=i,i.shadow&&(i.castShadow=this.castShadow,So(i.shadow.mapSize,this.shadowMapSize),So(i.shadow.camera,this.shadowCamera)),["color","intensity","castShadow"].forEach(e=>{Ze(()=>this[e],t=>{e==="color"?i.color.set(t):i[e]=t})}),this.initObject3D(i),(i instanceof Hr||i instanceof Vr)&&(B0(this,"target",i.target,"position"),this.addToParent(i.target))}},__hmrId:"Light"}),od=Le({extends:ms,created(){this.initLight(new v9(this.color,this.intensity))},__hmrId:"AmbientLight"}),YT=Le({extends:ms,props:{target:{type:Object,default:()=>({x:0,y:0,z:0})}},created(){this.initLight(new Vr(this.color,this.intensity))},__hmrId:"DirectionalLight"}),qT=Le({extends:ms,props:{groundColor:{type:String,default:"#444444"}},created(){const i=new S5(this.color,this.groundColor,this.intensity);Ze(()=>this.groundColor,e=>{i.groundColor.set(e)}),this.initLight(i)},__hmrId:"HemisphereLight"}),QT=Le({extends:ms,props:{distance:{type:Number,default:0},decay:{type:Number,default:1}},created(){this.initLight(new vo(this.color,this.intensity,this.distance,this.decay))},__hmrId:"PointLight"}),KT=Le({extends:ms,props:{width:{type:Number,default:10},height:{type:Number,default:10},helper:Boolean},created(){zM.init();const i=new L5(this.color,this.intensity,this.width,this.height);if(["width","height"].forEach(t=>{Ze(()=>this[t],n=>{i[t]=n})}),this.helper){const t=new BM(i);i.add(t)}this.initLight(i)},__hmrId:"RectAreaLight"}),ZT=Le({extends:ms,props:{angle:{type:Number,default:Math.PI/3},decay:{type:Number,default:1},distance:{type:Number,default:0},penumbra:{type:Number,default:0},target:Object},created(){const i=new Hr(this.color,this.intensity,this.distance,this.angle,this.penumbra,this.decay);["angle","decay","distance","penumbra"].forEach(t=>{Ze(()=>this[t],n=>{i[t]=n})}),this.initLight(i)},__hmrId:"SpotLight"});const z9=Symbol("Material"),B9=Le({emits:["created"],props:{color:{type:String,default:"#ffffff"},props:{type:Object,default:()=>({})}},inject:{mesh:Do},setup(){return{}},provide(){return{[z9]:this}},created(){if(!this.mesh){console.error("Missing parent Mesh");return}if(this.createMaterial){const i=this.material=this.createMaterial();Ze(()=>this.color,e=>{i.color.set(e)}),ai(this,"props",i,!1,this.setProp),this.$emit("created",i),this.mesh.setMaterial(i)}},unmounted(){var i;(i=this.material)==null||i.dispose()},methods:{getMaterialParams(){return{...Il(this.$props,["props"]),...this.props}},setProp(i,e,t,n=!1){const r=i[e];r instanceof be?r.set(t):i[e]=t,i.needsUpdate=n},setTexture(i,e="map"){this.setProp(this.material,e,i,!0)}},render(){return this.$slots.default?this.$slots.default():[]},__hmrId:"Material"});function tn(i,e,t){return Le({name:i,extends:B9,props:e,methods:{createMaterial(){return t(this.getMaterialParams())}}})}const JT=tn("BasicMaterial",{props:{type:Object,default:()=>({})}},i=>new xt(i)),$T=tn("LambertMaterial",{props:{type:Object,default:()=>({})}},i=>new m9(i)),eA=tn("PhongMaterial",{props:{type:Object,default:()=>({})}},i=>new Ks(i)),tA=tn("PhysicalMaterial",{props:{type:Object,default:()=>({})}},i=>new si(i)),nA=tn("PointsMaterial",{props:{type:Object,default:()=>({})}},i=>new Ll(i)),iA=tn("ShadowMaterial",{color:{type:String,default:"#000000"},props:{type:Object,default:()=>({})}},i=>new g5(i)),rA=tn("StandardMaterial",{props:{type:Object,default:()=>({})}},i=>new is(i)),sA=tn("ToonMaterial",{props:{type:Object,default:()=>({})}},i=>new v5(i));var oA=tn("MatcapMaterial",{src:String,name:{type:String,default:"0404E8_0404B5_0404CB_3333FC"}},i=>{const e=i.src?i.src:Mf(i.name),t=Il(i,["src","name"]);return t.matcap=new Bi().load(e),new y5(t)});const aA=` varying vec2 vUv; void main(){ vUv = uv; @@ -5383,7 +5383,7 @@ version 0.6.9 void main() { gl_FragColor = vec4(vUv.x, vUv.y, 0., 1.0); } -`;var cA=tn("ShaderMaterial",{props:{type:Object,default:()=>({uniforms:{},vertexShader:aA,fragmentShader:lA})}},i=>new u0(Fl(i,["color"])));function uA(i,e,t){return i.split(e).join(t)}const hA=De.meshphong_frag.slice(0,De.meshphong_frag.indexOf("void main() {")),fA=De.meshphong_frag.slice(De.meshphong_frag.indexOf("void main() {")),dA={uniforms:K0.merge([Pt.phong.uniforms,{thicknessColor:{value:new be(16777215)},thicknessDistortion:{value:.1},thicknessAmbient:{value:0},thicknessAttenuation:{value:.1},thicknessPower:{value:2},thicknessScale:{value:10}}]),vertexShader:` +`;var cA=tn("ShaderMaterial",{props:{type:Object,default:()=>({uniforms:{},vertexShader:aA,fragmentShader:lA})}},i=>new u0(Il(i,["color"])));function uA(i,e,t){return i.split(e).join(t)}const hA=De.meshphong_frag.slice(0,De.meshphong_frag.indexOf("void main() {")),fA=De.meshphong_frag.slice(De.meshphong_frag.indexOf("void main() {")),dA={uniforms:Z0.merge([Pt.phong.uniforms,{thicknessColor:{value:new be(16777215)},thicknessDistortion:{value:.1},thicknessAmbient:{value:0},thicknessAttenuation:{value:.1},thicknessPower:{value:2},thicknessScale:{value:10}}]),vertexShader:` #define USE_UV ${De.meshphong_vert} `,fragmentShader:` @@ -5415,7 +5415,7 @@ version 0.6.9 #if defined( SUBSURFACE ) && defined( USE_UV ) RE_Direct_Scattering(directLight, vUv, geometry, reflectedLight); #endif - `))};var pA=Le({extends:B9,props:{uniforms:{type:Object,default:()=>({diffuse:"#ffffff",thicknessColor:"#ffffff",thicknessDistortion:.4,thicknessAmbient:.01,thicknessAttenuation:.7,thicknessPower:2,thicknessScale:4})}},methods:{createMaterial(){const i=dA,e=K0.clone(i.uniforms);return ai(this,"uniforms",e,!0,(n,r,s)=>{const o=n[r].value;o instanceof be?o.set(s):n[r].value=s}),new u0({...i,lights:!0,...this.props,uniforms:e})}}}),k9=Le({inject:{material:z9},props:{name:{type:String,default:"map"},uniform:String,src:String,onLoad:Function,onProgress:Function,onError:Function,props:{type:Object,default:()=>({})}},setup(){return{}},created(){this.refreshTexture(),Ke(()=>this.src,this.refreshTexture)},unmounted(){var i,e;(i=this.material)==null||i.setTexture(null,this.name),(e=this.texture)==null||e.dispose()},methods:{createTexture(){if(this.src)return new Bi().load(this.src,this.onLoaded,this.onProgress,this.onError)},initTexture(){this.texture&&(ai(this,"props",this.texture),this.material&&(this.material.setTexture(this.texture,this.name),this.material.material instanceof u0&&this.uniform&&(this.material.material.uniforms[this.uniform]={value:this.texture})))},refreshTexture(){var i;(i=this.texture)==null||i.dispose(),this.texture=this.createTexture(),this.initTexture()},onLoaded(i){var e;(e=this.onLoad)==null||e.call(this,i)}},render(){return[]}}),mA=Le({extends:k9,props:{name:{type:String,default:"envMap"},path:{type:String,required:!0},urls:{type:Array,default:()=>["px.jpg","nx.jpg","py.jpg","ny.jpg","pz.jpg","nz.jpg"]},props:{type:Object,default:()=>({mapping:Zr})}},created(){Ke(()=>this.path,this.refreshTexture),Ke(()=>this.urls,this.refreshTexture)},methods:{createTexture(){return new M5().setPath(this.path).load(this.urls,this.onLoaded,this.onProgress,this.onError)}}}),gA=Le({extends:k9,props:{videoId:{type:String,required:!0}},created(){Ke(()=>this.videoId,this.refreshTexture)},methods:{createTexture(){const i=document.getElementById(this.videoId);return new X4(i)}}}),vA=rt("Box",Lf,Pf),xA=rt("Circle",Cf,Rf),yA=rt("Cone",Ff,If),_A=rt("Cylinder",Df,Nf),bA=rt("Dodecahedron",Of,Uf),wA=rt("Icosahedron",zf,Bf),MA=rt("Lathe",kf,Gf),SA=rt("Octahedron",Hf,Vf),TA=rt("Plane",Wf,Xf),AA=rt("Polyhedron",jf,Yf),EA=rt("Ring",qf,Qf),LA=rt("Sphere",Zf,Kf),PA=rt("Tetrahedron",Jf,$f);const CA={text:{type:String,required:!0,default:"Text"},fontSrc:{type:String,required:!0},size:{type:Number,default:80},height:{type:Number,default:5},depth:{type:Number,default:1},curveSegments:{type:Number,default:12},bevelEnabled:{type:Boolean,default:!1},bevelThickness:{type:Number,default:10},bevelSize:{type:Number,default:8},bevelOffset:{type:Number,default:0},bevelSegments:{type:Number,default:5},align:{type:[Boolean,String],default:!1}};var RA=Le({extends:ds,props:CA,setup(){return{}},created(){if(!this.fontSrc){console.error('Missing required prop: "font-src"');return}["text","size","height","curveSegments","bevelEnabled","bevelThickness","bevelSize","bevelOffset","bevelSegments","align"].forEach(t=>{Ke(()=>this[t],()=>{this.font&&this.refreshGeometry()})});const e=new GM;this.loading=!0,e.load(this.fontSrc,t=>{this.loading=!1,this.font=t,this.createGeometry(),this.initMesh()})},methods:{createGeometry(){this.geometry=new kM(this.text,{font:this.font,size:this.size,height:this.height,depth:this.depth,curveSegments:this.curveSegments,bevelEnabled:this.bevelEnabled,bevelThickness:this.bevelThickness,bevelSize:this.bevelSize,bevelOffset:this.bevelOffset,bevelSegments:this.bevelSegments}),this.align==="center"&&this.geometry.center()}}}),FA=rt("Torus",ed,td),IA=rt("TorusKnot",nd,id),DA=Le({extends:ds,props:_c,created(){this.createGeometry(),this.addGeometryWatchers(_c)},methods:{createGeometry(){this.geometry=rd(this)},updatePoints(i){sd(this.geometry,i)}},__hmrId:"Tube"}),NA=Le({emits:["loaded"],extends:ds,props:{src:{type:String,required:!0},width:Number,height:Number,widthSegments:{type:Number,default:1},heightSegments:{type:Number,default:1},keepSize:Boolean},setup(){return{}},created(){this.renderer&&(this.geometry=new t9(1,1,this.widthSegments,this.heightSegments),this.material=new xt({side:Zn,map:this.loadTexture()}),Ke(()=>this.src,this.refreshTexture),["width","height"].forEach(i=>{Ke(()=>this[i],this.resize)}),this.resize(),this.keepSize&&this.renderer.onResize(this.resize))},unmounted(){var i;(i=this.renderer)==null||i.offResize(this.resize)},methods:{loadTexture(){return new Bi().load(this.src,this.onLoaded)},refreshTexture(){var i;(i=this.texture)==null||i.dispose(),this.material&&(this.material.map=this.loadTexture(),this.material.needsUpdate=!0)},onLoaded(i){this.texture=i,this.resize(),this.$emit("loaded",i)},resize(){if(!this.renderer||!this.texture)return;const i=this.renderer.size,e=this.texture.image.width,t=this.texture.image.height,n=e/t;let r=1,s=1;this.width&&this.height?(r=this.width*i.wWidth/i.width,s=this.height*i.wHeight/i.height):this.width?(r=this.width*i.wWidth/i.width,s=r/n):this.height?(s=this.height*i.wHeight/i.height,r=s*n):n>1?r=s*n:s=r/n,this.mesh&&(this.mesh.scale.x=r,this.mesh.scale.y=s)}},__hmrId:"Image"}),OA=Le({extends:ds,props:{count:{type:Number,required:!0}},methods:{initMesh(){if(this.renderer){if(!this.geometry||!this.material)return console.error("Missing geometry and/or material"),!1;this.mesh=new Ya(this.geometry,this.material,this.count),this.mesh.userData.component=this,z0(this,"castShadow",this.mesh),z0(this,"receiveShadow",this.mesh),(this.onPointerEnter||this.onPointerOver||this.onPointerMove||this.onPointerLeave||this.onPointerDown||this.onPointerUp||this.onClick)&&this.renderer.three.addIntersectObject(this.mesh),this.initObject3D(this.mesh)}}},__hmrId:"InstancedMesh"}),UA=Le({extends:li,emits:["loaded"],props:{src:{type:String,required:!0}},setup(){return{}},created(){this.texture=new Bi().load(this.src,this.onLoaded),this.material=new a9({map:this.texture}),this.sprite=new V4(this.material),this.initObject3D(this.sprite)},unmounted(){var i,e;(i=this.texture)==null||i.dispose(),(e=this.material)==null||e.dispose()},methods:{onLoaded(){this.updateUV(),this.$emit("loaded")},updateUV(){if(!this.texture||!this.sprite)return;const i=this.texture.image.width,e=this.texture.image.height,t=i/e;let n=.5,r=.5;t>1?n=.5*t:r=.5/t;const s=this.sprite.geometry.attributes.position.array;s[0]=-n,s[1]=-r,s[5]=n,s[6]=-r,s[10]=n,s[11]=r,s[15]=-n,s[16]=r,this.sprite.geometry.attributes.position.needsUpdate=!0}},__hmrId:"Sprite"}),zA=Le({extends:li,setup(){return{}},provide(){return{[Do]:this}},mounted(){this.mesh=this.points=new l9(this.geometry,this.material),this.initObject3D(this.mesh)},methods:{setGeometry(i){this.geometry=i,this.mesh&&(this.mesh.geometry=i)},setMaterial(i){this.material=i,this.mesh&&(this.mesh.material=i)}}}),ad=Le({extends:li,emits:["before-load","load","progress","error"],props:{src:{type:String,required:!0}},data(){return{progress:0}},methods:{onLoad(i){this.$emit("load",i)},onProgress(i){this.progress=i.loaded/i.total,this.$emit("progress",i)},onError(i){this.$emit("error",i)}}}),ld=Le({extends:ad,created(){const i=new WM;this.$emit("before-load",i),i.load(this.src,e=>{this.onLoad(e),this.initObject3D(e.scene)},this.onProgress,this.onError)}}),BA=Le({extends:ad,created(){const i=new WS;this.$emit("before-load",i),i.load(this.src,e=>{this.onLoad(e),this.initObject3D(e)},this.onProgress,this.onError)}});const G9=Symbol("Composer");var kA=Le({setup(){return{renderer:nt(en)}},provide(){return{[G9]:this}},created(){if(!this.renderer){console.error("Renderer not found");return}const i=this.renderer,e=new rT(this.renderer.renderer);this.composer=e,this.renderer.composer=e,i.addListener("init",()=>{i.renderer.autoClear=!1,this.resize(),i.addListener("resize",this.resize)})},unmounted(){var i;(i=this.renderer)==null||i.removeListener("resize",this.resize)},methods:{addPass(i){var e;(e=this.composer)==null||e.addPass(i)},removePass(i){var e;(e=this.composer)==null||e.removePass(i)},resize(){this.composer&&this.renderer&&this.composer.setSize(this.renderer.size.width,this.renderer.size.height)}},render(){return this.$slots.default?this.$slots.default():[]},__hmrId:"EffectComposer"}),kt=Le({inject:{renderer:en,composer:G9},emits:["ready"],setup(){return{}},created(){this.composer||console.error("Missing parent EffectComposer"),this.renderer||console.error("Missing parent Renderer")},unmounted(){var i,e,t;this.pass&&((i=this.composer)==null||i.removePass(this.pass),(t=(e=this.pass).dispose)==null||t.call(e))},methods:{initEffectPass(i){var e;this.pass=i,(e=this.composer)==null||e.addPass(i),this.$emit("ready",i)}},render(){return[]},__hmrId:"EffectPass"}),GA=Le({extends:kt,created(){if(!this.renderer)return;if(!this.renderer.scene){console.error("Missing Scene");return}if(!this.renderer.camera){console.error("Missing Camera");return}const i=new sT(this.renderer.scene,this.renderer.camera);this.initEffectPass(i)},__hmrId:"RenderPass"});const H3={focus:{type:Number,default:1},aperture:{type:Number,default:.025},maxblur:{type:Number,default:.01}};var HA=Le({extends:kt,props:H3,created(){if(!this.renderer)return;if(!this.renderer.scene){console.error("Missing Scene");return}if(!this.renderer.camera){console.error("Missing Camera");return}const i={focus:this.focus,aperture:this.aperture,maxblur:this.maxblur,width:this.renderer.size.width,height:this.renderer.size.height},e=new oT(this.renderer.scene,this.renderer.camera,i);Object.keys(H3).forEach(t=>{Ke(()=>this[t],n=>{e.uniforms[t].value=n})}),this.initEffectPass(e)},__hmrId:"BokehPass"});const V3={noiseIntensity:{type:Number,default:.5},scanlinesIntensity:{type:Number,default:.05},scanlinesCount:{type:Number,default:4096},grayscale:{type:Number,default:0}};var VA=Le({extends:kt,props:V3,created(){const i=new aT(this.noiseIntensity,this.scanlinesIntensity,this.scanlinesCount,this.grayscale);Object.keys(V3).forEach(e=>{Ke(()=>this[e],t=>{i.uniforms[e].value=t})}),this.initEffectPass(i)},__hmrId:"FilmPass"}),WA=Le({extends:kt,created(){var i;const e=new Xr(lT);(i=this.renderer)==null||i.addListener("resize",this.resize),this.initEffectPass(e)},unmounted(){var i;(i=this.renderer)==null||i.removeListener("resize",this.resize)},methods:{resize({size:i}){if(this.pass){const{resolution:e}=this.pass.material.uniforms;e.value.x=1/i.width,e.value.y=1/i.height}}},__hmrId:"FXAAPass"});const W3={shape:{type:Number,default:1},radius:{type:Number,default:4},rotateR:{type:Number,default:Math.PI/12*1},rotateG:{type:Number,default:Math.PI/12*2},rotateB:{type:Number,default:Math.PI/12*3},scatter:{type:Number,default:0}};var XA=Le({extends:kt,props:W3,created(){if(!this.renderer)return;const i=new cT(this.renderer.size.width,this.renderer.size.height,{});Object.keys(W3).forEach(e=>{i.uniforms[e].value=this[e],Ke(()=>this[e],t=>{i.uniforms[e].value=t})}),this.initEffectPass(i)},__hmrId:"HalftonePass"}),jA=Le({extends:kt,created(){if(!this.renderer)return;const i=new uT(this.renderer.size.width,this.renderer.size.height);this.initEffectPass(i)},__hmrId:"SMAAPass"}),YA=Le({extends:kt,props:{options:{type:Object,default:()=>({})}},created(){if(!this.renderer)return;if(!this.renderer.scene){console.error("Missing Scene");return}if(!this.renderer.camera){console.error("Missing Camera");return}const i=new wf(this.renderer.scene,this.renderer.camera,this.renderer.size.width,this.renderer.size.height);Object.keys(this.options).forEach(e=>{i[e]=this.options[e]}),this.initEffectPass(i)},__hmrId:"SSAOPass"}),cd={uniforms:{},vertexShader:` + `))};var pA=Le({extends:B9,props:{uniforms:{type:Object,default:()=>({diffuse:"#ffffff",thicknessColor:"#ffffff",thicknessDistortion:.4,thicknessAmbient:.01,thicknessAttenuation:.7,thicknessPower:2,thicknessScale:4})}},methods:{createMaterial(){const i=dA,e=Z0.clone(i.uniforms);return ai(this,"uniforms",e,!0,(n,r,s)=>{const o=n[r].value;o instanceof be?o.set(s):n[r].value=s}),new u0({...i,lights:!0,...this.props,uniforms:e})}}}),k9=Le({inject:{material:z9},props:{name:{type:String,default:"map"},uniform:String,src:String,onLoad:Function,onProgress:Function,onError:Function,props:{type:Object,default:()=>({})}},setup(){return{}},created(){this.refreshTexture(),Ze(()=>this.src,this.refreshTexture)},unmounted(){var i,e;(i=this.material)==null||i.setTexture(null,this.name),(e=this.texture)==null||e.dispose()},methods:{createTexture(){if(this.src)return new Bi().load(this.src,this.onLoaded,this.onProgress,this.onError)},initTexture(){this.texture&&(ai(this,"props",this.texture),this.material&&(this.material.setTexture(this.texture,this.name),this.material.material instanceof u0&&this.uniform&&(this.material.material.uniforms[this.uniform]={value:this.texture})))},refreshTexture(){var i;(i=this.texture)==null||i.dispose(),this.texture=this.createTexture(),this.initTexture()},onLoaded(i){var e;(e=this.onLoad)==null||e.call(this,i)}},render(){return[]}}),mA=Le({extends:k9,props:{name:{type:String,default:"envMap"},path:{type:String,required:!0},urls:{type:Array,default:()=>["px.jpg","nx.jpg","py.jpg","ny.jpg","pz.jpg","nz.jpg"]},props:{type:Object,default:()=>({mapping:Zr})}},created(){Ze(()=>this.path,this.refreshTexture),Ze(()=>this.urls,this.refreshTexture)},methods:{createTexture(){return new M5().setPath(this.path).load(this.urls,this.onLoaded,this.onProgress,this.onError)}}}),gA=Le({extends:k9,props:{videoId:{type:String,required:!0}},created(){Ze(()=>this.videoId,this.refreshTexture)},methods:{createTexture(){const i=document.getElementById(this.videoId);return new X4(i)}}}),vA=rt("Box",Lf,Pf),xA=rt("Circle",Cf,Rf),yA=rt("Cone",Ff,If),_A=rt("Cylinder",Df,Nf),bA=rt("Dodecahedron",Of,Uf),wA=rt("Icosahedron",zf,Bf),MA=rt("Lathe",kf,Gf),SA=rt("Octahedron",Hf,Vf),TA=rt("Plane",Wf,Xf),AA=rt("Polyhedron",jf,Yf),EA=rt("Ring",qf,Qf),LA=rt("Sphere",Kf,Zf),PA=rt("Tetrahedron",Jf,$f);const CA={text:{type:String,required:!0,default:"Text"},fontSrc:{type:String,required:!0},size:{type:Number,default:80},height:{type:Number,default:5},depth:{type:Number,default:1},curveSegments:{type:Number,default:12},bevelEnabled:{type:Boolean,default:!1},bevelThickness:{type:Number,default:10},bevelSize:{type:Number,default:8},bevelOffset:{type:Number,default:0},bevelSegments:{type:Number,default:5},align:{type:[Boolean,String],default:!1}};var RA=Le({extends:ps,props:CA,setup(){return{}},created(){if(!this.fontSrc){console.error('Missing required prop: "font-src"');return}["text","size","height","curveSegments","bevelEnabled","bevelThickness","bevelSize","bevelOffset","bevelSegments","align"].forEach(t=>{Ze(()=>this[t],()=>{this.font&&this.refreshGeometry()})});const e=new GM;this.loading=!0,e.load(this.fontSrc,t=>{this.loading=!1,this.font=t,this.createGeometry(),this.initMesh()})},methods:{createGeometry(){this.geometry=new kM(this.text,{font:this.font,size:this.size,height:this.height,depth:this.depth,curveSegments:this.curveSegments,bevelEnabled:this.bevelEnabled,bevelThickness:this.bevelThickness,bevelSize:this.bevelSize,bevelOffset:this.bevelOffset,bevelSegments:this.bevelSegments}),this.align==="center"&&this.geometry.center()}}}),FA=rt("Torus",ed,td),IA=rt("TorusKnot",nd,id),DA=Le({extends:ps,props:bc,created(){this.createGeometry(),this.addGeometryWatchers(bc)},methods:{createGeometry(){this.geometry=rd(this)},updatePoints(i){sd(this.geometry,i)}},__hmrId:"Tube"}),NA=Le({emits:["loaded"],extends:ps,props:{src:{type:String,required:!0},width:Number,height:Number,widthSegments:{type:Number,default:1},heightSegments:{type:Number,default:1},keepSize:Boolean},setup(){return{}},created(){this.renderer&&(this.geometry=new t9(1,1,this.widthSegments,this.heightSegments),this.material=new xt({side:Kn,map:this.loadTexture()}),Ze(()=>this.src,this.refreshTexture),["width","height"].forEach(i=>{Ze(()=>this[i],this.resize)}),this.resize(),this.keepSize&&this.renderer.onResize(this.resize))},unmounted(){var i;(i=this.renderer)==null||i.offResize(this.resize)},methods:{loadTexture(){return new Bi().load(this.src,this.onLoaded)},refreshTexture(){var i;(i=this.texture)==null||i.dispose(),this.material&&(this.material.map=this.loadTexture(),this.material.needsUpdate=!0)},onLoaded(i){this.texture=i,this.resize(),this.$emit("loaded",i)},resize(){if(!this.renderer||!this.texture)return;const i=this.renderer.size,e=this.texture.image.width,t=this.texture.image.height,n=e/t;let r=1,s=1;this.width&&this.height?(r=this.width*i.wWidth/i.width,s=this.height*i.wHeight/i.height):this.width?(r=this.width*i.wWidth/i.width,s=r/n):this.height?(s=this.height*i.wHeight/i.height,r=s*n):n>1?r=s*n:s=r/n,this.mesh&&(this.mesh.scale.x=r,this.mesh.scale.y=s)}},__hmrId:"Image"}),OA=Le({extends:ps,props:{count:{type:Number,required:!0}},methods:{initMesh(){if(this.renderer){if(!this.geometry||!this.material)return console.error("Missing geometry and/or material"),!1;this.mesh=new Ya(this.geometry,this.material,this.count),this.mesh.userData.component=this,B0(this,"castShadow",this.mesh),B0(this,"receiveShadow",this.mesh),(this.onPointerEnter||this.onPointerOver||this.onPointerMove||this.onPointerLeave||this.onPointerDown||this.onPointerUp||this.onClick)&&this.renderer.three.addIntersectObject(this.mesh),this.initObject3D(this.mesh)}}},__hmrId:"InstancedMesh"}),UA=Le({extends:li,emits:["loaded"],props:{src:{type:String,required:!0}},setup(){return{}},created(){this.texture=new Bi().load(this.src,this.onLoaded),this.material=new a9({map:this.texture}),this.sprite=new V4(this.material),this.initObject3D(this.sprite)},unmounted(){var i,e;(i=this.texture)==null||i.dispose(),(e=this.material)==null||e.dispose()},methods:{onLoaded(){this.updateUV(),this.$emit("loaded")},updateUV(){if(!this.texture||!this.sprite)return;const i=this.texture.image.width,e=this.texture.image.height,t=i/e;let n=.5,r=.5;t>1?n=.5*t:r=.5/t;const s=this.sprite.geometry.attributes.position.array;s[0]=-n,s[1]=-r,s[5]=n,s[6]=-r,s[10]=n,s[11]=r,s[15]=-n,s[16]=r,this.sprite.geometry.attributes.position.needsUpdate=!0}},__hmrId:"Sprite"}),zA=Le({extends:li,setup(){return{}},provide(){return{[Do]:this}},mounted(){this.mesh=this.points=new l9(this.geometry,this.material),this.initObject3D(this.mesh)},methods:{setGeometry(i){this.geometry=i,this.mesh&&(this.mesh.geometry=i)},setMaterial(i){this.material=i,this.mesh&&(this.mesh.material=i)}}}),ad=Le({extends:li,emits:["before-load","load","progress","error"],props:{src:{type:String,required:!0}},data(){return{progress:0}},methods:{onLoad(i){this.$emit("load",i)},onProgress(i){this.progress=i.loaded/i.total,this.$emit("progress",i)},onError(i){this.$emit("error",i)}}}),ld=Le({extends:ad,created(){const i=new WM;this.$emit("before-load",i),i.load(this.src,e=>{this.onLoad(e),this.initObject3D(e.scene)},this.onProgress,this.onError)}}),BA=Le({extends:ad,created(){const i=new WS;this.$emit("before-load",i),i.load(this.src,e=>{this.onLoad(e),this.initObject3D(e)},this.onProgress,this.onError)}});const G9=Symbol("Composer");var kA=Le({setup(){return{renderer:nt(en)}},provide(){return{[G9]:this}},created(){if(!this.renderer){console.error("Renderer not found");return}const i=this.renderer,e=new rT(this.renderer.renderer);this.composer=e,this.renderer.composer=e,i.addListener("init",()=>{i.renderer.autoClear=!1,this.resize(),i.addListener("resize",this.resize)})},unmounted(){var i;(i=this.renderer)==null||i.removeListener("resize",this.resize)},methods:{addPass(i){var e;(e=this.composer)==null||e.addPass(i)},removePass(i){var e;(e=this.composer)==null||e.removePass(i)},resize(){this.composer&&this.renderer&&this.composer.setSize(this.renderer.size.width,this.renderer.size.height)}},render(){return this.$slots.default?this.$slots.default():[]},__hmrId:"EffectComposer"}),kt=Le({inject:{renderer:en,composer:G9},emits:["ready"],setup(){return{}},created(){this.composer||console.error("Missing parent EffectComposer"),this.renderer||console.error("Missing parent Renderer")},unmounted(){var i,e,t;this.pass&&((i=this.composer)==null||i.removePass(this.pass),(t=(e=this.pass).dispose)==null||t.call(e))},methods:{initEffectPass(i){var e;this.pass=i,(e=this.composer)==null||e.addPass(i),this.$emit("ready",i)}},render(){return[]},__hmrId:"EffectPass"}),GA=Le({extends:kt,created(){if(!this.renderer)return;if(!this.renderer.scene){console.error("Missing Scene");return}if(!this.renderer.camera){console.error("Missing Camera");return}const i=new sT(this.renderer.scene,this.renderer.camera);this.initEffectPass(i)},__hmrId:"RenderPass"});const H3={focus:{type:Number,default:1},aperture:{type:Number,default:.025},maxblur:{type:Number,default:.01}};var HA=Le({extends:kt,props:H3,created(){if(!this.renderer)return;if(!this.renderer.scene){console.error("Missing Scene");return}if(!this.renderer.camera){console.error("Missing Camera");return}const i={focus:this.focus,aperture:this.aperture,maxblur:this.maxblur,width:this.renderer.size.width,height:this.renderer.size.height},e=new oT(this.renderer.scene,this.renderer.camera,i);Object.keys(H3).forEach(t=>{Ze(()=>this[t],n=>{e.uniforms[t].value=n})}),this.initEffectPass(e)},__hmrId:"BokehPass"});const V3={noiseIntensity:{type:Number,default:.5},scanlinesIntensity:{type:Number,default:.05},scanlinesCount:{type:Number,default:4096},grayscale:{type:Number,default:0}};var VA=Le({extends:kt,props:V3,created(){const i=new aT(this.noiseIntensity,this.scanlinesIntensity,this.scanlinesCount,this.grayscale);Object.keys(V3).forEach(e=>{Ze(()=>this[e],t=>{i.uniforms[e].value=t})}),this.initEffectPass(i)},__hmrId:"FilmPass"}),WA=Le({extends:kt,created(){var i;const e=new jr(lT);(i=this.renderer)==null||i.addListener("resize",this.resize),this.initEffectPass(e)},unmounted(){var i;(i=this.renderer)==null||i.removeListener("resize",this.resize)},methods:{resize({size:i}){if(this.pass){const{resolution:e}=this.pass.material.uniforms;e.value.x=1/i.width,e.value.y=1/i.height}}},__hmrId:"FXAAPass"});const W3={shape:{type:Number,default:1},radius:{type:Number,default:4},rotateR:{type:Number,default:Math.PI/12*1},rotateG:{type:Number,default:Math.PI/12*2},rotateB:{type:Number,default:Math.PI/12*3},scatter:{type:Number,default:0}};var XA=Le({extends:kt,props:W3,created(){if(!this.renderer)return;const i=new cT(this.renderer.size.width,this.renderer.size.height,{});Object.keys(W3).forEach(e=>{i.uniforms[e].value=this[e],Ze(()=>this[e],t=>{i.uniforms[e].value=t})}),this.initEffectPass(i)},__hmrId:"HalftonePass"}),jA=Le({extends:kt,created(){if(!this.renderer)return;const i=new uT(this.renderer.size.width,this.renderer.size.height);this.initEffectPass(i)},__hmrId:"SMAAPass"}),YA=Le({extends:kt,props:{options:{type:Object,default:()=>({})}},created(){if(!this.renderer)return;if(!this.renderer.scene){console.error("Missing Scene");return}if(!this.renderer.camera){console.error("Missing Camera");return}const i=new wf(this.renderer.scene,this.renderer.camera,this.renderer.size.width,this.renderer.size.height);Object.keys(this.options).forEach(e=>{i[e]=this.options[e]}),this.initEffectPass(i)},__hmrId:"SSAOPass"}),cd={uniforms:{},vertexShader:` varying vec2 vUv; void main() { vUv = uv; @@ -5469,7 +5469,7 @@ version 0.6.9 /* switch back from pre-multiplied alpha */ gl_FragColor.rgb /= gl_FragColor.a + 0.00001; } - `};const qA={blurRadius:{type:Number,default:10},gradientRadius:{type:Number,default:100},start:{type:Object,default:()=>({x:0,y:100})},end:{type:Object,default:()=>({x:10,y:100})}};var QA=Le({extends:kt,props:qA,setup(){return{uniforms1:{},uniforms2:{}}},created(){if(!this.composer)return;this.pass1=new Xr(X3),this.pass2=new Xr(X3);const i=this.uniforms1=this.pass1.uniforms,e=this.uniforms2=this.pass2.uniforms;e.blurRadius=i.blurRadius,e.gradientRadius=i.gradientRadius,e.start=i.start,e.end=i.end,e.texSize=i.texSize,z0(this,"blurRadius",i.blurRadius,"value"),z0(this,"gradientRadius",i.gradientRadius,"value"),this.updateFocusLine(),["start","end"].forEach(t=>{Ke(()=>this[t],this.updateFocusLine,{deep:!0})}),this.pass1.setSize=(t,n)=>{i.texSize.value.set(t,n)},this.initEffectPass(this.pass1),this.composer.addPass(this.pass2)},unmounted(){this.composer&&this.pass2&&this.composer.removePass(this.pass2)},methods:{updateFocusLine(){this.uniforms1.start.value.copy(this.start),this.uniforms1.end.value.copy(this.end);const i=new ee().copy(this.end).sub(this.start).normalize();this.uniforms1.delta.value.copy(i),this.uniforms2.delta.value.set(-i.y,i.x)}},__hmrId:"TiltShiftPass"});const j3={strength:{type:Number,default:1.5},radius:{type:Number,default:0},threshold:{type:Number,default:0}};var ZA=Le({extends:kt,props:j3,created(){if(!this.renderer)return;const i=new ee(this.renderer.size.width,this.renderer.size.height),e=new N9(i,this.strength,this.radius,this.threshold);Object.keys(j3).forEach(t=>{Ke(()=>this[t],n=>{e.uniforms[t].value=n})}),this.initEffectPass(e)},__hmrId:"UnrealBloomPass"}),KA={uniforms:{tDiffuse:{value:null},center:{value:new ee(.5,.5)},strength:{value:0}},vertexShader:cd.vertexShader,fragmentShader:` + `};const qA={blurRadius:{type:Number,default:10},gradientRadius:{type:Number,default:100},start:{type:Object,default:()=>({x:0,y:100})},end:{type:Object,default:()=>({x:10,y:100})}};var QA=Le({extends:kt,props:qA,setup(){return{uniforms1:{},uniforms2:{}}},created(){if(!this.composer)return;this.pass1=new jr(X3),this.pass2=new jr(X3);const i=this.uniforms1=this.pass1.uniforms,e=this.uniforms2=this.pass2.uniforms;e.blurRadius=i.blurRadius,e.gradientRadius=i.gradientRadius,e.start=i.start,e.end=i.end,e.texSize=i.texSize,B0(this,"blurRadius",i.blurRadius,"value"),B0(this,"gradientRadius",i.gradientRadius,"value"),this.updateFocusLine(),["start","end"].forEach(t=>{Ze(()=>this[t],this.updateFocusLine,{deep:!0})}),this.pass1.setSize=(t,n)=>{i.texSize.value.set(t,n)},this.initEffectPass(this.pass1),this.composer.addPass(this.pass2)},unmounted(){this.composer&&this.pass2&&this.composer.removePass(this.pass2)},methods:{updateFocusLine(){this.uniforms1.start.value.copy(this.start),this.uniforms1.end.value.copy(this.end);const i=new ee().copy(this.end).sub(this.start).normalize();this.uniforms1.delta.value.copy(i),this.uniforms2.delta.value.set(-i.y,i.x)}},__hmrId:"TiltShiftPass"});const j3={strength:{type:Number,default:1.5},radius:{type:Number,default:0},threshold:{type:Number,default:0}};var KA=Le({extends:kt,props:j3,created(){if(!this.renderer)return;const i=new ee(this.renderer.size.width,this.renderer.size.height),e=new N9(i,this.strength,this.radius,this.threshold);Object.keys(j3).forEach(t=>{Ze(()=>this[t],n=>{e.uniforms[t].value=n})}),this.initEffectPass(e)},__hmrId:"UnrealBloomPass"}),ZA={uniforms:{tDiffuse:{value:null},center:{value:new ee(.5,.5)},strength:{value:0}},vertexShader:cd.vertexShader,fragmentShader:` uniform sampler2D tDiffuse; uniform vec2 center; uniform float strength; @@ -5505,4 +5505,4 @@ version 0.6.9 /* switch back from pre-multiplied alpha */ gl_FragColor.rgb /= gl_FragColor.a + 0.00001; } - `},JA=Le({extends:kt,props:{center:{type:Object,default:()=>({x:.5,y:.5})},strength:{type:Number,default:.5}},created(){const i=new Xr(KA);z0(this,"center",i.uniforms.center,"value"),z0(this,"strength",i.uniforms.strength,"value"),this.initEffectPass(i)},__hmrId:"ZoomBlurPass"}),$A=Object.freeze({__proto__:null,Renderer:Tf,RendererInjectionKey:en,OrthographicCamera:_T,PerspectiveCamera:yc,Camera:yc,Group:wT,Scene:Ef,SceneInjectionKey:O9,Object3D:li,Raycaster:MT,CubeCamera:ST,BufferGeometry:U9,BoxGeometry:TT,CircleGeometry:AT,ConeGeometry:ET,CylinderGeometry:LT,DodecahedronGeometry:PT,ExtrudeGeometry:FT,IcosahedronGeometry:IT,LatheGeometry:DT,OctahedronGeometry:NT,PlaneGeometry:OT,PolyhedronGeometry:UT,RingGeometry:zT,SphereGeometry:BT,ShapeGeometry:HT,TetrahedronGeometry:VT,TorusGeometry:WT,TorusKnotGeometry:XT,TubeGeometry:jT,AmbientLight:od,DirectionalLight:YT,HemisphereLight:qT,PointLight:QT,RectAreaLight:ZT,SpotLight:KT,Material:B9,BasicMaterial:JT,LambertMaterial:$T,PhongMaterial:eA,PhysicalMaterial:tA,PointsMaterial:nA,ShadowMaterial:iA,StandardMaterial:rA,ToonMaterial:sA,MaterialInjectionKey:z9,MatcapMaterial:oA,ShaderMaterial:cA,SubSurfaceMaterial:pA,Texture:k9,CubeTexture:mA,VideoTexture:gA,Mesh:ds,MeshInjectionKey:Do,Box:vA,Circle:xA,Cone:yA,Cylinder:_A,Dodecahedron:bA,Icosahedron:wA,Lathe:MA,Octahedron:SA,Plane:TA,Polyhedron:AA,Ring:EA,Sphere:LA,Tetrahedron:PA,Text:RA,Torus:FA,TorusKnot:IA,Tube:DA,Image:NA,InstancedMesh:OA,Sprite:UA,Points:zA,GltfModel:ld,FbxModel:BA,EffectComposer:kA,ComposerInjectionKey:G9,RenderPass:GA,EffectPass:kt,BokehPass:HA,FilmPass:VA,FXAAPass:WA,HalftonePass:XA,SMAAPass:jA,SSAOPass:YA,TiltShiftPass:QA,UnrealBloomPass:ZA,ZoomBlurPass:JA,applyObjectProps:Mo,bindObjectProp:ai,bindObjectProps:hT,setFromProp:So,bindProps:fT,bindProp:z0,propsValues:Fl,lerp:dT,limit:pT,getMatcapUrl:Mf});const eE={install(i){["Camera","OrthographicCamera","PerspectiveCamera","Raycaster","Renderer","Scene","Group","CubeCamera","AmbientLight","DirectionalLight","HemisphereLight","PointLight","RectAreaLight","SpotLight","BasicMaterial","LambertMaterial","MatcapMaterial","PhongMaterial","PhysicalMaterial","PointsMaterial","ShaderMaterial","StandardMaterial","SubSurfaceMaterial","ToonMaterial","Texture","CubeTexture","BufferGeometry","Mesh","Box","BoxGeometry","Circle","CircleGeometry","Cone","ConeGeometry","Cylinder","CylinderGeometry","Dodecahedron","DodecahedronGeometry","Icosahedron","IcosahedronGeometry","Lathe","LatheGeometry","Octahedron","OctahedronGeometry","Plane","PlaneGeometry","Polyhedron","PolyhedronGeometry","Ring","RingGeometry","Sphere","SphereGeometry","Tetrahedron","TetrahedronGeometry","Text","Torus","TorusGeometry","TorusKnot","TorusKnotGeometry","Tube","TubeGeometry","Image","InstancedMesh","Points","Sprite","FbxModel","GltfModel","BokehPass","EffectComposer","FilmPass","FXAAPass","HalftonePass","RenderPass","SAOPass","SMAAPass","SSAOPass","TiltShiftPass","UnrealBloomPass","ZoomBlurPass"].forEach(t=>{i.component(t,$A[t])})}},tE={components:{AmbientLight:od,Camera:yc,GltfModel:ld,Renderer:Tf,Scene:Ef}};function nE(i,e,t,n,r,s){const o=yi("Camera"),a=yi("AmbientLight"),l=yi("DirectionalLight"),c=yi("GltfModel"),u=yi("Scene"),h=yi("Renderer");return We(),kc(h,{ref:"renderer",antialias:"","orbit-ctrl":{enableDamping:!0},resize:""},{default:Mr(()=>[je(o,{position:{x:1,y:1,z:-2}}),je(u,{ref:"scene",background:"#f2f2f2"},{default:Mr(()=>[je(a),je(l,{position:{x:0,y:200,z:100}}),je(c,{src:"/../../../model/Tree1.glb"})]),_:1},512)]),_:1},512)}const Y3=_n(tE,[["render",nE]]),iE={},rE={contenteditable:"true",ref:"editableContent"},sE=me("p",null," Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi. ",-1),oE=[sE];function aE(i,e){return We(),Qe("div",rE,oE,512)}const q3=_n(iE,[["render",aE]]);const lE=["id","onMouseenter","onMouseleave"],cE={key:0,class:"actions"},uE={class:"actions-inner"},hE=["value"],fE=["onClick"],dE=["onClick"],pE={__name:"HomeView",setup(i){const e=P0([{uniqueId:"section1",component:Y2,props:{}},{uniqueId:"section2",component:q3,props:{title:"Über mich"}},{uniqueId:"section3",component:q2,props:{title:"Meine Projekte"}},{uniqueId:"section4",component:Q2,props:{title:"Meine Skills"}},{uniqueId:"section5",component:X2,props:{title:"Galerie"}},{uniqueId:"section6",component:Y3,props:{title:"3D-Model"}},{uniqueId:"section7",component:j2,props:{}}]),t=P0([{id:"section1",component:Y2,props:{title:"Startbild"}},{id:"section2",component:q3,props:{title:"Über mich"}},{id:"section3",component:q2,props:{title:"Meine Projekte"}},{id:"section4",component:Q2,props:{title:"Meine Skills"}},{id:"section5",component:X2,props:{title:"Galerie"}},{id:"section6",component:Y3,props:{title:"3D-Model"}},{id:"section7",component:j2,props:{title:"Kontaktformular"}}]);let n=P0("section1");function r(){return`section_${e.value.length+1}`}function s(l,c){const u=e.value.find(h=>h.uniqueId===l);u&&(u.hovered=c)}function o(l){l=l-1;const c=t.value.find(h=>h.id===n.value),u=r();c&&(c.id===t.value[0].id||c.id===t.value[t.value.length-1].id?e.value.splice(l+1,0,{id:c.id,component:c.component,props:{},uniqueId:u}):e.value.splice(l+1,0,{...c,uniqueId:u}))}function a(l){const c=e.value.findIndex(u=>u.uniqueId===l);c!==-1&&e.value.splice(c,1)}return(l,c)=>(We(),Qe("main",null,[(We(!0),Qe(W0,null,to(e.value,(u,h)=>(We(),Qe("section",{key:u.uniqueId,class:qn(["section-container",{"first-section":u.uniqueId==="section1"}]),id:u.uniqueId,onMouseenter:f=>s(u.uniqueId,!0),onMouseleave:f=>s(u.uniqueId,!1)},[me("h2",null,pr(u.props.title),1),(We(),kc(y8(u.component),Td(kh(u.props)),null,16)),u.hovered?(We(),Qe("div",cE,[me("div",uE,[Bn(me("select",{"onUpdate:modelValue":c[0]||(c[0]=f=>F0(n)?n.value=f:n=f),class:"select-section"},[(We(!0),Qe(W0,null,to(t.value,(f,d)=>(We(),Qe("option",{key:f.id,value:f.id},pr(f.props.title),9,hE))),128))],512),[[U6,Gn(n)]]),me("button",{onClick:f=>o(h),class:"add-section"},"+",8,fE),me("button",{class:"remove-button",onClick:f=>a(u.uniqueId)},"X",8,dE)])])):Gc("",!0)],42,lE))),128))]))}},mE=q7({history:h7("/"),routes:[{path:"/",name:"home",component:pE},{path:"/impressum",name:"impressum",component:()=>W2(()=>import("./Impressum-1f20f6a5.js"),["assets/Impressum-1f20f6a5.js","assets/Impressum-4d995ba2.css"])},{path:"/datenschutz",name:"datenschutz",component:()=>W2(()=>import("./Datenschutz-04c4c2c8.js"),["assets/Datenschutz-04c4c2c8.js","assets/Datenschutz-af8d9d9c.css"])}]}),Il=H6(zp);Il.use(j6());Il.use(mE);Il.use(eE);Il.mount("#app");export{_n as _,me as a,Qe as c,We as o}; + `},JA=Le({extends:kt,props:{center:{type:Object,default:()=>({x:.5,y:.5})},strength:{type:Number,default:.5}},created(){const i=new jr(ZA);B0(this,"center",i.uniforms.center,"value"),B0(this,"strength",i.uniforms.strength,"value"),this.initEffectPass(i)},__hmrId:"ZoomBlurPass"}),$A=Object.freeze({__proto__:null,Renderer:Tf,RendererInjectionKey:en,OrthographicCamera:_T,PerspectiveCamera:_c,Camera:_c,Group:wT,Scene:Ef,SceneInjectionKey:O9,Object3D:li,Raycaster:MT,CubeCamera:ST,BufferGeometry:U9,BoxGeometry:TT,CircleGeometry:AT,ConeGeometry:ET,CylinderGeometry:LT,DodecahedronGeometry:PT,ExtrudeGeometry:FT,IcosahedronGeometry:IT,LatheGeometry:DT,OctahedronGeometry:NT,PlaneGeometry:OT,PolyhedronGeometry:UT,RingGeometry:zT,SphereGeometry:BT,ShapeGeometry:HT,TetrahedronGeometry:VT,TorusGeometry:WT,TorusKnotGeometry:XT,TubeGeometry:jT,AmbientLight:od,DirectionalLight:YT,HemisphereLight:qT,PointLight:QT,RectAreaLight:KT,SpotLight:ZT,Material:B9,BasicMaterial:JT,LambertMaterial:$T,PhongMaterial:eA,PhysicalMaterial:tA,PointsMaterial:nA,ShadowMaterial:iA,StandardMaterial:rA,ToonMaterial:sA,MaterialInjectionKey:z9,MatcapMaterial:oA,ShaderMaterial:cA,SubSurfaceMaterial:pA,Texture:k9,CubeTexture:mA,VideoTexture:gA,Mesh:ps,MeshInjectionKey:Do,Box:vA,Circle:xA,Cone:yA,Cylinder:_A,Dodecahedron:bA,Icosahedron:wA,Lathe:MA,Octahedron:SA,Plane:TA,Polyhedron:AA,Ring:EA,Sphere:LA,Tetrahedron:PA,Text:RA,Torus:FA,TorusKnot:IA,Tube:DA,Image:NA,InstancedMesh:OA,Sprite:UA,Points:zA,GltfModel:ld,FbxModel:BA,EffectComposer:kA,ComposerInjectionKey:G9,RenderPass:GA,EffectPass:kt,BokehPass:HA,FilmPass:VA,FXAAPass:WA,HalftonePass:XA,SMAAPass:jA,SSAOPass:YA,TiltShiftPass:QA,UnrealBloomPass:KA,ZoomBlurPass:JA,applyObjectProps:Mo,bindObjectProp:ai,bindObjectProps:hT,setFromProp:So,bindProps:fT,bindProp:B0,propsValues:Il,lerp:dT,limit:pT,getMatcapUrl:Mf});const eE={install(i){["Camera","OrthographicCamera","PerspectiveCamera","Raycaster","Renderer","Scene","Group","CubeCamera","AmbientLight","DirectionalLight","HemisphereLight","PointLight","RectAreaLight","SpotLight","BasicMaterial","LambertMaterial","MatcapMaterial","PhongMaterial","PhysicalMaterial","PointsMaterial","ShaderMaterial","StandardMaterial","SubSurfaceMaterial","ToonMaterial","Texture","CubeTexture","BufferGeometry","Mesh","Box","BoxGeometry","Circle","CircleGeometry","Cone","ConeGeometry","Cylinder","CylinderGeometry","Dodecahedron","DodecahedronGeometry","Icosahedron","IcosahedronGeometry","Lathe","LatheGeometry","Octahedron","OctahedronGeometry","Plane","PlaneGeometry","Polyhedron","PolyhedronGeometry","Ring","RingGeometry","Sphere","SphereGeometry","Tetrahedron","TetrahedronGeometry","Text","Torus","TorusGeometry","TorusKnot","TorusKnotGeometry","Tube","TubeGeometry","Image","InstancedMesh","Points","Sprite","FbxModel","GltfModel","BokehPass","EffectComposer","FilmPass","FXAAPass","HalftonePass","RenderPass","SAOPass","SMAAPass","SSAOPass","TiltShiftPass","UnrealBloomPass","ZoomBlurPass"].forEach(t=>{i.component(t,$A[t])})}};const tE={components:{AmbientLight:od,Camera:_c,GltfModel:ld,Renderer:Tf,Scene:Ef},data(){return{modelSrc:"/../../../model/Tree1.glb",modelKey:0,exampleModels:[{name:"Tree1.glb",path:"/../../../model/Tree1.glb"},{name:"Rocks1.glb",path:"/../../../model/Rocks1.glb"},{name:"Bush1.glb",path:"/../../../model/Bush1.glb"}],currentSlide:0,slideshowInterval:null}},created(){this.startSlideshow()},beforeDestroy(){clearInterval(this.slideshowInterval)},methods:{handleFileChange(i){clearInterval(this.slideshowInterval);const e=i.target.files[0];if(e){const t=new FileReader;t.onload=n=>{const r=n.target.result;this.modelSrc=URL.createObjectURL(new Blob([r])),this.modelKey+=1},t.readAsArrayBuffer(e)}},selectExample(i){this.modelSrc=this.exampleModels[i].path,this.currentSlide=i},prevSlide(){this.currentSlide=(this.currentSlide-1+this.exampleModels.length)%this.exampleModels.length,this.modelSrc=this.exampleModels[this.currentSlide].path,this.modelKey+=1},nextSlide(){this.currentSlide=(this.currentSlide+1)%this.exampleModels.length,this.modelSrc=this.exampleModels[this.currentSlide].path,this.modelKey+=1},startSlideshow(){this.slideshowInterval=setInterval(()=>{this.nextSlide()},7e3)}}},nE={class:"object"},iE={class:"customFileInput"};function rE(i,e,t,n,r,s){const o=yi("Camera"),a=yi("AmbientLight"),l=yi("DirectionalLight"),c=yi("GltfModel"),u=yi("Scene"),h=yi("Renderer");return Ge(),qe(U0,null,[de("div",nE,[je(h,{ref:"renderer",antialias:"","orbit-ctrl":{enableDamping:!0},resize:""},{default:Mr(()=>[je(o,{position:{x:1,y:1,z:-2}}),je(u,{ref:"scene",background:"#f2f2f2"},{default:Mr(()=>[je(a),je(l,{position:{x:0,y:200,z:100}}),r.modelSrc?(Ge(),Gc(c,{key:r.modelKey,src:r.modelSrc},null,8,["src"])):ml("",!0)]),_:1},512)]),_:1},512),de("div",null,[de("div",{class:"arrow arrow-left",onClick:e[0]||(e[0]=(...f)=>s.prevSlide&&s.prevSlide(...f))},"<"),de("div",{class:"arrow arrow-right",onClick:e[1]||(e[1]=(...f)=>s.nextSlide&&s.nextSlide(...f))},">")])]),de("div",null,[de("label",iE,[Sr("EIGENES OBJEKT (+) "),de("input",{type:"file",id:"fileInput",onChange:e[2]||(e[2]=(...f)=>s.handleFileChange&&s.handleFileChange(...f)),accept:".glb",class:"fileInput",style:{display:"none"}},null,32)])])],64)}const Y3=_n(tE,[["render",rE]]),sE={},oE={contenteditable:"true",ref:"editableContent"},aE=de("p",null," Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi. ",-1),lE=[aE];function cE(i,e){return Ge(),qe("div",oE,lE,512)}const q3=_n(sE,[["render",cE]]);const uE=["id","onMouseenter","onMouseleave"],hE={key:0,class:"actions"},fE={class:"actions-inner"},dE=["value"],pE=["onClick"],mE=["onClick"],gE={__name:"HomeView",setup(i){const e=P0([{uniqueId:"section1",component:Y2,props:{}},{uniqueId:"section2",component:q3,props:{title:"Über mich"}},{uniqueId:"section3",component:q2,props:{title:"Meine Projekte"}},{uniqueId:"section4",component:Q2,props:{title:"Meine Skills"}},{uniqueId:"section5",component:X2,props:{title:"Galerie"}},{uniqueId:"section6",component:Y3,props:{title:"3D-Model"}},{uniqueId:"section7",component:j2,props:{}}]),t=P0([{id:"section1",component:Y2,props:{title:"Startbild"}},{id:"section2",component:q3,props:{title:"Über mich"}},{id:"section3",component:q2,props:{title:"Meine Projekte"}},{id:"section4",component:Q2,props:{title:"Meine Skills"}},{id:"section5",component:X2,props:{title:"Galerie"}},{id:"section6",component:Y3,props:{title:"3D-Model"}},{id:"section7",component:j2,props:{title:"Kontaktformular"}}]);let n=P0("section1");function r(){return`section_${e.value.length+1}`}function s(l,c){const u=e.value.find(h=>h.uniqueId===l);u&&(u.hovered=c)}function o(l){l=l-1;const c=t.value.find(h=>h.id===n.value),u=r();c&&(c.id===t.value[0].id||c.id===t.value[t.value.length-1].id?e.value.splice(l+1,0,{id:c.id,component:c.component,props:{},uniqueId:u}):e.value.splice(l+1,0,{...c,uniqueId:u}))}function a(l){const c=e.value.findIndex(u=>u.uniqueId===l);c!==-1&&e.value.splice(c,1)}return(l,c)=>(Ge(),qe("main",null,[(Ge(!0),qe(U0,null,to(e.value,(u,h)=>(Ge(),qe("section",{key:u.uniqueId,class:qn(["section-container",{"first-section":u.uniqueId==="section1"}]),id:u.uniqueId,onMouseenter:f=>s(u.uniqueId,!0),onMouseleave:f=>s(u.uniqueId,!1)},[de("h2",null,pr(u.props.title),1),(Ge(),Gc(y8(u.component),Td(kh(u.props)),null,16)),u.hovered?(Ge(),qe("div",hE,[de("div",fE,[Bn(de("select",{"onUpdate:modelValue":c[0]||(c[0]=f=>F0(n)?n.value=f:n=f),class:"select-section"},[(Ge(!0),qe(U0,null,to(t.value,(f,d)=>(Ge(),qe("option",{key:f.id,value:f.id},pr(f.props.title),9,dE))),128))],512),[[U6,Gn(n)]]),de("button",{onClick:f=>o(h),class:"add-section"},"+",8,pE),de("button",{class:"remove-button",onClick:f=>a(u.uniqueId)},"X",8,mE)])])):ml("",!0)],42,uE))),128))]))}},vE=q7({history:h7("/"),routes:[{path:"/",name:"home",component:gE},{path:"/impressum",name:"impressum",component:()=>W2(()=>import("./Impressum-07c8cc21.js"),["assets/Impressum-07c8cc21.js","assets/Impressum-4d995ba2.css"])},{path:"/datenschutz",name:"datenschutz",component:()=>W2(()=>import("./Datenschutz-b2f9b6d6.js"),["assets/Datenschutz-b2f9b6d6.js","assets/Datenschutz-af8d9d9c.css"])}]}),Dl=H6(zp);Dl.use(j6());Dl.use(vE);Dl.use(eE);Dl.mount("#app");export{_n as _,de as a,qe as c,Ge as o}; diff --git a/dist/index.html b/dist/index.html index 91acb86..5e05941 100644 --- a/dist/index.html +++ b/dist/index.html @@ -6,8 +6,8 @@ Portfolio - - + +
diff --git a/dist/model/Bush1.glb b/dist/model/Bush1.glb new file mode 100644 index 0000000..ae8aa03 Binary files /dev/null and b/dist/model/Bush1.glb differ diff --git a/dist/model/Rocks1.glb b/dist/model/Rocks1.glb new file mode 100644 index 0000000..8c2b949 Binary files /dev/null and b/dist/model/Rocks1.glb differ diff --git "a/dist/vue-portfolio-website - Verkn\303\274pfung.lnk" "b/dist/vue-portfolio-website - Verkn\303\274pfung.lnk" new file mode 100644 index 0000000..c17950b Binary files /dev/null and "b/dist/vue-portfolio-website - Verkn\303\274pfung.lnk" differ diff --git a/public/model/Bush1.glb b/public/model/Bush1.glb new file mode 100644 index 0000000..ae8aa03 Binary files /dev/null and b/public/model/Bush1.glb differ diff --git a/public/model/Rocks1.glb b/public/model/Rocks1.glb new file mode 100644 index 0000000..8c2b949 Binary files /dev/null and b/public/model/Rocks1.glb differ diff --git "a/public/vue-portfolio-website - Verkn\303\274pfung.lnk" "b/public/vue-portfolio-website - Verkn\303\274pfung.lnk" new file mode 100644 index 0000000..c17950b Binary files /dev/null and "b/public/vue-portfolio-website - Verkn\303\274pfung.lnk" differ diff --git a/src/components/3DModel.vue b/src/components/3DModel.vue index 4677d71..c94b4bb 100644 --- a/src/components/3DModel.vue +++ b/src/components/3DModel.vue @@ -1,14 +1,26 @@ \ No newline at end of file + + + +