Permalink
Browse files

Remove seemingly redundant handling of Geode in GLObjectsVisitor

  • Loading branch information...
1 parent fdf6d55 commit 6deefe0646c6aa426371042a4951ba58d30e0f98 @scrawl scrawl committed Feb 3, 2017
Showing with 0 additions and 27 deletions.
  1. +0 −5 include/osgUtil/GLObjectsVisitor
  2. +0 −22 src/osgUtil/GLObjectsVisitor.cpp
@@ -94,11 +94,6 @@ class OSGUTIL_EXPORT GLObjectsVisitor : public osg::NodeVisitor
/** Simply traverse using standard NodeVisitor traverse method.*/
virtual void apply(osg::Node& node);
- /** For each Geode visited set the display list usage according to the
- * _displayListMode.
- */
- virtual void apply(osg::Geode& node);
-
void apply(osg::Drawable& drawable);
void apply(osg::StateSet& stateset);
@@ -53,28 +53,6 @@ void GLObjectsVisitor::apply(osg::Node& node)
}
}
-void GLObjectsVisitor::apply(osg::Geode& node)
-{
- bool programSetBefore = _lastCompiledProgram.valid();
-
- if (node.getStateSet())
- {
- apply(*(node.getStateSet()));
- }
-
- traverse(node);
-
- bool programSetAfter = _lastCompiledProgram.valid();
- if (!programSetBefore && programSetAfter)
- {
- osg::State* state = _renderInfo.getState();
- osg::GLExtensions* extensions = state->get<osg::GLExtensions>();
- extensions->glUseProgram(0);
- state->setLastAppliedProgramObject(0);
- _lastCompiledProgram = 0;
- }
-}
-
void GLObjectsVisitor::apply(osg::Drawable& drawable)
{
if (_drawablesAppliedSet.count(&drawable)!=0) return;

0 comments on commit 6deefe0

Please sign in to comment.