[osg-users] modifying vertexs

Jim Brooks jimblist at gmail.com
Thu Mar 5 18:56:51 PST 2009

Found two different ways to tell OSG that vertexs were modified.
Maybe these are circumventions that aren't proper (?).

What is the "one right way"?
Call dirtyDisplayList() ?

:	mVertexs(new osg::Vec3Array),
	mDrawArray(new osg::DrawArrays( osg::PrimitiveSet::POINTS,0,0))

void AddParticle( const osg::Vec3& v )
	mVertexs->push_back( v );

    mDrawArray->setCount( mVertexs->size() );

// Passing same vertex array causes update.
	mGeom->setVertexArray( mVertexs.get() );


More information about the osg-users mailing list