Hi, I’m trying to advance my OpenGL knowledge past immediate mode. From Riven’s (thanks Riven) tutorial I was able to get a vertex array rendering properly but I was not able to see an increase in performance.
Here is how I tested it, if this is the wrong approach to bench-marking please inform me.
To test the performance of immediate mode and vertex arrays I drew a quad repeated, in this test it was 88573 quads. When I one big vertex array hold all 88573 quads it got close to the performance of immediate mode but not quite there.
Pastebin: http://pastebin.java-gaming.org/3dddd044049 (It’s messy)
Here is sample console output:
(I should have labeled these). The first columns is individual vertex arrays, the second columns is immediate mode, and the third columns is one big vertex array.
67900774 13660101 15001607 n: 88573
371488407 14153266 19133484 n: 88573
116280710 13882860 14012185 n: 88573
68273896 13738066 15345957 n: 88573
71455953 15008723 12876111 n: 88573
Q1: Could someone please explain why this occurred?
Q2: Does it matter how I render (immediate, vertex array, VBO) when I decide to fully use shaders?
Sorry, these questions must have been asked a lot, thank you for your time.
EDIT: This was done in 3D if that makes a significant difference.