Commit 796be7ab authored by Martin Schultz's avatar Martin Schultz
Browse files

fixed geometry being rendered on top of logger by storing GL_DEPTH_TEST

value
parent b375f519
...@@ -1079,7 +1079,8 @@ void glViewer::paintGL(double _aspect) ...@@ -1079,7 +1079,8 @@ void glViewer::paintGL(double _aspect)
{ {
properties_.lockUpdate(); properties_.lockUpdate();
GLboolean dtenabled;
glGetBooleanv(GL_DEPTH_TEST, &dtenabled);
ACG::GLState::enable(GL_DEPTH_TEST); ACG::GLState::enable(GL_DEPTH_TEST);
if (glstate_->compatibilityProfile()) if (glstate_->compatibilityProfile())
...@@ -1125,6 +1126,10 @@ void glViewer::paintGL(double _aspect) ...@@ -1125,6 +1126,10 @@ void glViewer::paintGL(double _aspect)
glPopAttrib(); glPopAttrib();
} }
if(dtenabled)
ACG::GLState::enable(GL_DEPTH_TEST);
else
ACG::GLState::disable(GL_DEPTH_TEST);
} }
glBindBuffer(GL_ARRAY_BUFFER, 0); glBindBuffer(GL_ARRAY_BUFFER, 0);
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0); glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, 0);
......
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