Browse Source

Updated builds.

Mr.doob 8 years ago
parent
commit
6293f5eea3
2 changed files with 22 additions and 18 deletions
  1. 11 9
      build/three.js
  2. 11 9
      build/three.module.js

+ 11 - 9
build/three.js

@@ -30020,13 +30020,13 @@
 	var AnimationUtils = {
 
 		// same as Array.prototype.slice, but also works on typed arrays
-		arraySlice: function( array, from, to ) {
+		arraySlice: function ( array, from, to ) {
 
 			if ( AnimationUtils.isTypedArray( array ) ) {
 
 				// in ios9 array.subarray(from, undefined) will return empty array
 				// but array.subarray(from) or array.subarray(from, len) is correct
-				return new array.constructor( array.subarray( from, to || array.length ) );
+				return new array.constructor( array.subarray( from, to !== undefined ? to : array.length ) );
 
 			}
 
@@ -30035,7 +30035,7 @@
 		},
 
 		// converts an array to a specific type
-		convertArray: function( array, type, forceClone ) {
+		convertArray: function ( array, type, forceClone ) {
 
 			if ( ! array || // let 'undefined' and 'null' pass
 					! forceClone && array.constructor === type ) return array;
@@ -30050,7 +30050,7 @@
 
 		},
 
-		isTypedArray: function( object ) {
+		isTypedArray: function ( object ) {
 
 			return ArrayBuffer.isView( object ) &&
 					! ( object instanceof DataView );
@@ -30058,7 +30058,7 @@
 		},
 
 		// returns an array by which times and values can be sorted
-		getKeyframeOrder: function( times ) {
+		getKeyframeOrder: function ( times ) {
 
 			function compareTime( i, j ) {
 
@@ -30077,7 +30077,7 @@
 		},
 
 		// uses the array previously returned by 'getKeyframeOrder' to sort data
-		sortedArray: function( values, stride, order ) {
+		sortedArray: function ( values, stride, order ) {
 
 			var nValues = values.length;
 			var result = new values.constructor( nValues );
@@ -30099,7 +30099,7 @@
 		},
 
 		// function for parsing AOS keyframe formats
-		flattenJSON: function( jsonKeys, times, values, valuePropertyName ) {
+		flattenJSON: function ( jsonKeys, times, values, valuePropertyName ) {
 
 			var i = 1, key = jsonKeys[ 0 ];
 
@@ -30132,6 +30132,7 @@
 				} while ( key !== undefined );
 
 			} else if ( value.toArray !== undefined ) {
+
 				// ...assume THREE.Math-ish
 
 				do {
@@ -30150,6 +30151,7 @@
 				} while ( key !== undefined );
 
 			} else {
+
 				// otherwise push as-is
 
 				do {
@@ -31004,9 +31006,9 @@
 
 	function KeyframeTrackConstructor( name, times, values, interpolation ) {
 
-		if( name === undefined ) throw new Error( "track name is undefined" );
+		if ( name === undefined ) throw new Error( "track name is undefined" );
 
-		if( times === undefined || times.length === 0 ) {
+		if ( times === undefined || times.length === 0 ) {
 
 			throw new Error( "no keyframes in track named " + name );
 

+ 11 - 9
build/three.module.js

@@ -30014,13 +30014,13 @@ AmbientLight.prototype = Object.assign( Object.create( Light.prototype ), {
 var AnimationUtils = {
 
 	// same as Array.prototype.slice, but also works on typed arrays
-	arraySlice: function( array, from, to ) {
+	arraySlice: function ( array, from, to ) {
 
 		if ( AnimationUtils.isTypedArray( array ) ) {
 
 			// in ios9 array.subarray(from, undefined) will return empty array
 			// but array.subarray(from) or array.subarray(from, len) is correct
-			return new array.constructor( array.subarray( from, to || array.length ) );
+			return new array.constructor( array.subarray( from, to !== undefined ? to : array.length ) );
 
 		}
 
@@ -30029,7 +30029,7 @@ var AnimationUtils = {
 	},
 
 	// converts an array to a specific type
-	convertArray: function( array, type, forceClone ) {
+	convertArray: function ( array, type, forceClone ) {
 
 		if ( ! array || // let 'undefined' and 'null' pass
 				! forceClone && array.constructor === type ) return array;
@@ -30044,7 +30044,7 @@ var AnimationUtils = {
 
 	},
 
-	isTypedArray: function( object ) {
+	isTypedArray: function ( object ) {
 
 		return ArrayBuffer.isView( object ) &&
 				! ( object instanceof DataView );
@@ -30052,7 +30052,7 @@ var AnimationUtils = {
 	},
 
 	// returns an array by which times and values can be sorted
-	getKeyframeOrder: function( times ) {
+	getKeyframeOrder: function ( times ) {
 
 		function compareTime( i, j ) {
 
@@ -30071,7 +30071,7 @@ var AnimationUtils = {
 	},
 
 	// uses the array previously returned by 'getKeyframeOrder' to sort data
-	sortedArray: function( values, stride, order ) {
+	sortedArray: function ( values, stride, order ) {
 
 		var nValues = values.length;
 		var result = new values.constructor( nValues );
@@ -30093,7 +30093,7 @@ var AnimationUtils = {
 	},
 
 	// function for parsing AOS keyframe formats
-	flattenJSON: function( jsonKeys, times, values, valuePropertyName ) {
+	flattenJSON: function ( jsonKeys, times, values, valuePropertyName ) {
 
 		var i = 1, key = jsonKeys[ 0 ];
 
@@ -30126,6 +30126,7 @@ var AnimationUtils = {
 			} while ( key !== undefined );
 
 		} else if ( value.toArray !== undefined ) {
+
 			// ...assume THREE.Math-ish
 
 			do {
@@ -30144,6 +30145,7 @@ var AnimationUtils = {
 			} while ( key !== undefined );
 
 		} else {
+
 			// otherwise push as-is
 
 			do {
@@ -30998,9 +31000,9 @@ KeyframeTrackPrototype = {
 
 function KeyframeTrackConstructor( name, times, values, interpolation ) {
 
-	if( name === undefined ) throw new Error( "track name is undefined" );
+	if ( name === undefined ) throw new Error( "track name is undefined" );
 
-	if( times === undefined || times.length === 0 ) {
+	if ( times === undefined || times.length === 0 ) {
 
 		throw new Error( "no keyframes in track named " + name );