|
@@ -2,12 +2,12 @@
|
|
|
(function(k,ta){"object"===typeof exports&&"undefined"!==typeof module?ta(exports):"function"===typeof define&&define.amd?define(["exports"],ta):(k=k||self,ta(k.THREE={}))})(this,function(k){function ta(){}function w(a,b){this.x=a||0;this.y=b||0}function wa(){this.elements=[1,0,0,0,1,0,0,0,1];0<arguments.length&&console.error("THREE.Matrix3: the constructor no longer reads arguments. use .set() instead.")}function R(a,b,c,d,e,f,g,h,l,n){Object.defineProperty(this,"id",{value:fj++});this.uuid=L.generateUUID();
|
|
|
this.name="";this.image=void 0!==a?a:R.DEFAULT_IMAGE;this.mipmaps=[];this.mapping=void 0!==b?b:R.DEFAULT_MAPPING;this.wrapS=void 0!==c?c:1001;this.wrapT=void 0!==d?d:1001;this.magFilter=void 0!==e?e:1006;this.minFilter=void 0!==f?f:1008;this.anisotropy=void 0!==l?l:1;this.format=void 0!==g?g:1023;this.internalFormat=null;this.type=void 0!==h?h:1009;this.offset=new w(0,0);this.repeat=new w(1,1);this.center=new w(0,0);this.rotation=0;this.matrixAutoUpdate=!0;this.matrix=new wa;this.generateMipmaps=
|
|
|
!0;this.premultiplyAlpha=!1;this.flipY=!0;this.unpackAlignment=4;this.encoding=void 0!==n?n:3E3;this.version=0;this.onUpdate=null}function ea(a,b,c,d){this.x=a||0;this.y=b||0;this.z=c||0;this.w=void 0!==d?d:1}function Ga(a,b,c){this.width=a;this.height=b;this.scissor=new ea(0,0,a,b);this.scissorTest=!1;this.viewport=new ea(0,0,a,b);c=c||{};this.texture=new R(void 0,c.mapping,c.wrapS,c.wrapT,c.magFilter,c.minFilter,c.format,c.type,c.anisotropy,c.encoding);this.texture.image={};this.texture.image.width=
|
|
|
-a;this.texture.image.height=b;this.texture.generateMipmaps=void 0!==c.generateMipmaps?c.generateMipmaps:!1;this.texture.minFilter=void 0!==c.minFilter?c.minFilter:1006;this.depthBuffer=void 0!==c.depthBuffer?c.depthBuffer:!0;this.stencilBuffer=void 0!==c.stencilBuffer?c.stencilBuffer:!0;this.depthTexture=void 0!==c.depthTexture?c.depthTexture:null}function Zf(a,b,c){Ga.call(this,a,b,c);this.samples=4}function ua(a,b,c,d){this._x=a||0;this._y=b||0;this._z=c||0;this._w=void 0!==d?d:1}function m(a,b,
|
|
|
+a;this.texture.image.height=b;this.texture.generateMipmaps=void 0!==c.generateMipmaps?c.generateMipmaps:!1;this.texture.minFilter=void 0!==c.minFilter?c.minFilter:1006;this.depthBuffer=void 0!==c.depthBuffer?c.depthBuffer:!0;this.stencilBuffer=void 0!==c.stencilBuffer?c.stencilBuffer:!0;this.depthTexture=void 0!==c.depthTexture?c.depthTexture:null}function Zf(a,b,c){Ga.call(this,a,b,c);this.samples=4}function la(a,b,c,d){this._x=a||0;this._y=b||0;this._z=c||0;this._w=void 0!==d?d:1}function m(a,b,
|
|
|
c){this.x=a||0;this.y=b||0;this.z=c||0}function M(){this.elements=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1];0<arguments.length&&console.error("THREE.Matrix4: the constructor no longer reads arguments. use .set() instead.")}function Tb(a,b,c,d){this._x=a||0;this._y=b||0;this._z=c||0;this._order=d||Tb.DefaultOrder}function De(){this.mask=1}function y(){Object.defineProperty(this,"id",{value:gj++});this.uuid=L.generateUUID();this.name="";this.type="Object3D";this.parent=null;this.children=[];this.up=y.DefaultUp.clone();
|
|
|
-var a=new m,b=new Tb,c=new ua,d=new m(1,1,1);b._onChange(function(){c.setFromEuler(b,!1)});c._onChange(function(){b.setFromQuaternion(c,void 0,!1)});Object.defineProperties(this,{position:{configurable:!0,enumerable:!0,value:a},rotation:{configurable:!0,enumerable:!0,value:b},quaternion:{configurable:!0,enumerable:!0,value:c},scale:{configurable:!0,enumerable:!0,value:d},modelViewMatrix:{value:new M},normalMatrix:{value:new wa}});this.matrix=new M;this.matrixWorld=new M;this.matrixAutoUpdate=y.DefaultMatrixAutoUpdate;
|
|
|
+var a=new m,b=new Tb,c=new la,d=new m(1,1,1);b._onChange(function(){c.setFromEuler(b,!1)});c._onChange(function(){b.setFromQuaternion(c,void 0,!1)});Object.defineProperties(this,{position:{configurable:!0,enumerable:!0,value:a},rotation:{configurable:!0,enumerable:!0,value:b},quaternion:{configurable:!0,enumerable:!0,value:c},scale:{configurable:!0,enumerable:!0,value:d},modelViewMatrix:{value:new M},normalMatrix:{value:new wa}});this.matrix=new M;this.matrixWorld=new M;this.matrixAutoUpdate=y.DefaultMatrixAutoUpdate;
|
|
|
this.matrixWorldNeedsUpdate=!1;this.layers=new De;this.visible=!0;this.receiveShadow=this.castShadow=!1;this.frustumCulled=!0;this.renderOrder=0;this.userData={}}function wd(){y.call(this);this.type="Scene";this.overrideMaterial=this.fog=this.environment=this.background=null;this.autoUpdate=!0;"undefined"!==typeof __THREE_DEVTOOLS__&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("observe",{detail:this}))}function Ta(a,b){this.min=void 0!==a?a:new m(Infinity,Infinity,Infinity);this.max=void 0!==
|
|
|
b?b:new m(-Infinity,-Infinity,-Infinity)}function $f(a,b,c,d,e){for(var f=0,g=a.length-3;f<=g;f+=3){Ub.fromArray(a,f);var h=e.x*Math.abs(Ub.x)+e.y*Math.abs(Ub.y)+e.z*Math.abs(Ub.z),l=b.dot(Ub),n=c.dot(Ub),t=d.dot(Ub);if(Math.max(-Math.max(l,n,t),Math.min(l,n,t))>h)return!1}return!0}function db(a,b){this.center=void 0!==a?a:new m;this.radius=void 0!==b?b:-1}function Vb(a,b){this.origin=void 0!==a?a:new m;this.direction=void 0!==b?b:new m(0,0,-1)}function Ua(a,b){this.normal=void 0!==a?a:new m(1,0,
|
|
|
-0);this.constant=void 0!==b?b:0}function oa(a,b,c){this.a=void 0!==a?a:new m;this.b=void 0!==b?b:new m;this.c=void 0!==c?c:new m}function D(a,b,c){return void 0===b&&void 0===c?this.set(a):this.setRGB(a,b,c)}function ag(a,b,c){0>c&&(c+=1);1<c&&--c;return c<1/6?a+6*(b-a)*c:.5>c?b:c<2/3?a+6*(b-a)*(2/3-c):a}function bg(a){return.04045>a?.0773993808*a:Math.pow(.9478672986*a+.0521327014,2.4)}function cg(a){return.0031308>a?12.92*a:1.055*Math.pow(a,.41666)-.055}function yc(a,b,c,d,e,f){this.a=a;this.b=
|
|
|
+0);this.constant=void 0!==b?b:0}function va(a,b,c){this.a=void 0!==a?a:new m;this.b=void 0!==b?b:new m;this.c=void 0!==c?c:new m}function D(a,b,c){return void 0===b&&void 0===c?this.set(a):this.setRGB(a,b,c)}function ag(a,b,c){0>c&&(c+=1);1<c&&--c;return c<1/6?a+6*(b-a)*c:.5>c?b:c<2/3?a+6*(b-a)*(2/3-c):a}function bg(a){return.04045>a?.0773993808*a:Math.pow(.9478672986*a+.0521327014,2.4)}function cg(a){return.0031308>a?12.92*a:1.055*Math.pow(a,.41666)-.055}function yc(a,b,c,d,e,f){this.a=a;this.b=
|
|
|
b;this.c=c;this.normal=d&&d.isVector3?d:new m;this.vertexNormals=Array.isArray(d)?d:[];this.color=e&&e.isColor?e:new D;this.vertexColors=Array.isArray(e)?e:[];this.materialIndex=void 0!==f?f:0}function K(){Object.defineProperty(this,"id",{value:hj++});this.uuid=L.generateUUID();this.name="";this.type="Material";this.fog=!0;this.blending=1;this.side=0;this.vertexColors=this.flatShading=!1;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.stencilWriteMask=255;this.stencilFunc=519;this.stencilRef=0;this.stencilFuncMask=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.version=0}function Na(a){K.call(this);this.type="MeshBasicMaterial";this.color=new D(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.morphTargets=this.skinning=!1;this.setValues(a)}
|
|
@@ -16,9 +16,9 @@ b,c)}function Wb(a,b,c){G.call(this,new Uint16Array(a),b,c)}function Bd(a,b,c){G
|
|
|
this.uvsNeedUpdate=this.colorsNeedUpdate=this.normalsNeedUpdate=this.verticesNeedUpdate=!1}function uh(a){if(0===a.length)return-Infinity;for(var b=a[0],c=1,d=a.length;c<d;++c)a[c]>b&&(b=a[c]);return b}function F(){Object.defineProperty(this,"id",{value:ij+=2});this.uuid=L.generateUUID();this.name="";this.type="BufferGeometry";this.index=null;this.attributes={};this.morphAttributes={};this.morphTargetsRelative=!1;this.groups=[];this.boundingSphere=this.boundingBox=null;this.drawRange={start:0,count:Infinity};
|
|
|
this.userData={}}function U(a,b){y.call(this);this.type="Mesh";this.geometry=void 0!==a?a:new F;this.material=void 0!==b?b:new Na;this.updateMorphTargets()}function vh(a,b,c,d,e,f,g,h){if(null===(1===b.side?d.intersectTriangle(g,f,e,!0,h):d.intersectTriangle(e,f,g,2!==b.side,h)))return null;Ee.copy(h);Ee.applyMatrix4(a.matrixWorld);b=c.ray.origin.distanceTo(Ee);return b<c.near||b>c.far?null:{distance:b,point:Ee.clone(),object:a}}function Fe(a,b,c,d,e,f,g,h,l,n,t,p){Bb.fromBufferAttribute(e,n);Cb.fromBufferAttribute(e,
|
|
|
t);Db.fromBufferAttribute(e,p);e=a.morphTargetInfluences;if(b.morphTargets&&f&&e){Ge.set(0,0,0);He.set(0,0,0);Ie.set(0,0,0);for(var u=0,r=f.length;u<r;u++){var k=e[u],v=f[u];0!==k&&(dg.fromBufferAttribute(v,n),eg.fromBufferAttribute(v,t),fg.fromBufferAttribute(v,p),g?(Ge.addScaledVector(dg,k),He.addScaledVector(eg,k),Ie.addScaledVector(fg,k)):(Ge.addScaledVector(dg.sub(Bb),k),He.addScaledVector(eg.sub(Cb),k),Ie.addScaledVector(fg.sub(Db),k)))}Bb.add(Ge);Cb.add(He);Db.add(Ie)}a.isSkinnedMesh&&(a.boneTransform(n,
|
|
|
-Bb),a.boneTransform(t,Cb),a.boneTransform(p,Db));if(a=vh(a,b,c,d,Bb,Cb,Db,Dd))h&&(zc.fromBufferAttribute(h,n),Ac.fromBufferAttribute(h,t),Bc.fromBufferAttribute(h,p),a.uv=oa.getUV(Dd,Bb,Cb,Db,zc,Ac,Bc,new w)),l&&(zc.fromBufferAttribute(l,n),Ac.fromBufferAttribute(l,t),Bc.fromBufferAttribute(l,p),a.uv2=oa.getUV(Dd,Bb,Cb,Db,zc,Ac,Bc,new w)),h=new yc(n,t,p),oa.getNormal(Bb,Cb,Db,h.normal),a.face=h;return a}function H(){Object.defineProperty(this,"id",{value:jj+=2});this.uuid=L.generateUUID();this.name=
|
|
|
+Bb),a.boneTransform(t,Cb),a.boneTransform(p,Db));if(a=vh(a,b,c,d,Bb,Cb,Db,Dd))h&&(zc.fromBufferAttribute(h,n),Ac.fromBufferAttribute(h,t),Bc.fromBufferAttribute(h,p),a.uv=va.getUV(Dd,Bb,Cb,Db,zc,Ac,Bc,new w)),l&&(zc.fromBufferAttribute(l,n),Ac.fromBufferAttribute(l,t),Bc.fromBufferAttribute(l,p),a.uv2=va.getUV(Dd,Bb,Cb,Db,zc,Ac,Bc,new w)),h=new yc(n,t,p),va.getNormal(Bb,Cb,Db,h.normal),a.face=h;return a}function H(){Object.defineProperty(this,"id",{value:jj+=2});this.uuid=L.generateUUID();this.name=
|
|
|
"";this.type="Geometry";this.vertices=[];this.colors=[];this.faces=[];this.faceVertexUvs=[[]];this.morphTargets=[];this.morphNormals=[];this.skinWeights=[];this.skinIndices=[];this.lineDistances=[];this.boundingSphere=this.boundingBox=null;this.groupsNeedUpdate=this.lineDistancesNeedUpdate=this.colorsNeedUpdate=this.normalsNeedUpdate=this.uvsNeedUpdate=this.verticesNeedUpdate=this.elementsNeedUpdate=!1}function Cc(a){var b={},c;for(c in a){b[c]={};for(var d in a[c]){var e=a[c][d];e&&(e.isColor||e.isMatrix3||
|
|
|
-e.isMatrix4||e.isVector2||e.isVector3||e.isVector4||e.isTexture)?b[c][d]=e.clone():Array.isArray(e)?b[c][d]=e.slice():b[c][d]=e}}return b}function va(a){for(var b={},c=0;c<a.length;c++){var d=Cc(a[c]),e;for(e in d)b[e]=d[e]}return b}function Aa(a){K.call(this);this.type="ShaderMaterial";this.defines={};this.uniforms={};this.vertexShader="void main() {\n\tgl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );\n}";this.fragmentShader="void main() {\n\tgl_FragColor = vec4( 1.0, 0.0, 0.0, 1.0 );\n}";
|
|
|
+e.isMatrix4||e.isVector2||e.isVector3||e.isVector4||e.isTexture)?b[c][d]=e.clone():Array.isArray(e)?b[c][d]=e.slice():b[c][d]=e}}return b}function ua(a){for(var b={},c=0;c<a.length;c++){var d=Cc(a[c]),e;for(e in d)b[e]=d[e]}return b}function Aa(a){K.call(this);this.type="ShaderMaterial";this.defines={};this.uniforms={};this.vertexShader="void main() {\n\tgl_Position = projectionMatrix * modelViewMatrix * vec4( position, 1.0 );\n}";this.fragmentShader="void main() {\n\tgl_FragColor = vec4( 1.0, 0.0, 0.0, 1.0 );\n}";
|
|
|
this.linewidth=1;this.wireframe=!1;this.wireframeLinewidth=1;this.morphNormals=this.morphTargets=this.skinning=this.clipping=this.lights=this.fog=!1;this.extensions={derivatives:!1,fragDepth:!1,drawBuffers:!1,shaderTextureLOD:!1};this.defaultAttributeValues={color:[1,1,1],uv:[0,0],uv2:[0,0]};this.index0AttributeName=void 0;this.uniformsNeedUpdate=!1;void 0!==a&&(void 0!==a.attributes&&console.error("THREE.ShaderMaterial: attributes should now be defined in THREE.BufferGeometry instead."),this.setValues(a))}
|
|
|
function eb(){y.call(this);this.type="Camera";this.matrixWorldInverse=new M;this.projectionMatrix=new M;this.projectionMatrixInverse=new M}function T(a,b,c,d){eb.call(this);this.type="PerspectiveCamera";this.fov=void 0!==a?a:50;this.zoom=1;this.near=void 0!==c?c:.1;this.far=void 0!==d?d:2E3;this.focus=10;this.aspect=void 0!==b?b:1;this.view=null;this.filmGauge=35;this.filmOffset=0;this.updateProjectionMatrix()}function Dc(a,b,c){y.call(this);this.type="CubeCamera";if(!0!==c.isWebGLCubeRenderTarget)console.error("THREE.CubeCamera: The constructor now expects an instance of WebGLCubeRenderTarget as third parameter.");
|
|
|
else{this.renderTarget=c;var d=new T(90,1,a,b);d.layers=this.layers;d.up.set(0,-1,0);d.lookAt(new m(1,0,0));this.add(d);var e=new T(90,1,a,b);e.layers=this.layers;e.up.set(0,-1,0);e.lookAt(new m(-1,0,0));this.add(e);var f=new T(90,1,a,b);f.layers=this.layers;f.up.set(0,0,1);f.lookAt(new m(0,1,0));this.add(f);var g=new T(90,1,a,b);g.layers=this.layers;g.up.set(0,0,-1);g.lookAt(new m(0,-1,0));this.add(g);var h=new T(90,1,a,b);h.layers=this.layers;h.up.set(0,-1,0);h.lookAt(new m(0,0,1));this.add(h);
|
|
@@ -30,8 +30,8 @@ a},setContext:function(a){b=a}}}function kj(a,b){function c(b,c){var d=b.array,e
|
|
|
f.buffer);-1===n.count?a.bufferSubData(g,0,l):(d?a.bufferSubData(g,n.offset*l.BYTES_PER_ELEMENT,l,n.offset,n.count):a.bufferSubData(g,n.offset*l.BYTES_PER_ELEMENT,l.subarray(n.offset,n.offset+n.count)),n.count=-1);f.version=b.version}}}}function Ed(a,b,c,d){H.call(this);this.type="PlaneGeometry";this.parameters={width:a,height:b,widthSegments:c,heightSegments:d};this.fromBufferGeometry(new $b(a,b,c,d));this.mergeVertices()}function $b(a,b,c,d){F.call(this);this.type="PlaneBufferGeometry";this.parameters=
|
|
|
{width:a,height:b,widthSegments:c,heightSegments:d};a=a||1;b=b||1;var e=a/2,f=b/2;c=Math.floor(c)||1;d=Math.floor(d)||1;var g=c+1,h=d+1,l=a/c,n=b/d;b=[];a=[];for(var t=[],p=[],k=0;k<h;k++)for(var r=k*n-f,q=0;q<g;q++)a.push(q*l-e,-r,0),t.push(0,0,1),p.push(q/c),p.push(1-k/d);for(e=0;e<d;e++)for(f=0;f<c;f++)h=f+g*(e+1),l=f+1+g*(e+1),n=f+1+g*e,b.push(f+g*e,h,n),b.push(h,l,n);this.setIndex(b);this.setAttribute("position",new B(a,3));this.setAttribute("normal",new B(t,3));this.setAttribute("uv",new B(p,
|
|
|
2))}function lj(a,b,c,d){function e(a,c){b.buffers.color.setClear(a.r,a.g,a.b,c,d)}var f=new D(0),g=0,h,l,n=null,t=0,p=null;return{getClearColor:function(){return f},setClearColor:function(a,b){f.set(a);g=void 0!==b?b:1;e(f,g)},getClearAlpha:function(){return g},setClearAlpha:function(a){g=a;e(f,g)},render:function(b,d,k,v){d=!0===d.isScene?d.background:null;k=a.xr;(k=k.getSession&&k.getSession())&&"additive"===k.environmentBlendMode&&(d=null);null===d?e(f,g):d&&d.isColor&&(e(d,1),v=!0);(a.autoClear||
|
|
|
-v)&&a.clear(a.autoClearColor,a.autoClearDepth,a.autoClearStencil);if(d&&(d.isCubeTexture||d.isWebGLCubeRenderTarget||306===d.mapping)){void 0===l&&(l=new U(new Fd(1,1,1),new Aa({type:"BackgroundCubeMaterial",uniforms:Cc(fb.cube.uniforms),vertexShader:fb.cube.vertexShader,fragmentShader:fb.cube.fragmentShader,side:1,depthTest:!1,depthWrite:!1,fog:!1})),l.geometry.deleteAttribute("normal"),l.geometry.deleteAttribute("uv"),l.onBeforeRender=function(a,b,c){this.matrixWorld.copyPosition(c.matrixWorld)},
|
|
|
-Object.defineProperty(l.material,"envMap",{get:function(){return this.uniforms.envMap.value}}),c.update(l));v=d.isWebGLCubeRenderTarget?d.texture:d;l.material.uniforms.envMap.value=v;l.material.uniforms.flipEnvMap.value=v.isCubeTexture?-1:1;if(n!==d||t!==v.version||p!==a.toneMapping)l.material.needsUpdate=!0,n=d,t=v.version,p=a.toneMapping;b.unshift(l,l.geometry,l.material,0,0,null)}else if(d&&d.isTexture){void 0===h&&(h=new U(new $b(2,2),new Aa({type:"BackgroundMaterial",uniforms:Cc(fb.background.uniforms),
|
|
|
+v)&&a.clear(a.autoClearColor,a.autoClearDepth,a.autoClearStencil);if(d&&(d.isCubeTexture||d.isWebGLCubeRenderTarget||306===d.mapping)){void 0===l&&(l=new U(new Fd(1,1,1),new Aa({name:"BackgroundCubeMaterial",uniforms:Cc(fb.cube.uniforms),vertexShader:fb.cube.vertexShader,fragmentShader:fb.cube.fragmentShader,side:1,depthTest:!1,depthWrite:!1,fog:!1})),l.geometry.deleteAttribute("normal"),l.geometry.deleteAttribute("uv"),l.onBeforeRender=function(a,b,c){this.matrixWorld.copyPosition(c.matrixWorld)},
|
|
|
+Object.defineProperty(l.material,"envMap",{get:function(){return this.uniforms.envMap.value}}),c.update(l));v=d.isWebGLCubeRenderTarget?d.texture:d;l.material.uniforms.envMap.value=v;l.material.uniforms.flipEnvMap.value=v.isCubeTexture?-1:1;if(n!==d||t!==v.version||p!==a.toneMapping)l.material.needsUpdate=!0,n=d,t=v.version,p=a.toneMapping;b.unshift(l,l.geometry,l.material,0,0,null)}else if(d&&d.isTexture){void 0===h&&(h=new U(new $b(2,2),new Aa({name:"BackgroundMaterial",uniforms:Cc(fb.background.uniforms),
|
|
|
vertexShader:fb.background.vertexShader,fragmentShader:fb.background.fragmentShader,side:0,depthTest:!1,depthWrite:!1,fog:!1})),h.geometry.deleteAttribute("normal"),Object.defineProperty(h.material,"map",{get:function(){return this.uniforms.t2D.value}}),c.update(h));h.material.uniforms.t2D.value=d;!0===d.matrixAutoUpdate&&d.updateMatrix();h.material.uniforms.uvTransform.value.copy(d.matrix);if(n!==d||t!==d.version||p!==a.toneMapping)h.material.needsUpdate=!0,n=d,t=d.version,p=a.toneMapping;b.unshift(h,
|
|
|
h.geometry,h.material,0,0,null)}}}}function mj(a,b,c,d){var e=d.isWebGL2,f;this.setMode=function(a){f=a};this.render=function(b,d){a.drawArrays(f,b,d);c.update(d,f)};this.renderInstances=function(d,h,l,n){if(0!==n){if(e){d=a;var g="drawArraysInstanced"}else if(d=b.get("ANGLE_instanced_arrays"),g="drawArraysInstancedANGLE",null===d){console.error("THREE.WebGLBufferRenderer: using THREE.InstancedBufferGeometry but hardware does not support extension ANGLE_instanced_arrays.");return}d[g](f,h,l,n);c.update(l,
|
|
|
f,n)}}}function nj(a,b,c){function d(b){if("highp"===b){if(0<a.getShaderPrecisionFormat(35633,36338).precision&&0<a.getShaderPrecisionFormat(35632,36338).precision)return"highp";b="mediump"}return"mediump"===b&&0<a.getShaderPrecisionFormat(35633,36337).precision&&0<a.getShaderPrecisionFormat(35632,36337).precision?"mediump":"lowp"}var e,f="undefined"!==typeof WebGL2RenderingContext&&a instanceof WebGL2RenderingContext||"undefined"!==typeof WebGL2ComputeRenderingContext&&a instanceof WebGL2ComputeRenderingContext,
|
|
@@ -60,33 +60,32 @@ b,c){var d=b.length,e=yh(c,d);a.uniform1iv(this.addr,e);for(a=0;a!==d;++a)c.safe
|
|
|
case 35678:case 36198:case 36298:case 36306:case 35682:return ak;case 35680:case 36300:case 36308:case 36293:return bk}}function dk(a,b,c){this.id=a;this.addr=c;this.cache=[];this.setValue=Oj(b.type)}function Fh(a,b,c){this.id=a;this.addr=c;this.cache=[];this.size=b.size;this.setValue=ck(b.type)}function Gh(a){this.id=a;this.seq=[];this.map={}}function Eb(a,b){this.seq=[];this.map={};for(var c=a.getProgramParameter(b,35718),d=0;d<c;++d){var e=a.getActiveUniform(b,d),f=a.getUniformLocation(b,e.name),
|
|
|
g=this,h=e.name,l=h.length;for(gg.lastIndex=0;;){var n=gg.exec(h),t=gg.lastIndex,p=n[1],k=n[3];"]"===n[2]&&(p|=0);if(void 0===k||"["===k&&t+2===l){h=g;e=void 0===k?new dk(p,e,f):new Fh(p,e,f);h.seq.push(e);h.map[e.id]=e;break}else k=g.map[p],void 0===k&&(k=new Gh(p),p=g,g=k,p.seq.push(g),p.map[g.id]=g),g=k}}}function Hh(a,b,c){b=a.createShader(b);a.shaderSource(b,c);a.compileShader(b);return b}function Ih(a){switch(a){case 3E3:return["Linear","( value )"];case 3001:return["sRGB","( value )"];case 3002:return["RGBE",
|
|
|
"( value )"];case 3004:return["RGBM","( value, 7.0 )"];case 3005:return["RGBM","( value, 16.0 )"];case 3006:return["RGBD","( value, 256.0 )"];case 3007:return["Gamma","( value, float( GAMMA_FACTOR ) )"];case 3003:return["LogLuv","( value )"];default:throw Error("unsupported encoding: "+a);}}function Jh(a,b,c){var d=a.getShaderParameter(b,35713),e=a.getShaderInfoLog(b).trim();if(d&&""===e)return"";a=a.getShaderSource(b).split("\n");for(b=0;b<a.length;b++)a[b]=b+1+": "+a[b];a=a.join("\n");return"THREE.WebGLShader: gl.getShaderInfoLog() "+
|
|
|
-c+"\n"+e+a}function Gd(a,b){b=Ih(b);return"vec4 "+a+"( vec4 value ) { return "+b[0]+"ToLinear"+b[1]+"; }"}function ek(a,b){b=Ih(b);return"vec4 "+a+"( vec4 value ) { return LinearTo"+b[0]+b[1]+"; }"}function fk(a,b){switch(b){case 1:b="Linear";break;case 2:b="Reinhard";break;case 3:b="Uncharted2";break;case 4:b="OptimizedCineon";break;case 5:b="ACESFilmic";break;default:throw Error("unsupported toneMapping: "+b);}return"vec3 "+a+"( vec3 color ) { return "+b+"ToneMapping( color ); }"}function gk(a){var b=
|
|
|
-[],c;for(c in a){var d=a[c];!1!==d&&b.push("#define "+c+" "+d)}return b.join("\n")}function Hd(a){return""!==a}function Kh(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).replace(/NUM_DIR_LIGHT_SHADOWS/g,b.numDirLightShadows).replace(/NUM_SPOT_LIGHT_SHADOWS/g,b.numSpotLightShadows).replace(/NUM_POINT_LIGHT_SHADOWS/g,
|
|
|
-b.numPointLightShadows)}function Lh(a,b){return a.replace(/NUM_CLIPPING_PLANES/g,b.numClippingPlanes).replace(/UNION_CLIPPING_PLANES/g,b.numClippingPlanes-b.numClipIntersection)}function hg(a,b){a=Q[b];if(void 0===a)throw Error("Can not resolve #include <"+b+">");return a.replace(ig,hg)}function Mh(a,b,c,d){console.warn("WebGLProgram: #pragma unroll_loop shader syntax is deprecated. Please use #pragma unroll_loop_start syntax instead.");return jg(a,b,c,d)}function jg(a,b,c,d){a="";for(b=parseInt(b);b<
|
|
|
-parseInt(c);b++)a+=d.replace(/\[ i \]/g,"[ "+b+" ]").replace(/UNROLLED_LOOP_INDEX/g,b);return a}function Nh(a){var b="precision "+a.precision+" float;\nprecision "+a.precision+" int;";"highp"===a.precision?b+="\n#define HIGH_PRECISION":"mediump"===a.precision?b+="\n#define MEDIUM_PRECISION":"lowp"===a.precision&&(b+="\n#define LOW_PRECISION");return b}function hk(a){var b="SHADOWMAP_TYPE_BASIC";1===a.shadowMapType?b="SHADOWMAP_TYPE_PCF":2===a.shadowMapType?b="SHADOWMAP_TYPE_PCF_SOFT":3===a.shadowMapType&&
|
|
|
-(b="SHADOWMAP_TYPE_VSM");return b}function ik(a){var b="ENVMAP_TYPE_CUBE";if(a.envMap)switch(a.envMapMode){case 301:case 302:b="ENVMAP_TYPE_CUBE";break;case 306:case 307:b="ENVMAP_TYPE_CUBE_UV";break;case 303:case 304:b="ENVMAP_TYPE_EQUIREC"}return b}function jk(a){var b="ENVMAP_MODE_REFLECTION";if(a.envMap)switch(a.envMapMode){case 302:case 304:b="ENVMAP_MODE_REFRACTION"}return b}function kk(a){var b="ENVMAP_BLENDING_NONE";if(a.envMap)switch(a.combine){case 0:b="ENVMAP_BLENDING_MULTIPLY";break;case 1:b=
|
|
|
-"ENVMAP_BLENDING_MIX";break;case 2:b="ENVMAP_BLENDING_ADD"}return b}function lk(a,b,c){var d=a.getContext(),e=c.defines,f=c.vertexShader,g=c.fragmentShader,h=hk(c),l=ik(c),n=jk(c),t=kk(c),p=0<a.gammaFactor?a.gammaFactor:1,k=c.isWebGL2?"":[c.extensionDerivatives||c.envMapCubeUV||c.bumpMap||c.tangentSpaceNormalMap||c.clearcoatNormalMap||c.flatShading||"physical"===c.shaderID?"#extension GL_OES_standard_derivatives : enable":"",(c.extensionFragDepth||c.logarithmicDepthBuffer)&&c.rendererExtensionFragDepth?
|
|
|
-"#extension GL_EXT_frag_depth : enable":"",c.extensionDrawBuffers&&c.rendererExtensionDrawBuffers?"#extension GL_EXT_draw_buffers : require":"",(c.extensionShaderTextureLOD||c.envMap)&&c.rendererExtensionShaderTextureLod?"#extension GL_EXT_shader_texture_lod : enable":""].filter(Hd).join("\n"),r=gk(e),q=d.createProgram();c.isRawShaderMaterial?(e=[r].filter(Hd).join("\n"),0<e.length&&(e+="\n"),h=[k,r].filter(Hd).join("\n"),0<h.length&&(h+="\n")):(e=[Nh(c),"#define SHADER_NAME "+c.shaderName,r,c.instancing?
|
|
|
-"#define USE_INSTANCING":"",c.supportsVertexTextures?"#define VERTEX_TEXTURES":"","#define GAMMA_FACTOR "+p,"#define MAX_BONES "+c.maxBones,c.useFog&&c.fog?"#define USE_FOG":"",c.useFog&&c.fogExp2?"#define FOG_EXP2":"",c.map?"#define USE_MAP":"",c.envMap?"#define USE_ENVMAP":"",c.envMap?"#define "+n:"",c.lightMap?"#define USE_LIGHTMAP":"",c.aoMap?"#define USE_AOMAP":"",c.emissiveMap?"#define USE_EMISSIVEMAP":"",c.bumpMap?"#define USE_BUMPMAP":"",c.normalMap?"#define USE_NORMALMAP":"",c.normalMap&&
|
|
|
-c.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",c.normalMap&&c.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",c.clearcoatMap?"#define USE_CLEARCOATMAP":"",c.clearcoatRoughnessMap?"#define USE_CLEARCOAT_ROUGHNESSMAP":"",c.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",c.displacementMap&&c.supportsVertexTextures?"#define USE_DISPLACEMENTMAP":"",c.specularMap?"#define USE_SPECULARMAP":"",c.roughnessMap?"#define USE_ROUGHNESSMAP":"",c.metalnessMap?"#define USE_METALNESSMAP":
|
|
|
-"",c.alphaMap?"#define USE_ALPHAMAP":"",c.vertexTangents?"#define USE_TANGENT":"",c.vertexColors?"#define USE_COLOR":"",c.vertexUvs?"#define USE_UV":"",c.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",c.flatShading?"#define FLAT_SHADED":"",c.skinning?"#define USE_SKINNING":"",c.useVertexTexture?"#define BONE_TEXTURE":"",c.morphTargets?"#define USE_MORPHTARGETS":"",c.morphNormals&&!1===c.flatShading?"#define USE_MORPHNORMALS":"",c.doubleSided?"#define DOUBLE_SIDED":"",c.flipSided?"#define FLIP_SIDED":
|
|
|
-"",c.shadowMapEnabled?"#define USE_SHADOWMAP":"",c.shadowMapEnabled?"#define "+h:"",c.sizeAttenuation?"#define USE_SIZEATTENUATION":"",c.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",c.logarithmicDepthBuffer&&c.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"","uniform mat4 modelMatrix;","uniform mat4 modelViewMatrix;","uniform mat4 projectionMatrix;","uniform mat4 viewMatrix;","uniform mat3 normalMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;","#ifdef USE_INSTANCING",
|
|
|
-" attribute mat4 instanceMatrix;","#endif","attribute vec3 position;","attribute vec3 normal;","attribute vec2 uv;","#ifdef USE_TANGENT","\tattribute vec4 tangent;","#endif","#ifdef USE_COLOR","\tattribute vec3 color;","#endif","#ifdef USE_MORPHTARGETS","\tattribute vec3 morphTarget0;","\tattribute vec3 morphTarget1;","\tattribute vec3 morphTarget2;","\tattribute vec3 morphTarget3;","\t#ifdef USE_MORPHNORMALS","\t\tattribute vec3 morphNormal0;","\t\tattribute vec3 morphNormal1;","\t\tattribute vec3 morphNormal2;",
|
|
|
-"\t\tattribute vec3 morphNormal3;","\t#else","\t\tattribute vec3 morphTarget4;","\t\tattribute vec3 morphTarget5;","\t\tattribute vec3 morphTarget6;","\t\tattribute vec3 morphTarget7;","\t#endif","#endif","#ifdef USE_SKINNING","\tattribute vec4 skinIndex;","\tattribute vec4 skinWeight;","#endif","\n"].filter(Hd).join("\n"),h=[k,Nh(c),"#define SHADER_NAME "+c.shaderName,r,c.alphaTest?"#define ALPHATEST "+c.alphaTest+(c.alphaTest%1?"":".0"):"","#define GAMMA_FACTOR "+p,c.useFog&&c.fog?"#define USE_FOG":
|
|
|
-"",c.useFog&&c.fogExp2?"#define FOG_EXP2":"",c.map?"#define USE_MAP":"",c.matcap?"#define USE_MATCAP":"",c.envMap?"#define USE_ENVMAP":"",c.envMap?"#define "+l:"",c.envMap?"#define "+n:"",c.envMap?"#define "+t:"",c.lightMap?"#define USE_LIGHTMAP":"",c.aoMap?"#define USE_AOMAP":"",c.emissiveMap?"#define USE_EMISSIVEMAP":"",c.bumpMap?"#define USE_BUMPMAP":"",c.normalMap?"#define USE_NORMALMAP":"",c.normalMap&&c.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",c.normalMap&&c.tangentSpaceNormalMap?
|
|
|
-"#define TANGENTSPACE_NORMALMAP":"",c.clearcoatMap?"#define USE_CLEARCOATMAP":"",c.clearcoatRoughnessMap?"#define USE_CLEARCOAT_ROUGHNESSMAP":"",c.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",c.specularMap?"#define USE_SPECULARMAP":"",c.roughnessMap?"#define USE_ROUGHNESSMAP":"",c.metalnessMap?"#define USE_METALNESSMAP":"",c.alphaMap?"#define USE_ALPHAMAP":"",c.sheen?"#define USE_SHEEN":"",c.vertexTangents?"#define USE_TANGENT":"",c.vertexColors?"#define USE_COLOR":"",c.vertexUvs?"#define USE_UV":
|
|
|
-"",c.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",c.gradientMap?"#define USE_GRADIENTMAP":"",c.flatShading?"#define FLAT_SHADED":"",c.doubleSided?"#define DOUBLE_SIDED":"",c.flipSided?"#define FLIP_SIDED":"",c.shadowMapEnabled?"#define USE_SHADOWMAP":"",c.shadowMapEnabled?"#define "+h:"",c.premultipliedAlpha?"#define PREMULTIPLIED_ALPHA":"",c.physicallyCorrectLights?"#define PHYSICALLY_CORRECT_LIGHTS":"",c.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",c.logarithmicDepthBuffer&&c.rendererExtensionFragDepth?
|
|
|
-"#define USE_LOGDEPTHBUF_EXT":"",(c.extensionShaderTextureLOD||c.envMap)&&c.rendererExtensionShaderTextureLod?"#define TEXTURE_LOD_EXT":"","uniform mat4 viewMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;",0!==c.toneMapping?"#define TONE_MAPPING":"",0!==c.toneMapping?Q.tonemapping_pars_fragment:"",0!==c.toneMapping?fk("toneMapping",c.toneMapping):"",c.dithering?"#define DITHERING":"",c.outputEncoding||c.mapEncoding||c.matcapEncoding||c.envMapEncoding||c.emissiveMapEncoding||
|
|
|
-c.lightMapEncoding?Q.encodings_pars_fragment:"",c.mapEncoding?Gd("mapTexelToLinear",c.mapEncoding):"",c.matcapEncoding?Gd("matcapTexelToLinear",c.matcapEncoding):"",c.envMapEncoding?Gd("envMapTexelToLinear",c.envMapEncoding):"",c.emissiveMapEncoding?Gd("emissiveMapTexelToLinear",c.emissiveMapEncoding):"",c.lightMapEncoding?Gd("lightMapTexelToLinear",c.lightMapEncoding):"",c.outputEncoding?ek("linearToOutputTexel",c.outputEncoding):"",c.depthPacking?"#define DEPTH_PACKING "+c.depthPacking:"","\n"].filter(Hd).join("\n"));
|
|
|
-f=f.replace(ig,hg);f=Kh(f,c);f=Lh(f,c);g=g.replace(ig,hg);g=Kh(g,c);g=Lh(g,c);f=f.replace(Oh,jg).replace(Ph,Mh);g=g.replace(Oh,jg).replace(Ph,Mh);c.isWebGL2&&!c.isRawShaderMaterial&&(l=!1,n=/^\s*#version\s+300\s+es\s*\n/,c.isShaderMaterial&&null!==f.match(n)&&null!==g.match(n)&&(l=!0,f=f.replace(n,""),g=g.replace(n,"")),e="#version 300 es\n\n#define attribute in\n#define varying out\n#define texture2D texture\n"+e,h=["#version 300 es\n\n#define varying in",l?"":"out highp vec4 pc_fragColor;",l?"":
|
|
|
-"#define gl_FragColor pc_fragColor","#define gl_FragDepthEXT gl_FragDepth\n#define texture2D texture\n#define textureCube texture\n#define texture2DProj textureProj\n#define texture2DLodEXT textureLod\n#define texture2DProjLodEXT textureProjLod\n#define textureCubeLodEXT textureLod\n#define texture2DGradEXT textureGrad\n#define texture2DProjGradEXT textureProjGrad\n#define textureCubeGradEXT textureGrad"].join("\n")+"\n"+h);g=h+g;f=Hh(d,35633,e+f);g=Hh(d,35632,g);d.attachShader(q,f);d.attachShader(q,
|
|
|
-g);void 0!==c.index0AttributeName?d.bindAttribLocation(q,0,c.index0AttributeName):!0===c.morphTargets&&d.bindAttribLocation(q,0,"position");d.linkProgram(q);if(a.debug.checkShaderErrors){a=d.getProgramInfoLog(q).trim();l=d.getShaderInfoLog(f).trim();n=d.getShaderInfoLog(g).trim();p=t=!0;if(!1===d.getProgramParameter(q,35714))t=!1,k=Jh(d,f,"vertex"),r=Jh(d,g,"fragment"),console.error("THREE.WebGLProgram: shader error: ",d.getError(),"35715",d.getProgramParameter(q,35715),"gl.getProgramInfoLog",a,k,
|
|
|
-r);else if(""!==a)console.warn("THREE.WebGLProgram: gl.getProgramInfoLog()",a);else if(""===l||""===n)p=!1;p&&(this.diagnostics={runnable:t,programLog:a,vertexShader:{log:l,prefix:e},fragmentShader:{log:n,prefix:h}})}d.deleteShader(f);d.deleteShader(g);var v;this.getUniforms=function(){void 0===v&&(v=new Eb(d,q));return v};var m;this.getAttributes=function(){if(void 0===m){for(var a={},b=d.getProgramParameter(q,35721),c=0;c<b;c++){var e=d.getActiveAttrib(q,c).name;a[e]=d.getAttribLocation(q,e)}m=
|
|
|
-a}return m};this.destroy=function(){d.deleteProgram(q);this.program=void 0};this.name=c.shaderName;this.id=mk++;this.cacheKey=b;this.usedTimes=1;this.program=q;this.vertexShader=f;this.fragmentShader=g;return this}function nk(a,b,c){function d(a){if(a)a.isTexture?b=a.encoding:a.isWebGLRenderTarget&&(console.warn("THREE.WebGLPrograms.getTextureEncodingFromMap: don't use render targets as textures. Use their .texture property instead."),b=a.texture.encoding);else var b=3E3;return b}var e=[],f=c.isWebGL2,
|
|
|
-g=c.logarithmicDepthBuffer,h=c.floatVertexTextures,l=c.maxVertexUniforms,n=c.vertexTextures,t=c.precision,p={MeshDepthMaterial:"depth",MeshDistanceMaterial:"distanceRGBA",MeshNormalMaterial:"normal",MeshBasicMaterial:"basic",MeshLambertMaterial:"lambert",MeshPhongMaterial:"phong",MeshToonMaterial:"toon",MeshStandardMaterial:"physical",MeshPhysicalMaterial:"physical",MeshMatcapMaterial:"matcap",LineBasicMaterial:"basic",LineDashedMaterial:"dashed",PointsMaterial:"points",ShadowMaterial:"shadow",SpriteMaterial:"sprite"},
|
|
|
-k="precision isWebGL2 supportsVertexTextures outputEncoding instancing map mapEncoding matcap matcapEncoding envMap envMapMode envMapEncoding envMapCubeUV lightMap lightMapEncoding aoMap emissiveMap emissiveMapEncoding bumpMap normalMap objectSpaceNormalMap tangentSpaceNormalMap clearcoatMap clearcoatRoughnessMap clearcoatNormalMap displacementMap specularMap roughnessMap metalnessMap gradientMap alphaMap combine vertexColors vertexTangents vertexUvs uvsVertexOnly fog useFog fogExp2 flatShading sizeAttenuation logarithmicDepthBuffer skinning maxBones useVertexTexture morphTargets morphNormals maxMorphTargets maxMorphNormals premultipliedAlpha numDirLights numPointLights numSpotLights numHemiLights numRectAreaLights numDirLightShadows numPointLightShadows numSpotLightShadows shadowMapEnabled shadowMapType toneMapping physicallyCorrectLights alphaTest doubleSided flipSided numClippingPlanes numClipIntersection depthPacking dithering sheen".split(" ");
|
|
|
+c+"\n"+e+a}function Gd(a,b){b=Ih(b);return"vec4 "+a+"( vec4 value ) { return "+b[0]+"ToLinear"+b[1]+"; }"}function ek(a,b){b=Ih(b);return"vec4 "+a+"( vec4 value ) { return LinearTo"+b[0]+b[1]+"; }"}function fk(a,b){switch(b){case 1:b="Linear";break;case 2:b="Reinhard";break;case 3:b="OptimizedCineon";break;case 4:b="ACESFilmic";break;default:throw Error("unsupported toneMapping: "+b);}return"vec3 "+a+"( vec3 color ) { return "+b+"ToneMapping( color ); }"}function gk(a){var b=[],c;for(c in a){var d=
|
|
|
+a[c];!1!==d&&b.push("#define "+c+" "+d)}return b.join("\n")}function Hd(a){return""!==a}function Kh(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).replace(/NUM_DIR_LIGHT_SHADOWS/g,b.numDirLightShadows).replace(/NUM_SPOT_LIGHT_SHADOWS/g,b.numSpotLightShadows).replace(/NUM_POINT_LIGHT_SHADOWS/g,b.numPointLightShadows)}
|
|
|
+function Lh(a,b){return a.replace(/NUM_CLIPPING_PLANES/g,b.numClippingPlanes).replace(/UNION_CLIPPING_PLANES/g,b.numClippingPlanes-b.numClipIntersection)}function hg(a,b){a=Q[b];if(void 0===a)throw Error("Can not resolve #include <"+b+">");return a.replace(ig,hg)}function Mh(a,b,c,d){console.warn("WebGLProgram: #pragma unroll_loop shader syntax is deprecated. Please use #pragma unroll_loop_start syntax instead.");return jg(a,b,c,d)}function jg(a,b,c,d){a="";for(b=parseInt(b);b<parseInt(c);b++)a+=
|
|
|
+d.replace(/\[ i \]/g,"[ "+b+" ]").replace(/UNROLLED_LOOP_INDEX/g,b);return a}function Nh(a){var b="precision "+a.precision+" float;\nprecision "+a.precision+" int;";"highp"===a.precision?b+="\n#define HIGH_PRECISION":"mediump"===a.precision?b+="\n#define MEDIUM_PRECISION":"lowp"===a.precision&&(b+="\n#define LOW_PRECISION");return b}function hk(a){var b="SHADOWMAP_TYPE_BASIC";1===a.shadowMapType?b="SHADOWMAP_TYPE_PCF":2===a.shadowMapType?b="SHADOWMAP_TYPE_PCF_SOFT":3===a.shadowMapType&&(b="SHADOWMAP_TYPE_VSM");
|
|
|
+return b}function ik(a){var b="ENVMAP_TYPE_CUBE";if(a.envMap)switch(a.envMapMode){case 301:case 302:b="ENVMAP_TYPE_CUBE";break;case 306:case 307:b="ENVMAP_TYPE_CUBE_UV";break;case 303:case 304:b="ENVMAP_TYPE_EQUIREC"}return b}function jk(a){var b="ENVMAP_MODE_REFLECTION";if(a.envMap)switch(a.envMapMode){case 302:case 304:b="ENVMAP_MODE_REFRACTION"}return b}function kk(a){var b="ENVMAP_BLENDING_NONE";if(a.envMap)switch(a.combine){case 0:b="ENVMAP_BLENDING_MULTIPLY";break;case 1:b="ENVMAP_BLENDING_MIX";
|
|
|
+break;case 2:b="ENVMAP_BLENDING_ADD"}return b}function lk(a,b,c){var d=a.getContext(),e=c.defines,f=c.vertexShader,g=c.fragmentShader,h=hk(c),l=ik(c),n=jk(c),t=kk(c),p=0<a.gammaFactor?a.gammaFactor:1,k=c.isWebGL2?"":[c.extensionDerivatives||c.envMapCubeUV||c.bumpMap||c.tangentSpaceNormalMap||c.clearcoatNormalMap||c.flatShading||"physical"===c.shaderID?"#extension GL_OES_standard_derivatives : enable":"",(c.extensionFragDepth||c.logarithmicDepthBuffer)&&c.rendererExtensionFragDepth?"#extension GL_EXT_frag_depth : enable":
|
|
|
+"",c.extensionDrawBuffers&&c.rendererExtensionDrawBuffers?"#extension GL_EXT_draw_buffers : require":"",(c.extensionShaderTextureLOD||c.envMap)&&c.rendererExtensionShaderTextureLod?"#extension GL_EXT_shader_texture_lod : enable":""].filter(Hd).join("\n"),r=gk(e),q=d.createProgram();c.isRawShaderMaterial?(e=[r].filter(Hd).join("\n"),0<e.length&&(e+="\n"),h=[k,r].filter(Hd).join("\n"),0<h.length&&(h+="\n")):(e=[Nh(c),"#define SHADER_NAME "+c.shaderName,r,c.instancing?"#define USE_INSTANCING":"",c.supportsVertexTextures?
|
|
|
+"#define VERTEX_TEXTURES":"","#define GAMMA_FACTOR "+p,"#define MAX_BONES "+c.maxBones,c.useFog&&c.fog?"#define USE_FOG":"",c.useFog&&c.fogExp2?"#define FOG_EXP2":"",c.map?"#define USE_MAP":"",c.envMap?"#define USE_ENVMAP":"",c.envMap?"#define "+n:"",c.lightMap?"#define USE_LIGHTMAP":"",c.aoMap?"#define USE_AOMAP":"",c.emissiveMap?"#define USE_EMISSIVEMAP":"",c.bumpMap?"#define USE_BUMPMAP":"",c.normalMap?"#define USE_NORMALMAP":"",c.normalMap&&c.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":
|
|
|
+"",c.normalMap&&c.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",c.clearcoatMap?"#define USE_CLEARCOATMAP":"",c.clearcoatRoughnessMap?"#define USE_CLEARCOAT_ROUGHNESSMAP":"",c.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",c.displacementMap&&c.supportsVertexTextures?"#define USE_DISPLACEMENTMAP":"",c.specularMap?"#define USE_SPECULARMAP":"",c.roughnessMap?"#define USE_ROUGHNESSMAP":"",c.metalnessMap?"#define USE_METALNESSMAP":"",c.alphaMap?"#define USE_ALPHAMAP":"",c.vertexTangents?
|
|
|
+"#define USE_TANGENT":"",c.vertexColors?"#define USE_COLOR":"",c.vertexUvs?"#define USE_UV":"",c.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",c.flatShading?"#define FLAT_SHADED":"",c.skinning?"#define USE_SKINNING":"",c.useVertexTexture?"#define BONE_TEXTURE":"",c.morphTargets?"#define USE_MORPHTARGETS":"",c.morphNormals&&!1===c.flatShading?"#define USE_MORPHNORMALS":"",c.doubleSided?"#define DOUBLE_SIDED":"",c.flipSided?"#define FLIP_SIDED":"",c.shadowMapEnabled?"#define USE_SHADOWMAP":"",c.shadowMapEnabled?
|
|
|
+"#define "+h:"",c.sizeAttenuation?"#define USE_SIZEATTENUATION":"",c.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",c.logarithmicDepthBuffer&&c.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"","uniform mat4 modelMatrix;","uniform mat4 modelViewMatrix;","uniform mat4 projectionMatrix;","uniform mat4 viewMatrix;","uniform mat3 normalMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;","#ifdef USE_INSTANCING"," attribute mat4 instanceMatrix;","#endif","attribute vec3 position;",
|
|
|
+"attribute vec3 normal;","attribute vec2 uv;","#ifdef USE_TANGENT","\tattribute vec4 tangent;","#endif","#ifdef USE_COLOR","\tattribute vec3 color;","#endif","#ifdef USE_MORPHTARGETS","\tattribute vec3 morphTarget0;","\tattribute vec3 morphTarget1;","\tattribute vec3 morphTarget2;","\tattribute vec3 morphTarget3;","\t#ifdef USE_MORPHNORMALS","\t\tattribute vec3 morphNormal0;","\t\tattribute vec3 morphNormal1;","\t\tattribute vec3 morphNormal2;","\t\tattribute vec3 morphNormal3;","\t#else","\t\tattribute vec3 morphTarget4;",
|
|
|
+"\t\tattribute vec3 morphTarget5;","\t\tattribute vec3 morphTarget6;","\t\tattribute vec3 morphTarget7;","\t#endif","#endif","#ifdef USE_SKINNING","\tattribute vec4 skinIndex;","\tattribute vec4 skinWeight;","#endif","\n"].filter(Hd).join("\n"),h=[k,Nh(c),"#define SHADER_NAME "+c.shaderName,r,c.alphaTest?"#define ALPHATEST "+c.alphaTest+(c.alphaTest%1?"":".0"):"","#define GAMMA_FACTOR "+p,c.useFog&&c.fog?"#define USE_FOG":"",c.useFog&&c.fogExp2?"#define FOG_EXP2":"",c.map?"#define USE_MAP":"",c.matcap?
|
|
|
+"#define USE_MATCAP":"",c.envMap?"#define USE_ENVMAP":"",c.envMap?"#define "+l:"",c.envMap?"#define "+n:"",c.envMap?"#define "+t:"",c.lightMap?"#define USE_LIGHTMAP":"",c.aoMap?"#define USE_AOMAP":"",c.emissiveMap?"#define USE_EMISSIVEMAP":"",c.bumpMap?"#define USE_BUMPMAP":"",c.normalMap?"#define USE_NORMALMAP":"",c.normalMap&&c.objectSpaceNormalMap?"#define OBJECTSPACE_NORMALMAP":"",c.normalMap&&c.tangentSpaceNormalMap?"#define TANGENTSPACE_NORMALMAP":"",c.clearcoatMap?"#define USE_CLEARCOATMAP":
|
|
|
+"",c.clearcoatRoughnessMap?"#define USE_CLEARCOAT_ROUGHNESSMAP":"",c.clearcoatNormalMap?"#define USE_CLEARCOAT_NORMALMAP":"",c.specularMap?"#define USE_SPECULARMAP":"",c.roughnessMap?"#define USE_ROUGHNESSMAP":"",c.metalnessMap?"#define USE_METALNESSMAP":"",c.alphaMap?"#define USE_ALPHAMAP":"",c.sheen?"#define USE_SHEEN":"",c.vertexTangents?"#define USE_TANGENT":"",c.vertexColors?"#define USE_COLOR":"",c.vertexUvs?"#define USE_UV":"",c.uvsVertexOnly?"#define UVS_VERTEX_ONLY":"",c.gradientMap?"#define USE_GRADIENTMAP":
|
|
|
+"",c.flatShading?"#define FLAT_SHADED":"",c.doubleSided?"#define DOUBLE_SIDED":"",c.flipSided?"#define FLIP_SIDED":"",c.shadowMapEnabled?"#define USE_SHADOWMAP":"",c.shadowMapEnabled?"#define "+h:"",c.premultipliedAlpha?"#define PREMULTIPLIED_ALPHA":"",c.physicallyCorrectLights?"#define PHYSICALLY_CORRECT_LIGHTS":"",c.logarithmicDepthBuffer?"#define USE_LOGDEPTHBUF":"",c.logarithmicDepthBuffer&&c.rendererExtensionFragDepth?"#define USE_LOGDEPTHBUF_EXT":"",(c.extensionShaderTextureLOD||c.envMap)&&
|
|
|
+c.rendererExtensionShaderTextureLod?"#define TEXTURE_LOD_EXT":"","uniform mat4 viewMatrix;","uniform vec3 cameraPosition;","uniform bool isOrthographic;",0!==c.toneMapping?"#define TONE_MAPPING":"",0!==c.toneMapping?Q.tonemapping_pars_fragment:"",0!==c.toneMapping?fk("toneMapping",c.toneMapping):"",c.dithering?"#define DITHERING":"",c.outputEncoding||c.mapEncoding||c.matcapEncoding||c.envMapEncoding||c.emissiveMapEncoding||c.lightMapEncoding?Q.encodings_pars_fragment:"",c.mapEncoding?Gd("mapTexelToLinear",
|
|
|
+c.mapEncoding):"",c.matcapEncoding?Gd("matcapTexelToLinear",c.matcapEncoding):"",c.envMapEncoding?Gd("envMapTexelToLinear",c.envMapEncoding):"",c.emissiveMapEncoding?Gd("emissiveMapTexelToLinear",c.emissiveMapEncoding):"",c.lightMapEncoding?Gd("lightMapTexelToLinear",c.lightMapEncoding):"",c.outputEncoding?ek("linearToOutputTexel",c.outputEncoding):"",c.depthPacking?"#define DEPTH_PACKING "+c.depthPacking:"","\n"].filter(Hd).join("\n"));f=f.replace(ig,hg);f=Kh(f,c);f=Lh(f,c);g=g.replace(ig,hg);g=
|
|
|
+Kh(g,c);g=Lh(g,c);f=f.replace(Oh,jg).replace(Ph,Mh);g=g.replace(Oh,jg).replace(Ph,Mh);c.isWebGL2&&!c.isRawShaderMaterial&&(l=!1,n=/^\s*#version\s+300\s+es\s*\n/,c.isShaderMaterial&&null!==f.match(n)&&null!==g.match(n)&&(l=!0,f=f.replace(n,""),g=g.replace(n,"")),e="#version 300 es\n\n#define attribute in\n#define varying out\n#define texture2D texture\n"+e,h=["#version 300 es\n\n#define varying in",l?"":"out highp vec4 pc_fragColor;",l?"":"#define gl_FragColor pc_fragColor","#define gl_FragDepthEXT gl_FragDepth\n#define texture2D texture\n#define textureCube texture\n#define texture2DProj textureProj\n#define texture2DLodEXT textureLod\n#define texture2DProjLodEXT textureProjLod\n#define textureCubeLodEXT textureLod\n#define texture2DGradEXT textureGrad\n#define texture2DProjGradEXT textureProjGrad\n#define textureCubeGradEXT textureGrad"].join("\n")+
|
|
|
+"\n"+h);g=h+g;f=Hh(d,35633,e+f);g=Hh(d,35632,g);d.attachShader(q,f);d.attachShader(q,g);void 0!==c.index0AttributeName?d.bindAttribLocation(q,0,c.index0AttributeName):!0===c.morphTargets&&d.bindAttribLocation(q,0,"position");d.linkProgram(q);if(a.debug.checkShaderErrors){a=d.getProgramInfoLog(q).trim();l=d.getShaderInfoLog(f).trim();n=d.getShaderInfoLog(g).trim();p=t=!0;if(!1===d.getProgramParameter(q,35714))t=!1,k=Jh(d,f,"vertex"),r=Jh(d,g,"fragment"),console.error("THREE.WebGLProgram: shader error: ",
|
|
|
+d.getError(),"35715",d.getProgramParameter(q,35715),"gl.getProgramInfoLog",a,k,r);else if(""!==a)console.warn("THREE.WebGLProgram: gl.getProgramInfoLog()",a);else if(""===l||""===n)p=!1;p&&(this.diagnostics={runnable:t,programLog:a,vertexShader:{log:l,prefix:e},fragmentShader:{log:n,prefix:h}})}d.deleteShader(f);d.deleteShader(g);var v;this.getUniforms=function(){void 0===v&&(v=new Eb(d,q));return v};var m;this.getAttributes=function(){if(void 0===m){for(var a={},b=d.getProgramParameter(q,35721),
|
|
|
+c=0;c<b;c++){var e=d.getActiveAttrib(q,c).name;a[e]=d.getAttribLocation(q,e)}m=a}return m};this.destroy=function(){d.deleteProgram(q);this.program=void 0};this.name=c.shaderName;this.id=mk++;this.cacheKey=b;this.usedTimes=1;this.program=q;this.vertexShader=f;this.fragmentShader=g;return this}function nk(a,b,c){function d(a){if(a)a.isTexture?b=a.encoding:a.isWebGLRenderTarget&&(console.warn("THREE.WebGLPrograms.getTextureEncodingFromMap: don't use render targets as textures. Use their .texture property instead."),
|
|
|
+b=a.texture.encoding);else var b=3E3;return b}var e=[],f=c.isWebGL2,g=c.logarithmicDepthBuffer,h=c.floatVertexTextures,l=c.maxVertexUniforms,n=c.vertexTextures,t=c.precision,p={MeshDepthMaterial:"depth",MeshDistanceMaterial:"distanceRGBA",MeshNormalMaterial:"normal",MeshBasicMaterial:"basic",MeshLambertMaterial:"lambert",MeshPhongMaterial:"phong",MeshToonMaterial:"toon",MeshStandardMaterial:"physical",MeshPhysicalMaterial:"physical",MeshMatcapMaterial:"matcap",LineBasicMaterial:"basic",LineDashedMaterial:"dashed",
|
|
|
+PointsMaterial:"points",ShadowMaterial:"shadow",SpriteMaterial:"sprite"},k="precision isWebGL2 supportsVertexTextures outputEncoding instancing map mapEncoding matcap matcapEncoding envMap envMapMode envMapEncoding envMapCubeUV lightMap lightMapEncoding aoMap emissiveMap emissiveMapEncoding bumpMap normalMap objectSpaceNormalMap tangentSpaceNormalMap clearcoatMap clearcoatRoughnessMap clearcoatNormalMap displacementMap specularMap roughnessMap metalnessMap gradientMap alphaMap combine vertexColors vertexTangents vertexUvs uvsVertexOnly fog useFog fogExp2 flatShading sizeAttenuation logarithmicDepthBuffer skinning maxBones useVertexTexture morphTargets morphNormals maxMorphTargets maxMorphNormals premultipliedAlpha numDirLights numPointLights numSpotLights numHemiLights numRectAreaLights numDirLightShadows numPointLightShadows numSpotLightShadows shadowMapEnabled shadowMapType toneMapping physicallyCorrectLights alphaTest doubleSided flipSided numClippingPlanes numClipIntersection depthPacking dithering sheen".split(" ");
|
|
|
return{getParameters:function(e,k,u,m,z,x,Ba){var q=m.fog;m=e.isMeshStandardMaterial?m.environment:null;m=e.envMap||m;var r=p[e.type];if(Ba.isSkinnedMesh){var v=Ba.skeleton.bones;if(h)v=1024;else{var A=Math.min(Math.floor((l-20)/4),v.length);A<v.length?(console.warn("THREE.WebGLRenderer: Skeleton has "+v.length+" bones. This GPU supports "+A+"."),v=0):v=A}}else v=0;null!==e.precision&&(t=c.getMaxPrecision(e.precision),t!==e.precision&&console.warn("THREE.WebGLProgram.getParameters:",e.precision,"not supported, using",
|
|
|
-t,"instead."));r?(A=fb[r],A={name:e.type,uniforms:Qh.clone(A.uniforms),vertexShader:A.vertexShader,fragmentShader:A.fragmentShader}):A={name:e.type,uniforms:e.uniforms,vertexShader:e.vertexShader,fragmentShader:e.fragmentShader};e.onBeforeCompile(A,a);var w=a.getRenderTarget();return{isWebGL2:f,shaderID:r,shaderName:A.name,uniforms:A.uniforms,vertexShader:A.vertexShader,fragmentShader:A.fragmentShader,defines:e.defines,isRawShaderMaterial:e.isRawShaderMaterial,isShaderMaterial:e.isShaderMaterial,
|
|
|
+t,"instead."));r?(A=fb[r],A={name:e.name||e.type,uniforms:Qh.clone(A.uniforms),vertexShader:A.vertexShader,fragmentShader:A.fragmentShader}):A={name:e.name||e.type,uniforms:e.uniforms,vertexShader:e.vertexShader,fragmentShader:e.fragmentShader};e.onBeforeCompile(A,a);var w=a.getRenderTarget();return{isWebGL2:f,shaderID:r,shaderName:A.name,uniforms:A.uniforms,vertexShader:A.vertexShader,fragmentShader:A.fragmentShader,defines:e.defines,isRawShaderMaterial:e.isRawShaderMaterial,isShaderMaterial:e.isShaderMaterial,
|
|
|
precision:t,instancing:!0===Ba.isInstancedMesh,supportsVertexTextures:n,outputEncoding:null!==w?d(w.texture):a.outputEncoding,map:!!e.map,mapEncoding:d(e.map),matcap:!!e.matcap,matcapEncoding:d(e.matcap),envMap:!!m,envMapMode:m&&m.mapping,envMapEncoding:d(m),envMapCubeUV:!!m&&(306===m.mapping||307===m.mapping),lightMap:!!e.lightMap,lightMapEncoding:d(e.lightMap),aoMap:!!e.aoMap,emissiveMap:!!e.emissiveMap,emissiveMapEncoding:d(e.emissiveMap),bumpMap:!!e.bumpMap,normalMap:!!e.normalMap,objectSpaceNormalMap:1===
|
|
|
e.normalMapType,tangentSpaceNormalMap:0===e.normalMapType,clearcoatMap:!!e.clearcoatMap,clearcoatRoughnessMap:!!e.clearcoatRoughnessMap,clearcoatNormalMap:!!e.clearcoatNormalMap,displacementMap:!!e.displacementMap,roughnessMap:!!e.roughnessMap,metalnessMap:!!e.metalnessMap,specularMap:!!e.specularMap,alphaMap:!!e.alphaMap,gradientMap:!!e.gradientMap,sheen:!!e.sheen,combine:e.combine,vertexTangents:e.normalMap&&e.vertexTangents,vertexColors:e.vertexColors,vertexUvs:!!e.map||!!e.bumpMap||!!e.normalMap||
|
|
|
!!e.specularMap||!!e.alphaMap||!!e.emissiveMap||!!e.roughnessMap||!!e.metalnessMap||!!e.clearcoatMap||!!e.clearcoatRoughnessMap||!!e.clearcoatNormalMap||!!e.displacementMap,uvsVertexOnly:!(e.map||e.bumpMap||e.normalMap||e.specularMap||e.alphaMap||e.emissiveMap||e.roughnessMap||e.metalnessMap||e.clearcoatNormalMap)&&!!e.displacementMap,fog:!!q,useFog:e.fog,fogExp2:q&&q.isFogExp2,flatShading:e.flatShading,sizeAttenuation:e.sizeAttenuation,logarithmicDepthBuffer:g,skinning:e.skinning&&0<v,maxBones:v,
|
|
@@ -183,12 +182,12 @@ e),e.displacementMap&&(a.displacementMap.value=e.displacementMap,a.displacementS
|
|
|
1===e.side&&a.normalScale.value.negate()),e.displacementMap&&(a.displacementMap.value=e.displacementMap,a.displacementScale.value=e.displacementScale,a.displacementBias.value=e.displacementBias);else if(e.isLineBasicMaterial)a.diffuse.value.copy(e.color),a.opacity.value=e.opacity,e.isLineDashedMaterial&&(a.dashSize.value=e.dashSize,a.totalSize.value=e.dashSize+e.gapSize,a.scale.value=e.scale);else if(e.isPointsMaterial){a.diffuse.value.copy(e.color);a.opacity.value=e.opacity;a.size.value=e.size*g;
|
|
|
a.scale.value=.5*h;e.map&&(a.map.value=e.map);e.alphaMap&&(a.alphaMap.value=e.alphaMap);if(e.map)var d=e.map;else e.alphaMap&&(d=e.alphaMap);void 0!==d&&(!0===d.matrixAutoUpdate&&d.updateMatrix(),a.uvTransform.value.copy(d.matrix))}else if(e.isSpriteMaterial){a.diffuse.value.copy(e.color);a.opacity.value=e.opacity;a.rotation.value=e.rotation;e.map&&(a.map.value=e.map);e.alphaMap&&(a.alphaMap.value=e.alphaMap);if(e.map)var n=e.map;else e.alphaMap&&(n=e.alphaMap);void 0!==n&&(!0===n.matrixAutoUpdate&&
|
|
|
n.updateMatrix(),a.uvTransform.value.copy(n.matrix))}else e.isShadowMaterial?(a.color.value.copy(e.color),a.opacity.value=e.opacity):e.isShaderMaterial&&(e.uniformsNeedUpdate=!1)}}}function mg(a){var b;function c(){ra=new pj(I);Fa=new nj(I,ra,a);!1===Fa.isWebGL2&&(ra.get("WEBGL_depth_texture"),ra.get("OES_texture_float"),ra.get("OES_texture_half_float"),ra.get("OES_texture_half_float_linear"),ra.get("OES_standard_derivatives"),ra.get("OES_element_index_uint"),ra.get("ANGLE_instanced_arrays"));ra.get("OES_texture_float_linear");
|
|
|
-qa=new Uh(I,ra,Fa);V=new yk(I,ra,Fa);V.scissor(U.copy(da).multiplyScalar(X).floor());V.viewport(aa.copy(Z).multiplyScalar(X).floor());W=new sj(I);T=new ok;ba=new zk(I,ra,V,T,Fa,qa,W);la=new kj(I,Fa);ua=new qj(I,la,W);oa=new vj(I,ua,la,W);ya=new uj(I);sa=new nk(O,ra,Fa);xa=new Ak(T);wa=new rk;va=new xk;pa=new lj(O,V,oa,Ba);Aa=new mj(I,ra,W,Fa);Da=new rj(I,ra,W,Fa);W.programs=sa.programs;O.capabilities=Fa;O.extensions=ra;O.properties=T;O.renderLists=wa;O.state=V;O.info=W}function d(a){a.preventDefault();
|
|
|
+qa=new Uh(I,ra,Fa);V=new yk(I,ra,Fa);V.scissor(U.copy(da).multiplyScalar(X).floor());V.viewport(aa.copy(Z).multiplyScalar(X).floor());W=new sj(I);T=new ok;ba=new zk(I,ra,V,T,Fa,qa,W);la=new kj(I,Fa);va=new qj(I,la,W);pa=new vj(I,va,la,W);ya=new uj(I);sa=new nk(O,ra,Fa);xa=new Ak(T);wa=new rk;ua=new xk;oa=new lj(O,V,pa,Ba);Aa=new mj(I,ra,W,Fa);Da=new rj(I,ra,W,Fa);W.programs=sa.programs;O.capabilities=Fa;O.extensions=ra;O.properties=T;O.renderLists=wa;O.state=V;O.info=W}function d(a){a.preventDefault();
|
|
|
console.log("THREE.WebGLRenderer: Context Lost.");B=!0}function e(){console.log("THREE.WebGLRenderer: Context Restored.");B=!1;c()}function f(a){a=a.target;a.removeEventListener("dispose",f);g(a);T.remove(a)}function g(a){var b=T.get(a).program;a.program=void 0;void 0!==b&&sa.releaseProgram(b)}function h(a,b){a.render(function(a){O.renderBufferImmediate(a,b)})}function l(a,b,c,d){if(!1!==a.visible){if(a.layers.test(b.layers))if(a.isGroup)c=a.renderOrder;else if(a.isLOD)!0===a.autoUpdate&&a.update(b);
|
|
|
-else if(a.isLight)y.pushLight(a),a.castShadow&&y.pushShadow(a);else if(a.isSprite){if(!a.frustumCulled||na.intersectsSprite(a)){d&&Hb.setFromMatrixPosition(a.matrixWorld).applyMatrix4(Jd);var e=oa.update(a),f=a.material;f.visible&&P.push(a,e,f,c,Hb.z,null)}}else if(a.isImmediateRenderObject)d&&Hb.setFromMatrixPosition(a.matrixWorld).applyMatrix4(Jd),P.push(a,null,a.material,c,Hb.z,null);else if(a.isMesh||a.isLine||a.isPoints)if(a.isSkinnedMesh&&a.skeleton.frame!==W.render.frame&&(a.skeleton.update(),
|
|
|
-a.skeleton.frame=W.render.frame),!a.frustumCulled||na.intersectsObject(a))if(d&&Hb.setFromMatrixPosition(a.matrixWorld).applyMatrix4(Jd),e=oa.update(a),f=a.material,Array.isArray(f))for(var g=e.groups,h=0,n=g.length;h<n;h++){var t=g[h],p=f[t.materialIndex];p&&p.visible&&P.push(a,e,p,c,Hb.z,t)}else f.visible&&P.push(a,e,f,c,Hb.z,null);a=a.children;e=0;for(f=a.length;e<f;e++)l(a[e],b,c,d)}}function n(a,b,c){for(var d=!0===b.isScene?b.overrideMaterial:null,e=0,f=a.length;e<f;e++){var g=a[e],h=g.object,
|
|
|
-l=g.geometry,n=null===d?g.material:d;g=g.group;if(c.isArrayCamera){R=c;for(var p=c.cameras,k=0,q=p.length;k<q;k++){var u=p[k];h.layers.test(u.layers)&&(V.viewport(aa.copy(u.viewport)),y.setupLights(u),t(h,b,u,l,n,g))}}else R=null,t(h,b,c,l,n,g)}}function t(a,c,d,e,f,g){a.onBeforeRender(O,c,d,e,f,g);y=va.get(c,R||d);a.modelViewMatrix.multiplyMatrices(d.matrixWorldInverse,a.matrixWorld);a.normalMatrix.getNormalMatrix(a.modelViewMatrix);if(a.isImmediateRenderObject){var l=k(d,c,f,a);V.setMaterial(f);
|
|
|
-Q=b=null;Le=!1;h(a,l)}else O.renderBufferDirect(d,c,e,f,a,g);a.onAfterRender(O,c,d,e,f,g);y=va.get(c,R||d)}function p(a,b,c){!0!==b.isScene&&(b=lg);var d=T.get(a),e=y.state.lights,h=e.state.version;c=sa.getParameters(a,e.state,y.state.shadowsArray,b,Va.numPlanes,Va.numIntersection,c);var l=sa.getProgramCacheKey(c),n=d.program,t=!0;if(void 0===n)a.addEventListener("dispose",f);else if(n.cacheKey!==l)g(a);else{if(d.lightsStateVersion!==h)d.lightsStateVersion=h;else if(void 0!==c.shaderID)return;t=!1}t&&
|
|
|
+else if(a.isLight)y.pushLight(a),a.castShadow&&y.pushShadow(a);else if(a.isSprite){if(!a.frustumCulled||na.intersectsSprite(a)){d&&Hb.setFromMatrixPosition(a.matrixWorld).applyMatrix4(Jd);var e=pa.update(a),f=a.material;f.visible&&P.push(a,e,f,c,Hb.z,null)}}else if(a.isImmediateRenderObject)d&&Hb.setFromMatrixPosition(a.matrixWorld).applyMatrix4(Jd),P.push(a,null,a.material,c,Hb.z,null);else if(a.isMesh||a.isLine||a.isPoints)if(a.isSkinnedMesh&&a.skeleton.frame!==W.render.frame&&(a.skeleton.update(),
|
|
|
+a.skeleton.frame=W.render.frame),!a.frustumCulled||na.intersectsObject(a))if(d&&Hb.setFromMatrixPosition(a.matrixWorld).applyMatrix4(Jd),e=pa.update(a),f=a.material,Array.isArray(f))for(var g=e.groups,h=0,n=g.length;h<n;h++){var t=g[h],p=f[t.materialIndex];p&&p.visible&&P.push(a,e,p,c,Hb.z,t)}else f.visible&&P.push(a,e,f,c,Hb.z,null);a=a.children;e=0;for(f=a.length;e<f;e++)l(a[e],b,c,d)}}function n(a,b,c){for(var d=!0===b.isScene?b.overrideMaterial:null,e=0,f=a.length;e<f;e++){var g=a[e],h=g.object,
|
|
|
+l=g.geometry,n=null===d?g.material:d;g=g.group;if(c.isArrayCamera){R=c;for(var p=c.cameras,k=0,q=p.length;k<q;k++){var u=p[k];h.layers.test(u.layers)&&(V.viewport(aa.copy(u.viewport)),y.setupLights(u),t(h,b,u,l,n,g))}}else R=null,t(h,b,c,l,n,g)}}function t(a,c,d,e,f,g){a.onBeforeRender(O,c,d,e,f,g);y=ua.get(c,R||d);a.modelViewMatrix.multiplyMatrices(d.matrixWorldInverse,a.matrixWorld);a.normalMatrix.getNormalMatrix(a.modelViewMatrix);if(a.isImmediateRenderObject){var l=k(d,c,f,a);V.setMaterial(f);
|
|
|
+Q=b=null;Le=!1;h(a,l)}else O.renderBufferDirect(d,c,e,f,a,g);a.onAfterRender(O,c,d,e,f,g);y=ua.get(c,R||d)}function p(a,b,c){!0!==b.isScene&&(b=lg);var d=T.get(a),e=y.state.lights,h=e.state.version;c=sa.getParameters(a,e.state,y.state.shadowsArray,b,Va.numPlanes,Va.numIntersection,c);var l=sa.getProgramCacheKey(c),n=d.program,t=!0;if(void 0===n)a.addEventListener("dispose",f);else if(n.cacheKey!==l)g(a);else{if(d.lightsStateVersion!==h)d.lightsStateVersion=h;else if(void 0!==c.shaderID)return;t=!1}t&&
|
|
|
(n=sa.acquireProgram(c,l),d.program=n,d.uniforms=c.uniforms,d.outputEncoding=c.outputEncoding,a.program=n);c=n.getAttributes();if(a.morphTargets)for(l=a.numSupportedMorphTargets=0;l<O.maxMorphTargets;l++)0<=c["morphTarget"+l]&&a.numSupportedMorphTargets++;if(a.morphNormals)for(l=a.numSupportedMorphNormals=0;l<O.maxMorphNormals;l++)0<=c["morphNormal"+l]&&a.numSupportedMorphNormals++;c=d.uniforms;if(!a.isShaderMaterial&&!a.isRawShaderMaterial||!0===a.clipping)d.numClippingPlanes=Va.numPlanes,d.numIntersection=
|
|
|
Va.numIntersection,c.clippingPlanes=Va.uniform;d.environment=a.isMeshStandardMaterial?b.environment:null;d.fog=b.fog;d.needsLights=a.isMeshLambertMaterial||a.isMeshToonMaterial||a.isMeshPhongMaterial||a.isMeshStandardMaterial||a.isShadowMaterial||a.isShaderMaterial&&!0===a.lights;d.lightsStateVersion=h;d.needsLights&&(c.ambientLightColor.value=e.state.ambient,c.lightProbe.value=e.state.probe,c.directionalLights.value=e.state.directional,c.directionalLightShadows.value=e.state.directionalShadow,c.spotLights.value=
|
|
|
e.state.spot,c.spotLightShadows.value=e.state.spotShadow,c.rectAreaLights.value=e.state.rectArea,c.pointLights.value=e.state.point,c.pointLightShadows.value=e.state.pointShadow,c.hemisphereLights.value=e.state.hemi,c.directionalShadowMap.value=e.state.directionalShadowMap,c.directionalShadowMatrix.value=e.state.directionalShadowMatrix,c.spotShadowMap.value=e.state.spotShadowMap,c.spotShadowMatrix.value=e.state.spotShadowMatrix,c.pointShadowMap.value=e.state.pointShadowMap,c.pointShadowMatrix.value=
|
|
@@ -202,22 +201,22 @@ g.setValue(I,"normalMatrix",d.normalMatrix);g.setValue(I,"modelMatrix",d.matrixW
|
|
|
a.powerPreference?a.powerPreference:"default",C=void 0!==a.failIfMajorPerformanceCaveat?a.failIfMajorPerformanceCaveat:!1,P=null,y=null;this.domElement=r;this.debug={checkShaderErrors:!0};this.sortObjects=this.autoClearStencil=this.autoClearDepth=this.autoClearColor=this.autoClear=!0;this.clippingPlanes=[];this.localClippingEnabled=!1;this.gammaFactor=2;this.outputEncoding=3E3;this.physicallyCorrectLights=!1;this.toneMapping=0;this.toneMappingExposure=1;this.maxMorphTargets=8;this.maxMorphNormals=
|
|
|
4;var O=this,B=!1,D=null,F=0,J=0,G=null,K=null,H=-1;var Q=b=null;var Le=!1;var S=null,R=null,aa=new ea,U=new ea,ca=null,Y=r.width,Pa=r.height,X=1,ha=null,ja=null,Z=new ea(0,0,Y,Pa),da=new ea(0,0,Y,Pa),ka=!1,na=new Ec,Va=new oj,Je=!1,kg=!1,Jd=new M,Hb=new m,lg={background:null,fog:null,environment:null,overrideMaterial:null,isScene:!0};try{v={alpha:v,depth:A,stencil:z,antialias:x,premultipliedAlpha:Ba,preserveDrawingBuffer:ma,powerPreference:N,failIfMajorPerformanceCaveat:C};r.addEventListener("webglcontextlost",
|
|
|
d,!1);r.addEventListener("webglcontextrestored",e,!1);var I=q||r.getContext("webgl",v)||r.getContext("experimental-webgl",v);if(null===I){if(null!==r.getContext("webgl"))throw Error("Error creating WebGL context with your selected attributes.");throw Error("Error creating WebGL context.");}void 0===I.getShaderPrecisionFormat&&(I.getShaderPrecisionFormat=function(){return{rangeMin:1,rangeMax:1,precision:1}})}catch(Wh){throw console.error("THREE.WebGLRenderer: "+Wh.message),Wh;}var ra,Fa,V,W,T,ba,la,
|
|
|
-ua,oa,sa,xa,wa,va,pa,ya,Aa,Da,qa;c();var ta=new Vh(O,I);this.xr=ta;var Ea=new Th(O,oa,Fa.maxTextureSize);this.shadowMap=Ea;this.getContext=function(){return I};this.getContextAttributes=function(){return I.getContextAttributes()};this.forceContextLoss=function(){var a=ra.get("WEBGL_lose_context");a&&a.loseContext()};this.forceContextRestore=function(){var a=ra.get("WEBGL_lose_context");a&&a.restoreContext()};this.getPixelRatio=function(){return X};this.setPixelRatio=function(a){void 0!==a&&(X=a,this.setSize(Y,
|
|
|
+va,pa,sa,xa,wa,ua,oa,ya,Aa,Da,qa;c();var ta=new Vh(O,I);this.xr=ta;var Ea=new Th(O,pa,Fa.maxTextureSize);this.shadowMap=Ea;this.getContext=function(){return I};this.getContextAttributes=function(){return I.getContextAttributes()};this.forceContextLoss=function(){var a=ra.get("WEBGL_lose_context");a&&a.loseContext()};this.forceContextRestore=function(){var a=ra.get("WEBGL_lose_context");a&&a.restoreContext()};this.getPixelRatio=function(){return X};this.setPixelRatio=function(a){void 0!==a&&(X=a,this.setSize(Y,
|
|
|
Pa,!1))};this.getSize=function(a){void 0===a&&(console.warn("WebGLRenderer: .getsize() now requires a Vector2 as an argument"),a=new w);return a.set(Y,Pa)};this.setSize=function(a,b,c){ta.isPresenting?console.warn("THREE.WebGLRenderer: Can't change size while VR device is presenting."):(Y=a,Pa=b,r.width=Math.floor(a*X),r.height=Math.floor(b*X),!1!==c&&(r.style.width=a+"px",r.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 w);return a.set(Y*X,Pa*X).floor()};this.setDrawingBufferSize=function(a,b,c){Y=a;Pa=b;X=c;r.width=Math.floor(a*c);r.height=Math.floor(b*c);this.setViewport(0,0,a,b)};this.getCurrentViewport=function(a){void 0===a&&(console.warn("WebGLRenderer: .getCurrentViewport() now requires a Vector4 as an argument"),a=new ea);return a.copy(aa)};this.getViewport=function(a){return a.copy(Z)};this.setViewport=function(a,b,c,d){a.isVector4?Z.set(a.x,a.y,a.z,a.w):Z.set(a,b,c,d);V.viewport(aa.copy(Z).multiplyScalar(X).floor())};
|
|
|
-this.getScissor=function(a){return a.copy(da)};this.setScissor=function(a,b,c,d){a.isVector4?da.set(a.x,a.y,a.z,a.w):da.set(a,b,c,d);V.scissor(U.copy(da).multiplyScalar(X).floor())};this.getScissorTest=function(){return ka};this.setScissorTest=function(a){V.setScissorTest(ka=a)};this.setOpaqueSort=function(a){ha=a};this.setTransparentSort=function(a){ja=a};this.getClearColor=function(){return pa.getClearColor()};this.setClearColor=function(){pa.setClearColor.apply(pa,arguments)};this.getClearAlpha=
|
|
|
-function(){return pa.getClearAlpha()};this.setClearAlpha=function(){pa.setClearAlpha.apply(pa,arguments)};this.clear=function(a,b,c){var d=0;if(void 0===a||a)d|=16384;if(void 0===b||b)d|=256;if(void 0===c||c)d|=1024;I.clear(d)};this.clearColor=function(){this.clear(!0,!1,!1)};this.clearDepth=function(){this.clear(!1,!0,!1)};this.clearStencil=function(){this.clear(!1,!1,!0)};this.dispose=function(){r.removeEventListener("webglcontextlost",d,!1);r.removeEventListener("webglcontextrestored",e,!1);wa.dispose();
|
|
|
-va.dispose();T.dispose();oa.dispose();ta.dispose();za.stop()};this.renderBufferImmediate=function(a,b){V.initAttributes();var c=T.get(a);a.hasPositions&&!c.position&&(c.position=I.createBuffer());a.hasNormals&&!c.normal&&(c.normal=I.createBuffer());a.hasUvs&&!c.uv&&(c.uv=I.createBuffer());a.hasColors&&!c.color&&(c.color=I.createBuffer());b=b.getAttributes();a.hasPositions&&(I.bindBuffer(34962,c.position),I.bufferData(34962,a.positionArray,35048),V.enableAttribute(b.position),I.vertexAttribPointer(b.position,
|
|
|
+this.getScissor=function(a){return a.copy(da)};this.setScissor=function(a,b,c,d){a.isVector4?da.set(a.x,a.y,a.z,a.w):da.set(a,b,c,d);V.scissor(U.copy(da).multiplyScalar(X).floor())};this.getScissorTest=function(){return ka};this.setScissorTest=function(a){V.setScissorTest(ka=a)};this.setOpaqueSort=function(a){ha=a};this.setTransparentSort=function(a){ja=a};this.getClearColor=function(){return oa.getClearColor()};this.setClearColor=function(){oa.setClearColor.apply(oa,arguments)};this.getClearAlpha=
|
|
|
+function(){return oa.getClearAlpha()};this.setClearAlpha=function(){oa.setClearAlpha.apply(oa,arguments)};this.clear=function(a,b,c){var d=0;if(void 0===a||a)d|=16384;if(void 0===b||b)d|=256;if(void 0===c||c)d|=1024;I.clear(d)};this.clearColor=function(){this.clear(!0,!1,!1)};this.clearDepth=function(){this.clear(!1,!0,!1)};this.clearStencil=function(){this.clear(!1,!1,!0)};this.dispose=function(){r.removeEventListener("webglcontextlost",d,!1);r.removeEventListener("webglcontextrestored",e,!1);wa.dispose();
|
|
|
+ua.dispose();T.dispose();pa.dispose();ta.dispose();za.stop()};this.renderBufferImmediate=function(a,b){V.initAttributes();var c=T.get(a);a.hasPositions&&!c.position&&(c.position=I.createBuffer());a.hasNormals&&!c.normal&&(c.normal=I.createBuffer());a.hasUvs&&!c.uv&&(c.uv=I.createBuffer());a.hasColors&&!c.color&&(c.color=I.createBuffer());b=b.getAttributes();a.hasPositions&&(I.bindBuffer(34962,c.position),I.bufferData(34962,a.positionArray,35048),V.enableAttribute(b.position),I.vertexAttribPointer(b.position,
|
|
|
3,5126,!1,0,0));a.hasNormals&&(I.bindBuffer(34962,c.normal),I.bufferData(34962,a.normalArray,35048),V.enableAttribute(b.normal),I.vertexAttribPointer(b.normal,3,5126,!1,0,0));a.hasUvs&&(I.bindBuffer(34962,c.uv),I.bufferData(34962,a.uvArray,35048),V.enableAttribute(b.uv),I.vertexAttribPointer(b.uv,2,5126,!1,0,0));a.hasColors&&(I.bindBuffer(34962,c.color),I.bufferData(34962,a.colorArray,35048),V.enableAttribute(b.color),I.vertexAttribPointer(b.color,3,5126,!1,0,0));V.disableUnusedAttributes();I.drawArrays(4,
|
|
|
-0,a.count);a.count=0};this.renderBufferDirect=function(a,c,d,e,f,g){null===c&&(c=lg);var h=f.isMesh&&0>f.matrixWorld.determinant(),l=k(a,c,e,f);V.setMaterial(e,h);var n=!1;if(b!==d.id||Q!==l.id||Le!==(!0===e.wireframe))b=d.id,Q=l.id,Le=!0===e.wireframe,n=!0;if(e.morphTargets||e.morphNormals)ya.update(f,d,e,l),n=!0;!0===f.isInstancedMesh&&(n=!0);a=d.index;c=d.attributes.position;if(null===a){if(void 0===c||0===c.count)return}else if(0===a.count)return;var t=1;!0===e.wireframe&&(a=ua.getWireframeAttribute(d),
|
|
|
+0,a.count);a.count=0};this.renderBufferDirect=function(a,c,d,e,f,g){null===c&&(c=lg);var h=f.isMesh&&0>f.matrixWorld.determinant(),l=k(a,c,e,f);V.setMaterial(e,h);var n=!1;if(b!==d.id||Q!==l.id||Le!==(!0===e.wireframe))b=d.id,Q=l.id,Le=!0===e.wireframe,n=!0;if(e.morphTargets||e.morphNormals)ya.update(f,d,e,l),n=!0;!0===f.isInstancedMesh&&(n=!0);a=d.index;c=d.attributes.position;if(null===a){if(void 0===c||0===c.count)return}else if(0===a.count)return;var t=1;!0===e.wireframe&&(a=va.getWireframeAttribute(d),
|
|
|
t=2);h=Aa;if(null!==a){var p=la.get(a);h=Da;h.setIndex(p)}if(n){if(!1!==Fa.isWebGL2||!f.isInstancedMesh&&!d.isInstancedBufferGeometry||null!==ra.get("ANGLE_instanced_arrays")){V.initAttributes();n=d.attributes;l=l.getAttributes();var q=e.defaultAttributeValues;for(N in l){var u=l[N];if(0<=u){var r=n[N];if(void 0!==r){var v=r.normalized,m=r.itemSize,A=la.get(r);if(void 0!==A){var x=A.buffer,z=A.type;A=A.bytesPerElement;if(r.isInterleavedBufferAttribute){var C=r.data,w=C.stride;r=r.offset;C&&C.isInstancedInterleavedBuffer?
|
|
|
(V.enableAttributeAndDivisor(u,C.meshPerAttribute),void 0===d._maxInstanceCount&&(d._maxInstanceCount=C.meshPerAttribute*C.count)):V.enableAttribute(u);I.bindBuffer(34962,x);V.vertexAttribPointer(u,m,z,v,w*A,r*A)}else r.isInstancedBufferAttribute?(V.enableAttributeAndDivisor(u,r.meshPerAttribute),void 0===d._maxInstanceCount&&(d._maxInstanceCount=r.meshPerAttribute*r.count)):V.enableAttribute(u),I.bindBuffer(34962,x),V.vertexAttribPointer(u,m,z,v,0,0)}}else if("instanceMatrix"===N)m=la.get(f.instanceMatrix),
|
|
|
void 0!==m&&(v=m.buffer,m=m.type,V.enableAttributeAndDivisor(u+0,1),V.enableAttributeAndDivisor(u+1,1),V.enableAttributeAndDivisor(u+2,1),V.enableAttributeAndDivisor(u+3,1),I.bindBuffer(34962,v),I.vertexAttribPointer(u+0,4,m,!1,64,0),I.vertexAttribPointer(u+1,4,m,!1,64,16),I.vertexAttribPointer(u+2,4,m,!1,64,32),I.vertexAttribPointer(u+3,4,m,!1,64,48));else if(void 0!==q&&(v=q[N],void 0!==v))switch(v.length){case 2:I.vertexAttrib2fv(u,v);break;case 3:I.vertexAttrib3fv(u,v);break;case 4:I.vertexAttrib4fv(u,
|
|
|
v);break;default:I.vertexAttrib1fv(u,v)}}}V.disableUnusedAttributes()}null!==a&&I.bindBuffer(34963,p.buffer)}var N=d.drawRange.start*t;n=null!==g?g.start*t:0;p=Math.max(N,n);g=Math.max(0,Math.min(null!==a?a.count:c.count,N+d.drawRange.count*t,n+(null!==g?g.count*t:Infinity))-1-p+1);0!==g&&(f.isMesh?!0===e.wireframe?(V.setLineWidth(e.wireframeLinewidth*(null===G?X:1)),h.setMode(1)):h.setMode(4):f.isLine?(e=e.linewidth,void 0===e&&(e=1),V.setLineWidth(e*(null===G?X:1)),f.isLineSegments?h.setMode(1):
|
|
|
-f.isLineLoop?h.setMode(2):h.setMode(3)):f.isPoints?h.setMode(0):f.isSprite&&h.setMode(4),f.isInstancedMesh?h.renderInstances(d,p,g,f.count):d.isInstancedBufferGeometry?h.renderInstances(d,p,g,Math.min(d.instanceCount,d._maxInstanceCount)):h.render(p,g))};this.compile=function(a,b){y=va.get(a,b);y.init();a.traverse(function(a){a.isLight&&(y.pushLight(a),a.castShadow&&y.pushShadow(a))});y.setupLights(b);var c={};a.traverse(function(b){var d=b.material;if(d)if(Array.isArray(d))for(var e=0;e<d.length;e++){var f=
|
|
|
+f.isLineLoop?h.setMode(2):h.setMode(3)):f.isPoints?h.setMode(0):f.isSprite&&h.setMode(4),f.isInstancedMesh?h.renderInstances(d,p,g,f.count):d.isInstancedBufferGeometry?h.renderInstances(d,p,g,Math.min(d.instanceCount,d._maxInstanceCount)):h.render(p,g))};this.compile=function(a,b){y=ua.get(a,b);y.init();a.traverse(function(a){a.isLight&&(y.pushLight(a),a.castShadow&&y.pushShadow(a))});y.setupLights(b);var c={};a.traverse(function(b){var d=b.material;if(d)if(Array.isArray(d))for(var e=0;e<d.length;e++){var f=
|
|
|
d[e];!1===f.uuid in c&&(p(f,a,b),c[f.uuid]=!0)}else!1===d.uuid in c&&(p(d,a,b),c[d.uuid]=!0)})};var Ca=null,za=new wh;za.setAnimationLoop(function(a){ta.isPresenting||Ca&&Ca(a)});"undefined"!==typeof window&&za.setContext(window);this.setAnimationLoop=function(a){Ca=a;ta.setAnimationLoop(a);za.start()};this.render=function(a,c,d,e){if(void 0!==d){console.warn("THREE.WebGLRenderer.render(): the renderTarget argument has been removed. Use .setRenderTarget() instead.");var f=d}if(void 0!==e){console.warn("THREE.WebGLRenderer.render(): the forceClear argument has been removed. Use .clear() instead.");
|
|
|
-var g=e}if(void 0!==c&&!0!==c.isCamera)console.error("THREE.WebGLRenderer.render: camera is not an instance of THREE.Camera.");else if(!0!==B){Q=b=null;Le=!1;H=-1;S=null;!0===a.autoUpdate&&a.updateMatrixWorld();null===c.parent&&c.updateMatrixWorld();!0===ta.enabled&&!0===ta.isPresenting&&(c=ta.getCamera(c));if(!0===a.isScene)a.onBeforeRender(O,a,c,f||G);y=va.get(a,c);y.init();Jd.multiplyMatrices(c.projectionMatrix,c.matrixWorldInverse);na.setFromProjectionMatrix(Jd);kg=this.localClippingEnabled;Je=
|
|
|
-Va.init(this.clippingPlanes,kg,c);P=wa.get(a,c);P.init();l(a,c,0,O.sortObjects);P.finish();!0===O.sortObjects&&P.sort(ha,ja);!0===Je&&Va.beginShadows();Ea.render(y.state.shadowsArray,a,c);y.setupLights(c);!0===Je&&Va.endShadows();!0===this.info.autoReset&&this.info.reset();void 0!==f&&this.setRenderTarget(f);pa.render(P,a,c,g);d=P.opaque;e=P.transparent;0<d.length&&n(d,a,c);0<e.length&&n(e,a,c);if(!0===a.isScene)a.onAfterRender(O,a,c);null!==G&&(ba.updateRenderTargetMipmap(G),ba.updateMultisampleRenderTarget(G));
|
|
|
+var g=e}if(void 0!==c&&!0!==c.isCamera)console.error("THREE.WebGLRenderer.render: camera is not an instance of THREE.Camera.");else if(!0!==B){Q=b=null;Le=!1;H=-1;S=null;!0===a.autoUpdate&&a.updateMatrixWorld();null===c.parent&&c.updateMatrixWorld();!0===ta.enabled&&!0===ta.isPresenting&&(c=ta.getCamera(c));if(!0===a.isScene)a.onBeforeRender(O,a,c,f||G);y=ua.get(a,c);y.init();Jd.multiplyMatrices(c.projectionMatrix,c.matrixWorldInverse);na.setFromProjectionMatrix(Jd);kg=this.localClippingEnabled;Je=
|
|
|
+Va.init(this.clippingPlanes,kg,c);P=wa.get(a,c);P.init();l(a,c,0,O.sortObjects);P.finish();!0===O.sortObjects&&P.sort(ha,ja);!0===Je&&Va.beginShadows();Ea.render(y.state.shadowsArray,a,c);y.setupLights(c);!0===Je&&Va.endShadows();!0===this.info.autoReset&&this.info.reset();void 0!==f&&this.setRenderTarget(f);oa.render(P,a,c,g);d=P.opaque;e=P.transparent;0<d.length&&n(d,a,c);0<e.length&&n(e,a,c);if(!0===a.isScene)a.onAfterRender(O,a,c);null!==G&&(ba.updateRenderTargetMipmap(G),ba.updateMultisampleRenderTarget(G));
|
|
|
V.buffers.depth.setTest(!0);V.buffers.depth.setMask(!0);V.buffers.color.setMask(!0);V.setPolygonOffset(!1);y=P=null}};this.setFramebuffer=function(a){D!==a&&null===G&&I.bindFramebuffer(36160,a);D=a};this.getActiveCubeFace=function(){return F};this.getActiveMipmapLevel=function(){return J};this.getRenderTarget=function(){return G};this.setRenderTarget=function(a,b,c){G=a;F=b;J=c;a&&void 0===T.get(a).__webglFramebuffer&&ba.setupRenderTarget(a);var d=D,e=!1;a?(d=T.get(a).__webglFramebuffer,a.isWebGLCubeRenderTarget?
|
|
|
(d=d[b||0],e=!0):d=a.isWebGLMultisampleRenderTarget?T.get(a).__webglMultisampledFramebuffer:d,aa.copy(a.viewport),U.copy(a.scissor),ca=a.scissorTest):(aa.copy(Z).multiplyScalar(X).floor(),U.copy(da).multiplyScalar(X).floor(),ca=ka);K!==d&&(I.bindFramebuffer(36160,d),K=d);V.viewport(aa);V.scissor(U);V.setScissorTest(ca);e&&(a=T.get(a.texture),I.framebufferTexture2D(36160,36064,34069+(b||0),a.__webglTexture,c||0))};this.readRenderTargetPixels=function(a,b,c,d,e,f,g){if(a&&a.isWebGLRenderTarget){var h=
|
|
|
T.get(a).__webglFramebuffer;a.isWebGLCubeRenderTarget&&void 0!==g&&(h=h[g]);if(h){g=!1;h!==K&&(I.bindFramebuffer(36160,h),g=!0);try{var l=a.texture,n=l.format,t=l.type;1023!==n&&qa.convert(n)!==I.getParameter(35739)?console.error("THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in RGBA or implementation defined format."):1009===t||qa.convert(t)===I.getParameter(35738)||1015===t&&(Fa.isWebGL2||ra.get("OES_texture_float")||ra.get("WEBGL_color_buffer_float"))||1016===t&&(Fa.isWebGL2?
|
|
@@ -302,7 +301,7 @@ case "quaternion":return je;case "bool":case "boolean":return $e;case "string":r
|
|
|
this.onStart=void 0;this.onLoad=a;this.onProgress=b;this.onError=c;this.itemStart=function(a){g++;if(!1===e&&void 0!==d.onStart)d.onStart(a,f,g);e=!0};this.itemEnd=function(a){f++;if(void 0!==d.onProgress)d.onProgress(a,f,g);if(f===g&&(e=!1,void 0!==d.onLoad))d.onLoad()};this.itemError=function(a){if(void 0!==d.onError)d.onError(a)};this.resolveURL=function(a){return h?h(a):a};this.setURLModifier=function(a){h=a;return this};this.addHandler=function(a,b){l.push(a,b);return this};this.removeHandler=
|
|
|
function(a){a=l.indexOf(a);-1!==a&&l.splice(a,2);return this};this.getHandler=function(a){for(var b=0,c=l.length;b<c;b+=2){var d=l[b],e=l[b+1];d.global&&(d.lastIndex=0);if(d.test(a))return e}return null}}function S(a){this.manager=void 0!==a?a:fi;this.crossOrigin="anonymous";this.resourcePath=this.path="";this.requestHeader={}}function Ra(a){S.call(this,a)}function ug(a){S.call(this,a)}function vg(a){S.call(this,a)}function df(a){S.call(this,a)}function bd(a){S.call(this,a)}function ef(a){S.call(this,
|
|
|
a)}function ff(a){S.call(this,a)}function J(){this.type="Curve";this.arcLengthDivisions=200}function La(a,b,c,d,e,f,g,h){J.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 cd(a,b,c,d,e,f){La.call(this,a,b,c,c,d,e,f);this.type="ArcCurve"}function wg(){var a=0,b=0,c=0,d=0;return{initCatmullRom:function(e,f,g,h,l){e=l*(g-e);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,n,k){e=((f-e)/l-(g-e)/(l+n)+(g-f)/n)*n;h=((g-f)/n-(h-f)/(n+k)+(h-g)/k)*n;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 pa(a,b,c,d){J.call(this);this.type="CatmullRomCurve3";this.points=a||[];this.closed=b||!1;this.curveType=c||"centripetal";this.tension=d||.5}function gi(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 ke(a,b,c,
|
|
|
+2*e-h;d=2*f-2*g+e+h},initNonuniformCatmullRom:function(e,f,g,h,l,n,k){e=((f-e)/l-(g-e)/(l+n)+(g-f)/n)*n;h=((g-f)/n-(h-f)/(n+k)+(h-g)/k)*n;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 oa(a,b,c,d){J.call(this);this.type="CatmullRomCurve3";this.points=a||[];this.closed=b||!1;this.curveType=c||"centripetal";this.tension=d||.5}function gi(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 ke(a,b,c,
|
|
|
d){var e=1-a;return e*e*b+2*(1-a)*a*c+a*a*d}function le(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 Xa(a,b,c,d){J.call(this);this.type="CubicBezierCurve";this.v0=a||new w;this.v1=b||new w;this.v2=c||new w;this.v3=d||new w}function ib(a,b,c,d){J.call(this);this.type="CubicBezierCurve3";this.v0=a||new m;this.v1=b||new m;this.v2=c||new m;this.v3=d||new m}function Ca(a,b){J.call(this);this.type="LineCurve";this.v1=a||new w;this.v2=b||new w}function Ya(a,b){J.call(this);
|
|
|
this.type="LineCurve3";this.v1=a||new m;this.v2=b||new m}function Za(a,b,c){J.call(this);this.type="QuadraticBezierCurve";this.v0=a||new w;this.v1=b||new w;this.v2=c||new w}function jb(a,b,c){J.call(this);this.type="QuadraticBezierCurve3";this.v0=a||new m;this.v1=b||new m;this.v2=c||new m}function $a(a){J.call(this);this.type="SplineCurve";this.points=a||[]}function tb(){J.call(this);this.type="CurvePath";this.curves=[];this.autoClose=!1}function ab(a){tb.call(this);this.type="Path";this.currentPoint=
|
|
|
new w;a&&this.setFromPoints(a)}function Mb(a){ab.call(this,a);this.uuid=L.generateUUID();this.type="Shape";this.holes=[]}function ha(a,b){y.call(this);this.type="Light";this.color=new D(a);this.intensity=void 0!==b?b:1;this.receiveShadow=void 0}function gf(a,b,c){ha.call(this,a,c);this.type="HemisphereLight";this.castShadow=void 0;this.position.copy(y.DefaultUp);this.updateMatrix();this.groundColor=new D(b)}function kb(a){this.camera=a;this.bias=0;this.radius=1;this.mapSize=new w(512,512);this.mapPass=
|
|
@@ -335,14 +334,14 @@ d;b++)c.setXYZ(a[b],yf.x,yf.y,yf.z)}function ub(a,b){this.object=a;void 0===b&&(
|
|
|
new F;c.setIndex(new G(a,1));c.setAttribute("position",new B([1,1,1,-1,1,1,-1,-1,1,1,-1,1,1,1,-1,-1,1,-1,-1,-1,-1,1,-1,-1],3));da.call(this,c,new ja({color:b,toneMapped:!1}));this.type="Box3Helper";this.geometry.computeBoundingSphere()}function qe(a,b,c){this.plane=a;this.size=void 0===b?1:b;a=void 0!==c?c:16776960;b=new F;b.setAttribute("position",new B([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,0,1,0,0,0],3));b.computeBoundingSphere();Ja.call(this,b,new ja({color:a,toneMapped:!1}));
|
|
|
this.type="PlaneHelper";b=new F;b.setAttribute("position",new B([1,1,1,-1,1,1,-1,-1,1,1,1,1,-1,-1,1,1,-1,1],3));b.computeBoundingSphere();this.add(new U(b,new Na({color:a,opacity:.2,transparent:!0,depthWrite:!1,toneMapped:!1})))}function vb(a,b,c,d,e,f){y.call(this);this.type="ArrowHelper";void 0===a&&(a=new m(0,0,1));void 0===b&&(b=new m(0,0,0));void 0===c&&(c=1);void 0===d&&(d=16776960);void 0===e&&(e=.2*c);void 0===f&&(f=.2*e);void 0===zf&&(zf=new F,zf.setAttribute("position",new B([0,0,0,0,1,
|
|
|
0],3)),Qg=new rb(0,.5,1,5,1),Qg.translate(0,-.5,0));this.position.copy(b);this.line=new Ja(zf,new ja({color:d,toneMapped:!1}));this.line.matrixAutoUpdate=!1;this.add(this.line);this.cone=new U(Qg,new Na({color:d,toneMapped:!1}));this.cone.matrixAutoUpdate=!1;this.add(this.cone);this.setDirection(a);this.setLength(c,e,f)}function re(a){a=a||1;var b=[0,0,0,a,0,0,0,0,0,0,a,0,0,0,0,0,0,a];a=new F;a.setAttribute("position",new B(b,3));a.setAttribute("color",new B([1,0,0,1,.6,0,0,1,0,.6,1,0,0,0,1,0,.6,
|
|
|
-1],3));b=new ja({vertexColors:!0,toneMapped:!1});da.call(this,a,b);this.type="AxesHelper"}function Rg(a){this._renderer=a;this._pingPongRenderTarget=null;a=new Float32Array(20);var b=new m(0,1,0);a=new sb({defines:{n:20},uniforms:{envMap:{value:null},samples:{value:1},weights:{value:a},latitudinal:{value:!1},dTheta:{value:0},mipInt:{value:0},poleAxis:{value:b},inputEncoding:{value:lb[3E3]},outputEncoding:{value:lb[3E3]}},vertexShader:Sg(),fragmentShader:"\nprecision mediump float;\nprecision mediump int;\nvarying vec3 vOutputDirection;\nuniform sampler2D envMap;\nuniform int samples;\nuniform float weights[n];\nuniform bool latitudinal;\nuniform float dTheta;\nuniform float mipInt;\nuniform vec3 poleAxis;\n\n"+
|
|
|
+1],3));b=new ja({vertexColors:!0,toneMapped:!1});da.call(this,a,b);this.type="AxesHelper"}function Rg(a){this._renderer=a;this._pingPongRenderTarget=null;a=new Float32Array(20);var b=new m(0,1,0);this._blurMaterial=new sb({name:"SphericalGaussianBlur",defines:{n:20},uniforms:{envMap:{value:null},samples:{value:1},weights:{value:a},latitudinal:{value:!1},dTheta:{value:0},mipInt:{value:0},poleAxis:{value:b},inputEncoding:{value:lb[3E3]},outputEncoding:{value:lb[3E3]}},vertexShader:Sg(),fragmentShader:"\nprecision mediump float;\nprecision mediump int;\nvarying vec3 vOutputDirection;\nuniform sampler2D envMap;\nuniform int samples;\nuniform float weights[n];\nuniform bool latitudinal;\nuniform float dTheta;\nuniform float mipInt;\nuniform vec3 poleAxis;\n\n"+
|
|
|
Tg()+"\n\n#define ENVMAP_TYPE_CUBE_UV\n#include <cube_uv_reflection_fragment>\n\nvec3 getSample(float theta, vec3 axis) {\n\tfloat cosTheta = cos(theta);\n\t// Rodrigues' axis-angle rotation\n\tvec3 sampleDirection = vOutputDirection * cosTheta\n\t\t+ cross(axis, vOutputDirection) * sin(theta)\n\t\t+ axis * dot(axis, vOutputDirection) * (1.0 - cosTheta);\n\treturn bilinearCubeUV(envMap, sampleDirection, mipInt);\n}\n\nvoid main() {\n\tvec3 axis = latitudinal ? poleAxis : cross(poleAxis, vOutputDirection);\n\tif (all(equal(axis, vec3(0.0))))\n\t\taxis = vec3(vOutputDirection.z, 0.0, - vOutputDirection.x);\n\taxis = normalize(axis);\n\tgl_FragColor = vec4(0.0);\n\tgl_FragColor.rgb += weights[0] * getSample(0.0, axis);\n\tfor (int i = 1; i < n; i++) {\n\t\tif (i >= samples)\n\t\t\tbreak;\n\t\tfloat theta = dTheta * float(i);\n\t\tgl_FragColor.rgb += weights[i] * getSample(-1.0 * theta, axis);\n\t\tgl_FragColor.rgb += weights[i] * getSample(theta, axis);\n\t}\n\tgl_FragColor = linearToOutputTexel(gl_FragColor);\n}\n\t\t",
|
|
|
-blending:0,depthTest:!1,depthWrite:!1});a.type="SphericalGaussianBlur";this._blurMaterial=a;this._cubemapShader=this._equirectShader=null;this._compileMaterial(this._blurMaterial)}function pi(a){a=new Ga(3*mb,3*mb,a);a.texture.mapping=306;a.texture.name="PMREM.cubeUv";a.scissorTest=!0;return a}function Ug(a,b,c,d,e){a.viewport.set(b,c,d,e);a.scissor.set(b,c,d,e)}function qi(){var a=new w(1,1);a=new sb({uniforms:{envMap:{value:null},texelSize:{value:a},inputEncoding:{value:lb[3E3]},outputEncoding:{value:lb[3E3]}},
|
|
|
+blending:0,depthTest:!1,depthWrite:!1});this._cubemapShader=this._equirectShader=null;this._compileMaterial(this._blurMaterial)}function pi(a){a=new Ga(3*mb,3*mb,a);a.texture.mapping=306;a.texture.name="PMREM.cubeUv";a.scissorTest=!0;return a}function Ug(a,b,c,d,e){a.viewport.set(b,c,d,e);a.scissor.set(b,c,d,e)}function qi(){var a=new w(1,1);return new sb({name:"EquirectangularToCubeUV",uniforms:{envMap:{value:null},texelSize:{value:a},inputEncoding:{value:lb[3E3]},outputEncoding:{value:lb[3E3]}},
|
|
|
vertexShader:Sg(),fragmentShader:"\nprecision mediump float;\nprecision mediump int;\nvarying vec3 vOutputDirection;\nuniform sampler2D envMap;\nuniform vec2 texelSize;\n\n"+Tg()+"\n\n#include <common>\n\nvoid main() {\n\tgl_FragColor = vec4(0.0);\n\tvec3 outputDirection = normalize(vOutputDirection);\n\tvec2 uv = equirectUv( outputDirection );\n\tvec2 f = fract(uv / texelSize - 0.5);\n\tuv -= f * texelSize;\n\tvec3 tl = envMapTexelToLinear(texture2D(envMap, uv)).rgb;\n\tuv.x += texelSize.x;\n\tvec3 tr = envMapTexelToLinear(texture2D(envMap, uv)).rgb;\n\tuv.y += texelSize.y;\n\tvec3 br = envMapTexelToLinear(texture2D(envMap, uv)).rgb;\n\tuv.x -= texelSize.x;\n\tvec3 bl = envMapTexelToLinear(texture2D(envMap, uv)).rgb;\n\tvec3 tm = mix(tl, tr, f.x);\n\tvec3 bm = mix(bl, br, f.x);\n\tgl_FragColor.rgb = mix(tm, bm, f.y);\n\tgl_FragColor = linearToOutputTexel(gl_FragColor);\n}\n\t\t",
|
|
|
-blending:0,depthTest:!1,depthWrite:!1});a.type="EquirectangularToCubeUV";return a}function ri(){var a=new sb({uniforms:{envMap:{value:null},inputEncoding:{value:lb[3E3]},outputEncoding:{value:lb[3E3]}},vertexShader:Sg(),fragmentShader:"\nprecision mediump float;\nprecision mediump int;\nvarying vec3 vOutputDirection;\nuniform samplerCube envMap;\n\n"+Tg()+"\n\nvoid main() {\n\tgl_FragColor = vec4(0.0);\n\tgl_FragColor.rgb = envMapTexelToLinear(textureCube(envMap, vec3( - vOutputDirection.x, vOutputDirection.yz ))).rgb;\n\tgl_FragColor = linearToOutputTexel(gl_FragColor);\n}\n\t\t",
|
|
|
-blending:0,depthTest:!1,depthWrite:!1});a.type="CubemapToCubeUV";return a}function Sg(){return"\nprecision mediump float;\nprecision mediump int;\nattribute vec3 position;\nattribute vec2 uv;\nattribute float faceIndex;\nvarying vec3 vOutputDirection;\n\n// RH coordinate system; PMREM face-indexing convention\nvec3 getDirection(vec2 uv, float face) {\n\tuv = 2.0 * uv - 1.0;\n\tvec3 direction = vec3(uv, 1.0);\n\tif (face == 0.0) {\n\t\tdirection = direction.zyx; // ( 1, v, u ) pos x\n\t} else if (face == 1.0) {\n\t\tdirection = direction.xzy;\n\t\tdirection.xz *= -1.0; // ( -u, 1, -v ) pos y\n\t} else if (face == 2.0) {\n\t\tdirection.x *= -1.0; // ( -u, v, 1 ) pos z\n\t} else if (face == 3.0) {\n\t\tdirection = direction.zyx;\n\t\tdirection.xz *= -1.0; // ( -1, v, -u ) neg x\n\t} else if (face == 4.0) {\n\t\tdirection = direction.xzy;\n\t\tdirection.xy *= -1.0; // ( -u, -1, v ) neg y\n\t} else if (face == 5.0) {\n\t\tdirection.z *= -1.0; // ( u, v, -1 ) neg z\n\t}\n\treturn direction;\n}\n\nvoid main() {\n\tvOutputDirection = getDirection(uv, faceIndex);\n\tgl_Position = vec4( position, 1.0 );\n}\n\t"}
|
|
|
+blending:0,depthTest:!1,depthWrite:!1})}function ri(){return new sb({name:"CubemapToCubeUV",uniforms:{envMap:{value:null},inputEncoding:{value:lb[3E3]},outputEncoding:{value:lb[3E3]}},vertexShader:Sg(),fragmentShader:"\nprecision mediump float;\nprecision mediump int;\nvarying vec3 vOutputDirection;\nuniform samplerCube envMap;\n\n"+Tg()+"\n\nvoid main() {\n\tgl_FragColor = vec4(0.0);\n\tgl_FragColor.rgb = envMapTexelToLinear(textureCube(envMap, vec3( - vOutputDirection.x, vOutputDirection.yz ))).rgb;\n\tgl_FragColor = linearToOutputTexel(gl_FragColor);\n}\n\t\t",
|
|
|
+blending:0,depthTest:!1,depthWrite:!1})}function Sg(){return"\nprecision mediump float;\nprecision mediump int;\nattribute vec3 position;\nattribute vec2 uv;\nattribute float faceIndex;\nvarying vec3 vOutputDirection;\n\n// RH coordinate system; PMREM face-indexing convention\nvec3 getDirection(vec2 uv, float face) {\n\tuv = 2.0 * uv - 1.0;\n\tvec3 direction = vec3(uv, 1.0);\n\tif (face == 0.0) {\n\t\tdirection = direction.zyx; // ( 1, v, u ) pos x\n\t} else if (face == 1.0) {\n\t\tdirection = direction.xzy;\n\t\tdirection.xz *= -1.0; // ( -u, 1, -v ) pos y\n\t} else if (face == 2.0) {\n\t\tdirection.x *= -1.0; // ( -u, v, 1 ) pos z\n\t} else if (face == 3.0) {\n\t\tdirection = direction.zyx;\n\t\tdirection.xz *= -1.0; // ( -1, v, -u ) neg x\n\t} else if (face == 4.0) {\n\t\tdirection = direction.xzy;\n\t\tdirection.xy *= -1.0; // ( -u, -1, v ) neg y\n\t} else if (face == 5.0) {\n\t\tdirection.z *= -1.0; // ( u, v, -1 ) neg z\n\t}\n\treturn direction;\n}\n\nvoid main() {\n\tvOutputDirection = getDirection(uv, faceIndex);\n\tgl_Position = vec4( position, 1.0 );\n}\n\t"}
|
|
|
function Tg(){return"\nuniform int inputEncoding;\nuniform int outputEncoding;\n\n#include <encodings_pars_fragment>\n\nvec4 inputTexelToLinear(vec4 value){\n\tif(inputEncoding == 0){\n\t\treturn value;\n\t}else if(inputEncoding == 1){\n\t\treturn sRGBToLinear(value);\n\t}else if(inputEncoding == 2){\n\t\treturn RGBEToLinear(value);\n\t}else if(inputEncoding == 3){\n\t\treturn RGBMToLinear(value, 7.0);\n\t}else if(inputEncoding == 4){\n\t\treturn RGBMToLinear(value, 16.0);\n\t}else if(inputEncoding == 5){\n\t\treturn RGBDToLinear(value, 256.0);\n\t}else{\n\t\treturn GammaToLinear(value, 2.2);\n\t}\n}\n\nvec4 linearToOutputTexel(vec4 value){\n\tif(outputEncoding == 0){\n\t\treturn value;\n\t}else if(outputEncoding == 1){\n\t\treturn LinearTosRGB(value);\n\t}else if(outputEncoding == 2){\n\t\treturn LinearToRGBE(value);\n\t}else if(outputEncoding == 3){\n\t\treturn LinearToRGBM(value, 7.0);\n\t}else if(outputEncoding == 4){\n\t\treturn LinearToRGBM(value, 16.0);\n\t}else if(outputEncoding == 5){\n\t\treturn LinearToRGBD(value, 256.0);\n\t}else{\n\t\treturn LinearToGamma(value, 2.2);\n\t}\n}\n\nvec4 envMapTexelToLinear(vec4 color) {\n\treturn inputTexelToLinear(color);\n}\n\t"}
|
|
|
-function si(a){console.warn("THREE.ClosedSplineCurve3 has been deprecated. Use THREE.CatmullRomCurve3 instead.");pa.call(this,a);this.type="catmullrom";this.closed=!0}function ti(a){console.warn("THREE.SplineCurve3 has been deprecated. Use THREE.CatmullRomCurve3 instead.");pa.call(this,a);this.type="catmullrom"}function Vg(a){console.warn("THREE.Spline has been removed. Use THREE.CatmullRomCurve3 instead.");pa.call(this,a);this.type="catmullrom"}void 0===Number.EPSILON&&(Number.EPSILON=Math.pow(2,
|
|
|
+function si(a){console.warn("THREE.ClosedSplineCurve3 has been deprecated. Use THREE.CatmullRomCurve3 instead.");oa.call(this,a);this.type="catmullrom";this.closed=!0}function ti(a){console.warn("THREE.SplineCurve3 has been deprecated. Use THREE.CatmullRomCurve3 instead.");oa.call(this,a);this.type="catmullrom"}function Vg(a){console.warn("THREE.Spline has been removed. Use THREE.CatmullRomCurve3 instead.");oa.call(this,a);this.type="catmullrom"}void 0===Number.EPSILON&&(Number.EPSILON=Math.pow(2,
|
|
|
-52));void 0===Number.isInteger&&(Number.isInteger=function(a){return"number"===typeof a&&isFinite(a)&&Math.floor(a)===a});void 0===Math.sign&&(Math.sign=function(a){return 0>a?-1:0<a?1:+a});!1==="name"in Function.prototype&&Object.defineProperty(Function.prototype,"name",{get:function(){return this.toString().match(/^\s*function\s*([^\(\s]*)/)[1]}});void 0===Object.assign&&(Object.assign=function(a){if(void 0===a||null===a)throw new TypeError("Cannot convert undefined or null to object");for(var b=
|
|
|
Object(a),c=1;c<arguments.length;c++){var d=arguments[c];if(void 0!==d&&null!==d)for(var e in d)Object.prototype.hasOwnProperty.call(d,e)&&(b[e]=d[e])}return b});Object.assign(ta.prototype,{addEventListener:function(a,b){void 0===this._listeners&&(this._listeners={});var c=this._listeners;void 0===c[a]&&(c[a]=[]);-1===c[a].indexOf(b)&&c[a].push(b)},hasEventListener:function(a,b){if(void 0===this._listeners)return!1;var c=this._listeners;return void 0!==c[a]&&-1!==c[a].indexOf(b)},removeEventListener:function(a,
|
|
|
b){void 0!==this._listeners&&(a=this._listeners[a],void 0!==a&&(b=a.indexOf(b),-1!==b&&a.splice(b,1)))},dispatchEvent:function(a){if(void 0!==this._listeners){var b=this._listeners[a.type];if(void 0!==b){a.target=this;b=b.slice(0);for(var c=0,d=b.length;c<d;c++)b[c].call(this,a)}}}});for(var xa=[],se=0;256>se;se++)xa[se]=(16>se?"0":"")+se.toString(16);var L={DEG2RAD:Math.PI/180,RAD2DEG:180/Math.PI,generateUUID:function(){var a=4294967295*Math.random()|0,b=4294967295*Math.random()|0,c=4294967295*Math.random()|
|
|
@@ -383,9 +382,9 @@ this.z=0>this.z?Math.ceil(this.z):Math.floor(this.z);this.w=0>this.w?Math.ceil(t
|
|
|
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){this.x=a.x+(b.x-a.x)*c;this.y=a.y+(b.y-a.y)*c;this.z=a.z+(b.z-a.z)*c;this.w=a.w+(b.w-a.w)*c;return this},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},random:function(){this.x=Math.random();this.y=
|
|
|
Math.random();this.z=Math.random();this.w=Math.random();return this}});Ga.prototype=Object.assign(Object.create(ta.prototype),{constructor:Ga,isWebGLRenderTarget:!0,setSize:function(a,b){if(this.width!==a||this.height!==b)this.width=a,this.height=b,this.texture.image.width=a,this.texture.image.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"})}});Zf.prototype=Object.assign(Object.create(Ga.prototype),{constructor:Zf,isWebGLMultisampleRenderTarget:!0,copy:function(a){Ga.prototype.copy.call(this,a);this.samples=a.samples;return this}});Object.assign(ua,{slerp:function(a,b,c,d){return c.copy(a).slerp(b,d)},slerpFlat:function(a,b,c,d,e,f,g){var h=
|
|
|
+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"})}});Zf.prototype=Object.assign(Object.create(Ga.prototype),{constructor:Zf,isWebGLMultisampleRenderTarget:!0,copy:function(a){Ga.prototype.copy.call(this,a);this.samples=a.samples;return this}});Object.assign(la,{slerp:function(a,b,c,d){return c.copy(a).slerp(b,d)},slerpFlat:function(a,b,c,d,e,f,g){var h=
|
|
|
c[d+0],l=c[d+1],n=c[d+2];c=c[d+3];d=e[f+0];var k=e[f+1],p=e[f+2];e=e[f+3];if(c!==e||h!==d||l!==k||n!==p){f=1-g;var m=h*d+l*k+n*p+c*e,r=0<=m?1:-1,q=1-m*m;q>Number.EPSILON&&(q=Math.sqrt(q),m=Math.atan2(q,m*r),f=Math.sin(f*m)/q,g=Math.sin(g*m)/q);r*=g;h=h*f+d*r;l=l*f+k*r;n=n*f+p*r;c=c*f+e*r;f===1-g&&(g=1/Math.sqrt(h*h+l*l+n*n+c*c),h*=g,l*=g,n*=g,c*=g)}a[b]=h;a[b+1]=l;a[b+2]=n;a[b+3]=c},multiplyQuaternionsFlat:function(a,b,c,d,e,f){var g=c[d],h=c[d+1],l=c[d+2];c=c[d+3];d=e[f];var n=e[f+1],k=e[f+2];e=
|
|
|
-e[f+3];a[b]=g*e+c*d+h*k-l*n;a[b+1]=h*e+c*n+l*d-g*k;a[b+2]=l*e+c*k+g*n-h*d;a[b+3]=c*e-g*d-h*n-l*k;return a}});Object.defineProperties(ua.prototype,{x:{get:function(){return this._x},set:function(a){this._x=a;this._onChangeCallback()}},y:{get:function(){return this._y},set:function(a){this._y=a;this._onChangeCallback()}},z:{get:function(){return this._z},set:function(a){this._z=a;this._onChangeCallback()}},w:{get:function(){return this._w},set:function(a){this._w=a;this._onChangeCallback()}}});Object.assign(ua.prototype,
|
|
|
+e[f+3];a[b]=g*e+c*d+h*k-l*n;a[b+1]=h*e+c*n+l*d-g*k;a[b+2]=l*e+c*k+g*n-h*d;a[b+3]=c*e-g*d-h*n-l*k;return a}});Object.defineProperties(la.prototype,{x:{get:function(){return this._x},set:function(a){this._x=a;this._onChangeCallback()}},y:{get:function(){return this._y},set:function(a){this._y=a;this._onChangeCallback()}},z:{get:function(){return this._z},set:function(a){this._z=a;this._onChangeCallback()}},w:{get:function(){return this._w},set:function(a){this._w=a;this._onChangeCallback()}}});Object.assign(la.prototype,
|
|
|
{isQuaternion:!0,set:function(a,b,c,d){this._x=a;this._y=b;this._z=c;this._w=d;this._onChangeCallback();return this},clone:function(){return new this.constructor(this._x,this._y,this._z,this._w)},copy:function(a){this._x=a.x;this._y=a.y;this._z=a.z;this._w=a.w;this._onChangeCallback();return this},setFromEuler:function(a,b){if(!a||!a.isEuler)throw Error("THREE.Quaternion: .setFromEuler() now expects an Euler rotation rather than a Vector3 and order.");var c=a._x,d=a._y,e=a._z;a=a.order;var f=Math.cos,
|
|
|
g=Math.sin,h=f(c/2),l=f(d/2);f=f(e/2);c=g(c/2);d=g(d/2);e=g(e/2);switch(a){case "XYZ":this._x=c*l*f+h*d*e;this._y=h*d*f-c*l*e;this._z=h*l*e+c*d*f;this._w=h*l*f-c*d*e;break;case "YXZ":this._x=c*l*f+h*d*e;this._y=h*d*f-c*l*e;this._z=h*l*e-c*d*f;this._w=h*l*f+c*d*e;break;case "ZXY":this._x=c*l*f-h*d*e;this._y=h*d*f+c*l*e;this._z=h*l*e+c*d*f;this._w=h*l*f-c*d*e;break;case "ZYX":this._x=c*l*f-h*d*e;this._y=h*d*f+c*l*e;this._z=h*l*e-c*d*f;this._w=h*l*f+c*d*e;break;case "YZX":this._x=c*l*f+h*d*e;this._y=
|
|
|
h*d*f+c*l*e;this._z=h*l*e-c*d*f;this._w=h*l*f-c*d*e;break;case "XZY":this._x=c*l*f-h*d*e;this._y=h*d*f-c*l*e;this._z=h*l*e+c*d*f;this._w=h*l*f+c*d*e;break;default:console.warn("THREE.Quaternion: .setFromEuler() encountered an unknown order: "+a)}!1!==b&&this._onChangeCallback();return this},setFromAxisAngle:function(a,b){b/=2;var c=Math.sin(b);this._x=a.x*c;this._y=a.y*c;this._z=a.z*c;this._w=Math.cos(b);this._onChangeCallback();return this},setFromRotationMatrix:function(a){var b=a.elements,c=b[0];
|
|
@@ -395,7 +394,7 @@ b){var c=a.dot(b)+1;1E-6>c?(c=0,Math.abs(a.x)>Math.abs(a.z)?(this._x=-a.y,this._
|
|
|
multiply:function(a,b){return void 0!==b?(console.warn("THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead."),this.multiplyQuaternions(a,b)):this.multiplyQuaternions(this,a)},premultiply:function(a){return this.multiplyQuaternions(a,this)},multiplyQuaternions:function(a,b){var c=a._x,d=a._y,e=a._z;a=a._w;var f=b._x,g=b._y,h=b._z;b=b._w;this._x=c*b+a*f+d*h-e*g;this._y=d*b+a*g+e*f-c*h;this._z=e*b+a*h+c*g-d*f;this._w=a*b-c*f-d*g-e*h;this._onChangeCallback();
|
|
|
return this},slerp:function(a,b){if(0===b)return this;if(1===b)return this.copy(a);var c=this._x,d=this._y,e=this._z,f=this._w,g=f*a._w+c*a._x+d*a._y+e*a._z;0>g?(this._w=-a._w,this._x=-a._x,this._y=-a._y,this._z=-a._z,g=-g):this.copy(a);if(1<=g)return this._w=f,this._x=c,this._y=d,this._z=e,this;a=1-g*g;if(a<=Number.EPSILON)return g=1-b,this._w=g*f+b*this._w,this._x=g*c+b*this._x,this._y=g*d+b*this._y,this._z=g*e+b*this._z,this.normalize(),this._onChangeCallback(),this;a=Math.sqrt(a);var h=Math.atan2(a,
|
|
|
g);g=Math.sin((1-b)*h)/a;b=Math.sin(b*h)/a;this._w=f*g+this._w*b;this._x=c*g+this._x*b;this._y=d*g+this._y*b;this._z=e*g+this._z*b;this._onChangeCallback();return this},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];this._onChangeCallback();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){this._x=a.getX(b);this._y=a.getY(b);this._z=a.getZ(b);this._w=a.getW(b);return this},_onChange:function(a){this._onChangeCallback=a;return this},_onChangeCallback:function(){}});var Wg=new m,ui=new ua;Object.assign(m.prototype,{isVector3:!0,set:function(a,b,c){this.x=a;this.y=b;this.z=c;return this},setScalar:function(a){this.z=this.y=this.x=a;return this},setX:function(a){this.x=a;return this},setY:function(a){this.y=a;return this},setZ:function(a){this.z=
|
|
|
+3]=this._w;return a},fromBufferAttribute:function(a,b){this._x=a.getX(b);this._y=a.getY(b);this._z=a.getZ(b);this._w=a.getW(b);return this},_onChange:function(a){this._onChangeCallback=a;return this},_onChangeCallback:function(){}});var Wg=new m,ui=new la;Object.assign(m.prototype,{isVector3:!0,set:function(a,b,c){this.x=a;this.y=b;this.z=c;return this},setScalar:function(a){this.z=this.y=this.x=a;return this},setX:function(a){this.x=a;return this},setY:function(a){this.y=a;return this},setZ:function(a){this.z=
|
|
|
a;return this},setComponent:function(a,b){switch(a){case 0:this.x=b;break;case 1:this.y=b;break;case 2:this.z=b;break;default:throw Error("index is out of range: "+a);}return this},getComponent:function(a){switch(a){case 0:return this.x;case 1:return this.y;case 2:return this.z;default:throw Error("index is out of range: "+a);}},clone:function(){return new this.constructor(this.x,this.y,this.z)},copy:function(a){this.x=a.x;this.y=a.y;this.z=a.z;return this},add:function(a,b){if(void 0!==b)return console.warn("THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead."),
|
|
|
this.addVectors(a,b);this.x+=a.x;this.y+=a.y;this.z+=a.z;return this},addScalar:function(a){this.x+=a;this.y+=a;this.z+=a;return this},addVectors:function(a,b){this.x=a.x+b.x;this.y=a.y+b.y;this.z=a.z+b.z;return this},addScaledVector:function(a,b){this.x+=a.x*b;this.y+=a.y*b;this.z+=a.z*b;return this},sub:function(a,b){if(void 0!==b)return console.warn("THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead."),this.subVectors(a,b);this.x-=a.x;this.y-=a.y;this.z-=a.z;
|
|
|
return this},subScalar:function(a){this.x-=a;this.y-=a;this.z-=a;return this},subVectors:function(a,b){this.x=a.x-b.x;this.y=a.y-b.y;this.z=a.z-b.z;return this},multiply:function(a,b){if(void 0!==b)return console.warn("THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead."),this.multiplyVectors(a,b);this.x*=a.x;this.y*=a.y;this.z*=a.z;return this},multiplyScalar:function(a){this.x*=a;this.y*=a;this.z*=a;return this},multiplyVectors:function(a,b){this.x=a.x*
|
|
@@ -427,20 +426,20 @@ b){var c=Math.cos(b);b=Math.sin(b);var d=1-c,e=a.x,f=a.y;a=a.z;var g=d*e,h=d*f;t
|
|
|
c.y;c=c.z;d[0]=(1-(m+g))*t;d[1]=(p+h)*t;d[2]=(e-k)*t;d[3]=0;d[4]=(p-h)*r;d[5]=(1-(b+g))*r;d[6]=(f+l)*r;d[7]=0;d[8]=(e+k)*c;d[9]=(f-l)*c;d[10]=(1-(b+m))*c;d[11]=0;d[12]=a.x;d[13]=a.y;d[14]=a.z;d[15]=1;return this},decompose:function(a,b,c){var d=this.elements,e=kd.set(d[0],d[1],d[2]).length(),f=kd.set(d[4],d[5],d[6]).length(),g=kd.set(d[8],d[9],d[10]).length();0>this.determinant()&&(e=-e);a.x=d[12];a.y=d[13];a.z=d[14];ba.copy(this);a=1/e;d=1/f;var h=1/g;ba.elements[0]*=a;ba.elements[1]*=a;ba.elements[2]*=
|
|
|
a;ba.elements[4]*=d;ba.elements[5]*=d;ba.elements[6]*=d;ba.elements[8]*=h;ba.elements[9]*=h;ba.elements[10]*=h;b.setFromRotationMatrix(ba);c.x=e;c.y=f;c.z=g;return this},makePerspective:function(a,b,c,d,e,f){void 0===f&&console.warn("THREE.Matrix4: .makePerspective() has been redefined and has a new signature. Please check the docs.");var g=this.elements;g[0]=2*e/(b-a);g[4]=0;g[8]=(b+a)/(b-a);g[12]=0;g[1]=0;g[5]=2*e/(c-d);g[9]=(c+d)/(c-d);g[13]=0;g[2]=0;g[6]=0;g[10]=-(f+e)/(f-e);g[14]=-2*f*e/(f-e);
|
|
|
g[3]=0;g[7]=0;g[11]=-1;g[15]=0;return this},makeOrthographic:function(a,b,c,d,e,f){var g=this.elements,h=1/(b-a),l=1/(c-d),k=1/(f-e);g[0]=2*h;g[4]=0;g[8]=0;g[12]=-((b+a)*h);g[1]=0;g[5]=2*l;g[9]=0;g[13]=-((c+d)*l);g[2]=0;g[6]=0;g[10]=-2*k;g[14]=-((f+e)*k);g[3]=0;g[7]=0;g[11]=0;g[15]=1;return this},equals:function(a){var b=this.elements;a=a.elements;for(var c=0;16>c;c++)if(b[c]!==a[c])return!1;return!0},fromArray:function(a,b){void 0===b&&(b=0);for(var c=0;16>c;c++)this.elements[c]=a[c+b];return this},
|
|
|
-toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);var c=this.elements;a[b]=c[0];a[b+1]=c[1];a[b+2]=c[2];a[b+3]=c[3];a[b+4]=c[4];a[b+5]=c[5];a[b+6]=c[6];a[b+7]=c[7];a[b+8]=c[8];a[b+9]=c[9];a[b+10]=c[10];a[b+11]=c[11];a[b+12]=c[12];a[b+13]=c[13];a[b+14]=c[14];a[b+15]=c[15];return a}});var vi=new M,wi=new ua;Tb.RotationOrders="XYZ YZX ZXY XZY YXZ ZYX".split(" ");Tb.DefaultOrder="XYZ";Object.defineProperties(Tb.prototype,{x:{get:function(){return this._x},set:function(a){this._x=a;this._onChangeCallback()}},
|
|
|
+toArray:function(a,b){void 0===a&&(a=[]);void 0===b&&(b=0);var c=this.elements;a[b]=c[0];a[b+1]=c[1];a[b+2]=c[2];a[b+3]=c[3];a[b+4]=c[4];a[b+5]=c[5];a[b+6]=c[6];a[b+7]=c[7];a[b+8]=c[8];a[b+9]=c[9];a[b+10]=c[10];a[b+11]=c[11];a[b+12]=c[12];a[b+13]=c[13];a[b+14]=c[14];a[b+15]=c[15];return a}});var vi=new M,wi=new la;Tb.RotationOrders="XYZ YZX ZXY XZY YXZ ZYX".split(" ");Tb.DefaultOrder="XYZ";Object.defineProperties(Tb.prototype,{x:{get:function(){return this._x},set:function(a){this._x=a;this._onChangeCallback()}},
|
|
|
y:{get:function(){return this._y},set:function(a){this._y=a;this._onChangeCallback()}},z:{get:function(){return this._z},set:function(a){this._z=a;this._onChangeCallback()}},order:{get:function(){return this._order},set:function(a){this._order=a;this._onChangeCallback()}}});Object.assign(Tb.prototype,{isEuler:!0,set:function(a,b,c,d){this._x=a;this._y=b;this._z=c;this._order=d||this._order;this._onChangeCallback();return this},clone:function(){return new this.constructor(this._x,this._y,this._z,this._order)},
|
|
|
copy:function(a){this._x=a._x;this._y=a._y;this._z=a._z;this._order=a._order;this._onChangeCallback();return this},setFromRotationMatrix:function(a,b,c){var d=L.clamp,e=a.elements;a=e[0];var f=e[4],g=e[8],h=e[1],l=e[5],k=e[9],t=e[2],p=e[6];e=e[10];b=b||this._order;switch(b){case "XYZ":this._y=Math.asin(d(g,-1,1));.9999999>Math.abs(g)?(this._x=Math.atan2(-k,e),this._z=Math.atan2(-f,a)):(this._x=Math.atan2(p,l),this._z=0);break;case "YXZ":this._x=Math.asin(-d(k,-1,1));.9999999>Math.abs(k)?(this._y=
|
|
|
Math.atan2(g,e),this._z=Math.atan2(h,l)):(this._y=Math.atan2(-t,a),this._z=0);break;case "ZXY":this._x=Math.asin(d(p,-1,1));.9999999>Math.abs(p)?(this._y=Math.atan2(-t,e),this._z=Math.atan2(-f,l)):(this._y=0,this._z=Math.atan2(h,a));break;case "ZYX":this._y=Math.asin(-d(t,-1,1));.9999999>Math.abs(t)?(this._x=Math.atan2(p,e),this._z=Math.atan2(h,a)):(this._x=0,this._z=Math.atan2(-f,l));break;case "YZX":this._z=Math.asin(d(h,-1,1));.9999999>Math.abs(h)?(this._x=Math.atan2(-k,l),this._y=Math.atan2(-t,
|
|
|
a)):(this._x=0,this._y=Math.atan2(g,e));break;case "XZY":this._z=Math.asin(-d(f,-1,1));.9999999>Math.abs(f)?(this._x=Math.atan2(p,l),this._y=Math.atan2(g,a)):(this._x=Math.atan2(-k,e),this._y=0);break;default:console.warn("THREE.Euler: .setFromRotationMatrix() encountered an unknown order: "+b)}this._order=b;!1!==c&&this._onChangeCallback();return this},setFromQuaternion:function(a,b,c){vi.makeRotationFromQuaternion(a);return this.setFromRotationMatrix(vi,b,c)},setFromVector3:function(a,b){return this.set(a.x,
|
|
|
a.y,a.z,b||this._order)},reorder:function(a){wi.setFromEuler(this);return this.setFromQuaternion(wi,a)},equals:function(a){return a._x===this._x&&a._y===this._y&&a._z===this._z&&a._order===this._order},fromArray:function(a){this._x=a[0];this._y=a[1];this._z=a[2];void 0!==a[3]&&(this._order=a[3]);this._onChangeCallback();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._order;return a},toVector3:function(a){return a?a.set(this._x,
|
|
|
-this._y,this._z):new m(this._x,this._y,this._z)},_onChange:function(a){this._onChangeCallback=a;return this},_onChangeCallback:function(){}});Object.assign(De.prototype,{set:function(a){this.mask=1<<a|0},enable:function(a){this.mask=this.mask|1<<a|0},enableAll:function(){this.mask=-1},toggle:function(a){this.mask^=1<<a|0},disable:function(a){this.mask&=~(1<<a|0)},disableAll:function(){this.mask=0},test:function(a){return 0!==(this.mask&a.mask)}});var gj=0,xi=new m,ld=new ua,wb=new M,Bf=new m,te=new m,
|
|
|
-Kk=new m,Lk=new ua,yi=new m(1,0,0),zi=new m(0,1,0),Ai=new m(0,0,1),Mk={type:"added"},Nk={type:"removed"};y.DefaultUp=new m(0,1,0);y.DefaultMatrixAutoUpdate=!0;y.prototype=Object.assign(Object.create(ta.prototype),{constructor:y,isObject3D:!0,onBeforeRender:function(){},onAfterRender:function(){},applyMatrix4:function(a){this.matrixAutoUpdate&&this.updateMatrix();this.matrix.premultiply(a);this.matrix.decompose(this.position,this.quaternion,this.scale)},applyQuaternion:function(a){this.quaternion.premultiply(a);
|
|
|
+this._y,this._z):new m(this._x,this._y,this._z)},_onChange:function(a){this._onChangeCallback=a;return this},_onChangeCallback:function(){}});Object.assign(De.prototype,{set:function(a){this.mask=1<<a|0},enable:function(a){this.mask=this.mask|1<<a|0},enableAll:function(){this.mask=-1},toggle:function(a){this.mask^=1<<a|0},disable:function(a){this.mask&=~(1<<a|0)},disableAll:function(){this.mask=0},test:function(a){return 0!==(this.mask&a.mask)}});var gj=0,xi=new m,ld=new la,wb=new M,Bf=new m,te=new m,
|
|
|
+Kk=new m,Lk=new la,yi=new m(1,0,0),zi=new m(0,1,0),Ai=new m(0,0,1),Mk={type:"added"},Nk={type:"removed"};y.DefaultUp=new m(0,1,0);y.DefaultMatrixAutoUpdate=!0;y.prototype=Object.assign(Object.create(ta.prototype),{constructor:y,isObject3D:!0,onBeforeRender:function(){},onAfterRender:function(){},applyMatrix4:function(a){this.matrixAutoUpdate&&this.updateMatrix();this.matrix.premultiply(a);this.matrix.decompose(this.position,this.quaternion,this.scale)},applyQuaternion:function(a){this.quaternion.premultiply(a);
|
|
|
return this},setRotationFromAxisAngle:function(a,b){this.quaternion.setFromAxisAngle(a,b)},setRotationFromEuler:function(a){this.quaternion.setFromEuler(a,!0)},setRotationFromMatrix:function(a){this.quaternion.setFromRotationMatrix(a)},setRotationFromQuaternion:function(a){this.quaternion.copy(a)},rotateOnAxis:function(a,b){ld.setFromAxisAngle(a,b);this.quaternion.multiply(ld);return this},rotateOnWorldAxis:function(a,b){ld.setFromAxisAngle(a,b);this.quaternion.premultiply(ld);return this},rotateX:function(a){return this.rotateOnAxis(yi,
|
|
|
a)},rotateY:function(a){return this.rotateOnAxis(zi,a)},rotateZ:function(a){return this.rotateOnAxis(Ai,a)},translateOnAxis:function(a,b){xi.copy(a).applyQuaternion(this.quaternion);this.position.add(xi.multiplyScalar(b));return this},translateX:function(a){return this.translateOnAxis(yi,a)},translateY:function(a){return this.translateOnAxis(zi,a)},translateZ:function(a){return this.translateOnAxis(Ai,a)},localToWorld:function(a){return a.applyMatrix4(this.matrixWorld)},worldToLocal:function(a){return a.applyMatrix4(wb.getInverse(this.matrixWorld))},
|
|
|
lookAt:function(a,b,c){a.isVector3?Bf.copy(a):Bf.set(a,b,c);a=this.parent;this.updateWorldMatrix(!0,!1);te.setFromMatrixPosition(this.matrixWorld);this.isCamera||this.isLight?wb.lookAt(te,Bf,this.up):wb.lookAt(Bf,te,this.up);this.quaternion.setFromRotationMatrix(wb);a&&(wb.extractRotation(a.matrixWorld),ld.setFromRotationMatrix(wb),this.quaternion.premultiply(ld.inverse()))},add:function(a){if(1<arguments.length){for(var b=0;b<arguments.length;b++)this.add(arguments[b]);return this}if(a===this)return console.error("THREE.Object3D.add: object can't be added as a child of itself.",
|
|
|
a),this;a&&a.isObject3D?(null!==a.parent&&a.parent.remove(a),a.parent=this,this.children.push(a),a.dispatchEvent(Mk)):console.error("THREE.Object3D.add: object not an instance of THREE.Object3D.",a);return this},remove:function(a){if(1<arguments.length){for(var b=0;b<arguments.length;b++)this.remove(arguments[b]);return this}b=this.children.indexOf(a);-1!==b&&(a.parent=null,this.children.splice(b,1),a.dispatchEvent(Nk));return this},attach:function(a){this.updateWorldMatrix(!0,!1);wb.getInverse(this.matrixWorld);
|
|
|
null!==a.parent&&(a.parent.updateWorldMatrix(!0,!1),wb.multiply(a.parent.matrixWorld));a.applyMatrix4(wb);a.updateWorldMatrix(!1,!1);this.add(a);return this},getObjectById:function(a){return this.getObjectByProperty("id",a)},getObjectByName:function(a){return this.getObjectByProperty("name",a)},getObjectByProperty:function(a,b){if(this[a]===b)return this;for(var c=0,d=this.children.length;c<d;c++){var e=this.children[c].getObjectByProperty(a,b);if(void 0!==e)return e}},getWorldPosition:function(a){void 0===
|
|
|
-a&&(console.warn("THREE.Object3D: .getWorldPosition() target is now required"),a=new m);this.updateMatrixWorld(!0);return a.setFromMatrixPosition(this.matrixWorld)},getWorldQuaternion:function(a){void 0===a&&(console.warn("THREE.Object3D: .getWorldQuaternion() target is now required"),a=new ua);this.updateMatrixWorld(!0);this.matrixWorld.decompose(te,a,Kk);return a},getWorldScale:function(a){void 0===a&&(console.warn("THREE.Object3D: .getWorldScale() target is now required"),a=new m);this.updateMatrixWorld(!0);
|
|
|
+a&&(console.warn("THREE.Object3D: .getWorldPosition() target is now required"),a=new m);this.updateMatrixWorld(!0);return a.setFromMatrixPosition(this.matrixWorld)},getWorldQuaternion:function(a){void 0===a&&(console.warn("THREE.Object3D: .getWorldQuaternion() target is now required"),a=new la);this.updateMatrixWorld(!0);this.matrixWorld.decompose(te,a,Kk);return a},getWorldScale:function(a){void 0===a&&(console.warn("THREE.Object3D: .getWorldScale() target is now required"),a=new m);this.updateMatrixWorld(!0);
|
|
|
this.matrixWorld.decompose(te,Lk,a);return a},getWorldDirection:function(a){void 0===a&&(console.warn("THREE.Object3D: .getWorldDirection() target is now required"),a=new m);this.updateMatrixWorld(!0);var b=this.matrixWorld.elements;return a.set(b[8],b[9],b[10]).normalize()},raycast:function(){},traverse:function(a){a(this);for(var b=this.children,c=0,d=b.length;c<d;c++)b[c].traverse(a)},traverseVisible:function(a){if(!1!==this.visible){a(this);for(var b=this.children,c=0,d=b.length;c<d;c++)b[c].traverseVisible(a)}},
|
|
|
traverseAncestors:function(a){var b=this.parent;null!==b&&(a(b),b.traverseAncestors(a))},updateMatrix:function(){this.matrix.compose(this.position,this.quaternion,this.scale);this.matrixWorldNeedsUpdate=!0},updateMatrixWorld:function(a){this.matrixAutoUpdate&&this.updateMatrix();if(this.matrixWorldNeedsUpdate||a)null===this.parent?this.matrixWorld.copy(this.matrix):this.matrixWorld.multiplyMatrices(this.parent.matrixWorld,this.matrix),this.matrixWorldNeedsUpdate=!1,a=!0;for(var b=this.children,c=
|
|
|
0,d=b.length;c<d;c++)b[c].updateMatrixWorld(a)},updateWorldMatrix:function(a,b){var c=this.parent;!0===a&&null!==c&&c.updateWorldMatrix(!0,!1);this.matrixAutoUpdate&&this.updateMatrix();null===this.parent?this.matrixWorld.copy(this.matrix):this.matrixWorld.multiplyMatrices(this.parent.matrixWorld,this.matrix);if(!0===b)for(a=this.children,b=0,c=a.length;b<c;b++)a[b].updateWorldMatrix(!1,!0)},toJSON:function(a){function b(b,c){void 0===b[c.uuid]&&(b[c.uuid]=c.toJSON(a));return c.uuid}function c(a){var b=
|
|
@@ -476,11 +475,11 @@ this.constant=b;return this},setComponents:function(a,b,c,d){this.normal.set(a,b
|
|
|
return this},normalize:function(){var a=1/this.normal.length();this.normal.multiplyScalar(a);this.constant*=a;return this},negate:function(){this.constant*=-1;this.normal.negate();return this},distanceToPoint:function(a){return this.normal.dot(a)+this.constant},distanceToSphere:function(a){return this.distanceToPoint(a.center)-a.radius},projectPoint:function(a,b){void 0===b&&(console.warn("THREE.Plane: .projectPoint() target is now required"),b=new m);return b.copy(this.normal).multiplyScalar(-this.distanceToPoint(a)).add(a)},
|
|
|
intersectLine:function(a,b){void 0===b&&(console.warn("THREE.Plane: .intersectLine() target is now required"),b=new m);var c=a.delta(ah),d=this.normal.dot(c);if(0===d){if(0===this.distanceToPoint(a.start))return b.copy(a.start)}else if(d=-(a.start.dot(this.normal)+this.constant)/d,!(0>d||1<d))return b.copy(c).multiplyScalar(d).add(a.start)},intersectsLine:function(a){var b=this.distanceToPoint(a.start);a=this.distanceToPoint(a.end);return 0>b&&0<a||0>a&&0<b},intersectsBox:function(a){return a.intersectsPlane(this)},
|
|
|
intersectsSphere:function(a){return a.intersectsPlane(this)},coplanarPoint:function(a){void 0===a&&(console.warn("THREE.Plane: .coplanarPoint() target is now required"),a=new m);return a.copy(this.normal).multiplyScalar(-this.constant)},applyMatrix4:function(a,b){b=b||Qk.getNormalMatrix(a);a=this.coplanarPoint(ah).applyMatrix4(a);b=this.normal.applyMatrix3(b).normalize();this.constant=-a.dot(b);return this},translate:function(a){this.constant-=a.dot(this.normal);return this},equals:function(a){return a.normal.equals(this.normal)&&
|
|
|
-a.constant===this.constant}});var bb=new m,zb=new m,bh=new m,Ab=new m,pd=new m,qd=new m,Bi=new m,ch=new m,dh=new m,eh=new m;Object.assign(oa,{getNormal:function(a,b,c,d){void 0===d&&(console.warn("THREE.Triangle: .getNormal() target is now required"),d=new m);d.subVectors(c,b);bb.subVectors(a,b);d.cross(bb);a=d.lengthSq();return 0<a?d.multiplyScalar(1/Math.sqrt(a)):d.set(0,0,0)},getBarycoord:function(a,b,c,d,e){bb.subVectors(d,b);zb.subVectors(c,b);bh.subVectors(a,b);a=bb.dot(bb);b=bb.dot(zb);c=bb.dot(bh);
|
|
|
-var f=zb.dot(zb);d=zb.dot(bh);var g=a*f-b*b;void 0===e&&(console.warn("THREE.Triangle: .getBarycoord() target is now required"),e=new m);if(0===g)return e.set(-2,-1,-1);g=1/g;f=(f*c-b*d)*g;a=(a*d-b*c)*g;return e.set(1-f-a,a,f)},containsPoint:function(a,b,c,d){oa.getBarycoord(a,b,c,d,Ab);return 0<=Ab.x&&0<=Ab.y&&1>=Ab.x+Ab.y},getUV:function(a,b,c,d,e,f,g,h){this.getBarycoord(a,b,c,d,Ab);h.set(0,0);h.addScaledVector(e,Ab.x);h.addScaledVector(f,Ab.y);h.addScaledVector(g,Ab.z);return h},isFrontFacing:function(a,
|
|
|
-b,c,d){bb.subVectors(c,b);zb.subVectors(a,b);return 0>bb.cross(zb).dot(d)?!0:!1}});Object.assign(oa.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},getArea:function(){bb.subVectors(this.c,this.b);zb.subVectors(this.a,
|
|
|
-this.b);return.5*bb.cross(zb).length()},getMidpoint:function(a){void 0===a&&(console.warn("THREE.Triangle: .getMidpoint() target is now required"),a=new m);return a.addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)},getNormal:function(a){return oa.getNormal(this.a,this.b,this.c,a)},getPlane:function(a){void 0===a&&(console.warn("THREE.Triangle: .getPlane() target is now required"),a=new Ua);return a.setFromCoplanarPoints(this.a,this.b,this.c)},getBarycoord:function(a,b){return oa.getBarycoord(a,
|
|
|
-this.a,this.b,this.c,b)},getUV:function(a,b,c,d,e){return oa.getUV(a,this.a,this.b,this.c,b,c,d,e)},containsPoint:function(a){return oa.containsPoint(a,this.a,this.b,this.c)},isFrontFacing:function(a){return oa.isFrontFacing(this.a,this.b,this.c,a)},intersectsBox:function(a){return a.intersectsTriangle(this)},closestPointToPoint:function(a,b){void 0===b&&(console.warn("THREE.Triangle: .closestPointToPoint() target is now required"),b=new m);var c=this.a,d=this.b,e=this.c;pd.subVectors(d,c);qd.subVectors(e,
|
|
|
+a.constant===this.constant}});var bb=new m,zb=new m,bh=new m,Ab=new m,pd=new m,qd=new m,Bi=new m,ch=new m,dh=new m,eh=new m;Object.assign(va,{getNormal:function(a,b,c,d){void 0===d&&(console.warn("THREE.Triangle: .getNormal() target is now required"),d=new m);d.subVectors(c,b);bb.subVectors(a,b);d.cross(bb);a=d.lengthSq();return 0<a?d.multiplyScalar(1/Math.sqrt(a)):d.set(0,0,0)},getBarycoord:function(a,b,c,d,e){bb.subVectors(d,b);zb.subVectors(c,b);bh.subVectors(a,b);a=bb.dot(bb);b=bb.dot(zb);c=bb.dot(bh);
|
|
|
+var f=zb.dot(zb);d=zb.dot(bh);var g=a*f-b*b;void 0===e&&(console.warn("THREE.Triangle: .getBarycoord() target is now required"),e=new m);if(0===g)return e.set(-2,-1,-1);g=1/g;f=(f*c-b*d)*g;a=(a*d-b*c)*g;return e.set(1-f-a,a,f)},containsPoint:function(a,b,c,d){va.getBarycoord(a,b,c,d,Ab);return 0<=Ab.x&&0<=Ab.y&&1>=Ab.x+Ab.y},getUV:function(a,b,c,d,e,f,g,h){this.getBarycoord(a,b,c,d,Ab);h.set(0,0);h.addScaledVector(e,Ab.x);h.addScaledVector(f,Ab.y);h.addScaledVector(g,Ab.z);return h},isFrontFacing:function(a,
|
|
|
+b,c,d){bb.subVectors(c,b);zb.subVectors(a,b);return 0>bb.cross(zb).dot(d)?!0:!1}});Object.assign(va.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},getArea:function(){bb.subVectors(this.c,this.b);zb.subVectors(this.a,
|
|
|
+this.b);return.5*bb.cross(zb).length()},getMidpoint:function(a){void 0===a&&(console.warn("THREE.Triangle: .getMidpoint() target is now required"),a=new m);return a.addVectors(this.a,this.b).add(this.c).multiplyScalar(1/3)},getNormal:function(a){return va.getNormal(this.a,this.b,this.c,a)},getPlane:function(a){void 0===a&&(console.warn("THREE.Triangle: .getPlane() target is now required"),a=new Ua);return a.setFromCoplanarPoints(this.a,this.b,this.c)},getBarycoord:function(a,b){return va.getBarycoord(a,
|
|
|
+this.a,this.b,this.c,b)},getUV:function(a,b,c,d,e){return va.getUV(a,this.a,this.b,this.c,b,c,d,e)},containsPoint:function(a){return va.containsPoint(a,this.a,this.b,this.c)},isFrontFacing:function(a){return va.isFrontFacing(this.a,this.b,this.c,a)},intersectsBox:function(a){return a.intersectsTriangle(this)},closestPointToPoint:function(a,b){void 0===b&&(console.warn("THREE.Triangle: .closestPointToPoint() target is now required"),b=new m);var c=this.a,d=this.b,e=this.c;pd.subVectors(d,c);qd.subVectors(e,
|
|
|
c);ch.subVectors(a,c);var f=pd.dot(ch),g=qd.dot(ch);if(0>=f&&0>=g)return b.copy(c);dh.subVectors(a,d);var h=pd.dot(dh),l=qd.dot(dh);if(0<=h&&l<=h)return b.copy(d);var k=f*l-h*g;if(0>=k&&0<=f&&0>=h)return d=f/(f-h),b.copy(c).addScaledVector(pd,d);eh.subVectors(a,e);a=pd.dot(eh);var t=qd.dot(eh);if(0<=t&&a<=t)return b.copy(e);f=a*g-f*t;if(0>=f&&0<=g&&0>=t)return k=g/(g-t),b.copy(c).addScaledVector(qd,k);g=h*t-a*l;if(0>=g&&0<=l-h&&0<=a-t)return Bi.subVectors(e,d),k=(l-h)/(l-h+(a-t)),b.copy(d).addScaledVector(Bi,
|
|
|
k);e=1/(g+f+k);d=f*e;k*=e;return b.copy(c).addScaledVector(pd,d).addScaledVector(qd,k)},equals:function(a){return a.a.equals(this.a)&&a.b.equals(this.b)&&a.c.equals(this.c)}});var Ci={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,
|
|
@@ -525,7 +524,7 @@ Ad;Wb.prototype=Object.create(G.prototype);Wb.prototype.constructor=Wb;Bd.protot
|
|
|
f&&(f.count=3*a-f.start,b.push(f));var f={start:3*a,materialIndex:c}}}void 0!==f&&(f.count=3*a-f.start,b.push(f));this.groups=b},fromGeometry:function(a){var b=a.faces,c=a.vertices,d=a.faceVertexUvs,e=d[0]&&0<d[0].length,f=d[1]&&0<d[1].length,g=a.morphTargets,h=g.length;if(0<h){var l=[];for(var k=0;k<h;k++)l[k]={name:g[k].name,data:[]};this.morphTargets.position=l}k=a.morphNormals;var m=k.length;if(0<m){var p=[];for(var u=0;u<m;u++)p[u]={name:k[u].name,data:[]};this.morphTargets.normal=p}u=a.skinIndices;
|
|
|
var r=a.skinWeights,q=u.length===c.length,v=r.length===c.length;0<c.length&&0===b.length&&console.error("THREE.DirectGeometry: Faceless geometries are not supported.");for(var A=0;A<b.length;A++){var z=b[A];this.vertices.push(c[z.a],c[z.b],c[z.c]);var x=z.vertexNormals;3===x.length?this.normals.push(x[0],x[1],x[2]):(x=z.normal,this.normals.push(x,x,x));x=z.vertexColors;3===x.length?this.colors.push(x[0],x[1],x[2]):(x=z.color,this.colors.push(x,x,x));!0===e&&(x=d[0][A],void 0!==x?this.uvs.push(x[0],
|
|
|
x[1],x[2]):(console.warn("THREE.DirectGeometry.fromGeometry(): Undefined vertexUv ",A),this.uvs.push(new w,new w,new w)));!0===f&&(x=d[1][A],void 0!==x?this.uvs2.push(x[0],x[1],x[2]):(console.warn("THREE.DirectGeometry.fromGeometry(): Undefined vertexUv2 ",A),this.uvs2.push(new w,new w,new w)));for(x=0;x<h;x++){var y=g[x].vertices;l[x].data.push(y[z.a],y[z.b],y[z.c])}for(x=0;x<m;x++)y=k[x].vertexNormals[A],p[x].data.push(y.a,y.b,y.c);q&&this.skinIndices.push(u[z.a],u[z.b],u[z.c]);v&&this.skinWeights.push(r[z.a],
|
|
|
-r[z.b],r[z.c])}this.computeGroups(a);this.verticesNeedUpdate=a.verticesNeedUpdate;this.normalsNeedUpdate=a.normalsNeedUpdate;this.colorsNeedUpdate=a.colorsNeedUpdate;this.uvsNeedUpdate=a.uvsNeedUpdate;this.groupsNeedUpdate=a.groupsNeedUpdate;null!==a.boundingSphere&&(this.boundingSphere=a.boundingSphere.clone());null!==a.boundingBox&&(this.boundingBox=a.boundingBox.clone());return this}});var ij=1,nb=new M,fh=new y,rd=new m,Ma=new Ta,we=new Ta,la=new m;F.prototype=Object.assign(Object.create(ta.prototype),
|
|
|
+r[z.b],r[z.c])}this.computeGroups(a);this.verticesNeedUpdate=a.verticesNeedUpdate;this.normalsNeedUpdate=a.normalsNeedUpdate;this.colorsNeedUpdate=a.colorsNeedUpdate;this.uvsNeedUpdate=a.uvsNeedUpdate;this.groupsNeedUpdate=a.groupsNeedUpdate;null!==a.boundingSphere&&(this.boundingSphere=a.boundingSphere.clone());null!==a.boundingBox&&(this.boundingBox=a.boundingBox.clone());return this}});var ij=1,nb=new M,fh=new y,rd=new m,Ma=new Ta,we=new Ta,pa=new m;F.prototype=Object.assign(Object.create(ta.prototype),
|
|
|
{constructor:F,isBufferGeometry:!0,getIndex:function(){return this.index},setIndex:function(a){Array.isArray(a)?this.index=new (65535<uh(a)?Xb:Wb)(a,1):this.index=a},getAttribute:function(a){return this.attributes[a]},setAttribute:function(a,b){this.attributes[a]=b;return this},deleteAttribute:function(a){delete this.attributes[a];return this},addGroup:function(a,b,c){this.groups.push({start:a,count:b,materialIndex:void 0!==c?c:0})},clearGroups:function(){this.groups=[]},setDrawRange:function(a,b){this.drawRange.start=
|
|
|
a;this.drawRange.count=b},applyMatrix4:function(a){var b=this.attributes.position;void 0!==b&&(b.applyMatrix4(a),b.needsUpdate=!0);b=this.attributes.normal;if(void 0!==b){var c=(new wa).getNormalMatrix(a);b.applyNormalMatrix(c);b.needsUpdate=!0}b=this.attributes.tangent;void 0!==b&&(b.transformDirection(a),b.needsUpdate=!0);null!==this.boundingBox&&this.computeBoundingBox();null!==this.boundingSphere&&this.computeBoundingSphere();return this},rotateX:function(a){nb.makeRotationX(a);this.applyMatrix4(nb);
|
|
|
return this},rotateY:function(a){nb.makeRotationY(a);this.applyMatrix4(nb);return this},rotateZ:function(a){nb.makeRotationZ(a);this.applyMatrix4(nb);return this},translate:function(a,b,c){nb.makeTranslation(a,b,c);this.applyMatrix4(nb);return this},scale:function(a,b,c){nb.makeScale(a,b,c);this.applyMatrix4(nb);return this},lookAt:function(a){fh.lookAt(a);fh.updateMatrix();this.applyMatrix4(fh.matrix);return this},center:function(){this.computeBoundingBox();this.boundingBox.getCenter(rd).negate();
|
|
@@ -536,25 +535,25 @@ c.needsUpdate=!0),b.normalsNeedUpdate=!1);!0===b.colorsNeedUpdate&&(c=this.attri
|
|
|
b.groups,b.groupsNeedUpdate=!1);return this},fromGeometry:function(a){a.__directGeometry=(new th).fromGeometry(a);return this.fromDirectGeometry(a.__directGeometry)},fromDirectGeometry:function(a){var b=new Float32Array(3*a.vertices.length);this.setAttribute("position",(new G(b,3)).copyVector3sArray(a.vertices));0<a.normals.length&&(b=new Float32Array(3*a.normals.length),this.setAttribute("normal",(new G(b,3)).copyVector3sArray(a.normals)));0<a.colors.length&&(b=new Float32Array(3*a.colors.length),
|
|
|
this.setAttribute("color",(new G(b,3)).copyColorsArray(a.colors)));0<a.uvs.length&&(b=new Float32Array(2*a.uvs.length),this.setAttribute("uv",(new G(b,2)).copyVector2sArray(a.uvs)));0<a.uvs2.length&&(b=new Float32Array(2*a.uvs2.length),this.setAttribute("uv2",(new G(b,2)).copyVector2sArray(a.uvs2)));this.groups=a.groups;for(var c in a.morphTargets){b=[];for(var d=a.morphTargets[c],e=0,f=d.length;e<f;e++){var g=d[e],h=new B(3*g.data.length,3);h.name=g.name;b.push(h.copyVector3sArray(g.data))}this.morphAttributes[c]=
|
|
|
b}0<a.skinIndices.length&&(c=new B(4*a.skinIndices.length,4),this.setAttribute("skinIndex",c.copyVector4sArray(a.skinIndices)));0<a.skinWeights.length&&(c=new B(4*a.skinWeights.length,4),this.setAttribute("skinWeight",c.copyVector4sArray(a.skinWeights)));null!==a.boundingSphere&&(this.boundingSphere=a.boundingSphere.clone());null!==a.boundingBox&&(this.boundingBox=a.boundingBox.clone());return this},computeBoundingBox:function(){null===this.boundingBox&&(this.boundingBox=new Ta);var a=this.attributes.position,
|
|
|
-b=this.morphAttributes.position;if(void 0!==a){if(this.boundingBox.setFromBufferAttribute(a),b){a=0;for(var c=b.length;a<c;a++)Ma.setFromBufferAttribute(b[a]),this.morphTargetsRelative?(la.addVectors(this.boundingBox.min,Ma.min),this.boundingBox.expandByPoint(la),la.addVectors(this.boundingBox.max,Ma.max),this.boundingBox.expandByPoint(la)):(this.boundingBox.expandByPoint(Ma.min),this.boundingBox.expandByPoint(Ma.max))}}else this.boundingBox.makeEmpty();(isNaN(this.boundingBox.min.x)||isNaN(this.boundingBox.min.y)||
|
|
|
-isNaN(this.boundingBox.min.z))&&console.error('THREE.BufferGeometry.computeBoundingBox: Computed min/max have NaN values. The "position" attribute is likely to have NaN values.',this)},computeBoundingSphere:function(){null===this.boundingSphere&&(this.boundingSphere=new db);var a=this.attributes.position,b=this.morphAttributes.position;if(a){var c=this.boundingSphere.center;Ma.setFromBufferAttribute(a);if(b)for(var d=0,e=b.length;d<e;d++)we.setFromBufferAttribute(b[d]),this.morphTargetsRelative?(la.addVectors(Ma.min,
|
|
|
-we.min),Ma.expandByPoint(la),la.addVectors(Ma.max,we.max),Ma.expandByPoint(la)):(Ma.expandByPoint(we.min),Ma.expandByPoint(we.max));Ma.getCenter(c);e=d=0;for(var f=a.count;e<f;e++)la.fromBufferAttribute(a,e),d=Math.max(d,c.distanceToSquared(la));if(b)for(e=0,f=b.length;e<f;e++)for(var g=b[e],h=this.morphTargetsRelative,l=0,k=g.count;l<k;l++)la.fromBufferAttribute(g,l),h&&(rd.fromBufferAttribute(a,l),la.add(rd)),d=Math.max(d,c.distanceToSquared(la));this.boundingSphere.radius=Math.sqrt(d);isNaN(this.boundingSphere.radius)&&
|
|
|
+b=this.morphAttributes.position;if(void 0!==a){if(this.boundingBox.setFromBufferAttribute(a),b){a=0;for(var c=b.length;a<c;a++)Ma.setFromBufferAttribute(b[a]),this.morphTargetsRelative?(pa.addVectors(this.boundingBox.min,Ma.min),this.boundingBox.expandByPoint(pa),pa.addVectors(this.boundingBox.max,Ma.max),this.boundingBox.expandByPoint(pa)):(this.boundingBox.expandByPoint(Ma.min),this.boundingBox.expandByPoint(Ma.max))}}else this.boundingBox.makeEmpty();(isNaN(this.boundingBox.min.x)||isNaN(this.boundingBox.min.y)||
|
|
|
+isNaN(this.boundingBox.min.z))&&console.error('THREE.BufferGeometry.computeBoundingBox: Computed min/max have NaN values. The "position" attribute is likely to have NaN values.',this)},computeBoundingSphere:function(){null===this.boundingSphere&&(this.boundingSphere=new db);var a=this.attributes.position,b=this.morphAttributes.position;if(a){var c=this.boundingSphere.center;Ma.setFromBufferAttribute(a);if(b)for(var d=0,e=b.length;d<e;d++)we.setFromBufferAttribute(b[d]),this.morphTargetsRelative?(pa.addVectors(Ma.min,
|
|
|
+we.min),Ma.expandByPoint(pa),pa.addVectors(Ma.max,we.max),Ma.expandByPoint(pa)):(Ma.expandByPoint(we.min),Ma.expandByPoint(we.max));Ma.getCenter(c);e=d=0;for(var f=a.count;e<f;e++)pa.fromBufferAttribute(a,e),d=Math.max(d,c.distanceToSquared(pa));if(b)for(e=0,f=b.length;e<f;e++)for(var g=b[e],h=this.morphTargetsRelative,l=0,k=g.count;l<k;l++)pa.fromBufferAttribute(g,l),h&&(rd.fromBufferAttribute(a,l),pa.add(rd)),d=Math.max(d,c.distanceToSquared(pa));this.boundingSphere.radius=Math.sqrt(d);isNaN(this.boundingSphere.radius)&&
|
|
|
console.error('THREE.BufferGeometry.computeBoundingSphere(): Computed radius is NaN. The "position" attribute is likely to have NaN values.',this)}},computeFaceNormals:function(){},computeVertexNormals:function(){var a=this.index,b=this.getAttribute("position");if(void 0!==b){var c=this.getAttribute("normal");if(void 0===c)c=new G(new Float32Array(3*b.count),3),this.setAttribute("normal",c);else for(var d=0,e=c.count;d<e;d++)c.setXYZ(d,0,0,0);d=new m;e=new m;var f=new m,g=new m,h=new m,l=new m,k=
|
|
|
new m,t=new m;if(a)for(var p=0,u=a.count;p<u;p+=3){var r=a.getX(p+0),q=a.getX(p+1),v=a.getX(p+2);d.fromBufferAttribute(b,r);e.fromBufferAttribute(b,q);f.fromBufferAttribute(b,v);k.subVectors(f,e);t.subVectors(d,e);k.cross(t);g.fromBufferAttribute(c,r);h.fromBufferAttribute(c,q);l.fromBufferAttribute(c,v);g.add(k);h.add(k);l.add(k);c.setXYZ(r,g.x,g.y,g.z);c.setXYZ(q,h.x,h.y,h.z);c.setXYZ(v,l.x,l.y,l.z)}else for(a=0,g=b.count;a<g;a+=3)d.fromBufferAttribute(b,a+0),e.fromBufferAttribute(b,a+1),f.fromBufferAttribute(b,
|
|
|
a+2),k.subVectors(f,e),t.subVectors(d,e),k.cross(t),c.setXYZ(a+0,k.x,k.y,k.z),c.setXYZ(a+1,k.x,k.y,k.z),c.setXYZ(a+2,k.x,k.y,k.z);this.normalizeNormals();c.needsUpdate=!0}},merge:function(a,b){if(a&&a.isBufferGeometry){void 0===b&&(b=0,console.warn("THREE.BufferGeometry.merge(): Overwriting original geometry, starting at offset=0. Use BufferGeometryUtils.mergeBufferGeometries() for lossless merge."));var c=this.attributes,d;for(d in c)if(void 0!==a.attributes[d]){var e=c[d].array,f=a.attributes[d],
|
|
|
-g=f.array,h=f.itemSize*b;f=Math.min(g.length,e.length-h);for(var l=0;l<f;l++,h++)e[h]=g[l]}return this}console.error("THREE.BufferGeometry.merge(): geometry not an instance of THREE.BufferGeometry.",a)},normalizeNormals:function(){for(var a=this.attributes.normal,b=0,c=a.count;b<c;b++)la.x=a.getX(b),la.y=a.getY(b),la.z=a.getZ(b),la.normalize(),a.setXYZ(b,la.x,la.y,la.z)},toNonIndexed:function(){function a(a,b){var c=a.array,d=a.itemSize;a=a.normalized;for(var e=new c.constructor(b.length*d),f,g=0,
|
|
|
-h=0,l=b.length;h<l;h++){f=b[h]*d;for(var k=0;k<d;k++)e[g++]=c[f++]}return new G(e,d,a)}if(null===this.index)return console.warn("THREE.BufferGeometry.toNonIndexed(): Geometry is already non-indexed."),this;var b=new F,c=this.index.array,d=this.attributes;for(g in d){var e=a(d[g],c);b.setAttribute(g,e)}d=this.morphAttributes;for(var f in d){var g=[];e=d[f];for(var h=0,l=e.length;h<l;h++){var k=a(e[h],c);g.push(k)}b.morphAttributes[f]=g}b.morphTargetsRelative=this.morphTargetsRelative;c=this.groups;
|
|
|
-f=0;for(d=c.length;f<d;f++)g=c[f],b.addGroup(g.start,g.count,g.materialIndex);return b},toJSON:function(){var a={metadata:{version:4.5,type:"BufferGeometry",generator:"BufferGeometry.toJSON"}};a.uuid=this.uuid;a.type=this.type;""!==this.name&&(a.name=this.name);0<Object.keys(this.userData).length&&(a.userData=this.userData);if(void 0!==this.parameters){var b=this.parameters;for(c in b)void 0!==b[c]&&(a[c]=b[c]);return a}a.data={attributes:{}};var c=this.index;null!==c&&(a.data.index={type:c.array.constructor.name,
|
|
|
-array:Array.prototype.slice.call(c.array)});c=this.attributes;for(var d in c){var e=c[d],f=e.toJSON(a.data);""!==e.name&&(f.name=e.name);a.data.attributes[d]=f}d={};c=!1;for(b in this.morphAttributes){e=this.morphAttributes[b];f=[];for(var g=0,h=e.length;g<h;g++){var l=e[g],k=l.toJSON(a.data);""!==l.name&&(k.name=l.name);f.push(k)}0<f.length&&(d[b]=f,c=!0)}c&&(a.data.morphAttributes=d,a.data.morphTargetsRelative=this.morphTargetsRelative);b=this.groups;0<b.length&&(a.data.groups=JSON.parse(JSON.stringify(b)));
|
|
|
-b=this.boundingSphere;null!==b&&(a.data.boundingSphere={center:b.center.toArray(),radius:b.radius});return a},clone:function(){return(new F).copy(this)},copy:function(a){this.index=null;this.attributes={};this.morphAttributes={};this.groups=[];this.boundingSphere=this.boundingBox=null;var b={};this.name=a.name;var c=a.index;null!==c&&this.setIndex(c.clone(b));c=a.attributes;for(var d in c)this.setAttribute(d,c[d].clone(b));d=a.morphAttributes;for(var e in d){c=[];for(var f=d[e],g=0,h=f.length;g<h;g++)c.push(f[g].clone(b));
|
|
|
-this.morphAttributes[e]=c}this.morphTargetsRelative=a.morphTargetsRelative;b=a.groups;e=0;for(d=b.length;e<d;e++)c=b[e],this.addGroup(c.start,c.count,c.materialIndex);b=a.boundingBox;null!==b&&(this.boundingBox=b.clone());b=a.boundingSphere;null!==b&&(this.boundingSphere=b.clone());this.drawRange.start=a.drawRange.start;this.drawRange.count=a.drawRange.count;this.userData=a.userData;return this},dispose:function(){this.dispatchEvent({type:"dispose"})}});var Di=new M,qc=new Vb,gh=new db,Bb=new m,Cb=
|
|
|
-new m,Db=new m,dg=new m,eg=new m,fg=new m,Ge=new m,He=new m,Ie=new m,zc=new w,Ac=new w,Bc=new w,Dd=new m,Ee=new m;U.prototype=Object.assign(Object.create(y.prototype),{constructor:U,isMesh:!0,copy:function(a){y.prototype.copy.call(this,a);void 0!==a.morphTargetInfluences&&(this.morphTargetInfluences=a.morphTargetInfluences.slice());void 0!==a.morphTargetDictionary&&(this.morphTargetDictionary=Object.assign({},a.morphTargetDictionary));this.material=a.material;this.geometry=a.geometry;return this},
|
|
|
-updateMorphTargets:function(){var a=this.geometry;if(a.isBufferGeometry){a=a.morphAttributes;var b=Object.keys(a);if(0<b.length&&(a=a[b[0]],void 0!==a)){this.morphTargetInfluences=[];this.morphTargetDictionary={};b=0;for(var c=a.length;b<c;b++){var d=a[b].name||String(b);this.morphTargetInfluences.push(0);this.morphTargetDictionary[d]=b}}}else a=a.morphTargets,void 0!==a&&0<a.length&&console.error("THREE.Mesh.updateMorphTargets() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")},
|
|
|
-raycast:function(a,b){var c=this.geometry,d=this.material,e=this.matrixWorld;if(void 0!==d&&(null===c.boundingSphere&&c.computeBoundingSphere(),gh.copy(c.boundingSphere),gh.applyMatrix4(e),!1!==a.ray.intersectsSphere(gh)&&(Di.getInverse(e),qc.copy(a.ray).applyMatrix4(Di),null===c.boundingBox||!1!==qc.intersectsBox(c.boundingBox))))if(c.isBufferGeometry){var f=c.index,g=c.attributes.position;e=c.morphAttributes.position;var h=c.morphTargetsRelative,l=c.attributes.uv,k=c.attributes.uv2,m=c.groups,p=
|
|
|
-c.drawRange;if(null!==f)if(Array.isArray(d))for(var u=0,r=m.length;u<r;u++)for(var q=m[u],v=d[q.materialIndex],A=Math.max(q.start,p.start),z=Math.min(q.start+q.count,p.start+p.count);A<z;A+=3){c=f.getX(A);var x=f.getX(A+1),y=f.getX(A+2);if(c=Fe(this,v,a,qc,g,e,h,l,k,c,x,y))c.faceIndex=Math.floor(A/3),c.face.materialIndex=q.materialIndex,b.push(c)}else for(m=Math.max(0,p.start),p=Math.min(f.count,p.start+p.count);m<p;m+=3){if(c=f.getX(m),u=f.getX(m+1),r=f.getX(m+2),c=Fe(this,d,a,qc,g,e,h,l,k,c,u,r))c.faceIndex=
|
|
|
-Math.floor(m/3),b.push(c)}else if(void 0!==g)if(Array.isArray(d))for(f=0,u=m.length;f<u;f++)for(r=m[f],q=d[r.materialIndex],v=Math.max(r.start,p.start),A=Math.min(r.start+r.count,p.start+p.count);v<A;v+=3){if(c=Fe(this,q,a,qc,g,e,h,l,k,v,v+1,v+2))c.faceIndex=Math.floor(v/3),c.face.materialIndex=r.materialIndex,b.push(c)}else for(m=Math.max(0,p.start),p=Math.min(g.count,p.start+p.count);m<p;m+=3)if(c=Fe(this,d,a,qc,g,e,h,l,k,m,m+1,m+2))c.faceIndex=Math.floor(m/3),b.push(c)}else if(c.isGeometry)for(e=
|
|
|
-Array.isArray(d),h=c.vertices,l=c.faces,c=c.faceVertexUvs[0],0<c.length&&(g=c),k=0,p=l.length;k<p;k++)if(m=l[k],c=e?d[m.materialIndex]:d,void 0!==c&&(f=h[m.a],u=h[m.b],r=h[m.c],c=vh(this,c,a,qc,f,u,r,Dd)))g&&g[k]&&(q=g[k],zc.copy(q[0]),Ac.copy(q[1]),Bc.copy(q[2]),c.uv=oa.getUV(Dd,f,u,r,zc,Ac,Bc,new w)),c.face=m,c.faceIndex=k,b.push(c)}});var jj=0,ob=new M,hh=new y,Hf=new m;H.prototype=Object.assign(Object.create(ta.prototype),{constructor:H,isGeometry:!0,applyMatrix4:function(a){for(var b=(new wa).getNormalMatrix(a),
|
|
|
-c=0,d=this.vertices.length;c<d;c++)this.vertices[c].applyMatrix4(a);a=0;for(c=this.faces.length;a<c;a++){d=this.faces[a];d.normal.applyMatrix3(b).normalize();for(var e=0,f=d.vertexNormals.length;e<f;e++)d.vertexNormals[e].applyMatrix3(b).normalize()}null!==this.boundingBox&&this.computeBoundingBox();null!==this.boundingSphere&&this.computeBoundingSphere();this.normalsNeedUpdate=this.verticesNeedUpdate=!0;return this},rotateX:function(a){ob.makeRotationX(a);this.applyMatrix4(ob);return this},rotateY:function(a){ob.makeRotationY(a);
|
|
|
+g=f.array,h=f.itemSize*b;f=Math.min(g.length,e.length-h);for(var l=0;l<f;l++,h++)e[h]=g[l]}return this}console.error("THREE.BufferGeometry.merge(): geometry not an instance of THREE.BufferGeometry.",a)},normalizeNormals:function(){for(var a=this.attributes.normal,b=0,c=a.count;b<c;b++)pa.fromBufferAttribute(a,b),pa.normalize(),a.setXYZ(b,pa.x,pa.y,pa.z)},toNonIndexed:function(){function a(a,b){var c=a.array,d=a.itemSize;a=a.normalized;for(var e=new c.constructor(b.length*d),f,g=0,h=0,l=b.length;h<
|
|
|
+l;h++){f=b[h]*d;for(var k=0;k<d;k++)e[g++]=c[f++]}return new G(e,d,a)}if(null===this.index)return console.warn("THREE.BufferGeometry.toNonIndexed(): Geometry is already non-indexed."),this;var b=new F,c=this.index.array,d=this.attributes;for(g in d){var e=a(d[g],c);b.setAttribute(g,e)}d=this.morphAttributes;for(var f in d){var g=[];e=d[f];for(var h=0,l=e.length;h<l;h++){var k=a(e[h],c);g.push(k)}b.morphAttributes[f]=g}b.morphTargetsRelative=this.morphTargetsRelative;c=this.groups;f=0;for(d=c.length;f<
|
|
|
+d;f++)g=c[f],b.addGroup(g.start,g.count,g.materialIndex);return b},toJSON:function(){var a={metadata:{version:4.5,type:"BufferGeometry",generator:"BufferGeometry.toJSON"}};a.uuid=this.uuid;a.type=this.type;""!==this.name&&(a.name=this.name);0<Object.keys(this.userData).length&&(a.userData=this.userData);if(void 0!==this.parameters){var b=this.parameters;for(c in b)void 0!==b[c]&&(a[c]=b[c]);return a}a.data={attributes:{}};var c=this.index;null!==c&&(a.data.index={type:c.array.constructor.name,array:Array.prototype.slice.call(c.array)});
|
|
|
+c=this.attributes;for(var d in c){var e=c[d],f=e.toJSON(a.data);""!==e.name&&(f.name=e.name);a.data.attributes[d]=f}d={};c=!1;for(b in this.morphAttributes){e=this.morphAttributes[b];f=[];for(var g=0,h=e.length;g<h;g++){var l=e[g],k=l.toJSON(a.data);""!==l.name&&(k.name=l.name);f.push(k)}0<f.length&&(d[b]=f,c=!0)}c&&(a.data.morphAttributes=d,a.data.morphTargetsRelative=this.morphTargetsRelative);b=this.groups;0<b.length&&(a.data.groups=JSON.parse(JSON.stringify(b)));b=this.boundingSphere;null!==b&&
|
|
|
+(a.data.boundingSphere={center:b.center.toArray(),radius:b.radius});return a},clone:function(){return(new F).copy(this)},copy:function(a){this.index=null;this.attributes={};this.morphAttributes={};this.groups=[];this.boundingSphere=this.boundingBox=null;var b={};this.name=a.name;var c=a.index;null!==c&&this.setIndex(c.clone(b));c=a.attributes;for(var d in c)this.setAttribute(d,c[d].clone(b));d=a.morphAttributes;for(var e in d){c=[];for(var f=d[e],g=0,h=f.length;g<h;g++)c.push(f[g].clone(b));this.morphAttributes[e]=
|
|
|
+c}this.morphTargetsRelative=a.morphTargetsRelative;b=a.groups;e=0;for(d=b.length;e<d;e++)c=b[e],this.addGroup(c.start,c.count,c.materialIndex);b=a.boundingBox;null!==b&&(this.boundingBox=b.clone());b=a.boundingSphere;null!==b&&(this.boundingSphere=b.clone());this.drawRange.start=a.drawRange.start;this.drawRange.count=a.drawRange.count;this.userData=a.userData;return this},dispose:function(){this.dispatchEvent({type:"dispose"})}});var Di=new M,qc=new Vb,gh=new db,Bb=new m,Cb=new m,Db=new m,dg=new m,
|
|
|
+eg=new m,fg=new m,Ge=new m,He=new m,Ie=new m,zc=new w,Ac=new w,Bc=new w,Dd=new m,Ee=new m;U.prototype=Object.assign(Object.create(y.prototype),{constructor:U,isMesh:!0,copy:function(a){y.prototype.copy.call(this,a);void 0!==a.morphTargetInfluences&&(this.morphTargetInfluences=a.morphTargetInfluences.slice());void 0!==a.morphTargetDictionary&&(this.morphTargetDictionary=Object.assign({},a.morphTargetDictionary));this.material=a.material;this.geometry=a.geometry;return this},updateMorphTargets:function(){var a=
|
|
|
+this.geometry;if(a.isBufferGeometry){a=a.morphAttributes;var b=Object.keys(a);if(0<b.length&&(a=a[b[0]],void 0!==a)){this.morphTargetInfluences=[];this.morphTargetDictionary={};b=0;for(var c=a.length;b<c;b++){var d=a[b].name||String(b);this.morphTargetInfluences.push(0);this.morphTargetDictionary[d]=b}}}else a=a.morphTargets,void 0!==a&&0<a.length&&console.error("THREE.Mesh.updateMorphTargets() no longer supports THREE.Geometry. Use THREE.BufferGeometry instead.")},raycast:function(a,b){var c=this.geometry,
|
|
|
+d=this.material,e=this.matrixWorld;if(void 0!==d&&(null===c.boundingSphere&&c.computeBoundingSphere(),gh.copy(c.boundingSphere),gh.applyMatrix4(e),!1!==a.ray.intersectsSphere(gh)&&(Di.getInverse(e),qc.copy(a.ray).applyMatrix4(Di),null===c.boundingBox||!1!==qc.intersectsBox(c.boundingBox))))if(c.isBufferGeometry){var f=c.index,g=c.attributes.position;e=c.morphAttributes.position;var h=c.morphTargetsRelative,l=c.attributes.uv,k=c.attributes.uv2,m=c.groups,p=c.drawRange;if(null!==f)if(Array.isArray(d))for(var u=
|
|
|
+0,r=m.length;u<r;u++)for(var q=m[u],v=d[q.materialIndex],A=Math.max(q.start,p.start),z=Math.min(q.start+q.count,p.start+p.count);A<z;A+=3){c=f.getX(A);var x=f.getX(A+1),y=f.getX(A+2);if(c=Fe(this,v,a,qc,g,e,h,l,k,c,x,y))c.faceIndex=Math.floor(A/3),c.face.materialIndex=q.materialIndex,b.push(c)}else for(m=Math.max(0,p.start),p=Math.min(f.count,p.start+p.count);m<p;m+=3){if(c=f.getX(m),u=f.getX(m+1),r=f.getX(m+2),c=Fe(this,d,a,qc,g,e,h,l,k,c,u,r))c.faceIndex=Math.floor(m/3),b.push(c)}else if(void 0!==
|
|
|
+g)if(Array.isArray(d))for(f=0,u=m.length;f<u;f++)for(r=m[f],q=d[r.materialIndex],v=Math.max(r.start,p.start),A=Math.min(r.start+r.count,p.start+p.count);v<A;v+=3){if(c=Fe(this,q,a,qc,g,e,h,l,k,v,v+1,v+2))c.faceIndex=Math.floor(v/3),c.face.materialIndex=r.materialIndex,b.push(c)}else for(m=Math.max(0,p.start),p=Math.min(g.count,p.start+p.count);m<p;m+=3)if(c=Fe(this,d,a,qc,g,e,h,l,k,m,m+1,m+2))c.faceIndex=Math.floor(m/3),b.push(c)}else if(c.isGeometry)for(e=Array.isArray(d),h=c.vertices,l=c.faces,
|
|
|
+c=c.faceVertexUvs[0],0<c.length&&(g=c),k=0,p=l.length;k<p;k++)if(m=l[k],c=e?d[m.materialIndex]:d,void 0!==c&&(f=h[m.a],u=h[m.b],r=h[m.c],c=vh(this,c,a,qc,f,u,r,Dd)))g&&g[k]&&(q=g[k],zc.copy(q[0]),Ac.copy(q[1]),Bc.copy(q[2]),c.uv=va.getUV(Dd,f,u,r,zc,Ac,Bc,new w)),c.face=m,c.faceIndex=k,b.push(c)}});var jj=0,ob=new M,hh=new y,Hf=new m;H.prototype=Object.assign(Object.create(ta.prototype),{constructor:H,isGeometry:!0,applyMatrix4:function(a){for(var b=(new wa).getNormalMatrix(a),c=0,d=this.vertices.length;c<
|
|
|
+d;c++)this.vertices[c].applyMatrix4(a);a=0;for(c=this.faces.length;a<c;a++){d=this.faces[a];d.normal.applyMatrix3(b).normalize();for(var e=0,f=d.vertexNormals.length;e<f;e++)d.vertexNormals[e].applyMatrix3(b).normalize()}null!==this.boundingBox&&this.computeBoundingBox();null!==this.boundingSphere&&this.computeBoundingSphere();this.normalsNeedUpdate=this.verticesNeedUpdate=!0;return this},rotateX:function(a){ob.makeRotationX(a);this.applyMatrix4(ob);return this},rotateY:function(a){ob.makeRotationY(a);
|
|
|
this.applyMatrix4(ob);return this},rotateZ:function(a){ob.makeRotationZ(a);this.applyMatrix4(ob);return this},translate:function(a,b,c){ob.makeTranslation(a,b,c);this.applyMatrix4(ob);return this},scale:function(a,b,c){ob.makeScale(a,b,c);this.applyMatrix4(ob);return this},lookAt:function(a){hh.lookAt(a);hh.updateMatrix();this.applyMatrix4(hh.matrix);return this},fromBufferGeometry:function(a){function b(a,b,d,e){var f=void 0===h?[]:[c.colors[a].clone(),c.colors[b].clone(),c.colors[d].clone()],n=
|
|
|
void 0===g?[]:[(new m).fromBufferAttribute(g,a),(new m).fromBufferAttribute(g,b),(new m).fromBufferAttribute(g,d)];e=new yc(a,b,d,n,f,e);c.faces.push(e);void 0!==l&&c.faceVertexUvs[0].push([(new w).fromBufferAttribute(l,a),(new w).fromBufferAttribute(l,b),(new w).fromBufferAttribute(l,d)]);void 0!==k&&c.faceVertexUvs[1].push([(new w).fromBufferAttribute(k,a),(new w).fromBufferAttribute(k,b),(new w).fromBufferAttribute(k,d)])}var c=this,d=null!==a.index?a.index:void 0,e=a.attributes;if(void 0===e.position)return console.error("THREE.Geometry.fromBufferGeometry(): Position attribute required for conversion."),
|
|
|
this;var f=e.position,g=e.normal,h=e.color,l=e.uv,k=e.uv2;void 0!==k&&(this.faceVertexUvs[1]=[]);for(e=0;e<f.count;e++)c.vertices.push((new m).fromBufferAttribute(f,e)),void 0!==h&&c.colors.push((new D).fromBufferAttribute(h,e));e=a.groups;if(0<e.length)for(f=0;f<e.length;f++){var t=e[f],p=t.start,u=p;for(p+=t.count;u<p;u+=3)void 0!==d?b(d.getX(u),d.getX(u+1),d.getX(u+2),t.materialIndex):b(u,u+1,u+2,t.materialIndex)}else if(void 0!==d)for(e=0;e<d.count;e+=3)b(d.getX(e),d.getX(e+1),d.getX(e+2));else for(d=
|
|
@@ -579,7 +578,7 @@ l.a=h.a.clone(),l.b=h.b.clone(),l.c=h.c.clone(),e.vertexNormals.push(l);if(void
|
|
|
b.clone());b=a.boundingSphere;null!==b&&(this.boundingSphere=b.clone());this.elementsNeedUpdate=a.elementsNeedUpdate;this.verticesNeedUpdate=a.verticesNeedUpdate;this.uvsNeedUpdate=a.uvsNeedUpdate;this.normalsNeedUpdate=a.normalsNeedUpdate;this.colorsNeedUpdate=a.colorsNeedUpdate;this.lineDistancesNeedUpdate=a.lineDistancesNeedUpdate;this.groupsNeedUpdate=a.groupsNeedUpdate;return this},dispose:function(){this.dispatchEvent({type:"dispose"})}});var ih=function(a){function b(b,d,e,f,g,h){a.call(this);
|
|
|
this.type="BoxGeometry";this.parameters={width:b,height:d,depth:e,widthSegments:f,heightSegments:g,depthSegments:h};this.fromBufferGeometry(new Fd(b,d,e,f,g,h));this.mergeVertices()}a&&(b.__proto__=a);b.prototype=Object.create(a&&a.prototype);return b.prototype.constructor=b}(H),Fd=function(a){function b(b,d,e,f,g,h){function c(a,b,c,d,e,f,g,h,l,n,w){var x=f/l,A=g/n,z=f/2,y=g/2,C=h/2;g=l+1;for(var B=n+1,E=f=0,D=new m,F=0;F<B;F++)for(var G=F*A-y,H=0;H<g;H++)D[a]=(H*x-z)*d,D[b]=G*e,D[c]=C,p.push(D.x,
|
|
|
D.y,D.z),D[a]=0,D[b]=0,D[c]=0<h?1:-1,u.push(D.x,D.y,D.z),r.push(H/l),r.push(1-F/n),f+=1;for(a=0;a<n;a++)for(b=0;b<l;b++)c=q+b+g*(a+1),d=q+(b+1)+g*(a+1),e=q+(b+1)+g*a,t.push(q+b+g*a,c,e),t.push(c,d,e),E+=6;k.addGroup(v,E,w);v+=E;q+=f}a.call(this);this.type="BoxBufferGeometry";this.parameters={width:b,height:d,depth:e,widthSegments:f,heightSegments:g,depthSegments:h};var k=this;b=b||1;d=d||1;e=e||1;f=Math.floor(f)||1;g=Math.floor(g)||1;h=Math.floor(h)||1;var t=[],p=[],u=[],r=[],q=0,v=0;c("z","y","x",
|
|
|
--1,-1,e,d,b,h,g,0);c("z","y","x",1,-1,e,d,-b,h,g,1);c("x","z","y",1,1,b,e,d,f,h,2);c("x","z","y",1,-1,b,e,-d,f,h,3);c("x","y","z",1,-1,b,d,e,f,g,4);c("x","y","z",-1,-1,b,d,-e,f,g,5);this.setIndex(t);this.setAttribute("position",new B(p,3));this.setAttribute("normal",new B(u,3));this.setAttribute("uv",new B(r,2))}a&&(b.__proto__=a);b.prototype=Object.create(a&&a.prototype);return b.prototype.constructor=b}(F),Qh={clone:Cc,merge:va};Aa.prototype=Object.create(K.prototype);Aa.prototype.constructor=Aa;
|
|
|
+-1,-1,e,d,b,h,g,0);c("z","y","x",1,-1,e,d,-b,h,g,1);c("x","z","y",1,1,b,e,d,f,h,2);c("x","z","y",1,-1,b,e,-d,f,h,3);c("x","y","z",1,-1,b,d,e,f,g,4);c("x","y","z",-1,-1,b,d,-e,f,g,5);this.setIndex(t);this.setAttribute("position",new B(p,3));this.setAttribute("normal",new B(u,3));this.setAttribute("uv",new B(r,2))}a&&(b.__proto__=a);b.prototype=Object.create(a&&a.prototype);return b.prototype.constructor=b}(F),Qh={clone:Cc,merge:ua};Aa.prototype=Object.create(K.prototype);Aa.prototype.constructor=Aa;
|
|
|
Aa.prototype.isShaderMaterial=!0;Aa.prototype.copy=function(a){K.prototype.copy.call(this,a);this.fragmentShader=a.fragmentShader;this.vertexShader=a.vertexShader;this.uniforms=Cc(a.uniforms);this.defines=Object.assign({},a.defines);this.wireframe=a.wireframe;this.wireframeLinewidth=a.wireframeLinewidth;this.lights=a.lights;this.clipping=a.clipping;this.skinning=a.skinning;this.morphTargets=a.morphTargets;this.morphNormals=a.morphNormals;this.extensions=Object.assign({},a.extensions);return this};
|
|
|
Aa.prototype.toJSON=function(a){var b=K.prototype.toJSON.call(this,a);b.uniforms={};for(var c in this.uniforms){var d=this.uniforms[c].value;b.uniforms[c]=d&&d.isTexture?{type:"t",value:d.toJSON(a).uuid}:d&&d.isColor?{type:"c",value:d.getHex()}:d&&d.isVector2?{type:"v2",value:d.toArray()}:d&&d.isVector3?{type:"v3",value:d.toArray()}:d&&d.isVector4?{type:"v4",value:d.toArray()}:d&&d.isMatrix3?{type:"m3",value:d.toArray()}:d&&d.isMatrix4?{type:"m4",value:d.toArray()}:{value:d}}0<Object.keys(this.defines).length&&
|
|
|
(b.defines=this.defines);b.vertexShader=this.vertexShader;b.fragmentShader=this.fragmentShader;a={};for(var e in this.extensions)!0===this.extensions[e]&&(a[e]=!0);0<Object.keys(a).length&&(b.extensions=a);return b};eb.prototype=Object.assign(Object.create(y.prototype),{constructor:eb,isCamera:!0,copy:function(a,b){y.prototype.copy.call(this,a,b);this.matrixWorldInverse.copy(a.matrixWorldInverse);this.projectionMatrix.copy(a.projectionMatrix);this.projectionMatrixInverse.copy(a.projectionMatrixInverse);
|
|
@@ -588,7 +587,7 @@ clone:function(){return(new this.constructor).copy(this)}});T.prototype=Object.a
|
|
|
Math.atan(a);this.updateProjectionMatrix()},getFocalLength:function(){var a=Math.tan(.5*L.DEG2RAD*this.fov);return.5*this.getFilmHeight()/a},getEffectiveFOV:function(){return 2*L.RAD2DEG*Math.atan(Math.tan(.5*L.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*L.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+=f.offsetX*d/g;b-=f.offsetY*c/h;d*=f.width/g;c*=f.height/h}f=this.filmOffset;0!==f&&(e+=a*f/this.getFilmWidth());this.projectionMatrix.makePerspective(e,e+d,b,b-c,a,this.far);this.projectionMatrixInverse.getInverse(this.projectionMatrix)},toJSON:function(a){a=y.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}});Dc.prototype=Object.create(y.prototype);Dc.prototype.constructor=Dc;Yb.prototype=Object.create(Ga.prototype);Yb.prototype.constructor=Yb;Yb.prototype.isWebGLCubeRenderTarget=!0;Yb.prototype.fromEquirectangularTexture=function(a,b){this.texture.type=b.type;this.texture.format=b.format;this.texture.encoding=b.encoding;var c=new wd,d=new Aa({type:"CubemapFromEquirect",uniforms:Cc({tEquirect:{value:null}}),vertexShader:"varying vec3 vWorldDirection;\nvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\n}\nvoid main() {\n\tvWorldDirection = transformDirection( position, modelMatrix );\n\t#include <begin_vertex>\n\t#include <project_vertex>\n}",
|
|
|
+this.view));a.object.filmGauge=this.filmGauge;a.object.filmOffset=this.filmOffset;return a}});Dc.prototype=Object.create(y.prototype);Dc.prototype.constructor=Dc;Yb.prototype=Object.create(Ga.prototype);Yb.prototype.constructor=Yb;Yb.prototype.isWebGLCubeRenderTarget=!0;Yb.prototype.fromEquirectangularTexture=function(a,b){this.texture.type=b.type;this.texture.format=b.format;this.texture.encoding=b.encoding;var c=new wd,d=new Aa({name:"CubemapFromEquirect",uniforms:Cc({tEquirect:{value:null}}),vertexShader:"varying vec3 vWorldDirection;\nvec3 transformDirection( in vec3 dir, in mat4 matrix ) {\n\treturn normalize( ( matrix * vec4( dir, 0.0 ) ).xyz );\n}\nvoid main() {\n\tvWorldDirection = transformDirection( position, modelMatrix );\n\t#include <begin_vertex>\n\t#include <project_vertex>\n}",
|
|
|
fragmentShader:"uniform sampler2D tEquirect;\nvarying vec3 vWorldDirection;\n#include <common>\nvoid main() {\n\tvec3 direction = normalize( vWorldDirection );\n\tvec2 sampleUV = equirectUv( direction );\n\tgl_FragColor = texture2D( tEquirect, sampleUV );\n}",side:1,blending:0});d.uniforms.tEquirect.value=b;b=new U(new Fd(5,5,5),d);c.add(b);(new Dc(1,10,this)).update(a,c);b.geometry.dispose();b.material.dispose();return this};Zb.prototype=Object.create(R.prototype);Zb.prototype.constructor=Zb;Zb.prototype.isDataTexture=
|
|
|
!0;var sd=new db,If=new m;Object.assign(Ec.prototype,{set:function(a,b,c,d,e,f){var g=this.planes;g[0].copy(a);g[1].copy(b);g[2].copy(c);g[3].copy(d);g[4].copy(e);g[5].copy(f);return this},clone:function(){return(new this.constructor).copy(this)},copy:function(a){for(var b=this.planes,c=0;6>c;c++)b[c].copy(a.planes[c]);return this},setFromProjectionMatrix:function(a){var b=this.planes,c=a.elements;a=c[0];var d=c[1],e=c[2],f=c[3],g=c[4],h=c[5],l=c[6],k=c[7],m=c[8],p=c[9],u=c[10],r=c[11],q=c[12],v=
|
|
|
c[13],w=c[14];c=c[15];b[0].setComponents(f-a,k-g,r-m,c-q).normalize();b[1].setComponents(f+a,k+g,r+m,c+q).normalize();b[2].setComponents(f+d,k+h,r+p,c+v).normalize();b[3].setComponents(f-d,k-h,r-p,c-v).normalize();b[4].setComponents(f-e,k-l,r-u,c-w).normalize();b[5].setComponents(f+e,k+l,r+u,c+w).normalize();return this},intersectsObject:function(a){var b=a.geometry;null===b.boundingSphere&&b.computeBoundingSphere();sd.copy(b.boundingSphere).applyMatrix4(a.matrixWorld);return this.intersectsSphere(sd)},
|
|
@@ -640,7 +639,7 @@ shadowmap_vertex:"#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\t#prag
|
|
|
shadowmask_pars_fragment:"float getShadowMask() {\n\tfloat shadow = 1.0;\n\t#ifdef USE_SHADOWMAP\n\t#if NUM_DIR_LIGHT_SHADOWS > 0\n\tDirectionalLightShadow directionalLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_DIR_LIGHT_SHADOWS; i ++ ) {\n\t\tdirectionalLight = directionalLightShadows[ i ];\n\t\tshadow *= receiveShadow ? getShadow( directionalShadowMap[ i ], directionalLight.shadowMapSize, directionalLight.shadowBias, directionalLight.shadowRadius, vDirectionalShadowCoord[ i ] ) : 1.0;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_SPOT_LIGHT_SHADOWS > 0\n\tSpotLightShadow spotLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_SPOT_LIGHT_SHADOWS; i ++ ) {\n\t\tspotLight = spotLightShadows[ i ];\n\t\tshadow *= receiveShadow ? getShadow( spotShadowMap[ i ], spotLight.shadowMapSize, spotLight.shadowBias, spotLight.shadowRadius, vSpotShadowCoord[ i ] ) : 1.0;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#if NUM_POINT_LIGHT_SHADOWS > 0\n\tPointLightShadow pointLight;\n\t#pragma unroll_loop_start\n\tfor ( int i = 0; i < NUM_POINT_LIGHT_SHADOWS; i ++ ) {\n\t\tpointLight = pointLightShadows[ i ];\n\t\tshadow *= receiveShadow ? getPointShadow( pointShadowMap[ i ], pointLight.shadowMapSize, pointLight.shadowBias, pointLight.shadowRadius, vPointShadowCoord[ i ], pointLight.shadowCameraNear, pointLight.shadowCameraFar ) : 1.0;\n\t}\n\t#pragma unroll_loop_end\n\t#endif\n\t#endif\n\treturn shadow;\n}",
|
|
|
skinbase_vertex:"#ifdef USE_SKINNING\n\tmat4 boneMatX = getBoneMatrix( skinIndex.x );\n\tmat4 boneMatY = getBoneMatrix( skinIndex.y );\n\tmat4 boneMatZ = getBoneMatrix( skinIndex.z );\n\tmat4 boneMatW = getBoneMatrix( skinIndex.w );\n#endif",skinning_pars_vertex:"#ifdef USE_SKINNING\n\tuniform mat4 bindMatrix;\n\tuniform mat4 bindMatrixInverse;\n\t#ifdef BONE_TEXTURE\n\t\tuniform highp sampler2D boneTexture;\n\t\tuniform int boneTextureSize;\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tfloat j = i * 4.0;\n\t\t\tfloat x = mod( j, float( boneTextureSize ) );\n\t\t\tfloat y = floor( j / float( boneTextureSize ) );\n\t\t\tfloat dx = 1.0 / float( boneTextureSize );\n\t\t\tfloat dy = 1.0 / float( boneTextureSize );\n\t\t\ty = dy * ( y + 0.5 );\n\t\t\tvec4 v1 = texture2D( boneTexture, vec2( dx * ( x + 0.5 ), y ) );\n\t\t\tvec4 v2 = texture2D( boneTexture, vec2( dx * ( x + 1.5 ), y ) );\n\t\t\tvec4 v3 = texture2D( boneTexture, vec2( dx * ( x + 2.5 ), y ) );\n\t\t\tvec4 v4 = texture2D( boneTexture, vec2( dx * ( x + 3.5 ), y ) );\n\t\t\tmat4 bone = mat4( v1, v2, v3, v4 );\n\t\t\treturn bone;\n\t\t}\n\t#else\n\t\tuniform mat4 boneMatrices[ MAX_BONES ];\n\t\tmat4 getBoneMatrix( const in float i ) {\n\t\t\tmat4 bone = boneMatrices[ int(i) ];\n\t\t\treturn bone;\n\t\t}\n\t#endif\n#endif",
|
|
|
skinning_vertex:"#ifdef USE_SKINNING\n\tvec4 skinVertex = bindMatrix * vec4( transformed, 1.0 );\n\tvec4 skinned = vec4( 0.0 );\n\tskinned += boneMatX * skinVertex * skinWeight.x;\n\tskinned += boneMatY * skinVertex * skinWeight.y;\n\tskinned += boneMatZ * skinVertex * skinWeight.z;\n\tskinned += boneMatW * skinVertex * skinWeight.w;\n\ttransformed = ( bindMatrixInverse * skinned ).xyz;\n#endif",skinnormal_vertex:"#ifdef USE_SKINNING\n\tmat4 skinMatrix = mat4( 0.0 );\n\tskinMatrix += skinWeight.x * boneMatX;\n\tskinMatrix += skinWeight.y * boneMatY;\n\tskinMatrix += skinWeight.z * boneMatZ;\n\tskinMatrix += skinWeight.w * boneMatW;\n\tskinMatrix = bindMatrixInverse * skinMatrix * bindMatrix;\n\tobjectNormal = vec4( skinMatrix * vec4( objectNormal, 0.0 ) ).xyz;\n\t#ifdef USE_TANGENT\n\t\tobjectTangent = vec4( skinMatrix * vec4( objectTangent, 0.0 ) ).xyz;\n\t#endif\n#endif",
|
|
|
-specularmap_fragment:"float specularStrength;\n#ifdef USE_SPECULARMAP\n\tvec4 texelSpecular = texture2D( specularMap, vUv );\n\tspecularStrength = texelSpecular.r;\n#else\n\tspecularStrength = 1.0;\n#endif",specularmap_pars_fragment:"#ifdef USE_SPECULARMAP\n\tuniform sampler2D specularMap;\n#endif",tonemapping_fragment:"#if defined( TONE_MAPPING )\n\tgl_FragColor.rgb = toneMapping( gl_FragColor.rgb );\n#endif",tonemapping_pars_fragment:"#ifndef saturate\n#define saturate(a) clamp( a, 0.0, 1.0 )\n#endif\nuniform float toneMappingExposure;\nvec3 LinearToneMapping( vec3 color ) {\n\treturn toneMappingExposure * color;\n}\nvec3 ReinhardToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\treturn saturate( color / ( vec3( 1.0 ) + color ) );\n}\n#define Uncharted2Helper( x ) max( ( ( x * ( 0.15 * x + 0.10 * 0.50 ) + 0.20 * 0.02 ) / ( x * ( 0.15 * x + 0.50 ) + 0.20 * 0.30 ) ) - 0.02 / 0.30, vec3( 0.0 ) )\nvec3 Uncharted2ToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\treturn saturate( Uncharted2Helper( color ) / Uncharted2Helper( vec3( 1.0 ) ) );\n}\nvec3 OptimizedCineonToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\tcolor = max( vec3( 0.0 ), color - 0.004 );\n\treturn pow( ( color * ( 6.2 * color + 0.5 ) ) / ( color * ( 6.2 * color + 1.7 ) + 0.06 ), vec3( 2.2 ) );\n}\nvec3 ACESFilmicToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\treturn saturate( ( color * ( 2.51 * color + 0.03 ) ) / ( color * ( 2.43 * color + 0.59 ) + 0.14 ) );\n}",
|
|
|
+specularmap_fragment:"float specularStrength;\n#ifdef USE_SPECULARMAP\n\tvec4 texelSpecular = texture2D( specularMap, vUv );\n\tspecularStrength = texelSpecular.r;\n#else\n\tspecularStrength = 1.0;\n#endif",specularmap_pars_fragment:"#ifdef USE_SPECULARMAP\n\tuniform sampler2D specularMap;\n#endif",tonemapping_fragment:"#if defined( TONE_MAPPING )\n\tgl_FragColor.rgb = toneMapping( gl_FragColor.rgb );\n#endif",tonemapping_pars_fragment:"#ifndef saturate\n#define saturate(a) clamp( a, 0.0, 1.0 )\n#endif\nuniform float toneMappingExposure;\nvec3 LinearToneMapping( vec3 color ) {\n\treturn toneMappingExposure * color;\n}\nvec3 ReinhardToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\treturn saturate( color / ( vec3( 1.0 ) + color ) );\n}\nvec3 OptimizedCineonToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\tcolor = max( vec3( 0.0 ), color - 0.004 );\n\treturn pow( ( color * ( 6.2 * color + 0.5 ) ) / ( color * ( 6.2 * color + 1.7 ) + 0.06 ), vec3( 2.2 ) );\n}\nvec3 ACESFilmicToneMapping( vec3 color ) {\n\tcolor *= toneMappingExposure;\n\treturn saturate( ( color * ( 2.51 * color + 0.03 ) ) / ( color * ( 2.43 * color + 0.59 ) + 0.14 ) );\n}",
|
|
|
uv_pars_fragment:"#if ( defined( USE_UV ) && ! defined( UVS_VERTEX_ONLY ) )\n\tvarying vec2 vUv;\n#endif",uv_pars_vertex:"#ifdef USE_UV\n\t#ifdef UVS_VERTEX_ONLY\n\t\tvec2 vUv;\n\t#else\n\t\tvarying vec2 vUv;\n\t#endif\n\tuniform mat3 uvTransform;\n#endif",uv_vertex:"#ifdef USE_UV\n\tvUv = ( uvTransform * vec3( uv, 1 ) ).xy;\n#endif",uv2_pars_fragment:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvarying vec2 vUv2;\n#endif",uv2_pars_vertex:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tattribute vec2 uv2;\n\tvarying vec2 vUv2;\n\tuniform mat3 uv2Transform;\n#endif",
|
|
|
uv2_vertex:"#if defined( USE_LIGHTMAP ) || defined( USE_AOMAP )\n\tvUv2 = ( uv2Transform * vec3( uv2, 1 ) ).xy;\n#endif",worldpos_vertex:"#if defined( USE_ENVMAP ) || defined( DISTANCE ) || defined ( USE_SHADOWMAP )\n\tvec4 worldPosition = vec4( transformed, 1.0 );\n\t#ifdef USE_INSTANCING\n\t\tworldPosition = instanceMatrix * worldPosition;\n\t#endif\n\tworldPosition = modelMatrix * worldPosition;\n#endif",background_frag:"uniform sampler2D t2D;\nvarying vec2 vUv;\nvoid main() {\n\tvec4 texColor = texture2D( t2D, vUv );\n\tgl_FragColor = mapTexelToLinear( texColor );\n\t#include <tonemapping_fragment>\n\t#include <encodings_fragment>\n}",
|
|
|
background_vert:"varying vec2 vUv;\nuniform mat3 uvTransform;\nvoid main() {\n\tvUv = ( uvTransform * vec3( uv, 1 ) ).xy;\n\tgl_Position = vec4( position.xy, 1.0, 1.0 );\n}",cube_frag:"#include <envmap_common_pars_fragment>\nuniform float opacity;\nvarying vec3 vWorldDirection;\n#include <cube_uv_reflection_fragment>\nvoid main() {\n\tvec3 vReflect = vWorldDirection;\n\t#include <envmap_fragment>\n\tgl_FragColor = envColor;\n\tgl_FragColor.a *= opacity;\n\t#include <tonemapping_fragment>\n\t#include <encodings_fragment>\n}",
|
|
@@ -670,12 +669,12 @@ points_vert:"uniform float size;\nuniform float scale;\n#include <common>\n#incl
|
|
|
shadow_frag:"uniform vec3 color;\nuniform float opacity;\n#include <common>\n#include <packing>\n#include <fog_pars_fragment>\n#include <bsdfs>\n#include <lights_pars_begin>\n#include <shadowmap_pars_fragment>\n#include <shadowmask_pars_fragment>\nvoid main() {\n\tgl_FragColor = vec4( color, opacity * ( 1.0 - getShadowMask() ) );\n\t#include <tonemapping_fragment>\n\t#include <encodings_fragment>\n\t#include <fog_fragment>\n}",shadow_vert:"#include <fog_pars_vertex>\n#include <shadowmap_pars_vertex>\nvoid main() {\n\t#include <begin_vertex>\n\t#include <project_vertex>\n\t#include <worldpos_vertex>\n\t#include <shadowmap_vertex>\n\t#include <fog_vertex>\n}",
|
|
|
sprite_frag:"uniform vec3 diffuse;\nuniform float opacity;\n#include <common>\n#include <uv_pars_fragment>\n#include <map_pars_fragment>\n#include <alphamap_pars_fragment>\n#include <fog_pars_fragment>\n#include <logdepthbuf_pars_fragment>\n#include <clipping_planes_pars_fragment>\nvoid main() {\n\t#include <clipping_planes_fragment>\n\tvec3 outgoingLight = vec3( 0.0 );\n\tvec4 diffuseColor = vec4( diffuse, opacity );\n\t#include <logdepthbuf_fragment>\n\t#include <map_fragment>\n\t#include <alphamap_fragment>\n\t#include <alphatest_fragment>\n\toutgoingLight = diffuseColor.rgb;\n\tgl_FragColor = vec4( outgoingLight, diffuseColor.a );\n\t#include <tonemapping_fragment>\n\t#include <encodings_fragment>\n\t#include <fog_fragment>\n}",
|
|
|
sprite_vert:"uniform float rotation;\nuniform vec2 center;\n#include <common>\n#include <uv_pars_vertex>\n#include <fog_pars_vertex>\n#include <logdepthbuf_pars_vertex>\n#include <clipping_planes_pars_vertex>\nvoid main() {\n\t#include <uv_vertex>\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 = isPerspectiveMatrix( projectionMatrix );\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 <logdepthbuf_vertex>\n\t#include <clipping_planes_vertex>\n\t#include <fog_vertex>\n}"},
|
|
|
-fb={basic:{uniforms:va([E.common,E.specularmap,E.envmap,E.aomap,E.lightmap,E.fog]),vertexShader:Q.meshbasic_vert,fragmentShader:Q.meshbasic_frag},lambert:{uniforms:va([E.common,E.specularmap,E.envmap,E.aomap,E.lightmap,E.emissivemap,E.fog,E.lights,{emissive:{value:new D(0)}}]),vertexShader:Q.meshlambert_vert,fragmentShader:Q.meshlambert_frag},phong:{uniforms:va([E.common,E.specularmap,E.envmap,E.aomap,E.lightmap,E.emissivemap,E.bumpmap,E.normalmap,E.displacementmap,E.fog,E.lights,{emissive:{value:new D(0)},
|
|
|
-specular:{value:new D(1118481)},shininess:{value:30}}]),vertexShader:Q.meshphong_vert,fragmentShader:Q.meshphong_frag},standard:{uniforms:va([E.common,E.envmap,E.aomap,E.lightmap,E.emissivemap,E.bumpmap,E.normalmap,E.displacementmap,E.roughnessmap,E.metalnessmap,E.fog,E.lights,{emissive:{value:new D(0)},roughness:{value:1},metalness:{value:0},envMapIntensity:{value:1}}]),vertexShader:Q.meshphysical_vert,fragmentShader:Q.meshphysical_frag},toon:{uniforms:va([E.common,E.specularmap,E.aomap,E.lightmap,
|
|
|
-E.emissivemap,E.bumpmap,E.normalmap,E.displacementmap,E.gradientmap,E.fog,E.lights,{emissive:{value:new D(0)},specular:{value:new D(1118481)},shininess:{value:30}}]),vertexShader:Q.meshtoon_vert,fragmentShader:Q.meshtoon_frag},matcap:{uniforms:va([E.common,E.bumpmap,E.normalmap,E.displacementmap,E.fog,{matcap:{value:null}}]),vertexShader:Q.meshmatcap_vert,fragmentShader:Q.meshmatcap_frag},points:{uniforms:va([E.points,E.fog]),vertexShader:Q.points_vert,fragmentShader:Q.points_frag},dashed:{uniforms:va([E.common,
|
|
|
-E.fog,{scale:{value:1},dashSize:{value:1},totalSize:{value:2}}]),vertexShader:Q.linedashed_vert,fragmentShader:Q.linedashed_frag},depth:{uniforms:va([E.common,E.displacementmap]),vertexShader:Q.depth_vert,fragmentShader:Q.depth_frag},normal:{uniforms:va([E.common,E.bumpmap,E.normalmap,E.displacementmap,{opacity:{value:1}}]),vertexShader:Q.normal_vert,fragmentShader:Q.normal_frag},sprite:{uniforms:va([E.sprite,E.fog]),vertexShader:Q.sprite_vert,fragmentShader:Q.sprite_frag},background:{uniforms:{uvTransform:{value:new wa},
|
|
|
-t2D:{value:null}},vertexShader:Q.background_vert,fragmentShader:Q.background_frag},cube:{uniforms:va([E.envmap,{opacity:{value:1}}]),vertexShader:Q.cube_vert,fragmentShader:Q.cube_frag},equirect:{uniforms:{tEquirect:{value:null}},vertexShader:Q.equirect_vert,fragmentShader:Q.equirect_frag},distanceRGBA:{uniforms:va([E.common,E.displacementmap,{referencePosition:{value:new m},nearDistance:{value:1},farDistance:{value:1E3}}]),vertexShader:Q.distanceRGBA_vert,fragmentShader:Q.distanceRGBA_frag},shadow:{uniforms:va([E.lights,
|
|
|
-E.fog,{color:{value:new D(0)},opacity:{value:1}}]),vertexShader:Q.shadow_vert,fragmentShader:Q.shadow_frag}};fb.physical={uniforms:va([fb.standard.uniforms,{clearcoat:{value:0},clearcoatMap:{value:null},clearcoatRoughness:{value:0},clearcoatRoughnessMap:{value:null},clearcoatNormalScale:{value:new w(1,1)},clearcoatNormalMap:{value:null},sheen:{value:new D(0)},transparency:{value:0}}]),vertexShader:Q.meshphysical_vert,fragmentShader:Q.meshphysical_frag};pb.prototype=Object.create(R.prototype);pb.prototype.constructor=
|
|
|
+fb={basic:{uniforms:ua([E.common,E.specularmap,E.envmap,E.aomap,E.lightmap,E.fog]),vertexShader:Q.meshbasic_vert,fragmentShader:Q.meshbasic_frag},lambert:{uniforms:ua([E.common,E.specularmap,E.envmap,E.aomap,E.lightmap,E.emissivemap,E.fog,E.lights,{emissive:{value:new D(0)}}]),vertexShader:Q.meshlambert_vert,fragmentShader:Q.meshlambert_frag},phong:{uniforms:ua([E.common,E.specularmap,E.envmap,E.aomap,E.lightmap,E.emissivemap,E.bumpmap,E.normalmap,E.displacementmap,E.fog,E.lights,{emissive:{value:new D(0)},
|
|
|
+specular:{value:new D(1118481)},shininess:{value:30}}]),vertexShader:Q.meshphong_vert,fragmentShader:Q.meshphong_frag},standard:{uniforms:ua([E.common,E.envmap,E.aomap,E.lightmap,E.emissivemap,E.bumpmap,E.normalmap,E.displacementmap,E.roughnessmap,E.metalnessmap,E.fog,E.lights,{emissive:{value:new D(0)},roughness:{value:1},metalness:{value:0},envMapIntensity:{value:1}}]),vertexShader:Q.meshphysical_vert,fragmentShader:Q.meshphysical_frag},toon:{uniforms:ua([E.common,E.specularmap,E.aomap,E.lightmap,
|
|
|
+E.emissivemap,E.bumpmap,E.normalmap,E.displacementmap,E.gradientmap,E.fog,E.lights,{emissive:{value:new D(0)},specular:{value:new D(1118481)},shininess:{value:30}}]),vertexShader:Q.meshtoon_vert,fragmentShader:Q.meshtoon_frag},matcap:{uniforms:ua([E.common,E.bumpmap,E.normalmap,E.displacementmap,E.fog,{matcap:{value:null}}]),vertexShader:Q.meshmatcap_vert,fragmentShader:Q.meshmatcap_frag},points:{uniforms:ua([E.points,E.fog]),vertexShader:Q.points_vert,fragmentShader:Q.points_frag},dashed:{uniforms:ua([E.common,
|
|
|
+E.fog,{scale:{value:1},dashSize:{value:1},totalSize:{value:2}}]),vertexShader:Q.linedashed_vert,fragmentShader:Q.linedashed_frag},depth:{uniforms:ua([E.common,E.displacementmap]),vertexShader:Q.depth_vert,fragmentShader:Q.depth_frag},normal:{uniforms:ua([E.common,E.bumpmap,E.normalmap,E.displacementmap,{opacity:{value:1}}]),vertexShader:Q.normal_vert,fragmentShader:Q.normal_frag},sprite:{uniforms:ua([E.sprite,E.fog]),vertexShader:Q.sprite_vert,fragmentShader:Q.sprite_frag},background:{uniforms:{uvTransform:{value:new wa},
|
|
|
+t2D:{value:null}},vertexShader:Q.background_vert,fragmentShader:Q.background_frag},cube:{uniforms:ua([E.envmap,{opacity:{value:1}}]),vertexShader:Q.cube_vert,fragmentShader:Q.cube_frag},equirect:{uniforms:{tEquirect:{value:null}},vertexShader:Q.equirect_vert,fragmentShader:Q.equirect_frag},distanceRGBA:{uniforms:ua([E.common,E.displacementmap,{referencePosition:{value:new m},nearDistance:{value:1},farDistance:{value:1E3}}]),vertexShader:Q.distanceRGBA_vert,fragmentShader:Q.distanceRGBA_frag},shadow:{uniforms:ua([E.lights,
|
|
|
+E.fog,{color:{value:new D(0)},opacity:{value:1}}]),vertexShader:Q.shadow_vert,fragmentShader:Q.shadow_frag}};fb.physical={uniforms:ua([fb.standard.uniforms,{clearcoat:{value:0},clearcoatMap:{value:null},clearcoatRoughness:{value:0},clearcoatRoughnessMap:{value:null},clearcoatNormalScale:{value:new w(1,1)},clearcoatNormalMap:{value:null},sheen:{value:new D(0)},transparency:{value:0}}]),vertexShader:Q.meshphysical_vert,fragmentShader:Q.meshphysical_frag};pb.prototype=Object.create(R.prototype);pb.prototype.constructor=
|
|
|
pb;pb.prototype.isCubeTexture=!0;Object.defineProperty(pb.prototype,"images",{get:function(){return this.image},set:function(a){this.image=a}});Fc.prototype=Object.create(R.prototype);Fc.prototype.constructor=Fc;Fc.prototype.isDataTexture2DArray=!0;Gc.prototype=Object.create(R.prototype);Gc.prototype.constructor=Gc;Gc.prototype.isDataTexture3D=!0;var Dh=new R,Fj=new Fc,Hj=new Gc,Eh=new pb,xh=[],zh=[],Ch=new Float32Array(16),Bh=new Float32Array(9),Ah=new Float32Array(4);Fh.prototype.updateCache=function(a){var b=
|
|
|
this.cache;a instanceof Float32Array&&b.length!==a.length&&(this.cache=new Float32Array(a.length));Ha(b,a)};Gh.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 gg=/([\w\d_]+)(\])?(\[|\.)?/g;Eb.prototype.setValue=function(a,b,c,d){b=this.map[b];void 0!==b&&b.setValue(a,c,d)};Eb.prototype.setOptional=function(a,b,c){b=b[c];void 0!==b&&this.setValue(a,c,b)};Eb.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)}};Eb.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 mk=0,ig=/^[ \t]*#include +<([\w\d./]+)>/gm,Ph=/#pragma unroll_loop[\s]+?for \( int i = (\d+); i < (\d+); i \+\+ \) \{([\s\S]+?)(?=\})\}/g,Oh=/#pragma unroll_loop_start[\s]+?for \( int i = (\d+); i < (\d+); i \+\+ \) \{([\s\S]+?)(?=\})\}[\s]+?#pragma unroll_loop_end/g,wk=0;Fb.prototype=Object.create(K.prototype);Fb.prototype.constructor=
|
|
@@ -694,7 +693,7 @@ a=[];for(var b=0;b<this.count;b++)for(var c=b*this.data.stride+this.offset,d=0;d
|
|
|
a=[];for(var b=0;b<this.count;b++)for(var c=b*this.data.stride+this.offset,d=0;d<this.itemSize;d++)a.push(this.data.array[c+d]);return{itemSize:this.itemSize,type:this.array.constructor.name,array:a,normalized:this.normalized}}void 0===a.interleavedBuffers&&(a.interleavedBuffers={});void 0===a.interleavedBuffers[this.data.uuid]&&(a.interleavedBuffers[this.data.uuid]=this.data.toJSON(a));return{isInterleavedBufferAttribute:!0,itemSize:this.itemSize,data:this.data.uuid,offset:this.offset,normalized:this.normalized}}});
|
|
|
Jb.prototype=Object.create(K.prototype);Jb.prototype.constructor=Jb;Jb.prototype.isSpriteMaterial=!0;Jb.prototype.copy=function(a){K.prototype.copy.call(this,a);this.color.copy(a.color);this.map=a.map;this.alphaMap=a.alphaMap;this.rotation=a.rotation;this.sizeAttenuation=a.sizeAttenuation;return this};var Jc,xe=new m,td=new m,ud=new m,Kc=new w,Md=new w,Xh=new M,Jf=new m,ye=new m,Kf=new m,Ei=new w,jh=new w,Fi=new w;Ld.prototype=Object.assign(Object.create(y.prototype),{constructor:Ld,isSprite:!0,raycast:function(a,
|
|
|
b){null===a.camera&&console.error('THREE.Sprite: "Raycaster.camera" needs to be set in order to raycast against sprites.');td.setFromMatrixScale(this.matrixWorld);Xh.copy(a.camera.matrixWorld);this.modelViewMatrix.multiplyMatrices(a.camera.matrixWorldInverse,this.matrixWorld);ud.setFromMatrixPosition(this.modelViewMatrix);a.camera.isPerspectiveCamera&&!1===this.material.sizeAttenuation&&td.multiplyScalar(-ud.z);var c=this.material.rotation;if(0!==c){var d=Math.cos(c);var e=Math.sin(c)}c=this.center;
|
|
|
-Qe(Jf.set(-.5,-.5,0),ud,c,td,e,d);Qe(ye.set(.5,-.5,0),ud,c,td,e,d);Qe(Kf.set(.5,.5,0),ud,c,td,e,d);Ei.set(0,0);jh.set(1,0);Fi.set(1,1);var f=a.ray.intersectTriangle(Jf,ye,Kf,!1,xe);if(null===f&&(Qe(ye.set(-.5,.5,0),ud,c,td,e,d),jh.set(0,1),f=a.ray.intersectTriangle(Jf,Kf,ye,!1,xe),null===f))return;e=a.ray.origin.distanceTo(xe);e<a.near||e>a.far||b.push({distance:e,point:xe.clone(),uv:oa.getUV(xe,Jf,ye,Kf,Ei,jh,Fi,new w),face:null,object:this})},copy:function(a){y.prototype.copy.call(this,a);void 0!==
|
|
|
+Qe(Jf.set(-.5,-.5,0),ud,c,td,e,d);Qe(ye.set(.5,-.5,0),ud,c,td,e,d);Qe(Kf.set(.5,.5,0),ud,c,td,e,d);Ei.set(0,0);jh.set(1,0);Fi.set(1,1);var f=a.ray.intersectTriangle(Jf,ye,Kf,!1,xe);if(null===f&&(Qe(ye.set(-.5,.5,0),ud,c,td,e,d),jh.set(0,1),f=a.ray.intersectTriangle(Jf,Kf,ye,!1,xe),null===f))return;e=a.ray.origin.distanceTo(xe);e<a.near||e>a.far||b.push({distance:e,point:xe.clone(),uv:va.getUV(xe,Jf,ye,Kf,Ei,jh,Fi,new w),face:null,object:this})},copy:function(a){y.prototype.copy.call(this,a);void 0!==
|
|
|
a.center&&this.center.copy(a.center);this.material=a.material;return this}});var Lf=new m,Gi=new m;Nd.prototype=Object.assign(Object.create(y.prototype),{constructor:Nd,isLOD:!0,copy:function(a){y.prototype.copy.call(this,a,!1);for(var b=a.levels,c=0,d=b.length;c<d;c++){var e=b[c];this.addLevel(e.object.clone(),e.distance)}this.autoUpdate=a.autoUpdate;return this},addLevel:function(a,b){void 0===b&&(b=0);b=Math.abs(b);var c=this.levels,d;for(d=0;d<c.length&&!(b<c[d].distance);d++);c.splice(d,0,{distance:b,
|
|
|
object:a});this.add(a);return this},getCurrentLevel:function(){return this._currentLevel},getObjectForDistance:function(a){var b=this.levels;if(0<b.length){var c;var d=1;for(c=b.length;d<c&&!(a<b[d].distance);d++);return b[d-1].object}return null},raycast:function(a,b){if(0<this.levels.length){Lf.setFromMatrixPosition(this.matrixWorld);var c=a.ray.origin.distanceTo(Lf);this.getObjectForDistance(c).raycast(a,b)}},update:function(a){var b=this.levels;if(1<b.length){Lf.setFromMatrixPosition(a.matrixWorld);
|
|
|
Gi.setFromMatrixPosition(this.matrixWorld);a=Lf.distanceTo(Gi)/a.zoom;b[0].object.visible=!0;var c;var d=1;for(c=b.length;d<c;d++)if(a>=b[d].distance)b[d-1].object.visible=!1,b[d].object.visible=!0;else break;for(this._currentLevel=d-1;d<c;d++)b[d].object.visible=!1}},toJSON:function(a){a=y.prototype.toJSON.call(this,a);!1===this.autoUpdate&&(a.object.autoUpdate=!1);a.object.levels=[];for(var b=this.levels,c=0,d=b.length;c<d;c++){var e=b[c];a.object.levels.push({object:e.object.uuid,distance:e.distance})}return a}});
|
|
@@ -746,7 +745,7 @@ b,c){return Z.isTypedArray(a)?new a.constructor(a.subarray(b,void 0!==c?c:a.leng
|
|
|
f=0,g=0;g!==d;++f)for(var h=c[f]*b,l=0;l!==b;++l)e[g++]=a[h+l];return e},flattenJSON:function(a,b,c,d){for(var e=1,f=a[0];void 0!==f&&void 0===f[d];)f=a[e++];if(void 0!==f){var g=f[d];if(void 0!==g)if(Array.isArray(g)){do g=f[d],void 0!==g&&(b.push(f.time),c.push.apply(c,g)),f=a[e++];while(void 0!==f)}else if(void 0!==g.toArray){do g=f[d],void 0!==g&&(b.push(f.time),g.toArray(c,c.length)),f=a[e++];while(void 0!==f)}else{do g=f[d],void 0!==g&&(b.push(f.time),c.push(g)),f=a[e++];while(void 0!==f)}}},
|
|
|
subclip:function(a,b,c,d,e){e=e||30;a=a.clone();a.name=b;b=[];for(var f=0;f<a.tracks.length;++f){for(var g=a.tracks[f],h=g.getValueSize(),l=[],k=[],m=0;m<g.times.length;++m){var p=g.times[m]*e;if(!(p<c||p>=d))for(l.push(g.times[m]),p=0;p<h;++p)k.push(g.values[m*h+p])}0!==l.length&&(g.times=Z.convertArray(l,g.times.constructor),g.values=Z.convertArray(k,g.values.constructor),b.push(g))}a.tracks=b;c=Infinity;for(d=0;d<a.tracks.length;++d)c>a.tracks[d].times[0]&&(c=a.tracks[d].times[0]);for(d=0;d<a.tracks.length;++d)a.tracks[d].shift(-1*
|
|
|
c);a.resetDuration();return a},makeClipAdditive:function(a,b,c,d){void 0===b&&(b=0);void 0===c&&(c=a);if(void 0===d||0>=d)d=30;var e=a.tracks.length,f=b/d;b=function(b){var d=c.tracks[b],e=d.ValueTypeName;if("bool"!==e&&"string"!==e&&(b=a.tracks.find(function(a){return a.name===d.name&&a.ValueTypeName===e}),void 0!==b)){var g=d.getValueSize(),k=d.times.length-1,p=void 0;f<=d.times[0]?p=Z.arraySlice(d.values,0,d.valueSize):f>=d.times[k]?p=Z.arraySlice(d.values,k*g):(p=d.createInterpolant(),p.evaluate(f),
|
|
|
-p=p.resultBuffer);"quaternion"===e&&(new ua(p[0],p[1],p[2],p[3])).normalize().conjugate().toArray(p);k=b.times.length;for(var m=0;m<k;++m){var r=m*g;if("quaternion"===e)ua.multiplyQuaternionsFlat(b.values,r,p,0,b.values,r);else for(var q=0;q<g;++q)b.values[r+q]-=p[q]}}};for(d=0;d<e;++d)b(d);a.blendMode=2501;return a}};Object.assign(Ka.prototype,{evaluate:function(a){var b=this.parameterPositions,c=this._cachedIndex,d=b[c],e=b[c-1];a:{b:{c:{d:if(!(a<d)){for(var f=c+2;;){if(void 0===d){if(a<e)break d;
|
|
|
+p=p.resultBuffer);"quaternion"===e&&(new la(p[0],p[1],p[2],p[3])).normalize().conjugate().toArray(p);k=b.times.length;for(var m=0;m<k;++m){var r=m*g;if("quaternion"===e)la.multiplyQuaternionsFlat(b.values,r,p,0,b.values,r);else for(var q=0;q<g;++q)b.values[r+q]-=p[q]}}};for(d=0;d<e;++d)b(d);a.blendMode=2501;return a}};Object.assign(Ka.prototype,{evaluate:function(a){var b=this.parameterPositions,c=this._cachedIndex,d=b[c],e=b[c-1];a:{b:{c:{d:if(!(a<d)){for(var f=c+2;;){if(void 0===d){if(a<e)break d;
|
|
|
this._cachedIndex=c=b.length;return this.afterEnd_(c-1,a,e)}if(c===f)break;e=d;d=b[++c];if(a<d)break b}d=b.length;break c}if(a>=e)break a;else{f=b[1];a<f&&(c=2,e=f);for(f=c-2;;){if(void 0===e)return this._cachedIndex=0,this.beforeStart_(0,a,d);if(c===f)break;d=e;e=b[--c-1];if(a>=e)break b}d=c;c=0}}for(;c<d;)e=c+d>>>1,a<b[e]?d=e:c=e+1;d=b[c];e=b[c-1];if(void 0===e)return this._cachedIndex=0,this.beforeStart_(0,a,d);if(void 0===d)return this._cachedIndex=c=b.length,this.afterEnd_(c-1,e,a)}this._cachedIndex=
|
|
|
c;this.intervalChanged_(c,e,d)}return this.interpolate_(c,e,a,d)},settings:null,DefaultSettings_:{},getSettings_:function(){return this.settings||this.DefaultSettings_},copySampleValue_:function(a){var b=this.resultBuffer,c=this.sampleValues,d=this.valueSize;a*=d;for(var e=0;e!==d;++e)b[e]=c[a+e];return b},interpolate_:function(){throw Error("call to abstract method");},intervalChanged_:function(){}});Object.assign(Ka.prototype,{beforeStart_:Ka.prototype.copySampleValue_,afterEnd_:Ka.prototype.copySampleValue_});
|
|
|
Ye.prototype=Object.assign(Object.create(Ka.prototype),{constructor:Ye,DefaultSettings_:{endingStart:2400,endingEnd:2400},intervalChanged_:function(a,b,c){var d=this.parameterPositions,e=a-2,f=a+1,g=d[e],h=d[f];if(void 0===g)switch(this.getSettings_().endingStart){case 2401:e=a;g=2*b-c;break;case 2402:e=d.length-2;g=b+d[e]-d[e+1];break;default:e=a,g=c}if(void 0===h)switch(this.getSettings_().endingEnd){case 2401:f=a;h=2*c-b;break;case 2402:f=1;h=c+d[1]-d[0];break;default:f=a-1,h=b}a=.5*(c-b);d=this.valueSize;
|
|
@@ -759,7 +758,7 @@ d;++c)b[c]*=a;return this},trim:function(a,b){for(var c=this.times,d=c.length,e=
|
|
|
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&&Z.isTypedArray(b))for(c=0,d=b.length;c!==d;++c)if(e=b[c],isNaN(e)){console.error("THREE.KeyframeTrack: Value is not a valid number.",this,c,e);a=!1;break}return a},optimize:function(){for(var a=Z.arraySlice(this.times),
|
|
|
b=Z.arraySlice(this.values),c=this.getValueSize(),d=2302===this.getInterpolation(),e=a.length-1,f=1,g=1;g<e;++g){var h=!1,k=a[g];if(k!==a[g+1]&&(1!==g||k!==k[0]))if(d)h=!0;else{k=g*c;for(var n=k-c,m=k+c,p=0;p!==c;++p){var u=b[k+p];if(u!==b[n+p]||u!==b[m+p]){h=!0;break}}}if(h){if(g!==f)for(a[f]=a[g],h=g*c,k=f*c,n=0;n!==c;++n)b[k+n]=b[h+n];++f}}if(0<e){a[f]=a[e];d=e*c;e=f*c;for(g=0;g!==c;++g)b[e+g]=b[d+g];++f}f!==a.length?(this.times=Z.arraySlice(a,0,f),this.values=Z.arraySlice(b,0,f*c)):(this.times=
|
|
|
a,this.values=b);return this},clone:function(){var a=Z.arraySlice(this.times,0),b=Z.arraySlice(this.values,0);a=new this.constructor(this.name,a,b);a.createInterpolant=this.createInterpolant;return a}});$e.prototype=Object.assign(Object.create(sa.prototype),{constructor:$e,ValueTypeName:"bool",ValueBufferType:Array,DefaultInterpolation:2300,InterpolantFactoryMethodLinear:void 0,InterpolantFactoryMethodSmooth:void 0});af.prototype=Object.assign(Object.create(sa.prototype),{constructor:af,ValueTypeName:"color"});
|
|
|
-$c.prototype=Object.assign(Object.create(sa.prototype),{constructor:$c,ValueTypeName:"number"});bf.prototype=Object.assign(Object.create(Ka.prototype),{constructor:bf,interpolate_:function(a,b,c,d){var e=this.resultBuffer,f=this.sampleValues,g=this.valueSize;b=(c-b)/(d-b);a*=g;for(c=a+g;a!==c;a+=4)ua.slerpFlat(e,0,f,a-g,f,a,b);return e}});je.prototype=Object.assign(Object.create(sa.prototype),{constructor:je,ValueTypeName:"quaternion",DefaultInterpolation:2301,InterpolantFactoryMethodLinear:function(a){return new bf(this.times,
|
|
|
+$c.prototype=Object.assign(Object.create(sa.prototype),{constructor:$c,ValueTypeName:"number"});bf.prototype=Object.assign(Object.create(Ka.prototype),{constructor:bf,interpolate_:function(a,b,c,d){var e=this.resultBuffer,f=this.sampleValues,g=this.valueSize;b=(c-b)/(d-b);a*=g;for(c=a+g;a!==c;a+=4)la.slerpFlat(e,0,f,a-g,f,a,b);return e}});je.prototype=Object.assign(Object.create(sa.prototype),{constructor:je,ValueTypeName:"quaternion",DefaultInterpolation:2301,InterpolantFactoryMethodLinear:function(a){return new bf(this.times,
|
|
|
this.values,this.getValueSize(),a)},InterpolantFactoryMethodSmooth:void 0});cf.prototype=Object.assign(Object.create(sa.prototype),{constructor:cf,ValueTypeName:"string",ValueBufferType:Array,DefaultInterpolation:2300,InterpolantFactoryMethodLinear:void 0,InterpolantFactoryMethodSmooth:void 0});ad.prototype=Object.assign(Object.create(sa.prototype),{constructor:ad,ValueTypeName:"vector"});Object.assign(Qa,{parse:function(a){for(var b=[],c=a.tracks,d=1/(a.fps||1),e=0,f=c.length;e!==f;++e)b.push(Hk(c[e]).scale(d));
|
|
|
return new Qa(a.name,a.duration,b,a.blendMode)},toJSON:function(a){var b=[],c=a.tracks;a={name:a.name,duration:a.duration,tracks:b,uuid:a.uuid,blendMode:a.blendMode};for(var d=0,e=c.length;d!==e;++d)b.push(sa.toJSON(c[d]));return a},CreateFromMorphTargetSequence:function(a,b,c,d){for(var e=b.length,f=[],g=0;g<e;g++){var h=[],k=[];h.push((g+e-1)%e,g,(g+1)%e);k.push(0,1,0);var n=Z.getKeyframeOrder(h);h=Z.sortedArray(h,1,n);k=Z.sortedArray(k,1,n);d||0!==h[0]||(h.push(e),k.push(k[0]));f.push((new $c(".morphTargetInfluences["+
|
|
|
b[g].name+"]",h,k)).scale(1/c))}return new Qa(a,-1,f)},findByName:function(a,b){var c=a;Array.isArray(a)||(c=a.geometry&&a.geometry.animations||a.animations);for(a=0;a<c.length;a++)if(c[a].name===b)return c[a];return null},CreateClipsFromMorphTargetSequences:function(a,b,c){for(var d={},e=/^([\w-]*?)([\d]+)$/,f=0,g=a.length;f<g;f++){var h=a[f],k=h.name.match(e);if(k&&1<k.length){k=k[1];var n=d[k];n||(d[k]=n=[]);n.push(h)}}a=[];for(var m in d)a.push(Qa.CreateFromMorphTargetSequence(m,d[m],b,c));return a},
|
|
@@ -787,10 +786,10 @@ k))),f[c].crossVectors(d[c],e[c]);if(!0===b)for(b=Math.acos(L.clamp(e[0].dot(e[a
|
|
|
this.arcLengthDivisions;a.type=this.type;return a},fromJSON:function(a){this.arcLengthDivisions=a.arcLengthDivisions;return this}});La.prototype=Object.create(J.prototype);La.prototype.constructor=La;La.prototype.isEllipseCurve=!0;La.prototype.getPoint=function(a,b){b=b||new w;for(var c=2*Math.PI,d=this.aEndAngle-this.aStartAngle,e=Math.abs(d)<Number.EPSILON;0>d;)d+=c;for(;d>c;)d-=c;d<Number.EPSILON&&(d=e?0:c);!0!==this.aClockwise||e||(d=d===c?-c:d-c);c=this.aStartAngle+a*d;a=this.aX+this.xRadius*
|
|
|
Math.cos(c);var f=this.aY+this.yRadius*Math.sin(c);0!==this.aRotation&&(c=Math.cos(this.aRotation),d=Math.sin(this.aRotation),e=a-this.aX,f-=this.aY,a=e*c-f*d+this.aX,f=e*d+f*c+this.aY);return b.set(a,f)};La.prototype.copy=function(a){J.prototype.copy.call(this,a);this.aX=a.aX;this.aY=a.aY;this.xRadius=a.xRadius;this.yRadius=a.yRadius;this.aStartAngle=a.aStartAngle;this.aEndAngle=a.aEndAngle;this.aClockwise=a.aClockwise;this.aRotation=a.aRotation;return this};La.prototype.toJSON=function(){var a=
|
|
|
J.prototype.toJSON.call(this);a.aX=this.aX;a.aY=this.aY;a.xRadius=this.xRadius;a.yRadius=this.yRadius;a.aStartAngle=this.aStartAngle;a.aEndAngle=this.aEndAngle;a.aClockwise=this.aClockwise;a.aRotation=this.aRotation;return a};La.prototype.fromJSON=function(a){J.prototype.fromJSON.call(this,a);this.aX=a.aX;this.aY=a.aY;this.xRadius=a.xRadius;this.yRadius=a.yRadius;this.aStartAngle=a.aStartAngle;this.aEndAngle=a.aEndAngle;this.aClockwise=a.aClockwise;this.aRotation=a.aRotation;return this};cd.prototype=
|
|
|
-Object.create(La.prototype);cd.prototype.constructor=cd;cd.prototype.isArcCurve=!0;var Rf=new m,kh=new wg,lh=new wg,mh=new wg;pa.prototype=Object.create(J.prototype);pa.prototype.constructor=pa;pa.prototype.isCatmullRomCurve3=!0;pa.prototype.getPoint=function(a,b){b=b||new m;var c=this.points,d=c.length;a*=d-(this.closed?0:1);var e=Math.floor(a);a-=e;this.closed?e+=0<e?0:(Math.floor(Math.abs(e)/d)+1)*d:0===a&&e===d-1&&(e=d-2,a=1);if(this.closed||0<e)var f=c[(e-1)%d];else Rf.subVectors(c[0],c[1]).add(c[0]),
|
|
|
+Object.create(La.prototype);cd.prototype.constructor=cd;cd.prototype.isArcCurve=!0;var Rf=new m,kh=new wg,lh=new wg,mh=new wg;oa.prototype=Object.create(J.prototype);oa.prototype.constructor=oa;oa.prototype.isCatmullRomCurve3=!0;oa.prototype.getPoint=function(a,b){b=b||new m;var c=this.points,d=c.length;a*=d-(this.closed?0:1);var e=Math.floor(a);a-=e;this.closed?e+=0<e?0:(Math.floor(Math.abs(e)/d)+1)*d:0===a&&e===d-1&&(e=d-2,a=1);if(this.closed||0<e)var f=c[(e-1)%d];else Rf.subVectors(c[0],c[1]).add(c[0]),
|
|
|
f=Rf;var g=c[e%d];var h=c[(e+1)%d];this.closed||e+2<d?c=c[(e+2)%d]:(Rf.subVectors(c[d-1],c[d-2]).add(c[d-1]),c=Rf);if("centripetal"===this.curveType||"chordal"===this.curveType){var k="chordal"===this.curveType?.5:.25;d=Math.pow(f.distanceToSquared(g),k);e=Math.pow(g.distanceToSquared(h),k);k=Math.pow(h.distanceToSquared(c),k);1E-4>e&&(e=1);1E-4>d&&(d=e);1E-4>k&&(k=e);kh.initNonuniformCatmullRom(f.x,g.x,h.x,c.x,d,e,k);lh.initNonuniformCatmullRom(f.y,g.y,h.y,c.y,d,e,k);mh.initNonuniformCatmullRom(f.z,
|
|
|
-g.z,h.z,c.z,d,e,k)}else"catmullrom"===this.curveType&&(kh.initCatmullRom(f.x,g.x,h.x,c.x,this.tension),lh.initCatmullRom(f.y,g.y,h.y,c.y,this.tension),mh.initCatmullRom(f.z,g.z,h.z,c.z,this.tension));b.set(kh.calc(a),lh.calc(a),mh.calc(a));return b};pa.prototype.copy=function(a){J.prototype.copy.call(this,a);this.points=[];for(var b=0,c=a.points.length;b<c;b++)this.points.push(a.points[b].clone());this.closed=a.closed;this.curveType=a.curveType;this.tension=a.tension;return this};pa.prototype.toJSON=
|
|
|
-function(){var a=J.prototype.toJSON.call(this);a.points=[];for(var b=0,c=this.points.length;b<c;b++)a.points.push(this.points[b].toArray());a.closed=this.closed;a.curveType=this.curveType;a.tension=this.tension;return a};pa.prototype.fromJSON=function(a){J.prototype.fromJSON.call(this,a);this.points=[];for(var b=0,c=a.points.length;b<c;b++){var d=a.points[b];this.points.push((new m).fromArray(d))}this.closed=a.closed;this.curveType=a.curveType;this.tension=a.tension;return this};Xa.prototype=Object.create(J.prototype);
|
|
|
+g.z,h.z,c.z,d,e,k)}else"catmullrom"===this.curveType&&(kh.initCatmullRom(f.x,g.x,h.x,c.x,this.tension),lh.initCatmullRom(f.y,g.y,h.y,c.y,this.tension),mh.initCatmullRom(f.z,g.z,h.z,c.z,this.tension));b.set(kh.calc(a),lh.calc(a),mh.calc(a));return b};oa.prototype.copy=function(a){J.prototype.copy.call(this,a);this.points=[];for(var b=0,c=a.points.length;b<c;b++)this.points.push(a.points[b].clone());this.closed=a.closed;this.curveType=a.curveType;this.tension=a.tension;return this};oa.prototype.toJSON=
|
|
|
+function(){var a=J.prototype.toJSON.call(this);a.points=[];for(var b=0,c=this.points.length;b<c;b++)a.points.push(this.points[b].toArray());a.closed=this.closed;a.curveType=this.curveType;a.tension=this.tension;return a};oa.prototype.fromJSON=function(a){J.prototype.fromJSON.call(this,a);this.points=[];for(var b=0,c=a.points.length;b<c;b++){var d=a.points[b];this.points.push((new m).fromArray(d))}this.closed=a.closed;this.curveType=a.curveType;this.tension=a.tension;return this};Xa.prototype=Object.create(J.prototype);
|
|
|
Xa.prototype.constructor=Xa;Xa.prototype.isCubicBezierCurve=!0;Xa.prototype.getPoint=function(a,b){b=b||new w;var c=this.v0,d=this.v1,e=this.v2,f=this.v3;b.set(le(a,c.x,d.x,e.x,f.x),le(a,c.y,d.y,e.y,f.y));return b};Xa.prototype.copy=function(a){J.prototype.copy.call(this,a);this.v0.copy(a.v0);this.v1.copy(a.v1);this.v2.copy(a.v2);this.v3.copy(a.v3);return this};Xa.prototype.toJSON=function(){var a=J.prototype.toJSON.call(this);a.v0=this.v0.toArray();a.v1=this.v1.toArray();a.v2=this.v2.toArray();a.v3=
|
|
|
this.v3.toArray();return a};Xa.prototype.fromJSON=function(a){J.prototype.fromJSON.call(this,a);this.v0.fromArray(a.v0);this.v1.fromArray(a.v1);this.v2.fromArray(a.v2);this.v3.fromArray(a.v3);return this};ib.prototype=Object.create(J.prototype);ib.prototype.constructor=ib;ib.prototype.isCubicBezierCurve3=!0;ib.prototype.getPoint=function(a,b){b=b||new m;var c=this.v0,d=this.v1,e=this.v2,f=this.v3;b.set(le(a,c.x,d.x,e.x,f.x),le(a,c.y,d.y,e.y,f.y),le(a,c.z,d.z,e.z,f.z));return b};ib.prototype.copy=
|
|
|
function(a){J.prototype.copy.call(this,a);this.v0.copy(a.v0);this.v1.copy(a.v1);this.v2.copy(a.v2);this.v3.copy(a.v3);return this};ib.prototype.toJSON=function(){var a=J.prototype.toJSON.call(this);a.v0=this.v0.toArray();a.v1=this.v1.toArray();a.v2=this.v2.toArray();a.v3=this.v3.toArray();return a};ib.prototype.fromJSON=function(a){J.prototype.fromJSON.call(this,a);this.v0.fromArray(a.v0);this.v1.fromArray(a.v1);this.v2.fromArray(a.v2);this.v3.fromArray(a.v3);return this};Ca.prototype=Object.create(J.prototype);
|
|
@@ -801,7 +800,7 @@ b){b=b||new w;var c=this.v0,d=this.v1,e=this.v2;b.set(ke(a,c.x,d.x,e.x),ke(a,c.y
|
|
|
return this};jb.prototype=Object.create(J.prototype);jb.prototype.constructor=jb;jb.prototype.isQuadraticBezierCurve3=!0;jb.prototype.getPoint=function(a,b){b=b||new m;var c=this.v0,d=this.v1,e=this.v2;b.set(ke(a,c.x,d.x,e.x),ke(a,c.y,d.y,e.y),ke(a,c.z,d.z,e.z));return b};jb.prototype.copy=function(a){J.prototype.copy.call(this,a);this.v0.copy(a.v0);this.v1.copy(a.v1);this.v2.copy(a.v2);return this};jb.prototype.toJSON=function(){var a=J.prototype.toJSON.call(this);a.v0=this.v0.toArray();a.v1=this.v1.toArray();
|
|
|
a.v2=this.v2.toArray();return a};jb.prototype.fromJSON=function(a){J.prototype.fromJSON.call(this,a);this.v0.fromArray(a.v0);this.v1.fromArray(a.v1);this.v2.fromArray(a.v2);return this};$a.prototype=Object.create(J.prototype);$a.prototype.constructor=$a;$a.prototype.isSplineCurve=!0;$a.prototype.getPoint=function(a,b){b=b||new w;var c=this.points,d=(c.length-1)*a;a=Math.floor(d);d-=a;var e=c[0===a?a:a-1],f=c[a],g=c[a>c.length-2?c.length-1:a+1];c=c[a>c.length-3?c.length-1:a+2];b.set(gi(d,e.x,f.x,g.x,
|
|
|
c.x),gi(d,e.y,f.y,g.y,c.y));return b};$a.prototype.copy=function(a){J.prototype.copy.call(this,a);this.points=[];for(var b=0,c=a.points.length;b<c;b++)this.points.push(a.points[b].clone());return this};$a.prototype.toJSON=function(){var a=J.prototype.toJSON.call(this);a.points=[];for(var b=0,c=this.points.length;b<c;b++)a.points.push(this.points[b].toArray());return a};$a.prototype.fromJSON=function(a){J.prototype.fromJSON.call(this,a);this.points=[];for(var b=0,c=a.points.length;b<c;b++){var d=a.points[b];
|
|
|
-this.points.push((new w).fromArray(d))}return this};var nh=Object.freeze({__proto__:null,ArcCurve:cd,CatmullRomCurve3:pa,CubicBezierCurve:Xa,CubicBezierCurve3:ib,EllipseCurve:La,LineCurve:Ca,LineCurve3:Ya,QuadraticBezierCurve:Za,QuadraticBezierCurve3:jb,SplineCurve:$a});tb.prototype=Object.assign(Object.create(J.prototype),{constructor:tb,add:function(a){this.curves.push(a)},closePath:function(){var a=this.curves[0].getPoint(0),b=this.curves[this.curves.length-1].getPoint(1);a.equals(b)||this.curves.push(new Ca(b,
|
|
|
+this.points.push((new w).fromArray(d))}return this};var nh=Object.freeze({__proto__:null,ArcCurve:cd,CatmullRomCurve3:oa,CubicBezierCurve:Xa,CubicBezierCurve3:ib,EllipseCurve:La,LineCurve:Ca,LineCurve3:Ya,QuadraticBezierCurve:Za,QuadraticBezierCurve3:jb,SplineCurve:$a});tb.prototype=Object.assign(Object.create(J.prototype),{constructor:tb,add:function(a){this.curves.push(a)},closePath:function(){var a=this.curves[0].getPoint(0),b=this.curves[this.curves.length-1].getPoint(1);a.equals(b)||this.curves.push(new Ca(b,
|
|
|
a))},getPoint:function(a){var b=a*this.getLength(),c=this.getCurveLengths();for(a=0;a<c.length;){if(c[a]>=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;c<d;c++)b+=this.curves[c].getLength(),a.push(b);return this.cacheLengths=a},getSpacedPoints:function(a){void 0===a&&(a=40);for(var b=[],c=0;c<=a;c++)b.push(this.getPoint(c/a));this.autoClose&&b.push(b[0]);return b},getPoints:function(a){a=a||12;for(var b=[],c,d=0,e=this.curves;d<e.length;d++){var f=e[d];f=f.getPoints(f&&f.isEllipseCurve?2*a:f&&(f.isLineCurve||f.isLineCurve3)?1:f&&f.isSplineCurve?a*f.points.length:a);for(var g=0;g<f.length;g++){var h=f[g];c&&c.equals(h)||
|
|
|
(b.push(h),c=h)}}this.autoClose&&1<b.length&&!b[b.length-1].equals(b[0])&&b.push(b[0]);return b},copy:function(a){J.prototype.copy.call(this,a);this.curves=[];for(var b=0,c=a.curves.length;b<c;b++)this.curves.push(a.curves[b].clone());this.autoClose=a.autoClose;return this},toJSON:function(){var a=J.prototype.toJSON.call(this);a.autoClose=this.autoClose;a.curves=[];for(var b=0,c=this.curves.length;b<c;b++)a.curves.push(this.curves[b].toJSON());return a},fromJSON:function(a){J.prototype.fromJSON.call(this,
|
|
@@ -877,7 +876,7 @@ this,f=new Ra(e.manager);f.setResponseType("arraybuffer");f.setPath(e.path);f.lo
|
|
|
{constructor:Dg,isAmbientLightProbe:!0,copy:function(a){Sa.prototype.copy.call(this,a);return this},toJSON:function(a){return Sa.prototype.toJSON.call(this,a)}});var Qi=new M,Ri=new M;Object.assign(hi.prototype,{update:function(a){var b=this._cache;if(b.focus!==a.focus||b.fov!==a.fov||b.aspect!==a.aspect*this.aspect||b.near!==a.near||b.far!==a.far||b.zoom!==a.zoom||b.eyeSep!==this.eyeSep){b.focus=a.focus;b.fov=a.fov;b.aspect=a.aspect*this.aspect;b.near=a.near;b.far=a.far;b.zoom=a.zoom;b.eyeSep=this.eyeSep;
|
|
|
var c=a.projectionMatrix.clone(),d=b.eyeSep/2,e=d*b.near/b.focus,f=b.near*Math.tan(L.DEG2RAD*b.fov*.5)/b.zoom;Ri.elements[12]=-d;Qi.elements[12]=d;d=-f*b.aspect+e;var g=f*b.aspect+e;c.elements[0]=2*b.near/(g-d);c.elements[8]=(g+d)/(g-d);this.cameraL.projectionMatrix.copy(c);d=-f*b.aspect-e;g=f*b.aspect-e;c.elements[0]=2*b.near/(g-d);c.elements[8]=(g+d)/(g-d);this.cameraR.projectionMatrix.copy(c)}this.cameraL.matrixWorld.copy(a.matrixWorld).multiply(Ri);this.cameraR.matrixWorld.copy(a.matrixWorld).multiply(Qi)}});
|
|
|
Object.assign(Eg.prototype,{start:function(){this.oldTime=this.startTime=("undefined"===typeof performance?Date:performance).now();this.elapsedTime=0;this.running=!0},stop:function(){this.getElapsedTime();this.autoStart=this.running=!1},getElapsedTime:function(){this.getDelta();return this.elapsedTime},getDelta:function(){var a=0;if(this.autoStart&&!this.running)return this.start(),0;if(this.running){var b=("undefined"===typeof performance?Date:performance).now();a=(b-this.oldTime)/1E3;this.oldTime=
|
|
|
-b;this.elapsedTime+=a}return a}});var tc=new m,Si=new ua,Vk=new m,uc=new m;Fg.prototype=Object.assign(Object.create(y.prototype),{constructor:Fg,getInput:function(){return this.gain},removeFilter:function(){null!==this.filter&&(this.gain.disconnect(this.filter),this.filter.disconnect(this.context.destination),this.gain.connect(this.context.destination),this.filter=null);return this},getFilter:function(){return this.filter},setFilter:function(a){null!==this.filter?(this.gain.disconnect(this.filter),
|
|
|
+b;this.elapsedTime+=a}return a}});var tc=new m,Si=new la,Vk=new m,uc=new m;Fg.prototype=Object.assign(Object.create(y.prototype),{constructor:Fg,getInput:function(){return this.gain},removeFilter:function(){null!==this.filter&&(this.gain.disconnect(this.filter),this.filter.disconnect(this.context.destination),this.gain.connect(this.context.destination),this.filter=null);return this},getFilter:function(){return this.filter},setFilter:function(a){null!==this.filter?(this.gain.disconnect(this.filter),
|
|
|
this.filter.disconnect(this.context.destination)):this.gain.disconnect(this.context.destination);this.filter=a;this.gain.connect(this.filter);this.filter.connect(this.context.destination);return this},getMasterVolume:function(){return this.gain.gain.value},setMasterVolume:function(a){this.gain.gain.setTargetAtTime(a,this.context.currentTime,.01);return this},updateMatrixWorld:function(a){y.prototype.updateMatrixWorld.call(this,a);a=this.context.listener;var b=this.up;this.timeDelta=this._clock.getDelta();
|
|
|
this.matrixWorld.decompose(tc,Si,Vk);uc.set(0,0,-1).applyQuaternion(Si);if(a.positionX){var c=this.context.currentTime+this.timeDelta;a.positionX.linearRampToValueAtTime(tc.x,c);a.positionY.linearRampToValueAtTime(tc.y,c);a.positionZ.linearRampToValueAtTime(tc.z,c);a.forwardX.linearRampToValueAtTime(uc.x,c);a.forwardY.linearRampToValueAtTime(uc.y,c);a.forwardZ.linearRampToValueAtTime(uc.z,c);a.upX.linearRampToValueAtTime(b.x,c);a.upY.linearRampToValueAtTime(b.y,c);a.upZ.linearRampToValueAtTime(b.z,
|
|
|
c)}else a.setPosition(tc.x,tc.y,tc.z),a.setOrientation(uc.x,uc.y,uc.z,b.x,b.y,b.z)}});ed.prototype=Object.assign(Object.create(y.prototype),{constructor:ed,getOutput:function(){return this.gain},setNodeSource:function(a){this.hasPlaybackControl=!1;this.sourceType="audioNode";this.source=a;this.connect();return this},setMediaElementSource:function(a){this.hasPlaybackControl=!1;this.sourceType="mediaNode";this.source=this.context.createMediaElementSource(a);this.connect();return this},setMediaStreamSource:function(a){this.hasPlaybackControl=
|
|
@@ -887,14 +886,14 @@ this._startedAt,0)*this.playbackRate,!0===this.loop&&(this._progress%=this.durat
|
|
|
b;a++)this.filters[a-1].connect(this.filters[a]);this.filters[this.filters.length-1].connect(this.getOutput())}else this.source.connect(this.getOutput());return this},disconnect:function(){if(0<this.filters.length){this.source.disconnect(this.filters[0]);for(var a=1,b=this.filters.length;a<b;a++)this.filters[a-1].disconnect(this.filters[a]);this.filters[this.filters.length-1].disconnect(this.getOutput())}else this.source.disconnect(this.getOutput());return this},getFilters:function(){return this.filters},
|
|
|
setFilters:function(a){a||(a=[]);!0===this.isPlaying?(this.disconnect(),this.filters=a,this.connect()):this.filters=a;return this},setDetune:function(a){this.detune=a;if(void 0!==this.source.detune)return!0===this.isPlaying&&this.source.detune.setTargetAtTime(this.detune,this.context.currentTime,.01),this},getDetune:function(){return this.detune},getFilter:function(){return this.getFilters()[0]},setFilter:function(a){return this.setFilters(a?[a]:[])},setPlaybackRate:function(a){if(!1===this.hasPlaybackControl)console.warn("THREE.Audio: this Audio has no playback control.");
|
|
|
else return this.playbackRate=a,!0===this.isPlaying&&this.source.playbackRate.setTargetAtTime(this.playbackRate,this.context.currentTime,.01),this},getPlaybackRate:function(){return this.playbackRate},onEnded:function(){this.isPlaying=!1},getLoop:function(){return!1===this.hasPlaybackControl?(console.warn("THREE.Audio: this Audio has no playback control."),!1):this.loop},setLoop:function(a){if(!1===this.hasPlaybackControl)console.warn("THREE.Audio: this Audio has no playback control.");else return this.loop=
|
|
|
-a,!0===this.isPlaying&&(this.source.loop=this.loop),this},setLoopStart:function(a){this.loopStart=a;return this},setLoopEnd:function(a){this.loopEnd=a;return this},getVolume:function(){return this.gain.gain.value},setVolume:function(a){this.gain.gain.setTargetAtTime(a,this.context.currentTime,.01);return this}});var vc=new m,Ti=new ua,Wk=new m,wc=new m;Hg.prototype=Object.assign(Object.create(ed.prototype),{constructor:Hg,getOutput:function(){return this.panner},getRefDistance:function(){return this.panner.refDistance},
|
|
|
+a,!0===this.isPlaying&&(this.source.loop=this.loop),this},setLoopStart:function(a){this.loopStart=a;return this},setLoopEnd:function(a){this.loopEnd=a;return this},getVolume:function(){return this.gain.gain.value},setVolume:function(a){this.gain.gain.setTargetAtTime(a,this.context.currentTime,.01);return this}});var vc=new m,Ti=new la,Wk=new m,wc=new m;Hg.prototype=Object.assign(Object.create(ed.prototype),{constructor:Hg,getOutput:function(){return this.panner},getRefDistance:function(){return this.panner.refDistance},
|
|
|
setRefDistance:function(a){this.panner.refDistance=a;return this},getRolloffFactor:function(){return this.panner.rolloffFactor},setRolloffFactor:function(a){this.panner.rolloffFactor=a;return this},getDistanceModel:function(){return this.panner.distanceModel},setDistanceModel:function(a){this.panner.distanceModel=a;return this},getMaxDistance:function(){return this.panner.maxDistance},setMaxDistance:function(a){this.panner.maxDistance=a;return this},setDirectionalCone:function(a,b,c){this.panner.coneInnerAngle=
|
|
|
a;this.panner.coneOuterAngle=b;this.panner.coneOuterGain=c;return this},updateMatrixWorld:function(a){y.prototype.updateMatrixWorld.call(this,a);if(!0!==this.hasPlaybackControl||!1!==this.isPlaying)if(this.matrixWorld.decompose(vc,Ti,Wk),wc.set(0,0,1).applyQuaternion(Ti),a=this.panner,a.positionX){var b=this.context.currentTime+this.listener.timeDelta;a.positionX.linearRampToValueAtTime(vc.x,b);a.positionY.linearRampToValueAtTime(vc.y,b);a.positionZ.linearRampToValueAtTime(vc.z,b);a.orientationX.linearRampToValueAtTime(wc.x,
|
|
|
b);a.orientationY.linearRampToValueAtTime(wc.y,b);a.orientationZ.linearRampToValueAtTime(wc.z,b)}else a.setPosition(vc.x,vc.y,vc.z),a.setOrientation(wc.x,wc.y,wc.z)}});Object.assign(Ig.prototype,{getFrequencyData:function(){this.analyser.getByteFrequencyData(this.data);return this.data},getAverageFrequency:function(){for(var a=0,b=this.getFrequencyData(),c=0;c<b.length;c++)a+=b[c];return a/b.length}});Object.assign(Jg.prototype,{accumulate:function(a,b){var c=this.buffer,d=this.valueSize;a=a*d+d;
|
|
|
var e=this.cumulativeWeight;if(0===e){for(e=0;e!==d;++e)c[a+e]=c[e];e=b}else e+=b,this._mixBufferRegion(c,a,0,b/e,d);this.cumulativeWeight=e},accumulateAdditive:function(a){var b=this.buffer,c=this.valueSize,d=c*this._addIndex;0===this.cumulativeWeightAdditive&&this._setIdentity();this._mixBufferRegionAdditive(b,d,0,a,c);this.cumulativeWeightAdditive+=a},apply:function(a){var b=this.valueSize,c=this.buffer;a=a*b+b;var d=this.cumulativeWeight,e=this.cumulativeWeightAdditive,f=this.binding;this.cumulativeWeightAdditive=
|
|
|
this.cumulativeWeight=0;1>d&&this._mixBufferRegion(c,a,b*this._origIndex,1-d,b);0<e&&this._mixBufferRegionAdditive(c,a,this._addIndex*b,1,b);d=b;for(e=b+b;d!==e;++d)if(c[d]!==c[d+b]){f.setValue(c,a);break}},saveOriginalState:function(){var a=this.buffer,b=this.valueSize,c=b*this._origIndex;this.binding.getValue(a,c);for(var d=b;d!==c;++d)a[d]=a[c+d%b];this._setIdentity();this.cumulativeWeightAdditive=this.cumulativeWeight=0},restoreOriginalState:function(){this.binding.setValue(this.buffer,3*this.valueSize)},
|
|
|
-_setAdditiveIdentityNumeric:function(){for(var a=this._addIndex*this.valueSize,b=a+this.valueSize;a<b;a++)this.buffer[a]=0},_setAdditiveIdentityQuaternion:function(){this._setAdditiveIdentityNumeric();this.buffer[4*this._addIndex+3]=1},_setAdditiveIdentityOther:function(){for(var a=this._origIndex*this.valueSize,b=this._addIndex*this.valueSize,c=0;c<this.valueSize;c++)this.buffer[b+c]=this.buffer[a+c]},_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){ua.slerpFlat(a,
|
|
|
-b,a,b,a,c,d)},_slerpAdditive:function(a,b,c,d,e){e*=this._workIndex;ua.multiplyQuaternionsFlat(a,e,a,b,a,c);ua.slerpFlat(a,b,a,b,a,e,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}},_lerpAdditive:function(a,b,c,d,e){for(var f=0;f!==e;++f){var g=b+f;a[g]+=a[c+f]*d}}});var Xk=/[\[\]\.:\/]/g,Yk="[^"+"\\[\\]\\.:\\/".replace("\\.","")+"]",Zk=/((?:WC+[\/:])*)/.source.replace("WC","[^\\[\\]\\.:\\/]"),$k=/(WCOD+)?/.source.replace("WCOD",Yk),al=/(?:\.(WC+)(?:\[(.+)\])?)?/.source.replace("WC",
|
|
|
+_setAdditiveIdentityNumeric:function(){for(var a=this._addIndex*this.valueSize,b=a+this.valueSize;a<b;a++)this.buffer[a]=0},_setAdditiveIdentityQuaternion:function(){this._setAdditiveIdentityNumeric();this.buffer[4*this._addIndex+3]=1},_setAdditiveIdentityOther:function(){for(var a=this._origIndex*this.valueSize,b=this._addIndex*this.valueSize,c=0;c<this.valueSize;c++)this.buffer[b+c]=this.buffer[a+c]},_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){la.slerpFlat(a,
|
|
|
+b,a,b,a,c,d)},_slerpAdditive:function(a,b,c,d,e){e*=this._workIndex;la.multiplyQuaternionsFlat(a,e,a,b,a,c);la.slerpFlat(a,b,a,b,a,e,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}},_lerpAdditive:function(a,b,c,d,e){for(var f=0;f!==e;++f){var g=b+f;a[g]+=a[c+f]*d}}});var Xk=/[\[\]\.:\/]/g,Yk="[^"+"\\[\\]\\.:\\/".replace("\\.","")+"]",Zk=/((?:WC+[\/:])*)/.source.replace("WC","[^\\[\\]\\.:\\/]"),$k=/(WCOD+)?/.source.replace("WCOD",Yk),al=/(?:\.(WC+)(?:\[(.+)\])?)?/.source.replace("WC",
|
|
|
"[^\\[\\]\\.:\\/]"),bl=/\.(WC+)(?:\[(.+)\])?/.source.replace("WC","[^\\[\\]\\.:\\/]"),cl=new RegExp("^"+Zk+$k+al+bl+"$"),dl=["material","materials","bones"];Object.assign(ii.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(ya,{Composite:ii,create:function(a,b,c){return a&&a.isAnimationObjectGroup?new ya.Composite(a,b,c):new ya(a,b,c)},sanitizeNodeName:function(a){return a.replace(/\s/g,"_").replace(Xk,"")},parseTrackName:function(a){var b=cl.exec(a);if(!b)throw Error("PropertyBinding: Cannot parse trackName: "+a);b={nodeName:b[2],objectName:b[3],objectIndex:b[4],
|
|
|
propertyName:b[5],propertyIndex:b[6]};var c=b.nodeName&&b.nodeName.lastIndexOf(".");if(void 0!==c&&-1!==c){var d=b.nodeName.substring(c+1);-1!==dl.indexOf(d)&&(b.nodeName=b.nodeName.substring(0,c),b.objectName=d)}if(null===b.propertyName||0===b.propertyName.length)throw Error("PropertyBinding: can not parse propertyName from trackName: "+a);return b},findNode:function(a,b){if(!b||""===b||"."===b||-1===b||b===a.name||b===a.uuid)return a;if(a.skeleton){var c=a.skeleton.getBoneByName(b);if(void 0!==
|
|
@@ -968,7 +967,7 @@ lb[b.texture.encoding];Ug(b,0,0,3*mb,2*mb);c.setRenderTarget(b);c.render(e,qh)},
|
|
|
f&&"longitudinal"!==f&&console.error("blur direction must be either latitudinal or longitudinal!");var n=new U(Ce[d],k);k=k.uniforms;var m=dj[c]-1;m=isFinite(e)?Math.PI/(2*m):2*Math.PI/39;var p=e/m,u=isFinite(e)?1+Math.floor(3*p):20;20<u&&console.warn("sigmaRadians, "+e+", is too large and will clip, as it requested "+u+" samples when the maximum is set to 20");e=[];for(var r=0,q=0;20>q;++q){var v=q/p;v=Math.exp(-v*v/2);e.push(v);0==q?r+=v:q<u&&(r+=2*v)}for(p=0;p<e.length;p++)e[p]/=r;k.envMap.value=
|
|
|
a.texture;k.samples.value=u;k.weights.value=e;k.latitudinal.value="latitudinal"===f;g&&(k.poleAxis.value=g);k.dTheta.value=m;k.mipInt.value=8-c;k.inputEncoding.value=lb[a.texture.encoding];k.outputEncoding.value=lb[a.texture.encoding];a=dj[d];Ug(b,3*Math.max(0,mb-2*a),(0===d?0:2*mb)+2*a*(4<d?d-8+4:0),3*a,2*a);h.setRenderTarget(b);h.render(n,qh)}};J.create=function(a,b){console.log("THREE.Curve.create() has been deprecated");a.prototype=Object.create(J.prototype);a.prototype.constructor=a;a.prototype.getPoint=
|
|
|
b;return a};Object.assign(tb.prototype,{createPointsGeometry:function(a){console.warn("THREE.CurvePath: .createPointsGeometry() has been removed. Use new THREE.Geometry().setFromPoints( points ) instead.");a=this.getPoints(a);return this.createGeometry(a)},createSpacedPointsGeometry:function(a){console.warn("THREE.CurvePath: .createSpacedPointsGeometry() has been removed. Use new THREE.Geometry().setFromPoints( points ) instead.");a=this.getSpacedPoints(a);return this.createGeometry(a)},createGeometry:function(a){console.warn("THREE.CurvePath: .createGeometry() has been removed. Use new THREE.Geometry().setFromPoints( points ) instead.");
|
|
|
-for(var b=new H,c=0,d=a.length;c<d;c++){var e=a[c];b.vertices.push(new m(e.x,e.y,e.z||0))}return b}});Object.assign(ab.prototype,{fromPoints:function(a){console.warn("THREE.Path: .fromPoints() has been renamed to .setFromPoints().");return this.setFromPoints(a)}});si.prototype=Object.create(pa.prototype);ti.prototype=Object.create(pa.prototype);Vg.prototype=Object.create(pa.prototype);Object.assign(Vg.prototype,{initFromArray:function(){console.error("THREE.Spline: .initFromArray() has been removed.")},
|
|
|
+for(var b=new H,c=0,d=a.length;c<d;c++){var e=a[c];b.vertices.push(new m(e.x,e.y,e.z||0))}return b}});Object.assign(ab.prototype,{fromPoints:function(a){console.warn("THREE.Path: .fromPoints() has been renamed to .setFromPoints().");return this.setFromPoints(a)}});si.prototype=Object.create(oa.prototype);ti.prototype=Object.create(oa.prototype);Vg.prototype=Object.create(oa.prototype);Object.assign(Vg.prototype,{initFromArray:function(){console.error("THREE.Spline: .initFromArray() has been removed.")},
|
|
|
getControlPointsArray:function(){console.error("THREE.Spline: .getControlPointsArray() has been removed.")},reparametrizeByArcLength:function(){console.error("THREE.Spline: .reparametrizeByArcLength() has been removed.")}});wf.prototype.setColors=function(){console.error("THREE.GridHelper: setColors() has been deprecated, pass them in the constructor instead.")};oc.prototype.update=function(){console.error("THREE.SkeletonHelper: update() no longer needs to be called.")};Object.assign(S.prototype,
|
|
|
{extractUrlBase:function(a){console.warn("THREE.Loader: .extractUrlBase() has been deprecated. Use THREE.LoaderUtils.extractUrlBase() instead.");return oh.extractUrlBase(a)}});S.Handlers={add:function(){console.error("THREE.Loader: Handlers.add() has been removed. Use LoadingManager.addHandler() instead.")},get:function(){console.error("THREE.Loader: Handlers.get() has been removed. Use LoadingManager.getHandler() instead.")}};Object.assign(tf.prototype,{setTexturePath:function(a){console.warn("THREE.ObjectLoader: .setTexturePath() has been renamed to .setResourcePath().");
|
|
|
return this.setResourcePath(a)}});Object.assign(Og.prototype,{center:function(a){console.warn("THREE.Box2: .center() has been renamed to .getCenter().");return this.getCenter(a)},empty:function(){console.warn("THREE.Box2: .empty() has been renamed to .isEmpty().");return this.isEmpty()},isIntersectionBox:function(a){console.warn("THREE.Box2: .isIntersectionBox() has been renamed to .intersectsBox().");return this.intersectsBox(a)},size:function(a){console.warn("THREE.Box2: .size() has been renamed to .getSize().");
|
|
@@ -980,10 +979,10 @@ return a.applyMatrix3(this)},applyToVector3Array:function(){console.error("THREE
|
|
|
return(new m).setFromMatrixColumn(this,3)},setRotationFromQuaternion:function(a){console.warn("THREE.Matrix4: .setRotationFromQuaternion() has been renamed to .makeRotationFromQuaternion().");return this.makeRotationFromQuaternion(a)},multiplyToArray:function(){console.warn("THREE.Matrix4: .multiplyToArray() has been removed.")},multiplyVector3:function(a){console.warn("THREE.Matrix4: .multiplyVector3() has been removed. Use vector.applyMatrix4( matrix ) instead.");return a.applyMatrix4(this)},multiplyVector4:function(a){console.warn("THREE.Matrix4: .multiplyVector4() has been removed. Use vector.applyMatrix4( matrix ) instead.");
|
|
|
return a.applyMatrix4(this)},multiplyVector3Array:function(){console.error("THREE.Matrix4: .multiplyVector3Array() has been removed.")},rotateAxis:function(a){console.warn("THREE.Matrix4: .rotateAxis() has been removed. Use Vector3.transformDirection( matrix ) instead.");a.transformDirection(this)},crossVector:function(a){console.warn("THREE.Matrix4: .crossVector() has been removed. Use vector.applyMatrix4( matrix ) instead.");return a.applyMatrix4(this)},translate:function(){console.error("THREE.Matrix4: .translate() has been removed.")},
|
|
|
rotateX:function(){console.error("THREE.Matrix4: .rotateX() has been removed.")},rotateY:function(){console.error("THREE.Matrix4: .rotateY() has been removed.")},rotateZ:function(){console.error("THREE.Matrix4: .rotateZ() has been removed.")},rotateByAxis:function(){console.error("THREE.Matrix4: .rotateByAxis() has been removed.")},applyToBufferAttribute:function(a){console.warn("THREE.Matrix4: .applyToBufferAttribute() has been removed. Use attribute.applyMatrix4( matrix ) instead.");return a.applyMatrix4(this)},
|
|
|
-applyToVector3Array:function(){console.error("THREE.Matrix4: .applyToVector3Array() has been removed.")},makeFrustum:function(a,b,c,d,e,f){console.warn("THREE.Matrix4: .makeFrustum() has been removed. Use .makePerspective( left, right, top, bottom, near, far ) instead.");return this.makePerspective(a,b,d,c,e,f)}});Ua.prototype.isIntersectionLine=function(a){console.warn("THREE.Plane: .isIntersectionLine() has been renamed to .intersectsLine().");return this.intersectsLine(a)};ua.prototype.multiplyVector3=
|
|
|
+applyToVector3Array:function(){console.error("THREE.Matrix4: .applyToVector3Array() has been removed.")},makeFrustum:function(a,b,c,d,e,f){console.warn("THREE.Matrix4: .makeFrustum() has been removed. Use .makePerspective( left, right, top, bottom, near, far ) instead.");return this.makePerspective(a,b,d,c,e,f)}});Ua.prototype.isIntersectionLine=function(a){console.warn("THREE.Plane: .isIntersectionLine() has been renamed to .intersectsLine().");return this.intersectsLine(a)};la.prototype.multiplyVector3=
|
|
|
function(a){console.warn("THREE.Quaternion: .multiplyVector3() has been removed. Use is now vector.applyQuaternion( quaternion ) instead.");return a.applyQuaternion(this)};Object.assign(Vb.prototype,{isIntersectionBox:function(a){console.warn("THREE.Ray: .isIntersectionBox() has been renamed to .intersectsBox().");return this.intersectsBox(a)},isIntersectionPlane:function(a){console.warn("THREE.Ray: .isIntersectionPlane() has been renamed to .intersectsPlane().");return this.intersectsPlane(a)},isIntersectionSphere:function(a){console.warn("THREE.Ray: .isIntersectionSphere() has been renamed to .intersectsSphere().");
|
|
|
-return this.intersectsSphere(a)}});Object.assign(oa.prototype,{area:function(){console.warn("THREE.Triangle: .area() has been renamed to .getArea().");return this.getArea()},barycoordFromPoint:function(a,b){console.warn("THREE.Triangle: .barycoordFromPoint() has been renamed to .getBarycoord().");return this.getBarycoord(a,b)},midpoint:function(a){console.warn("THREE.Triangle: .midpoint() has been renamed to .getMidpoint().");return this.getMidpoint(a)},normal:function(a){console.warn("THREE.Triangle: .normal() has been renamed to .getNormal().");
|
|
|
-return this.getNormal(a)},plane:function(a){console.warn("THREE.Triangle: .plane() has been renamed to .getPlane().");return this.getPlane(a)}});Object.assign(oa,{barycoordFromPoint:function(a,b,c,d,e){console.warn("THREE.Triangle: .barycoordFromPoint() has been renamed to .getBarycoord().");return oa.getBarycoord(a,b,c,d,e)},normal:function(a,b,c,d){console.warn("THREE.Triangle: .normal() has been renamed to .getNormal().");return oa.getNormal(a,b,c,d)}});Object.assign(Mb.prototype,{extractAllPoints:function(a){console.warn("THREE.Shape: .extractAllPoints() has been removed. Use .extractPoints() instead.");
|
|
|
+return this.intersectsSphere(a)}});Object.assign(va.prototype,{area:function(){console.warn("THREE.Triangle: .area() has been renamed to .getArea().");return this.getArea()},barycoordFromPoint:function(a,b){console.warn("THREE.Triangle: .barycoordFromPoint() has been renamed to .getBarycoord().");return this.getBarycoord(a,b)},midpoint:function(a){console.warn("THREE.Triangle: .midpoint() has been renamed to .getMidpoint().");return this.getMidpoint(a)},normal:function(a){console.warn("THREE.Triangle: .normal() has been renamed to .getNormal().");
|
|
|
+return this.getNormal(a)},plane:function(a){console.warn("THREE.Triangle: .plane() has been renamed to .getPlane().");return this.getPlane(a)}});Object.assign(va,{barycoordFromPoint:function(a,b,c,d,e){console.warn("THREE.Triangle: .barycoordFromPoint() has been renamed to .getBarycoord().");return va.getBarycoord(a,b,c,d,e)},normal:function(a,b,c,d){console.warn("THREE.Triangle: .normal() has been renamed to .getNormal().");return va.getNormal(a,b,c,d)}});Object.assign(Mb.prototype,{extractAllPoints:function(a){console.warn("THREE.Shape: .extractAllPoints() has been removed. Use .extractPoints() instead.");
|
|
|
return this.extractPoints(a)},extrude:function(a){console.warn("THREE.Shape: .extrude() has been removed. Use ExtrudeGeometry() instead.");return new cc(this,a)},makeGeometry:function(a){console.warn("THREE.Shape: .makeGeometry() has been removed. Use ShapeGeometry() instead.");return new ec(this,a)}});Object.assign(w.prototype,{fromAttribute:function(a,b,c){console.warn("THREE.Vector2: .fromAttribute() has been renamed to .fromBufferAttribute().");return this.fromBufferAttribute(a,b,c)},distanceToManhattan:function(a){console.warn("THREE.Vector2: .distanceToManhattan() has been renamed to .manhattanDistanceTo().");
|
|
|
return this.manhattanDistanceTo(a)},lengthManhattan:function(){console.warn("THREE.Vector2: .lengthManhattan() has been renamed to .manhattanLength().");return this.manhattanLength()}});Object.assign(m.prototype,{setEulerFromRotationMatrix:function(){console.error("THREE.Vector3: .setEulerFromRotationMatrix() has been removed. Use Euler.setFromRotationMatrix() instead.")},setEulerFromQuaternion:function(){console.error("THREE.Vector3: .setEulerFromQuaternion() has been removed. Use Euler.setFromQuaternion() instead.")},
|
|
|
getPositionFromMatrix:function(a){console.warn("THREE.Vector3: .getPositionFromMatrix() has been renamed to .setFromMatrixPosition().");return this.setFromMatrixPosition(a)},getScaleFromMatrix:function(a){console.warn("THREE.Vector3: .getScaleFromMatrix() has been renamed to .setFromMatrixScale().");return this.setFromMatrixScale(a)},getColumnFromMatrix:function(a,b){console.warn("THREE.Vector3: .getColumnFromMatrix() has been renamed to .setFromMatrixColumn().");return this.setFromMatrixColumn(b,
|
|
@@ -1028,9 +1027,9 @@ this.texture.format=a}},type:{get:function(){console.warn("THREE.WebGLRenderTarg
|
|
|
this.texture.generateMipmaps=a}}});Object.defineProperties(ed.prototype,{load:{value:function(a){console.warn("THREE.Audio: .load has been deprecated. Use THREE.AudioLoader instead.");var b=this;(new uf).load(a,function(a){b.setBuffer(a)});return this}},startTime:{set:function(){console.warn("THREE.Audio: .startTime is now .play( delay ).")}}});Ig.prototype.getData=function(){console.warn("THREE.AudioAnalyser: .getData() is now .getFrequencyData().");return this.getFrequencyData()};Dc.prototype.updateCubeMap=
|
|
|
function(a,b){console.warn("THREE.CubeCamera: .updateCubeMap() is now .update().");return this.update(a,b)};Nb.crossOrigin=void 0;Nb.loadTexture=function(a,b,c,d){console.warn("THREE.ImageUtils.loadTexture has been deprecated. Use THREE.TextureLoader() instead.");var e=new ff;e.setCrossOrigin(this.crossOrigin);a=e.load(a,c,void 0,d);b&&(a.mapping=b);return a};Nb.loadTextureCube=function(a,b,c,d){console.warn("THREE.ImageUtils.loadTextureCube has been deprecated. Use THREE.CubeTextureLoader() instead.");
|
|
|
var e=new ef;e.setCrossOrigin(this.crossOrigin);a=e.load(a,c,void 0,d);b&&(a.mapping=b);return a};Nb.loadCompressedTexture=function(){console.error("THREE.ImageUtils.loadCompressedTexture has been removed. Use THREE.DDSLoader instead.")};Nb.loadCompressedTextureCube=function(){console.error("THREE.ImageUtils.loadCompressedTextureCube has been removed. Use THREE.DDSLoader instead.")};"undefined"!==typeof __THREE_DEVTOOLS__&&__THREE_DEVTOOLS__.dispatchEvent(new CustomEvent("register",{detail:{revision:"118dev"}}));
|
|
|
-k.ACESFilmicToneMapping=5;k.AddEquation=100;k.AddOperation=2;k.AdditiveAnimationBlendMode=2501;k.AdditiveBlending=2;k.AlphaFormat=1021;k.AlwaysDepth=1;k.AlwaysStencilFunc=519;k.AmbientLight=nf;k.AmbientLightProbe=Dg;k.AnimationClip=Qa;k.AnimationLoader=ug;k.AnimationMixer=Kg;k.AnimationObjectGroup=ji;k.AnimationUtils=Z;k.ArcCurve=cd;k.ArrayCamera=Me;k.ArrowHelper=vb;k.Audio=ed;k.AudioAnalyser=Ig;k.AudioContext=Gg;k.AudioListener=Fg;k.AudioLoader=uf;k.AxesHelper=re;k.AxisHelper=function(a){console.warn("THREE.AxisHelper has been renamed to THREE.AxesHelper.");
|
|
|
+k.ACESFilmicToneMapping=4;k.AddEquation=100;k.AddOperation=2;k.AdditiveAnimationBlendMode=2501;k.AdditiveBlending=2;k.AlphaFormat=1021;k.AlwaysDepth=1;k.AlwaysStencilFunc=519;k.AmbientLight=nf;k.AmbientLightProbe=Dg;k.AnimationClip=Qa;k.AnimationLoader=ug;k.AnimationMixer=Kg;k.AnimationObjectGroup=ji;k.AnimationUtils=Z;k.ArcCurve=cd;k.ArrayCamera=Me;k.ArrowHelper=vb;k.Audio=ed;k.AudioAnalyser=Ig;k.AudioContext=Gg;k.AudioListener=Fg;k.AudioLoader=uf;k.AxesHelper=re;k.AxisHelper=function(a){console.warn("THREE.AxisHelper has been renamed to THREE.AxesHelper.");
|
|
|
return new re(a)};k.BackSide=1;k.BasicDepthPacking=3200;k.BasicShadowMap=0;k.BinaryTextureLoader=function(a){console.warn("THREE.BinaryTextureLoader has been renamed to THREE.DataTextureLoader.");return new df(a)};k.Bone=ng;k.BooleanKeyframeTrack=$e;k.BoundingBoxHelper=function(a,b){console.warn("THREE.BoundingBoxHelper has been deprecated. Creating a THREE.BoxHelper instead.");return new ub(a,b)};k.Box2=Og;k.Box3=Ta;k.Box3Helper=pe;k.BoxBufferGeometry=Fd;k.BoxGeometry=ih;k.BoxHelper=ub;k.BufferAttribute=
|
|
|
-G;k.BufferGeometry=F;k.BufferGeometryLoader=sf;k.ByteType=1010;k.Cache=sc;k.Camera=eb;k.CameraHelper=oe;k.CanvasRenderer=function(){console.error("THREE.CanvasRenderer has been removed")};k.CanvasTexture=Od;k.CatmullRomCurve3=pa;k.CineonToneMapping=4;k.CircleBufferGeometry=Zc;k.CircleGeometry=he;k.ClampToEdgeWrapping=1001;k.Clock=Eg;k.ClosedSplineCurve3=si;k.Color=D;k.ColorKeyframeTrack=af;k.CompressedTexture=Mc;k.CompressedTextureLoader=vg;k.ConeBufferGeometry=ge;k.ConeGeometry=fe;k.CubeCamera=Dc;
|
|
|
+G;k.BufferGeometry=F;k.BufferGeometryLoader=sf;k.ByteType=1010;k.Cache=sc;k.Camera=eb;k.CameraHelper=oe;k.CanvasRenderer=function(){console.error("THREE.CanvasRenderer has been removed")};k.CanvasTexture=Od;k.CatmullRomCurve3=oa;k.CineonToneMapping=3;k.CircleBufferGeometry=Zc;k.CircleGeometry=he;k.ClampToEdgeWrapping=1001;k.Clock=Eg;k.ClosedSplineCurve3=si;k.Color=D;k.ColorKeyframeTrack=af;k.CompressedTexture=Mc;k.CompressedTextureLoader=vg;k.ConeBufferGeometry=ge;k.ConeGeometry=fe;k.CubeCamera=Dc;
|
|
|
k.CubeGeometry=ih;k.CubeReflectionMapping=301;k.CubeRefractionMapping=302;k.CubeTexture=pb;k.CubeTextureLoader=ef;k.CubeUVReflectionMapping=306;k.CubeUVRefractionMapping=307;k.CubicBezierCurve=Xa;k.CubicBezierCurve3=ib;k.CubicInterpolant=Ye;k.CullFaceBack=1;k.CullFaceFront=2;k.CullFaceFrontBack=3;k.CullFaceNone=0;k.Curve=J;k.CurvePath=tb;k.CustomBlending=5;k.CylinderBufferGeometry=rb;k.CylinderGeometry=gc;k.Cylindrical=ni;k.DataTexture=Zb;k.DataTexture2DArray=Fc;k.DataTexture3D=Gc;k.DataTextureLoader=
|
|
|
df;k.DecrementStencilOp=7683;k.DecrementWrapStencilOp=34056;k.DefaultLoadingManager=fi;k.DepthFormat=1026;k.DepthStencilFormat=1027;k.DepthTexture=Pd;k.DirectionalLight=mf;k.DirectionalLightHelper=id;k.DirectionalLightShadow=lf;k.DiscreteInterpolant=Ze;k.DodecahedronBufferGeometry=Rc;k.DodecahedronGeometry=Vd;k.DoubleSide=2;k.DstAlphaFactor=206;k.DstColorFactor=208;k.DynamicBufferAttribute=function(a,b){console.warn("THREE.DynamicBufferAttribute has been removed. Use new THREE.BufferAttribute().setUsage( THREE.DynamicDrawUsage ) instead.");
|
|
|
return(new G(a,b)).setUsage(35048)};k.DynamicCopyUsage=35050;k.DynamicDrawUsage=35048;k.DynamicReadUsage=35049;k.EdgesGeometry=Yc;k.EdgesHelper=function(a,b){console.warn("THREE.EdgesHelper has been removed. Use THREE.EdgesGeometry instead.");return new da(new Yc(a.geometry),new ja({color:void 0!==b?b:16777215}))};k.EllipseCurve=La;k.EqualDepth=4;k.EqualStencilFunc=514;k.EquirectangularReflectionMapping=303;k.EquirectangularRefractionMapping=304;k.Euler=Tb;k.EventDispatcher=ta;k.ExtrudeBufferGeometry=
|
|
@@ -1045,15 +1044,15 @@ Fb;k.MeshDistanceMaterial=Gb;k.MeshFaceMaterial=function(a){console.warn("THREE.
|
|
|
a.isMultiMaterial=!0;a.materials=a;a.clone=function(){return a.slice()};return a};k.MultiplyBlending=4;k.MultiplyOperation=0;k.NearestFilter=1003;k.NearestMipMapLinearFilter=1005;k.NearestMipMapNearestFilter=1004;k.NearestMipmapLinearFilter=1005;k.NearestMipmapNearestFilter=1004;k.NeverDepth=0;k.NeverStencilFunc=512;k.NoBlending=0;k.NoColors=0;k.NoToneMapping=0;k.NormalAnimationBlendMode=2500;k.NormalBlending=1;k.NotEqualDepth=7;k.NotEqualStencilFunc=517;k.NumberKeyframeTrack=$c;k.Object3D=y;k.ObjectLoader=
|
|
|
tf;k.ObjectSpaceNormalMap=1;k.OctahedronBufferGeometry=ac;k.OctahedronGeometry=Td;k.OneFactor=201;k.OneMinusDstAlphaFactor=207;k.OneMinusDstColorFactor=209;k.OneMinusSrcAlphaFactor=205;k.OneMinusSrcColorFactor=203;k.OrthographicCamera=dd;k.PCFShadowMap=1;k.PCFSoftShadowMap=2;k.PMREMGenerator=Rg;k.ParametricBufferGeometry=Oc;k.ParametricGeometry=Qd;k.Particle=function(a){console.warn("THREE.Particle has been renamed to THREE.Sprite.");return new Ld(a)};k.ParticleBasicMaterial=function(a){console.warn("THREE.ParticleBasicMaterial has been renamed to THREE.PointsMaterial.");
|
|
|
return new Wa(a)};k.ParticleSystem=function(a,b){console.warn("THREE.ParticleSystem has been renamed to THREE.Points.");return new Lc(a,b)};k.ParticleSystemMaterial=function(a){console.warn("THREE.ParticleSystemMaterial has been renamed to THREE.PointsMaterial.");return new Wa(a)};k.Path=ab;k.PerspectiveCamera=T;k.Plane=Ua;k.PlaneBufferGeometry=$b;k.PlaneGeometry=Ed;k.PlaneHelper=qe;k.PointCloud=function(a,b){console.warn("THREE.PointCloud has been renamed to THREE.Points.");return new Lc(a,b)};k.PointCloudMaterial=
|
|
|
-function(a){console.warn("THREE.PointCloudMaterial has been renamed to THREE.PointsMaterial.");return new Wa(a)};k.PointLight=kf;k.PointLightHelper=gd;k.Points=Lc;k.PointsMaterial=Wa;k.PolarGridHelper=xf;k.PolyhedronBufferGeometry=Ea;k.PolyhedronGeometry=Rd;k.PositionalAudio=Hg;k.PropertyBinding=ya;k.PropertyMixer=Jg;k.QuadraticBezierCurve=Za;k.QuadraticBezierCurve3=jb;k.Quaternion=ua;k.QuaternionKeyframeTrack=je;k.QuaternionLinearInterpolant=bf;k.REVISION="118dev";k.RGBADepthPacking=3201;k.RGBAFormat=
|
|
|
+function(a){console.warn("THREE.PointCloudMaterial has been renamed to THREE.PointsMaterial.");return new Wa(a)};k.PointLight=kf;k.PointLightHelper=gd;k.Points=Lc;k.PointsMaterial=Wa;k.PolarGridHelper=xf;k.PolyhedronBufferGeometry=Ea;k.PolyhedronGeometry=Rd;k.PositionalAudio=Hg;k.PropertyBinding=ya;k.PropertyMixer=Jg;k.QuadraticBezierCurve=Za;k.QuadraticBezierCurve3=jb;k.Quaternion=la;k.QuaternionKeyframeTrack=je;k.QuaternionLinearInterpolant=bf;k.REVISION="118dev";k.RGBADepthPacking=3201;k.RGBAFormat=
|
|
|
1023;k.RGBAIntegerFormat=1033;k.RGBA_ASTC_10x10_Format=37819;k.RGBA_ASTC_10x5_Format=37816;k.RGBA_ASTC_10x6_Format=37817;k.RGBA_ASTC_10x8_Format=37818;k.RGBA_ASTC_12x10_Format=37820;k.RGBA_ASTC_12x12_Format=37821;k.RGBA_ASTC_4x4_Format=37808;k.RGBA_ASTC_5x4_Format=37809;k.RGBA_ASTC_5x5_Format=37810;k.RGBA_ASTC_6x5_Format=37811;k.RGBA_ASTC_6x6_Format=37812;k.RGBA_ASTC_8x5_Format=37813;k.RGBA_ASTC_8x6_Format=37814;k.RGBA_ASTC_8x8_Format=37815;k.RGBA_BPTC_Format=36492;k.RGBA_ETC2_EAC_Format=37496;k.RGBA_PVRTC_2BPPV1_Format=
|
|
|
35843;k.RGBA_PVRTC_4BPPV1_Format=35842;k.RGBA_S3TC_DXT1_Format=33777;k.RGBA_S3TC_DXT3_Format=33778;k.RGBA_S3TC_DXT5_Format=33779;k.RGBDEncoding=3006;k.RGBEEncoding=3002;k.RGBEFormat=1023;k.RGBFormat=1022;k.RGBIntegerFormat=1032;k.RGBM16Encoding=3005;k.RGBM7Encoding=3004;k.RGB_ETC1_Format=36196;k.RGB_ETC2_Format=37492;k.RGB_PVRTC_2BPPV1_Format=35841;k.RGB_PVRTC_4BPPV1_Format=35840;k.RGB_S3TC_DXT1_Format=33776;k.RGFormat=1030;k.RGIntegerFormat=1031;k.RawShaderMaterial=sb;k.Ray=Vb;k.Raycaster=Mg;k.RectAreaLight=
|
|
|
of;k.RedFormat=1028;k.RedIntegerFormat=1029;k.ReinhardToneMapping=2;k.RepeatWrapping=1E3;k.ReplaceStencilOp=7681;k.ReverseSubtractEquation=102;k.RingBufferGeometry=Wc;k.RingGeometry=de;k.SRGB8_ALPHA8_ASTC_10x10_Format=37851;k.SRGB8_ALPHA8_ASTC_10x5_Format=37848;k.SRGB8_ALPHA8_ASTC_10x6_Format=37849;k.SRGB8_ALPHA8_ASTC_10x8_Format=37850;k.SRGB8_ALPHA8_ASTC_12x10_Format=37852;k.SRGB8_ALPHA8_ASTC_12x12_Format=37853;k.SRGB8_ALPHA8_ASTC_4x4_Format=37840;k.SRGB8_ALPHA8_ASTC_5x4_Format=37841;k.SRGB8_ALPHA8_ASTC_5x5_Format=
|
|
|
37842;k.SRGB8_ALPHA8_ASTC_6x5_Format=37843;k.SRGB8_ALPHA8_ASTC_6x6_Format=37844;k.SRGB8_ALPHA8_ASTC_8x5_Format=37845;k.SRGB8_ALPHA8_ASTC_8x6_Format=37846;k.SRGB8_ALPHA8_ASTC_8x8_Format=37847;k.Scene=wd;k.SceneUtils={createMultiMaterialObject:function(){console.error("THREE.SceneUtils has been moved to /examples/jsm/utils/SceneUtils.js")},detach:function(){console.error("THREE.SceneUtils has been moved to /examples/jsm/utils/SceneUtils.js")},attach:function(){console.error("THREE.SceneUtils has been moved to /examples/jsm/utils/SceneUtils.js")}};
|
|
|
k.ShaderChunk=Q;k.ShaderLib=fb;k.ShaderMaterial=Aa;k.ShadowMaterial=hc;k.Shape=Mb;k.ShapeBufferGeometry=fc;k.ShapeGeometry=ec;k.ShapePath=zg;k.ShapeUtils=qb;k.ShortType=1011;k.Skeleton=Se;k.SkeletonHelper=oc;k.SkinnedMesh=Re;k.SmoothShading=2;k.Sphere=db;k.SphereBufferGeometry=dc;k.SphereGeometry=ce;k.Spherical=mi;k.SphericalHarmonics3=pf;k.Spline=Vg;k.SplineCurve=$a;k.SplineCurve3=ti;k.SpotLight=jf;k.SpotLightHelper=fd;k.SpotLightShadow=hf;k.Sprite=Ld;k.SpriteMaterial=Jb;k.SrcAlphaFactor=204;k.SrcAlphaSaturateFactor=
|
|
|
210;k.SrcColorFactor=202;k.StaticCopyUsage=35046;k.StaticDrawUsage=35044;k.StaticReadUsage=35045;k.StereoCamera=hi;k.StreamCopyUsage=35042;k.StreamDrawUsage=35040;k.StreamReadUsage=35041;k.StringKeyframeTrack=cf;k.SubtractEquation=101;k.SubtractiveBlending=3;k.TOUCH={ROTATE:0,PAN:1,DOLLY_PAN:2,DOLLY_ROTATE:3};k.TangentSpaceNormalMap=0;k.TetrahedronBufferGeometry=Pc;k.TetrahedronGeometry=Sd;k.TextBufferGeometry=Vc;k.TextGeometry=be;k.Texture=R;k.TextureLoader=ff;k.TorusBufferGeometry=Tc;k.TorusGeometry=
|
|
|
-Yd;k.TorusKnotBufferGeometry=Sc;k.TorusKnotGeometry=Xd;k.Triangle=oa;k.TriangleFanDrawMode=2;k.TriangleStripDrawMode=1;k.TrianglesDrawMode=0;k.TubeBufferGeometry=bc;k.TubeGeometry=Wd;k.UVMapping=300;k.Uint16Attribute=function(a,b){console.warn("THREE.Uint16Attribute has been removed. Use new THREE.Uint16BufferAttribute() instead.");return new Wb(a,b)};k.Uint16BufferAttribute=Wb;k.Uint32Attribute=function(a,b){console.warn("THREE.Uint32Attribute has been removed. Use new THREE.Uint32BufferAttribute() instead.");
|
|
|
-return new Xb(a,b)};k.Uint32BufferAttribute=Xb;k.Uint8Attribute=function(a,b){console.warn("THREE.Uint8Attribute has been removed. Use new THREE.Uint8BufferAttribute() instead.");return new yd(a,b)};k.Uint8BufferAttribute=yd;k.Uint8ClampedAttribute=function(a,b){console.warn("THREE.Uint8ClampedAttribute has been removed. Use new THREE.Uint8ClampedBufferAttribute() instead.");return new zd(a,b)};k.Uint8ClampedBufferAttribute=zd;k.Uncharted2ToneMapping=3;k.Uniform=vf;k.UniformsLib=E;k.UniformsUtils=
|
|
|
-Qh;k.UnsignedByteType=1009;k.UnsignedInt248Type=1020;k.UnsignedIntType=1014;k.UnsignedShort4444Type=1017;k.UnsignedShort5551Type=1018;k.UnsignedShort565Type=1019;k.UnsignedShortType=1012;k.VSMShadowMap=3;k.Vector2=w;k.Vector3=m;k.Vector4=ea;k.VectorKeyframeTrack=ad;k.Vertex=function(a,b,c){console.warn("THREE.Vertex has been removed. Use THREE.Vector3 instead.");return new m(a,b,c)};k.VertexColors=2;k.VideoTexture=qg;k.WebGLCubeRenderTarget=Yb;k.WebGLMultisampleRenderTarget=Zf;k.WebGLRenderTarget=
|
|
|
-Ga;k.WebGLRenderTargetCube=function(a,b,c){console.warn("THREE.WebGLRenderTargetCube( width, height, options ) is now WebGLCubeRenderTarget( size, options ).");return new Yb(a,c)};k.WebGLRenderer=mg;k.WebGLUtils=Uh;k.WireframeGeometry=Nc;k.WireframeHelper=function(a,b){console.warn("THREE.WireframeHelper has been removed. Use THREE.WireframeGeometry instead.");return new da(new Nc(a.geometry),new ja({color:void 0!==b?b:16777215}))};k.WrapAroundEnding=2402;k.XHRLoader=function(a){console.warn("THREE.XHRLoader has been renamed to THREE.FileLoader.");
|
|
|
+Yd;k.TorusKnotBufferGeometry=Sc;k.TorusKnotGeometry=Xd;k.Triangle=va;k.TriangleFanDrawMode=2;k.TriangleStripDrawMode=1;k.TrianglesDrawMode=0;k.TubeBufferGeometry=bc;k.TubeGeometry=Wd;k.UVMapping=300;k.Uint16Attribute=function(a,b){console.warn("THREE.Uint16Attribute has been removed. Use new THREE.Uint16BufferAttribute() instead.");return new Wb(a,b)};k.Uint16BufferAttribute=Wb;k.Uint32Attribute=function(a,b){console.warn("THREE.Uint32Attribute has been removed. Use new THREE.Uint32BufferAttribute() instead.");
|
|
|
+return new Xb(a,b)};k.Uint32BufferAttribute=Xb;k.Uint8Attribute=function(a,b){console.warn("THREE.Uint8Attribute has been removed. Use new THREE.Uint8BufferAttribute() instead.");return new yd(a,b)};k.Uint8BufferAttribute=yd;k.Uint8ClampedAttribute=function(a,b){console.warn("THREE.Uint8ClampedAttribute has been removed. Use new THREE.Uint8ClampedBufferAttribute() instead.");return new zd(a,b)};k.Uint8ClampedBufferAttribute=zd;k.Uniform=vf;k.UniformsLib=E;k.UniformsUtils=Qh;k.UnsignedByteType=1009;
|
|
|
+k.UnsignedInt248Type=1020;k.UnsignedIntType=1014;k.UnsignedShort4444Type=1017;k.UnsignedShort5551Type=1018;k.UnsignedShort565Type=1019;k.UnsignedShortType=1012;k.VSMShadowMap=3;k.Vector2=w;k.Vector3=m;k.Vector4=ea;k.VectorKeyframeTrack=ad;k.Vertex=function(a,b,c){console.warn("THREE.Vertex has been removed. Use THREE.Vector3 instead.");return new m(a,b,c)};k.VertexColors=2;k.VideoTexture=qg;k.WebGLCubeRenderTarget=Yb;k.WebGLMultisampleRenderTarget=Zf;k.WebGLRenderTarget=Ga;k.WebGLRenderTargetCube=
|
|
|
+function(a,b,c){console.warn("THREE.WebGLRenderTargetCube( width, height, options ) is now WebGLCubeRenderTarget( size, options ).");return new Yb(a,c)};k.WebGLRenderer=mg;k.WebGLUtils=Uh;k.WireframeGeometry=Nc;k.WireframeHelper=function(a,b){console.warn("THREE.WireframeHelper has been removed. Use THREE.WireframeGeometry instead.");return new da(new Nc(a.geometry),new ja({color:void 0!==b?b:16777215}))};k.WrapAroundEnding=2402;k.XHRLoader=function(a){console.warn("THREE.XHRLoader has been renamed to THREE.FileLoader.");
|
|
|
return new Ra(a)};k.ZeroCurvatureEnding=2400;k.ZeroFactor=200;k.ZeroSlopeEnding=2401;k.ZeroStencilOp=0;k.sRGBEncoding=3001;Object.defineProperty(k,"__esModule",{value:!0})});
|