PDA

View Full Version : glCallList() and glNewList()



02-01-2005, 02:40 PM
Hi All,
Can a glCallList() be nested in a glNewList()?
glNewList(triangle, GL_COMPILE);
.....
glEndList();

glNewList(rectangle, GL_COMPILE);
....
glCallList(triangle);
glEndList();

if I substitute glCallList() with another glNewList(), it worked. Is there any solid "knowledge" that I miss?
Thanks.

shinpaughp
02-01-2005, 05:59 PM
glCallList(s) can be nested inside a glNewList glEndList pair. GL_INVALID_OPERATION is generated for glNewList to be called after a glNewList and before a glEndList.