OpenGL vs DirectX: vertex buffer performance

DrawRangeElements is not always faster. It may be faster, depending on the implementation. Worst-case, it goes at the same speed as DrawElements.
Ok, I should have said that of DrawRangeElements is always faster or as fast as DrawElements. In any case there is nor reason for using DrawElements. Personally I have experimented impressive speed gains with classic arrays and DrawRangeElements.

Since the size is already specified when creating a VBO, glDrawRangeElements is pretty much obsolete with VBOs.

But it’s no longer usefull with static VBO since all the data is already in the video memory.
You both are not right. In the the NVidia paper “Using Vertex Buffer Objects” you can read things like this:

This combination of memory usage can help the memory manager balance between
three kinds of memory: system, AGP and video.
So the buffer is not always in video memory.

And in the same paper:

Use glDrawRangeElements Instead of glDrawElements
Using range elements is more efficient for two reasons:

  • If the specified range can fit into a 16-bit integer, the driver can optimize the
    format of indices to pass to the GPU. It can turn a 32-bit integer format into a
    16-bit integer format. In this case, there is a gain of 2×.
  • The range is precious information for the VBO manager, which can use it to
    optimize its internal memory configuration.
    So it’s always better to use DrawRangeElements, because al least it will be as fast as DrawElements.

You should perhaps take a hint from d3d (yet again). In d3d there simply isn’t the option to not specify range information in a DrawIndexedPrimitive call. Also, let’s face it, it’s trivial information for the app to gather. Just do it, and forget about it.

Definitely, Direct3D has hugely greater vertex buffers performance.

Uhm, no. Done correctly, performance is about the same on both APIs. Done wrong, performance sucks on both APIs.

Originally posted by Humus:
Uhm, no. Done correctly, performance is about the same on both APIs. Done wrong, performance sucks on both APIs.
You right, both APIs is about the same performance.