瀏覽代碼

Updated builds.

Mr.doob 3 年之前
父節點
當前提交
599453bdcb
共有 4 個文件被更改,包括 39 次插入321 次删除
  1. 13 95
      build/three.cjs
  2. 13 95
      build/three.js
  3. 0 0
      build/three.min.js
  4. 13 131
      build/three.module.js

+ 13 - 95
build/three.cjs

@@ -569,12 +569,7 @@ class Vector2 {
 		return this;
 	}
 
-	add(v, w) {
-		if (w !== undefined) {
-			console.warn('THREE.Vector2: .add() now only accepts one argument. Use .addVectors( a, b ) instead.');
-			return this.addVectors(v, w);
-		}
-
+	add(v) {
 		this.x += v.x;
 		this.y += v.y;
 		return this;
@@ -598,12 +593,7 @@ class Vector2 {
 		return this;
 	}
 
-	sub(v, w) {
-		if (w !== undefined) {
-			console.warn('THREE.Vector2: .sub() now only accepts one argument. Use .subVectors( a, b ) instead.');
-			return this.subVectors(v, w);
-		}
-
+	sub(v) {
 		this.x -= v.x;
 		this.y -= v.y;
 		return this;
@@ -788,11 +778,7 @@ class Vector2 {
 		return array;
 	}
 
-	fromBufferAttribute(attribute, index, offset) {
-		if (offset !== undefined) {
-			console.warn('THREE.Vector2: offset has been removed from .fromBufferAttribute().');
-		}
-
+	fromBufferAttribute(attribute, index) {
 		this.x = attribute.getX(index);
 		this.y = attribute.getY(index);
 		return this;
@@ -825,10 +811,6 @@ class Matrix3 {
 	constructor() {
 		Matrix3.prototype.isMatrix3 = true;
 		this.elements = [1, 0, 0, 0, 1, 0, 0, 0, 1];
-
-		if (arguments.length > 0) {
-			console.error('THREE.Matrix3: the constructor no longer reads arguments. use .set() instead.');
-		}
 	}
 
 	set(n11, n12, n13, n21, n22, n23, n31, n32, n33) {
@@ -2231,12 +2213,7 @@ class Vector4 {
 		return this;
 	}
 
-	add(v, w) {
-		if (w !== undefined) {
-			console.warn('THREE.Vector4: .add() now only accepts one argument. Use .addVectors( a, b ) instead.');
-			return this.addVectors(v, w);
-		}
-
+	add(v) {
 		this.x += v.x;
 		this.y += v.y;
 		this.z += v.z;
@@ -2268,12 +2245,7 @@ class Vector4 {
 		return this;
 	}
 
-	sub(v, w) {
-		if (w !== undefined) {
-			console.warn('THREE.Vector4: .sub() now only accepts one argument. Use .subVectors( a, b ) instead.');
-			return this.subVectors(v, w);
-		}
-
+	sub(v) {
 		this.x -= v.x;
 		this.y -= v.y;
 		this.z -= v.z;
@@ -2578,11 +2550,7 @@ class Vector4 {
 		return array;
 	}
 
-	fromBufferAttribute(attribute, index, offset) {
-		if (offset !== undefined) {
-			console.warn('THREE.Vector4: offset has been removed from .fromBufferAttribute().');
-		}
-
+	fromBufferAttribute(attribute, index) {
 		this.x = attribute.getX(index);
 		this.y = attribute.getY(index);
 		this.z = attribute.getZ(index);
@@ -3187,12 +3155,7 @@ class Quaternion {
 		return this;
 	}
 
-	multiply(q, p) {
-		if (p !== undefined) {
-			console.warn('THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead.');
-			return this.multiplyQuaternions(q, p);
-		}
-
+	multiply(q) {
 		return this.multiplyQuaternions(this, q);
 	}
 
@@ -3427,12 +3390,7 @@ class Vector3 {
 		return this;
 	}
 
-	add(v, w) {
-		if (w !== undefined) {
-			console.warn('THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead.');
-			return this.addVectors(v, w);
-		}
-
+	add(v) {
 		this.x += v.x;
 		this.y += v.y;
 		this.z += v.z;
@@ -3460,12 +3418,7 @@ class Vector3 {
 		return this;
 	}
 
-	sub(v, w) {
-		if (w !== undefined) {
-			console.warn('THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead.');
-			return this.subVectors(v, w);
-		}
-
+	sub(v) {
 		this.x -= v.x;
 		this.y -= v.y;
 		this.z -= v.z;
@@ -3486,12 +3439,7 @@ class Vector3 {
 		return this;
 	}
 
-	multiply(v, w) {
-		if (w !== undefined) {
-			console.warn('THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead.');
-			return this.multiplyVectors(v, w);
-		}
-
+	multiply(v) {
 		this.x *= v.x;
 		this.y *= v.y;
 		this.z *= v.z;
@@ -3513,10 +3461,6 @@ class Vector3 {
 	}
 
 	applyEuler(euler) {
-		if (!(euler && euler.isEuler)) {
-			console.error('THREE.Vector3: .applyEuler() now expects an Euler rotation rather than a Vector3 and order.');
-		}
-
 		return this.applyQuaternion(_quaternion$4.setFromEuler(euler));
 	}
 
@@ -3711,12 +3655,7 @@ class Vector3 {
 		return this;
 	}
 
-	cross(v, w) {
-		if (w !== undefined) {
-			console.warn('THREE.Vector3: .cross() now only accepts one argument. Use .crossVectors( a, b ) instead.');
-			return this.crossVectors(v, w);
-		}
-
+	cross(v) {
 		return this.crossVectors(this, v);
 	}
 
@@ -3849,11 +3788,7 @@ class Vector3 {
 		return array;
 	}
 
-	fromBufferAttribute(attribute, index, offset) {
-		if (offset !== undefined) {
-			console.warn('THREE.Vector3: offset has been removed from .fromBufferAttribute().');
-		}
-
+	fromBufferAttribute(attribute, index) {
 		this.x = attribute.getX(index);
 		this.y = attribute.getY(index);
 		this.z = attribute.getZ(index);
@@ -4807,10 +4742,6 @@ class Matrix4 {
 	constructor() {
 		Matrix4.prototype.isMatrix4 = true;
 		this.elements = [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1];
-
-		if (arguments.length > 0) {
-			console.error('THREE.Matrix4: the constructor no longer reads arguments. use .set() instead.');
-		}
 	}
 
 	set(n11, n12, n13, n14, n21, n22, n23, n24, n31, n32, n33, n34, n41, n42, n43, n44) {
@@ -4923,10 +4854,6 @@ class Matrix4 {
 	}
 
 	makeRotationFromEuler(euler) {
-		if (!(euler && euler.isEuler)) {
-			console.error('THREE.Matrix4: .makeRotationFromEuler() now expects a Euler rotation rather than a Vector3 and order.');
-		}
-
 		const te = this.elements;
 		const x = euler.x,
 					y = euler.y,
@@ -5083,12 +5010,7 @@ class Matrix4 {
 		return this;
 	}
 
-	multiply(m, n) {
-		if (n !== undefined) {
-			console.warn('THREE.Matrix4: .multiply() now only accepts one argument. Use .multiplyMatrices( a, b ) instead.');
-			return this.multiplyMatrices(m, n);
-		}
-
+	multiply(m) {
 		return this.multiplyMatrices(this, m);
 	}
 
@@ -5436,10 +5358,6 @@ class Matrix4 {
 	}
 
 	makePerspective(left, right, top, bottom, near, far) {
-		if (far === undefined) {
-			console.warn('THREE.Matrix4: .makePerspective() has been redefined and has a new signature. Please check the docs.');
-		}
-
 		const te = this.elements;
 		const x = 2 * near / (right - left);
 		const y = 2 * near / (top - bottom);

+ 13 - 95
build/three.js

@@ -571,12 +571,7 @@
 			return this;
 		}
 
-		add(v, w) {
-			if (w !== undefined) {
-				console.warn('THREE.Vector2: .add() now only accepts one argument. Use .addVectors( a, b ) instead.');
-				return this.addVectors(v, w);
-			}
-
+		add(v) {
 			this.x += v.x;
 			this.y += v.y;
 			return this;
@@ -600,12 +595,7 @@
 			return this;
 		}
 
-		sub(v, w) {
-			if (w !== undefined) {
-				console.warn('THREE.Vector2: .sub() now only accepts one argument. Use .subVectors( a, b ) instead.');
-				return this.subVectors(v, w);
-			}
-
+		sub(v) {
 			this.x -= v.x;
 			this.y -= v.y;
 			return this;
@@ -790,11 +780,7 @@
 			return array;
 		}
 
-		fromBufferAttribute(attribute, index, offset) {
-			if (offset !== undefined) {
-				console.warn('THREE.Vector2: offset has been removed from .fromBufferAttribute().');
-			}
-
+		fromBufferAttribute(attribute, index) {
 			this.x = attribute.getX(index);
 			this.y = attribute.getY(index);
 			return this;
@@ -827,10 +813,6 @@
 		constructor() {
 			Matrix3.prototype.isMatrix3 = true;
 			this.elements = [1, 0, 0, 0, 1, 0, 0, 0, 1];
-
-			if (arguments.length > 0) {
-				console.error('THREE.Matrix3: the constructor no longer reads arguments. use .set() instead.');
-			}
 		}
 
 		set(n11, n12, n13, n21, n22, n23, n31, n32, n33) {
@@ -2233,12 +2215,7 @@
 			return this;
 		}
 
-		add(v, w) {
-			if (w !== undefined) {
-				console.warn('THREE.Vector4: .add() now only accepts one argument. Use .addVectors( a, b ) instead.');
-				return this.addVectors(v, w);
-			}
-
+		add(v) {
 			this.x += v.x;
 			this.y += v.y;
 			this.z += v.z;
@@ -2270,12 +2247,7 @@
 			return this;
 		}
 
-		sub(v, w) {
-			if (w !== undefined) {
-				console.warn('THREE.Vector4: .sub() now only accepts one argument. Use .subVectors( a, b ) instead.');
-				return this.subVectors(v, w);
-			}
-
+		sub(v) {
 			this.x -= v.x;
 			this.y -= v.y;
 			this.z -= v.z;
@@ -2580,11 +2552,7 @@
 			return array;
 		}
 
-		fromBufferAttribute(attribute, index, offset) {
-			if (offset !== undefined) {
-				console.warn('THREE.Vector4: offset has been removed from .fromBufferAttribute().');
-			}
-
+		fromBufferAttribute(attribute, index) {
 			this.x = attribute.getX(index);
 			this.y = attribute.getY(index);
 			this.z = attribute.getZ(index);
@@ -3189,12 +3157,7 @@
 			return this;
 		}
 
-		multiply(q, p) {
-			if (p !== undefined) {
-				console.warn('THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead.');
-				return this.multiplyQuaternions(q, p);
-			}
-
+		multiply(q) {
 			return this.multiplyQuaternions(this, q);
 		}
 
@@ -3429,12 +3392,7 @@
 			return this;
 		}
 
-		add(v, w) {
-			if (w !== undefined) {
-				console.warn('THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead.');
-				return this.addVectors(v, w);
-			}
-
+		add(v) {
 			this.x += v.x;
 			this.y += v.y;
 			this.z += v.z;
@@ -3462,12 +3420,7 @@
 			return this;
 		}
 
-		sub(v, w) {
-			if (w !== undefined) {
-				console.warn('THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead.');
-				return this.subVectors(v, w);
-			}
-
+		sub(v) {
 			this.x -= v.x;
 			this.y -= v.y;
 			this.z -= v.z;
@@ -3488,12 +3441,7 @@
 			return this;
 		}
 
-		multiply(v, w) {
-			if (w !== undefined) {
-				console.warn('THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead.');
-				return this.multiplyVectors(v, w);
-			}
-
+		multiply(v) {
 			this.x *= v.x;
 			this.y *= v.y;
 			this.z *= v.z;
@@ -3515,10 +3463,6 @@
 		}
 
 		applyEuler(euler) {
-			if (!(euler && euler.isEuler)) {
-				console.error('THREE.Vector3: .applyEuler() now expects an Euler rotation rather than a Vector3 and order.');
-			}
-
 			return this.applyQuaternion(_quaternion$4.setFromEuler(euler));
 		}
 
@@ -3713,12 +3657,7 @@
 			return this;
 		}
 
-		cross(v, w) {
-			if (w !== undefined) {
-				console.warn('THREE.Vector3: .cross() now only accepts one argument. Use .crossVectors( a, b ) instead.');
-				return this.crossVectors(v, w);
-			}
-
+		cross(v) {
 			return this.crossVectors(this, v);
 		}
 
@@ -3851,11 +3790,7 @@
 			return array;
 		}
 
-		fromBufferAttribute(attribute, index, offset) {
-			if (offset !== undefined) {
-				console.warn('THREE.Vector3: offset has been removed from .fromBufferAttribute().');
-			}
-
+		fromBufferAttribute(attribute, index) {
 			this.x = attribute.getX(index);
 			this.y = attribute.getY(index);
 			this.z = attribute.getZ(index);
@@ -4809,10 +4744,6 @@
 		constructor() {
 			Matrix4.prototype.isMatrix4 = true;
 			this.elements = [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1];
-
-			if (arguments.length > 0) {
-				console.error('THREE.Matrix4: the constructor no longer reads arguments. use .set() instead.');
-			}
 		}
 
 		set(n11, n12, n13, n14, n21, n22, n23, n24, n31, n32, n33, n34, n41, n42, n43, n44) {
@@ -4925,10 +4856,6 @@
 		}
 
 		makeRotationFromEuler(euler) {
-			if (!(euler && euler.isEuler)) {
-				console.error('THREE.Matrix4: .makeRotationFromEuler() now expects a Euler rotation rather than a Vector3 and order.');
-			}
-
 			const te = this.elements;
 			const x = euler.x,
 						y = euler.y,
@@ -5085,12 +5012,7 @@
 			return this;
 		}
 
-		multiply(m, n) {
-			if (n !== undefined) {
-				console.warn('THREE.Matrix4: .multiply() now only accepts one argument. Use .multiplyMatrices( a, b ) instead.');
-				return this.multiplyMatrices(m, n);
-			}
-
+		multiply(m) {
 			return this.multiplyMatrices(this, m);
 		}
 
@@ -5438,10 +5360,6 @@
 		}
 
 		makePerspective(left, right, top, bottom, near, far) {
-			if (far === undefined) {
-				console.warn('THREE.Matrix4: .makePerspective() has been redefined and has a new signature. Please check the docs.');
-			}
-
 			const te = this.elements;
 			const x = 2 * near / (right - left);
 			const y = 2 * near / (top - bottom);

文件差異過大導致無法顯示
+ 0 - 0
build/three.min.js


+ 13 - 131
build/three.module.js

@@ -703,14 +703,7 @@ class Vector2 {
 
 	}
 
-	add( v, w ) {
-
-		if ( w !== undefined ) {
-
-			console.warn( 'THREE.Vector2: .add() now only accepts one argument. Use .addVectors( a, b ) instead.' );
-			return this.addVectors( v, w );
-
-		}
+	add( v ) {
 
 		this.x += v.x;
 		this.y += v.y;
@@ -746,14 +739,7 @@ class Vector2 {
 
 	}
 
-	sub( v, w ) {
-
-		if ( w !== undefined ) {
-
-			console.warn( 'THREE.Vector2: .sub() now only accepts one argument. Use .subVectors( a, b ) instead.' );
-			return this.subVectors( v, w );
-
-		}
+	sub( v ) {
 
 		this.x -= v.x;
 		this.y -= v.y;
@@ -1029,13 +1015,7 @@ class Vector2 {
 
 	}
 
-	fromBufferAttribute( attribute, index, offset ) {
-
-		if ( offset !== undefined ) {
-
-			console.warn( 'THREE.Vector2: offset has been removed from .fromBufferAttribute().' );
-
-		}
+	fromBufferAttribute( attribute, index ) {
 
 		this.x = attribute.getX( index );
 		this.y = attribute.getY( index );
@@ -1090,12 +1070,6 @@ class Matrix3 {
 
 		];
 
-		if ( arguments.length > 0 ) {
-
-			console.error( 'THREE.Matrix3: the constructor no longer reads arguments. use .set() instead.' );
-
-		}
-
 	}
 
 	set( n11, n12, n13, n21, n22, n23, n31, n32, n33 ) {
@@ -2807,14 +2781,7 @@ class Vector4 {
 
 	}
 
-	add( v, w ) {
-
-		if ( w !== undefined ) {
-
-			console.warn( 'THREE.Vector4: .add() now only accepts one argument. Use .addVectors( a, b ) instead.' );
-			return this.addVectors( v, w );
-
-		}
+	add( v ) {
 
 		this.x += v.x;
 		this.y += v.y;
@@ -2858,14 +2825,7 @@ class Vector4 {
 
 	}
 
-	sub( v, w ) {
-
-		if ( w !== undefined ) {
-
-			console.warn( 'THREE.Vector4: .sub() now only accepts one argument. Use .subVectors( a, b ) instead.' );
-			return this.subVectors( v, w );
-
-		}
+	sub( v ) {
 
 		this.x -= v.x;
 		this.y -= v.y;
@@ -3293,13 +3253,7 @@ class Vector4 {
 
 	}
 
-	fromBufferAttribute( attribute, index, offset ) {
-
-		if ( offset !== undefined ) {
-
-			console.warn( 'THREE.Vector4: offset has been removed from .fromBufferAttribute().' );
-
-		}
+	fromBufferAttribute( attribute, index ) {
 
 		this.x = attribute.getX( index );
 		this.y = attribute.getY( index );
@@ -4094,14 +4048,7 @@ class Quaternion {
 
 	}
 
-	multiply( q, p ) {
-
-		if ( p !== undefined ) {
-
-			console.warn( 'THREE.Quaternion: .multiply() now only accepts one argument. Use .multiplyQuaternions( a, b ) instead.' );
-			return this.multiplyQuaternions( q, p );
-
-		}
+	multiply( q ) {
 
 		return this.multiplyQuaternions( this, q );
 
@@ -4394,14 +4341,7 @@ class Vector3 {
 
 	}
 
-	add( v, w ) {
-
-		if ( w !== undefined ) {
-
-			console.warn( 'THREE.Vector3: .add() now only accepts one argument. Use .addVectors( a, b ) instead.' );
-			return this.addVectors( v, w );
-
-		}
+	add( v ) {
 
 		this.x += v.x;
 		this.y += v.y;
@@ -4441,14 +4381,7 @@ class Vector3 {
 
 	}
 
-	sub( v, w ) {
-
-		if ( w !== undefined ) {
-
-			console.warn( 'THREE.Vector3: .sub() now only accepts one argument. Use .subVectors( a, b ) instead.' );
-			return this.subVectors( v, w );
-
-		}
+	sub( v ) {
 
 		this.x -= v.x;
 		this.y -= v.y;
@@ -4478,14 +4411,7 @@ class Vector3 {
 
 	}
 
-	multiply( v, w ) {
-
-		if ( w !== undefined ) {
-
-			console.warn( 'THREE.Vector3: .multiply() now only accepts one argument. Use .multiplyVectors( a, b ) instead.' );
-			return this.multiplyVectors( v, w );
-
-		}
+	multiply( v ) {
 
 		this.x *= v.x;
 		this.y *= v.y;
@@ -4517,12 +4443,6 @@ class Vector3 {
 
 	applyEuler( euler ) {
 
-		if ( ! ( euler && euler.isEuler ) ) {
-
-			console.error( 'THREE.Vector3: .applyEuler() now expects an Euler rotation rather than a Vector3 and order.' );
-
-		}
-
 		return this.applyQuaternion( _quaternion$4.setFromEuler( euler ) );
 
 	}
@@ -4791,14 +4711,7 @@ class Vector3 {
 
 	}
 
-	cross( v, w ) {
-
-		if ( w !== undefined ) {
-
-			console.warn( 'THREE.Vector3: .cross() now only accepts one argument. Use .crossVectors( a, b ) instead.' );
-			return this.crossVectors( v, w );
-
-		}
+	cross( v ) {
 
 		return this.crossVectors( this, v );
 
@@ -4988,13 +4901,7 @@ class Vector3 {
 
 	}
 
-	fromBufferAttribute( attribute, index, offset ) {
-
-		if ( offset !== undefined ) {
-
-			console.warn( 'THREE.Vector3: offset has been removed from .fromBufferAttribute().' );
-
-		}
+	fromBufferAttribute( attribute, index ) {
 
 		this.x = attribute.getX( index );
 		this.y = attribute.getY( index );
@@ -6304,12 +6211,6 @@ class Matrix4 {
 
 		];
 
-		if ( arguments.length > 0 ) {
-
-			console.error( 'THREE.Matrix4: the constructor no longer reads arguments. use .set() instead.' );
-
-		}
-
 	}
 
 	set( n11, n12, n13, n14, n21, n22, n23, n24, n31, n32, n33, n34, n41, n42, n43, n44 ) {
@@ -6449,12 +6350,6 @@ class Matrix4 {
 
 	makeRotationFromEuler( euler ) {
 
-		if ( ! ( euler && euler.isEuler ) ) {
-
-			console.error( 'THREE.Matrix4: .makeRotationFromEuler() now expects a Euler rotation rather than a Vector3 and order.' );
-
-		}
-
 		const te = this.elements;
 
 		const x = euler.x, y = euler.y, z = euler.z;
@@ -6628,14 +6523,7 @@ class Matrix4 {
 
 	}
 
-	multiply( m, n ) {
-
-		if ( n !== undefined ) {
-
-			console.warn( 'THREE.Matrix4: .multiply() now only accepts one argument. Use .multiplyMatrices( a, b ) instead.' );
-			return this.multiplyMatrices( m, n );
-
-		}
+	multiply( m ) {
 
 		return this.multiplyMatrices( this, m );
 
@@ -7062,12 +6950,6 @@ class Matrix4 {
 
 	makePerspective( left, right, top, bottom, near, far ) {
 
-		if ( far === undefined ) {
-
-			console.warn( 'THREE.Matrix4: .makePerspective() has been redefined and has a new signature. Please check the docs.' );
-
-		}
-
 		const te = this.elements;
 		const x = 2 * near / ( right - left );
 		const y = 2 * near / ( top - bottom );

部分文件因文件數量過多而無法顯示