diff --git a/src/osg/Drawable.cpp b/src/osg/Drawable.cpp index fcd9bd048..3f8d381ae 100644 --- a/src/osg/Drawable.cpp +++ b/src/osg/Drawable.cpp @@ -624,7 +624,6 @@ void Drawable::compileGLObjects(RenderInfo& renderInfo) const void Drawable::draw(RenderInfo& renderInfo) const { - State& state = *renderInfo.getState(); bool useVertexArrayObject = state.useVertexArrayObject(_useVertexArrayObject); if (useVertexArrayObject) @@ -634,16 +633,13 @@ void Drawable::draw(RenderInfo& renderInfo) const VertexArrayState* vas = _vertexArrayStateList[contextID].get(); if (!vas) { - _vertexArrayStateList[contextID] = vas = createVertexArrayState(renderInfo, true); - // OSG_NOTICE<<" Geometry::draw() "<