|
@@ -16024,7 +16024,7 @@ function WebGLAttributes( gl ) {
|
|
|
|
|
|
} else if ( array instanceof Float64Array ) {
|
|
|
|
|
|
- console.warn( "Unsupported data buffer format: Float64Array" );
|
|
|
+ console.warn( 'THREE.WebGLAttributes: Unsupported data buffer format: Float64Array.' );
|
|
|
|
|
|
} else if ( array instanceof Uint16Array ) {
|
|
|
|
|
@@ -17335,10 +17335,10 @@ function WebGLProgram( renderer, code, material, parameters ) {
|
|
|
|
|
|
}
|
|
|
|
|
|
- vertexShader = parseIncludes( vertexShader, parameters );
|
|
|
+ vertexShader = parseIncludes( vertexShader );
|
|
|
vertexShader = replaceLightNums( vertexShader, parameters );
|
|
|
|
|
|
- fragmentShader = parseIncludes( fragmentShader, parameters );
|
|
|
+ fragmentShader = parseIncludes( fragmentShader );
|
|
|
fragmentShader = replaceLightNums( fragmentShader, parameters );
|
|
|
|
|
|
if ( ! material.isShaderMaterial ) {
|
|
@@ -19449,7 +19449,7 @@ function WebGLState( gl, extensions, paramThreeToGL ) {
|
|
|
|
|
|
} catch ( error ) {
|
|
|
|
|
|
- console.error( error );
|
|
|
+ console.error( 'THREE.WebGLState:', error );
|
|
|
|
|
|
}
|
|
|
|
|
@@ -19463,7 +19463,7 @@ function WebGLState( gl, extensions, paramThreeToGL ) {
|
|
|
|
|
|
} catch ( error ) {
|
|
|
|
|
|
- console.error( error );
|
|
|
+ console.error( 'THREE.WebGLState:', error );
|
|
|
|
|
|
}
|
|
|
|
|
@@ -22382,7 +22382,7 @@ function WebGLRenderer( parameters ) {
|
|
|
|
|
|
if ( textureUnit >= capabilities.maxTextures ) {
|
|
|
|
|
|
- console.warn( 'WebGLRenderer: trying to use ' + textureUnit + ' texture units while this GPU supports only ' + capabilities.maxTextures );
|
|
|
+ console.warn( 'THREE.WebGLRenderer: Trying to use ' + textureUnit + ' texture units while this GPU supports only ' + capabilities.maxTextures );
|
|
|
|
|
|
}
|
|
|
|
|
@@ -31207,7 +31207,7 @@ KeyframeTrackPrototype = {
|
|
|
|
|
|
}
|
|
|
|
|
|
- console.warn( message );
|
|
|
+ console.warn( 'THREE.KeyframeTrackPrototype:', message );
|
|
|
return;
|
|
|
|
|
|
}
|
|
@@ -31318,7 +31318,7 @@ KeyframeTrackPrototype = {
|
|
|
var valueSize = this.getValueSize();
|
|
|
if ( valueSize - Math.floor( valueSize ) !== 0 ) {
|
|
|
|
|
|
- console.error( "invalid value size in track", this );
|
|
|
+ console.error( 'THREE.KeyframeTrackPrototype: Invalid value size in track.', this );
|
|
|
valid = false;
|
|
|
|
|
|
}
|
|
@@ -31330,7 +31330,7 @@ KeyframeTrackPrototype = {
|
|
|
|
|
|
if ( nKeys === 0 ) {
|
|
|
|
|
|
- console.error( "track is empty", this );
|
|
|
+ console.error( 'THREE.KeyframeTrackPrototype: Track is empty.', this );
|
|
|
valid = false;
|
|
|
|
|
|
}
|
|
@@ -31343,7 +31343,7 @@ KeyframeTrackPrototype = {
|
|
|
|
|
|
if ( typeof currTime === 'number' && isNaN( currTime ) ) {
|
|
|
|
|
|
- console.error( "time is not a valid number", this, i, currTime );
|
|
|
+ console.error( 'THREE.KeyframeTrackPrototype: Time is not a valid number.', this, i, currTime );
|
|
|
valid = false;
|
|
|
break;
|
|
|
|
|
@@ -31351,7 +31351,7 @@ KeyframeTrackPrototype = {
|
|
|
|
|
|
if ( prevTime !== null && prevTime > currTime ) {
|
|
|
|
|
|
- console.error( "out of order keys", this, i, currTime, prevTime );
|
|
|
+ console.error( 'THREE.KeyframeTrackPrototype: Out of order keys.', this, i, currTime, prevTime );
|
|
|
valid = false;
|
|
|
break;
|
|
|
|
|
@@ -31371,7 +31371,7 @@ KeyframeTrackPrototype = {
|
|
|
|
|
|
if ( isNaN( value ) ) {
|
|
|
|
|
|
- console.error( "value is not a valid number", this, i, value );
|
|
|
+ console.error( 'THREE.KeyframeTrackPrototype: Value is not a valid number.', this, i, value );
|
|
|
valid = false;
|
|
|
break;
|
|
|
|
|
@@ -32070,7 +32070,7 @@ Object.assign( AnimationClip, {
|
|
|
|
|
|
if ( ! animation ) {
|
|
|
|
|
|
- console.error( " no animation in JSONLoader data" );
|
|
|
+ console.error( 'THREE.AnimationClip: No animation in JSONLoader data.' );
|
|
|
return null;
|
|
|
|
|
|
}
|
|
@@ -37247,7 +37247,7 @@ Object.assign( PropertyBinding.prototype, { // prototype, continued
|
|
|
// ensure there is a value node
|
|
|
if ( ! targetObject ) {
|
|
|
|
|
|
- console.error( " trying to update node for track: " + this.path + " but it wasn't found." );
|
|
|
+ console.error( 'THREE.PropertyBinding: Trying to update node for track: ' + this.path + ' but it wasn\'t found.' );
|
|
|
return;
|
|
|
|
|
|
}
|
|
@@ -37263,14 +37263,14 @@ Object.assign( PropertyBinding.prototype, { // prototype, continued
|
|
|
|
|
|
if ( ! targetObject.material ) {
|
|
|
|
|
|
- console.error( ' can not bind to material as node does not have a material', this );
|
|
|
+ console.error( 'THREE.PropertyBinding: Can not bind to material as node does not have a material.', this );
|
|
|
return;
|
|
|
|
|
|
}
|
|
|
|
|
|
if ( ! targetObject.material.materials ) {
|
|
|
|
|
|
- console.error( ' can not bind to material.materials as node.material does not have a materials array', this );
|
|
|
+ console.error( 'THREE.PropertyBinding: Can not bind to material.materials as node.material does not have a materials array.', this );
|
|
|
return;
|
|
|
|
|
|
}
|
|
@@ -37283,7 +37283,7 @@ Object.assign( PropertyBinding.prototype, { // prototype, continued
|
|
|
|
|
|
if ( ! targetObject.skeleton ) {
|
|
|
|
|
|
- console.error( ' can not bind to bones as node does not have a skeleton', this );
|
|
|
+ console.error( 'THREE.PropertyBinding: Can not bind to bones as node does not have a skeleton.', this );
|
|
|
return;
|
|
|
|
|
|
}
|
|
@@ -37311,7 +37311,7 @@ Object.assign( PropertyBinding.prototype, { // prototype, continued
|
|
|
|
|
|
if ( targetObject[ objectName ] === undefined ) {
|
|
|
|
|
|
- console.error( ' can not bind to objectName of node, undefined', this );
|
|
|
+ console.error( 'THREE.PropertyBinding: Can not bind to objectName of node undefined.', this );
|
|
|
return;
|
|
|
|
|
|
}
|
|
@@ -37325,7 +37325,7 @@ Object.assign( PropertyBinding.prototype, { // prototype, continued
|
|
|
|
|
|
if ( targetObject[ objectIndex ] === undefined ) {
|
|
|
|
|
|
- console.error( " trying to bind to objectIndex of objectName, but is undefined:", this, targetObject );
|
|
|
+ console.error( 'THREE.PropertyBinding: Trying to bind to objectIndex of objectName, but is undefined.', this, targetObject );
|
|
|
return;
|
|
|
|
|
|
}
|
|
@@ -37343,8 +37343,8 @@ Object.assign( PropertyBinding.prototype, { // prototype, continued
|
|
|
|
|
|
var nodeName = parsedPath.nodeName;
|
|
|
|
|
|
- console.error( " trying to update property for track: " + nodeName +
|
|
|
- '.' + propertyName + " but it wasn't found.", targetObject );
|
|
|
+ console.error( 'THREE.PropertyBinding: Trying to update property for track: ' + nodeName +
|
|
|
+ '.' + propertyName + ' but it wasn\'t found.', targetObject );
|
|
|
return;
|
|
|
|
|
|
}
|
|
@@ -37378,7 +37378,7 @@ Object.assign( PropertyBinding.prototype, { // prototype, continued
|
|
|
// support resolving morphTarget names into indices.
|
|
|
if ( ! targetObject.geometry ) {
|
|
|
|
|
|
- console.error( ' can not bind to morphTargetInfluences becasuse node does not have a geometry', this );
|
|
|
+ console.error( 'THREE.PropertyBinding: Can not bind to morphTargetInfluences because node does not have a geometry.', this );
|
|
|
return;
|
|
|
|
|
|
}
|
|
@@ -37387,7 +37387,7 @@ Object.assign( PropertyBinding.prototype, { // prototype, continued
|
|
|
|
|
|
if ( ! targetObject.geometry.morphAttributes ) {
|
|
|
|
|
|
- console.error( ' can not bind to morphTargetInfluences becasuse node does not have a geometry.morphAttributes', this );
|
|
|
+ console.error( 'THREE.PropertyBinding: Can not bind to morphTargetInfluences because node does not have a geometry.morphAttributes.', this );
|
|
|
return;
|
|
|
|
|
|
}
|
|
@@ -37408,7 +37408,7 @@ Object.assign( PropertyBinding.prototype, { // prototype, continued
|
|
|
|
|
|
if ( ! targetObject.geometry.morphTargets ) {
|
|
|
|
|
|
- console.error( ' can not bind to morphTargetInfluences becasuse node does not have a geometry.morphTargets', this );
|
|
|
+ console.error( 'THREE.PropertyBinding: Can not bind to morphTargetInfluences because node does not have a geometry.morphTargets.', this );
|
|
|
return;
|
|
|
|
|
|
}
|
|
@@ -37633,9 +37633,8 @@ Object.assign( AnimationObjectGroup.prototype, {
|
|
|
|
|
|
} else if ( objects[ index ] !== knownObject ) {
|
|
|
|
|
|
- console.error( "Different objects with the same UUID " +
|
|
|
- "detected. Clean the caches or recreate your " +
|
|
|
- "infrastructure when reloading scenes..." );
|
|
|
+ console.error( 'THREE.AnimationObjectGroup: Different objects with the same UUID ' +
|
|
|
+ 'detected. Clean the caches or recreate your infrastructure when reloading scenes.' );
|
|
|
|
|
|
} // else the object is already where we want it to be
|
|
|
|
|
@@ -41699,11 +41698,13 @@ var px = new CubicPoly();
|
|
|
var py = new CubicPoly();
|
|
|
var pz = new CubicPoly();
|
|
|
|
|
|
-function CatmullRomCurve3( p /* array of Vector3 */ ) {
|
|
|
+function CatmullRomCurve3( points ) {
|
|
|
|
|
|
Curve.call( this );
|
|
|
|
|
|
- this.points = p || [];
|
|
|
+ if ( points.length < 2 ) console.warn( 'THREE.CatmullRomCurve3: Points array needs at least two entries.' );
|
|
|
+
|
|
|
+ this.points = points || [];
|
|
|
this.closed = false;
|
|
|
|
|
|
}
|
|
@@ -41716,8 +41717,6 @@ CatmullRomCurve3.prototype.getPoint = function ( t ) {
|
|
|
var points = this.points;
|
|
|
var l = points.length;
|
|
|
|
|
|
- if ( l < 2 ) console.log( 'duh, you need at least 2 points' );
|
|
|
-
|
|
|
var point = ( l - ( this.closed ? 0 : 1 ) ) * t;
|
|
|
var intPoint = Math.floor( point );
|
|
|
var weight = point - intPoint;
|