Hi Ignacio,

500+ cylinders isn't that high in terms of what the graphics hardware
can handle, but if you are using lots of seperate MatrixTransforms
then this could be a bottleneck for cull and draw dispatch as the OSG
has to account for all these seperate transforms.

The most effecient way to draw them is to create a batch the geometry
of the cylinders together so you have neighbouring cylinders in one
osg::Geometry.  For instance you could batch 10 or more together, or
perhaps the whole lot.  The memory consumption won't be a great
problem, so feel free to duplicate rather than share the geometry.

Personally I'd write the code for create the cylinder geometry in
batches and then experiment with how many cylinders works best for
performance.  Too many cylinders in one osg::Geometry will lead to
poor cull, too find grained and cull and draw dispatch times on the
CPU will gate peformance.

Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Reply via email to