See the image before and after in my game where I try to change color on a instanced item using registerInstancedBuffer on source mesh and instancedBuffers.color on the instance.
There are no errors, and once I apply the mesh disappears… Any clue why this happens ? I do use some optimization and the engine runs offscreencanvas. And I am unable to reproduce the error on playground.

You should use instanceColor instead to not conflict with the “color” attribute used for vertex colors
I found out this about instancedBuffers and colors.
- Create mesh and instances first.
- Wait one second by using SetTimeout
- Register instancedBuffers and set instanceColor
- Meshes disappears.
- Remove Timeout for one second and it works as expected.
You can see this playground example: Babylon.js Playground
Is this normal behavior ?
Seems to be a weird bug, I ll look into it ASAP.
2 Likes