提交 195ba9cf 编写于 作者: M Mr.doob

BufferGeometry: Removed unused closure in computeBoundingBox.

上级 67ea2d53
......@@ -552,40 +552,34 @@ THREE.BufferGeometry.prototype = {
computeBoundingBox: function () {
var vector = new THREE.Vector3();
return function () {
if ( this.boundingBox === null ) {
if ( this.boundingBox === null ) {
this.boundingBox = new THREE.Box3();
this.boundingBox = new THREE.Box3();
}
var positions = this.attributes.position.array;
}
if ( positions ) {
var positions = this.attributes.position.array;
this.boundingBox.setFromArray( positions );
if ( positions ) {
}
this.boundingBox.setFromArray( positions );
if ( positions === undefined || positions.length === 0 ) {
}
this.boundingBox.min.set( 0, 0, 0 );
this.boundingBox.max.set( 0, 0, 0 );
if ( positions === undefined || positions.length === 0 ) {
}
this.boundingBox.min.set( 0, 0, 0 );
this.boundingBox.max.set( 0, 0, 0 );
if ( isNaN( this.boundingBox.min.x ) || isNaN( this.boundingBox.min.y ) || isNaN( this.boundingBox.min.z ) ) {
}
console.error( 'THREE.BufferGeometry.computeBoundingBox: Computed min/max have NaN values. The "position" attribute is likely to have NaN values.', this );
if ( isNaN( this.boundingBox.min.x ) || isNaN( this.boundingBox.min.y ) || isNaN( this.boundingBox.min.z ) ) {
}
console.error( 'THREE.BufferGeometry.computeBoundingBox: Computed min/max have NaN values. The "position" attribute is likely to have NaN values.', this );
};
}
}(),
},
computeBoundingSphere: function () {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册