|
@@ -191,7 +191,7 @@ e=b.image.height,f=oa.convert(b.format);this.setTexture2D(b,0);E.copyTexImage2D(
|
|
|
null;this.rotation=0;this.lights=this.fog=!1;this.setValues(a)}function Ac(a){A.call(this);this.type="Sprite";this.material=void 0!==a?a:new fb;this.center=new C(.5,.5)}function Bc(){A.call(this);this.type="LOD";Object.defineProperties(this,{levels:{enumerable:!0,value:[]}})}function Cc(a,b){a=a||[];this.bones=a.slice(0);this.boneMatrices=new Float32Array(16*this.bones.length);if(void 0===b)this.calculateInverses();else if(this.bones.length===b.length)this.boneInverses=b.slice(0);else for(console.warn("THREE.Skeleton boneInverses is the wrong length."),
|
|
|
this.boneInverses=[],a=0,b=this.bones.length;a<b;a++)this.boneInverses.push(new Q)}function rd(){A.call(this);this.type="Bone"}function sd(a,b){ua.call(this,a,b);this.type="SkinnedMesh";this.bindMode="attached";this.bindMatrix=new Q;this.bindMatrixInverse=new Q;a=this.initBones();a=new Cc(a);this.bind(a,this.matrixWorld);this.normalizeSkinWeights()}function Z(a){L.call(this);this.type="LineBasicMaterial";this.color=new G(16777215);this.linewidth=1;this.linejoin=this.linecap="round";this.lights=!1;
|
|
|
this.setValues(a)}function qa(a,b,c){if(1===c)return console.warn("THREE.Line: parameter THREE.LinePieces no longer supported. Created THREE.LineSegments instead."),new U(a,b);A.call(this);this.type="Line";this.geometry=void 0!==a?a:new D;this.material=void 0!==b?b:new Z({color:16777215*Math.random()})}function U(a,b){qa.call(this,a,b);this.type="LineSegments"}function td(a,b){qa.call(this,a,b);this.type="LineLoop"}function Ga(a){L.call(this);this.type="PointsMaterial";this.color=new G(16777215);
|
|
|
-this.map=null;this.size=1;this.sizeAttenuation=!0;this.lights=!1;this.setValues(a)}function Pb(a,b){A.call(this);this.type="Points";this.geometry=void 0!==a?a:new D;this.material=void 0!==b?b:new Ga({color:16777215*Math.random()})}function ud(){A.call(this);this.type="Group"}function $d(a,b,c,d,e,f,g,h,l){aa.call(this,a,b,c,d,e,f,g,h,l);this.generateMipmaps=!1;this.frameRate=30}function Qb(a,b,c,d,e,f,g,h,l,m,v,n){aa.call(this,null,f,g,h,l,m,d,e,v,n);this.image={width:b,height:c};this.mipmaps=a;this.generateMipmaps=
|
|
|
+this.map=null;this.size=1;this.sizeAttenuation=!0;this.lights=!1;this.setValues(a)}function Pb(a,b){A.call(this);this.type="Points";this.geometry=void 0!==a?a:new D;this.material=void 0!==b?b:new Ga({color:16777215*Math.random()})}function ud(){A.call(this);this.type="Group"}function $d(a,b,c,d,e,f,g,h,l){aa.call(this,a,b,c,d,e,f,g,h,l);this.generateMipmaps=!1}function Qb(a,b,c,d,e,f,g,h,l,m,v,n){aa.call(this,null,f,g,h,l,m,d,e,v,n);this.image={width:b,height:c};this.mipmaps=a;this.generateMipmaps=
|
|
|
this.flipY=!1}function Dc(a,b,c,d,e,f,g,h,l,m){m=void 0!==m?m:1026;if(1026!==m&&1027!==m)throw Error("DepthTexture format must be either THREE.DepthFormat or THREE.DepthStencilFormat");void 0===c&&1026===m&&(c=1012);void 0===c&&1027===m&&(c=1020);aa.call(this,null,d,e,f,g,h,m,c,l);this.image={width:a,height:b};this.magFilter=void 0!==g?g:1003;this.minFilter=void 0!==h?h:1003;this.generateMipmaps=this.flipY=!1}function Rb(a){D.call(this);this.type="WireframeGeometry";var b=[],c,d,e,f=[0,0],g={},h=
|
|
|
["a","b","c"];if(a&&a.isGeometry){var l=a.faces;var m=0;for(d=l.length;m<d;m++){var v=l[m];for(c=0;3>c;c++){var n=v[h[c]];var k=v[h[(c+1)%3]];f[0]=Math.min(n,k);f[1]=Math.max(n,k);n=f[0]+","+f[1];void 0===g[n]&&(g[n]={index1:f[0],index2:f[1]})}}for(n in g)m=g[n],h=a.vertices[m.index1],b.push(h.x,h.y,h.z),h=a.vertices[m.index2],b.push(h.x,h.y,h.z)}else if(a&&a.isBufferGeometry)if(h=new p,null!==a.index){l=a.attributes.position;v=a.index;var r=a.groups;0===r.length&&(r=[{start:0,count:v.count,materialIndex:0}]);
|
|
|
a=0;for(e=r.length;a<e;++a)for(m=r[a],c=m.start,d=m.count,m=c,d=c+d;m<d;m+=3)for(c=0;3>c;c++)n=v.getX(m+c),k=v.getX(m+(c+1)%3),f[0]=Math.min(n,k),f[1]=Math.max(n,k),n=f[0]+","+f[1],void 0===g[n]&&(g[n]={index1:f[0],index2:f[1]});for(n in g)m=g[n],h.fromBufferAttribute(l,m.index1),b.push(h.x,h.y,h.z),h.fromBufferAttribute(l,m.index2),b.push(h.x,h.y,h.z)}else for(l=a.attributes.position,m=0,d=l.count/3;m<d;m++)for(c=0;3>c;c++)g=3*m+c,h.fromBufferAttribute(l,g),b.push(h.x,h.y,h.z),g=3*m+(c+1)%3,h.fromBufferAttribute(l,
|
|
@@ -605,58 +605,58 @@ face:null,faceIndex:null,object:this}))}}}(),clone:function(){return(new this.co
|
|
|
c.addAttribute("lineDistance",new THREE.Float32BufferAttribute(e,1))}else console.warn("THREE.LineSegments.computeLineDistances(): Computation only possible with non-indexed BufferGeometry.");else if(c.isGeometry)for(d=c.vertices,e=c.lineDistances,f=0,g=d.length;f<g;f+=2)a.copy(d[f]),b.copy(d[f+1]),e[f]=0===f?0:e[f-1],e[f+1]=e[f]+a.distanceTo(b);return this}}()});td.prototype=Object.assign(Object.create(qa.prototype),{constructor:td,isLineLoop:!0});Ga.prototype=Object.create(L.prototype);Ga.prototype.constructor=
|
|
|
Ga;Ga.prototype.isPointsMaterial=!0;Ga.prototype.copy=function(a){L.prototype.copy.call(this,a);this.color.copy(a.color);this.map=a.map;this.size=a.size;this.sizeAttenuation=a.sizeAttenuation;return this};Pb.prototype=Object.assign(Object.create(A.prototype),{constructor:Pb,isPoints:!0,raycast:function(){var a=new Q,b=new ob,c=new Ba;return function(d,e){function f(a,c){var f=b.distanceSqToPoint(a);if(f<k){a=b.closestPointToPoint(a);a.applyMatrix4(l);var h=d.ray.origin.distanceTo(a);h<d.near||h>d.far||
|
|
|
e.push({distance:h,distanceToRay:Math.sqrt(f),point:a.clone(),index:c,face:null,object:g})}}var g=this,h=this.geometry,l=this.matrixWorld,m=d.params.Points.threshold;null===h.boundingSphere&&h.computeBoundingSphere();c.copy(h.boundingSphere);c.applyMatrix4(l);c.radius+=m;if(!1!==d.ray.intersectsSphere(c)){a.getInverse(l);b.copy(d.ray).applyMatrix4(a);m/=(this.scale.x+this.scale.y+this.scale.z)/3;var k=m*m;m=new p;if(h.isBufferGeometry){var n=h.index;h=h.attributes.position.array;if(null!==n){var u=
|
|
|
-n.array;n=0;for(var r=u.length;n<r;n++){var q=u[n];m.fromArray(h,3*q);f(m,q)}}else for(n=0,u=h.length/3;n<u;n++)m.fromArray(h,3*n),f(m,n)}else for(m=h.vertices,n=0,u=m.length;n<u;n++)f(m[n],n)}}}(),clone:function(){return(new this.constructor(this.geometry,this.material)).copy(this)}});ud.prototype=Object.assign(Object.create(A.prototype),{constructor:ud,isGroup:!0});$d.prototype=Object.assign(Object.create(aa.prototype),{constructor:$d,isVideoTexture:!0,update:function(){var a=0;return function(){var b=
|
|
|
-this.image;b.readyState>=b.HAVE_CURRENT_DATA&&(b=performance.now(),a+1E3/this.frameRate<=b&&(this.needsUpdate=!0,a=b))}}()});Qb.prototype=Object.create(aa.prototype);Qb.prototype.constructor=Qb;Qb.prototype.isCompressedTexture=!0;Dc.prototype=Object.create(aa.prototype);Dc.prototype.constructor=Dc;Dc.prototype.isDepthTexture=!0;Rb.prototype=Object.create(D.prototype);Rb.prototype.constructor=Rb;Ec.prototype=Object.create(M.prototype);Ec.prototype.constructor=Ec;Sb.prototype=Object.create(D.prototype);
|
|
|
-Sb.prototype.constructor=Sb;Fc.prototype=Object.create(M.prototype);Fc.prototype.constructor=Fc;va.prototype=Object.create(D.prototype);va.prototype.constructor=va;Gc.prototype=Object.create(M.prototype);Gc.prototype.constructor=Gc;Tb.prototype=Object.create(va.prototype);Tb.prototype.constructor=Tb;Hc.prototype=Object.create(M.prototype);Hc.prototype.constructor=Hc;qb.prototype=Object.create(va.prototype);qb.prototype.constructor=qb;Ic.prototype=Object.create(M.prototype);Ic.prototype.constructor=
|
|
|
-Ic;Ub.prototype=Object.create(va.prototype);Ub.prototype.constructor=Ub;Jc.prototype=Object.create(M.prototype);Jc.prototype.constructor=Jc;Vb.prototype=Object.create(va.prototype);Vb.prototype.constructor=Vb;Kc.prototype=Object.create(M.prototype);Kc.prototype.constructor=Kc;Wb.prototype=Object.create(D.prototype);Wb.prototype.constructor=Wb;Lc.prototype=Object.create(M.prototype);Lc.prototype.constructor=Lc;Xb.prototype=Object.create(D.prototype);Xb.prototype.constructor=Xb;Mc.prototype=Object.create(M.prototype);
|
|
|
-Mc.prototype.constructor=Mc;Yb.prototype=Object.create(D.prototype);Yb.prototype.constructor=Yb;var Lg={triangulate:function(a,b,c){c=c||2;var d=b&&b.length,e=d?b[0]*c:a.length,f=Xe(a,0,e,c,!0),g=[];if(!f)return g;var h;if(d){var l=c;d=[];var m;var k=0;for(m=b.length;k<m;k++){var n=b[k]*l;var p=k<m-1?b[k+1]*l:a.length;n=Xe(a,n,p,l,!1);n===n.next&&(n.steiner=!0);d.push(Jg(n))}d.sort(Hg);for(k=0;k<d.length;k++){b=d[k];l=f;if(l=Ig(b,l))b=$e(l,b),Oc(b,b.next);f=Oc(f,f.next)}}if(a.length>80*c){var r=h=
|
|
|
-a[0];var q=d=a[1];for(l=c;l<e;l+=c)k=a[l],b=a[l+1],k<r&&(r=k),b<q&&(q=b),k>h&&(h=k),b>d&&(d=b);h=Math.max(h-r,d-q);h=0!==h?1/h:0}Pc(f,g,c,r,q,h);return g}},Xa={area:function(a){for(var b=a.length,c=0,d=b-1,e=0;e<b;d=e++)c+=a[d].x*a[e].y-a[e].x*a[d].y;return.5*c},isClockWise:function(a){return 0>Xa.area(a)},triangulateShape:function(a,b){var c=[],d=[],e=[];af(a);bf(c,a);var f=a.length;b.forEach(af);for(a=0;a<b.length;a++)d.push(f),f+=b[a].length,bf(c,b[a]);b=Lg.triangulate(c,d);for(a=0;a<b.length;a+=
|
|
|
-3)e.push(b.slice(a,a+3));return e}};gb.prototype=Object.create(M.prototype);gb.prototype.constructor=gb;Ha.prototype=Object.create(D.prototype);Ha.prototype.constructor=Ha;Ha.prototype.getArrays=function(){var a=this.getAttribute("position");a=a?Array.prototype.slice.call(a.array):[];var b=this.getAttribute("uv");b=b?Array.prototype.slice.call(b.array):[];var c=this.index;c=c?Array.prototype.slice.call(c.array):[];return{position:a,uv:b,index:c}};Ha.prototype.addShapeList=function(a,b){var c=a.length;
|
|
|
-b.arrays=this.getArrays();for(var d=0;d<c;d++)this.addShape(a[d],b);this.setIndex(b.arrays.index);this.addAttribute("position",new B(b.arrays.position,3));this.addAttribute("uv",new B(b.arrays.uv,2))};Ha.prototype.addShape=function(a,b){function c(a,b,c){b||console.error("THREE.ExtrudeGeometry: vec does not exist");return b.clone().multiplyScalar(c).add(a)}function d(a,b,c){var d=a.x-b.x;var e=a.y-b.y;var f=c.x-a.x;var g=c.y-a.y,h=d*d+e*e;if(Math.abs(d*g-e*f)>Number.EPSILON){var l=Math.sqrt(h),m=
|
|
|
-Math.sqrt(f*f+g*g);h=b.x-e/l;b=b.y+d/l;g=((c.x-g/m-h)*g-(c.y+f/m-b)*f)/(d*g-e*f);f=h+d*g-a.x;d=b+e*g-a.y;e=f*f+d*d;if(2>=e)return new C(f,d);e=Math.sqrt(e/2)}else a=!1,d>Number.EPSILON?f>Number.EPSILON&&(a=!0):d<-Number.EPSILON?f<-Number.EPSILON&&(a=!0):Math.sign(e)===Math.sign(g)&&(a=!0),a?(f=-e,e=Math.sqrt(h)):(f=d,d=e,e=Math.sqrt(h/2));return new C(f/e,d/e)}function e(a,b){for(I=a.length;0<=--I;){var c=I;var d=I-1;0>d&&(d=a.length-1);var e,f=z+2*w;for(e=0;e<f;e++){var g=aa*e,m=aa*(e+1),n=b+d+g,
|
|
|
-p=b+d+m;m=b+c+m;h(b+c+g);h(n);h(m);h(n);h(p);h(m);g=k.length/3;g=G.generateSideWallUV(S,k,g-6,g-3,g-2,g-1);l(g[0]);l(g[1]);l(g[3]);l(g[1]);l(g[2]);l(g[3])}}}function f(a,b,c){r.push(a);r.push(b);r.push(c)}function g(a,b,c){h(a);h(b);h(c);a=k.length/3;a=G.generateTopUV(S,k,a-3,a-2,a-1);l(a[0]);l(a[1]);l(a[2])}function h(a){n.push(k.length/3);k.push(r[3*a]);k.push(r[3*a+1]);k.push(r[3*a+2])}function l(a){u.push(a.x);u.push(a.y)}var m=b.arrays?b.arrays:this.getArrays(),k=m.position,n=m.index,u=m.uv,
|
|
|
-r=[];m=void 0!==b.amount?b.amount:100;var q=void 0!==b.bevelThickness?b.bevelThickness:6,t=void 0!==b.bevelSize?b.bevelSize:q-2,w=void 0!==b.bevelSegments?b.bevelSegments:3,x=void 0!==b.bevelEnabled?b.bevelEnabled:!0,y=void 0!==b.curveSegments?b.curveSegments:12,z=void 0!==b.steps?b.steps:1,A=b.extrudePath,D=!1,G=void 0!==b.UVGenerator?b.UVGenerator:gb.WorldUVGenerator;if(A){var H=A.getSpacedPoints(z);D=!0;x=!1;var O=void 0!==b.frames?b.frames:A.computeFrenetFrames(z,!1);var K=new p;var M=new p;var N=
|
|
|
-new p}x||(t=q=w=0);var L,S=this;y=a.extractPoints(y);a=y.shape;var Q=y.holes;if(!Xa.isClockWise(a)){a=a.reverse();var T=0;for(L=Q.length;T<L;T++){var R=Q[T];Xa.isClockWise(R)&&(Q[T]=R.reverse())}}var Z=Xa.triangulateShape(a,Q),W=a;T=0;for(L=Q.length;T<L;T++)R=Q[T],a=a.concat(R);var U,aa=a.length,X,da=Z.length;y=[];var I=0;var V=W.length;var P=V-1;for(U=I+1;I<V;I++,P++,U++)P===V&&(P=0),U===V&&(U=0),y[I]=d(W[I],W[P],W[U]);A=[];var ea=y.concat();T=0;for(L=Q.length;T<L;T++){R=Q[T];var ca=[];I=0;V=R.length;
|
|
|
-P=V-1;for(U=I+1;I<V;I++,P++,U++)P===V&&(P=0),U===V&&(U=0),ca[I]=d(R[I],R[P],R[U]);A.push(ca);ea=ea.concat(ca)}for(P=0;P<w;P++){V=P/w;var fa=q*Math.cos(V*Math.PI/2);U=t*Math.sin(V*Math.PI/2);I=0;for(V=W.length;I<V;I++){var ia=c(W[I],y[I],U);f(ia.x,ia.y,-fa)}T=0;for(L=Q.length;T<L;T++)for(R=Q[T],ca=A[T],I=0,V=R.length;I<V;I++)ia=c(R[I],ca[I],U),f(ia.x,ia.y,-fa)}U=t;for(I=0;I<aa;I++)ia=x?c(a[I],ea[I],U):a[I],D?(M.copy(O.normals[0]).multiplyScalar(ia.x),K.copy(O.binormals[0]).multiplyScalar(ia.y),N.copy(H[0]).add(M).add(K),
|
|
|
-f(N.x,N.y,N.z)):f(ia.x,ia.y,0);for(V=1;V<=z;V++)for(I=0;I<aa;I++)ia=x?c(a[I],ea[I],U):a[I],D?(M.copy(O.normals[V]).multiplyScalar(ia.x),K.copy(O.binormals[V]).multiplyScalar(ia.y),N.copy(H[V]).add(M).add(K),f(N.x,N.y,N.z)):f(ia.x,ia.y,m/z*V);for(P=w-1;0<=P;P--){V=P/w;fa=q*Math.cos(V*Math.PI/2);U=t*Math.sin(V*Math.PI/2);I=0;for(V=W.length;I<V;I++)ia=c(W[I],y[I],U),f(ia.x,ia.y,m+fa);T=0;for(L=Q.length;T<L;T++)for(R=Q[T],ca=A[T],I=0,V=R.length;I<V;I++)ia=c(R[I],ca[I],U),D?f(ia.x,ia.y+H[z-1].y,H[z-1].x+
|
|
|
-fa):f(ia.x,ia.y,m+fa)}(function(){var a=k.length/3;if(x){var c=0*aa;for(I=0;I<da;I++)X=Z[I],g(X[2]+c,X[1]+c,X[0]+c);c=aa*(z+2*w);for(I=0;I<da;I++)X=Z[I],g(X[0]+c,X[1]+c,X[2]+c)}else{for(I=0;I<da;I++)X=Z[I],g(X[2],X[1],X[0]);for(I=0;I<da;I++)X=Z[I],g(X[0]+aa*z,X[1]+aa*z,X[2]+aa*z)}S.addGroup(a,k.length/3-a,void 0!==b.material?b.material:0)})();(function(){var a=k.length/3,c=0;e(W,c);c+=W.length;T=0;for(L=Q.length;T<L;T++)R=Q[T],e(R,c),c+=R.length;S.addGroup(a,k.length/3-a,void 0!==b.extrudeMaterial?
|
|
|
-b.extrudeMaterial:1)})();b.arrays||(this.setIndex(n),this.addAttribute("position",new B(k,3)),this.addAttribute("uv",new B(u,2)))};gb.WorldUVGenerator={generateTopUV:function(a,b,c,d,e){a=b[3*d];d=b[3*d+1];var f=b[3*e];e=b[3*e+1];return[new C(b[3*c],b[3*c+1]),new C(a,d),new C(f,e)]},generateSideWallUV:function(a,b,c,d,e,f){a=b[3*c];var g=b[3*c+1];c=b[3*c+2];var h=b[3*d],l=b[3*d+1];d=b[3*d+2];var m=b[3*e],k=b[3*e+1];e=b[3*e+2];var n=b[3*f],p=b[3*f+1];b=b[3*f+2];return.01>Math.abs(g-l)?[new C(a,1-c),
|
|
|
-new C(h,1-d),new C(m,1-e),new C(n,1-b)]:[new C(g,1-c),new C(l,1-d),new C(k,1-e),new C(p,1-b)]}};Rc.prototype=Object.create(M.prototype);Rc.prototype.constructor=Rc;Zb.prototype=Object.create(Ha.prototype);Zb.prototype.constructor=Zb;Sc.prototype=Object.create(M.prototype);Sc.prototype.constructor=Sc;sb.prototype=Object.create(D.prototype);sb.prototype.constructor=sb;Tc.prototype=Object.create(M.prototype);Tc.prototype.constructor=Tc;$b.prototype=Object.create(D.prototype);$b.prototype.constructor=
|
|
|
-$b;Uc.prototype=Object.create(M.prototype);Uc.prototype.constructor=Uc;ac.prototype=Object.create(D.prototype);ac.prototype.constructor=ac;tb.prototype=Object.create(M.prototype);tb.prototype.constructor=tb;tb.prototype.toJSON=function(){var a=M.prototype.toJSON.call(this);return cf(this.parameters.shapes,a)};ub.prototype=Object.create(D.prototype);ub.prototype.constructor=ub;ub.prototype.toJSON=function(){var a=D.prototype.toJSON.call(this);return cf(this.parameters.shapes,a)};bc.prototype=Object.create(D.prototype);
|
|
|
-bc.prototype.constructor=bc;vb.prototype=Object.create(M.prototype);vb.prototype.constructor=vb;Ya.prototype=Object.create(D.prototype);Ya.prototype.constructor=Ya;Vc.prototype=Object.create(vb.prototype);Vc.prototype.constructor=Vc;Wc.prototype=Object.create(Ya.prototype);Wc.prototype.constructor=Wc;Xc.prototype=Object.create(M.prototype);Xc.prototype.constructor=Xc;cc.prototype=Object.create(D.prototype);cc.prototype.constructor=cc;var oa=Object.freeze({WireframeGeometry:Rb,ParametricGeometry:Ec,
|
|
|
-ParametricBufferGeometry:Sb,TetrahedronGeometry:Gc,TetrahedronBufferGeometry:Tb,OctahedronGeometry:Hc,OctahedronBufferGeometry:qb,IcosahedronGeometry:Ic,IcosahedronBufferGeometry:Ub,DodecahedronGeometry:Jc,DodecahedronBufferGeometry:Vb,PolyhedronGeometry:Fc,PolyhedronBufferGeometry:va,TubeGeometry:Kc,TubeBufferGeometry:Wb,TorusKnotGeometry:Lc,TorusKnotBufferGeometry:Xb,TorusGeometry:Mc,TorusBufferGeometry:Yb,TextGeometry:Rc,TextBufferGeometry:Zb,SphereGeometry:Sc,SphereBufferGeometry:sb,RingGeometry:Tc,
|
|
|
-RingBufferGeometry:$b,PlaneGeometry:yc,PlaneBufferGeometry:nb,LatheGeometry:Uc,LatheBufferGeometry:ac,ShapeGeometry:tb,ShapeBufferGeometry:ub,ExtrudeGeometry:gb,ExtrudeBufferGeometry:Ha,EdgesGeometry:bc,ConeGeometry:Vc,ConeBufferGeometry:Wc,CylinderGeometry:vb,CylinderBufferGeometry:Ya,CircleGeometry:Xc,CircleBufferGeometry:cc,BoxGeometry:Kb,BoxBufferGeometry:mb});dc.prototype=Object.create(L.prototype);dc.prototype.constructor=dc;dc.prototype.isShadowMaterial=!0;ec.prototype=Object.create(Ca.prototype);
|
|
|
-ec.prototype.constructor=ec;ec.prototype.isRawShaderMaterial=!0;Ra.prototype=Object.create(L.prototype);Ra.prototype.constructor=Ra;Ra.prototype.isMeshStandardMaterial=!0;Ra.prototype.copy=function(a){L.prototype.copy.call(this,a);this.defines={STANDARD:""};this.color.copy(a.color);this.roughness=a.roughness;this.metalness=a.metalness;this.map=a.map;this.lightMap=a.lightMap;this.lightMapIntensity=a.lightMapIntensity;this.aoMap=a.aoMap;this.aoMapIntensity=a.aoMapIntensity;this.emissive.copy(a.emissive);
|
|
|
-this.emissiveMap=a.emissiveMap;this.emissiveIntensity=a.emissiveIntensity;this.bumpMap=a.bumpMap;this.bumpScale=a.bumpScale;this.normalMap=a.normalMap;this.normalScale.copy(a.normalScale);this.displacementMap=a.displacementMap;this.displacementScale=a.displacementScale;this.displacementBias=a.displacementBias;this.roughnessMap=a.roughnessMap;this.metalnessMap=a.metalnessMap;this.alphaMap=a.alphaMap;this.envMap=a.envMap;this.envMapIntensity=a.envMapIntensity;this.refractionRatio=a.refractionRatio;
|
|
|
-this.wireframe=a.wireframe;this.wireframeLinewidth=a.wireframeLinewidth;this.wireframeLinecap=a.wireframeLinecap;this.wireframeLinejoin=a.wireframeLinejoin;this.skinning=a.skinning;this.morphTargets=a.morphTargets;this.morphNormals=a.morphNormals;return this};wb.prototype=Object.create(Ra.prototype);wb.prototype.constructor=wb;wb.prototype.isMeshPhysicalMaterial=!0;wb.prototype.copy=function(a){Ra.prototype.copy.call(this,a);this.defines={PHYSICAL:""};this.reflectivity=a.reflectivity;this.clearCoat=
|
|
|
-a.clearCoat;this.clearCoatRoughness=a.clearCoatRoughness;return this};Ia.prototype=Object.create(L.prototype);Ia.prototype.constructor=Ia;Ia.prototype.isMeshPhongMaterial=!0;Ia.prototype.copy=function(a){L.prototype.copy.call(this,a);this.color.copy(a.color);this.specular.copy(a.specular);this.shininess=a.shininess;this.map=a.map;this.lightMap=a.lightMap;this.lightMapIntensity=a.lightMapIntensity;this.aoMap=a.aoMap;this.aoMapIntensity=a.aoMapIntensity;this.emissive.copy(a.emissive);this.emissiveMap=
|
|
|
-a.emissiveMap;this.emissiveIntensity=a.emissiveIntensity;this.bumpMap=a.bumpMap;this.bumpScale=a.bumpScale;this.normalMap=a.normalMap;this.normalScale.copy(a.normalScale);this.displacementMap=a.displacementMap;this.displacementScale=a.displacementScale;this.displacementBias=a.displacementBias;this.specularMap=a.specularMap;this.alphaMap=a.alphaMap;this.envMap=a.envMap;this.combine=a.combine;this.reflectivity=a.reflectivity;this.refractionRatio=a.refractionRatio;this.wireframe=a.wireframe;this.wireframeLinewidth=
|
|
|
-a.wireframeLinewidth;this.wireframeLinecap=a.wireframeLinecap;this.wireframeLinejoin=a.wireframeLinejoin;this.skinning=a.skinning;this.morphTargets=a.morphTargets;this.morphNormals=a.morphNormals;return this};xb.prototype=Object.create(Ia.prototype);xb.prototype.constructor=xb;xb.prototype.isMeshToonMaterial=!0;xb.prototype.copy=function(a){Ia.prototype.copy.call(this,a);this.gradientMap=a.gradientMap;return this};yb.prototype=Object.create(L.prototype);yb.prototype.constructor=yb;yb.prototype.isMeshNormalMaterial=
|
|
|
-!0;yb.prototype.copy=function(a){L.prototype.copy.call(this,a);this.bumpMap=a.bumpMap;this.bumpScale=a.bumpScale;this.normalMap=a.normalMap;this.normalScale.copy(a.normalScale);this.displacementMap=a.displacementMap;this.displacementScale=a.displacementScale;this.displacementBias=a.displacementBias;this.wireframe=a.wireframe;this.wireframeLinewidth=a.wireframeLinewidth;this.skinning=a.skinning;this.morphTargets=a.morphTargets;this.morphNormals=a.morphNormals;return this};zb.prototype=Object.create(L.prototype);
|
|
|
-zb.prototype.constructor=zb;zb.prototype.isMeshLambertMaterial=!0;zb.prototype.copy=function(a){L.prototype.copy.call(this,a);this.color.copy(a.color);this.map=a.map;this.lightMap=a.lightMap;this.lightMapIntensity=a.lightMapIntensity;this.aoMap=a.aoMap;this.aoMapIntensity=a.aoMapIntensity;this.emissive.copy(a.emissive);this.emissiveMap=a.emissiveMap;this.emissiveIntensity=a.emissiveIntensity;this.specularMap=a.specularMap;this.alphaMap=a.alphaMap;this.envMap=a.envMap;this.combine=a.combine;this.reflectivity=
|
|
|
-a.reflectivity;this.refractionRatio=a.refractionRatio;this.wireframe=a.wireframe;this.wireframeLinewidth=a.wireframeLinewidth;this.wireframeLinecap=a.wireframeLinecap;this.wireframeLinejoin=a.wireframeLinejoin;this.skinning=a.skinning;this.morphTargets=a.morphTargets;this.morphNormals=a.morphNormals;return this};Ab.prototype=Object.create(Z.prototype);Ab.prototype.constructor=Ab;Ab.prototype.isLineDashedMaterial=!0;Ab.prototype.copy=function(a){Z.prototype.copy.call(this,a);this.scale=a.scale;this.dashSize=
|
|
|
-a.dashSize;this.gapSize=a.gapSize;return this};var Mg=Object.freeze({ShadowMaterial:dc,SpriteMaterial:fb,RawShaderMaterial:ec,ShaderMaterial:Ca,PointsMaterial:Ga,MeshPhysicalMaterial:wb,MeshStandardMaterial:Ra,MeshPhongMaterial:Ia,MeshToonMaterial:xb,MeshNormalMaterial:yb,MeshLambertMaterial:zb,MeshDepthMaterial:cb,MeshDistanceMaterial:db,MeshBasicMaterial:ya,LineDashedMaterial:Ab,LineBasicMaterial:Z,Material:L}),Eb={enabled:!1,files:{},add:function(a,b){!1!==this.enabled&&(this.files[a]=b)},get:function(a){if(!1!==
|
|
|
-this.enabled)return this.files[a]},remove:function(a){delete this.files[a]},clear:function(){this.files={}}},sa=new ce,$a={};Object.assign(Ja.prototype,{load:function(a,b,c,d){void 0===a&&(a="");void 0!==this.path&&(a=this.path+a);a=this.manager.resolveURL(a);var e=this,f=Eb.get(a);if(void 0!==f)return e.manager.itemStart(a),setTimeout(function(){b&&b(f);e.manager.itemEnd(a)},0),f;if(void 0!==$a[a])$a[a].push({onLoad:b,onProgress:c,onError:d});else{var g=a.match(/^data:(.*?)(;base64)?,(.*)$/);if(g){c=
|
|
|
-g[1];var h=!!g[2];g=g[3];g=window.decodeURIComponent(g);h&&(g=window.atob(g));try{var l=(this.responseType||"").toLowerCase();switch(l){case "arraybuffer":case "blob":var m=new Uint8Array(g.length);for(h=0;h<g.length;h++)m[h]=g.charCodeAt(h);var k="blob"===l?new Blob([m.buffer],{type:c}):m.buffer;break;case "document":k=(new DOMParser).parseFromString(g,c);break;case "json":k=JSON.parse(g);break;default:k=g}window.setTimeout(function(){b&&b(k);e.manager.itemEnd(a)},0)}catch(u){window.setTimeout(function(){d&&
|
|
|
-d(u);e.manager.itemEnd(a);e.manager.itemError(a)},0)}}else{$a[a]=[];$a[a].push({onLoad:b,onProgress:c,onError:d});var n=new XMLHttpRequest;n.open("GET",a,!0);n.addEventListener("load",function(b){var c=this.response;Eb.add(a,c);var d=$a[a];delete $a[a];if(200===this.status){for(var f=0,g=d.length;f<g;f++){var h=d[f];if(h.onLoad)h.onLoad(c)}e.manager.itemEnd(a)}else if(0===this.status){console.warn("THREE.FileLoader: HTTP Status 0 received.");f=0;for(g=d.length;f<g;f++)if(h=d[f],h.onLoad)h.onLoad(c);
|
|
|
-e.manager.itemEnd(a)}else{f=0;for(g=d.length;f<g;f++)if(h=d[f],h.onError)h.onError(b);e.manager.itemEnd(a);e.manager.itemError(a)}},!1);n.addEventListener("progress",function(b){for(var c=$a[a],d=0,e=c.length;d<e;d++){var f=c[d];if(f.onProgress)f.onProgress(b)}},!1);n.addEventListener("error",function(b){var c=$a[a];delete $a[a];for(var d=0,f=c.length;d<f;d++){var g=c[d];if(g.onError)g.onError(b)}e.manager.itemEnd(a);e.manager.itemError(a)},!1);void 0!==this.responseType&&(n.responseType=this.responseType);
|
|
|
-void 0!==this.withCredentials&&(n.withCredentials=this.withCredentials);n.overrideMimeType&&n.overrideMimeType(void 0!==this.mimeType?this.mimeType:"text/plain");for(h in this.requestHeader)n.setRequestHeader(h,this.requestHeader[h]);n.send(null)}e.manager.itemStart(a);return n}},setPath:function(a){this.path=a;return this},setResponseType:function(a){this.responseType=a;return this},setWithCredentials:function(a){this.withCredentials=a;return this},setMimeType:function(a){this.mimeType=a;return this},
|
|
|
-setRequestHeader:function(a){this.requestHeader=a;return this}});Object.assign(df.prototype,{load:function(a,b,c,d){function e(e){l.load(a[e],function(a){a=f._parser(a,!0);g[e]={width:a.width,height:a.height,format:a.format,mipmaps:a.mipmaps};m+=1;6===m&&(1===a.mipmapCount&&(h.minFilter=1006),h.format=a.format,h.needsUpdate=!0,b&&b(h))},c,d)}var f=this,g=[],h=new Qb;h.image=g;var l=new Ja(this.manager);l.setPath(this.path);l.setResponseType("arraybuffer");if(Array.isArray(a))for(var m=0,k=0,n=a.length;k<
|
|
|
-n;++k)e(k);else l.load(a,function(a){a=f._parser(a,!0);if(a.isCubemap)for(var c=a.mipmaps.length/a.mipmapCount,d=0;d<c;d++){g[d]={mipmaps:[]};for(var e=0;e<a.mipmapCount;e++)g[d].mipmaps.push(a.mipmaps[d*a.mipmapCount+e]),g[d].format=a.format,g[d].width=a.width,g[d].height=a.height}else h.image.width=a.width,h.image.height=a.height,h.mipmaps=a.mipmaps;1===a.mipmapCount&&(h.minFilter=1006);h.format=a.format;h.needsUpdate=!0;b&&b(h)},c,d);return h},setPath:function(a){this.path=a;return this}});Object.assign(de.prototype,
|
|
|
-{load:function(a,b,c,d){var e=this,f=new jb,g=new Ja(this.manager);g.setResponseType("arraybuffer");g.load(a,function(a){if(a=e._parser(a))void 0!==a.image?f.image=a.image:void 0!==a.data&&(f.image.width=a.width,f.image.height=a.height,f.image.data=a.data),f.wrapS=void 0!==a.wrapS?a.wrapS:1001,f.wrapT=void 0!==a.wrapT?a.wrapT:1001,f.magFilter=void 0!==a.magFilter?a.magFilter:1006,f.minFilter=void 0!==a.minFilter?a.minFilter:1008,f.anisotropy=void 0!==a.anisotropy?a.anisotropy:1,void 0!==a.format&&
|
|
|
-(f.format=a.format),void 0!==a.type&&(f.type=a.type),void 0!==a.mipmaps&&(f.mipmaps=a.mipmaps),1===a.mipmapCount&&(f.minFilter=1006),f.needsUpdate=!0,b&&b(f,a)},c,d);return f}});Object.assign(Yc.prototype,{crossOrigin:"Anonymous",load:function(a,b,c,d){void 0===a&&(a="");void 0!==this.path&&(a=this.path+a);a=this.manager.resolveURL(a);var e=this,f=Eb.get(a);if(void 0!==f)return e.manager.itemStart(a),setTimeout(function(){b&&b(f);e.manager.itemEnd(a)},0),f;c=document.createElementNS("http://www.w3.org/1999/xhtml",
|
|
|
-"img");c.addEventListener("load",function(){Eb.add(a,this);b&&b(this);e.manager.itemEnd(a)},!1);c.addEventListener("error",function(b){d&&d(b);e.manager.itemEnd(a);e.manager.itemError(a)},!1);"data:"!==a.substr(0,5)&&void 0!==this.crossOrigin&&(c.crossOrigin=this.crossOrigin);e.manager.itemStart(a);c.src=a;return c},setCrossOrigin:function(a){this.crossOrigin=a;return this},setPath:function(a){this.path=a;return this}});Object.assign(ee.prototype,{crossOrigin:"Anonymous",load:function(a,b,c,d){function e(c){g.load(a[c],
|
|
|
-function(a){f.images[c]=a;h++;6===h&&(f.needsUpdate=!0,b&&b(f))},void 0,d)}var f=new ab,g=new Yc(this.manager);g.setCrossOrigin(this.crossOrigin);g.setPath(this.path);var h=0;for(c=0;c<a.length;++c)e(c);return f},setCrossOrigin:function(a){this.crossOrigin=a;return this},setPath:function(a){this.path=a;return this}});Object.assign(wd.prototype,{crossOrigin:"Anonymous",load:function(a,b,c,d){var e=new aa,f=new Yc(this.manager);f.setCrossOrigin(this.crossOrigin);f.setPath(this.path);f.load(a,function(c){e.image=
|
|
|
-c;c=0<a.search(/\.(jpg|jpeg)$/)||0===a.search(/^data:image\/jpeg/);e.format=c?1022:1023;e.needsUpdate=!0;void 0!==b&&b(e)},c,d);return e},setCrossOrigin:function(a){this.crossOrigin=a;return this},setPath:function(a){this.path=a;return this}});Object.assign(K.prototype,{getPoint:function(){console.warn("THREE.Curve: .getPoint() not implemented.");return null},getPointAt:function(a,b){a=this.getUtoTmapping(a);return this.getPoint(a,b)},getPoints:function(a){void 0===a&&(a=5);for(var b=[],c=0;c<=a;c++)b.push(this.getPoint(c/
|
|
|
-a));return b},getSpacedPoints:function(a){void 0===a&&(a=5);for(var b=[],c=0;c<=a;c++)b.push(this.getPointAt(c/a));return b},getLength:function(){var a=this.getLengths();return a[a.length-1]},getLengths:function(a){void 0===a&&(a=this.arcLengthDivisions);if(this.cacheArcLengths&&this.cacheArcLengths.length===a+1&&!this.needsUpdate)return this.cacheArcLengths;this.needsUpdate=!1;var b=[],c=this.getPoint(0),d,e=0;b.push(0);for(d=1;d<=a;d++){var f=this.getPoint(d/a);e+=f.distanceTo(c);b.push(e);c=f}return this.cacheArcLengths=
|
|
|
-b},updateArcLengths:function(){this.needsUpdate=!0;this.getLengths()},getUtoTmapping:function(a,b){var c=this.getLengths(),d=c.length;b=b?b:a*c[d-1];for(var e=0,f=d-1,g;e<=f;)if(a=Math.floor(e+(f-e)/2),g=c[a]-b,0>g)e=a+1;else if(0<g)f=a-1;else{f=a;break}a=f;if(c[a]===b)return a/(d-1);e=c[a];return(a+(b-e)/(c[a+1]-e))/(d-1)},getTangent:function(a){var b=a-1E-4;a+=1E-4;0>b&&(b=0);1<a&&(a=1);b=this.getPoint(b);return this.getPoint(a).clone().sub(b).normalize()},getTangentAt:function(a){a=this.getUtoTmapping(a);
|
|
|
-return this.getTangent(a)},computeFrenetFrames:function(a,b){var c=new p,d=[],e=[],f=[],g=new p,h=new Q,l;for(l=0;l<=a;l++){var m=l/a;d[l]=this.getTangentAt(m);d[l].normalize()}e[0]=new p;f[0]=new p;l=Number.MAX_VALUE;m=Math.abs(d[0].x);var k=Math.abs(d[0].y),n=Math.abs(d[0].z);m<=l&&(l=m,c.set(1,0,0));k<=l&&(l=k,c.set(0,1,0));n<=l&&c.set(0,0,1);g.crossVectors(d[0],c).normalize();e[0].crossVectors(d[0],g);f[0].crossVectors(d[0],e[0]);for(l=1;l<=a;l++)e[l]=e[l-1].clone(),f[l]=f[l-1].clone(),g.crossVectors(d[l-
|
|
|
-1],d[l]),g.length()>Number.EPSILON&&(g.normalize(),c=Math.acos(S.clamp(d[l-1].dot(d[l]),-1,1)),e[l].applyMatrix4(h.makeRotationAxis(g,c))),f[l].crossVectors(d[l],e[l]);if(!0===b)for(c=Math.acos(S.clamp(e[0].dot(e[a]),-1,1)),c/=a,0<d[0].dot(g.crossVectors(e[0],e[a]))&&(c=-c),l=1;l<=a;l++)e[l].applyMatrix4(h.makeRotationAxis(d[l],c*l)),f[l].crossVectors(d[l],e[l]);return{tangents:d,normals:e,binormals:f}},clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.arcLengthDivisions=
|
|
|
-a.arcLengthDivisions;return this},toJSON:function(){var a={metadata:{version:4.5,type:"Curve",generator:"Curve.toJSON"}};a.arcLengthDivisions=this.arcLengthDivisions;a.type=this.type;return a},fromJSON:function(a){this.arcLengthDivisions=a.arcLengthDivisions;return this}});za.prototype=Object.create(K.prototype);za.prototype.constructor=za;za.prototype.isEllipseCurve=!0;za.prototype.getPoint=function(a,b){b=b||new C;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)};za.prototype.copy=function(a){K.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};za.prototype.toJSON=function(){var a=K.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};za.prototype.fromJSON=function(a){K.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};fc.prototype=Object.create(za.prototype);fc.prototype.constructor=fc;fc.prototype.isArcCurve=!0;var Pd=new p,Ae=new fe,Be=new fe,Ce=new fe;da.prototype=Object.create(K.prototype);da.prototype.constructor=da;da.prototype.isCatmullRomCurve3=!0;da.prototype.getPoint=function(a,b){b=b||new p;var c=this.points,d=c.length;a*=d-(this.closed?0:1);var e=Math.floor(a);a-=e;this.closed?e+=0<e?0:(Math.floor(Math.abs(e)/
|
|
|
-c.length)+1)*c.length:0===a&&e===d-1&&(e=d-2,a=1);if(this.closed||0<e)var f=c[(e-1)%d];else Pd.subVectors(c[0],c[1]).add(c[0]),f=Pd;var g=c[e%d];var h=c[(e+1)%d];this.closed||e+2<d?c=c[(e+2)%d]:(Pd.subVectors(c[d-1],c[d-2]).add(c[d-1]),c=Pd);if("centripetal"===this.curveType||"chordal"===this.curveType){var l="chordal"===this.curveType?.5:.25;d=Math.pow(f.distanceToSquared(g),l);e=Math.pow(g.distanceToSquared(h),l);l=Math.pow(h.distanceToSquared(c),l);1E-4>e&&(e=1);1E-4>d&&(d=e);1E-4>l&&(l=e);Ae.initNonuniformCatmullRom(f.x,
|
|
|
+n.array;n=0;for(var r=u.length;n<r;n++){var q=u[n];m.fromArray(h,3*q);f(m,q)}}else for(n=0,u=h.length/3;n<u;n++)m.fromArray(h,3*n),f(m,n)}else for(m=h.vertices,n=0,u=m.length;n<u;n++)f(m[n],n)}}}(),clone:function(){return(new this.constructor(this.geometry,this.material)).copy(this)}});ud.prototype=Object.assign(Object.create(A.prototype),{constructor:ud,isGroup:!0});$d.prototype=Object.assign(Object.create(aa.prototype),{constructor:$d,isVideoTexture:!0,update:function(){var a=this.image;a.readyState>=
|
|
|
+a.HAVE_CURRENT_DATA&&(this.needsUpdate=!0)}});Qb.prototype=Object.create(aa.prototype);Qb.prototype.constructor=Qb;Qb.prototype.isCompressedTexture=!0;Dc.prototype=Object.create(aa.prototype);Dc.prototype.constructor=Dc;Dc.prototype.isDepthTexture=!0;Rb.prototype=Object.create(D.prototype);Rb.prototype.constructor=Rb;Ec.prototype=Object.create(M.prototype);Ec.prototype.constructor=Ec;Sb.prototype=Object.create(D.prototype);Sb.prototype.constructor=Sb;Fc.prototype=Object.create(M.prototype);Fc.prototype.constructor=
|
|
|
+Fc;va.prototype=Object.create(D.prototype);va.prototype.constructor=va;Gc.prototype=Object.create(M.prototype);Gc.prototype.constructor=Gc;Tb.prototype=Object.create(va.prototype);Tb.prototype.constructor=Tb;Hc.prototype=Object.create(M.prototype);Hc.prototype.constructor=Hc;qb.prototype=Object.create(va.prototype);qb.prototype.constructor=qb;Ic.prototype=Object.create(M.prototype);Ic.prototype.constructor=Ic;Ub.prototype=Object.create(va.prototype);Ub.prototype.constructor=Ub;Jc.prototype=Object.create(M.prototype);
|
|
|
+Jc.prototype.constructor=Jc;Vb.prototype=Object.create(va.prototype);Vb.prototype.constructor=Vb;Kc.prototype=Object.create(M.prototype);Kc.prototype.constructor=Kc;Wb.prototype=Object.create(D.prototype);Wb.prototype.constructor=Wb;Lc.prototype=Object.create(M.prototype);Lc.prototype.constructor=Lc;Xb.prototype=Object.create(D.prototype);Xb.prototype.constructor=Xb;Mc.prototype=Object.create(M.prototype);Mc.prototype.constructor=Mc;Yb.prototype=Object.create(D.prototype);Yb.prototype.constructor=
|
|
|
+Yb;var Lg={triangulate:function(a,b,c){c=c||2;var d=b&&b.length,e=d?b[0]*c:a.length,f=Xe(a,0,e,c,!0),g=[];if(!f)return g;var h;if(d){var l=c;d=[];var m;var k=0;for(m=b.length;k<m;k++){var n=b[k]*l;var p=k<m-1?b[k+1]*l:a.length;n=Xe(a,n,p,l,!1);n===n.next&&(n.steiner=!0);d.push(Jg(n))}d.sort(Hg);for(k=0;k<d.length;k++){b=d[k];l=f;if(l=Ig(b,l))b=$e(l,b),Oc(b,b.next);f=Oc(f,f.next)}}if(a.length>80*c){var r=h=a[0];var q=d=a[1];for(l=c;l<e;l+=c)k=a[l],b=a[l+1],k<r&&(r=k),b<q&&(q=b),k>h&&(h=k),b>d&&(d=
|
|
|
+b);h=Math.max(h-r,d-q);h=0!==h?1/h:0}Pc(f,g,c,r,q,h);return g}},Xa={area:function(a){for(var b=a.length,c=0,d=b-1,e=0;e<b;d=e++)c+=a[d].x*a[e].y-a[e].x*a[d].y;return.5*c},isClockWise:function(a){return 0>Xa.area(a)},triangulateShape:function(a,b){var c=[],d=[],e=[];af(a);bf(c,a);var f=a.length;b.forEach(af);for(a=0;a<b.length;a++)d.push(f),f+=b[a].length,bf(c,b[a]);b=Lg.triangulate(c,d);for(a=0;a<b.length;a+=3)e.push(b.slice(a,a+3));return e}};gb.prototype=Object.create(M.prototype);gb.prototype.constructor=
|
|
|
+gb;Ha.prototype=Object.create(D.prototype);Ha.prototype.constructor=Ha;Ha.prototype.getArrays=function(){var a=this.getAttribute("position");a=a?Array.prototype.slice.call(a.array):[];var b=this.getAttribute("uv");b=b?Array.prototype.slice.call(b.array):[];var c=this.index;c=c?Array.prototype.slice.call(c.array):[];return{position:a,uv:b,index:c}};Ha.prototype.addShapeList=function(a,b){var c=a.length;b.arrays=this.getArrays();for(var d=0;d<c;d++)this.addShape(a[d],b);this.setIndex(b.arrays.index);
|
|
|
+this.addAttribute("position",new B(b.arrays.position,3));this.addAttribute("uv",new B(b.arrays.uv,2))};Ha.prototype.addShape=function(a,b){function c(a,b,c){b||console.error("THREE.ExtrudeGeometry: vec does not exist");return b.clone().multiplyScalar(c).add(a)}function d(a,b,c){var d=a.x-b.x;var e=a.y-b.y;var f=c.x-a.x;var g=c.y-a.y,h=d*d+e*e;if(Math.abs(d*g-e*f)>Number.EPSILON){var l=Math.sqrt(h),m=Math.sqrt(f*f+g*g);h=b.x-e/l;b=b.y+d/l;g=((c.x-g/m-h)*g-(c.y+f/m-b)*f)/(d*g-e*f);f=h+d*g-a.x;d=b+e*
|
|
|
+g-a.y;e=f*f+d*d;if(2>=e)return new C(f,d);e=Math.sqrt(e/2)}else a=!1,d>Number.EPSILON?f>Number.EPSILON&&(a=!0):d<-Number.EPSILON?f<-Number.EPSILON&&(a=!0):Math.sign(e)===Math.sign(g)&&(a=!0),a?(f=-e,e=Math.sqrt(h)):(f=d,d=e,e=Math.sqrt(h/2));return new C(f/e,d/e)}function e(a,b){for(I=a.length;0<=--I;){var c=I;var d=I-1;0>d&&(d=a.length-1);var e,f=z+2*w;for(e=0;e<f;e++){var g=aa*e,m=aa*(e+1),n=b+d+g,p=b+d+m;m=b+c+m;h(b+c+g);h(n);h(m);h(n);h(p);h(m);g=k.length/3;g=G.generateSideWallUV(S,k,g-6,g-3,
|
|
|
+g-2,g-1);l(g[0]);l(g[1]);l(g[3]);l(g[1]);l(g[2]);l(g[3])}}}function f(a,b,c){r.push(a);r.push(b);r.push(c)}function g(a,b,c){h(a);h(b);h(c);a=k.length/3;a=G.generateTopUV(S,k,a-3,a-2,a-1);l(a[0]);l(a[1]);l(a[2])}function h(a){n.push(k.length/3);k.push(r[3*a]);k.push(r[3*a+1]);k.push(r[3*a+2])}function l(a){u.push(a.x);u.push(a.y)}var m=b.arrays?b.arrays:this.getArrays(),k=m.position,n=m.index,u=m.uv,r=[];m=void 0!==b.amount?b.amount:100;var q=void 0!==b.bevelThickness?b.bevelThickness:6,t=void 0!==
|
|
|
+b.bevelSize?b.bevelSize:q-2,w=void 0!==b.bevelSegments?b.bevelSegments:3,x=void 0!==b.bevelEnabled?b.bevelEnabled:!0,y=void 0!==b.curveSegments?b.curveSegments:12,z=void 0!==b.steps?b.steps:1,A=b.extrudePath,D=!1,G=void 0!==b.UVGenerator?b.UVGenerator:gb.WorldUVGenerator;if(A){var H=A.getSpacedPoints(z);D=!0;x=!1;var O=void 0!==b.frames?b.frames:A.computeFrenetFrames(z,!1);var K=new p;var M=new p;var N=new p}x||(t=q=w=0);var L,S=this;y=a.extractPoints(y);a=y.shape;var Q=y.holes;if(!Xa.isClockWise(a)){a=
|
|
|
+a.reverse();var T=0;for(L=Q.length;T<L;T++){var R=Q[T];Xa.isClockWise(R)&&(Q[T]=R.reverse())}}var Z=Xa.triangulateShape(a,Q),W=a;T=0;for(L=Q.length;T<L;T++)R=Q[T],a=a.concat(R);var U,aa=a.length,X,da=Z.length;y=[];var I=0;var V=W.length;var P=V-1;for(U=I+1;I<V;I++,P++,U++)P===V&&(P=0),U===V&&(U=0),y[I]=d(W[I],W[P],W[U]);A=[];var ea=y.concat();T=0;for(L=Q.length;T<L;T++){R=Q[T];var ca=[];I=0;V=R.length;P=V-1;for(U=I+1;I<V;I++,P++,U++)P===V&&(P=0),U===V&&(U=0),ca[I]=d(R[I],R[P],R[U]);A.push(ca);ea=
|
|
|
+ea.concat(ca)}for(P=0;P<w;P++){V=P/w;var fa=q*Math.cos(V*Math.PI/2);U=t*Math.sin(V*Math.PI/2);I=0;for(V=W.length;I<V;I++){var ia=c(W[I],y[I],U);f(ia.x,ia.y,-fa)}T=0;for(L=Q.length;T<L;T++)for(R=Q[T],ca=A[T],I=0,V=R.length;I<V;I++)ia=c(R[I],ca[I],U),f(ia.x,ia.y,-fa)}U=t;for(I=0;I<aa;I++)ia=x?c(a[I],ea[I],U):a[I],D?(M.copy(O.normals[0]).multiplyScalar(ia.x),K.copy(O.binormals[0]).multiplyScalar(ia.y),N.copy(H[0]).add(M).add(K),f(N.x,N.y,N.z)):f(ia.x,ia.y,0);for(V=1;V<=z;V++)for(I=0;I<aa;I++)ia=x?c(a[I],
|
|
|
+ea[I],U):a[I],D?(M.copy(O.normals[V]).multiplyScalar(ia.x),K.copy(O.binormals[V]).multiplyScalar(ia.y),N.copy(H[V]).add(M).add(K),f(N.x,N.y,N.z)):f(ia.x,ia.y,m/z*V);for(P=w-1;0<=P;P--){V=P/w;fa=q*Math.cos(V*Math.PI/2);U=t*Math.sin(V*Math.PI/2);I=0;for(V=W.length;I<V;I++)ia=c(W[I],y[I],U),f(ia.x,ia.y,m+fa);T=0;for(L=Q.length;T<L;T++)for(R=Q[T],ca=A[T],I=0,V=R.length;I<V;I++)ia=c(R[I],ca[I],U),D?f(ia.x,ia.y+H[z-1].y,H[z-1].x+fa):f(ia.x,ia.y,m+fa)}(function(){var a=k.length/3;if(x){var c=0*aa;for(I=
|
|
|
+0;I<da;I++)X=Z[I],g(X[2]+c,X[1]+c,X[0]+c);c=aa*(z+2*w);for(I=0;I<da;I++)X=Z[I],g(X[0]+c,X[1]+c,X[2]+c)}else{for(I=0;I<da;I++)X=Z[I],g(X[2],X[1],X[0]);for(I=0;I<da;I++)X=Z[I],g(X[0]+aa*z,X[1]+aa*z,X[2]+aa*z)}S.addGroup(a,k.length/3-a,void 0!==b.material?b.material:0)})();(function(){var a=k.length/3,c=0;e(W,c);c+=W.length;T=0;for(L=Q.length;T<L;T++)R=Q[T],e(R,c),c+=R.length;S.addGroup(a,k.length/3-a,void 0!==b.extrudeMaterial?b.extrudeMaterial:1)})();b.arrays||(this.setIndex(n),this.addAttribute("position",
|
|
|
+new B(k,3)),this.addAttribute("uv",new B(u,2)))};gb.WorldUVGenerator={generateTopUV:function(a,b,c,d,e){a=b[3*d];d=b[3*d+1];var f=b[3*e];e=b[3*e+1];return[new C(b[3*c],b[3*c+1]),new C(a,d),new C(f,e)]},generateSideWallUV:function(a,b,c,d,e,f){a=b[3*c];var g=b[3*c+1];c=b[3*c+2];var h=b[3*d],l=b[3*d+1];d=b[3*d+2];var m=b[3*e],k=b[3*e+1];e=b[3*e+2];var n=b[3*f],p=b[3*f+1];b=b[3*f+2];return.01>Math.abs(g-l)?[new C(a,1-c),new C(h,1-d),new C(m,1-e),new C(n,1-b)]:[new C(g,1-c),new C(l,1-d),new C(k,1-e),
|
|
|
+new C(p,1-b)]}};Rc.prototype=Object.create(M.prototype);Rc.prototype.constructor=Rc;Zb.prototype=Object.create(Ha.prototype);Zb.prototype.constructor=Zb;Sc.prototype=Object.create(M.prototype);Sc.prototype.constructor=Sc;sb.prototype=Object.create(D.prototype);sb.prototype.constructor=sb;Tc.prototype=Object.create(M.prototype);Tc.prototype.constructor=Tc;$b.prototype=Object.create(D.prototype);$b.prototype.constructor=$b;Uc.prototype=Object.create(M.prototype);Uc.prototype.constructor=Uc;ac.prototype=
|
|
|
+Object.create(D.prototype);ac.prototype.constructor=ac;tb.prototype=Object.create(M.prototype);tb.prototype.constructor=tb;tb.prototype.toJSON=function(){var a=M.prototype.toJSON.call(this);return cf(this.parameters.shapes,a)};ub.prototype=Object.create(D.prototype);ub.prototype.constructor=ub;ub.prototype.toJSON=function(){var a=D.prototype.toJSON.call(this);return cf(this.parameters.shapes,a)};bc.prototype=Object.create(D.prototype);bc.prototype.constructor=bc;vb.prototype=Object.create(M.prototype);
|
|
|
+vb.prototype.constructor=vb;Ya.prototype=Object.create(D.prototype);Ya.prototype.constructor=Ya;Vc.prototype=Object.create(vb.prototype);Vc.prototype.constructor=Vc;Wc.prototype=Object.create(Ya.prototype);Wc.prototype.constructor=Wc;Xc.prototype=Object.create(M.prototype);Xc.prototype.constructor=Xc;cc.prototype=Object.create(D.prototype);cc.prototype.constructor=cc;var oa=Object.freeze({WireframeGeometry:Rb,ParametricGeometry:Ec,ParametricBufferGeometry:Sb,TetrahedronGeometry:Gc,TetrahedronBufferGeometry:Tb,
|
|
|
+OctahedronGeometry:Hc,OctahedronBufferGeometry:qb,IcosahedronGeometry:Ic,IcosahedronBufferGeometry:Ub,DodecahedronGeometry:Jc,DodecahedronBufferGeometry:Vb,PolyhedronGeometry:Fc,PolyhedronBufferGeometry:va,TubeGeometry:Kc,TubeBufferGeometry:Wb,TorusKnotGeometry:Lc,TorusKnotBufferGeometry:Xb,TorusGeometry:Mc,TorusBufferGeometry:Yb,TextGeometry:Rc,TextBufferGeometry:Zb,SphereGeometry:Sc,SphereBufferGeometry:sb,RingGeometry:Tc,RingBufferGeometry:$b,PlaneGeometry:yc,PlaneBufferGeometry:nb,LatheGeometry:Uc,
|
|
|
+LatheBufferGeometry:ac,ShapeGeometry:tb,ShapeBufferGeometry:ub,ExtrudeGeometry:gb,ExtrudeBufferGeometry:Ha,EdgesGeometry:bc,ConeGeometry:Vc,ConeBufferGeometry:Wc,CylinderGeometry:vb,CylinderBufferGeometry:Ya,CircleGeometry:Xc,CircleBufferGeometry:cc,BoxGeometry:Kb,BoxBufferGeometry:mb});dc.prototype=Object.create(L.prototype);dc.prototype.constructor=dc;dc.prototype.isShadowMaterial=!0;ec.prototype=Object.create(Ca.prototype);ec.prototype.constructor=ec;ec.prototype.isRawShaderMaterial=!0;Ra.prototype=
|
|
|
+Object.create(L.prototype);Ra.prototype.constructor=Ra;Ra.prototype.isMeshStandardMaterial=!0;Ra.prototype.copy=function(a){L.prototype.copy.call(this,a);this.defines={STANDARD:""};this.color.copy(a.color);this.roughness=a.roughness;this.metalness=a.metalness;this.map=a.map;this.lightMap=a.lightMap;this.lightMapIntensity=a.lightMapIntensity;this.aoMap=a.aoMap;this.aoMapIntensity=a.aoMapIntensity;this.emissive.copy(a.emissive);this.emissiveMap=a.emissiveMap;this.emissiveIntensity=a.emissiveIntensity;
|
|
|
+this.bumpMap=a.bumpMap;this.bumpScale=a.bumpScale;this.normalMap=a.normalMap;this.normalScale.copy(a.normalScale);this.displacementMap=a.displacementMap;this.displacementScale=a.displacementScale;this.displacementBias=a.displacementBias;this.roughnessMap=a.roughnessMap;this.metalnessMap=a.metalnessMap;this.alphaMap=a.alphaMap;this.envMap=a.envMap;this.envMapIntensity=a.envMapIntensity;this.refractionRatio=a.refractionRatio;this.wireframe=a.wireframe;this.wireframeLinewidth=a.wireframeLinewidth;this.wireframeLinecap=
|
|
|
+a.wireframeLinecap;this.wireframeLinejoin=a.wireframeLinejoin;this.skinning=a.skinning;this.morphTargets=a.morphTargets;this.morphNormals=a.morphNormals;return this};wb.prototype=Object.create(Ra.prototype);wb.prototype.constructor=wb;wb.prototype.isMeshPhysicalMaterial=!0;wb.prototype.copy=function(a){Ra.prototype.copy.call(this,a);this.defines={PHYSICAL:""};this.reflectivity=a.reflectivity;this.clearCoat=a.clearCoat;this.clearCoatRoughness=a.clearCoatRoughness;return this};Ia.prototype=Object.create(L.prototype);
|
|
|
+Ia.prototype.constructor=Ia;Ia.prototype.isMeshPhongMaterial=!0;Ia.prototype.copy=function(a){L.prototype.copy.call(this,a);this.color.copy(a.color);this.specular.copy(a.specular);this.shininess=a.shininess;this.map=a.map;this.lightMap=a.lightMap;this.lightMapIntensity=a.lightMapIntensity;this.aoMap=a.aoMap;this.aoMapIntensity=a.aoMapIntensity;this.emissive.copy(a.emissive);this.emissiveMap=a.emissiveMap;this.emissiveIntensity=a.emissiveIntensity;this.bumpMap=a.bumpMap;this.bumpScale=a.bumpScale;
|
|
|
+this.normalMap=a.normalMap;this.normalScale.copy(a.normalScale);this.displacementMap=a.displacementMap;this.displacementScale=a.displacementScale;this.displacementBias=a.displacementBias;this.specularMap=a.specularMap;this.alphaMap=a.alphaMap;this.envMap=a.envMap;this.combine=a.combine;this.reflectivity=a.reflectivity;this.refractionRatio=a.refractionRatio;this.wireframe=a.wireframe;this.wireframeLinewidth=a.wireframeLinewidth;this.wireframeLinecap=a.wireframeLinecap;this.wireframeLinejoin=a.wireframeLinejoin;
|
|
|
+this.skinning=a.skinning;this.morphTargets=a.morphTargets;this.morphNormals=a.morphNormals;return this};xb.prototype=Object.create(Ia.prototype);xb.prototype.constructor=xb;xb.prototype.isMeshToonMaterial=!0;xb.prototype.copy=function(a){Ia.prototype.copy.call(this,a);this.gradientMap=a.gradientMap;return this};yb.prototype=Object.create(L.prototype);yb.prototype.constructor=yb;yb.prototype.isMeshNormalMaterial=!0;yb.prototype.copy=function(a){L.prototype.copy.call(this,a);this.bumpMap=a.bumpMap;
|
|
|
+this.bumpScale=a.bumpScale;this.normalMap=a.normalMap;this.normalScale.copy(a.normalScale);this.displacementMap=a.displacementMap;this.displacementScale=a.displacementScale;this.displacementBias=a.displacementBias;this.wireframe=a.wireframe;this.wireframeLinewidth=a.wireframeLinewidth;this.skinning=a.skinning;this.morphTargets=a.morphTargets;this.morphNormals=a.morphNormals;return this};zb.prototype=Object.create(L.prototype);zb.prototype.constructor=zb;zb.prototype.isMeshLambertMaterial=!0;zb.prototype.copy=
|
|
|
+function(a){L.prototype.copy.call(this,a);this.color.copy(a.color);this.map=a.map;this.lightMap=a.lightMap;this.lightMapIntensity=a.lightMapIntensity;this.aoMap=a.aoMap;this.aoMapIntensity=a.aoMapIntensity;this.emissive.copy(a.emissive);this.emissiveMap=a.emissiveMap;this.emissiveIntensity=a.emissiveIntensity;this.specularMap=a.specularMap;this.alphaMap=a.alphaMap;this.envMap=a.envMap;this.combine=a.combine;this.reflectivity=a.reflectivity;this.refractionRatio=a.refractionRatio;this.wireframe=a.wireframe;
|
|
|
+this.wireframeLinewidth=a.wireframeLinewidth;this.wireframeLinecap=a.wireframeLinecap;this.wireframeLinejoin=a.wireframeLinejoin;this.skinning=a.skinning;this.morphTargets=a.morphTargets;this.morphNormals=a.morphNormals;return this};Ab.prototype=Object.create(Z.prototype);Ab.prototype.constructor=Ab;Ab.prototype.isLineDashedMaterial=!0;Ab.prototype.copy=function(a){Z.prototype.copy.call(this,a);this.scale=a.scale;this.dashSize=a.dashSize;this.gapSize=a.gapSize;return this};var Mg=Object.freeze({ShadowMaterial:dc,
|
|
|
+SpriteMaterial:fb,RawShaderMaterial:ec,ShaderMaterial:Ca,PointsMaterial:Ga,MeshPhysicalMaterial:wb,MeshStandardMaterial:Ra,MeshPhongMaterial:Ia,MeshToonMaterial:xb,MeshNormalMaterial:yb,MeshLambertMaterial:zb,MeshDepthMaterial:cb,MeshDistanceMaterial:db,MeshBasicMaterial:ya,LineDashedMaterial:Ab,LineBasicMaterial:Z,Material:L}),Eb={enabled:!1,files:{},add:function(a,b){!1!==this.enabled&&(this.files[a]=b)},get:function(a){if(!1!==this.enabled)return this.files[a]},remove:function(a){delete this.files[a]},
|
|
|
+clear:function(){this.files={}}},sa=new ce,$a={};Object.assign(Ja.prototype,{load:function(a,b,c,d){void 0===a&&(a="");void 0!==this.path&&(a=this.path+a);a=this.manager.resolveURL(a);var e=this,f=Eb.get(a);if(void 0!==f)return e.manager.itemStart(a),setTimeout(function(){b&&b(f);e.manager.itemEnd(a)},0),f;if(void 0!==$a[a])$a[a].push({onLoad:b,onProgress:c,onError:d});else{var g=a.match(/^data:(.*?)(;base64)?,(.*)$/);if(g){c=g[1];var h=!!g[2];g=g[3];g=window.decodeURIComponent(g);h&&(g=window.atob(g));
|
|
|
+try{var l=(this.responseType||"").toLowerCase();switch(l){case "arraybuffer":case "blob":var m=new Uint8Array(g.length);for(h=0;h<g.length;h++)m[h]=g.charCodeAt(h);var k="blob"===l?new Blob([m.buffer],{type:c}):m.buffer;break;case "document":k=(new DOMParser).parseFromString(g,c);break;case "json":k=JSON.parse(g);break;default:k=g}window.setTimeout(function(){b&&b(k);e.manager.itemEnd(a)},0)}catch(u){window.setTimeout(function(){d&&d(u);e.manager.itemEnd(a);e.manager.itemError(a)},0)}}else{$a[a]=
|
|
|
+[];$a[a].push({onLoad:b,onProgress:c,onError:d});var n=new XMLHttpRequest;n.open("GET",a,!0);n.addEventListener("load",function(b){var c=this.response;Eb.add(a,c);var d=$a[a];delete $a[a];if(200===this.status){for(var f=0,g=d.length;f<g;f++){var h=d[f];if(h.onLoad)h.onLoad(c)}e.manager.itemEnd(a)}else if(0===this.status){console.warn("THREE.FileLoader: HTTP Status 0 received.");f=0;for(g=d.length;f<g;f++)if(h=d[f],h.onLoad)h.onLoad(c);e.manager.itemEnd(a)}else{f=0;for(g=d.length;f<g;f++)if(h=d[f],
|
|
|
+h.onError)h.onError(b);e.manager.itemEnd(a);e.manager.itemError(a)}},!1);n.addEventListener("progress",function(b){for(var c=$a[a],d=0,e=c.length;d<e;d++){var f=c[d];if(f.onProgress)f.onProgress(b)}},!1);n.addEventListener("error",function(b){var c=$a[a];delete $a[a];for(var d=0,f=c.length;d<f;d++){var g=c[d];if(g.onError)g.onError(b)}e.manager.itemEnd(a);e.manager.itemError(a)},!1);void 0!==this.responseType&&(n.responseType=this.responseType);void 0!==this.withCredentials&&(n.withCredentials=this.withCredentials);
|
|
|
+n.overrideMimeType&&n.overrideMimeType(void 0!==this.mimeType?this.mimeType:"text/plain");for(h in this.requestHeader)n.setRequestHeader(h,this.requestHeader[h]);n.send(null)}e.manager.itemStart(a);return n}},setPath:function(a){this.path=a;return this},setResponseType:function(a){this.responseType=a;return this},setWithCredentials:function(a){this.withCredentials=a;return this},setMimeType:function(a){this.mimeType=a;return this},setRequestHeader:function(a){this.requestHeader=a;return this}});Object.assign(df.prototype,
|
|
|
+{load:function(a,b,c,d){function e(e){l.load(a[e],function(a){a=f._parser(a,!0);g[e]={width:a.width,height:a.height,format:a.format,mipmaps:a.mipmaps};m+=1;6===m&&(1===a.mipmapCount&&(h.minFilter=1006),h.format=a.format,h.needsUpdate=!0,b&&b(h))},c,d)}var f=this,g=[],h=new Qb;h.image=g;var l=new Ja(this.manager);l.setPath(this.path);l.setResponseType("arraybuffer");if(Array.isArray(a))for(var m=0,k=0,n=a.length;k<n;++k)e(k);else l.load(a,function(a){a=f._parser(a,!0);if(a.isCubemap)for(var c=a.mipmaps.length/
|
|
|
+a.mipmapCount,d=0;d<c;d++){g[d]={mipmaps:[]};for(var e=0;e<a.mipmapCount;e++)g[d].mipmaps.push(a.mipmaps[d*a.mipmapCount+e]),g[d].format=a.format,g[d].width=a.width,g[d].height=a.height}else h.image.width=a.width,h.image.height=a.height,h.mipmaps=a.mipmaps;1===a.mipmapCount&&(h.minFilter=1006);h.format=a.format;h.needsUpdate=!0;b&&b(h)},c,d);return h},setPath:function(a){this.path=a;return this}});Object.assign(de.prototype,{load:function(a,b,c,d){var e=this,f=new jb,g=new Ja(this.manager);g.setResponseType("arraybuffer");
|
|
|
+g.load(a,function(a){if(a=e._parser(a))void 0!==a.image?f.image=a.image:void 0!==a.data&&(f.image.width=a.width,f.image.height=a.height,f.image.data=a.data),f.wrapS=void 0!==a.wrapS?a.wrapS:1001,f.wrapT=void 0!==a.wrapT?a.wrapT:1001,f.magFilter=void 0!==a.magFilter?a.magFilter:1006,f.minFilter=void 0!==a.minFilter?a.minFilter:1008,f.anisotropy=void 0!==a.anisotropy?a.anisotropy:1,void 0!==a.format&&(f.format=a.format),void 0!==a.type&&(f.type=a.type),void 0!==a.mipmaps&&(f.mipmaps=a.mipmaps),1===
|
|
|
+a.mipmapCount&&(f.minFilter=1006),f.needsUpdate=!0,b&&b(f,a)},c,d);return f}});Object.assign(Yc.prototype,{crossOrigin:"Anonymous",load:function(a,b,c,d){void 0===a&&(a="");void 0!==this.path&&(a=this.path+a);a=this.manager.resolveURL(a);var e=this,f=Eb.get(a);if(void 0!==f)return e.manager.itemStart(a),setTimeout(function(){b&&b(f);e.manager.itemEnd(a)},0),f;c=document.createElementNS("http://www.w3.org/1999/xhtml","img");c.addEventListener("load",function(){Eb.add(a,this);b&&b(this);e.manager.itemEnd(a)},
|
|
|
+!1);c.addEventListener("error",function(b){d&&d(b);e.manager.itemEnd(a);e.manager.itemError(a)},!1);"data:"!==a.substr(0,5)&&void 0!==this.crossOrigin&&(c.crossOrigin=this.crossOrigin);e.manager.itemStart(a);c.src=a;return c},setCrossOrigin:function(a){this.crossOrigin=a;return this},setPath:function(a){this.path=a;return this}});Object.assign(ee.prototype,{crossOrigin:"Anonymous",load:function(a,b,c,d){function e(c){g.load(a[c],function(a){f.images[c]=a;h++;6===h&&(f.needsUpdate=!0,b&&b(f))},void 0,
|
|
|
+d)}var f=new ab,g=new Yc(this.manager);g.setCrossOrigin(this.crossOrigin);g.setPath(this.path);var h=0;for(c=0;c<a.length;++c)e(c);return f},setCrossOrigin:function(a){this.crossOrigin=a;return this},setPath:function(a){this.path=a;return this}});Object.assign(wd.prototype,{crossOrigin:"Anonymous",load:function(a,b,c,d){var e=new aa,f=new Yc(this.manager);f.setCrossOrigin(this.crossOrigin);f.setPath(this.path);f.load(a,function(c){e.image=c;c=0<a.search(/\.(jpg|jpeg)$/)||0===a.search(/^data:image\/jpeg/);
|
|
|
+e.format=c?1022:1023;e.needsUpdate=!0;void 0!==b&&b(e)},c,d);return e},setCrossOrigin:function(a){this.crossOrigin=a;return this},setPath:function(a){this.path=a;return this}});Object.assign(K.prototype,{getPoint:function(){console.warn("THREE.Curve: .getPoint() not implemented.");return null},getPointAt:function(a,b){a=this.getUtoTmapping(a);return this.getPoint(a,b)},getPoints:function(a){void 0===a&&(a=5);for(var b=[],c=0;c<=a;c++)b.push(this.getPoint(c/a));return b},getSpacedPoints:function(a){void 0===
|
|
|
+a&&(a=5);for(var b=[],c=0;c<=a;c++)b.push(this.getPointAt(c/a));return b},getLength:function(){var a=this.getLengths();return a[a.length-1]},getLengths:function(a){void 0===a&&(a=this.arcLengthDivisions);if(this.cacheArcLengths&&this.cacheArcLengths.length===a+1&&!this.needsUpdate)return this.cacheArcLengths;this.needsUpdate=!1;var b=[],c=this.getPoint(0),d,e=0;b.push(0);for(d=1;d<=a;d++){var f=this.getPoint(d/a);e+=f.distanceTo(c);b.push(e);c=f}return this.cacheArcLengths=b},updateArcLengths:function(){this.needsUpdate=
|
|
|
+!0;this.getLengths()},getUtoTmapping:function(a,b){var c=this.getLengths(),d=c.length;b=b?b:a*c[d-1];for(var e=0,f=d-1,g;e<=f;)if(a=Math.floor(e+(f-e)/2),g=c[a]-b,0>g)e=a+1;else if(0<g)f=a-1;else{f=a;break}a=f;if(c[a]===b)return a/(d-1);e=c[a];return(a+(b-e)/(c[a+1]-e))/(d-1)},getTangent:function(a){var b=a-1E-4;a+=1E-4;0>b&&(b=0);1<a&&(a=1);b=this.getPoint(b);return this.getPoint(a).clone().sub(b).normalize()},getTangentAt:function(a){a=this.getUtoTmapping(a);return this.getTangent(a)},computeFrenetFrames:function(a,
|
|
|
+b){var c=new p,d=[],e=[],f=[],g=new p,h=new Q,l;for(l=0;l<=a;l++){var m=l/a;d[l]=this.getTangentAt(m);d[l].normalize()}e[0]=new p;f[0]=new p;l=Number.MAX_VALUE;m=Math.abs(d[0].x);var k=Math.abs(d[0].y),n=Math.abs(d[0].z);m<=l&&(l=m,c.set(1,0,0));k<=l&&(l=k,c.set(0,1,0));n<=l&&c.set(0,0,1);g.crossVectors(d[0],c).normalize();e[0].crossVectors(d[0],g);f[0].crossVectors(d[0],e[0]);for(l=1;l<=a;l++)e[l]=e[l-1].clone(),f[l]=f[l-1].clone(),g.crossVectors(d[l-1],d[l]),g.length()>Number.EPSILON&&(g.normalize(),
|
|
|
+c=Math.acos(S.clamp(d[l-1].dot(d[l]),-1,1)),e[l].applyMatrix4(h.makeRotationAxis(g,c))),f[l].crossVectors(d[l],e[l]);if(!0===b)for(c=Math.acos(S.clamp(e[0].dot(e[a]),-1,1)),c/=a,0<d[0].dot(g.crossVectors(e[0],e[a]))&&(c=-c),l=1;l<=a;l++)e[l].applyMatrix4(h.makeRotationAxis(d[l],c*l)),f[l].crossVectors(d[l],e[l]);return{tangents:d,normals:e,binormals:f}},clone:function(){return(new this.constructor).copy(this)},copy:function(a){this.arcLengthDivisions=a.arcLengthDivisions;return this},toJSON:function(){var a=
|
|
|
+{metadata:{version:4.5,type:"Curve",generator:"Curve.toJSON"}};a.arcLengthDivisions=this.arcLengthDivisions;a.type=this.type;return a},fromJSON:function(a){this.arcLengthDivisions=a.arcLengthDivisions;return this}});za.prototype=Object.create(K.prototype);za.prototype.constructor=za;za.prototype.isEllipseCurve=!0;za.prototype.getPoint=function(a,b){b=b||new C;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)};za.prototype.copy=function(a){K.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};za.prototype.toJSON=function(){var a=K.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};za.prototype.fromJSON=function(a){K.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};fc.prototype=Object.create(za.prototype);fc.prototype.constructor=fc;fc.prototype.isArcCurve=!0;var Pd=new p,Ae=new fe,Be=new fe,Ce=new fe;da.prototype=Object.create(K.prototype);da.prototype.constructor=da;da.prototype.isCatmullRomCurve3=!0;da.prototype.getPoint=function(a,b){b=b||new p;var c=this.points,d=c.length;a*=d-(this.closed?0:1);var e=Math.floor(a);a-=e;this.closed?e+=0<e?0:(Math.floor(Math.abs(e)/c.length)+1)*c.length:
|
|
|
+0===a&&e===d-1&&(e=d-2,a=1);if(this.closed||0<e)var f=c[(e-1)%d];else Pd.subVectors(c[0],c[1]).add(c[0]),f=Pd;var g=c[e%d];var h=c[(e+1)%d];this.closed||e+2<d?c=c[(e+2)%d]:(Pd.subVectors(c[d-1],c[d-2]).add(c[d-1]),c=Pd);if("centripetal"===this.curveType||"chordal"===this.curveType){var l="chordal"===this.curveType?.5:.25;d=Math.pow(f.distanceToSquared(g),l);e=Math.pow(g.distanceToSquared(h),l);l=Math.pow(h.distanceToSquared(c),l);1E-4>e&&(e=1);1E-4>d&&(d=e);1E-4>l&&(l=e);Ae.initNonuniformCatmullRom(f.x,
|
|
|
g.x,h.x,c.x,d,e,l);Be.initNonuniformCatmullRom(f.y,g.y,h.y,c.y,d,e,l);Ce.initNonuniformCatmullRom(f.z,g.z,h.z,c.z,d,e,l)}else"catmullrom"===this.curveType&&(Ae.initCatmullRom(f.x,g.x,h.x,c.x,this.tension),Be.initCatmullRom(f.y,g.y,h.y,c.y,this.tension),Ce.initCatmullRom(f.z,g.z,h.z,c.z,this.tension));b.set(Ae.calc(a),Be.calc(a),Ce.calc(a));return b};da.prototype.copy=function(a){K.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};da.prototype.toJSON=function(){var a=K.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};da.prototype.fromJSON=function(a){K.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 p).fromArray(d))}this.closed=
|
|
|
a.closed;this.curveType=a.curveType;this.tension=a.tension;return this};Ka.prototype=Object.create(K.prototype);Ka.prototype.constructor=Ka;Ka.prototype.isCubicBezierCurve=!0;Ka.prototype.getPoint=function(a,b){b=b||new C;var c=this.v0,d=this.v1,e=this.v2,f=this.v3;b.set($c(a,c.x,d.x,e.x,f.x),$c(a,c.y,d.y,e.y,f.y));return b};Ka.prototype.copy=function(a){K.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};Ka.prototype.toJSON=function(){var a=
|