Parcourir la source

Added length to BufferAttribute.

Mr.doob il y a 11 ans
Parent
commit
99ef9cb04a
1 fichiers modifiés avec 6 ajouts et 0 suppressions
  1. 6 0
      src/core/BufferAttribute.js

+ 6 - 0
src/core/BufferAttribute.js

@@ -8,6 +8,12 @@ THREE.BufferAttribute.prototype = {
 
 	constructor: THREE.BufferAttribute,
 
+	get length () {
+
+		return this.array.length;
+
+	},
+
 	set: function ( value ) {
 
 		this.array.set( value );