From 2ca76844cc1d16dd46f9ba9de8fdfa6a5c7618cd Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Fri, 23 Oct 2009 17:27:54 +0000 Subject: [PATCH] Added missing unbinds of VBO and EBO's to Geometry::drawImplementation(..), fixing crash in osganimationtimeline when stats were enabled --- src/osg/Geometry.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/osg/Geometry.cpp b/src/osg/Geometry.cpp index b195aa40d..6953fe41e 100644 --- a/src/osg/Geometry.cpp +++ b/src/osg/Geometry.cpp @@ -1166,6 +1166,10 @@ void Geometry::drawImplementation(RenderInfo& renderInfo) const } } } + + // unbind the VBO's if any are used. + state.unbindVertexBufferObject(); + state.unbindElementBufferObject(); } class AttributeFunctorArrayVisitor : public ArrayVisitor