[vtk-developers] Rendering of vtkPolyData broken on Nvidia systems

Oleg Koren koren at curefab.com
Fri Jun 22 11:58:40 EDT 2012


Hello,

I think, now I know the root of the problem. Great thanks for the suggestion
to run an OpenGL logger. My log boils down to the following:

glColor3f(1.0f, 0.0f, 0.0f);
glDeleteLists(1,1);
glGenLists(1);
glNewList(1,GL_COMPILE);
glDisable(GL_LIGHTING);
glBegin(GL_LINE_STRIP);
	glVertex3f(0.000000,0.000000,0.000000);
	glVertex3f(1.000000,0.000000,0.000000);
	glVertex3f(1.000000,1.000000,0.000000);
	glVertex3f(0.000000,1.000000,0.000000);
	glVertex3f(0.000000,0.000000,0.000000);
glEnd();
glEnable(GL_LIGHTING);
glEndList();		
glCallList(1);

glColor3f(1.0f, 1.0f, 0.0f);
glDeleteLists(2,1);
glGenLists(1);
glNewList(2,GL_COMPILE);
glDisable(GL_LIGHTING);
glBegin(GL_LINE_STRIP);
	glVertex3f(0.000000,0.000000,0.000000);
	glVertex3f(0.000000,1.000000,0.000000);
	glVertex3f(0.000000,1.000000,1.000000);
	glVertex3f(0.000000,0.000000,1.000000);
	glVertex3f(0.000000,0.000000,0.000000);
glEnd();
glEnable(GL_LIGHTING);
glEndList();
glCallList(2); 

and this actually doesn't work. Which is, I guess, because lists are
deprecated since OpenGL 3.0 and should receive very limited support by now,
if any. Removing all calls to list functions does the trick.

That means, one should always set ImmediateModeRenderingOn on a
vtkPolyDataMapper. Immediate rendering mode disables OpenGL lists.


--
View this message in context: http://vtk.1045678.n5.nabble.com/Rendering-of-vtkPolyData-broken-on-Nvidia-systems-tp5714114p5714147.html
Sent from the VTK - Dev mailing list archive at Nabble.com.



More information about the vtk-developers mailing list