PDA

View Full Version : Use the same Color for a set of vertex



EpSiLoN
01-29-2004, 05:38 AM
I have a display list with a huge number of vertex, because this vertex have all the same color is there a way to use the display list sharing a single information like color(but also normal or other) between them?
I can not use glColor() before to call display list in any case.

Thank you.

dorbie
01-29-2004, 07:17 AM
Put the glColor call *in* the display list, ONCE at the beginning, or call it before the display list is called.

OpenGL is a state engine, everything you set stays that way until you set it again, including color. So to share color, normals etc, you just set it once and leave it alone, it won't change until you tell it to.