3
« on: June 19, 2020, 07:07:37 pm »
Hello,
I am working on a Cellular Automota simulation project (Game Of Life type).
I allow the user to zoom in and out, and when they zoom out, more cells of the simulation are computed.
I was drawing all cells individually and I, very quickly, encountered performance issues as I was calling draw so many times.
I would like to use sf::VertexArray to display my cells (each cell is a quad). However, I wondered if it is not dangerous that the number of cells I use can be unbounded (since the user can zoom out).
Put it in an other way, is there a maximal size above which it is not safe/performant to use sf::VertexArray ? Will SFML or OpenGL automatically split my sf::VertexArray if it is too big for the buffer of my GPU ?
Would you recommend I fix a maximal limit in number of quads in a sf::VertexArray and potentially use several of them ? If yes, what would you recommend that maximal size to be ?
Thank very much in advance,