未验证 提交 715c7b1a 编写于 作者: M Michael Herzog 提交者: GitHub

Merge pull request #17654 from aardgoose/setarray-error

BufferAttribute and InterleavedBuffer .setArray() deprecated > removed
......@@ -1199,14 +1199,9 @@ Object.assign( BufferAttribute.prototype, {
console.error( 'THREE.BufferAttribute: .copyIndicesArray() has been removed.' );
},
setArray: function ( array ) {
setArray: function ( /* array */ ) {
console.warn( 'THREE.BufferAttribute: .setArray has been deprecated. Use BufferGeometry .setAttribute to replace/resize attribute buffers' );
this.count = array !== undefined ? array.length / this.itemSize : 0;
this.array = array;
return this;
console.error( 'THREE.BufferAttribute: .setArray has been removed. Use BufferGeometry .setAttribute to replace/resize attribute buffers' );
}
} );
......@@ -1297,14 +1292,9 @@ Object.assign( InterleavedBuffer.prototype, {
return this;
},
setArray: function ( array ) {
setArray: function ( /* array */ ) {
console.warn( 'THREE.InterleavedBuffer: .setArray has been deprecated. Use BufferGeometry .setAttribute to replace/resize attribute buffers' );
this.count = array !== undefined ? array.length / this.stride : 0;
this.array = array;
return this;
console.error( 'THREE.InterleavedBuffer: .setArray has been removed. Use BufferGeometry .setAttribute to replace/resize attribute buffers' );
}
} );
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册