diff --git a/build/three.js b/build/three.js index 9ce85978959f93f58ea39d67cb4cb26be0b4a1a6..4b89d4c06f93d7376195ff3118f186278c3c2f37 100644 --- a/build/three.js +++ b/build/three.js @@ -4563,7 +4563,7 @@ } WebGLRenderTarget.prototype = Object.assign( Object.create( EventDispatcher.prototype ), { - + constructor: WebGLRenderTarget, isWebGLRenderTarget: true, @@ -7685,7 +7685,7 @@ } Material.prototype = Object.assign( Object.create( EventDispatcher.prototype ), { - + constructor: Material, isMaterial: true, @@ -10275,7 +10275,7 @@ Object3D.DefaultMatrixAutoUpdate = true; Object3D.prototype = Object.assign( Object.create( EventDispatcher.prototype ), { - + constructor: Object3D, isObject3D: true, @@ -11288,7 +11288,7 @@ } Geometry.prototype = Object.assign( Object.create( EventDispatcher.prototype ), { - + constructor: Geometry, isGeometry: true, @@ -13416,7 +13416,7 @@ } BufferGeometry.prototype = Object.assign( Object.create( EventDispatcher.prototype ), { - + constructor: BufferGeometry, isBufferGeometry: true, @@ -30530,6 +30530,7 @@ this.setURLModifier = function ( transform ) { urlModifier = transform; + return this; }; @@ -34050,6 +34051,50 @@ } ); + /** + * @author Don McCurdy / https://www.donmccurdy.com + */ + + var LoaderUtils = { + + decodeText: function ( array ) { + + if ( typeof TextDecoder !== 'undefined' ) { + + return new TextDecoder().decode( array ); + + } + + // Avoid the String.fromCharCode.apply(null, array) shortcut, which + // throws a "maximum call stack size exceeded" error for large arrays. + + var s = ''; + + for ( var i = 0, il = array.length; i < il; i ++ ) { + + // Implicitly assumes little-endian. + s += String.fromCharCode( array[ i ] ); + + } + + return s; + + }, + + extractUrlBase: function ( url ) { + + var parts = url.split( '/' ); + + if ( parts.length === 1 ) return './'; + + parts.pop(); + + return parts.join( '/' ) + '/'; + + } + + }; + /** * @author mrdoob / http://mrdoob.com/ * @author alteredq / http://alteredqualia.com/ @@ -34076,7 +34121,7 @@ var scope = this; - var texturePath = this.texturePath && ( typeof this.texturePath === "string" ) ? this.texturePath : Loader.prototype.extractUrlBase( url ); + var texturePath = this.texturePath && ( typeof this.texturePath === 'string' ) ? this.texturePath : LoaderUtils.extractUrlBase( url ); var loader = new FileLoader( this.manager ); loader.setWithCredentials( this.withCredentials ); @@ -37249,50 +37294,6 @@ } ); - /** - * @author Don McCurdy / https://www.donmccurdy.com - */ - - var LoaderUtils = { - - decodeText: function ( array ) { - - if ( typeof TextDecoder !== 'undefined' ) { - - return new TextDecoder().decode( array ); - - } - - // Avoid the String.fromCharCode.apply(null, array) shortcut, which - // throws a "maximum call stack size exceeded" error for large arrays. - - var s = ''; - - for ( var i = 0, il = array.length; i < il; i ++ ) { - - // Implicitly assumes little-endian. - s += String.fromCharCode( array[ i ] ); - - } - - return s; - - }, - - extractUrlBase: function ( url ) { - - var parts = url.split( '/' ); - - if ( parts.length === 1 ) return './'; - - parts.pop(); - - return parts.join( '/' ) + '/'; - - } - - }; - /** * @author mrdoob / http://mrdoob.com/ */ @@ -40103,7 +40104,7 @@ } AnimationMixer.prototype = Object.assign( Object.create( EventDispatcher.prototype ), { - + constructor: AnimationMixer, _bindAction: function ( action, prototypeAction ) { diff --git a/build/three.min.js b/build/three.min.js index e41a2e6a0708d56e52778d7ed30b04afcb27fd7e..8023471ae7e050ef5688ccb342ea81139b212d4e 100644 --- a/build/three.min.js +++ b/build/three.min.js @@ -2,15 +2,15 @@ (function(l,xa){"object"===typeof exports&&"undefined"!==typeof module?xa(exports):"function"===typeof define&&define.amd?define(["exports"],xa):xa(l.THREE={})})(this,function(l){function xa(){}function D(a,b){this.x=a||0;this.y=b||0}function H(){this.elements=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];0=d||0=d||0 0 ) {\n\t\tfloat fogFactor = 0.0;\n\t\tif ( fogType == 1 ) {\n\t\t\tfogFactor = smoothstep( fogNear, fogFar, fogDepth );\n\t\t} else {\n\t\t\tconst float LOG2 = 1.442695;\n\t\t\tfogFactor = exp2( - fogDensity * fogDensity * fogDepth * fogDepth * LOG2 );\n\t\t\tfogFactor = 1.0 - clamp( fogFactor, 0.0, 1.0 );\n\t\t}\n\t\tgl_FragColor.rgb = mix( gl_FragColor.rgb, fogColor, fogFactor );\n\t}\n}"].join("\n")); b.compileShader(M);b.compileShader(B);b.attachShader(x,M);b.attachShader(x,B);b.linkProgram(x);na=x;A=b.getAttribLocation(na,"position");J=b.getAttribLocation(na,"uv");f=b.getUniformLocation(na,"uvOffset");g=b.getUniformLocation(na,"uvScale");h=b.getUniformLocation(na,"rotation");k=b.getUniformLocation(na,"scale");m=b.getUniformLocation(na,"color");q=b.getUniformLocation(na,"map");n=b.getUniformLocation(na,"opacity");u=b.getUniformLocation(na,"modelViewMatrix");r=b.getUniformLocation(na,"projectionMatrix"); -t=b.getUniformLocation(na,"fogType");l=b.getUniformLocation(na,"fogDensity");w=b.getUniformLocation(na,"fogNear");z=b.getUniformLocation(na,"fogFar");y=b.getUniformLocation(na,"fogColor");b.getUniformLocation(na,"fogDepth");I=b.getUniformLocation(na,"alphaTest");x=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");x.width=8;x.height=8;M=x.getContext("2d");M.fillStyle="white";M.fillRect(0,0,8,8);Se=new sc(x)}c.useProgram(na);c.initAttributes();c.enableAttribute(A);c.enableAttribute(J); +t=b.getUniformLocation(na,"fogType");l=b.getUniformLocation(na,"fogDensity");w=b.getUniformLocation(na,"fogNear");z=b.getUniformLocation(na,"fogFar");y=b.getUniformLocation(na,"fogColor");b.getUniformLocation(na,"fogDepth");I=b.getUniformLocation(na,"alphaTest");x=document.createElementNS("http://www.w3.org/1999/xhtml","canvas");x.width=8;x.height=8;M=x.getContext("2d");M.fillStyle="white";M.fillRect(0,0,8,8);Te=new sc(x)}c.useProgram(na);c.initAttributes();c.enableAttribute(A);c.enableAttribute(J); c.disableUnusedAttributes();c.disable(b.CULL_FACE);c.enable(b.BLEND);b.bindBuffer(b.ARRAY_BUFFER,Ba);b.vertexAttribPointer(A,2,b.FLOAT,!1,16,0);b.vertexAttribPointer(J,2,b.FLOAT,!1,16,8);b.bindBuffer(b.ELEMENT_ARRAY_BUFFER,ma);b.uniformMatrix4fv(r,!1,D.projectionMatrix.elements);c.activeTexture(b.TEXTURE0);b.uniform1i(q,0);M=x=0;(B=p.fog)?(b.uniform3f(y,B.color.r,B.color.g,B.color.b),B.isFog?(b.uniform1f(w,B.near),b.uniform1f(z,B.far),b.uniform1i(t,1),M=x=1):B.isFogExp2&&(b.uniform1f(l,B.density), b.uniform1i(t,2),M=x=2)):(b.uniform1i(t,0),M=x=0);for(var C=0,va=v.length;Cb&&(b=a[c]);return b}function C(){Object.defineProperty(this,"id",{value:dg+=2});this.uuid=O.generateUUID();this.name="";this.type="BufferGeometry";this.index=null;this.attributes={};this.morphAttributes= -{};this.groups=[];this.boundingSphere=this.boundingBox=null;this.drawRange={start:0,count:Infinity}}function Lb(a,b,c,d,e,f){L.call(this);this.type="BoxGeometry";this.parameters={width:a,height:b,depth:c,widthSegments:d,heightSegments:e,depthSegments:f};this.fromBufferGeometry(new mb(a,b,c,d,e,f));this.mergeVertices()}function mb(a,b,c,d,e,f){function g(a,b,c,d,e,f,g,l,Ha,Ba,ma){var t=f/Ha,v=g/Ba,I=f/2,A=g/2,w=l/2;g=Ha+1;var z=Ba+1,y=f=0,J,x,B=new p;for(x=0;xm;m++){if(n=d[m])if(h=n[0],n=n[1]){q&&e.addAttribute("morphTarget"+m,q[h]);f&&e.addAttribute("morphNormal"+m,f[h]);c[m]=n;continue}c[m]=0}g.getUniforms().setValue(a,"morphTargetInfluences",c)}}}function lg(a,b,c){var d,e,f;this.setMode=function(a){d= @@ -73,11 +73,11 @@ A.shadow,h.shadowBias=k.bias,h.shadowRadius=k.radius,h.shadowMapSize=k.mapSize;b h.penumbraCos=Math.cos(A.angle*(1-A.penumbra));h.decay=0===A.distance?0:A.decay;if(h.shadow=A.castShadow)k=A.shadow,h.shadowBias=k.bias,h.shadowRadius=k.radius,h.shadowMapSize=k.mapSize;b.spotShadowMap[t]=Ba;b.spotShadowMatrix[t]=A.shadow.matrix;b.spot[t]=h;t++}else if(A.isRectAreaLight)h=a.get(A),h.color.copy(k).multiplyScalar(J/(A.width*A.height)),h.position.setFromMatrixPosition(A.matrixWorld),h.position.applyMatrix4(p),e.identity(),d.copy(A.matrixWorld),d.premultiply(p),e.extractRotation(d),h.halfWidth.set(.5* A.width,0,0),h.halfHeight.set(0,.5*A.height,0),h.halfWidth.applyMatrix4(e),h.halfHeight.applyMatrix4(e),b.rectArea[l]=h,l++;else if(A.isPointLight){h=a.get(A);h.position.setFromMatrixPosition(A.matrixWorld);h.position.applyMatrix4(p);h.color.copy(A.color).multiplyScalar(A.intensity);h.distance=A.distance;h.decay=0===A.distance?0:A.decay;if(h.shadow=A.castShadow)k=A.shadow,h.shadowBias=k.bias,h.shadowRadius=k.radius,h.shadowMapSize=k.mapSize,h.shadowCameraNear=k.camera.near,h.shadowCameraFar=k.camera.far; b.pointShadowMap[r]=Ba;b.pointShadowMatrix[r]=A.shadow.matrix;b.point[r]=h;r++}else A.isHemisphereLight&&(h=a.get(A),h.direction.setFromMatrixPosition(A.matrixWorld),h.direction.transformDirection(p),h.direction.normalize(),h.skyColor.copy(A.color).multiplyScalar(J),h.groundColor.copy(A.groundColor).multiplyScalar(J),b.hemi[w]=h,w++)}b.ambient[0]=m;b.ambient[1]=q;b.ambient[2]=n;b.directional.length=u;b.spot.length=t;b.rectArea.length=l;b.point.length=r;b.hemi.length=w;b.hash=u+","+r+","+t+","+l+","+ -w+","+g.length},state:b}}function qg(a,b){var c={};return{update:function(d){var e=b.frame,f=d.geometry,g=a.get(d,f);c[g.id]!==e&&(f.isGeometry&&g.updateFromObject(d),a.update(g),c[g.id]=e);return g},clear:function(){c={}}}}function rg(a){a=a.split("\n");for(var b=0;b/gm,function(a,c){a=Q[c];if(void 0===a)throw Error("Can not resolve #include <"+c+">");return Zd(a)})}function Ye(a){return a.replace(/for \( int i \= (\d+)\; i < (\d+)\; i \+\+ \) \{([\s\S]+?)(?=\})\}/g, +c+" "+d)}return b.join("\n")}function Ac(a){return""!==a}function Ye(a,b){return a.replace(/NUM_DIR_LIGHTS/g,b.numDirLights).replace(/NUM_SPOT_LIGHTS/g,b.numSpotLights).replace(/NUM_RECT_AREA_LIGHTS/g,b.numRectAreaLights).replace(/NUM_POINT_LIGHTS/g,b.numPointLights).replace(/NUM_HEMI_LIGHTS/g,b.numHemiLights)}function Zd(a){return a.replace(/^[ \t]*#include +<([\w\d.]+)>/gm,function(a,c){a=Q[c];if(void 0===a)throw Error("Can not resolve #include <"+c+">");return Zd(a)})}function Ze(a){return a.replace(/for \( int i \= (\d+)\; i < (\d+)\; i \+\+ \) \{([\s\S]+?)(?=\})\}/g, function(a,c,d,e){a="";for(c=parseInt(c);ca.matrixWorld.determinant();Z.setMaterial(e,h);h=u(c,b.fog,e,a);Q=""; g(a,h,e)}else S.renderBufferDirect(c,b.fog,d,e,a,f);a.onAfterRender(S,b,c,d,e,f)}function n(a,b,c){var d=da.get(a);c=oa.getParameters(a,ua.state,C,b,Ia.numPlanes,Ia.numIntersection,c);var g=oa.getProgramCode(a,c),h=d.program,k=!0;if(void 0===h)a.addEventListener("dispose",e);else if(h.code!==g)f(a);else{if(void 0!==c.shaderID)return;k=!1}k&&(c.shaderID?(h=pb[c.shaderID],d.shader={name:a.type,uniforms:Ga.clone(h.uniforms),vertexShader:h.vertexShader,fragmentShader:h.fragmentShader}):d.shader={name:a.type, uniforms:a.uniforms,vertexShader:a.vertexShader,fragmentShader:a.fragmentShader},a.onBeforeCompile(d.shader),h=oa.acquireProgram(a,d.shader,c,g),d.program=h,a.program=h);c=h.getAttributes();if(a.morphTargets)for(g=a.numSupportedMorphTargets=0;g=U.maxTextures&&console.warn("THREE.WebGLRenderer: Trying to use "+a+" texture units while this GPU supports only "+U.maxTextures);Y+=1;return a};this.setTexture2D= function(){var a=!1;return function(b,c){b&&b.isWebGLRenderTarget&&(a||(console.warn("THREE.WebGLRenderer.setTexture2D: don't use render targets as textures. Use their .texture property instead."),a=!0),b=b.texture);ga.setTexture2D(b,c)}}();this.setTexture=function(){var a=!1;return function(b,c){a||(console.warn("THREE.WebGLRenderer: .setTexture is deprecated, use setTexture2D instead."),a=!0);ga.setTexture2D(b,c)}}();this.setTextureCube=function(){var a=!1;return function(b,c){b&&b.isWebGLRenderTargetCube&& (a||(console.warn("THREE.WebGLRenderer.setTextureCube: don't use cube render targets as textures. Use their .texture property instead."),a=!0),b=b.texture);b&&b.isCubeTexture||Array.isArray(b.image)&&6===b.image.length?ga.setTextureCube(b,c):ga.setTextureCubeDynamic(b,c)}}();this.getRenderTarget=function(){return M};this.setRenderTarget=function(a){(M=a)&&void 0===da.get(a).__webglFramebuffer&&ga.setupRenderTarget(a);var b=null,c=!1;a?(b=da.get(a).__webglFramebuffer,a.isWebGLRenderTargetCube&&(b= -b[a.activeCubeFace],c=!0),jb.copy(a.viewport),X.copy(a.scissor),G=a.scissorTest):(jb.copy(ca).multiplyScalar(wa),X.copy(fa).multiplyScalar(wa),G=Ze);R!==b&&(E.bindFramebuffer(E.FRAMEBUFFER,b),R=b);Z.viewport(jb);Z.scissor(X);Z.setScissorTest(G);c&&(c=da.get(a.texture),E.framebufferTexture2D(E.FRAMEBUFFER,E.COLOR_ATTACHMENT0,E.TEXTURE_CUBE_MAP_POSITIVE_X+a.activeCubeFace,c.__webglTexture,a.activeMipMapLevel))};this.readRenderTargetPixels=function(a,b,c,d,e,f){if(a&&a.isWebGLRenderTarget){var g=da.get(a).__webglFramebuffer; +b[a.activeCubeFace],c=!0),jb.copy(a.viewport),X.copy(a.scissor),G=a.scissorTest):(jb.copy(ca).multiplyScalar(wa),X.copy(fa).multiplyScalar(wa),G=$e);R!==b&&(E.bindFramebuffer(E.FRAMEBUFFER,b),R=b);Z.viewport(jb);Z.scissor(X);Z.setScissorTest(G);c&&(c=da.get(a.texture),E.framebufferTexture2D(E.FRAMEBUFFER,E.COLOR_ATTACHMENT0,E.TEXTURE_CUBE_MAP_POSITIVE_X+a.activeCubeFace,c.__webglTexture,a.activeMipMapLevel))};this.readRenderTargetPixels=function(a,b,c,d,e,f){if(a&&a.isWebGLRenderTarget){var g=da.get(a).__webglFramebuffer; if(g){var h=!1;g!==R&&(E.bindFramebuffer(E.FRAMEBUFFER,g),h=!0);try{var k=a.texture,m=k.format,q=k.type;1023!==m&&pa.convert(m)!==E.getParameter(E.IMPLEMENTATION_COLOR_READ_FORMAT)?console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in RGBA or implementation defined format."):1009===q||pa.convert(q)===E.getParameter(E.IMPLEMENTATION_COLOR_READ_TYPE)||1015===q&&(ia.get("OES_texture_float")||ia.get("WEBGL_color_buffer_float"))||1016===q&&ia.get("EXT_color_buffer_half_float")? E.checkFramebufferStatus(E.FRAMEBUFFER)===E.FRAMEBUFFER_COMPLETE?0<=b&&b<=a.width-d&&0<=c&&c<=a.height-e&&E.readPixels(b,c,d,e,pa.convert(m),pa.convert(q),f):console.error("THREE.WebGLRenderer.readRenderTargetPixels: readPixels from renderTarget failed. Framebuffer not complete."):console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in UnsignedByteType or implementation defined type.")}finally{h&&E.bindFramebuffer(E.FRAMEBUFFER,R)}}}else console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not THREE.WebGLRenderTarget.")}} -function Ob(a,b){this.name="";this.color=new F(a);this.density=void 0!==b?b:2.5E-4}function Pb(a,b,c){this.name="";this.color=new F(a);this.near=void 0!==b?b:1;this.far=void 0!==c?c:1E3}function vd(){x.call(this);this.type="Scene";this.overrideMaterial=this.fog=this.background=null;this.autoUpdate=!0}function de(a,b,c,d,e){x.call(this);this.lensFlares=[];this.positionScreen=new p;this.customUpdateCallback=void 0;void 0!==a&&this.add(a,b,c,d,e)}function $a(a){N.call(this);this.type="SpriteMaterial"; +function Nb(a,b){this.name="";this.color=new F(a);this.density=void 0!==b?b:2.5E-4}function Ob(a,b,c){this.name="";this.color=new F(a);this.near=void 0!==b?b:1;this.far=void 0!==c?c:1E3}function vd(){x.call(this);this.type="Scene";this.overrideMaterial=this.fog=this.background=null;this.autoUpdate=!0}function de(a,b,c,d,e){x.call(this);this.lensFlares=[];this.positionScreen=new p;this.customUpdateCallback=void 0;void 0!==a&&this.add(a,b,c,d,e)}function $a(a){N.call(this);this.type="SpriteMaterial"; this.color=new F(16777215);this.map=null;this.rotation=0;this.lights=this.fog=!1;this.setValues(a)}function Bc(a){x.call(this);this.type="Sprite";this.material=void 0!==a?a:new $a}function Cc(){x.call(this);this.type="LOD";Object.defineProperties(this,{levels:{enumerable:!0,value:[]}})}function Dc(a,b){a=a||[];this.bones=a.slice(0);this.boneMatrices=new Float32Array(16*this.bones.length);if(void 0===b)this.calculateInverses();else if(this.bones.length===b.length)this.boneInverses=b.slice(0);else for(console.warn("THREE.Skeleton boneInverses is the wrong length."), this.boneInverses=[],a=0,b=this.bones.length;ac;c++){var n=q[h[c]];var u=q[h[(c+1)%3]];f[0]=Math.min(n,u);f[1]=Math.max(n,u);n=f[0]+","+f[1];void 0===g[n]&&(g[n]={index1:f[0],index2:f[1]})}}for(n in g)m=g[n],h=a.vertices[m.index1],b.push(h.x,h.y,h.z),h=a.vertices[m.index2],b.push(h.x,h.y,h.z)}else if(a&&a.isBufferGeometry){var h=new p;if(null!== +this.flipY=!1}function Rb(a){C.call(this);this.type="WireframeGeometry";var b=[],c,d,e,f=[0,0],g={},h=["a","b","c"];if(a&&a.isGeometry){var k=a.faces;var m=0;for(d=k.length;mc;c++){var n=q[h[c]];var u=q[h[(c+1)%3]];f[0]=Math.min(n,u);f[1]=Math.max(n,u);n=f[0]+","+f[1];void 0===g[n]&&(g[n]={index1:f[0],index2:f[1]})}}for(n in g)m=g[n],h=a.vertices[m.index1],b.push(h.x,h.y,h.z),h=a.vertices[m.index2],b.push(h.x,h.y,h.z)}else if(a&&a.isBufferGeometry){var h=new p;if(null!== a.index){k=a.attributes.position;q=a.index;var l=a.groups;0===l.length&&(l=[{start:0,count:q.count,materialIndex:0}]);a=0;for(e=l.length;ac;c++)n=q.getX(m+c),u=q.getX(m+(c+1)%3),f[0]=Math.min(n,u),f[1]=Math.max(n,u),n=f[0]+","+f[1],void 0===g[n]&&(g[n]={index1:f[0],index2:f[1]});for(n in g)m=g[n],h.fromBufferAttribute(k,m.index1),b.push(h.x,h.y,h.z),h.fromBufferAttribute(k,m.index2),b.push(h.x,h.y,h.z)}else for(k=a.attributes.position, -m=0,d=k.count/3;mc;c++)g=3*m+c,h.fromBufferAttribute(k,g),b.push(h.x,h.y,h.z),g=3*m+(c+1)%3,h.fromBufferAttribute(k,g),b.push(h.x,h.y,h.z)}this.addAttribute("position",new B(b,3))}function Gc(a,b,c){L.call(this);this.type="ParametricGeometry";this.parameters={func:a,slices:b,stacks:c};this.fromBufferGeometry(new Tb(a,b,c));this.mergeVertices()}function Tb(a,b,c){C.call(this);this.type="ParametricBufferGeometry";this.parameters={func:a,slices:b,stacks:c};var d=[],e=[],f=[],g=[],h= +m=0,d=k.count/3;mc;c++)g=3*m+c,h.fromBufferAttribute(k,g),b.push(h.x,h.y,h.z),g=3*m+(c+1)%3,h.fromBufferAttribute(k,g),b.push(h.x,h.y,h.z)}this.addAttribute("position",new B(b,3))}function Gc(a,b,c){L.call(this);this.type="ParametricGeometry";this.parameters={func:a,slices:b,stacks:c};this.fromBufferGeometry(new Sb(a,b,c));this.mergeVertices()}function Sb(a,b,c){C.call(this);this.type="ParametricBufferGeometry";this.parameters={func:a,slices:b,stacks:c};var d=[],e=[],f=[],g=[],h= new p,k=new p,m=new p,q=new p,n=new p,u,l,t=b+1;for(u=0;u<=c;u++){var v=u/c;for(l=0;l<=b;l++){var w=l/b,k=a(w,v,k);e.push(k.x,k.y,k.z);0<=w-1E-5?(m=a(w-1E-5,v,m),q.subVectors(k,m)):(m=a(w+1E-5,v,m),q.subVectors(m,k));0<=v-1E-5?(m=a(w,v-1E-5,m),n.subVectors(k,m)):(m=a(w,v+1E-5,m),n.subVectors(m,k));h.crossVectors(q,n).normalize();f.push(h.x,h.y,h.z);g.push(w,v)}}for(u=0;ud&&1===a.x&&(k[b]=a.x-1);0===c.x&&0===c.z&&(k[b]=d/2/Math.PI+.5)}C.call(this);this.type="PolyhedronBufferGeometry"; this.parameters={vertices:a,indices:b,radius:c,detail:d};c=c||1;d=d||0;var h=[],k=[];(function(a){for(var c=new p,d=new p,g=new p,h=0;he&&(.2>b&&(k[a+0]+=1),.2>c&&(k[a+2]+=1),.2>d&&(k[a+4]+=1))})();this.addAttribute("position",new B(h,3));this.addAttribute("normal",new B(h.slice(),3));this.addAttribute("uv",new B(k,2));0===d?this.computeVertexNormals(): -this.normalizeNormals()}function Ic(a,b){L.call(this);this.type="TetrahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new Ub(a,b));this.mergeVertices()}function Ub(a,b){sa.call(this,[1,1,1,-1,-1,1,-1,1,-1,1,-1,-1],[2,1,0,0,3,2,1,3,0,2,3,1],a,b);this.type="TetrahedronBufferGeometry";this.parameters={radius:a,detail:b}}function Jc(a,b){L.call(this);this.type="OctahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new qb(a,b));this.mergeVertices()} -function qb(a,b){sa.call(this,[1,0,0,-1,0,0,0,1,0,0,-1,0,0,0,1,0,0,-1],[0,2,4,0,4,3,0,3,5,0,5,2,1,2,5,1,5,3,1,3,4,1,4,2],a,b);this.type="OctahedronBufferGeometry";this.parameters={radius:a,detail:b}}function Kc(a,b){L.call(this);this.type="IcosahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new Vb(a,b));this.mergeVertices()}function Vb(a,b){var c=(1+Math.sqrt(5))/2;sa.call(this,[-1,c,0,1,c,0,-1,-c,0,1,-c,0,0,-1,c,0,1,c,0,-1,-c,0,1,-c,c,0,-1,c,0,1,-c,0,-1,-c,0,1],[0,11, -5,0,5,1,0,1,7,0,7,10,0,10,11,1,5,9,5,11,4,11,10,2,10,7,6,7,1,8,3,9,4,3,4,2,3,2,6,3,6,8,3,8,9,4,9,5,2,4,11,6,2,10,8,6,7,9,8,1],a,b);this.type="IcosahedronBufferGeometry";this.parameters={radius:a,detail:b}}function Lc(a,b){L.call(this);this.type="DodecahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new Wb(a,b));this.mergeVertices()}function Wb(a,b){var c=(1+Math.sqrt(5))/2,d=1/c;sa.call(this,[-1,-1,-1,-1,-1,1,-1,1,-1,-1,1,1,1,-1,-1,1,-1,1,1,1,-1,1,1,1,0,-d,-c,0,-d,c,0, +this.normalizeNormals()}function Ic(a,b){L.call(this);this.type="TetrahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new Tb(a,b));this.mergeVertices()}function Tb(a,b){sa.call(this,[1,1,1,-1,-1,1,-1,1,-1,1,-1,-1],[2,1,0,0,3,2,1,3,0,2,3,1],a,b);this.type="TetrahedronBufferGeometry";this.parameters={radius:a,detail:b}}function Jc(a,b){L.call(this);this.type="OctahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new qb(a,b));this.mergeVertices()} +function qb(a,b){sa.call(this,[1,0,0,-1,0,0,0,1,0,0,-1,0,0,0,1,0,0,-1],[0,2,4,0,4,3,0,3,5,0,5,2,1,2,5,1,5,3,1,3,4,1,4,2],a,b);this.type="OctahedronBufferGeometry";this.parameters={radius:a,detail:b}}function Kc(a,b){L.call(this);this.type="IcosahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new Ub(a,b));this.mergeVertices()}function Ub(a,b){var c=(1+Math.sqrt(5))/2;sa.call(this,[-1,c,0,1,c,0,-1,-c,0,1,-c,0,0,-1,c,0,1,c,0,-1,-c,0,1,-c,c,0,-1,c,0,1,-c,0,-1,-c,0,1],[0,11, +5,0,5,1,0,1,7,0,7,10,0,10,11,1,5,9,5,11,4,11,10,2,10,7,6,7,1,8,3,9,4,3,4,2,3,2,6,3,6,8,3,8,9,4,9,5,2,4,11,6,2,10,8,6,7,9,8,1],a,b);this.type="IcosahedronBufferGeometry";this.parameters={radius:a,detail:b}}function Lc(a,b){L.call(this);this.type="DodecahedronGeometry";this.parameters={radius:a,detail:b};this.fromBufferGeometry(new Vb(a,b));this.mergeVertices()}function Vb(a,b){var c=(1+Math.sqrt(5))/2,d=1/c;sa.call(this,[-1,-1,-1,-1,-1,1,-1,1,-1,-1,1,1,1,-1,-1,1,-1,1,1,1,-1,1,1,1,0,-d,-c,0,-d,c,0, d,-c,0,d,c,-d,-c,0,-d,c,0,d,-c,0,d,c,0,-c,0,-d,c,0,-d,-c,0,d,c,0,d],[3,11,7,3,7,15,3,15,13,7,19,17,7,17,6,7,6,15,17,4,8,17,8,10,17,10,6,8,0,16,8,16,2,8,2,10,0,12,1,0,1,18,0,18,16,6,10,2,6,2,13,6,13,15,2,16,18,2,18,3,2,3,13,18,1,9,18,9,11,18,11,3,4,14,12,4,12,0,4,0,8,11,9,5,11,5,19,11,19,7,19,5,14,19,14,4,19,4,17,1,12,14,1,14,5,1,5,9],a,b);this.type="DodecahedronBufferGeometry";this.parameters={radius:a,detail:b}}function Mc(a,b,c,d,e,f){L.call(this);this.type="TubeGeometry";this.parameters={path:a, -tubularSegments:b,radius:c,radialSegments:d,closed:e};void 0!==f&&console.warn("THREE.TubeGeometry: taper has been removed.");a=new Xb(a,b,c,d,e);this.tangents=a.tangents;this.normals=a.normals;this.binormals=a.binormals;this.fromBufferGeometry(a);this.mergeVertices()}function Xb(a,b,c,d,e){function f(e){q=a.getPointAt(e/b,q);var f=g.normals[e];e=g.binormals[e];for(l=0;l<=d;l++){var m=l/d*Math.PI*2,n=Math.sin(m),m=-Math.cos(m);k.x=m*f.x+n*e.x;k.y=m*f.y+n*e.y;k.z=m*f.z+n*e.z;k.normalize();t.push(k.x, +tubularSegments:b,radius:c,radialSegments:d,closed:e};void 0!==f&&console.warn("THREE.TubeGeometry: taper has been removed.");a=new Wb(a,b,c,d,e);this.tangents=a.tangents;this.normals=a.normals;this.binormals=a.binormals;this.fromBufferGeometry(a);this.mergeVertices()}function Wb(a,b,c,d,e){function f(e){q=a.getPointAt(e/b,q);var f=g.normals[e];e=g.binormals[e];for(l=0;l<=d;l++){var m=l/d*Math.PI*2,n=Math.sin(m),m=-Math.cos(m);k.x=m*f.x+n*e.x;k.y=m*f.y+n*e.y;k.z=m*f.z+n*e.z;k.normalize();t.push(k.x, k.y,k.z);h.x=q.x+c*k.x;h.y=q.y+c*k.y;h.z=q.z+c*k.z;r.push(h.x,h.y,h.z)}}C.call(this);this.type="TubeBufferGeometry";this.parameters={path:a,tubularSegments:b,radius:c,radialSegments:d,closed:e};b=b||64;c=c||1;d=d||8;e=e||!1;var g=a.computeFrenetFrames(b,e);this.tangents=g.tangents;this.normals=g.normals;this.binormals=g.binormals;var h=new p,k=new p,m=new D,q=new p,n,l,r=[],t=[],v=[],w=[];for(n=0;n=b;e-=d)f=bf(e,a[e],a[e+1],f);f&&rb(f,f.next)&&(Pc(f),f=f.next);return f}function Qc(a,b){if(!a)return a;b||(b=a);do{var c=!1;if(a.steiner||!rb(a,a.next)&&0!==ra(a.prev,a,a.next))a=a.next;else{Pc(a);a=b=a.prev; +e);this.setIndex(f);this.addAttribute("position",new B(g,3));this.addAttribute("normal",new B(h,3));this.addAttribute("uv",new B(k,2))}function bf(a,b,c,d,e){for(var f,g=0,h=b,k=c-d;h=b;e-=d)f=cf(e,a[e],a[e+1],f);f&&rb(f,f.next)&&(Pc(f),f=f.next);return f}function Qc(a,b){if(!a)return a;b||(b=a);do{var c=!1;if(a.steiner||!rb(a,a.next)&&0!==ra(a.prev,a,a.next))a=a.next;else{Pc(a);a=b=a.prev; if(a===a.next)break;c=!0}}while(c||a!==b);return b}function Rc(a,b,c,d,e,f,g){if(a){if(!g&&f){var h=a,k=h;do null===k.z&&(k.z=fe(k.x,k.y,d,e,f)),k.prevZ=k.prev,k=k.nextZ=k.next;while(k!==h);k.prevZ.nextZ=null;k.prevZ=null;var h=k,m,q,n,l,r=1;do{k=h;var t=h=null;for(q=0;k;){q++;var p=k;for(m=n=0;mn.x?q.x>r.x?q.x:r.x:n.x>r.x?n.x:r.x,I=q.y>n.y?q.y>r.y?q.y:r.y:n.y>r.y?n.y:r.y;m=fe(q.x=m;){if(w!==t.prev&&w!==t.next&&zd(q.x,q.y,n.x,n.y,r.x, -r.y,w.x,w.y)&&0<=ra(w.prev,w,w.next)){t=!1;break a}w=w.prevZ}t=!0}}else a:if(t=a,q=t.prev,n=t,r=t.next,0<=ra(q,n,r))t=!1;else{for(m=t.next.next;m!==t.prev;){if(zd(q.x,q.y,n.x,n.y,r.x,r.y,m.x,m.y)&&0<=ra(m.prev,m,m.next)){t=!1;break a}m=m.next}t=!0}if(t)b.push(k.i/c),b.push(a.i/c),b.push(p.i/c),Pc(a),h=a=p.next;else if(a=p,a===h){if(!g)Rc(Qc(a),b,c,d,e,f,1);else if(1===g){g=b;h=c;k=a;do p=k.prev,t=k.next.next,!rb(p,t)&&cf(p,k,k.next,t)&&Sc(p,t)&&Sc(t,p)&&(g.push(p.i/h),g.push(k.i/h),g.push(t.i/h), -Pc(k),Pc(k.next),k=a=t),k=k.next;while(k!==a);a=k;Rc(a,b,c,d,e,f,2)}else if(2===g)a:{g=a;do{for(h=g.next.next;h!==g.prev;){if(k=g.i!==h.i){k=g;p=h;if(t=k.next.i!==p.i&&k.prev.i!==p.i){b:{t=k;do{if(t.i!==k.i&&t.next.i!==k.i&&t.i!==p.i&&t.next.i!==p.i&&cf(t,t.next,k,p)){t=!0;break b}t=t.next}while(t!==k);t=!1}t=!t}if(t=t&&Sc(k,p)&&Sc(p,k)){t=k;q=!1;n=(k.x+p.x)/2;p=(k.y+p.y)/2;do t.y>p!==t.next.y>p&&t.next.y!==t.y&&n<(t.next.x-t.x)*(p-t.y)/(t.next.y-t.y)+t.x&&(q=!q),t=t.next;while(t!==k);t=q}k=t}if(k){a= -df(g,h);g=Qc(g,g.next);a=Qc(a,a.next);Rc(g,b,c,d,e,f);Rc(a,b,c,d,e,f);break a}h=h.next}g=g.next}while(g!==a)}break}}}}function Gg(a,b){return a.x-b.x}function Hg(a,b){var c=b,d=a.x,e=a.y,f=-Infinity;do{if(e<=c.y&&e>=c.next.y&&c.next.y!==c.y){var g=c.x+(e-c.y)*(c.next.x-c.x)/(c.next.y-c.y);if(g<=d&&g>f){f=g;if(g===d){if(e===c.y)return c;if(e===c.next.y)return c.next}var h=c.xp!==t.next.y>p&&t.next.y!==t.y&&n<(t.next.x-t.x)*(p-t.y)/(t.next.y-t.y)+t.x&&(q=!q),t=t.next;while(t!==k);t=q}k=t}if(k){a= +ef(g,h);g=Qc(g,g.next);a=Qc(a,a.next);Rc(g,b,c,d,e,f);Rc(a,b,c,d,e,f);break a}h=h.next}g=g.next}while(g!==a)}break}}}}function Gg(a,b){return a.x-b.x}function Hg(a,b){var c=b,d=a.x,e=a.y,f=-Infinity;do{if(e<=c.y&&e>=c.next.y&&c.next.y!==c.y){var g=c.x+(e-c.y)*(c.next.x-c.x)/(c.next.y-c.y);if(g<=d&&g>f){f=g;if(g===d){if(e===c.y)return c;if(e===c.next.y)return c.next}var h=c.x=c.x&&c.x>=g&&d!==c.x&&zd(eh.x)&&Sc(c,a)&&(h=c,m=q)),c=c.next;return h}function fe(a,b,c,d,e){a=32767*(a-c)*e;b=32767*(b-d)*e;a=(a|a<<8)&16711935;a=(a|a<<4)&252645135;a=(a|a<<2)&858993459;b=(b|b<<8)&16711935;b=(b|b<<4)&252645135;b=(b|b<<2)&858993459;return(a|a<<1)&1431655765|((b|b<<1)&1431655765)<<1}function Ig(a){var b=a,c=a;do b.xra(a.prev,a,a.next)?0<=ra(a,b,a.next)&&0<=ra(a,a.prev,b):0>ra(a,b,a.prev)||0>ra(a,a.next,b)}function df(a,b){var c=new ge(a.i,a.x,a.y),d=new ge(b.i,b.x,b.y),e=a.next,f=b.prev; -a.next=b;b.prev=a;c.next=e;e.prev=c;d.next=c;c.prev=d;f.next=d;d.prev=f;return d}function bf(a,b,c,d){a=new ge(a,b,c);d?(a.next=d.next,a.prev=d,d.next.prev=a,d.next=a):(a.prev=a,a.next=a);return a}function Pc(a){a.next.prev=a.prev;a.prev.next=a.next;a.prevZ&&(a.prevZ.nextZ=a.nextZ);a.nextZ&&(a.nextZ.prevZ=a.prevZ)}function ge(a,b,c){this.i=a;this.x=b;this.y=c;this.nextZ=this.prevZ=this.z=this.next=this.prev=null;this.steiner=!1}function ab(a,b){L.call(this);this.type="ExtrudeGeometry";this.parameters= -{shapes:a,options:b};this.fromBufferGeometry(new Ja(a,b));this.mergeVertices()}function Ja(a,b){"undefined"!==typeof a&&(C.call(this),this.type="ExtrudeBufferGeometry",a=Array.isArray(a)?a:[a],this.addShapeList(a,b),this.computeVertexNormals())}function Tc(a,b){L.call(this);this.type="TextGeometry";this.parameters={text:a,parameters:b};this.fromBufferGeometry(new $b(a,b));this.mergeVertices()}function $b(a,b){b=b||{};var c=b.font;if(!c||!c.isFont)return console.error("THREE.TextGeometry: font parameter is not an instance of THREE.Font."), +g)*(b-h)-(a-g)*(f-h)&&0<=(a-g)*(d-h)-(c-g)*(b-h)&&0<=(c-g)*(f-h)-(e-g)*(d-h)}function ra(a,b,c){return(b.y-a.y)*(c.x-b.x)-(b.x-a.x)*(c.y-b.y)}function rb(a,b){return a.x===b.x&&a.y===b.y}function df(a,b,c,d){return rb(a,b)&&rb(c,d)||rb(a,d)&&rb(c,b)?!0:0ra(a.prev,a,a.next)?0<=ra(a,b,a.next)&&0<=ra(a,a.prev,b):0>ra(a,b,a.prev)||0>ra(a,a.next,b)}function ef(a,b){var c=new ge(a.i,a.x,a.y),d=new ge(b.i,b.x,b.y),e=a.next,f=b.prev; +a.next=b;b.prev=a;c.next=e;e.prev=c;d.next=c;c.prev=d;f.next=d;d.prev=f;return d}function cf(a,b,c,d){a=new ge(a,b,c);d?(a.next=d.next,a.prev=d,d.next.prev=a,d.next=a):(a.prev=a,a.next=a);return a}function Pc(a){a.next.prev=a.prev;a.prev.next=a.next;a.prevZ&&(a.prevZ.nextZ=a.nextZ);a.nextZ&&(a.nextZ.prevZ=a.prevZ)}function ge(a,b,c){this.i=a;this.x=b;this.y=c;this.nextZ=this.prevZ=this.z=this.next=this.prev=null;this.steiner=!1}function ab(a,b){L.call(this);this.type="ExtrudeGeometry";this.parameters= +{shapes:a,options:b};this.fromBufferGeometry(new Ja(a,b));this.mergeVertices()}function Ja(a,b){"undefined"!==typeof a&&(C.call(this),this.type="ExtrudeBufferGeometry",a=Array.isArray(a)?a:[a],this.addShapeList(a,b),this.computeVertexNormals())}function Tc(a,b){L.call(this);this.type="TextGeometry";this.parameters={text:a,parameters:b};this.fromBufferGeometry(new Zb(a,b));this.mergeVertices()}function Zb(a,b){b=b||{};var c=b.font;if(!c||!c.isFont)return console.error("THREE.TextGeometry: font parameter is not an instance of THREE.Font."), new L;a=c.generateShapes(a,b.size,b.curveSegments);b.amount=void 0!==b.height?b.height:50;void 0===b.bevelThickness&&(b.bevelThickness=10);void 0===b.bevelSize&&(b.bevelSize=8);void 0===b.bevelEnabled&&(b.bevelEnabled=!1);Ja.call(this,a,b);this.type="TextBufferGeometry"}function Uc(a,b,c,d,e,f,g){L.call(this);this.type="SphereGeometry";this.parameters={radius:a,widthSegments:b,heightSegments:c,phiStart:d,phiLength:e,thetaStart:f,thetaLength:g};this.fromBufferGeometry(new sb(a,b,c,d,e,f,g));this.mergeVertices()} function sb(a,b,c,d,e,f,g){C.call(this);this.type="SphereBufferGeometry";this.parameters={radius:a,widthSegments:b,heightSegments:c,phiStart:d,phiLength:e,thetaStart:f,thetaLength:g};a=a||1;b=Math.max(3,Math.floor(b)||8);c=Math.max(2,Math.floor(c)||6);d=void 0!==d?d:0;e=void 0!==e?e:2*Math.PI;f=void 0!==f?f:0;g=void 0!==g?g:Math.PI;var h=f+g,k,m,q=0,n=[],l=new p,r=new p,t=[],v=[],w=[],z=[];for(m=0;m<=c;m++){var y=[],I=m/c;for(k=0;k<=b;k++){var A=k/b;l.x=-a*Math.cos(d+A*e)*Math.sin(f+I*g);l.y=a*Math.cos(f+ I*g);l.z=a*Math.sin(d+A*e)*Math.sin(f+I*g);v.push(l.x,l.y,l.z);r.set(l.x,l.y,l.z).normalize();w.push(r.x,r.y,r.z);z.push(A,1-I);y.push(q++)}n.push(y)}for(m=0;mq;q++){var n=m[f[q]];var l=m[f[(q+1)%3]];d[0]=Math.min(n,l);d[1]=Math.max(n,l);n=d[0]+","+ +new B(f,3));this.addAttribute("uv",new B(g,2))}function dc(a,b){C.call(this);this.type="EdgesGeometry";this.parameters={thresholdAngle:b};var c=[];b=Math.cos(O.DEG2RAD*(void 0!==b?b:1));var d=[0,0],e={},f=["a","b","c"];if(a.isBufferGeometry){var g=new L;g.fromBufferGeometry(a)}else g=a.clone();g.mergeVertices();g.computeFaceNormals();a=g.vertices;g=g.faces;for(var h=0,k=g.length;hq;q++){var n=m[f[q]];var l=m[f[(q+1)%3]];d[0]=Math.min(n,l);d[1]=Math.max(n,l);n=d[0]+","+ d[1];void 0===e[n]?e[n]={index1:d[0],index2:d[1],face1:h,face2:void 0}:e[n].face2=h}for(n in e)if(d=e[n],void 0===d.face2||g[d.face1].normal.dot(g[d.face2].normal)<=b)f=a[d.index1],c.push(f.x,f.y,f.z),f=a[d.index2],c.push(f.x,f.y,f.z);this.addAttribute("position",new B(c,3))}function tb(a,b,c,d,e,f,g,h){L.call(this);this.type="CylinderGeometry";this.parameters={radiusTop:a,radiusBottom:b,height:c,radialSegments:d,heightSegments:e,openEnded:f,thetaStart:g,thetaLength:h};this.fromBufferGeometry(new Ua(a, b,c,d,e,f,g,h));this.mergeVertices()}function Ua(a,b,c,d,e,f,g,h){function k(c){var e,f=new D,k=new p,u=0,v=!0===c?a:b,y=!0===c?1:-1;var x=t;for(e=1;e<=d;e++)n.push(0,w*y,0),l.push(0,y,0),r.push(.5,.5),t++;var B=t;for(e=0;e<=d;e++){var C=e/d*h+g,F=Math.cos(C),C=Math.sin(C);k.x=v*C;k.y=w*y;k.z=v*F;n.push(k.x,k.y,k.z);l.push(0,y,0);f.x=.5*F+.5;f.y=.5*C*y+.5;r.push(f.x,f.y);t++}for(e=0;ethis.duration&&this.resetDuration();this.optimize()}function Pd(a){this.manager= -void 0!==a?a:ja;this.textures={}}function ke(a){this.manager=void 0!==a?a:ja}function Ab(){this.onLoadStart=function(){};this.onLoadProgress=function(){};this.onLoadComplete=function(){}}function le(a){"boolean"===typeof a&&(console.warn("THREE.JSONLoader: showStatus parameter has been removed from constructor."),a=void 0);this.manager=void 0!==a?a:ja;this.withCredentials=!1}function ff(a){this.manager=void 0!==a?a:ja;this.texturePath=""}function me(a){"undefined"===typeof createImageBitmap&&console.warn("THREE.ImageBitmapLoader: createImageBitmap() not supported."); -"undefined"===typeof fetch&&console.warn("THREE.ImageBitmapLoader: fetch() not supported.");this.manager=void 0!==a?a:ja;this.options=void 0}function gf(a,b,c,d,e){b=.5*(d-b);e=.5*(e-c);var f=a*a;return(2*c-2*d+b+e)*a*f+(-3*c+3*d-2*b-e)*f+b*a+c}function cd(a,b,c,d){var e=1-a;return e*e*b+2*(1-a)*a*c+a*a*d}function dd(a,b,c,d,e){var f=1-a,g=1-a;return f*f*f*b+3*g*g*a*c+3*(1-a)*a*a*d+a*a*a*e}function P(){this.type="Curve";this.arcLengthDivisions=200}function Ma(a,b){P.call(this);this.type="LineCurve"; -this.v1=a||new D;this.v2=b||new D}function Bb(){P.call(this);this.type="CurvePath";this.curves=[];this.autoClose=!1}function Pa(a,b,c,d,e,f,g,h){P.call(this);this.type="EllipseCurve";this.aX=a||0;this.aY=b||0;this.xRadius=c||1;this.yRadius=d||1;this.aStartAngle=e||0;this.aEndAngle=f||2*Math.PI;this.aClockwise=g||!1;this.aRotation=h||0}function bb(a){P.call(this);this.type="SplineCurve";this.points=a||[]}function cb(a,b,c,d){P.call(this);this.type="CubicBezierCurve";this.v0=a||new D;this.v1=b||new D; -this.v2=c||new D;this.v3=d||new D}function db(a,b,c){P.call(this);this.type="QuadraticBezierCurve";this.v0=a||new D;this.v1=b||new D;this.v2=c||new D}function eb(a){Bb.call(this);this.type="Path";this.currentPoint=new D;a&&this.setFromPoints(a)}function Cb(a){eb.call(this,a);this.type="Shape";this.holes=[]}function ne(){this.type="ShapePath";this.subPaths=[];this.currentPath=null}function oe(a){this.type="Font";this.data=a}function hf(a){this.manager=void 0!==a?a:ja}function pe(a){this.manager=void 0!== -a?a:ja}function jf(){this.type="StereoCamera";this.aspect=1;this.eyeSep=.064;this.cameraL=new ba;this.cameraL.layers.enable(1);this.cameraL.matrixAutoUpdate=!1;this.cameraR=new ba;this.cameraR.layers.enable(2);this.cameraR.matrixAutoUpdate=!1}function ed(a,b,c){x.call(this);this.type="CubeCamera";var d=new ba(90,1,a,b);d.up.set(0,-1,0);d.lookAt(new p(1,0,0));this.add(d);var e=new ba(90,1,a,b);e.up.set(0,-1,0);e.lookAt(new p(-1,0,0));this.add(e);var f=new ba(90,1,a,b);f.up.set(0,0,1);f.lookAt(new p(0, -1,0));this.add(f);var g=new ba(90,1,a,b);g.up.set(0,0,-1);g.lookAt(new p(0,-1,0));this.add(g);var h=new ba(90,1,a,b);h.up.set(0,-1,0);h.lookAt(new p(0,0,1));this.add(h);var k=new ba(90,1,a,b);k.up.set(0,-1,0);k.lookAt(new p(0,0,-1));this.add(k);this.renderTarget=new Ib(c,c,{format:1022,magFilter:1006,minFilter:1006});this.renderTarget.texture.name="CubeCamera";this.update=function(a,b){null===this.parent&&this.updateMatrixWorld();var c=this.renderTarget,m=c.texture.generateMipmaps;c.texture.generateMipmaps= +void 0!==d?d:new b.constructor(c);this.sampleValues=b;this.valueSize=c}function Ld(a,b,c,d){za.call(this,a,b,c,d)}function ad(a,b,c,d){U.call(this,a,b,c,d)}function Md(a,b,c,d){U.call(this,a,b,c,d)}function hc(a,b,c,d){U.call(this,a,b,c,d)}function Nd(a,b,c,d){za.call(this,a,b,c,d);this._offsetNext=this._weightNext=this._offsetPrev=this._weightPrev=-0}function bd(a,b,c,d){za.call(this,a,b,c,d)}function Od(a,b,c,d){za.call(this,a,b,c,d)}function U(a,b,c,d){if(void 0===a)throw Error("THREE.KeyframeTrack: track name is undefined"); +if(void 0===b||0===b.length)throw Error("THREE.KeyframeTrack: no keyframes in track named "+a);this.name=a;this.times=da.convertArray(b,this.TimeBufferType);this.values=da.convertArray(c,this.ValueBufferType);this.setInterpolation(d||this.DefaultInterpolation);this.validate();this.optimize()}function ic(a,b,c,d){U.call(this,a,b,c,d)}function la(a,b,c){this.name=a;this.tracks=c;this.duration=void 0!==b?b:-1;this.uuid=O.generateUUID();0>this.duration&&this.resetDuration();this.optimize()}function Pd(a){this.manager= +void 0!==a?a:ja;this.textures={}}function ke(a){this.manager=void 0!==a?a:ja}function jc(){this.onLoadStart=function(){};this.onLoadProgress=function(){};this.onLoadComplete=function(){}}function le(a){"boolean"===typeof a&&(console.warn("THREE.JSONLoader: showStatus parameter has been removed from constructor."),a=void 0);this.manager=void 0!==a?a:ja;this.withCredentials=!1}function gf(a){this.manager=void 0!==a?a:ja;this.texturePath=""}function me(a){"undefined"===typeof createImageBitmap&&console.warn("THREE.ImageBitmapLoader: createImageBitmap() not supported."); +"undefined"===typeof fetch&&console.warn("THREE.ImageBitmapLoader: fetch() not supported.");this.manager=void 0!==a?a:ja;this.options=void 0}function hf(a,b,c,d,e){b=.5*(d-b);e=.5*(e-c);var f=a*a;return(2*c-2*d+b+e)*a*f+(-3*c+3*d-2*b-e)*f+b*a+c}function cd(a,b,c,d){var e=1-a;return e*e*b+2*(1-a)*a*c+a*a*d}function dd(a,b,c,d,e){var f=1-a,g=1-a;return f*f*f*b+3*g*g*a*c+3*(1-a)*a*a*d+a*a*a*e}function P(){this.type="Curve";this.arcLengthDivisions=200}function Ma(a,b){P.call(this);this.type="LineCurve"; +this.v1=a||new D;this.v2=b||new D}function Ab(){P.call(this);this.type="CurvePath";this.curves=[];this.autoClose=!1}function Pa(a,b,c,d,e,f,g,h){P.call(this);this.type="EllipseCurve";this.aX=a||0;this.aY=b||0;this.xRadius=c||1;this.yRadius=d||1;this.aStartAngle=e||0;this.aEndAngle=f||2*Math.PI;this.aClockwise=g||!1;this.aRotation=h||0}function bb(a){P.call(this);this.type="SplineCurve";this.points=a||[]}function cb(a,b,c,d){P.call(this);this.type="CubicBezierCurve";this.v0=a||new D;this.v1=b||new D; +this.v2=c||new D;this.v3=d||new D}function db(a,b,c){P.call(this);this.type="QuadraticBezierCurve";this.v0=a||new D;this.v1=b||new D;this.v2=c||new D}function eb(a){Ab.call(this);this.type="Path";this.currentPoint=new D;a&&this.setFromPoints(a)}function Bb(a){eb.call(this,a);this.type="Shape";this.holes=[]}function ne(){this.type="ShapePath";this.subPaths=[];this.currentPath=null}function oe(a){this.type="Font";this.data=a}function jf(a){this.manager=void 0!==a?a:ja}function pe(a){this.manager=void 0!== +a?a:ja}function kf(){this.type="StereoCamera";this.aspect=1;this.eyeSep=.064;this.cameraL=new ba;this.cameraL.layers.enable(1);this.cameraL.matrixAutoUpdate=!1;this.cameraR=new ba;this.cameraR.layers.enable(2);this.cameraR.matrixAutoUpdate=!1}function ed(a,b,c){x.call(this);this.type="CubeCamera";var d=new ba(90,1,a,b);d.up.set(0,-1,0);d.lookAt(new p(1,0,0));this.add(d);var e=new ba(90,1,a,b);e.up.set(0,-1,0);e.lookAt(new p(-1,0,0));this.add(e);var f=new ba(90,1,a,b);f.up.set(0,0,1);f.lookAt(new p(0, +1,0));this.add(f);var g=new ba(90,1,a,b);g.up.set(0,0,-1);g.lookAt(new p(0,-1,0));this.add(g);var h=new ba(90,1,a,b);h.up.set(0,-1,0);h.lookAt(new p(0,0,1));this.add(h);var k=new ba(90,1,a,b);k.up.set(0,-1,0);k.lookAt(new p(0,0,-1));this.add(k);this.renderTarget=new Hb(c,c,{format:1022,magFilter:1006,minFilter:1006});this.renderTarget.texture.name="CubeCamera";this.update=function(a,b){null===this.parent&&this.updateMatrixWorld();var c=this.renderTarget,m=c.texture.generateMipmaps;c.texture.generateMipmaps= !1;c.activeCubeFace=0;a.render(b,d,c);c.activeCubeFace=1;a.render(b,e,c);c.activeCubeFace=2;a.render(b,f,c);c.activeCubeFace=3;a.render(b,g,c);c.activeCubeFace=4;a.render(b,h,c);c.texture.generateMipmaps=m;c.activeCubeFace=5;a.render(b,k,c);a.setRenderTarget(null)};this.clear=function(a,b,c,d){for(var e=this.renderTarget,f=0;6>f;f++)e.activeCubeFace=f,a.setRenderTarget(e),a.clear(b,c,d);a.setRenderTarget(null)}}function qe(){x.call(this);this.type="AudioListener";this.context=re.getContext();this.gain= this.context.createGain();this.gain.connect(this.context.destination);this.filter=null}function kc(a){x.call(this);this.type="Audio";this.context=a.context;this.gain=this.context.createGain();this.gain.connect(a.getInput());this.autoplay=!1;this.buffer=null;this.loop=!1;this.offset=this.startTime=0;this.playbackRate=1;this.isPlaying=!1;this.hasPlaybackControl=!0;this.sourceType="empty";this.filters=[]}function se(a){kc.call(this,a);this.panner=this.context.createPanner();this.panner.connect(this.gain)} -function te(a,b){this.analyser=a.context.createAnalyser();this.analyser.fftSize=void 0!==b?b:2048;this.data=new Uint8Array(this.analyser.frequencyBinCount);a.getOutput().connect(this.analyser)}function ue(a,b,c){this.binding=a;this.valueSize=c;a=Float64Array;switch(b){case "quaternion":b=this._slerp;break;case "string":case "bool":a=Array;b=this._select;break;default:b=this._lerp}this.buffer=new a(4*c);this._mixBufferRegion=b;this.referenceCount=this.useCount=this.cumulativeWeight=0}function kf(a, -b,c){c=c||ga.parseTrackName(b);this._targetGroup=a;this._bindings=a.subscribe_(b,c)}function ga(a,b,c){this.path=b;this.parsedPath=c||ga.parseTrackName(b);this.node=ga.findNode(a,this.parsedPath.nodeName)||a;this.rootNode=a}function lf(){this.uuid=O.generateUUID();this._objects=Array.prototype.slice.call(arguments);this.nCachedObjects_=0;var a={};this._indicesByUUID=a;for(var b=0,c=arguments.length;b!==c;++b)a[arguments[b].uuid]=b;this._paths=[];this._parsedPaths=[];this._bindings=[];this._bindingsIndicesByPath= -{};var d=this;this.stats={objects:{get total(){return d._objects.length},get inUse(){return this.total-d.nCachedObjects_}},get bindingsPerObject(){return d._bindings.length}}}function mf(a,b,c){this._mixer=a;this._clip=b;this._localRoot=c||null;a=b.tracks;b=a.length;c=Array(b);for(var d={endingStart:2400,endingEnd:2400},e=0;e!==b;++e){var f=a[e].createInterpolant(null);c[e]=f;f.settings=d}this._interpolantSettings=d;this._interpolants=c;this._propertyBindings=Array(b);this._weightInterpolant=this._timeScaleInterpolant= +function te(a,b){this.analyser=a.context.createAnalyser();this.analyser.fftSize=void 0!==b?b:2048;this.data=new Uint8Array(this.analyser.frequencyBinCount);a.getOutput().connect(this.analyser)}function ue(a,b,c){this.binding=a;this.valueSize=c;a=Float64Array;switch(b){case "quaternion":b=this._slerp;break;case "string":case "bool":a=Array;b=this._select;break;default:b=this._lerp}this.buffer=new a(4*c);this._mixBufferRegion=b;this.referenceCount=this.useCount=this.cumulativeWeight=0}function lf(a, +b,c){c=c||ga.parseTrackName(b);this._targetGroup=a;this._bindings=a.subscribe_(b,c)}function ga(a,b,c){this.path=b;this.parsedPath=c||ga.parseTrackName(b);this.node=ga.findNode(a,this.parsedPath.nodeName)||a;this.rootNode=a}function mf(){this.uuid=O.generateUUID();this._objects=Array.prototype.slice.call(arguments);this.nCachedObjects_=0;var a={};this._indicesByUUID=a;for(var b=0,c=arguments.length;b!==c;++b)a[arguments[b].uuid]=b;this._paths=[];this._parsedPaths=[];this._bindings=[];this._bindingsIndicesByPath= +{};var d=this;this.stats={objects:{get total(){return d._objects.length},get inUse(){return this.total-d.nCachedObjects_}},get bindingsPerObject(){return d._bindings.length}}}function nf(a,b,c){this._mixer=a;this._clip=b;this._localRoot=c||null;a=b.tracks;b=a.length;c=Array(b);for(var d={endingStart:2400,endingEnd:2400},e=0;e!==b;++e){var f=a[e].createInterpolant(null);c[e]=f;f.settings=d}this._interpolantSettings=d;this._interpolants=c;this._propertyBindings=Array(b);this._weightInterpolant=this._timeScaleInterpolant= this._byClipCacheIndex=this._cacheIndex=null;this.loop=2201;this._loopCount=-1;this._startTime=null;this.time=0;this._effectiveWeight=this.weight=this._effectiveTimeScale=this.timeScale=1;this.repetitions=Infinity;this.paused=!1;this.enabled=!0;this.clampWhenFinished=!1;this.zeroSlopeAtEnd=this.zeroSlopeAtStart=!0}function ve(a){this._root=a;this._initMemoryManager();this.time=this._accuIndex=0;this.timeScale=1}function Qd(a,b){"string"===typeof a&&(console.warn("THREE.Uniform: Type parameter is no longer needed."), a=b);this.value=a}function we(){C.call(this);this.type="InstancedBufferGeometry";this.maxInstancedCount=void 0}function xe(a,b,c,d){this.uuid=O.generateUUID();this.data=a;this.itemSize=b;this.offset=c;this.normalized=!0===d}function lc(a,b){this.uuid=O.generateUUID();this.array=a;this.stride=b;this.count=void 0!==a?a.length/b:0;this.dynamic=!1;this.updateRange={offset:0,count:-1};this.onUploadCallback=function(){};this.version=0}function ye(a,b,c){lc.call(this,a,b);this.meshPerAttribute=c||1}function ze(a, -b,c){R.call(this,a,b);this.meshPerAttribute=c||1}function nf(a,b,c,d){this.ray=new ob(a,b);this.near=c||0;this.far=d||Infinity;this.params={Mesh:{},Line:{},LOD:{},Points:{threshold:1},Sprite:{}};Object.defineProperties(this.params,{PointCloud:{get:function(){console.warn("THREE.Raycaster: params.PointCloud has been renamed to params.Points.");return this.Points}}})}function of(a,b){return a.distance-b.distance}function Ae(a,b,c,d){if(!1!==a.visible&&(a.raycast(b,c),!0===d)){a=a.children;d=0;for(var e= -a.length;dc;c++,d++){var e=c/32*Math.PI*2,f=d/32*Math.PI*2;b.push(Math.cos(e),Math.sin(e),1,Math.cos(f),Math.sin(f),1)}a.addAttribute("position",new B(b,3));b=new W({fog:!1});this.cone=new X(a,b);this.add(this.cone);this.update()}function sf(a){var b=[];a&&a.isBone&&b.push(a);for(var c=0;cc;c++,d++){var e=c/32*Math.PI*2,f=d/32*Math.PI*2;b.push(Math.cos(e),Math.sin(e),1,Math.cos(f),Math.sin(f),1)}a.addAttribute("position",new B(b,3));b=new W({fog:!1});this.cone=new X(a,b);this.add(this.cone);this.update()}function tf(a){var b=[];a&&a.isBone&&b.push(a);for(var c=0;ca?-1:0b;b++)a[b]=(16>b?"0":"")+b.toString(16).toUpperCase(); @@ -369,8 +369,8 @@ this.z=Math.round(this.z);this.w=Math.round(this.w);return this},roundToZero:fun this.x+this.y*this.y+this.z*this.z+this.w*this.w},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y+this.z*this.z+this.w*this.w)},manhattanLength:function(){return Math.abs(this.x)+Math.abs(this.y)+Math.abs(this.z)+Math.abs(this.w)},normalize:function(){return this.divideScalar(this.length()||1)},setLength:function(a){return this.normalize().multiplyScalar(a)},lerp:function(a,b){this.x+=(a.x-this.x)*b;this.y+=(a.y-this.y)*b;this.z+=(a.z-this.z)*b;this.w+=(a.w-this.w)*b;return this},lerpVectors:function(a, b,c){return this.subVectors(b,a).multiplyScalar(c).add(a)},equals:function(a){return a.x===this.x&&a.y===this.y&&a.z===this.z&&a.w===this.w},fromArray:function(a,b){void 0===b&&(b=0);this.x=a[b];this.y=a[b+1];this.z=a[b+2];this.w=a[b+3];return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);a[b]=this.x;a[b+1]=this.y;a[b+2]=this.z;a[b+3]=this.w;return a},fromBufferAttribute:function(a,b,c){void 0!==c&&console.warn("THREE.Vector4: offset has been removed from .fromBufferAttribute()."); this.x=a.getX(b);this.y=a.getY(b);this.z=a.getZ(b);this.w=a.getW(b);return this}});gb.prototype=Object.assign(Object.create(xa.prototype),{constructor:gb,isWebGLRenderTarget:!0,setSize:function(a,b){if(this.width!==a||this.height!==b)this.width=a,this.height=b,this.dispose();this.viewport.set(0,0,a,b);this.scissor.set(0,0,a,b)},clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.width=a.width;this.height=a.height;this.viewport.copy(a.viewport);this.texture=a.texture.clone(); -this.depthBuffer=a.depthBuffer;this.stencilBuffer=a.stencilBuffer;this.depthTexture=a.depthTexture;return this},dispose:function(){this.dispatchEvent({type:"dispose"})}});Ib.prototype=Object.create(gb.prototype);Ib.prototype.constructor=Ib;Ib.prototype.isWebGLRenderTargetCube=!0;hb.prototype=Object.create(V.prototype);hb.prototype.constructor=hb;hb.prototype.isDataTexture=!0;Wa.prototype=Object.create(V.prototype);Wa.prototype.constructor=Wa;Wa.prototype.isCubeTexture=!0;Object.defineProperty(Wa.prototype, -"images",{get:function(){return this.image},set:function(a){this.image=a}});var Me=new V,Ne=new Wa,He=[],Je=[],Le=new Float32Array(16),Ke=new Float32Array(9);Re.prototype.setValue=function(a,b){for(var c=this.seq,d=0,e=c.length;d!==e;++d){var f=c[d];f.setValue(a,b[f.id])}};var Vd=/([\w\d_]+)(\])?(\[|\.)?/g;ib.prototype.setValue=function(a,b,c){b=this.map[b];void 0!==b&&b.setValue(a,c,this.renderer)};ib.prototype.setOptional=function(a,b,c){b=b[c];void 0!==b&&this.setValue(a,c,b)};ib.upload=function(a, +this.depthBuffer=a.depthBuffer;this.stencilBuffer=a.stencilBuffer;this.depthTexture=a.depthTexture;return this},dispose:function(){this.dispatchEvent({type:"dispose"})}});Hb.prototype=Object.create(gb.prototype);Hb.prototype.constructor=Hb;Hb.prototype.isWebGLRenderTargetCube=!0;hb.prototype=Object.create(V.prototype);hb.prototype.constructor=hb;hb.prototype.isDataTexture=!0;Wa.prototype=Object.create(V.prototype);Wa.prototype.constructor=Wa;Wa.prototype.isCubeTexture=!0;Object.defineProperty(Wa.prototype, +"images",{get:function(){return this.image},set:function(a){this.image=a}});var Ne=new V,Oe=new Wa,Ie=[],Ke=[],Me=new Float32Array(16),Le=new Float32Array(9);Se.prototype.setValue=function(a,b){for(var c=this.seq,d=0,e=c.length;d!==e;++d){var f=c[d];f.setValue(a,b[f.id])}};var Vd=/([\w\d_]+)(\])?(\[|\.)?/g;ib.prototype.setValue=function(a,b,c){b=this.map[b];void 0!==b&&b.setValue(a,c,this.renderer)};ib.prototype.setOptional=function(a,b,c){b=b[c];void 0!==b&&this.setValue(a,c,b)};ib.upload=function(a, b,c,d){for(var e=0,f=b.length;e!==f;++e){var g=b[e],h=c[g.id];!1!==h.needsUpdate&&g.setValue(a,h.value,d)}};ib.seqWithValue=function(a,b){for(var c=[],d=0,e=a.length;d!==e;++d){var f=a[d];f.id in b&&c.push(f)}return c};var Jg={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, @@ -508,7 +508,7 @@ this.quaternion,this.scale);this.matrixWorldNeedsUpdate=!0},updateMatrixWorld:fu this.matrix.toArray();void 0!==this.geometry&&(f.geometry=b(a.geometries,this.geometry));if(void 0!==this.material)if(Array.isArray(this.material)){for(var g=[],h=0,k=this.material.length;he&&0>d?null:0>e?this.at(d,c):this.at(e,c)}}(),intersectsSphere:function(a){return this.distanceToPoint(a.center)<=a.radius},distanceToPlane:function(a){var b=a.normal.dot(this.direction);if(0===b)return 0===a.distanceToPoint(this.origin)?0:null;a=-(this.origin.dot(a.normal)+a.constant)/b;return 0<=a?a:null},intersectPlane:function(a,b){a=this.distanceToPlane(a);return null===a?null:this.at(a,b)},intersectsPlane:function(a){var b=a.distanceToPoint(this.origin); return 0===b||0>a.normal.dot(this.direction)*b?!0:!1},intersectBox:function(a,b){var c=1/this.direction.x;var d=1/this.direction.y;var e=1/this.direction.z,f=this.origin;if(0<=c){var g=(a.min.x-f.x)*c;c*=a.max.x-f.x}else g=(a.max.x-f.x)*c,c*=a.min.x-f.x;if(0<=d){var h=(a.min.y-f.y)*d;d*=a.max.y-f.y}else h=(a.max.y-f.y)*d,d*=a.min.y-f.y;if(g>d||h>c)return null;if(h>g||g!==g)g=h;if(da||h>c)return null; if(h>g||g!==g)g=h;if(ac?null:this.at(0<=g?g:c,b)},intersectsBox:function(){var a=new p;return function(b){return null!==this.intersectBox(b,a)}}(),intersectTriangle:function(){var a=new p,b=new p,c=new p,d=new p;return function(e,f,g,h,k){b.subVectors(f,e);c.subVectors(g,e);d.crossVectors(b,c);f=this.direction.dot(d);if(0f)h=-1,f=-f;else return null;a.subVectors(this.origin,e);e=h*this.direction.dot(c.crossVectors(a,c));if(0>e)return null; -g=h*this.direction.dot(b.cross(a));if(0>g||e+g>f)return null;e=-h*a.dot(d);return 0>e?null:this.at(e/f,k)}}(),applyMatrix4:function(a){this.origin.applyMatrix4(a);this.direction.transformDirection(a);return this},equals:function(a){return a.origin.equals(this.origin)&&a.direction.equals(this.direction)}});Object.assign(Mb.prototype,{set:function(a,b){this.start.copy(a);this.end.copy(b);return this},clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.start.copy(a.start); +g=h*this.direction.dot(b.cross(a));if(0>g||e+g>f)return null;e=-h*a.dot(d);return 0>e?null:this.at(e/f,k)}}(),applyMatrix4:function(a){this.origin.applyMatrix4(a);this.direction.transformDirection(a);return this},equals:function(a){return a.origin.equals(this.origin)&&a.direction.equals(this.direction)}});Object.assign(Lb.prototype,{set:function(a,b){this.start.copy(a);this.end.copy(b);return this},clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.start.copy(a.start); this.end.copy(a.end);return this},getCenter:function(a){return(a||new p).addVectors(this.start,this.end).multiplyScalar(.5)},delta:function(a){return(a||new p).subVectors(this.end,this.start)},distanceSq:function(){return this.start.distanceToSquared(this.end)},distance:function(){return this.start.distanceTo(this.end)},at:function(a,b){b=b||new p;return this.delta(b).multiplyScalar(a).add(this.start)},closestPointToPointParameter:function(){var a=new p,b=new p;return function(c,d){a.subVectors(c, this.start);b.subVectors(this.end,this.start);c=b.dot(b);c=b.dot(a)/c;d&&(c=O.clamp(c,0,1));return c}}(),closestPointToPoint:function(a,b,c){a=this.closestPointToPointParameter(a,b);c=c||new p;return this.delta(c).multiplyScalar(a).add(this.start)},applyMatrix4:function(a){this.start.applyMatrix4(a);this.end.applyMatrix4(a);return this},equals:function(a){return a.start.equals(this.start)&&a.end.equals(this.end)}});Object.assign(Sa,{normal:function(){var a=new p;return function(b,c,d,e){e=e||new p; e.subVectors(d,c);a.subVectors(b,c);e.cross(a);b=e.lengthSq();return 0=b.x+b.y}}()});Object.assign(Sa.prototype,{set:function(a,b,c){this.a.copy(a);this.b.copy(b);this.c.copy(c);return this},setFromPointsAndIndices:function(a,b,c,d){this.a.copy(a[b]);this.b.copy(a[c]);this.c.copy(a[d]);return this},clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.a.copy(a.a);this.b.copy(a.b);this.c.copy(a.c);return this},area:function(){var a=new p,b=new p;return function(){a.subVectors(this.c, this.b);b.subVectors(this.a,this.b);return.5*a.cross(b).length()}}(),midpoint:function(a){return(a||new p).addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)},normal:function(a){return Sa.normal(this.a,this.b,this.c,a)},plane:function(a){return(a||new Ca).setFromCoplanarPoints(this.a,this.b,this.c)},barycoordFromPoint:function(a,b){return Sa.barycoordFromPoint(a,this.a,this.b,this.c,b)},containsPoint:function(a){return Sa.containsPoint(a,this.a,this.b,this.c)},closestPointToPoint:function(){var a= -new Ca,b=[new Mb,new Mb,new Mb],c=new p,d=new p;return function(e,f){f=f||new p;var g=Infinity;a.setFromCoplanarPoints(this.a,this.b,this.c);a.projectPoint(e,c);if(!0===this.containsPoint(c))f.copy(c);else for(b[0].set(this.a,this.b),b[1].set(this.b,this.c),b[2].set(this.c,this.a),e=0;ec.far?null:{distance:b,point:z.clone(),object:a}}function c(c,d,e,f,m,l,q,n){g.fromBufferAttribute(f,l);h.fromBufferAttribute(f,q);k.fromBufferAttribute(f,n);if(c=b(c,c.material,d,e,g,h,k,w))m&&(u.fromBufferAttribute(m, @@ -594,8 +594,8 @@ I=g;F=h;L=k}if(x=b(this,x,q,e,I,F,L,w))B&&B[H]&&(N=B[H],u.copy(N[0]),r.copy(N[1] this.view=null===a.view?null:Object.assign({},a.view);this.filmGauge=a.filmGauge;this.filmOffset=a.filmOffset;return this},setFocalLength:function(a){a=.5*this.getFilmHeight()/a;this.fov=2*O.RAD2DEG*Math.atan(a);this.updateProjectionMatrix()},getFocalLength:function(){var a=Math.tan(.5*O.DEG2RAD*this.fov);return.5*this.getFilmHeight()/a},getEffectiveFOV:function(){return 2*O.RAD2DEG*Math.atan(Math.tan(.5*O.DEG2RAD*this.fov)/this.zoom)},getFilmWidth:function(){return this.filmGauge*Math.min(this.aspect, 1)},getFilmHeight:function(){return this.filmGauge/Math.max(this.aspect,1)},setViewOffset:function(a,b,c,d,e,f){this.aspect=a/b;null===this.view&&(this.view={enabled:!0,fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1});this.view.enabled=!0;this.view.fullWidth=a;this.view.fullHeight=b;this.view.offsetX=c;this.view.offsetY=d;this.view.width=e;this.view.height=f;this.updateProjectionMatrix()},clearViewOffset:function(){null!==this.view&&(this.view.enabled=!1);this.updateProjectionMatrix()}, updateProjectionMatrix:function(){var a=this.near,b=a*Math.tan(.5*O.DEG2RAD*this.fov)/this.zoom,c=2*b,d=this.aspect*c,e=-.5*d,f=this.view;if(null!==this.view&&this.view.enabled)var g=f.fullWidth,h=f.fullHeight,e=e+f.offsetX*d/g,b=b-f.offsetY*c/h,d=f.width/g*d,c=f.height/h*c;f=this.filmOffset;0!==f&&(e+=a*f/this.getFilmWidth());this.projectionMatrix.makePerspective(e,e+d,b,b-c,a,this.far)},toJSON:function(a){a=x.prototype.toJSON.call(this,a);a.object.fov=this.fov;a.object.zoom=this.zoom;a.object.near= -this.near;a.object.far=this.far;a.object.focus=this.focus;a.object.aspect=this.aspect;null!==this.view&&(a.object.view=Object.assign({},this.view));a.object.filmGauge=this.filmGauge;a.object.filmOffset=this.filmOffset;return a}});ud.prototype=Object.assign(Object.create(ba.prototype),{constructor:ud,isArrayCamera:!0});Ob.prototype.isFogExp2=!0;Ob.prototype.clone=function(){return new Ob(this.color.getHex(),this.density)};Ob.prototype.toJSON=function(){return{type:"FogExp2",color:this.color.getHex(), -density:this.density}};Pb.prototype.isFog=!0;Pb.prototype.clone=function(){return new Pb(this.color.getHex(),this.near,this.far)};Pb.prototype.toJSON=function(){return{type:"Fog",color:this.color.getHex(),near:this.near,far:this.far}};vd.prototype=Object.assign(Object.create(x.prototype),{constructor:vd,copy:function(a,b){x.prototype.copy.call(this,a,b);null!==a.background&&(this.background=a.background.clone());null!==a.fog&&(this.fog=a.fog.clone());null!==a.overrideMaterial&&(this.overrideMaterial= +this.near;a.object.far=this.far;a.object.focus=this.focus;a.object.aspect=this.aspect;null!==this.view&&(a.object.view=Object.assign({},this.view));a.object.filmGauge=this.filmGauge;a.object.filmOffset=this.filmOffset;return a}});ud.prototype=Object.assign(Object.create(ba.prototype),{constructor:ud,isArrayCamera:!0});Nb.prototype.isFogExp2=!0;Nb.prototype.clone=function(){return new Nb(this.color.getHex(),this.density)};Nb.prototype.toJSON=function(){return{type:"FogExp2",color:this.color.getHex(), +density:this.density}};Ob.prototype.isFog=!0;Ob.prototype.clone=function(){return new Ob(this.color.getHex(),this.near,this.far)};Ob.prototype.toJSON=function(){return{type:"Fog",color:this.color.getHex(),near:this.near,far:this.far}};vd.prototype=Object.assign(Object.create(x.prototype),{constructor:vd,copy:function(a,b){x.prototype.copy.call(this,a,b);null!==a.background&&(this.background=a.background.clone());null!==a.fog&&(this.fog=a.fog.clone());null!==a.overrideMaterial&&(this.overrideMaterial= a.overrideMaterial.clone());this.autoUpdate=a.autoUpdate;this.matrixAutoUpdate=a.matrixAutoUpdate;return this},toJSON:function(a){var b=x.prototype.toJSON.call(this,a);null!==this.background&&(b.object.background=this.background.toJSON(a));null!==this.fog&&(b.object.fog=this.fog.toJSON());return b}});de.prototype=Object.assign(Object.create(x.prototype),{constructor:de,isLensFlare:!0,copy:function(a){x.prototype.copy.call(this,a);this.positionScreen.copy(a.positionScreen);this.customUpdateCallback= a.customUpdateCallback;for(var b=0,c=a.lensFlares.length;bf||(l.applyMatrix4(this.matrixWorld),u=d.ray.origin.distanceTo(l),ud.far||e.push({distance:u,point:h.clone().applyMatrix4(this.matrixWorld),index:g,face:null,faceIndex:null,object:this}));else for(g=0,v=r.length/3-1;gf||(l.applyMatrix4(this.matrixWorld),u=d.ray.origin.distanceTo(l), ud.far||e.push({distance:u,point:h.clone().applyMatrix4(this.matrixWorld),index:g,face:null,faceIndex:null,object:this}))}else if(g.isGeometry)for(k=g.vertices,m=k.length,g=0;gf||(l.applyMatrix4(this.matrixWorld),u=d.ray.origin.distanceTo(l),ud.far||e.push({distance:u,point:h.clone().applyMatrix4(this.matrixWorld),index:g,face:null,faceIndex:null,object:this}))}}}(),clone:function(){return(new this.constructor(this.geometry, -this.material)).copy(this)}});X.prototype=Object.assign(Object.create(oa.prototype),{constructor:X,isLineSegments:!0});yd.prototype=Object.assign(Object.create(oa.prototype),{constructor:yd,isLineLoop:!0});Da.prototype=Object.create(N.prototype);Da.prototype.constructor=Da;Da.prototype.isPointsMaterial=!0;Da.prototype.copy=function(a){N.prototype.copy.call(this,a);this.color.copy(a.color);this.map=a.map;this.size=a.size;this.sizeAttenuation=a.sizeAttenuation;return this};Qb.prototype=Object.assign(Object.create(x.prototype), -{constructor:Qb,isPoints:!0,raycast:function(){var a=new H,b=new ob,c=new Fa;return function(d,e){function f(a,c){var f=b.distanceSqToPoint(a);if(fd.far||e.push({distance:h,distanceToRay:Math.sqrt(f),point:a.clone(),index:c,face:null,object:g})}}var g=this,h=this.geometry,k=this.matrixWorld,m=d.params.Points.threshold;null===h.boundingSphere&&h.computeBoundingSphere();c.copy(h.boundingSphere);c.applyMatrix4(k); +this.material)).copy(this)}});X.prototype=Object.assign(Object.create(oa.prototype),{constructor:X,isLineSegments:!0});yd.prototype=Object.assign(Object.create(oa.prototype),{constructor:yd,isLineLoop:!0});Da.prototype=Object.create(N.prototype);Da.prototype.constructor=Da;Da.prototype.isPointsMaterial=!0;Da.prototype.copy=function(a){N.prototype.copy.call(this,a);this.color.copy(a.color);this.map=a.map;this.size=a.size;this.sizeAttenuation=a.sizeAttenuation;return this};Pb.prototype=Object.assign(Object.create(x.prototype), +{constructor:Pb,isPoints:!0,raycast:function(){var a=new H,b=new ob,c=new Fa;return function(d,e){function f(a,c){var f=b.distanceSqToPoint(a);if(fd.far||e.push({distance:h,distanceToRay:Math.sqrt(f),point:a.clone(),index:c,face:null,object:g})}}var g=this,h=this.geometry,k=this.matrixWorld,m=d.params.Points.threshold;null===h.boundingSphere&&h.computeBoundingSphere();c.copy(h.boundingSphere);c.applyMatrix4(k); c.radius+=m;if(!1!==d.ray.intersectsSphere(c)){a.getInverse(k);b.copy(d.ray).applyMatrix4(a);var m=m/((this.scale.x+this.scale.y+this.scale.z)/3),l=m*m,m=new p;if(h.isBufferGeometry){var n=h.index,h=h.attributes.position.array;if(null!==n)for(var u=n.array,n=0,r=u.length;n=a.HAVE_CURRENT_DATA&&(this.needsUpdate=!0)}});Rb.prototype=Object.create(V.prototype);Rb.prototype.constructor=Rb;Rb.prototype.isCompressedTexture=!0;Fc.prototype=Object.create(V.prototype);Fc.prototype.constructor=Fc;Fc.prototype.isDepthTexture=!0;Sb.prototype=Object.create(C.prototype); -Sb.prototype.constructor=Sb;Gc.prototype=Object.create(L.prototype);Gc.prototype.constructor=Gc;Tb.prototype=Object.create(C.prototype);Tb.prototype.constructor=Tb;Hc.prototype=Object.create(L.prototype);Hc.prototype.constructor=Hc;sa.prototype=Object.create(C.prototype);sa.prototype.constructor=sa;Ic.prototype=Object.create(L.prototype);Ic.prototype.constructor=Ic;Ub.prototype=Object.create(sa.prototype);Ub.prototype.constructor=Ub;Jc.prototype=Object.create(L.prototype);Jc.prototype.constructor= -Jc;qb.prototype=Object.create(sa.prototype);qb.prototype.constructor=qb;Kc.prototype=Object.create(L.prototype);Kc.prototype.constructor=Kc;Vb.prototype=Object.create(sa.prototype);Vb.prototype.constructor=Vb;Lc.prototype=Object.create(L.prototype);Lc.prototype.constructor=Lc;Wb.prototype=Object.create(sa.prototype);Wb.prototype.constructor=Wb;Mc.prototype=Object.create(L.prototype);Mc.prototype.constructor=Mc;Xb.prototype=Object.create(C.prototype);Xb.prototype.constructor=Xb;Nc.prototype=Object.create(L.prototype); -Nc.prototype.constructor=Nc;Yb.prototype=Object.create(C.prototype);Yb.prototype.constructor=Yb;Oc.prototype=Object.create(L.prototype);Oc.prototype.constructor=Oc;Zb.prototype=Object.create(C.prototype);Zb.prototype.constructor=Zb;var Kg={triangulate:function(a,b,c){c=c||2;var d=b&&b.length,e=d?b[0]*c:a.length,f=af(a,0,e,c,!0),g=[];if(!f)return g;var h;if(d){var k=c,d=[],m;var l=0;for(m=b.length;l80*c){var r=h=a[0];var t=d=a[1];for(k=c;kh&&(h=l),b>d&&(d=b);h=Math.max(h-r,d-t);h=0!==h?1/h:0}Rc(f,g,c,r,t,h);return g}},Ta={area:function(a){for(var b=a.length,c=0,d=b-1,e=0;eTa.area(a)},triangulateShape:function(a,b){function c(a){var b=a.length;2=a.HAVE_CURRENT_DATA&&(this.needsUpdate=!0)}});Qb.prototype=Object.create(V.prototype);Qb.prototype.constructor=Qb;Qb.prototype.isCompressedTexture=!0;Fc.prototype=Object.create(V.prototype);Fc.prototype.constructor=Fc;Fc.prototype.isDepthTexture=!0;Rb.prototype=Object.create(C.prototype); +Rb.prototype.constructor=Rb;Gc.prototype=Object.create(L.prototype);Gc.prototype.constructor=Gc;Sb.prototype=Object.create(C.prototype);Sb.prototype.constructor=Sb;Hc.prototype=Object.create(L.prototype);Hc.prototype.constructor=Hc;sa.prototype=Object.create(C.prototype);sa.prototype.constructor=sa;Ic.prototype=Object.create(L.prototype);Ic.prototype.constructor=Ic;Tb.prototype=Object.create(sa.prototype);Tb.prototype.constructor=Tb;Jc.prototype=Object.create(L.prototype);Jc.prototype.constructor= +Jc;qb.prototype=Object.create(sa.prototype);qb.prototype.constructor=qb;Kc.prototype=Object.create(L.prototype);Kc.prototype.constructor=Kc;Ub.prototype=Object.create(sa.prototype);Ub.prototype.constructor=Ub;Lc.prototype=Object.create(L.prototype);Lc.prototype.constructor=Lc;Vb.prototype=Object.create(sa.prototype);Vb.prototype.constructor=Vb;Mc.prototype=Object.create(L.prototype);Mc.prototype.constructor=Mc;Wb.prototype=Object.create(C.prototype);Wb.prototype.constructor=Wb;Nc.prototype=Object.create(L.prototype); +Nc.prototype.constructor=Nc;Xb.prototype=Object.create(C.prototype);Xb.prototype.constructor=Xb;Oc.prototype=Object.create(L.prototype);Oc.prototype.constructor=Oc;Yb.prototype=Object.create(C.prototype);Yb.prototype.constructor=Yb;var Kg={triangulate:function(a,b,c){c=c||2;var d=b&&b.length,e=d?b[0]*c:a.length,f=bf(a,0,e,c,!0),g=[];if(!f)return g;var h;if(d){var k=c,d=[],m;var l=0;for(m=b.length;l80*c){var r=h=a[0];var t=d=a[1];for(k=c;kh&&(h=l),b>d&&(d=b);h=Math.max(h-r,d-t);h=0!==h?1/h:0}Rc(f,g,c,r,t,h);return g}},Ta={area:function(a){for(var b=a.length,c=0,d=b-1,e=0;eTa.area(a)},triangulateShape:function(a,b){function c(a){var b=a.length;2Number.EPSILON){var k=Math.sqrt(h),m=Math.sqrt(f*f+g*g),h=b.x-e/k;b=b.y+d/k;g=((c.x-g/m-h)*g-(c.y+f/m-b)*f)/(d*g-e*f);f=h+d*g-a.x;d=b+e*g-a.y;e=f*f+d*d;if(2>=e)return new D(f,d);e=Math.sqrt(e/2)}else a=!1,d>Number.EPSILON?f>Number.EPSILON&&(a=!0):d<-Number.EPSILON?f<-Number.EPSILON&&(a=!0):Math.sign(e)===Math.sign(g)&&(a=!0),a?(f=-e,e=Math.sqrt(h)):(f= @@ -629,12 +629,12 @@ G+1;GMath.abs(g-k)?[new D(a,1-c),new D(h,1-d),new D(m,1-e),new D(n,1-b)]:[new D(g,1-c),new D(k,1-d),new D(l,1-e),new D(p,1-b)]}};Tc.prototype=Object.create(L.prototype);Tc.prototype.constructor=Tc;$b.prototype=Object.create(Ja.prototype);$b.prototype.constructor=$b;Uc.prototype=Object.create(L.prototype);Uc.prototype.constructor=Uc;sb.prototype= -Object.create(C.prototype);sb.prototype.constructor=sb;Vc.prototype=Object.create(L.prototype);Vc.prototype.constructor=Vc;ac.prototype=Object.create(C.prototype);ac.prototype.constructor=ac;Wc.prototype=Object.create(L.prototype);Wc.prototype.constructor=Wc;bc.prototype=Object.create(C.prototype);bc.prototype.constructor=bc;cc.prototype=Object.create(L.prototype);cc.prototype.constructor=cc;dc.prototype=Object.create(C.prototype);dc.prototype.constructor=dc;ec.prototype=Object.create(C.prototype); -ec.prototype.constructor=ec;tb.prototype=Object.create(L.prototype);tb.prototype.constructor=tb;Ua.prototype=Object.create(C.prototype);Ua.prototype.constructor=Ua;Xc.prototype=Object.create(tb.prototype);Xc.prototype.constructor=Xc;Yc.prototype=Object.create(Ua.prototype);Yc.prototype.constructor=Yc;Zc.prototype=Object.create(L.prototype);Zc.prototype.constructor=Zc;fc.prototype=Object.create(C.prototype);fc.prototype.constructor=fc;var Ea=Object.freeze({WireframeGeometry:Sb,ParametricGeometry:Gc, -ParametricBufferGeometry:Tb,TetrahedronGeometry:Ic,TetrahedronBufferGeometry:Ub,OctahedronGeometry:Jc,OctahedronBufferGeometry:qb,IcosahedronGeometry:Kc,IcosahedronBufferGeometry:Vb,DodecahedronGeometry:Lc,DodecahedronBufferGeometry:Wb,PolyhedronGeometry:Hc,PolyhedronBufferGeometry:sa,TubeGeometry:Mc,TubeBufferGeometry:Xb,TorusKnotGeometry:Nc,TorusKnotBufferGeometry:Yb,TorusGeometry:Oc,TorusBufferGeometry:Zb,TextGeometry:Tc,TextBufferGeometry:$b,SphereGeometry:Uc,SphereBufferGeometry:sb,RingGeometry:Vc, -RingBufferGeometry:ac,PlaneGeometry:zc,PlaneBufferGeometry:nb,LatheGeometry:Wc,LatheBufferGeometry:bc,ShapeGeometry:cc,ShapeBufferGeometry:dc,ExtrudeGeometry:ab,ExtrudeBufferGeometry:Ja,EdgesGeometry:ec,ConeGeometry:Xc,ConeBufferGeometry:Yc,CylinderGeometry:tb,CylinderBufferGeometry:Ua,CircleGeometry:Zc,CircleBufferGeometry:fc,BoxGeometry:Lb,BoxBufferGeometry:mb});gc.prototype=Object.create(N.prototype);gc.prototype.constructor=gc;gc.prototype.isShadowMaterial=!0;hc.prototype=Object.create(pa.prototype); -hc.prototype.constructor=hc;hc.prototype.isRawShaderMaterial=!0;Oa.prototype=Object.create(N.prototype);Oa.prototype.constructor=Oa;Oa.prototype.isMeshStandardMaterial=!0;Oa.prototype.copy=function(a){N.prototype.copy.call(this,a);this.defines={STANDARD:""};this.color.copy(a.color);this.roughness=a.roughness;this.metalness=a.metalness;this.map=a.map;this.lightMap=a.lightMap;this.lightMapIntensity=a.lightMapIntensity;this.aoMap=a.aoMap;this.aoMapIntensity=a.aoMapIntensity;this.emissive.copy(a.emissive); +b,c,d,e,f){a=b[3*c];var g=b[3*c+1];c=b[3*c+2];var h=b[3*d],k=b[3*d+1];d=b[3*d+2];var m=b[3*e],l=b[3*e+1];e=b[3*e+2];var n=b[3*f],p=b[3*f+1];b=b[3*f+2];return.01>Math.abs(g-k)?[new D(a,1-c),new D(h,1-d),new D(m,1-e),new D(n,1-b)]:[new D(g,1-c),new D(k,1-d),new D(l,1-e),new D(p,1-b)]}};Tc.prototype=Object.create(L.prototype);Tc.prototype.constructor=Tc;Zb.prototype=Object.create(Ja.prototype);Zb.prototype.constructor=Zb;Uc.prototype=Object.create(L.prototype);Uc.prototype.constructor=Uc;sb.prototype= +Object.create(C.prototype);sb.prototype.constructor=sb;Vc.prototype=Object.create(L.prototype);Vc.prototype.constructor=Vc;$b.prototype=Object.create(C.prototype);$b.prototype.constructor=$b;Wc.prototype=Object.create(L.prototype);Wc.prototype.constructor=Wc;ac.prototype=Object.create(C.prototype);ac.prototype.constructor=ac;bc.prototype=Object.create(L.prototype);bc.prototype.constructor=bc;cc.prototype=Object.create(C.prototype);cc.prototype.constructor=cc;dc.prototype=Object.create(C.prototype); +dc.prototype.constructor=dc;tb.prototype=Object.create(L.prototype);tb.prototype.constructor=tb;Ua.prototype=Object.create(C.prototype);Ua.prototype.constructor=Ua;Xc.prototype=Object.create(tb.prototype);Xc.prototype.constructor=Xc;Yc.prototype=Object.create(Ua.prototype);Yc.prototype.constructor=Yc;Zc.prototype=Object.create(L.prototype);Zc.prototype.constructor=Zc;ec.prototype=Object.create(C.prototype);ec.prototype.constructor=ec;var Ea=Object.freeze({WireframeGeometry:Rb,ParametricGeometry:Gc, +ParametricBufferGeometry:Sb,TetrahedronGeometry:Ic,TetrahedronBufferGeometry:Tb,OctahedronGeometry:Jc,OctahedronBufferGeometry:qb,IcosahedronGeometry:Kc,IcosahedronBufferGeometry:Ub,DodecahedronGeometry:Lc,DodecahedronBufferGeometry:Vb,PolyhedronGeometry:Hc,PolyhedronBufferGeometry:sa,TubeGeometry:Mc,TubeBufferGeometry:Wb,TorusKnotGeometry:Nc,TorusKnotBufferGeometry:Xb,TorusGeometry:Oc,TorusBufferGeometry:Yb,TextGeometry:Tc,TextBufferGeometry:Zb,SphereGeometry:Uc,SphereBufferGeometry:sb,RingGeometry:Vc, +RingBufferGeometry:$b,PlaneGeometry:zc,PlaneBufferGeometry:nb,LatheGeometry:Wc,LatheBufferGeometry:ac,ShapeGeometry:bc,ShapeBufferGeometry:cc,ExtrudeGeometry:ab,ExtrudeBufferGeometry:Ja,EdgesGeometry:dc,ConeGeometry:Xc,ConeBufferGeometry:Yc,CylinderGeometry:tb,CylinderBufferGeometry:Ua,CircleGeometry:Zc,CircleBufferGeometry:ec,BoxGeometry:Kb,BoxBufferGeometry:mb});fc.prototype=Object.create(N.prototype);fc.prototype.constructor=fc;fc.prototype.isShadowMaterial=!0;gc.prototype=Object.create(pa.prototype); +gc.prototype.constructor=gc;gc.prototype.isRawShaderMaterial=!0;Oa.prototype=Object.create(N.prototype);Oa.prototype.constructor=Oa;Oa.prototype.isMeshStandardMaterial=!0;Oa.prototype.copy=function(a){N.prototype.copy.call(this,a);this.defines={STANDARD:""};this.color.copy(a.color);this.roughness=a.roughness;this.metalness=a.metalness;this.map=a.map;this.lightMap=a.lightMap;this.lightMapIntensity=a.lightMapIntensity;this.aoMap=a.aoMap;this.aoMapIntensity=a.aoMapIntensity;this.emissive.copy(a.emissive); this.emissiveMap=a.emissiveMap;this.emissiveIntensity=a.emissiveIntensity;this.bumpMap=a.bumpMap;this.bumpScale=a.bumpScale;this.normalMap=a.normalMap;this.normalScale.copy(a.normalScale);this.displacementMap=a.displacementMap;this.displacementScale=a.displacementScale;this.displacementBias=a.displacementBias;this.roughnessMap=a.roughnessMap;this.metalnessMap=a.metalnessMap;this.alphaMap=a.alphaMap;this.envMap=a.envMap;this.envMapIntensity=a.envMapIntensity;this.refractionRatio=a.refractionRatio; this.wireframe=a.wireframe;this.wireframeLinewidth=a.wireframeLinewidth;this.wireframeLinecap=a.wireframeLinecap;this.wireframeLinejoin=a.wireframeLinejoin;this.skinning=a.skinning;this.morphTargets=a.morphTargets;this.morphNormals=a.morphNormals;return this};ub.prototype=Object.create(Oa.prototype);ub.prototype.constructor=ub;ub.prototype.isMeshPhysicalMaterial=!0;ub.prototype.copy=function(a){Oa.prototype.copy.call(this,a);this.defines={PHYSICAL:""};this.reflectivity=a.reflectivity;this.clearCoat= a.clearCoat;this.clearCoatRoughness=a.clearCoatRoughness;return this};Ka.prototype=Object.create(N.prototype);Ka.prototype.constructor=Ka;Ka.prototype.isMeshPhongMaterial=!0;Ka.prototype.copy=function(a){N.prototype.copy.call(this,a);this.color.copy(a.color);this.specular.copy(a.specular);this.shininess=a.shininess;this.map=a.map;this.lightMap=a.lightMap;this.lightMapIntensity=a.lightMapIntensity;this.aoMap=a.aoMap;this.aoMapIntensity=a.aoMapIntensity;this.emissive.copy(a.emissive);this.emissiveMap= @@ -643,17 +643,17 @@ a.wireframeLinewidth;this.wireframeLinecap=a.wireframeLinecap;this.wireframeLine !0;wb.prototype.copy=function(a){N.prototype.copy.call(this,a);this.bumpMap=a.bumpMap;this.bumpScale=a.bumpScale;this.normalMap=a.normalMap;this.normalScale.copy(a.normalScale);this.displacementMap=a.displacementMap;this.displacementScale=a.displacementScale;this.displacementBias=a.displacementBias;this.wireframe=a.wireframe;this.wireframeLinewidth=a.wireframeLinewidth;this.skinning=a.skinning;this.morphTargets=a.morphTargets;this.morphNormals=a.morphNormals;return this};xb.prototype=Object.create(N.prototype); xb.prototype.constructor=xb;xb.prototype.isMeshLambertMaterial=!0;xb.prototype.copy=function(a){N.prototype.copy.call(this,a);this.color.copy(a.color);this.map=a.map;this.lightMap=a.lightMap;this.lightMapIntensity=a.lightMapIntensity;this.aoMap=a.aoMap;this.aoMapIntensity=a.aoMapIntensity;this.emissive.copy(a.emissive);this.emissiveMap=a.emissiveMap;this.emissiveIntensity=a.emissiveIntensity;this.specularMap=a.specularMap;this.alphaMap=a.alphaMap;this.envMap=a.envMap;this.combine=a.combine;this.reflectivity= a.reflectivity;this.refractionRatio=a.refractionRatio;this.wireframe=a.wireframe;this.wireframeLinewidth=a.wireframeLinewidth;this.wireframeLinecap=a.wireframeLinecap;this.wireframeLinejoin=a.wireframeLinejoin;this.skinning=a.skinning;this.morphTargets=a.morphTargets;this.morphNormals=a.morphNormals;return this};yb.prototype=Object.create(W.prototype);yb.prototype.constructor=yb;yb.prototype.isLineDashedMaterial=!0;yb.prototype.copy=function(a){W.prototype.copy.call(this,a);this.scale=a.scale;this.dashSize= -a.dashSize;this.gapSize=a.gapSize;return this};var Lg=Object.freeze({ShadowMaterial:gc,SpriteMaterial:$a,RawShaderMaterial:hc,ShaderMaterial:pa,PointsMaterial:Da,MeshPhysicalMaterial:ub,MeshStandardMaterial:Oa,MeshPhongMaterial:Ka,MeshToonMaterial:vb,MeshNormalMaterial:wb,MeshLambertMaterial:xb,MeshDepthMaterial:Xa,MeshDistanceMaterial:Ya,MeshBasicMaterial:ya,LineDashedMaterial:yb,LineBasicMaterial:W,Material:N}),Hb={enabled:!1,files:{},add:function(a,b){!1!==this.enabled&&(this.files[a]=b)},get:function(a){if(!1!== -this.enabled)return this.files[a]},remove:function(a){delete this.files[a]},clear:function(){this.files={}}},ja=new he,Va={};Object.assign(La.prototype,{load:function(a,b,c,d){void 0===a&&(a="");void 0!==this.path&&(a=this.path+a);a=this.manager.resolveURL(a);var e=this,f=Hb.get(a);if(void 0!==f)return e.manager.itemStart(a),setTimeout(function(){b&&b(f);e.manager.itemEnd(a)},0),f;if(void 0!==Va[a])Va[a].push({onLoad:b,onProgress:c,onError:d});else{var g=a.match(/^data:(.*?)(;base64)?,(.*)$/);if(g){c= +a.dashSize;this.gapSize=a.gapSize;return this};var Lg=Object.freeze({ShadowMaterial:fc,SpriteMaterial:$a,RawShaderMaterial:gc,ShaderMaterial:pa,PointsMaterial:Da,MeshPhysicalMaterial:ub,MeshStandardMaterial:Oa,MeshPhongMaterial:Ka,MeshToonMaterial:vb,MeshNormalMaterial:wb,MeshLambertMaterial:xb,MeshDepthMaterial:Xa,MeshDistanceMaterial:Ya,MeshBasicMaterial:ya,LineDashedMaterial:yb,LineBasicMaterial:W,Material:N}),Gb={enabled:!1,files:{},add:function(a,b){!1!==this.enabled&&(this.files[a]=b)},get:function(a){if(!1!== +this.enabled)return this.files[a]},remove:function(a){delete this.files[a]},clear:function(){this.files={}}},ja=new he,Va={};Object.assign(La.prototype,{load:function(a,b,c,d){void 0===a&&(a="");void 0!==this.path&&(a=this.path+a);a=this.manager.resolveURL(a);var e=this,f=Gb.get(a);if(void 0!==f)return e.manager.itemStart(a),setTimeout(function(){b&&b(f);e.manager.itemEnd(a)},0),f;if(void 0!==Va[a])Va[a].push({onLoad:b,onProgress:c,onError:d});else{var g=a.match(/^data:(.*?)(;base64)?,(.*)$/);if(g){c= g[1];var h=!!g[2],g=g[3],g=window.decodeURIComponent(g);h&&(g=window.atob(g));try{var k=(this.responseType||"").toLowerCase();switch(k){case "arraybuffer":case "blob":for(var m=new Uint8Array(g.length),h=0;h=e)break a;else{f=b[1];a=e)break b}d=c;c=0}}for(;c>>1,ab;)--f;++f;if(0!==e||f!==d)e>=f&&(f=Math.max(f,1),e=f-1),a=this.getValueSize(),this.times=da.arraySlice(c,e,f),this.values=da.arraySlice(this.values,e*a,f*a);return this},validate:function(){var a=!0,b=this.getValueSize();0!==b-Math.floor(b)&&(console.error("THREE.KeyframeTrack: Invalid value size in track.",this),a=!1);var c=this.times,b=this.values, d=c.length;0===d&&(console.error("THREE.KeyframeTrack: Track is empty.",this),a=!1);for(var e=null,f=0;f!==d;f++){var g=c[f];if("number"===typeof g&&isNaN(g)){console.error("THREE.KeyframeTrack: Time is not a valid number.",this,f,g);a=!1;break}if(null!==e&&e>g){console.error("THREE.KeyframeTrack: Out of order keys.",this,f,g,e);a=!1;break}e=g}if(void 0!==b&&da.isTypedArray(b))for(f=0,c=b.length;f!==c;++f)if(d=b[f],isNaN(d)){console.error("THREE.KeyframeTrack: Value is not a valid number.",this,f, d);a=!1;break}return a},optimize:function(){for(var a,b,c=this.times,d=this.values,e=this.getValueSize(),f=2302===this.getInterpolation(),g=1,h=c.length-1,k=1;km.opacity&&(m.transparent=!0);d.setTextures(k);return d.parse(m)}}()});Object.assign(le.prototype,{load:function(a,b,c,d){var e=this,f=this.texturePath&&"string"===typeof this.texturePath?this.texturePath:Ab.prototype.extractUrlBase(a),g=new La(this.manager); -g.setWithCredentials(this.withCredentials);g.load(a,function(c){c=JSON.parse(c);var d=c.metadata;if(void 0!==d&&(d=d.type,void 0!==d)){if("object"===d.toLowerCase()){console.error("THREE.JSONLoader: "+a+" should be loaded with THREE.ObjectLoader instead.");return}if("scene"===d.toLowerCase()){console.error("THREE.JSONLoader: "+a+" should be loaded with THREE.SceneLoader instead.");return}}c=e.parse(c,f);b(c.geometry,c.materials)},c,d)},setTexturePath:function(a){this.texturePath=a},parse:function(){return function(a, -b){void 0!==a.data&&(a=a.data);a.scale=void 0!==a.scale?1/a.scale:1;var c=new L,d=a,e,f,g,h=d.faces;var k=d.vertices;var m=d.normals,l=d.colors;var n=d.scale;var u=0;if(void 0!==d.uvs){for(e=0;ef;f++){var A=h[r++];var B=x[2*A];A=x[2*A+1];B=new D(B,A);2!==f&&c.faceVertexUvs[e][v].push(B);0!==f&&c.faceVertexUvs[e][v+1].push(B)}}w&&(w=3*h[r++],t.normal.set(m[w++],m[w++],m[w]),y.normal.copy(t.normal));if(z)for(e=0;4>e;e++)w=3*h[r++],z=new p(m[w++],m[w++],m[w]),2!==e&&t.vertexNormals.push(z), -0!==e&&y.vertexNormals.push(z);n&&(n=h[r++],n=l[n],t.color.setHex(n),y.color.setHex(n));if(k)for(e=0;4>e;e++)n=h[r++],n=l[n],2!==e&&t.vertexColors.push(new F(n)),0!==e&&y.vertexColors.push(new F(n));c.faces.push(t);c.faces.push(y)}else{t=new Ra;t.a=h[r++];t.b=h[r++];t.c=h[r++];v&&(v=h[r++],t.materialIndex=v);v=c.faces.length;if(e)for(e=0;ef;f++)A=h[r++],B=x[2*A],A=x[2*A+1],B=new D(B,A),c.faceVertexUvs[e][v].push(B);w&&(w=3*h[r++],t.normal.set(m[w++], -m[w++],m[w]));if(z)for(e=0;3>e;e++)w=3*h[r++],z=new p(m[w++],m[w++],m[w]),t.vertexNormals.push(z);n&&(n=h[r++],t.color.setHex(l[n]));if(k)for(e=0;3>e;e++)n=h[r++],t.vertexColors.push(new F(l[n]));c.faces.push(t)}}d=a;r=void 0!==d.influencesPerVertex?d.influencesPerVertex:2;if(d.skinWeights)for(g=0,h=d.skinWeights.length;gg)e=a+1;else if(0b&&(b=0);1Number.EPSILON&&(g.normalize(),c=Math.acos(O.clamp(d[k-1].dot(d[k]),-1,1)),e[k].applyMatrix4(h.makeRotationAxis(g,c))),f[k].crossVectors(d[k],e[k]);if(!0===b)for(c=Math.acos(O.clamp(e[0].dot(e[a]),-1,1)),c/=a,0=b)return b=c[a]-b,a=this.curves[a],c=a.getLength(),a.getPointAt(0===c?0:1-b/c);a++}return null},getLength:function(){var a=this.getCurveLengths();return a[a.length-1]},updateArcLengths:function(){this.needsUpdate=!0;this.cacheLengths=null;this.getCurveLengths()},getCurveLengths:function(){if(this.cacheLengths&&this.cacheLengths.length===this.curves.length)return this.cacheLengths;for(var a=[],b=0,c=0,d=this.curves.length;cd;)d+=c;for(;d>c;)d-=c;dc.length-2?c.length-1:a+1],c=c[a>c.length-3?c.length-1:a+2];b.set(gf(d,e.x,f.x,g.x,c.x),gf(d,e.y,f.y,g.y,c.y));return b};bb.prototype.copy=function(a){P.prototype.copy.call(this,a);this.points=[];for(var b=0,c=a.points.length;bNumber.EPSILON){if(0>m&&(g=b[f],k=-k,h=b[e],m=-m),!(a.yh.y))if(a.y===g.y){if(a.x===g.x)return!0}else{e=m*(a.x-g.x)-k*(a.y-g.y);if(0===e)return!0;0>e||(d=!d)}}else if(a.y===g.y&&(h.x<=a.x&&a.x<=g.x||g.x<=a.x&&a.x<=h.x))return!0}return d}var e=Ta.isClockWise,f=this.subPaths;if(0===f.length)return[];if(!0===b)return c(f);b=[];if(1===f.length){var g=f[0];var h=new Cb;h.curves=g.curves; -b.push(h);return b}var k=!e(f[0].getPoints()),k=a?!k:k;h=[];var m=[],l=[],n=0;m[n]=void 0;l[n]=[];for(var p=0,r=f.length;pd&&this._mixBufferRegion(c,a,3*b,1-d,b);for(var d=b,f=b+b;d!==f;++d)if(c[d]!==c[d+b]){e.setValue(c,a);break}},saveOriginalState:function(){var a=this.buffer,b=this.valueSize,c=3*b;this.binding.getValue(a,c);for(var d=b;d!==c;++d)a[d]=a[c+d%b];this.cumulativeWeight=0},restoreOriginalState:function(){this.binding.setValue(this.buffer,3*this.valueSize)},_select:function(a,b,c,d,e){if(.5<=d)for(d=0;d!==e;++d)a[b+d]=a[c+d]},_slerp:function(a,b,c,d){ha.slerpFlat(a,b,a,b,a,c,d)},_lerp:function(a,b,c,d, -e){for(var f=1-d,g=0;g!==e;++g){var h=b+g;a[h]=a[h]*f+a[c+g]*d}}});Object.assign(kf.prototype,{getValue:function(a,b){this.bind();var c=this._bindings[this._targetGroup.nCachedObjects_];void 0!==c&&c.getValue(a,b)},setValue:function(a,b){for(var c=this._bindings,d=this._targetGroup.nCachedObjects_,e=c.length;d!==e;++d)c[d].setValue(a,b)},bind:function(){for(var a=this._bindings,b=this._targetGroup.nCachedObjects_,c=a.length;b!==c;++b)a[b].bind()},unbind:function(){for(var a=this._bindings,b=this._targetGroup.nCachedObjects_, -c=a.length;b!==c;++b)a[b].unbind()}});Object.assign(ga,{Composite:kf,create:function(a,b,c){return a&&a.isAnimationObjectGroup?new ga.Composite(a,b,c):new ga(a,b,c)},sanitizeNodeName:function(a){return a.replace(/\s/g,"_").replace(/[^\w-]/g,"")},parseTrackName:function(){var a=new RegExp("^"+/((?:[\w-]+[\/:])*)/.source+/([\w-\.]+)?/.source+/(?:\.([\w-]+)(?:\[(.+)\])?)?/.source+/\.([\w-]+)(?:\[(.+)\])?/.source+"$"),b=["material","materials","bones"];return function(c){var d=a.exec(c);if(!d)throw Error("PropertyBinding: Cannot parse trackName: "+ -c);var d={nodeName:d[2],objectName:d[3],objectIndex:d[4],propertyName:d[5],propertyIndex:d[6]},e=d.nodeName&&d.nodeName.lastIndexOf(".");if(void 0!==e&&-1!==e){var f=d.nodeName.substring(e+1);-1!==b.indexOf(f)&&(d.nodeName=d.nodeName.substring(0,e),d.objectName=f)}if(null===d.propertyName||0===d.propertyName.length)throw Error("PropertyBinding: can not parse propertyName from trackName: "+c);return d}}(),findNode:function(a,b){if(!b||""===b||"root"===b||"."===b||-1===b||b===a.name||b===a.uuid)return a; -if(a.skeleton){var c=function(a){for(var c=0;c=b){var l=b++,n=a[l];c[n.uuid]=m;a[m]=n;c[k]=l;a[l]=h;h=0;for(k=e;h!==k;++h){var n=d[h],p=n[m];n[m]=n[l];n[l]=p}}}this.nCachedObjects_=b},uncache:function(){for(var a,b,c=this._objects,d=c.length,e=this.nCachedObjects_,f=this._indicesByUUID,g=this._bindings,h=g.length,k=0,m=arguments.length;k!==m;++k){b=arguments[k].uuid;var l= -f[b];if(void 0!==l)if(delete f[b],lb||0===c)return;this._startTime=null;b*=c}b*=this._updateTimeScale(a);c=this._updateTime(b);a=this._updateWeight(a);if(0c.parameterPositions[1]&&(this.stopFading(),0===d&&(this.enabled=!1))}}return this._effectiveWeight=b},_updateTimeScale:function(a){var b=0;if(!this.paused){var b=this.timeScale,c=this._timeScaleInterpolant;if(null!==c){var d=c.evaluate(a)[0],b=b*d;a>c.parameterPositions[1]&&(this.stopWarping(),0===b?this.paused=!0:this.timeScale=b)}}return this._effectiveTimeScale=b},_updateTime:function(a){var b=this.time+a;if(0===a)return b;var c=this._clip.duration,d=this.loop,e=this._loopCount;if(2200=== -d)a:{if(-1===e&&(this._loopCount=0,this._setEndings(!0,!0,!1)),b>=c)b=c;else if(0>b)b=0;else break a;this.clampWhenFinished?this.paused=!0:this.enabled=!1;this._mixer.dispatchEvent({type:"finished",action:this,direction:0>a?-1:1})}else{d=2202===d;-1===e&&(0<=a?(e=0,this._setEndings(!0,0===this.repetitions,d)):this._setEndings(0===this.repetitions,!0,d));if(b>=c||0>b){var f=Math.floor(b/c),b=b-c*f,e=e+Math.abs(f),g=this.repetitions-e;0>g?(this.clampWhenFinished?this.paused=!0:this.enabled=!1,b=0a,this._setEndings(a,!a,d)):this._setEndings(!1,!1,d),this._loopCount=e,this._mixer.dispatchEvent({type:"loop",action:this,loopDelta:f}))}if(d&&1===(e&1))return this.time=b,c-b}return this.time=b},_setEndings:function(a,b,c){var d=this._interpolantSettings;c?(d.endingStart=2401,d.endingEnd=2401):(d.endingStart=a?this.zeroSlopeAtStart?2401:2400:2402,d.endingEnd=b?this.zeroSlopeAtEnd?2401:2400:2402)},_scheduleFading:function(a, -b,c){var d=this._mixer,e=d.time,f=this._weightInterpolant;null===f&&(this._weightInterpolant=f=d._lendControlInterpolant());d=f.parameterPositions;f=f.sampleValues;d[0]=e;f[0]=b;d[1]=e+a;f[1]=c;return this}});ve.prototype=Object.assign(Object.create(xa.prototype),{constructor:ve,_bindAction:function(a,b){var c=a._localRoot||this._root,d=a._clip.tracks,e=d.length,f=a._propertyBindings;a=a._interpolants;var g=c.uuid,h=this._bindingsByRootAndName,k=h[g];void 0===k&&(k={},h[g]=k);for(h=0;h!==e;++h){var l= -d[h],p=l.name,n=k[p];if(void 0===n){n=f[h];if(void 0!==n){null===n._cacheIndex&&(++n.referenceCount,this._addInactiveBinding(n,g,p));continue}n=new ue(ga.create(c,p,b&&b._propertyBindings[h].binding.parsedPath),l.ValueTypeName,l.getValueSize());++n.referenceCount;this._addInactiveBinding(n,g,p)}f[h]=n;a[h].resultBuffer=n.buffer}},_activateAction:function(a){if(!this._isActiveAction(a)){if(null===a._cacheIndex){var b=(a._localRoot||this._root).uuid,c=a._clip.uuid,d=this._actionsByClip[c];this._bindAction(a, -d&&d.knownActions[0]);this._addInactiveAction(a,c,b)}b=a._propertyBindings;c=0;for(d=b.length;c!==d;++c){var e=b[c];0===e.useCount++&&(this._lendBinding(e),e.saveOriginalState())}this._lendAction(a)}},_deactivateAction:function(a){if(this._isActiveAction(a)){for(var b=a._propertyBindings,c=0,d=b.length;c!==d;++c){var e=b[c];0===--e.useCount&&(e.restoreOriginalState(),this._takeBackBinding(e))}this._takeBackAction(a)}},_initMemoryManager:function(){this._actions=[];this._nActiveActions=0;this._actionsByClip= -{};this._bindings=[];this._nActiveBindings=0;this._bindingsByRootAndName={};this._controlInterpolants=[];this._nActiveControlInterpolants=0;var a=this;this.stats={actions:{get total(){return a._actions.length},get inUse(){return a._nActiveActions}},bindings:{get total(){return a._bindings.length},get inUse(){return a._nActiveBindings}},controlInterpolants:{get total(){return a._controlInterpolants.length},get inUse(){return a._nActiveControlInterpolants}}}},_isActiveAction:function(a){a=a._cacheIndex; -return null!==a&&aMath.abs(b)&&(b=1E-8);this.scale.set(.5*this.size,.5*this.size,b);this.lookAt(this.plane.normal); -x.prototype.updateMatrixWorld.call(this,a)};var Sd,Be;Eb.prototype=Object.create(x.prototype);Eb.prototype.constructor=Eb;Eb.prototype.setDirection=function(){var a=new p,b;return function(c){.99999c.y?this.quaternion.set(1,0,0,0):(a.set(c.z,0,-c.x).normalize(),b=Math.acos(c.y),this.quaternion.setFromAxisAngle(a,b))}}();Eb.prototype.setLength=function(a,b,c){void 0===b&&(b=.2*a);void 0===c&&(c=.2*b);this.line.scale.set(1,Math.max(0,a-b),1);this.line.updateMatrix(); -this.cone.scale.set(c,b,c);this.cone.position.y=a;this.cone.updateMatrix()};Eb.prototype.setColor=function(a){this.line.material.color.copy(a);this.cone.material.color.copy(a)};md.prototype=Object.create(X.prototype);md.prototype.constructor=md;var Ud=new p,Ee=new Ce,Fe=new Ce,Ge=new Ce;Aa.prototype=Object.create(P.prototype);Aa.prototype.constructor=Aa;Aa.prototype.isCatmullRomCurve3=!0;Aa.prototype.getPoint=function(a,b){b=b||new p;var c=this.points,d=c.length;a*=d-(this.closed?0:1);var e=Math.floor(a); -a-=e;this.closed?e+=0e&&(e=1);1E-4>d&&(d=e);1E-4>k&&(k=e);Ee.initNonuniformCatmullRom(f.x,g.x,h.x,c.x,d,e,k);Fe.initNonuniformCatmullRom(f.y,g.y,h.y,c.y,d,e,k);Ge.initNonuniformCatmullRom(f.z,g.z,h.z,c.z,d,e,k)}else"catmullrom"===this.curveType&&(Ee.initCatmullRom(f.x,g.x,h.x,c.x,this.tension),Fe.initCatmullRom(f.y,g.y,h.y,c.y,this.tension),Ge.initCatmullRom(f.z,g.z,h.z,c.z,this.tension));b.set(Ee.calc(a),Fe.calc(a),Ge.calc(a));return b};Aa.prototype.copy=function(a){P.prototype.copy.call(this,a);this.points= -[];for(var b=0,c=a.points.length;bm.opacity&&(m.transparent=!0);d.setTextures(k);return d.parse(m)}}()});var Ee={decodeText:function(a){if("undefined"!==typeof TextDecoder)return(new TextDecoder).decode(a);for(var b="",c=0,d=a.length;cf;f++){var A=h[r++]; +var B=x[2*A];A=x[2*A+1];B=new D(B,A);2!==f&&c.faceVertexUvs[e][v].push(B);0!==f&&c.faceVertexUvs[e][v+1].push(B)}}w&&(w=3*h[r++],t.normal.set(m[w++],m[w++],m[w]),y.normal.copy(t.normal));if(z)for(e=0;4>e;e++)w=3*h[r++],z=new p(m[w++],m[w++],m[w]),2!==e&&t.vertexNormals.push(z),0!==e&&y.vertexNormals.push(z);n&&(n=h[r++],n=l[n],t.color.setHex(n),y.color.setHex(n));if(k)for(e=0;4>e;e++)n=h[r++],n=l[n],2!==e&&t.vertexColors.push(new F(n)),0!==e&&y.vertexColors.push(new F(n));c.faces.push(t);c.faces.push(y)}else{t= +new Ra;t.a=h[r++];t.b=h[r++];t.c=h[r++];v&&(v=h[r++],t.materialIndex=v);v=c.faces.length;if(e)for(e=0;ef;f++)A=h[r++],B=x[2*A],A=x[2*A+1],B=new D(B,A),c.faceVertexUvs[e][v].push(B);w&&(w=3*h[r++],t.normal.set(m[w++],m[w++],m[w]));if(z)for(e=0;3>e;e++)w=3*h[r++],z=new p(m[w++],m[w++],m[w]),t.vertexNormals.push(z);n&&(n=h[r++],t.color.setHex(l[n]));if(k)for(e=0;3>e;e++)n=h[r++],t.vertexColors.push(new F(l[n]));c.faces.push(t)}}d=a;r=void 0!==d.influencesPerVertex? +d.influencesPerVertex:2;if(d.skinWeights)for(g=0,h=d.skinWeights.length;gg)e=a+1;else if(0b&&(b=0);1Number.EPSILON&&(g.normalize(),c=Math.acos(O.clamp(d[k-1].dot(d[k]),-1,1)),e[k].applyMatrix4(h.makeRotationAxis(g,c))),f[k].crossVectors(d[k],e[k]);if(!0===b)for(c=Math.acos(O.clamp(e[0].dot(e[a]),-1,1)),c/=a,0=b)return b=c[a]-b,a=this.curves[a],c=a.getLength(),a.getPointAt(0===c?0:1-b/c);a++}return null},getLength:function(){var a= +this.getCurveLengths();return a[a.length-1]},updateArcLengths:function(){this.needsUpdate=!0;this.cacheLengths=null;this.getCurveLengths()},getCurveLengths:function(){if(this.cacheLengths&&this.cacheLengths.length===this.curves.length)return this.cacheLengths;for(var a=[],b=0,c=0,d=this.curves.length;cd;)d+=c;for(;d>c;)d-=c;dc.length-2?c.length-1:a+1],c=c[a>c.length-3?c.length-1:a+2];b.set(hf(d,e.x,f.x,g.x,c.x),hf(d,e.y,f.y,g.y,c.y));return b};bb.prototype.copy=function(a){P.prototype.copy.call(this,a);this.points=[];for(var b=0,c=a.points.length;b +Number.EPSILON){if(0>m&&(g=b[f],k=-k,h=b[e],m=-m),!(a.yh.y))if(a.y===g.y){if(a.x===g.x)return!0}else{e=m*(a.x-g.x)-k*(a.y-g.y);if(0===e)return!0;0>e||(d=!d)}}else if(a.y===g.y&&(h.x<=a.x&&a.x<=g.x||g.x<=a.x&&a.x<=h.x))return!0}return d}var e=Ta.isClockWise,f=this.subPaths;if(0===f.length)return[];if(!0===b)return c(f);b=[];if(1===f.length){var g=f[0];var h=new Bb;h.curves=g.curves;b.push(h);return b}var k=!e(f[0].getPoints()),k=a?!k:k;h=[];var m=[],l=[],n=0;m[n]=void 0;l[n]=[];for(var p= +0,r=f.length;pd&&this._mixBufferRegion(c,a,3*b,1-d,b);for(var d=b,f=b+b;d!==f;++d)if(c[d]!==c[d+b]){e.setValue(c,a);break}},saveOriginalState:function(){var a=this.buffer,b=this.valueSize,c=3*b;this.binding.getValue(a,c);for(var d=b;d!==c;++d)a[d]=a[c+d%b];this.cumulativeWeight=0},restoreOriginalState:function(){this.binding.setValue(this.buffer,3*this.valueSize)},_select:function(a,b,c,d,e){if(.5<=d)for(d= +0;d!==e;++d)a[b+d]=a[c+d]},_slerp:function(a,b,c,d){ha.slerpFlat(a,b,a,b,a,c,d)},_lerp:function(a,b,c,d,e){for(var f=1-d,g=0;g!==e;++g){var h=b+g;a[h]=a[h]*f+a[c+g]*d}}});Object.assign(lf.prototype,{getValue:function(a,b){this.bind();var c=this._bindings[this._targetGroup.nCachedObjects_];void 0!==c&&c.getValue(a,b)},setValue:function(a,b){for(var c=this._bindings,d=this._targetGroup.nCachedObjects_,e=c.length;d!==e;++d)c[d].setValue(a,b)},bind:function(){for(var a=this._bindings,b=this._targetGroup.nCachedObjects_, +c=a.length;b!==c;++b)a[b].bind()},unbind:function(){for(var a=this._bindings,b=this._targetGroup.nCachedObjects_,c=a.length;b!==c;++b)a[b].unbind()}});Object.assign(ga,{Composite:lf,create:function(a,b,c){return a&&a.isAnimationObjectGroup?new ga.Composite(a,b,c):new ga(a,b,c)},sanitizeNodeName:function(a){return a.replace(/\s/g,"_").replace(/[^\w-]/g,"")},parseTrackName:function(){var a=new RegExp("^"+/((?:[\w-]+[\/:])*)/.source+/([\w-\.]+)?/.source+/(?:\.([\w-]+)(?:\[(.+)\])?)?/.source+/\.([\w-]+)(?:\[(.+)\])?/.source+ +"$"),b=["material","materials","bones"];return function(c){var d=a.exec(c);if(!d)throw Error("PropertyBinding: Cannot parse trackName: "+c);var d={nodeName:d[2],objectName:d[3],objectIndex:d[4],propertyName:d[5],propertyIndex:d[6]},e=d.nodeName&&d.nodeName.lastIndexOf(".");if(void 0!==e&&-1!==e){var f=d.nodeName.substring(e+1);-1!==b.indexOf(f)&&(d.nodeName=d.nodeName.substring(0,e),d.objectName=f)}if(null===d.propertyName||0===d.propertyName.length)throw Error("PropertyBinding: can not parse propertyName from trackName: "+ +c);return d}}(),findNode:function(a,b){if(!b||""===b||"root"===b||"."===b||-1===b||b===a.name||b===a.uuid)return a;if(a.skeleton){var c=function(a){for(var c=0;c=b){var l=b++,n=a[l];c[n.uuid]=m;a[m]=n;c[k]=l;a[l]=h;h=0;for(k=e;h!==k;++h){var n=d[h],p= +n[m];n[m]=n[l];n[l]=p}}}this.nCachedObjects_=b},uncache:function(){for(var a,b,c=this._objects,d=c.length,e=this.nCachedObjects_,f=this._indicesByUUID,g=this._bindings,h=g.length,k=0,m=arguments.length;k!==m;++k){b=arguments[k].uuid;var l=f[b];if(void 0!==l)if(delete f[b],lb||0===c)return;this._startTime=null;b*=c}b*=this._updateTimeScale(a);c=this._updateTime(b);a=this._updateWeight(a);if(0c.parameterPositions[1]&&(this.stopFading(),0===d&&(this.enabled=!1))}}return this._effectiveWeight=b},_updateTimeScale:function(a){var b=0;if(!this.paused){var b=this.timeScale,c=this._timeScaleInterpolant;if(null!==c){var d=c.evaluate(a)[0], +b=b*d;a>c.parameterPositions[1]&&(this.stopWarping(),0===b?this.paused=!0:this.timeScale=b)}}return this._effectiveTimeScale=b},_updateTime:function(a){var b=this.time+a;if(0===a)return b;var c=this._clip.duration,d=this.loop,e=this._loopCount;if(2200===d)a:{if(-1===e&&(this._loopCount=0,this._setEndings(!0,!0,!1)),b>=c)b=c;else if(0>b)b=0;else break a;this.clampWhenFinished?this.paused=!0:this.enabled=!1;this._mixer.dispatchEvent({type:"finished",action:this,direction:0>a?-1:1})}else{d=2202===d; +-1===e&&(0<=a?(e=0,this._setEndings(!0,0===this.repetitions,d)):this._setEndings(0===this.repetitions,!0,d));if(b>=c||0>b){var f=Math.floor(b/c),b=b-c*f,e=e+Math.abs(f),g=this.repetitions-e;0>g?(this.clampWhenFinished?this.paused=!0:this.enabled=!1,b=0a,this._setEndings(a,!a,d)):this._setEndings(!1,!1,d),this._loopCount=e,this._mixer.dispatchEvent({type:"loop",action:this,loopDelta:f}))}if(d&&1===(e&1))return this.time= +b,c-b}return this.time=b},_setEndings:function(a,b,c){var d=this._interpolantSettings;c?(d.endingStart=2401,d.endingEnd=2401):(d.endingStart=a?this.zeroSlopeAtStart?2401:2400:2402,d.endingEnd=b?this.zeroSlopeAtEnd?2401:2400:2402)},_scheduleFading:function(a,b,c){var d=this._mixer,e=d.time,f=this._weightInterpolant;null===f&&(this._weightInterpolant=f=d._lendControlInterpolant());d=f.parameterPositions;f=f.sampleValues;d[0]=e;f[0]=b;d[1]=e+a;f[1]=c;return this}});ve.prototype=Object.assign(Object.create(xa.prototype), +{constructor:ve,_bindAction:function(a,b){var c=a._localRoot||this._root,d=a._clip.tracks,e=d.length,f=a._propertyBindings;a=a._interpolants;var g=c.uuid,h=this._bindingsByRootAndName,k=h[g];void 0===k&&(k={},h[g]=k);for(h=0;h!==e;++h){var l=d[h],p=l.name,n=k[p];if(void 0===n){n=f[h];if(void 0!==n){null===n._cacheIndex&&(++n.referenceCount,this._addInactiveBinding(n,g,p));continue}n=new ue(ga.create(c,p,b&&b._propertyBindings[h].binding.parsedPath),l.ValueTypeName,l.getValueSize());++n.referenceCount; +this._addInactiveBinding(n,g,p)}f[h]=n;a[h].resultBuffer=n.buffer}},_activateAction:function(a){if(!this._isActiveAction(a)){if(null===a._cacheIndex){var b=(a._localRoot||this._root).uuid,c=a._clip.uuid,d=this._actionsByClip[c];this._bindAction(a,d&&d.knownActions[0]);this._addInactiveAction(a,c,b)}b=a._propertyBindings;c=0;for(d=b.length;c!==d;++c){var e=b[c];0===e.useCount++&&(this._lendBinding(e),e.saveOriginalState())}this._lendAction(a)}},_deactivateAction:function(a){if(this._isActiveAction(a)){for(var b= +a._propertyBindings,c=0,d=b.length;c!==d;++c){var e=b[c];0===--e.useCount&&(e.restoreOriginalState(),this._takeBackBinding(e))}this._takeBackAction(a)}},_initMemoryManager:function(){this._actions=[];this._nActiveActions=0;this._actionsByClip={};this._bindings=[];this._nActiveBindings=0;this._bindingsByRootAndName={};this._controlInterpolants=[];this._nActiveControlInterpolants=0;var a=this;this.stats={actions:{get total(){return a._actions.length},get inUse(){return a._nActiveActions}},bindings:{get total(){return a._bindings.length}, +get inUse(){return a._nActiveBindings}},controlInterpolants:{get total(){return a._controlInterpolants.length},get inUse(){return a._nActiveControlInterpolants}}}},_isActiveAction:function(a){a=a._cacheIndex;return null!==a&&aMath.abs(b)&&(b=1E-8);this.scale.set(.5*this.size,.5*this.size,b);this.lookAt(this.plane.normal);x.prototype.updateMatrixWorld.call(this,a)};var Sd,Be;Db.prototype=Object.create(x.prototype);Db.prototype.constructor=Db;Db.prototype.setDirection=function(){var a=new p,b;return function(c){.99999c.y?this.quaternion.set(1, +0,0,0):(a.set(c.z,0,-c.x).normalize(),b=Math.acos(c.y),this.quaternion.setFromAxisAngle(a,b))}}();Db.prototype.setLength=function(a,b,c){void 0===b&&(b=.2*a);void 0===c&&(c=.2*b);this.line.scale.set(1,Math.max(0,a-b),1);this.line.updateMatrix();this.cone.scale.set(c,b,c);this.cone.position.y=a;this.cone.updateMatrix()};Db.prototype.setColor=function(a){this.line.material.color.copy(a);this.cone.material.color.copy(a)};md.prototype=Object.create(X.prototype);md.prototype.constructor=md;var Ud=new p, +Fe=new Ce,Ge=new Ce,He=new Ce;Aa.prototype=Object.create(P.prototype);Aa.prototype.constructor=Aa;Aa.prototype.isCatmullRomCurve3=!0;Aa.prototype.getPoint=function(a,b){b=b||new p;var c=this.points,d=c.length;a*=d-(this.closed?0:1);var e=Math.floor(a);a-=e;this.closed?e+=0e&&(e=1);1E-4>d&&(d=e);1E-4>k&&(k=e);Fe.initNonuniformCatmullRom(f.x,g.x,h.x,c.x,d,e,k);Ge.initNonuniformCatmullRom(f.y,g.y,h.y,c.y,d,e,k);He.initNonuniformCatmullRom(f.z,g.z,h.z,c.z,d,e,k)}else"catmullrom"===this.curveType&&(Fe.initCatmullRom(f.x,g.x,h.x, +c.x,this.tension),Ge.initCatmullRom(f.y,g.y,h.y,c.y,this.tension),He.initCatmullRom(f.z,g.z,h.z,c.z,this.tension));b.set(Fe.calc(a),Ge.calc(a),He.calc(a));return b};Aa.prototype.copy=function(a){P.prototype.copy.call(this,a);this.points=[];for(var b=0,c=a.points.length;b