Hi All,

in my scene I have many drawables that share the same settings/glsl
program - the needed params to render the different drawables are
already passed in as vertex attributes at geometry level.
I'd like to know it there's any difference, with respect to
performances, if I share the common StateSet either one of the
following methods:

1. share the common SS in a single geode

geode1 - SS1
  |
  |--------------------------------
  |              |               |
draw1      draw2        draw3


geode1 - SS2
  |
  |--------------------------------
  |              |                |
draw11      draw12      draw13



2. share the same instance of the SS (let's call them SS1 and SS2) at
drawable level:

geode
  |
  
|----------------------------------------------------------------------------------------------------------------------
  |                       |                        |
  |                       |                        |
draw1--SS1      draw2--SS1        draw3--SS1      draw11--SS2
draw12--SS2        draw13--SS2


The second method would be preferable to me, as every drawable
represents an independent object, and I might need to change the way
it's rendered at runtime (see hilight, etc...).
I'd like to know if there are some performance penalties with respect
to method 1.

Thanks a lot.
Ricky
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to