1
DotNet / Pushing everything to a VertexArray each frame
« on: June 14, 2014, 07:46:19 pm »
So the method I'm using for rendering, is I have all these Images and Tilemaps and stuff I've written. Most of them work using vertices, and I have a BatchManager that will batch everything batchable into the same VertexArray (that is, everything that has the same texture, blendmode, shader, etc.)
Thing is, I've noticed this is a bit cpu-expensive. Clearing all the VertexArrays and pushing everything to them each frame seems to be a bit of a performance issue.
This is written using C# by the way, just to clarify.
Am I doing it terribly wrong? Should I just stick to using SFML's sprites and stuff that simply don't use batching (and just batch Tilemap or Particles)? Any tips on how to improve performance?
Thing is, I've noticed this is a bit cpu-expensive. Clearing all the VertexArrays and pushing everything to them each frame seems to be a bit of a performance issue.
This is written using C# by the way, just to clarify.
Am I doing it terribly wrong? Should I just stick to using SFML's sprites and stuff that simply don't use batching (and just batch Tilemap or Particles)? Any tips on how to improve performance?