Archived

This topic is now archived and is closed to further replies.

thw

compiled_vertex_array vs draw_range_elements

Recommended Posts

Hi, i recently wondered what the difference between GL_EXT_compiled_vertex_array and GL_EXT_draw_range_elements is, but i found no difference. So where is it ?

Share this post


Link to post
Share on other sites
The difference is simply, that they have nothing in common
They are two totally different extensions / commands.

GL_EXT_compiled_vertex_array (CVA) simply let''s you lock a standard vertex array into video memory, so it gets rendered faster, if you draw it a second time (or more). The driver copies your VA data into video memory the first time you render it, consecutive accesses are faster. But this also means, that if you use CVA on data that will only be rendered once, then it is actually slower than standard VA, because of the extra copy step.

GL_EXT_draw_range_elements is just an extended way of calling the DrawElements() call. It lets you specify additional parameters (an index range), so that the OpenGL driver can directly stream your index array to the hardware, without needing further processing.

You can (and should) actually use RangeElements in combination with CVA''s to get the best performance.

Now, there is a third one: vertex_array_range (VAR), this one is the fastest possible, but it''s complex to use and nVidia proprietary (won''t work eg. on ATi).

Share this post


Link to post
Share on other sites