Browse Source

removed redundant check from FontUtils

Juergen Ahting 11 years ago
parent
commit
57f068d43f
3 changed files with 208 additions and 207 deletions
  1. 11 8
      build/three.js
  2. 197 197
      build/three.min.js
  3. 0 2
      src/extras/FontUtils.js

+ 11 - 8
build/three.js

@@ -6242,11 +6242,7 @@ THREE.Math = {
 
 
 		};
 		};
 
 
-	}(),
-
-	isPowerOfTwo: function ( value ) {
-		return ( value & ( value - 1 ) ) === 0 && value !== 0;
-	}
+	}()
 
 
 };
 };
 
 
@@ -25568,6 +25564,13 @@ THREE.WebGLRenderer = function ( parameters ) {
 
 
 	// Textures
 	// Textures
 
 
+
+	function isPowerOfTwo ( value ) {
+
+		return ( value & ( value - 1 ) ) === 0;
+
+	};
+
 	function setTextureParameters ( textureType, texture, isImagePowerOfTwo ) {
 	function setTextureParameters ( textureType, texture, isImagePowerOfTwo ) {
 
 
 		if ( isImagePowerOfTwo ) {
 		if ( isImagePowerOfTwo ) {
@@ -25625,7 +25628,7 @@ THREE.WebGLRenderer = function ( parameters ) {
 			_gl.pixelStorei( _gl.UNPACK_ALIGNMENT, texture.unpackAlignment );
 			_gl.pixelStorei( _gl.UNPACK_ALIGNMENT, texture.unpackAlignment );
 
 
 			var image = texture.image,
 			var image = texture.image,
-			isImagePowerOfTwo = THREE.Math.isPowerOfTwo( image.width ) && THREE.Math.isPowerOfTwo( image.height ),
+			isImagePowerOfTwo = isPowerOfTwo( image.width ) && isPowerOfTwo( image.height ),
 			glFormat = paramThreeToGL( texture.format ),
 			glFormat = paramThreeToGL( texture.format ),
 			glType = paramThreeToGL( texture.type );
 			glType = paramThreeToGL( texture.type );
 
 
@@ -25775,7 +25778,7 @@ THREE.WebGLRenderer = function ( parameters ) {
 				}
 				}
 
 
 				var image = cubeImage[ 0 ],
 				var image = cubeImage[ 0 ],
-				isImagePowerOfTwo = THREE.Math.isPowerOfTwo( image.width ) && THREE.Math.isPowerOfTwo( image.height ),
+				isImagePowerOfTwo = isPowerOfTwo( image.width ) && isPowerOfTwo( image.height ),
 				glFormat = paramThreeToGL( texture.format ),
 				glFormat = paramThreeToGL( texture.format ),
 				glType = paramThreeToGL( texture.type );
 				glType = paramThreeToGL( texture.type );
 
 
@@ -25888,7 +25891,7 @@ THREE.WebGLRenderer = function ( parameters ) {
 
 
 			// Setup texture, create render and frame buffers
 			// Setup texture, create render and frame buffers
 
 
-			var isTargetPowerOfTwo = THREE.Math.isPowerOfTwo( renderTarget.width ) && THREE.Math.isPowerOfTwo( renderTarget.height ),
+			var isTargetPowerOfTwo = isPowerOfTwo( renderTarget.width ) && isPowerOfTwo( renderTarget.height ),
 				glFormat = paramThreeToGL( renderTarget.format ),
 				glFormat = paramThreeToGL( renderTarget.format ),
 				glType = paramThreeToGL( renderTarget.type );
 				glType = paramThreeToGL( renderTarget.type );
 
 

File diff suppressed because it is too large
+ 197 - 197
build/three.min.js


+ 0 - 2
src/extras/FontUtils.js

@@ -424,8 +424,6 @@ THREE.FontUtils.generateShapes = function( text, parameters ) {
 
 
 		for ( p = 0; p < n; p++ ) {
 		for ( p = 0; p < n; p++ ) {
 
 
-			if( (p === u) || (p === v) || (p === w) ) continue;
-
 			px = contour[ verts[ p ] ].x
 			px = contour[ verts[ p ] ].x
 			py = contour[ verts[ p ] ].y
 			py = contour[ verts[ p ] ].y
 
 

Some files were not shown because too many files changed in this diff