On Sun, Apr 17, 2011 at 6:10 PM, ThorstenB <bre...@gmail.com> wrote:
> On 16.04.2011 21:16, Anders Gidenstam wrote:
>> If I'm not mistaken the particles issue has been around since we got
>> particles, so it is apparently not that bad (leak and race
>> condition) in practice.
> Ok, thanks! I've create a bug issue as a reminder, in case someone else
> noticed the issue some day.
> http://code.google.com/p/flightgear-bugs/issues/detail?id=305
>
>>> Not sure, but I guess the issues with "Effect" objects is probably worse
>>> than with particles. There's a larger number of Effect objects - and
>>> each is connected to a texture (.rgb/.png images) - which may occupy a
>>> lot of memory. Just by starting at KSFO, loads of KSFO terminal textures
>>> - and textures of 15 different MP aircraft immediately stick in memory...
>> Yes, the big textures will eat memory fast. Particle systems usually use
>> small textures (the effect of the accumulation of particle system updaters
>> is noticeable with wildfire, though - but you'd need a lot of MP aircraft
>> passing through to generate anywhere near those numbers of particle
>> systems).
> The effect/texture "mystery" is also solved - alas - explained. There is
> a global cache in simgear/makeEffect.cxx (effectMap), and it has no
> condition to ever drop anything. So, created effects always stay in
> memory until shutdown - hence also their textures. If that's used for
> scenery/MP aircraft a lot, it _might_ accumulate a lot of memory. Tim
> might know more about this :).

It seemed like a good idea at the time :)

The Effect cache could be changed to use osg::observer_ptr, which is a
weak pointer. Also, there may be some places where effects are not
being found in the cache and are being recreated.

Tim
>
> cheers,
> Thorsten
>
> ------------------------------------------------------------------------------
> Benefiting from Server Virtualization: Beyond Initial Workload
> Consolidation -- Increasing the use of server virtualization is a top
> priority.Virtualization can reduce costs, simplify management, and improve
> application availability and disaster protection. Learn more about boosting
> the value of server virtualization. http://p.sf.net/sfu/vmware-sfdev2dev
> _______________________________________________
> Flightgear-devel mailing list
> Flightgear-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/flightgear-devel
>

------------------------------------------------------------------------------
Benefiting from Server Virtualization: Beyond Initial Workload 
Consolidation -- Increasing the use of server virtualization is a top
priority.Virtualization can reduce costs, simplify management, and improve 
application availability and disaster protection. Learn more about boosting 
the value of server virtualization. http://p.sf.net/sfu/vmware-sfdev2dev
_______________________________________________
Flightgear-devel mailing list
Flightgear-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/flightgear-devel

Reply via email to