Update: CC - Demo New - Key Up (194yv3pctj.js) 110 bytes modified

beta.r3js.org
-=yb4f310 2018-02-12 14:34:31 +01:00
parent a07c3cd4b7
commit f121ccbaaf
1 changed files with 4 additions and 2 deletions

View File

@ -48,7 +48,7 @@ if (data.code === 'KeyL') {
height = heightData[(y * 128) + x] * 10;
scale = height * 0.1;
positions.push(x, 128 - y, height);
positions.push(x - 64, 64 - y, height);
quaternions.push(0, 0, 0, 1);
scales.push(scale, scale, scale);
}
@ -70,7 +70,9 @@ if (data.code === 'KeyL') {
this.instancedGeometry.instance.addAttribute('color', new THREE.Float32BufferAttribute(colors, 3));
this.instancedGeometry.instance.addGroup(0, 5, 0);
this.instancedGeometry.instance.clearGroups();
this.instancedGeometry.instance.addGroup(0, this.instancedGeometry.instance.attributes.position.count, 0);
//this.meshImageGrid.geometry.instance = this.instancedGeometry.instance;