浏览代码

Examples: More clean up

Mugen87 8 年之前
父节点
当前提交
2ffbccead2
共有 1 个文件被更改,包括 3 次插入2 次删除
  1. 3 2
      examples/webgl_buffergeometry_instancing_dynamic.html

+ 3 - 2
examples/webgl_buffergeometry_instancing_dynamic.html

@@ -125,11 +125,12 @@
 
 			var bufferGeometry = new THREE.BoxBufferGeometry( 2, 2, 2 );
 
-			// copy data from a simple box geometry
+			// copying data from a simple box geometry, but you can specify a custom geometry if you want
 
 			var geometry = new THREE.InstancedBufferGeometry();
 			geometry.index = bufferGeometry.index;
-			geometry.attributes = bufferGeometry.attributes;
+			geometry.attributes.position = bufferGeometry.attributes.position;
+			geometry.attributes.uv = bufferGeometry.attributes.uv;
 
 			// per instance data