From f0273bb346ca7962b75e00eb1ec0f96ca45d137e Mon Sep 17 00:00:00 2001 From: Zehua Hu Date: Sat, 13 Jul 2024 16:49:55 +0800 Subject: [PATCH] Add initial value to InstancedMesh's setColorAt method (#28854) * Add initial value to InstancedMesh's setColorAt method * add spaces --- src/objects/InstancedMesh.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/objects/InstancedMesh.js b/src/objects/InstancedMesh.js index 90f78092a4551f..d295c30dbeac2d 100644 --- a/src/objects/InstancedMesh.js +++ b/src/objects/InstancedMesh.js @@ -207,7 +207,7 @@ class InstancedMesh extends Mesh { if ( this.instanceColor === null ) { - this.instanceColor = new InstancedBufferAttribute( new Float32Array( this.instanceMatrix.count * 3 ), 3 ); + this.instanceColor = new InstancedBufferAttribute( new Float32Array( this.instanceMatrix.count * 3 ).fill( 1 ), 3 ); }