[osg-users] Geode, Geometry, glCallList, glMultMatrix and so on :)

Quanteek osgforum at tevs.eu
Sat Mar 14 08:13:33 PDT 2009


Hey everyone,

I am new to OSG and I am sure that I have misunderstood something about rendering into OSG.

I have got two models of pattern : one for a cylinder, and one for a leaf of a tree.

The openGl way would be to use a display List and store my pattern into and when I have to redraw the thing into a different place than pre-calculated one I use glMultMatrix and glCallList with the good number.

In osg I load them into a osg::Geometry thanks to a PrimitiveSet (ElementUInt + Polygon) but I create a Geometry for every new place.
So typically I have got a Geode for cylinder and a Geode for leaf because I will not use same material. And into the Geode cylinder I attach a lot of different geometries, same thing into leaf.

Am I wrong ? (I am sure I am :p) Is the good way to create a Geode with a unique Geometry and then using the MatrixTransform ? Is it not to heavy for rendering a big scene ? And is collada plugin will export correctly the scene ?

Sorry for all these begineers questions but I have looked into documentation and I am a little bit confusing with all informations.

P.S. : My scene is only a real tree but with a lot of informations (i.e. each branch are divided into several (100) cylinders and I have got each leaf too draw) I have put a screen of wireframe mode

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=8477#8477



-------------- next part --------------
A non-text attachment was scrubbed...
Name: ligDrawScreen.png
Type: image/png
Size: 140064 bytes
Desc: not available
URL: <http://lists.openscenegraph.org/pipermail/osg-users-openscenegraph.org/attachments/20090314/c216fb6c/attachment-0002.png>


More information about the osg-users mailing list