Commit ebebdb01 authored by Clinton Stimpson's avatar Clinton Stimpson

ENH: Remove Render() method.

Removed Render() method and its implementation.  The burden now rests on
the user of the class.  This fixes some possible OpenGL errors.
parent c5049851
......@@ -74,37 +74,6 @@ void vtkGenericOpenGLRenderWindow::SetBackRightBuffer(unsigned int b)
this->BackRightBuffer = b;
}
void vtkGenericOpenGLRenderWindow::Render()
{
// save/restore state as well as set up the state to what VTK assumes
glPushClientAttrib(GL_CLIENT_ALL_ATTRIB_BITS);
glPushAttrib(GL_ALL_ATTRIB_BITS);
glMatrixMode(GL_PROJECTION);
glPushMatrix();
glLoadIdentity();
glMatrixMode(GL_MODELVIEW);
glPushMatrix();
glLoadIdentity();
glEnable(GL_DEPTH_TEST);
glEnable(GL_BLEND);
glBlendFunc(GL_ONE, GL_ZERO);
glDepthFunc( GL_LEQUAL );
// OpenGLInit() has more ... should fix this so we can call some code in vtkOpenGLRenderWindow to re-establish
// the OpenGL state that VTK wants.
this->Superclass::Render();
glPopClientAttrib();
glPopAttrib();
glMatrixMode(GL_PROJECTION);
glPopMatrix();
glMatrixMode(GL_MODELVIEW);
glPopMatrix();
}
void vtkGenericOpenGLRenderWindow::Finalize()
{
// tell each of the renderers that this render window/graphics context
......
......@@ -41,9 +41,6 @@ public:
//! Cleans up graphics resources allocated in the context for this VTK scene.
void Finalize();
//! Specific implementation for Render() to save/restore the OpenGL state.
void Render();
//! flush the pending drawing operations
//! Class user may to watch for WindowFrameEvent and act on it
void Frame();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment