Hi Fred, ShapeDrawable does not support vertex buffer objects as the vertex data is created on demand.
Robert. On Mon, Jul 26, 2010 at 4:02 PM, Fred Smith <[email protected]> wrote: > Hi, > > setUseVertexBufferObjects(true) has no effect for me with the code below: > > > Code: > osg::Geode* geode = new osg::Geode(); > geode->addDrawable(new osg::ShapeDrawable(new > osg::Cylinder(osg::Vec3(4.4f,0.0f,0.0f),1.0f,1.4f))); > geode->getDrawable(0)->setUseVertexBufferObjects(true); > > > > > When I run this code with an OpenGL API tracer, I can see display lists are > still being used (glNewList to build the display list, then glCallList to use > it). > > This test is easy to reproduce with the osgShaders sample, in GL2Scene.cpp, > CreateModel() can be changed to reflect the above code. > > I guess I must be doing something wrong to make use of VBOs. > > Any idea? > > Cheers, > Fred > > [/code] > > ------------------ > Read this topic online here: > http://forum.openscenegraph.org/viewtopic.php?p=30275#30275 > > > > > > _______________________________________________ > osg-users mailing list > [email protected] > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org > _______________________________________________ osg-users mailing list [email protected] http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

