提交 c914858d 编写于 作者: R Ricardo Cabello

Merge pull request #6500 from benaadams/buffer-length-to-count

Rename BufferAttribute.length to BufferAttribute.count
......@@ -17,6 +17,13 @@ THREE.BufferAttribute.prototype = {
get length () {
THREE.warn( 'THREE.BufferAttribute.length has been removed. Use THREE.BufferAttribute.count instead.' );
return this.count;
},
get count() {
return this.array.length / this.itemSize;
},
......
......@@ -17,6 +17,13 @@ THREE.InterleavedBufferAttribute.prototype = {
get length() {
THREE.warn( 'THREE.InterleavedBufferAttribute.length has been removed. Use THREE.InterleavedBufferAttribute.count instead.' );
return this.count;
},
get count() {
return this.data.array.length / this.data.stride;
},
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册