Is it possible to create a display list during several frames?

Started by
2 comments, last by Falken42 18 years, 1 month ago
Hi there! I'm working on a rather big scale engine, and I want the loading to be smooth and as non existant as possible. While the terrain data is being able to be loaded during several frames, can a display list be created in the same manner..? Right now it gets created in one go, and it causes a stutter in the gameflow.. :/ I.e, can I keep a NewList(..) open without it catching other glBegin calls etc...? Thanks for your time! :) /Robert
"Game Maker For Life, probably never professional thou." =)
Advertisement
No, glNewList captures (pretty much) everything until glEndList. Compiling display lists is also slow -- they are not something you'd want to be creating dynamically during runtime.

Perhaps dynamic vertex buffers are more of what you're looking for?
So, if I understood correctly, these buffers are able to be filled one chunk per frame..?

Since I really don't want to store a couple of square miles terrain in the video-memory I need something dynamic, I guess :D
"Game Maker For Life, probably never professional thou." =)
The GL_ARB_vertex_buffer_object extention allows you to create a streamable vertex buffer in video memory. Every frame, you can just pump in the vertices used by your terrain into it -- fast and efficient.

If you have a huge terrain, you obviously won't be able to store the entire thing in video memory. You might want to consider implementing some kind of LOD calculation, such as ROAM or SOAR, if you haven't already.

I personally use a method similar to SOAR -- with huge landscapes my vertex buffer is only 512Kb, and I stream that to the video card every frame at over 200fps on a Geforce 6 with an AMD Athlon 2800+.

This topic is closed to new replies.

Advertisement