From 9e07a72119a6a35b00a9ea54fa97310303842076 Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Sun, 29 Apr 2007 20:13:53 +0000 Subject: [PATCH] Added temporary code (but comment out) for testing VBO performance --- src/osg/Drawable.cpp | 3 +++ src/osg/Geometry.cpp | 9 ++++++--- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/osg/Drawable.cpp b/src/osg/Drawable.cpp index 039928713..2d74d46d5 100644 --- a/src/osg/Drawable.cpp +++ b/src/osg/Drawable.cpp @@ -258,6 +258,7 @@ Drawable::Drawable() _supportsVertexBufferObjects = false; _useVertexBufferObjects = false; + // _useVertexBufferObjects = true; _numChildrenRequiringUpdateTraversal = 0; _numChildrenRequiringEventTraversal = 0; @@ -603,6 +604,8 @@ void Drawable::setUseDisplayList(bool flag) void Drawable::setUseVertexBufferObjects(bool flag) { + // _useVertexBufferObjects = true; + // osg::notify(osg::NOTICE)<<"Drawable::setUseVertexBufferObjects("<getTotalDataSize(); - + unsigned int unit; for(unit=0;unit<_texCoordList.size();++unit) { _texCoordList[unit].offset = totalSize; @@ -1670,7 +1672,8 @@ void Geometry::drawImplementation(RenderInfo& renderInfo) const state.setFogCoordPointer(GL_FLOAT,0,(const GLvoid*)_fogCoordData.offset); else state.disableFogCoordPointer(); - + + unsigned int unit; for(unit=0;unit<_texCoordList.size();++unit) { const Array* array = _texCoordList[unit].array.get();