On hover change color for instanced mesh

Hello BABYLON folks!
This is my first post here, and first of all let me thank you for this awesome engine!
I am deeply and truly amazed: Features, Docs, Forum, Community, Youtube channel, Playground, Sandbox, Inspector, Editors for all kinds of stuff. Absolutely mind-blowing. Breathtaking!

After start of my journey back in Mart 1, I finally get stuck. The problem is pretty described in topic title.
here is my solution so far (if it doesn’t render please drag camera a little)
I guess I can pinpoint the problem to single thing:
find index of instanced mesh to change data in sourcemesh vertex buffer
thanks in advance

You can use the registerInstancedBuffer method instead of handling the vertex buffer data yourself.

That way, you can access the color property of each instance right on the instance mesh itself, making everything easier:



Simply brilliant. Thank you.

Just to wrap this up, here is final solution

1 Like