I have the following scenario:
I have over 250 different textures (with 256x256 resolution), and over 3000 objects to render, each of them uses one of the 250 textures. I need the ability for each object to individually
- change its color
- change its position
- change its rotation
Also I need the ability to freely remove any one of the 3000 objects realtime, and also add a new one (realtime).
Right now I’m rendering the objects with a pretty basic logic: globally 1 PlaneBufferGeometry (reused each time), separate material for each object (to be able to modify their colors individually), and basic
THREE.Mesh instances (3000 pieces).
The FPS gets quite low of course, so I’m wondering if there’s anything I could do about it. I guess merging them is not really a good idea, because of the need for the individual position/orientation setting, that could/should happen realtime.
Using InstancedMesh would help, right? If so, can someone show me an example that I could use as a starting point? One with different textures would be great.
Also, any other performance-improving hints would be welcome for this scenario.
Thanks in advance