Yes I was originally adding material plus disabling back-face culling per
stateset per Geode, hence the huge saving.

Moving the colour to the vertices (one colour bound overall) does the same
job as far as I'm concerned and definitely saves on memory/performance :)

I'm still having a lot of issues with memory - probably due to the way I've
constructed my scenegraph - I will elaborate next week on the other thread
you quoted.

Thanks,
Andrew

On Fri, Jul 17, 2009 at 7:07 PM, Thrall, Bryan <
[email protected]> wrote:

> Andrew Burnett-Thompson wrote on Friday, July 17, 2009 10:42 AM:
> > However so far I can see the only way to add specular is via a
> StateSet. I
> > previously had one stateset per object, but this consumed too much
> memory, so
> > now have a shared stateset
>
> I assume you're referring to your statement here:
>
> http://forum.openscenegraph.org/viewtopic.php?t=3121
>
> Where you say moving from a StateSet per Geode to a shared StateSet
> saved you 250MB.
>
> We don't have any details on how you're creating those StateSets, but
> the StateSet itself is only about 192 bytes, so the rest of the memory
> savings probably come from all the StateAttributes you must be adding to
> the StateSets. Perhaps if you shared the StateAttributes as much as
> possible, you could still use a StateSet per Geode (such as for adding
> specular) with a much smaller memory footprint (closer to 36MB for your
> 200000 object model).
>
> I'm assuming a lot about what you were doing, though, so feel free to
> shoot me down if some of my assumptions are wrong :)
> --
> Bryan Thrall
> FlightSafety International
> [email protected]
> _______________________________________________
> 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

Reply via email to