瀏覽代碼

BufferGeometry: Prevented duplicate index buffers.

tschw 10 年之前
父節點
當前提交
97c70d207f
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      src/core/BufferGeometry.js

+ 2 - 0
src/core/BufferGeometry.js

@@ -66,6 +66,8 @@ THREE.BufferGeometry.prototype = {
 			console.warn( 'THREE.BufferGeometry.addAttribute: Use .setIndex() for index attribute.' );
 			this.setIndex( attribute );
 
+			return;
+
 		}
 
 		this.attributes[ name ] = attribute;