diff --git a/build/three.js b/build/three.js index 615e10399d809489baa052fa66b2193cd0c79e62..e05c4a8d828eff0f67acd00a58e9d65f4de3066c 100644 --- a/build/three.js +++ b/build/three.js @@ -97,90 +97,6 @@ } - /** - * https://github.com/mrdoob/eventdispatcher.js/ - */ - - function EventDispatcher() {} - - Object.assign( EventDispatcher.prototype, { - - addEventListener: function ( type, listener ) { - - if ( this._listeners === undefined ) { this._listeners = {}; } - - var listeners = this._listeners; - - if ( listeners[ type ] === undefined ) { - - listeners[ type ] = []; - - } - - if ( listeners[ type ].indexOf( listener ) === - 1 ) { - - listeners[ type ].push( listener ); - - } - - }, - - hasEventListener: function ( type, listener ) { - - if ( this._listeners === undefined ) { return false; } - - var listeners = this._listeners; - - return listeners[ type ] !== undefined && listeners[ type ].indexOf( listener ) !== - 1; - - }, - - removeEventListener: function ( type, listener ) { - - if ( this._listeners === undefined ) { return; } - - var listeners = this._listeners; - var listenerArray = listeners[ type ]; - - if ( listenerArray !== undefined ) { - - var index = listenerArray.indexOf( listener ); - - if ( index !== - 1 ) { - - listenerArray.splice( index, 1 ); - - } - - } - - }, - - dispatchEvent: function ( event ) { - - if ( this._listeners === undefined ) { return; } - - var listeners = this._listeners; - var listenerArray = listeners[ event.type ]; - - if ( listenerArray !== undefined ) { - - event.target = this; - - var array = listenerArray.slice( 0 ); - - for ( var i = 0, l = array.length; i < l; i ++ ) { - - array[ i ].call( this, event ); - - } - - } - - } - - } ); - var REVISION = '109dev'; var MOUSE = { LEFT: 0, MIDDLE: 1, RIGHT: 2, ROTATE: 0, DOLLY: 1, PAN: 2 }; var TOUCH = { ROTATE: 0, PAN: 1, DOLLY_PAN: 2, DOLLY_ROTATE: 3 }; @@ -350,6 +266,90 @@ var GreaterEqualStencilFunc = 518; var AlwaysStencilFunc = 519; + /** + * https://github.com/mrdoob/eventdispatcher.js/ + */ + + function EventDispatcher() {} + + Object.assign( EventDispatcher.prototype, { + + addEventListener: function ( type, listener ) { + + if ( this._listeners === undefined ) { this._listeners = {}; } + + var listeners = this._listeners; + + if ( listeners[ type ] === undefined ) { + + listeners[ type ] = []; + + } + + if ( listeners[ type ].indexOf( listener ) === - 1 ) { + + listeners[ type ].push( listener ); + + } + + }, + + hasEventListener: function ( type, listener ) { + + if ( this._listeners === undefined ) { return false; } + + var listeners = this._listeners; + + return listeners[ type ] !== undefined && listeners[ type ].indexOf( listener ) !== - 1; + + }, + + removeEventListener: function ( type, listener ) { + + if ( this._listeners === undefined ) { return; } + + var listeners = this._listeners; + var listenerArray = listeners[ type ]; + + if ( listenerArray !== undefined ) { + + var index = listenerArray.indexOf( listener ); + + if ( index !== - 1 ) { + + listenerArray.splice( index, 1 ); + + } + + } + + }, + + dispatchEvent: function ( event ) { + + if ( this._listeners === undefined ) { return; } + + var listeners = this._listeners; + var listenerArray = listeners[ event.type ]; + + if ( listenerArray !== undefined ) { + + event.target = this; + + var array = listenerArray.slice( 0 ); + + for ( var i = 0, l = array.length; i < l; i ++ ) { + + array[ i ].call( this, event ); + + } + + } + + } + + } ); + /** * @author alteredq / http://alteredqualia.com/ * @author mrdoob / http://mrdoob.com/ @@ -8458,6 +8458,7 @@ if ( this.roughness !== undefined ) { data.roughness = this.roughness; } if ( this.metalness !== undefined ) { data.metalness = this.metalness; } + if ( this.sheen && this.sheen.isColor ) { data.sheen = this.sheen.getHex(); } if ( this.emissive && this.emissive.isColor ) { data.emissive = this.emissive.getHex(); } if ( this.emissiveIntensity && this.emissiveIntensity !== 1 ) { data.emissiveIntensity = this.emissiveIntensity; } @@ -38202,6 +38203,7 @@ if ( json.color !== undefined ) { material.color.setHex( json.color ); } if ( json.roughness !== undefined ) { material.roughness = json.roughness; } if ( json.metalness !== undefined ) { material.metalness = json.metalness; } + if ( json.sheen !== undefined ) { material.sheen = new Color().setHex( json.sheen ); } if ( json.emissive !== undefined ) { material.emissive.setHex( json.emissive ); } if ( json.specular !== undefined ) { material.specular.setHex( json.specular ); } if ( json.shininess !== undefined ) { material.shininess = json.shininess; } @@ -48524,6 +48526,16 @@ } + if ( typeof __THREE_DEVTOOLS__ !== 'undefined' ) { + + /* eslint-disable no-undef */ + __THREE_DEVTOOLS__.dispatchEvent( new CustomEvent( 'register', { detail: { + revision: REVISION, + } } ) ); + /* eslint-enable no-undef */ + + } + exports.ACESFilmicToneMapping = ACESFilmicToneMapping; exports.AddEquation = AddEquation; exports.AddOperation = AddOperation; diff --git a/build/three.min.js b/build/three.min.js index 8670045697d446caa4b07a757bd12b8e41069d0c..4ed500316648c4b18342a8665081136896fed15e 100644 --- a/build/three.min.js +++ b/build/three.min.js @@ -1,3 +1,4 @@ +// threejs.org/license (function(k,za){"object"===typeof exports&&"undefined"!==typeof module?za(exports):"function"===typeof define&&define.amd?define(["exports"],za):(k=k||self,za(k.THREE={}))})(this,function(k){function za(){}function v(a,b){this.x=a||0;this.y=b||0}function sa(a,b,c,d){this._x=a||0;this._y=b||0;this._z=c||0;this._w=void 0!==d?d:1}function n(a,b,c){this.x=a||0;this.y=b||0;this.z=c||0}function S(){this.elements=[1,0,0,0,1,0,0,0,1];0h)return!1}return!0}function nb(a,b){this.center=void 0!==a?a:new n;this.radius=void 0!==b?b:0}function Rb(a,b){this.origin=void 0!==a?a:new n;this.direction=void 0!==b?b:new n}function ca(a,b,c){this.a=void 0!==a?a:new n;this.b=void 0!==b?b:new n;this.c=void 0!==c?c:new n}function I(a,b,c){return void 0===b&&void 0=== -c?this.set(a):this.setRGB(a,b,c)}function Rf(a,b,c){0>c&&(c+=1);1c?b:c<2/3?a+6*(b-a)*(2/3-c):a}function Sf(a){return.04045>a?.0773993808*a:Math.pow(.9478672986*a+.0521327014,2.4)}function Tf(a){return.0031308>a?12.92*a:1.055*Math.pow(a,.41666)-.055}function zc(a,b,c,d,e,f){this.a=a;this.b=b;this.c=c;this.normal=d&&d.isVector3?d:new n;this.vertexNormals=Array.isArray(d)?d:[];this.color=e&&e.isColor?e:new I;this.vertexColors=Array.isArray(e)?e:[];this.materialIndex= +a.length-3;g<=f;g+=3){Qb.fromArray(a,g);var h=e.x*Math.abs(Qb.x)+e.y*Math.abs(Qb.y)+e.z*Math.abs(Qb.z),l=b.dot(Qb),m=c.dot(Qb),p=d.dot(Qb);if(Math.max(-Math.max(l,m,p),Math.min(l,m,p))>h)return!1}return!0}function nb(a,b){this.center=void 0!==a?a:new n;this.radius=void 0!==b?b:0}function Rb(a,b){this.origin=void 0!==a?a:new n;this.direction=void 0!==b?b:new n}function ca(a,b,c){this.a=void 0!==a?a:new n;this.b=void 0!==b?b:new n;this.c=void 0!==c?c:new n}function G(a,b,c){return void 0===b&&void 0=== +c?this.set(a):this.setRGB(a,b,c)}function Rf(a,b,c){0>c&&(c+=1);1c?b:c<2/3?a+6*(b-a)*(2/3-c):a}function Sf(a){return.04045>a?.0773993808*a:Math.pow(.9478672986*a+.0521327014,2.4)}function Tf(a){return.0031308>a?12.92*a:1.055*Math.pow(a,.41666)-.055}function zc(a,b,c,d,e,f){this.a=a;this.b=b;this.c=c;this.normal=d&&d.isVector3?d:new n;this.vertexNormals=Array.isArray(d)?d:[];this.color=e&&e.isColor?e:new G;this.vertexColors=Array.isArray(e)?e:[];this.materialIndex= void 0!==f?f:0}function O(){Object.defineProperty(this,"id",{value:Mi++});this.uuid=N.generateUUID();this.name="";this.type="Material";this.lights=this.fog=!0;this.blending=1;this.side=0;this.vertexTangents=this.flatShading=!1;this.vertexColors=0;this.opacity=1;this.transparent=!1;this.blendSrc=204;this.blendDst=205;this.blendEquation=100;this.blendEquationAlpha=this.blendDstAlpha=this.blendSrcAlpha=null;this.depthFunc=3;this.depthWrite=this.depthTest=!0;this.stencilFunc=519;this.stencilRef=0;this.stencilMask= -255;this.stencilZPass=this.stencilZFail=this.stencilFail=7680;this.stencilWrite=!1;this.clippingPlanes=null;this.clipShadows=this.clipIntersection=!1;this.shadowSide=null;this.colorWrite=!0;this.precision=null;this.polygonOffset=!1;this.polygonOffsetUnits=this.polygonOffsetFactor=0;this.dithering=!1;this.alphaTest=0;this.premultipliedAlpha=!1;this.toneMapped=this.visible=!0;this.userData={};this.needsUpdate=!0}function Fa(a){O.call(this);this.type="MeshBasicMaterial";this.color=new I(16777215);this.lightMap= +255;this.stencilZPass=this.stencilZFail=this.stencilFail=7680;this.stencilWrite=!1;this.clippingPlanes=null;this.clipShadows=this.clipIntersection=!1;this.shadowSide=null;this.colorWrite=!0;this.precision=null;this.polygonOffset=!1;this.polygonOffsetUnits=this.polygonOffsetFactor=0;this.dithering=!1;this.alphaTest=0;this.premultipliedAlpha=!1;this.toneMapped=this.visible=!0;this.userData={};this.needsUpdate=!0}function Fa(a){O.call(this);this.type="MeshBasicMaterial";this.color=new G(16777215);this.lightMap= this.map=null;this.lightMapIntensity=1;this.aoMap=null;this.aoMapIntensity=1;this.envMap=this.alphaMap=this.specularMap=null;this.combine=0;this.reflectivity=1;this.refractionRatio=.98;this.wireframe=!1;this.wireframeLinewidth=1;this.wireframeLinejoin=this.wireframeLinecap="round";this.lights=this.morphTargets=this.skinning=!1;this.setValues(a)}function L(a,b,c){if(Array.isArray(a))throw new TypeError("THREE.BufferAttribute: array should be a Typed Array.");this.name="";this.array=a;this.itemSize= b;this.count=void 0!==a?a.length/b:0;this.normalized=!0===c;this.dynamic=!1;this.updateRange={offset:0,count:-1};this.version=0}function xd(a,b,c){L.call(this,new Int8Array(a),b,c)}function yd(a,b,c){L.call(this,new Uint8Array(a),b,c)}function zd(a,b,c){L.call(this,new Uint8ClampedArray(a),b,c)}function Ad(a,b,c){L.call(this,new Int16Array(a),b,c)}function Sb(a,b,c){L.call(this,new Uint16Array(a),b,c)}function Bd(a,b,c){L.call(this,new Int32Array(a),b,c)}function Tb(a,b,c){L.call(this,new Uint32Array(a), b,c)}function B(a,b,c){L.call(this,new Float32Array(a),b,c)}function Cd(a,b,c){L.call(this,new Float64Array(a),b,c)}function eh(){this.vertices=[];this.normals=[];this.colors=[];this.uvs=[];this.uvs2=[];this.groups=[];this.morphTargets={};this.skinWeights=[];this.skinIndices=[];this.boundingSphere=this.boundingBox=null;this.groupsNeedUpdate=this.uvsNeedUpdate=this.colorsNeedUpdate=this.normalsNeedUpdate=this.verticesNeedUpdate=!1}function fh(a){if(0===a.length)return-Infinity;for(var b=a[0],c=1,d= @@ -27,7 +28,7 @@ c&&null!==d&&(b.requestAnimationFrame(a),c=!0)},stop:function(){c=!1},setAnimati Uint32Array?c=5125:d instanceof Int32Array?c=5124:d instanceof Int8Array?c=5120:d instanceof Uint8Array&&(c=5121);return{buffer:h,type:c,bytesPerElement:d.BYTES_PER_ELEMENT,version:b.version}}var c=new WeakMap;return{get:function(a){a.isInterleavedBufferAttribute&&(a=a.data);return c.get(a)},remove:function(b){b.isInterleavedBufferAttribute&&(b=b.data);var d=c.get(b);d&&(a.deleteBuffer(d.buffer),c.delete(b))},update:function(d,e){d.isInterleavedBufferAttribute&&(d=d.data);var f=c.get(d);if(void 0=== f)c.set(d,b(d,e));else if(f.versionc;c++)b.probe.push(new n);var d=new n,e=new W,f=new W;return{setup:function(c,h,l){for(var g=0,p=0,u=0,k=0;9>k;k++)b.probe[k].set(0,0,0);var r=h=0,t=0,z=0,n=0,y=0,x=0,U=0;l=l.matrixWorldInverse;c.sort(Tj);k=0;for(var R=c.length;kCa;Ca++)b.probe[Ca].addScaledVector(E.sh.coefficients[Ca],v);else if(E.isDirectionalLight){var H=a.get(E);H.color.copy(E.color).multiplyScalar(E.intensity);H.direction.setFromMatrixPosition(E.matrixWorld);d.setFromMatrixPosition(E.target.matrixWorld);H.direction.sub(d);H.direction.transformDirection(l);if(H.shadow=E.castShadow)v=E.shadow,H.shadowBias=v.bias,H.shadowRadius=v.radius,H.shadowMapSize=v.mapSize,b.directionalShadowMap[h]=Ca,b.directionalShadowMatrix[h]= E.shadow.matrix,y++;b.directional[h]=H;h++}else if(E.isSpotLight){H=a.get(E);H.position.setFromMatrixPosition(E.matrixWorld);H.position.applyMatrix4(l);H.color.copy(Cb).multiplyScalar(v);H.distance=B;H.direction.setFromMatrixPosition(E.matrixWorld);d.setFromMatrixPosition(E.target.matrixWorld);H.direction.sub(d);H.direction.transformDirection(l);H.coneCos=Math.cos(E.angle);H.penumbraCos=Math.cos(E.angle*(1-E.penumbra));H.decay=E.decay;if(H.shadow=E.castShadow)v=E.shadow,H.shadowBias=v.bias,H.shadowRadius= @@ -110,11 +111,11 @@ g.x=h.x*X.x,T.mapSize.x=h.x),g.y>c&&(h.y=Math.floor(c/X.y),g.y=h.y*X.y,T.mapSize X=T.getViewportCount();for(var U=0;U=e.maxTextures&&console.warn("THREE.WebGLTextures: Trying to use "+a+" texture units while this GPU supports only "+e.maxTextures);G+=1;return a};this.resetTextureUnits=function(){G=0};this.setTexture2D=w;this.setTexture2DArray= +null)}function A(a){return e.isWebGL2&&a.isWebGLMultisampleRenderTarget?Math.min(e.maxSamples,a.samples):0}var Ca=new WeakMap,H,D="undefined"!==typeof OffscreenCanvas&&null!==(new OffscreenCanvas(1,1)).getContext("2d"),I=0,G=!1,C=!1;this.allocateTextureUnit=function(){var a=I;a>=e.maxTextures&&console.warn("THREE.WebGLTextures: Trying to use "+a+" texture units while this GPU supports only "+e.maxTextures);I+=1;return a};this.resetTextureUnits=function(){I=0};this.setTexture2D=w;this.setTexture2DArray= function(a,b){var e=d.get(a);0r;r++)h.__webglFramebuffer[r]=a.createFramebuffer();else if(h.__webglFramebuffer=a.createFramebuffer(),r)if(e.isWebGL2){h.__webglMultisampledFramebuffer=a.createFramebuffer();h.__webglColorRenderbuffer=a.createRenderbuffer();a.bindRenderbuffer(36161,h.__webglColorRenderbuffer);r=f.convert(b.texture.format);var z=f.convert(b.texture.type);r=k(r,z);z=A(b);a.renderbufferStorageMultisample(36161, z,r,b.width,b.height);a.bindFramebuffer(36160,h.__webglMultisampledFramebuffer);a.framebufferRenderbuffer(36160,36064,36161,h.__webglColorRenderbuffer);a.bindRenderbuffer(36161,null);b.depthBuffer&&(h.__webglDepthRenderbuffer=a.createRenderbuffer(),B(h.__webglDepthRenderbuffer,b,!0));a.bindFramebuffer(36160,null)}else console.warn("THREE.WebGLRenderer: WebGLMultisampleRenderTarget can only be used with WebGL2.");if(q){c.bindTexture(34067,l.__webglTexture);U(34067,b.texture,t);for(r=0;6>r;r++)v(h.__webglFramebuffer[r], @@ -145,7 +146,7 @@ b,36064,34069+r);p(b.texture,t)&&u(34067,b.texture,b.width,b.height);c.bindTextu a.bindFramebuffer(36160,h.__webglFramebuffer);if(!b.depthTexture||!b.depthTexture.isDepthTexture)throw Error("renderTarget.depthTexture must be an instance of THREE.DepthTexture");d.get(b.depthTexture).__webglTexture&&b.depthTexture.image.width===b.width&&b.depthTexture.image.height===b.height||(b.depthTexture.image.width=b.width,b.depthTexture.image.height=b.height,b.depthTexture.needsUpdate=!0);w(b.depthTexture,0);h=d.get(b.depthTexture).__webglTexture;if(1026===b.depthTexture.format)a.framebufferTexture2D(36160, 36096,3553,h,0);else if(1027===b.depthTexture.format)a.framebufferTexture2D(36160,33306,3553,h,0);else throw Error("Unknown depthTexture format");}else if(l)for(h.__webglDepthbuffer=[],l=0;6>l;l++)a.bindFramebuffer(36160,h.__webglFramebuffer[l]),h.__webglDepthbuffer[l]=a.createRenderbuffer(),B(h.__webglDepthbuffer[l],b);else a.bindFramebuffer(36160,h.__webglFramebuffer),h.__webglDepthbuffer=a.createRenderbuffer(),B(h.__webglDepthbuffer,b);a.bindFramebuffer(36160,null)}};this.updateRenderTargetMipmap= function(a){var b=a.texture,f=m(a)||e.isWebGL2;if(p(b,f)){f=a.isWebGLRenderTargetCube?34067:3553;var g=d.get(b).__webglTexture;c.bindTexture(f,g);u(f,b,a.width,a.height);c.bindTexture(f,null)}};this.updateMultisampleRenderTarget=function(b){if(b.isWebGLMultisampleRenderTarget)if(e.isWebGL2){var c=d.get(b);a.bindFramebuffer(36008,c.__webglMultisampledFramebuffer);a.bindFramebuffer(36009,c.__webglFramebuffer);c=b.width;var f=b.height,g=16384;b.depthBuffer&&(g|=256);b.stencilBuffer&&(g|=1024);a.blitFramebuffer(0, -0,c,f,0,0,c,f,g,9728)}else console.warn("THREE.WebGLRenderer: WebGLMultisampleRenderTarget can only be used with WebGL2.")};this.safeSetTexture2D=function(a,b){a&&a.isWebGLRenderTarget&&(!1===I&&(console.warn("THREE.WebGLTextures.safeSetTexture2D: don't use render targets as textures. Use their .texture property instead."),I=!0),a=a.texture);w(a,b)};this.safeSetTextureCube=function(a,b){a&&a.isWebGLRenderTargetCube&&(!1===C&&(console.warn("THREE.WebGLTextures.safeSetTextureCube: don't use cube render targets as textures. Use their .texture property instead."), +0,c,f,0,0,c,f,g,9728)}else console.warn("THREE.WebGLRenderer: WebGLMultisampleRenderTarget can only be used with WebGL2.")};this.safeSetTexture2D=function(a,b){a&&a.isWebGLRenderTarget&&(!1===G&&(console.warn("THREE.WebGLTextures.safeSetTexture2D: don't use render targets as textures. Use their .texture property instead."),G=!0),a=a.texture);w(a,b)};this.safeSetTextureCube=function(a,b){a&&a.isWebGLRenderTargetCube&&(!1===C&&(console.warn("THREE.WebGLTextures.safeSetTextureCube: don't use cube render targets as textures. Use their .texture property instead."), C=!0),a=a.texture);a&&a.isCubeTexture||Array.isArray(a.image)&&6===a.image.length?y(a,b):x(a,b)}}function Dh(a,b,c){return{convert:function(a){if(1E3===a)return 10497;if(1001===a)return 33071;if(1002===a)return 33648;if(1003===a)return 9728;if(1004===a)return 9984;if(1005===a)return 9986;if(1006===a)return 9729;if(1007===a)return 9985;if(1008===a)return 9987;if(1009===a)return 5121;if(1017===a)return 32819;if(1018===a)return 32820;if(1019===a)return 33635;if(1010===a)return 5120;if(1011===a)return 5122; if(1012===a)return 5123;if(1013===a)return 5124;if(1014===a)return 5125;if(1015===a)return 5126;if(1016===a){if(c.isWebGL2)return 5131;var d=b.get("OES_texture_half_float");if(null!==d)return d.HALF_FLOAT_OES}if(1021===a)return 6406;if(1022===a)return 6407;if(1023===a)return 6408;if(1024===a)return 6409;if(1025===a)return 6410;if(1026===a)return 6402;if(1027===a)return 34041;if(1028===a)return 6403;if(100===a)return 32774;if(101===a)return 32778;if(102===a)return 32779;if(200===a)return 0;if(201=== a)return 1;if(202===a)return 768;if(203===a)return 769;if(204===a)return 770;if(205===a)return 771;if(206===a)return 772;if(207===a)return 773;if(208===a)return 774;if(209===a)return 775;if(210===a)return 776;if(33776===a||33777===a||33778===a||33779===a)if(d=b.get("WEBGL_compressed_texture_s3tc"),null!==d){if(33776===a)return d.COMPRESSED_RGB_S3TC_DXT1_EXT;if(33777===a)return d.COMPRESSED_RGBA_S3TC_DXT1_EXT;if(33778===a)return d.COMPRESSED_RGBA_S3TC_DXT3_EXT;if(33779===a)return d.COMPRESSED_RGBA_S3TC_DXT5_EXT}if(35840=== @@ -184,15 +185,15 @@ c.sheen&&p.sheen.value.copy(c.sheen),c.clearcoatNormalMap&&(p.clearcoatNormalSca 1===c.side&&p.normalScale.value.negate()),c.displacementMap&&(p.displacementMap.value=c.displacementMap,p.displacementScale.value=c.displacementScale,p.displacementBias.value=c.displacementBias)):c.isMeshDepthMaterial?(r(p,c),c.displacementMap&&(p.displacementMap.value=c.displacementMap,p.displacementScale.value=c.displacementScale,p.displacementBias.value=c.displacementBias)):c.isMeshDistanceMaterial?(r(p,c),c.displacementMap&&(p.displacementMap.value=c.displacementMap,p.displacementScale.value= c.displacementScale,p.displacementBias.value=c.displacementBias),p.referencePosition.value.copy(c.referencePosition),p.nearDistance.value=c.nearDistance,p.farDistance.value=c.farDistance):c.isMeshNormalMaterial?(r(p,c),c.bumpMap&&(p.bumpMap.value=c.bumpMap,p.bumpScale.value=c.bumpScale,1===c.side&&(p.bumpScale.value*=-1)),c.normalMap&&(p.normalMap.value=c.normalMap,p.normalScale.value.copy(c.normalScale),1===c.side&&p.normalScale.value.negate()),c.displacementMap&&(p.displacementMap.value=c.displacementMap, p.displacementScale.value=c.displacementScale,p.displacementBias.value=c.displacementBias)):c.isLineBasicMaterial?(p.diffuse.value.copy(c.color),p.opacity.value=c.opacity,c.isLineDashedMaterial&&(p.dashSize.value=c.dashSize,p.totalSize.value=c.dashSize+c.gapSize,p.scale.value=c.scale)):c.isPointsMaterial?(p.diffuse.value.copy(c.color),p.opacity.value=c.opacity,p.size.value=c.size*ea,p.scale.value=.5*Y,p.map.value=c.map,null!==c.map&&(!0===c.map.matrixAutoUpdate&&c.map.updateMatrix(),p.uvTransform.value.copy(c.map.matrix))): -c.isSpriteMaterial?(p.diffuse.value.copy(c.color),p.opacity.value=c.opacity,p.rotation.value=c.rotation,p.map.value=c.map,null!==c.map&&(!0===c.map.matrixAutoUpdate&&c.map.updateMatrix(),p.uvTransform.value.copy(c.map.matrix))):c.isShadowMaterial&&(p.color.value.copy(c.color),p.opacity.value=c.opacity),void 0!==p.ltc_1&&(p.ltc_1.value=G.LTC_1),void 0!==p.ltc_2&&(p.ltc_2.value=G.LTC_2),Bb.upload(K,e.uniformsList,p,ca));c.isShaderMaterial&&!0===c.uniformsNeedUpdate&&(Bb.upload(K,e.uniformsList,p,ca), +c.isSpriteMaterial?(p.diffuse.value.copy(c.color),p.opacity.value=c.opacity,p.rotation.value=c.rotation,p.map.value=c.map,null!==c.map&&(!0===c.map.matrixAutoUpdate&&c.map.updateMatrix(),p.uvTransform.value.copy(c.map.matrix))):c.isShadowMaterial&&(p.color.value.copy(c.color),p.opacity.value=c.opacity),void 0!==p.ltc_1&&(p.ltc_1.value=I.LTC_1),void 0!==p.ltc_2&&(p.ltc_2.value=I.LTC_2),Bb.upload(K,e.uniformsList,p,ca));c.isShaderMaterial&&!0===c.uniformsNeedUpdate&&(Bb.upload(K,e.uniformsList,p,ca), c.uniformsNeedUpdate=!1);c.isSpriteMaterial&&m.setValue(K,"center",d.center);m.setValue(K,"modelViewMatrix",d.modelViewMatrix);m.setValue(K,"normalMatrix",d.normalMatrix);m.setValue(K,"modelMatrix",d.matrixWorld);return f}function r(a,b){a.opacity.value=b.opacity;b.color&&a.diffuse.value.copy(b.color);b.emissive&&a.emissive.value.copy(b.emissive).multiplyScalar(b.emissiveIntensity);b.map&&(a.map.value=b.map);b.alphaMap&&(a.alphaMap.value=b.alphaMap);b.specularMap&&(a.specularMap.value=b.specularMap); b.envMap&&(a.envMap.value=b.envMap,a.flipEnvMap.value=b.envMap.isCubeTexture?-1:1,a.reflectivity.value=b.reflectivity,a.refractionRatio.value=b.refractionRatio,a.maxMipLevel.value=S.get(b.envMap).__maxMipLevel);b.lightMap&&(a.lightMap.value=b.lightMap,a.lightMapIntensity.value=b.lightMapIntensity);b.aoMap&&(a.aoMap.value=b.aoMap,a.aoMapIntensity.value=b.aoMapIntensity);if(b.map)var c=b.map;else b.specularMap?c=b.specularMap:b.displacementMap?c=b.displacementMap:b.normalMap?c=b.normalMap:b.bumpMap? c=b.bumpMap:b.roughnessMap?c=b.roughnessMap:b.metalnessMap?c=b.metalnessMap:b.alphaMap?c=b.alphaMap:b.emissiveMap&&(c=b.emissiveMap);void 0!==c&&(c.isWebGLRenderTarget&&(c=c.texture),!0===c.matrixAutoUpdate&&c.updateMatrix(),a.uvTransform.value.copy(c.matrix))}function t(a,b){a.specular.value.copy(b.specular);a.shininess.value=Math.max(b.shininess,1E-4);b.emissiveMap&&(a.emissiveMap.value=b.emissiveMap);b.bumpMap&&(a.bumpMap.value=b.bumpMap,a.bumpScale.value=b.bumpScale,1===b.side&&(a.bumpScale.value*= -1));b.normalMap&&(a.normalMap.value=b.normalMap,a.normalScale.value.copy(b.normalScale),1===b.side&&a.normalScale.value.negate());b.displacementMap&&(a.displacementMap.value=b.displacementMap,a.displacementScale.value=b.displacementScale,a.displacementBias.value=b.displacementBias)}function z(a,b){a.roughness.value=b.roughness;a.metalness.value=b.metalness;b.roughnessMap&&(a.roughnessMap.value=b.roughnessMap);b.metalnessMap&&(a.metalnessMap.value=b.metalnessMap);b.emissiveMap&&(a.emissiveMap.value= b.emissiveMap);b.bumpMap&&(a.bumpMap.value=b.bumpMap,a.bumpScale.value=b.bumpScale,1===b.side&&(a.bumpScale.value*=-1));b.normalMap&&(a.normalMap.value=b.normalMap,a.normalScale.value.copy(b.normalScale),1===b.side&&a.normalScale.value.negate());b.displacementMap&&(a.displacementMap.value=b.displacementMap,a.displacementScale.value=b.displacementScale,a.displacementBias.value=b.displacementBias);b.envMap&&(a.envMapIntensity.value=b.envMapIntensity)}a=a||{};var w=void 0!==a.canvas?a.canvas:document.createElementNS("http://www.w3.org/1999/xhtml", -"canvas"),y=void 0!==a.context?a.context:null,x=void 0!==a.alpha?a.alpha:!1,U=void 0!==a.depth?a.depth:!0,R=void 0!==a.stencil?a.stencil:!0,E=void 0!==a.antialias?a.antialias:!1,B=void 0!==a.premultipliedAlpha?a.premultipliedAlpha:!0,A=void 0!==a.preserveDrawingBuffer?a.preserveDrawingBuffer:!1,D=void 0!==a.powerPreference?a.powerPreference:"default",I=void 0!==a.failIfMajorPerformanceCaveat?a.failIfMajorPerformanceCaveat:!1,H=null,C=null;this.domElement=w;this.debug={checkShaderErrors:!0};this.sortObjects= +"canvas"),y=void 0!==a.context?a.context:null,x=void 0!==a.alpha?a.alpha:!1,U=void 0!==a.depth?a.depth:!0,R=void 0!==a.stencil?a.stencil:!0,E=void 0!==a.antialias?a.antialias:!1,B=void 0!==a.premultipliedAlpha?a.premultipliedAlpha:!0,A=void 0!==a.preserveDrawingBuffer?a.preserveDrawingBuffer:!1,D=void 0!==a.powerPreference?a.powerPreference:"default",G=void 0!==a.failIfMajorPerformanceCaveat?a.failIfMajorPerformanceCaveat:!1,H=null,C=null;this.domElement=w;this.debug={checkShaderErrors:!0};this.sortObjects= this.autoClearStencil=this.autoClearDepth=this.autoClearColor=this.autoClear=!0;this.clippingPlanes=[];this.localClippingEnabled=!1;this.gammaFactor=2;this.physicallyCorrectLights=this.gammaOutput=this.gammaInput=!1;this.toneMappingWhitePoint=this.toneMappingExposure=this.toneMapping=1;this.maxMorphTargets=8;this.maxMorphNormals=4;var F=this,O=!1,L=null,T=0,X=0,M=null,$b=null,fa=-1;var ac=b=null;var Z=!1;var P=null,Pa=null,V=new da,aa=new da,ba=null,J=w.width,Y=w.height,ea=1,Q=new da(0,0,J,Y),ja= -new da(0,0,J,Y),na=!1,bg=new Ed,Oa=new Ti,He=!1,ra=!1,Id=new W,Fb=new n;try{x={alpha:x,depth:U,stencil:R,antialias:E,premultipliedAlpha:B,preserveDrawingBuffer:A,powerPreference:D,failIfMajorPerformanceCaveat:I,xrCompatible:!0};w.addEventListener("webglcontextlost",d,!1);w.addEventListener("webglcontextrestored",e,!1);var K=y||w.getContext("webgl",x)||w.getContext("experimental-webgl",x);if(null===K){if(null!==w.getContext("webgl"))throw Error("Error creating WebGL context with your selected attributes."); +new da(0,0,J,Y),na=!1,bg=new Ed,Oa=new Ti,He=!1,ra=!1,Id=new W,Fb=new n;try{x={alpha:x,depth:U,stencil:R,antialias:E,premultipliedAlpha:B,preserveDrawingBuffer:A,powerPreference:D,failIfMajorPerformanceCaveat:G,xrCompatible:!0};w.addEventListener("webglcontextlost",d,!1);w.addEventListener("webglcontextrestored",e,!1);var K=y||w.getContext("webgl",x)||w.getContext("experimental-webgl",x);if(null===K){if(null!==w.getContext("webgl"))throw Error("Error creating WebGL context with your selected attributes."); throw Error("Error creating WebGL context.");}void 0===K.getShaderPrecisionFormat&&(K.getShaderPrecisionFormat=function(){return{rangeMin:1,rangeMax:1,precision:1}})}catch(Ih){throw console.error("THREE.WebGLRenderer: "+Ih.message),Ih;}var pa,Da,ha,ia,S,ca,ta,va,qa,ma,ua,sa,la,wa,ya,za,ka;c();var oa="undefined"!==typeof navigator&&"xr"in navigator&&"supportsSession"in navigator.xr?new Hh(F,K):new cg(F);this.vr=oa;var Ba=new Ch(F,qa,Da.maxTextureSize);this.shadowMap=Ba;this.getContext=function(){return K}; this.getContextAttributes=function(){return K.getContextAttributes()};this.forceContextLoss=function(){var a=pa.get("WEBGL_lose_context");a&&a.loseContext()};this.forceContextRestore=function(){var a=pa.get("WEBGL_lose_context");a&&a.restoreContext()};this.getPixelRatio=function(){return ea};this.setPixelRatio=function(a){void 0!==a&&(ea=a,this.setSize(J,Y,!1))};this.getSize=function(a){void 0===a&&(console.warn("WebGLRenderer: .getsize() now requires a Vector2 as an argument"),a=new v);return a.set(J, Y)};this.setSize=function(a,b,c){oa.isPresenting()?console.warn("THREE.WebGLRenderer: Can't change size while VR device is presenting."):(J=a,Y=b,w.width=Math.floor(a*ea),w.height=Math.floor(b*ea),!1!==c&&(w.style.width=a+"px",w.style.height=b+"px"),this.setViewport(0,0,a,b))};this.getDrawingBufferSize=function(a){void 0===a&&(console.warn("WebGLRenderer: .getdrawingBufferSize() now requires a Vector2 as an argument"),a=new v);return a.set(J*ea,Y*ea).floor()};this.setDrawingBufferSize=function(a, @@ -214,12 +215,12 @@ C=H=null):console.error("THREE.WebGLRenderer.render: camera is not an instance o a.isWebGLRenderTargetCube&&void 0!==g&&(h=h[g]);if(h){g=!1;h!==$b&&(K.bindFramebuffer(36160,h),g=!0);try{var l=a.texture,m=l.format,p=l.type;1023!==m&&ka.convert(m)!==K.getParameter(35739)?console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in RGBA or implementation defined format."):1009===p||ka.convert(p)===K.getParameter(35738)||1015===p&&(Da.isWebGL2||pa.get("OES_texture_float")||pa.get("WEBGL_color_buffer_float"))||1016===p&&(Da.isWebGL2?pa.get("EXT_color_buffer_float"): pa.get("EXT_color_buffer_half_float"))?36053===K.checkFramebufferStatus(36160)?0<=b&&b<=a.width-d&&0<=c&&c<=a.height-e&&K.readPixels(b,c,d,e,ka.convert(m),ka.convert(p),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{g&&K.bindFramebuffer(36160,$b)}}}else console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not THREE.WebGLRenderTarget.")}; this.copyFramebufferToTexture=function(a,b,c){var d=b.image.width,e=b.image.height,f=ka.convert(b.format);ca.setTexture2D(b,0);K.copyTexImage2D(3553,c||0,f,a.x,a.y,d,e,0)};this.copyTextureToTexture=function(a,b,c,d){var e=b.image.width,f=b.image.height,g=ka.convert(c.format),h=ka.convert(c.type);ca.setTexture2D(c,0);b.isDataTexture?K.texSubImage2D(3553,d||0,a.x,a.y,e,f,g,h,b.image.data):K.texSubImage2D(3553,d||0,a.x,a.y,g,h,b.image)};"undefined"!==typeof __THREE_DEVTOOLS__&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe", -{detail:this}))}function Ie(a,b){this.name="";this.color=new I(a);this.density=void 0!==b?b:2.5E-4}function Je(a,b,c){this.name="";this.color=new I(a);this.near=void 0!==b?b:1;this.far=void 0!==c?c:1E3}function bc(a,b){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.version=0}function Kd(a,b,c,d){this.data=a;this.itemSize=b;this.offset=c;this.normalized=!0===d}function Gb(a){O.call(this);this.type="SpriteMaterial";this.color= -new I(16777215);this.map=null;this.rotation=0;this.sizeAttenuation=!0;this.lights=!1;this.transparent=!0;this.setValues(a)}function Ld(a){A.call(this);this.type="Sprite";if(void 0===Ic){Ic=new D;var b=new Float32Array([-.5,-.5,0,0,0,.5,-.5,0,1,0,.5,.5,0,1,1,-.5,.5,0,0,1]);b=new bc(b,5);Ic.setIndex([0,1,2,0,2,3]);Ic.addAttribute("position",new Kd(b,3,0,!1));Ic.addAttribute("uv",new Kd(b,2,3,!1))}this.geometry=Ic;this.material=void 0!==a?a:new Gb;this.center=new v(.5,.5)}function Ke(a,b,c,d,e,f){Jc.subVectors(a, +{detail:this}))}function Ie(a,b){this.name="";this.color=new G(a);this.density=void 0!==b?b:2.5E-4}function Je(a,b,c){this.name="";this.color=new G(a);this.near=void 0!==b?b:1;this.far=void 0!==c?c:1E3}function bc(a,b){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.version=0}function Kd(a,b,c,d){this.data=a;this.itemSize=b;this.offset=c;this.normalized=!0===d}function Gb(a){O.call(this);this.type="SpriteMaterial";this.color= +new G(16777215);this.map=null;this.rotation=0;this.sizeAttenuation=!0;this.lights=!1;this.transparent=!0;this.setValues(a)}function Ld(a){A.call(this);this.type="Sprite";if(void 0===Ic){Ic=new D;var b=new Float32Array([-.5,-.5,0,0,0,.5,-.5,0,1,0,.5,.5,0,1,1,-.5,.5,0,0,1]);b=new bc(b,5);Ic.setIndex([0,1,2,0,2,3]);Ic.addAttribute("position",new Kd(b,3,0,!1));Ic.addAttribute("uv",new Kd(b,2,3,!1))}this.geometry=Ic;this.material=void 0!==a?a:new Gb;this.center=new v(.5,.5)}function Ke(a,b,c,d,e,f){Jc.subVectors(a, c).addScalar(.5).multiply(d);void 0!==e?(Md.x=f*Jc.x-e*Jc.y,Md.y=e*Jc.x+f*Jc.y):Md.copy(Jc);a.copy(b);a.x+=Md.x;a.y+=Md.y;a.applyMatrix4(Jh)}function Nd(){A.call(this);this.type="LOD";Object.defineProperties(this,{levels:{enumerable:!0,value:[]}});this.autoUpdate=!0}function Od(a,b){a&&a.isGeometry&&console.error("THREE.SkinnedMesh no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.");ia.call(this,a,b);this.type="SkinnedMesh";this.bindMode="attached";this.bindMatrix=new W;this.bindMatrixInverse= -new W}function Le(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;ae.far||f.push({distance:a,distanceToRay:Math.sqrt(h), +this.color=new G(16777215);this.map=null;this.size=1;this.sizeAttenuation=!0;this.lights=this.morphTargets=!1;this.setValues(a)}function Kc(a,b){A.call(this);this.type="Points";this.geometry=void 0!==a?a:new D;this.material=void 0!==b?b:new Qa({color:16777215*Math.random()});this.updateMorphTargets()}function fg(a,b,c,d,e,f,g){var h=gg.distanceSqToPoint(a);he.far||f.push({distance:a,distanceToRay:Math.sqrt(h), point:c,index:b,face:null,object:g}))}function hg(a,b,c,d,e,f,g,h,l){V.call(this,a,b,c,d,e,f,g,h,l);this.format=void 0!==g?g:1022;this.minFilter=void 0!==f?f:1006;this.magFilter=void 0!==e?e:1006;this.generateMipmaps=!1}function Lc(a,b,c,d,e,f,g,h,l,m,p,k){V.call(this,null,f,g,h,l,m,d,e,p,k);this.image={width:b,height:c};this.mipmaps=a;this.generateMipmaps=this.flipY=!1}function Pd(a,b,c,d,e,f,g,h,l){V.call(this,a,b,c,d,e,f,g,h,l);this.needsUpdate=!0}function Qd(a,b,c,d,e,f,g,h,l,m){m=void 0!==m? m:1026;if(1026!==m&&1027!==m)throw Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");void 0===c&&1026===m&&(c=1012);void 0===c&&1027===m&&(c=1020);V.call(this,null,d,e,f,g,h,m,c,l);this.image={width:a,height:b};this.magFilter=void 0!==g?g:1003;this.minFilter=void 0!==h?h:1003;this.generateMipmaps=this.flipY=!1}function Mc(a){D.call(this);this.type="WireframeGeometry";var b=[],c,d,e,f=[0,0],g={},h=["a","b","c"];if(a&&a.isGeometry){var l=a.faces;var m=0;for(d= l.length;mc;c++){var k=p[h[c]];var q=p[h[(c+1)%3]];f[0]=Math.min(k,q);f[1]=Math.max(k,q);k=f[0]+","+f[1];void 0===g[k]&&(g[k]={index1:f[0],index2:f[1]})}}for(k in g)m=g[k],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)if(h=new n,null!==a.index){l=a.attributes.position;p=a.index;var r=a.groups;0===r.length&&(r=[{start:0,count:p.count,materialIndex:0}]);a=0;for(e=r.length;athis.duration&&this.resetDuration()}function ek(a){switch(a.toLowerCase()){case "scalar":case "double":case "float":case "number":case "integer":return $c; @@ -293,14 +294,14 @@ a)}function Ue(a){Z.call(this,a)}function Ve(a){Z.call(this,a)}function C(){this h=l*(h-f);a=f;b=e;c=-3*f+3*g-2*e-h;d=2*f-2*g+e+h},initNonuniformCatmullRom:function(e,f,g,h,l,m,k){e=((f-e)/l-(g-e)/(l+m)+(g-f)/m)*m;h=((g-f)/m-(h-f)/(m+k)+(h-g)/k)*m;a=f;b=e;c=-3*f+3*g-2*e-h;d=2*f-2*g+e+h},calc:function(e){var f=e*e;return a+b*e+c*f+d*f*e}}}function wa(a,b,c,d){C.call(this);this.type="CatmullRomCurve3";this.points=a||[];this.closed=b||!1;this.curveType=c||"centripetal";this.tension=d||.5}function Th(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 me(a,b,c,d){var e=1-a;return e*e*b+2*(1-a)*a*c+a*a*d}function ne(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 Sa(a,b,c,d){C.call(this);this.type="CubicBezierCurve";this.v0=a||new v;this.v1=b||new v;this.v2=c||new v;this.v3=d||new v}function gb(a,b,c,d){C.call(this);this.type="CubicBezierCurve3";this.v0=a||new n;this.v1=b||new n;this.v2=c||new n;this.v3=d||new n}function xa(a,b){C.call(this);this.type="LineCurve";this.v1=a||new v;this.v2=b|| new v}function Ta(a,b){C.call(this);this.type="LineCurve3";this.v1=a||new n;this.v2=b||new n}function Ua(a,b,c){C.call(this);this.type="QuadraticBezierCurve";this.v0=a||new v;this.v1=b||new v;this.v2=c||new v}function hb(a,b,c){C.call(this);this.type="QuadraticBezierCurve3";this.v0=a||new n;this.v1=b||new n;this.v2=c||new n}function Va(a){C.call(this);this.type="SplineCurve";this.points=a||[]}function rb(){C.call(this);this.type="CurvePath";this.curves=[];this.autoClose=!1}function Wa(a){rb.call(this); -this.type="Path";this.currentPoint=new v;a&&this.setFromPoints(a)}function Ib(a){Wa.call(this,a);this.uuid=N.generateUUID();this.type="Shape";this.holes=[]}function ba(a,b){A.call(this);this.type="Light";this.color=new I(a);this.intensity=void 0!==b?b:1;this.receiveShadow=void 0}function We(a,b,c){ba.call(this,a,c);this.type="HemisphereLight";this.castShadow=void 0;this.position.copy(A.DefaultUp);this.updateMatrix();this.groundColor=new I(b)}function ib(a){this.camera=a;this.bias=0;this.radius=1; +this.type="Path";this.currentPoint=new v;a&&this.setFromPoints(a)}function Ib(a){Wa.call(this,a);this.uuid=N.generateUUID();this.type="Shape";this.holes=[]}function ba(a,b){A.call(this);this.type="Light";this.color=new G(a);this.intensity=void 0!==b?b:1;this.receiveShadow=void 0}function We(a,b,c){ba.call(this,a,c);this.type="HemisphereLight";this.castShadow=void 0;this.position.copy(A.DefaultUp);this.updateMatrix();this.groundColor=new G(b)}function ib(a){this.camera=a;this.bias=0;this.radius=1; this.mapSize=new v(512,512);this.mapPass=this.map=null;this.matrix=new W;this._frustum=new Ed;this._frameExtents=new v(1,1);this._viewportCount=1;this._viewports=[new da(0,0,1,1)]}function Xe(){ib.call(this,new ja(50,1,.5,500))}function Ye(a,b,c,d,e,f){ba.call(this,a,b);this.type="SpotLight";this.position.copy(A.DefaultUp);this.updateMatrix();this.target=new A;Object.defineProperty(this,"power",{get:function(){return this.intensity*Math.PI},set:function(a){this.intensity=a/Math.PI}});this.distance= void 0!==c?c:0;this.angle=void 0!==d?d:Math.PI/3;this.penumbra=void 0!==e?e:0;this.decay=void 0!==f?f:1;this.shadow=new Xe}function og(){ib.call(this,new ja(90,1,.5,500));this._frameExtents=new v(4,2);this._viewportCount=6;this._viewports=[new da(2,1,1,1),new da(0,1,1,1),new da(3,1,1,1),new da(1,1,1,1),new da(3,0,1,1),new da(1,0,1,1)];this._cubeDirections=[new n(1,0,0),new n(-1,0,0),new n(0,0,1),new n(0,0,-1),new n(0,1,0),new n(0,-1,0)];this._cubeUps=[new n(0,1,0),new n(0,1,0),new n(0,1,0),new n(0, 1,0),new n(0,0,1),new n(0,0,-1)]}function Ze(a,b,c,d){ba.call(this,a,b);this.type="PointLight";Object.defineProperty(this,"power",{get:function(){return 4*this.intensity*Math.PI},set:function(a){this.intensity=a/(4*Math.PI)}});this.distance=void 0!==c?c:0;this.decay=void 0!==d?d:1;this.shadow=new og}function oe(a,b,c,d,e,f){bb.call(this);this.type="OrthographicCamera";this.zoom=1;this.view=null;this.left=void 0!==a?a:-1;this.right=void 0!==b?b:1;this.top=void 0!==c?c:1;this.bottom=void 0!==d?d:-1; this.near=void 0!==e?e:.1;this.far=void 0!==f?f:2E3;this.updateProjectionMatrix()}function $e(){ib.call(this,new oe(-5,5,5,-5,.5,500))}function af(a,b){ba.call(this,a,b);this.type="DirectionalLight";this.position.copy(A.DefaultUp);this.updateMatrix();this.target=new A;this.shadow=new $e}function bf(a,b){ba.call(this,a,b);this.type="AmbientLight";this.castShadow=void 0}function cf(a,b,c,d){ba.call(this,a,b);this.type="RectAreaLight";this.width=void 0!==c?c:10;this.height=void 0!==d?d:10}function df(a){Z.call(this, a);this.textures={}}function ef(){D.call(this);this.type="InstancedBufferGeometry";this.maxInstancedCount=void 0}function ff(a,b,c,d){"number"===typeof c&&(d=c,c=!1,console.error("THREE.InstancedBufferAttribute: The constructor now expects normalized as the third argument."));L.call(this,a,b,c);this.meshPerAttribute=d||1}function gf(a){Z.call(this,a)}function hf(a){Z.call(this,a)}function pg(a){"undefined"===typeof createImageBitmap&&console.warn("THREE.ImageBitmapLoader: createImageBitmap() not supported."); -"undefined"===typeof fetch&&console.warn("THREE.ImageBitmapLoader: fetch() not supported.");Z.call(this,a);this.options=void 0}function qg(){this.type="ShapePath";this.color=new I;this.subPaths=[];this.currentPath=null}function rg(a){this.type="Font";this.data=a}function sg(a){Z.call(this,a)}function jf(a){Z.call(this,a)}function kf(){this.coefficients=[];for(var a=0;9>a;a++)this.coefficients.push(new n)}function Xa(a,b){ba.call(this,void 0,b);this.sh=void 0!==a?a:new kf}function tg(a,b,c){Xa.call(this, -void 0,c);a=(new I).set(a);c=(new I).set(b);b=new n(a.r,a.g,a.b);a=new n(c.r,c.g,c.b);c=Math.sqrt(Math.PI);var d=c*Math.sqrt(.75);this.sh.coefficients[0].copy(b).add(a).multiplyScalar(c);this.sh.coefficients[1].copy(b).sub(a).multiplyScalar(d)}function ug(a,b){Xa.call(this,void 0,b);a=(new I).set(a);this.sh.coefficients[0].set(a.r,a.g,a.b).multiplyScalar(2*Math.sqrt(Math.PI))}function Uh(){this.type="StereoCamera";this.aspect=1;this.eyeSep=.064;this.cameraL=new ja;this.cameraL.layers.enable(1);this.cameraL.matrixAutoUpdate= +"undefined"===typeof fetch&&console.warn("THREE.ImageBitmapLoader: fetch() not supported.");Z.call(this,a);this.options=void 0}function qg(){this.type="ShapePath";this.color=new G;this.subPaths=[];this.currentPath=null}function rg(a){this.type="Font";this.data=a}function sg(a){Z.call(this,a)}function jf(a){Z.call(this,a)}function kf(){this.coefficients=[];for(var a=0;9>a;a++)this.coefficients.push(new n)}function Xa(a,b){ba.call(this,void 0,b);this.sh=void 0!==a?a:new kf}function tg(a,b,c){Xa.call(this, +void 0,c);a=(new G).set(a);c=(new G).set(b);b=new n(a.r,a.g,a.b);a=new n(c.r,c.g,c.b);c=Math.sqrt(Math.PI);var d=c*Math.sqrt(.75);this.sh.coefficients[0].copy(b).add(a).multiplyScalar(c);this.sh.coefficients[1].copy(b).sub(a).multiplyScalar(d)}function ug(a,b){Xa.call(this,void 0,b);a=(new G).set(a);this.sh.coefficients[0].set(a.r,a.g,a.b).multiplyScalar(2*Math.sqrt(Math.PI))}function Uh(){this.type="StereoCamera";this.aspect=1;this.eyeSep=.064;this.cameraL=new ja;this.cameraL.layers.enable(1);this.cameraL.matrixAutoUpdate= !1;this.cameraR=new ja;this.cameraR.layers.enable(2);this.cameraR.matrixAutoUpdate=!1;this._cache={focus:null,fov:null,aspect:null,near:null,far:null,zoom:null,eyeSep:null}}function vg(a){this.autoStart=void 0!==a?a:!0;this.elapsedTime=this.oldTime=this.startTime=0;this.running=!1}function wg(){A.call(this);this.type="AudioListener";this.context=xg.getContext();this.gain=this.context.createGain();this.gain.connect(this.context.destination);this.filter=null;this.timeDelta=0;this._clock=new vg}function dd(a){A.call(this); this.type="Audio";this.listener=a;this.context=a.context;this.gain=this.context.createGain();this.gain.connect(a.getInput());this.autoplay=!1;this.buffer=null;this.detune=0;this.loop=!1;this.offset=this.startTime=0;this.duration=void 0;this.playbackRate=1;this.isPlaying=!1;this.hasPlaybackControl=!0;this.sourceType="empty";this.filters=[]}function yg(a){dd.call(this,a);this.panner=this.context.createPanner();this.panner.panningModel="HRTF";this.panner.connect(this.gain)}function zg(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 Ag(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 Vh(a,b,c){c=c||ya.parseTrackName(b); @@ -311,16 +312,16 @@ this.value=a}function Cg(a,b,c){bc.call(this,a,b);this.meshPerAttribute=c||1}fun 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 P({fog:!1});this.cone=new aa(a,b);this.add(this.cone);this.update()}function bi(a){var b=[];a&&a.isBone&&b.push(a);for(var c=0;c>16&255)/255;this.g=(a>>8&255)/255;this.b=(a&255)/255;return this},setRGB:function(a,b,c){this.r=a;this.g=b;this.b=c;return this},setHSL:function(a,b,c){a=N.euclideanModulo(a,1);b=N.clamp(b,0,1);c=N.clamp(c,0,1);0===b?this.r=this.g=this.b=c:(b=.5>=c?c*(1+b):c+b-c*b,c=2*c-b,this.r=Rf(c,b,a+1/3),this.g=Rf(c,b,a),this.b=Rf(c,b,a-1/3));return this},setStyle:function(a){function b(b){void 0!==b&&1>parseFloat(b)&&console.warn("THREE.Color: Alpha component of "+a+" will be ignored.")}var c;if(c= /^((?:rgb|hsl)a?)\(\s*([^\)]*)\)/.exec(a)){var d=c[2];switch(c[1]){case "rgb":case "rgba":if(c=/^(\d+)\s*,\s*(\d+)\s*,\s*(\d+)\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(d))return this.r=Math.min(255,parseInt(c[1],10))/255,this.g=Math.min(255,parseInt(c[2],10))/255,this.b=Math.min(255,parseInt(c[3],10))/255,b(c[5]),this;if(c=/^(\d+)%\s*,\s*(\d+)%\s*,\s*(\d+)%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(d))return this.r=Math.min(100,parseInt(c[1],10))/100,this.g=Math.min(100,parseInt(c[2],10))/100,this.b=Math.min(100, parseInt(c[3],10))/100,b(c[5]),this;break;case "hsl":case "hsla":if(c=/^([0-9]*\.?[0-9]+)\s*,\s*(\d+)%\s*,\s*(\d+)%\s*(,\s*([0-9]*\.?[0-9]+)\s*)?$/.exec(d)){d=parseFloat(c[1])/360;var e=parseInt(c[2],10)/100,f=parseInt(c[3],10)/100;b(c[5]);return this.setHSL(d,e,f)}}}else if(c=/^#([A-Fa-f0-9]+)$/.exec(a)){c=c[1];d=c.length;if(3===d)return this.r=parseInt(c.charAt(0)+c.charAt(0),16)/255,this.g=parseInt(c.charAt(1)+c.charAt(1),16)/255,this.b=parseInt(c.charAt(2)+c.charAt(2),16)/255,this;if(6===d)return this.r= @@ -476,13 +477,13 @@ sub:function(a){this.r=Math.max(0,this.r-a.r);this.g=Math.max(0,this.g-a.g);this equals:function(a){return a.r===this.r&&a.g===this.g&&a.b===this.b},fromArray:function(a,b){void 0===b&&(b=0);this.r=a[b];this.g=a[b+1];this.b=a[b+2];return this},toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);a[b]=this.r;a[b+1]=this.g;a[b+2]=this.b;return a},toJSON:function(){return this.getHex()}});Object.assign(zc.prototype,{clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.a=a.a;this.b=a.b;this.c=a.c;this.normal.copy(a.normal);this.color.copy(a.color); this.materialIndex=a.materialIndex;for(var b=0,c=a.vertexNormals.length;bthis.opacity&&(d.opacity=this.opacity);!0===this.transparent&&(d.transparent=this.transparent);d.depthFunc=this.depthFunc;d.depthTest=this.depthTest;d.depthWrite=this.depthWrite;d.stencilWrite=this.stencilWrite;d.stencilFunc= -this.stencilFunc;d.stencilRef=this.stencilRef;d.stencilMask=this.stencilMask;d.stencilFail=this.stencilFail;d.stencilZFail=this.stencilZFail;d.stencilZPass=this.stencilZPass;this.rotation&&0!==this.rotation&&(d.rotation=this.rotation);!0===this.polygonOffset&&(d.polygonOffset=!0);0!==this.polygonOffsetFactor&&(d.polygonOffsetFactor=this.polygonOffsetFactor);0!==this.polygonOffsetUnits&&(d.polygonOffsetUnits=this.polygonOffsetUnits);this.linewidth&&1!==this.linewidth&&(d.linewidth=this.linewidth); +type:"Material",generator:"Material.toJSON"}};d.uuid=this.uuid;d.type=this.type;""!==this.name&&(d.name=this.name);this.color&&this.color.isColor&&(d.color=this.color.getHex());void 0!==this.roughness&&(d.roughness=this.roughness);void 0!==this.metalness&&(d.metalness=this.metalness);this.sheen&&this.sheen.isColor&&(d.sheen=this.sheen.getHex());this.emissive&&this.emissive.isColor&&(d.emissive=this.emissive.getHex());this.emissiveIntensity&&1!==this.emissiveIntensity&&(d.emissiveIntensity=this.emissiveIntensity); +this.specular&&this.specular.isColor&&(d.specular=this.specular.getHex());void 0!==this.shininess&&(d.shininess=this.shininess);void 0!==this.clearcoat&&(d.clearcoat=this.clearcoat);void 0!==this.clearcoatRoughness&&(d.clearcoatRoughness=this.clearcoatRoughness);this.clearcoatNormalMap&&this.clearcoatNormalMap.isTexture&&(d.clearcoatNormalMap=this.clearcoatNormalMap.toJSON(a).uuid,d.clearcoatNormalScale=this.clearcoatNormalScale.toArray());this.map&&this.map.isTexture&&(d.map=this.map.toJSON(a).uuid); +this.matcap&&this.matcap.isTexture&&(d.matcap=this.matcap.toJSON(a).uuid);this.alphaMap&&this.alphaMap.isTexture&&(d.alphaMap=this.alphaMap.toJSON(a).uuid);this.lightMap&&this.lightMap.isTexture&&(d.lightMap=this.lightMap.toJSON(a).uuid);this.aoMap&&this.aoMap.isTexture&&(d.aoMap=this.aoMap.toJSON(a).uuid,d.aoMapIntensity=this.aoMapIntensity);this.bumpMap&&this.bumpMap.isTexture&&(d.bumpMap=this.bumpMap.toJSON(a).uuid,d.bumpScale=this.bumpScale);this.normalMap&&this.normalMap.isTexture&&(d.normalMap= +this.normalMap.toJSON(a).uuid,d.normalMapType=this.normalMapType,d.normalScale=this.normalScale.toArray());this.displacementMap&&this.displacementMap.isTexture&&(d.displacementMap=this.displacementMap.toJSON(a).uuid,d.displacementScale=this.displacementScale,d.displacementBias=this.displacementBias);this.roughnessMap&&this.roughnessMap.isTexture&&(d.roughnessMap=this.roughnessMap.toJSON(a).uuid);this.metalnessMap&&this.metalnessMap.isTexture&&(d.metalnessMap=this.metalnessMap.toJSON(a).uuid);this.emissiveMap&& +this.emissiveMap.isTexture&&(d.emissiveMap=this.emissiveMap.toJSON(a).uuid);this.specularMap&&this.specularMap.isTexture&&(d.specularMap=this.specularMap.toJSON(a).uuid);this.envMap&&this.envMap.isTexture&&(d.envMap=this.envMap.toJSON(a).uuid,d.reflectivity=this.reflectivity,d.refractionRatio=this.refractionRatio,void 0!==this.combine&&(d.combine=this.combine),void 0!==this.envMapIntensity&&(d.envMapIntensity=this.envMapIntensity));this.gradientMap&&this.gradientMap.isTexture&&(d.gradientMap=this.gradientMap.toJSON(a).uuid); +void 0!==this.size&&(d.size=this.size);void 0!==this.sizeAttenuation&&(d.sizeAttenuation=this.sizeAttenuation);1!==this.blending&&(d.blending=this.blending);!0===this.flatShading&&(d.flatShading=this.flatShading);0!==this.side&&(d.side=this.side);0!==this.vertexColors&&(d.vertexColors=this.vertexColors);1>this.opacity&&(d.opacity=this.opacity);!0===this.transparent&&(d.transparent=this.transparent);d.depthFunc=this.depthFunc;d.depthTest=this.depthTest;d.depthWrite=this.depthWrite;d.stencilWrite=this.stencilWrite; +d.stencilFunc=this.stencilFunc;d.stencilRef=this.stencilRef;d.stencilMask=this.stencilMask;d.stencilFail=this.stencilFail;d.stencilZFail=this.stencilZFail;d.stencilZPass=this.stencilZPass;this.rotation&&0!==this.rotation&&(d.rotation=this.rotation);!0===this.polygonOffset&&(d.polygonOffset=!0);0!==this.polygonOffsetFactor&&(d.polygonOffsetFactor=this.polygonOffsetFactor);0!==this.polygonOffsetUnits&&(d.polygonOffsetUnits=this.polygonOffsetUnits);this.linewidth&&1!==this.linewidth&&(d.linewidth=this.linewidth); void 0!==this.dashSize&&(d.dashSize=this.dashSize);void 0!==this.gapSize&&(d.gapSize=this.gapSize);void 0!==this.scale&&(d.scale=this.scale);!0===this.dithering&&(d.dithering=!0);0\n#incl shadow_frag:"uniform vec3 color;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\tgl_FragColor = vec4( color, opacity * ( 1.0 - getShadowMask() ) );\n\t#include \n}",shadow_vert:"#include \n#include \nvoid main() {\n\t#include \n\t#include \n\t#include \n\t#include \n\t#include \n}", sprite_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#include \n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include \n\t#include \n\t#include \n\toutgoingLight = diffuseColor.rgb;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include \n\t#include \n\t#include \n}", sprite_vert:"uniform float rotation;\nuniform vec2 center;\n#include \n#include \n#include \n#include \n#include \nvoid main() {\n\t#include \n\tvec4 mvPosition = modelViewMatrix * vec4( 0.0, 0.0, 0.0, 1.0 );\n\tvec2 scale;\n\tscale.x = length( vec3( modelMatrix[ 0 ].x, modelMatrix[ 0 ].y, modelMatrix[ 0 ].z ) );\n\tscale.y = length( vec3( modelMatrix[ 1 ].x, modelMatrix[ 1 ].y, modelMatrix[ 1 ].z ) );\n\t#ifndef USE_SIZEATTENUATION\n\t\tbool isPerspective = ( projectionMatrix[ 2 ][ 3 ] == - 1.0 );\n\t\tif ( isPerspective ) scale *= - mvPosition.z;\n\t#endif\n\tvec2 alignedPosition = ( position.xy - ( center - vec2( 0.5 ) ) ) * scale;\n\tvec2 rotatedPosition;\n\trotatedPosition.x = cos( rotation ) * alignedPosition.x - sin( rotation ) * alignedPosition.y;\n\trotatedPosition.y = sin( rotation ) * alignedPosition.x + cos( rotation ) * alignedPosition.y;\n\tmvPosition.xy += rotatedPosition;\n\tgl_Position = projectionMatrix * mvPosition;\n\t#include \n\t#include \n\t#include \n}"}, -G={common:{diffuse:{value:new I(15658734)},opacity:{value:1},map:{value:null},uvTransform:{value:new S},alphaMap:{value:null}},specularmap:{specularMap:{value:null}},envmap:{envMap:{value:null},flipEnvMap:{value:-1},reflectivity:{value:1},refractionRatio:{value:.98},maxMipLevel:{value:0}},aomap:{aoMap:{value:null},aoMapIntensity:{value:1}},lightmap:{lightMap:{value:null},lightMapIntensity:{value:1}},emissivemap:{emissiveMap:{value:null}},bumpmap:{bumpMap:{value:null},bumpScale:{value:1}},normalmap:{normalMap:{value:null}, -normalScale:{value:new v(1,1)}},displacementmap:{displacementMap:{value:null},displacementScale:{value:1},displacementBias:{value:0}},roughnessmap:{roughnessMap:{value:null}},metalnessmap:{metalnessMap:{value:null}},gradientmap:{gradientMap:{value:null}},fog:{fogDensity:{value:2.5E-4},fogNear:{value:1},fogFar:{value:2E3},fogColor:{value:new I(16777215)}},lights:{ambientLightColor:{value:[]},lightProbe:{value:[]},directionalLights:{value:[],properties:{direction:{},color:{},shadow:{},shadowBias:{}, +I={common:{diffuse:{value:new G(15658734)},opacity:{value:1},map:{value:null},uvTransform:{value:new S},alphaMap:{value:null}},specularmap:{specularMap:{value:null}},envmap:{envMap:{value:null},flipEnvMap:{value:-1},reflectivity:{value:1},refractionRatio:{value:.98},maxMipLevel:{value:0}},aomap:{aoMap:{value:null},aoMapIntensity:{value:1}},lightmap:{lightMap:{value:null},lightMapIntensity:{value:1}},emissivemap:{emissiveMap:{value:null}},bumpmap:{bumpMap:{value:null},bumpScale:{value:1}},normalmap:{normalMap:{value:null}, +normalScale:{value:new v(1,1)}},displacementmap:{displacementMap:{value:null},displacementScale:{value:1},displacementBias:{value:0}},roughnessmap:{roughnessMap:{value:null}},metalnessmap:{metalnessMap:{value:null}},gradientmap:{gradientMap:{value:null}},fog:{fogDensity:{value:2.5E-4},fogNear:{value:1},fogFar:{value:2E3},fogColor:{value:new G(16777215)}},lights:{ambientLightColor:{value:[]},lightProbe:{value:[]},directionalLights:{value:[],properties:{direction:{},color:{},shadow:{},shadowBias:{}, shadowRadius:{},shadowMapSize:{}}},directionalShadowMap:{value:[]},directionalShadowMatrix:{value:[]},spotLights:{value:[],properties:{color:{},position:{},direction:{},distance:{},coneCos:{},penumbraCos:{},decay:{},shadow:{},shadowBias:{},shadowRadius:{},shadowMapSize:{}}},spotShadowMap:{value:[]},spotShadowMatrix:{value:[]},pointLights:{value:[],properties:{color:{},position:{},decay:{},distance:{},shadow:{},shadowBias:{},shadowRadius:{},shadowMapSize:{},shadowCameraNear:{},shadowCameraFar:{}}}, -pointShadowMap:{value:[]},pointShadowMatrix:{value:[]},hemisphereLights:{value:[],properties:{direction:{},skyColor:{},groundColor:{}}},rectAreaLights:{value:[],properties:{color:{},position:{},width:{},height:{}}}},points:{diffuse:{value:new I(15658734)},opacity:{value:1},size:{value:1},scale:{value:1},map:{value:null},uvTransform:{value:new S}},sprite:{diffuse:{value:new I(15658734)},opacity:{value:1},center:{value:new v(.5,.5)},rotation:{value:0},map:{value:null},uvTransform:{value:new S}}},db= -{basic:{uniforms:Ba([G.common,G.specularmap,G.envmap,G.aomap,G.lightmap,G.fog]),vertexShader:M.meshbasic_vert,fragmentShader:M.meshbasic_frag},lambert:{uniforms:Ba([G.common,G.specularmap,G.envmap,G.aomap,G.lightmap,G.emissivemap,G.fog,G.lights,{emissive:{value:new I(0)}}]),vertexShader:M.meshlambert_vert,fragmentShader:M.meshlambert_frag},phong:{uniforms:Ba([G.common,G.specularmap,G.envmap,G.aomap,G.lightmap,G.emissivemap,G.bumpmap,G.normalmap,G.displacementmap,G.gradientmap,G.fog,G.lights,{emissive:{value:new I(0)}, -specular:{value:new I(1118481)},shininess:{value:30}}]),vertexShader:M.meshphong_vert,fragmentShader:M.meshphong_frag},standard:{uniforms:Ba([G.common,G.envmap,G.aomap,G.lightmap,G.emissivemap,G.bumpmap,G.normalmap,G.displacementmap,G.roughnessmap,G.metalnessmap,G.fog,G.lights,{emissive:{value:new I(0)},roughness:{value:.5},metalness:{value:.5},envMapIntensity:{value:1}}]),vertexShader:M.meshphysical_vert,fragmentShader:M.meshphysical_frag},matcap:{uniforms:Ba([G.common,G.bumpmap,G.normalmap,G.displacementmap, -G.fog,{matcap:{value:null}}]),vertexShader:M.meshmatcap_vert,fragmentShader:M.meshmatcap_frag},points:{uniforms:Ba([G.points,G.fog]),vertexShader:M.points_vert,fragmentShader:M.points_frag},dashed:{uniforms:Ba([G.common,G.fog,{scale:{value:1},dashSize:{value:1},totalSize:{value:2}}]),vertexShader:M.linedashed_vert,fragmentShader:M.linedashed_frag},depth:{uniforms:Ba([G.common,G.displacementmap]),vertexShader:M.depth_vert,fragmentShader:M.depth_frag},normal:{uniforms:Ba([G.common,G.bumpmap,G.normalmap, -G.displacementmap,{opacity:{value:1}}]),vertexShader:M.normal_vert,fragmentShader:M.normal_frag},sprite:{uniforms:Ba([G.sprite,G.fog]),vertexShader:M.sprite_vert,fragmentShader:M.sprite_frag},background:{uniforms:{uvTransform:{value:new S},t2D:{value:null}},vertexShader:M.background_vert,fragmentShader:M.background_frag},cube:{uniforms:{tCube:{value:null},tFlip:{value:-1},opacity:{value:1}},vertexShader:M.cube_vert,fragmentShader:M.cube_frag},equirect:{uniforms:{tEquirect:{value:null}},vertexShader:M.equirect_vert, -fragmentShader:M.equirect_frag},distanceRGBA:{uniforms:Ba([G.common,G.displacementmap,{referencePosition:{value:new n},nearDistance:{value:1},farDistance:{value:1E3}}]),vertexShader:M.distanceRGBA_vert,fragmentShader:M.distanceRGBA_frag},shadow:{uniforms:Ba([G.lights,G.fog,{color:{value:new I(0)},opacity:{value:1}}]),vertexShader:M.shadow_vert,fragmentShader:M.shadow_frag}};db.physical={uniforms:Ba([db.standard.uniforms,{transparency:{value:0},clearcoat:{value:0},clearcoatRoughness:{value:0},sheen:{value:new I(0)}, +pointShadowMap:{value:[]},pointShadowMatrix:{value:[]},hemisphereLights:{value:[],properties:{direction:{},skyColor:{},groundColor:{}}},rectAreaLights:{value:[],properties:{color:{},position:{},width:{},height:{}}}},points:{diffuse:{value:new G(15658734)},opacity:{value:1},size:{value:1},scale:{value:1},map:{value:null},uvTransform:{value:new S}},sprite:{diffuse:{value:new G(15658734)},opacity:{value:1},center:{value:new v(.5,.5)},rotation:{value:0},map:{value:null},uvTransform:{value:new S}}},db= +{basic:{uniforms:Ba([I.common,I.specularmap,I.envmap,I.aomap,I.lightmap,I.fog]),vertexShader:M.meshbasic_vert,fragmentShader:M.meshbasic_frag},lambert:{uniforms:Ba([I.common,I.specularmap,I.envmap,I.aomap,I.lightmap,I.emissivemap,I.fog,I.lights,{emissive:{value:new G(0)}}]),vertexShader:M.meshlambert_vert,fragmentShader:M.meshlambert_frag},phong:{uniforms:Ba([I.common,I.specularmap,I.envmap,I.aomap,I.lightmap,I.emissivemap,I.bumpmap,I.normalmap,I.displacementmap,I.gradientmap,I.fog,I.lights,{emissive:{value:new G(0)}, +specular:{value:new G(1118481)},shininess:{value:30}}]),vertexShader:M.meshphong_vert,fragmentShader:M.meshphong_frag},standard:{uniforms:Ba([I.common,I.envmap,I.aomap,I.lightmap,I.emissivemap,I.bumpmap,I.normalmap,I.displacementmap,I.roughnessmap,I.metalnessmap,I.fog,I.lights,{emissive:{value:new G(0)},roughness:{value:.5},metalness:{value:.5},envMapIntensity:{value:1}}]),vertexShader:M.meshphysical_vert,fragmentShader:M.meshphysical_frag},matcap:{uniforms:Ba([I.common,I.bumpmap,I.normalmap,I.displacementmap, +I.fog,{matcap:{value:null}}]),vertexShader:M.meshmatcap_vert,fragmentShader:M.meshmatcap_frag},points:{uniforms:Ba([I.points,I.fog]),vertexShader:M.points_vert,fragmentShader:M.points_frag},dashed:{uniforms:Ba([I.common,I.fog,{scale:{value:1},dashSize:{value:1},totalSize:{value:2}}]),vertexShader:M.linedashed_vert,fragmentShader:M.linedashed_frag},depth:{uniforms:Ba([I.common,I.displacementmap]),vertexShader:M.depth_vert,fragmentShader:M.depth_frag},normal:{uniforms:Ba([I.common,I.bumpmap,I.normalmap, +I.displacementmap,{opacity:{value:1}}]),vertexShader:M.normal_vert,fragmentShader:M.normal_frag},sprite:{uniforms:Ba([I.sprite,I.fog]),vertexShader:M.sprite_vert,fragmentShader:M.sprite_frag},background:{uniforms:{uvTransform:{value:new S},t2D:{value:null}},vertexShader:M.background_vert,fragmentShader:M.background_frag},cube:{uniforms:{tCube:{value:null},tFlip:{value:-1},opacity:{value:1}},vertexShader:M.cube_vert,fragmentShader:M.cube_frag},equirect:{uniforms:{tEquirect:{value:null}},vertexShader:M.equirect_vert, +fragmentShader:M.equirect_frag},distanceRGBA:{uniforms:Ba([I.common,I.displacementmap,{referencePosition:{value:new n},nearDistance:{value:1},farDistance:{value:1E3}}]),vertexShader:M.distanceRGBA_vert,fragmentShader:M.distanceRGBA_frag},shadow:{uniforms:Ba([I.lights,I.fog,{color:{value:new G(0)},opacity:{value:1}}]),vertexShader:M.shadow_vert,fragmentShader:M.shadow_frag}};db.physical={uniforms:Ba([db.standard.uniforms,{transparency:{value:0},clearcoat:{value:0},clearcoatRoughness:{value:0},sheen:{value:new G(0)}, clearcoatNormalScale:{value:new v(1,1)},clearcoatNormalMap:{value:null}}]),vertexShader:M.meshphysical_vert,fragmentShader:M.meshphysical_frag};Fd.prototype=Object.create(F.prototype);Fd.prototype.constructor=Fd;Zb.prototype=Object.create(D.prototype);Zb.prototype.constructor=Zb;ob.prototype=Object.create(V.prototype);ob.prototype.constructor=ob;ob.prototype.isCubeTexture=!0;Object.defineProperty(ob.prototype,"images",{get:function(){return this.image},set:function(a){this.image=a}});Ec.prototype= Object.create(V.prototype);Ec.prototype.constructor=Ec;Ec.prototype.isDataTexture2DArray=!0;Fc.prototype=Object.create(V.prototype);Fc.prototype.constructor=Fc;Fc.prototype.isDataTexture3D=!0;var qh=new V,jj=new Ec,lj=new Fc,rh=new ob,kh=[],mh=[],ph=new Float32Array(16),oh=new Float32Array(9),nh=new Float32Array(4);sh.prototype.updateCache=function(a){var b=this.cache;a instanceof Float32Array&&b.length!==a.length&&(this.cache=new Float32Array(a.length));Ga(b,a)};th.prototype.setValue=function(a, b,c){for(var d=this.seq,e=0,f=d.length;e!==f;++e){var g=d[e];g.setValue(a,b[g.id],c)}};var Yf=/([\w\d_]+)(\])?(\[|\.)?/g;Bb.prototype.setValue=function(a,b,c,d){b=this.map[b];void 0!==b&&b.setValue(a,c,d)};Bb.prototype.setOptional=function(a,b,c){b=b[c];void 0!==b&&this.setValue(a,c,b)};Bb.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)}};Bb.seqWithValue=function(a,b){for(var c=[],d=0,e=a.length;d!==e;++d){var f=a[d];f.id in @@ -693,7 +694,7 @@ ExtrudeBufferGeometry:eb,EdgesGeometry:Xc,ConeGeometry:he,ConeBufferGeometry:ie, !0;fb.prototype=Object.create(O.prototype);fb.prototype.constructor=fb;fb.prototype.isMeshStandardMaterial=!0;fb.prototype.copy=function(a){O.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.normalMapType=a.normalMapType;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};kc.prototype=Object.create(fb.prototype);kc.prototype.constructor=kc;kc.prototype.isMeshPhysicalMaterial=!0;kc.prototype.copy=function(a){fb.prototype.copy.call(this,a);this.defines={STANDARD:"",PHYSICAL:""};this.reflectivity=a.reflectivity;this.clearcoat=a.clearcoat;this.clearcoatRoughness= -a.clearcoatRoughness;this.sheen=a.sheen?(this.sheen||new I).copy(a.sheen):null;this.clearcoatNormalMap=a.clearcoatNormalMap;this.clearcoatNormalScale.copy(a.clearcoatNormalScale);this.transparency=a.transparency;return this};Ra.prototype=Object.create(O.prototype);Ra.prototype.constructor=Ra;Ra.prototype.isMeshPhongMaterial=!0;Ra.prototype.copy=function(a){O.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.clearcoatRoughness;this.sheen=a.sheen?(this.sheen||new G).copy(a.sheen):null;this.clearcoatNormalMap=a.clearcoatNormalMap;this.clearcoatNormalScale.copy(a.clearcoatNormalScale);this.transparency=a.transparency;return this};Ra.prototype=Object.create(O.prototype);Ra.prototype.constructor=Ra;Ra.prototype.isMeshPhongMaterial=!0;Ra.prototype.copy=function(a){O.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=a.emissiveMap;this.emissiveIntensity=a.emissiveIntensity;this.bumpMap=a.bumpMap;this.bumpScale=a.bumpScale;this.normalMap=a.normalMap;this.normalMapType=a.normalMapType;this.normalScale.copy(a.normalScale);this.displacementMap=a.displacementMap;this.displacementScale=a.displacementScale;this.displacementBias=a.displacementBias;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};lc.prototype=Object.create(Ra.prototype);lc.prototype.constructor=lc;lc.prototype.isMeshToonMaterial= !0;lc.prototype.copy=function(a){Ra.prototype.copy.call(this,a);this.gradientMap=a.gradientMap;return this};mc.prototype=Object.create(O.prototype);mc.prototype.constructor=mc;mc.prototype.isMeshNormalMaterial=!0;mc.prototype.copy=function(a){O.prototype.copy.call(this,a);this.bumpMap=a.bumpMap;this.bumpScale=a.bumpScale;this.normalMap=a.normalMap;this.normalMapType=a.normalMapType;this.normalScale.copy(a.normalScale);this.displacementMap=a.displacementMap;this.displacementScale=a.displacementScale; @@ -779,26 +780,26 @@ fullWidth:1,fullHeight:1,offsetX:0,offsetY:0,width:1,height:1});this.view.enable A.prototype.toJSON.call(this,a);a.object.zoom=this.zoom;a.object.left=this.left;a.object.right=this.right;a.object.top=this.top;a.object.bottom=this.bottom;a.object.near=this.near;a.object.far=this.far;null!==this.view&&(a.object.view=Object.assign({},this.view));return a}});$e.prototype=Object.assign(Object.create(ib.prototype),{constructor:$e,isDirectionalLightShadow:!0,updateMatrices:function(a,b,c){ib.prototype.updateMatrices.call(this,a,b,c)}});af.prototype=Object.assign(Object.create(ba.prototype), {constructor:af,isDirectionalLight:!0,copy:function(a){ba.prototype.copy.call(this,a);this.target=a.target.clone();this.shadow=a.shadow.clone();return this}});bf.prototype=Object.assign(Object.create(ba.prototype),{constructor:bf,isAmbientLight:!0});cf.prototype=Object.assign(Object.create(ba.prototype),{constructor:cf,isRectAreaLight:!0,copy:function(a){ba.prototype.copy.call(this,a);this.width=a.width;this.height=a.height;return this},toJSON:function(a){a=ba.prototype.toJSON.call(this,a);a.object.width= this.width;a.object.height=this.height;return a}});df.prototype=Object.assign(Object.create(Z.prototype),{constructor:df,load:function(a,b,c,d){var e=this,f=new Na(e.manager);f.setPath(e.path);f.load(a,function(a){b(e.parse(JSON.parse(a)))},c,d)},parse:function(a){function b(a){void 0===c[a]&&console.warn("THREE.MaterialLoader: Undefined texture",a);return c[a]}var c=this.textures,d=new tk[a.type];void 0!==a.uuid&&(d.uuid=a.uuid);void 0!==a.name&&(d.name=a.name);void 0!==a.color&&d.color.setHex(a.color); -void 0!==a.roughness&&(d.roughness=a.roughness);void 0!==a.metalness&&(d.metalness=a.metalness);void 0!==a.emissive&&d.emissive.setHex(a.emissive);void 0!==a.specular&&d.specular.setHex(a.specular);void 0!==a.shininess&&(d.shininess=a.shininess);void 0!==a.clearcoat&&(d.clearcoat=a.clearcoat);void 0!==a.clearcoatRoughness&&(d.clearcoatRoughness=a.clearcoatRoughness);void 0!==a.vertexColors&&(d.vertexColors=a.vertexColors);void 0!==a.fog&&(d.fog=a.fog);void 0!==a.flatShading&&(d.flatShading=a.flatShading); -void 0!==a.blending&&(d.blending=a.blending);void 0!==a.combine&&(d.combine=a.combine);void 0!==a.side&&(d.side=a.side);void 0!==a.opacity&&(d.opacity=a.opacity);void 0!==a.transparent&&(d.transparent=a.transparent);void 0!==a.alphaTest&&(d.alphaTest=a.alphaTest);void 0!==a.depthTest&&(d.depthTest=a.depthTest);void 0!==a.depthWrite&&(d.depthWrite=a.depthWrite);void 0!==a.colorWrite&&(d.colorWrite=a.colorWrite);void 0!==a.wireframe&&(d.wireframe=a.wireframe);void 0!==a.wireframeLinewidth&&(d.wireframeLinewidth= -a.wireframeLinewidth);void 0!==a.wireframeLinecap&&(d.wireframeLinecap=a.wireframeLinecap);void 0!==a.wireframeLinejoin&&(d.wireframeLinejoin=a.wireframeLinejoin);void 0!==a.rotation&&(d.rotation=a.rotation);1!==a.linewidth&&(d.linewidth=a.linewidth);void 0!==a.dashSize&&(d.dashSize=a.dashSize);void 0!==a.gapSize&&(d.gapSize=a.gapSize);void 0!==a.scale&&(d.scale=a.scale);void 0!==a.polygonOffset&&(d.polygonOffset=a.polygonOffset);void 0!==a.polygonOffsetFactor&&(d.polygonOffsetFactor=a.polygonOffsetFactor); -void 0!==a.polygonOffsetUnits&&(d.polygonOffsetUnits=a.polygonOffsetUnits);void 0!==a.skinning&&(d.skinning=a.skinning);void 0!==a.morphTargets&&(d.morphTargets=a.morphTargets);void 0!==a.morphNormals&&(d.morphNormals=a.morphNormals);void 0!==a.dithering&&(d.dithering=a.dithering);void 0!==a.visible&&(d.visible=a.visible);void 0!==a.toneMapped&&(d.toneMapped=a.toneMapped);void 0!==a.userData&&(d.userData=a.userData);if(void 0!==a.uniforms)for(var e in a.uniforms){var f=a.uniforms[e];d.uniforms[e]= -{};switch(f.type){case "t":d.uniforms[e].value=b(f.value);break;case "c":d.uniforms[e].value=(new I).setHex(f.value);break;case "v2":d.uniforms[e].value=(new v).fromArray(f.value);break;case "v3":d.uniforms[e].value=(new n).fromArray(f.value);break;case "v4":d.uniforms[e].value=(new da).fromArray(f.value);break;case "m3":d.uniforms[e].value=(new S).fromArray(f.value);case "m4":d.uniforms[e].value=(new W).fromArray(f.value);break;default:d.uniforms[e].value=f.value}}void 0!==a.defines&&(d.defines= -a.defines);void 0!==a.vertexShader&&(d.vertexShader=a.vertexShader);void 0!==a.fragmentShader&&(d.fragmentShader=a.fragmentShader);if(void 0!==a.extensions)for(var g in a.extensions)d.extensions[g]=a.extensions[g];void 0!==a.shading&&(d.flatShading=1===a.shading);void 0!==a.size&&(d.size=a.size);void 0!==a.sizeAttenuation&&(d.sizeAttenuation=a.sizeAttenuation);void 0!==a.map&&(d.map=b(a.map));void 0!==a.matcap&&(d.matcap=b(a.matcap));void 0!==a.alphaMap&&(d.alphaMap=b(a.alphaMap),d.transparent=!0); -void 0!==a.bumpMap&&(d.bumpMap=b(a.bumpMap));void 0!==a.bumpScale&&(d.bumpScale=a.bumpScale);void 0!==a.normalMap&&(d.normalMap=b(a.normalMap));void 0!==a.normalMapType&&(d.normalMapType=a.normalMapType);void 0!==a.normalScale&&(e=a.normalScale,!1===Array.isArray(e)&&(e=[e,e]),d.normalScale=(new v).fromArray(e));void 0!==a.displacementMap&&(d.displacementMap=b(a.displacementMap));void 0!==a.displacementScale&&(d.displacementScale=a.displacementScale);void 0!==a.displacementBias&&(d.displacementBias= -a.displacementBias);void 0!==a.roughnessMap&&(d.roughnessMap=b(a.roughnessMap));void 0!==a.metalnessMap&&(d.metalnessMap=b(a.metalnessMap));void 0!==a.emissiveMap&&(d.emissiveMap=b(a.emissiveMap));void 0!==a.emissiveIntensity&&(d.emissiveIntensity=a.emissiveIntensity);void 0!==a.specularMap&&(d.specularMap=b(a.specularMap));void 0!==a.envMap&&(d.envMap=b(a.envMap));void 0!==a.envMapIntensity&&(d.envMapIntensity=a.envMapIntensity);void 0!==a.reflectivity&&(d.reflectivity=a.reflectivity);void 0!==a.refractionRatio&& -(d.refractionRatio=a.refractionRatio);void 0!==a.lightMap&&(d.lightMap=b(a.lightMap));void 0!==a.lightMapIntensity&&(d.lightMapIntensity=a.lightMapIntensity);void 0!==a.aoMap&&(d.aoMap=b(a.aoMap));void 0!==a.aoMapIntensity&&(d.aoMapIntensity=a.aoMapIntensity);void 0!==a.gradientMap&&(d.gradientMap=b(a.gradientMap));void 0!==a.clearcoatNormalMap&&(d.clearcoatNormalMap=b(a.clearcoatNormalMap));void 0!==a.clearcoatNormalScale&&(d.clearcoatNormalScale=(new v).fromArray(a.clearcoatNormalScale));return d}, -setTextures:function(a){this.textures=a;return this}});var ah={decodeText:function(a){if("undefined"!==typeof TextDecoder)return(new TextDecoder).decode(a);for(var b="",c=0,d=a.length;c