- Home /
Bad performance using entity component system
I am working on a randomly generated voxel world in which the blocks are grouped together in chunks and was running into some performance issues, so I started testing with ECS, Jobs and the Batch compiler.
I made a small testscene in which I instantiated 10.000 Rendermesh entities with a single triangle and my framerate dropped to about 8 frames per second. With this test I made a new instance of Rendermesh for every entity.
When I made only one Rendermesh and applied them to all entities i could have over a million with a decent framerate. But the problem is: All of the chunks in my voxel world have their own mesh and uv-coördinates so I can't just create one rendermesh and apply it to all.
Is there any way around this? Am I missing something? Is ECS only ever usefull when you need a lot of the exact same model? Should i just revert back to regular old gameobjects?
Thanks in advance!