|
@@ -495,10 +495,12 @@ THREE.FontUtils.generateShapes=function(a,b){var b=b||{},c=b.curveSegments!==voi
|
|
|
C=void 0,z=void 0,v=void 0,H=void 0,w=m[t[p]].x,s=m[t[p]].y,x=m[t[r]].x,F=m[t[r]].y,C=m[t[n]].x,z=m[t[n]].y;if(1.0E-10>(x-w)*(z-s)-(F-s)*(C-w))m=false;else{for(u=0;u<q;u++)if(!(u==p||u==r||u==n)){var v=m[t[u]].x,H=m[t[u]].y,I=void 0,N=void 0,R=void 0,Y=void 0,B=void 0,G=void 0,Q=void 0,D=void 0,i=void 0,P=void 0,L=void 0,S=void 0,I=R=B=void 0,I=C-x,N=z-F,R=w-C,Y=s-z,B=x-w,G=F-s,Q=v-w,D=H-s,i=v-x,P=H-F,L=v-C,S=H-z,I=I*P-N*i,B=B*D-G*Q,R=R*S-Y*L;if(I>=0&&R>=0&&B>=0){m=false;break a}}m=true}}if(m){f.push([a[g[k]],
|
|
|
a[g[j]],a[g[l]]]);h.push([g[k],g[j],g[l]]);k=j;for(l=j+1;l<e;k++,l++)g[k]=g[l];e--;o=2*e}}return d?h:f};a.Triangulate.area=b;return a})(THREE.FontUtils);self._typeface_js={faces:THREE.FontUtils.faces,loadFace:THREE.FontUtils.loadFace};
|
|
|
THREE.BufferGeometry=function(){this.id=THREE.GeometryCount++;this.vertexColorArray=this.vertexUvArray=this.vertexNormalArray=this.vertexPositionArray=this.vertexIndexArray=this.vertexColorBuffer=this.vertexUvBuffer=this.vertexNormalBuffer=this.vertexPositionBuffer=this.vertexIndexBuffer=null;this.dynamic=false;this.boundingSphere=this.boundingBox=null;this.morphTargets=[]};
|
|
|
-THREE.BufferGeometry.prototype={constructor:THREE.BufferGeometry,applyMatrix:function(a){if(this.vertexPositionArray!==void 0){a.multiplyVector3Array(this.vertexPositionArray);this.verticesNeedUpdate=true}if(this.vertexNormalArray!==void 0){var b=new THREE.Matrix4;b.extractRotation(a);b.multiplyVector3Array(this.vertexNormalArray);this.normalsNeedUpdate=true}},computeBoundingBox:function(){},computeBoundingSphere:function(){}};THREE.Curve=function(){};
|
|
|
-THREE.Curve.prototype.getPoint=function(){console.log("Warning, getPoint() not implemented!");return null};THREE.Curve.prototype.getPointAt=function(a){return this.getPoint(this.getUtoTmapping(a))};THREE.Curve.prototype.getPoints=function(a){a||(a=5);var b,c=[];for(b=0;b<=a;b++)c.push(this.getPoint(b/a));return c};THREE.Curve.prototype.getSpacedPoints=function(a){a||(a=5);var b,c=[];for(b=0;b<=a;b++)c.push(this.getPointAt(b/a));return c};
|
|
|
-THREE.Curve.prototype.getLength=function(){var a=this.getLengths();return a[a.length-1]};THREE.Curve.prototype.getLengths=function(a){a||(a=this.__arcLengthDivisions?this.__arcLengthDivisions:200);if(this.cacheArcLengths&&this.cacheArcLengths.length==a+1&&!this.needsUpdate)return this.cacheArcLengths;this.needsUpdate=false;var b=[],c,d=this.getPoint(0),e,f=0;b.push(0);for(e=1;e<=a;e++){c=this.getPoint(e/a);f=f+c.distanceTo(d);b.push(f);d=c}return this.cacheArcLengths=b};
|
|
|
-THREE.Curve.prototype.updateArcLengths=function(){this.needsUpdate=true;this.getLengths()};THREE.Curve.prototype.getUtoTmapping=function(a,b){var c=this.getLengths(),d=0,e=c.length,f;f=b?b:a*c[e-1];for(var g=0,h=e-1,k;g<=h;){d=Math.floor(g+(h-g)/2);k=c[d]-f;if(k<0)g=d+1;else if(k>0)h=d-1;else{h=d;break}}d=h;if(c[d]==f)return d/(e-1);g=c[d];return c=(d+(f-g)/(c[d+1]-g))/(e-1)};THREE.Curve.prototype.getNormalVector=function(a){a=this.getTangent(a);return new THREE.Vector2(-a.y,a.x)};
|
|
|
+THREE.BufferGeometry.prototype={constructor:THREE.BufferGeometry,applyMatrix:function(a){if(this.vertexPositionArray!==void 0){a.multiplyVector3Array(this.vertexPositionArray);this.verticesNeedUpdate=true}if(this.vertexNormalArray!==void 0){var b=new THREE.Matrix4;b.extractRotation(a);b.multiplyVector3Array(this.vertexNormalArray);this.normalsNeedUpdate=true}},computeBoundingBox:function(){if(!this.boundingBox)this.boundingBox={min:new THREE.Vector3(Infinity,Infinity,Infinity),max:new THREE.Vector3(-Infinity,
|
|
|
+-Infinity,-Infinity)};var a=this.vertexPositionArray;if(a)for(var b=this.boundingBox,c,d,e,f=0,g=a.length;f<g;f=f+3){c=a[f];d=a[f+1];e=a[f+2];if(c<b.min.x)b.min.x=c;else if(c>b.max.x)b.max.x=c;if(d<b.min.y)b.min.y=d;else if(d>b.max.y)b.max.y=d;if(e<b.min.z)b.min.z=e;else if(e>b.max.z)b.max.z=e}if(a===void 0||a.length===0){this.boundingBox.min.set(0,0,0);this.boundingBox.max.set(0,0,0)}},computeBoundingSphere:function(){if(!this.boundingSphere)this.boundingSphere={radius:0};var a=this.vertexPositionArray;
|
|
|
+if(a){for(var b,c=0,d,e,f=0,g=a.length;f<g;f=f+3){b=a[f];d=a[f+1];e=a[f+2];b=Math.sqrt(b*b+d*d+e*e);b>c&&(c=b)}this.boundingSphere.radius=c}}};THREE.Curve=function(){};THREE.Curve.prototype.getPoint=function(){console.log("Warning, getPoint() not implemented!");return null};THREE.Curve.prototype.getPointAt=function(a){return this.getPoint(this.getUtoTmapping(a))};THREE.Curve.prototype.getPoints=function(a){a||(a=5);var b,c=[];for(b=0;b<=a;b++)c.push(this.getPoint(b/a));return c};
|
|
|
+THREE.Curve.prototype.getSpacedPoints=function(a){a||(a=5);var b,c=[];for(b=0;b<=a;b++)c.push(this.getPointAt(b/a));return c};THREE.Curve.prototype.getLength=function(){var a=this.getLengths();return a[a.length-1]};
|
|
|
+THREE.Curve.prototype.getLengths=function(a){a||(a=this.__arcLengthDivisions?this.__arcLengthDivisions:200);if(this.cacheArcLengths&&this.cacheArcLengths.length==a+1&&!this.needsUpdate)return this.cacheArcLengths;this.needsUpdate=false;var b=[],c,d=this.getPoint(0),e,f=0;b.push(0);for(e=1;e<=a;e++){c=this.getPoint(e/a);f=f+c.distanceTo(d);b.push(f);d=c}return this.cacheArcLengths=b};THREE.Curve.prototype.updateArcLengths=function(){this.needsUpdate=true;this.getLengths()};
|
|
|
+THREE.Curve.prototype.getUtoTmapping=function(a,b){var c=this.getLengths(),d=0,e=c.length,f;f=b?b:a*c[e-1];for(var g=0,h=e-1,k;g<=h;){d=Math.floor(g+(h-g)/2);k=c[d]-f;if(k<0)g=d+1;else if(k>0)h=d-1;else{h=d;break}}d=h;if(c[d]==f)return d/(e-1);g=c[d];return c=(d+(f-g)/(c[d+1]-g))/(e-1)};THREE.Curve.prototype.getNormalVector=function(a){a=this.getTangent(a);return new THREE.Vector2(-a.y,a.x)};
|
|
|
THREE.Curve.prototype.getTangent=function(a){var b=a-1.0E-4,a=a+1.0E-4;b<0&&(b=0);a>1&&(a=1);b=this.getPoint(b);return this.getPoint(a).clone().subSelf(b).normalize()};THREE.Curve.prototype.getTangentAt=function(a){return this.getTangent(this.getUtoTmapping(a))};THREE.LineCurve=function(a,b){this.v1=a;this.v2=b};THREE.LineCurve.prototype=Object.create(THREE.Curve.prototype);THREE.LineCurve.prototype.getPoint=function(a){var b=this.v2.clone().subSelf(this.v1);b.multiplyScalar(a).addSelf(this.v1);return b};
|
|
|
THREE.LineCurve.prototype.getPointAt=function(a){return this.getPoint(a)};THREE.LineCurve.prototype.getTangent=function(){return this.v2.clone().subSelf(this.v1).normalize()};THREE.QuadraticBezierCurve=function(a,b,c){this.v0=a;this.v1=b;this.v2=c};THREE.QuadraticBezierCurve.prototype=Object.create(THREE.Curve.prototype);
|
|
|
THREE.QuadraticBezierCurve.prototype.getPoint=function(a){var b;b=THREE.Shape.Utils.b2(a,this.v0.x,this.v1.x,this.v2.x);a=THREE.Shape.Utils.b2(a,this.v0.y,this.v1.y,this.v2.y);return new THREE.Vector2(b,a)};THREE.QuadraticBezierCurve.prototype.getTangent=function(a){var b;b=THREE.Curve.Utils.tangentQuadraticBezier(a,this.v0.x,this.v1.x,this.v2.x);a=THREE.Curve.Utils.tangentQuadraticBezier(a,this.v0.y,this.v1.y,this.v2.y);b=new THREE.Vector2(b,a);b.normalize();return b};
|