Archived

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

Zeusel

display lists

Recommended Posts

In a word ... no. But it depends on what you want to do with the list. It could simply contain state changes. If however, you are drawing primatives, then the same rules apply as in immediate mode - which would use glBegin(GL_WHATEVER)/glEnd()

You just need

glNewList(1, GL_COMPILE);
//code
glEndList();

Share this post


Link to post
Share on other sites
I want to create a function that writes text! each letter is a display list! if a string is long glBegin/End, would be called very often!

Share this post


Link to post
Share on other sites
If your using a font engine and you want to manually create all the fonts, you could have display lists like this:

charA = glGenLists(1);

glNewList(charA, GL_COMPILE);
DrawCharacterA(); //this would be where you draw your character
glEndList();


So in answer to your question, yes & no. They don''t require you to have a glBegin(GL_TRIANGLES)/glEnd() or whatever, but you do need glNewList(..) and glEndList() when defining the lists contents.

Share this post


Link to post
Share on other sites