iDevGames Forums

Full Version: Fast rendering with OpenGL 1.1
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello!

Can someone recommend me a way to render a texture on screen that is faster than glDrawArrays and glVertex2f that will work on OpenGL 1.1.

Every example and documentation that I found doesn't work with OpenGL 1.1
Depends. Are you taking about desktop GL 1.1, or ES 1.1? What sort of environment are you coding for where you're restricted to 1.1 (of either flavor)?

To answer your question directly, you might be able to use display lists (glNewList, glCallList, etc.) if you're in desktop GL 1.1 without ARB_vertex_buffer_object. If you're in ES 1.1 and/or have ARB_vertex_buffer_object, you can create a VBO and use glDrawElements. In both of these cases, your vertex data is stored on the GPU, so you won't be transferring it from RAM like you would with call to glDrawArrays.

That said, are you sure your bottleneck is the draw call you're using? Since you're saying "render a texture on screen", it sounds like you don't have many vertices (maybe just one quad), and you just want to blit something to the display. In that case, fill rate is probably your bottleneck by far, and changing the way you submit your vertices won't actually help.
I have a hard time believing that you mean OpenGL (non-ES) 1.1, since that is 15 years out of date. Yet OpenGL ES 1.1 doesn't have glVertex2f(). I sort of doubt OS X supported anything less than 1.3 ever. Do you just mean like pre-shader OpenGL?

As ThemsAllTook mentioned though, you really can't draw a texture faster than glDrawArrays. Submitting the geometry, no matter how you do it is trivial for a single quad compared to the actual draw call cost or the fillrate.
The drivers of my video card a GeForceFX 5200 supports Open GL 1.1 and GL_EXT_bgra from 1.2,I'm using only desktop OpenGL , on Windows.

I'm trying to use render to texture,an array in RAM with RGB values of an image at the resolution 1024x768 and I'm displaying that on a 2D viewport.

I just tried display lists and it's still lagging.
Is there any other way of doing it?
I updated the video driver and now works smooth.

Thank you!
Reference URL's