Re: [osg-users] Texture Caching Problem with 3.6.3/4

2020-03-31 Thread OpenSceneGraph Users
On Tue, 31 Mar 2020 at 15:20, OpenSceneGraph Users < osg-users@lists.openscenegraph.org> wrote: > Do you have hangouts > Whom are asking this question of? There are thousands of people in the OSG community. If you are referring to me then, not for general public OSG support, if I did I'd spend

Re: [osg-users] Texture Caching Problem with 3.6.3/4

2020-03-31 Thread OpenSceneGraph Users
Do you have hangouts On Mar 31, 2020 14:42, "OpenSceneGraph Users" < osg-users@lists.openscenegraph.org> wrote: > Hi Robert, > I stumbled upon this topic while I was looking for a similar problem that > I am having using osgEarth in an osgQt viewer. I am posting this message > here because I

Re: [osg-users] Texture Caching Problem with 3.6.3/4

2020-03-31 Thread OpenSceneGraph Users
HI Emanuele, I'm not the author or maintainer of osgQt, and don't have Qt expertise. If there is an issue with interaction with Qt integration I'm really not the best person to look at it. My only guess given the parsing error, any chance that it a locale issue with parsing ascii files in one

Re: [osg-users] Texture Caching Problem with 3.6.3/4

2020-03-31 Thread OpenSceneGraph Users
Hi Robert, I stumbled upon this topic while I was looking for a similar problem that I am having using osgEarth in an osgQt viewer. I am posting this message here because I think that the two problems might be related and I hope that you could help me. I am using OpenSceneGraph-3.6.5 and

Re: [osg-users] Texture Caching Problem with 3.6.3/4

2019-12-18 Thread Greg D
Robert, Thanks for the fix. That solved the problem. I had previously worked around it with your suggestion to disable texture caching. unsigned int options = osgUtil::Optimizer::ALL_OPTIMIZATIONS; options ^= osgUtil::Optimizer::OPTIMIZE_TEXTURE_SETTINGS; optimizer.optimize(model, options);

Re: [osg-users] Texture Caching Problem with 3.6.3/4

2019-12-16 Thread Robert Osfield
Hi Greg, Today I worked on improving the ObectCache::releaseGLObjects() implementation so that it removes objects in the scene that are Texture or contain Textures in their subgraph, where the Texture no longer have any associated osg::Image. I believe this resolves the usage case : 1.

Re: [osg-users] Texture Caching Problem with 3.6.3/4

2019-12-11 Thread Robert Osfield
On Wed, 11 Dec 2019 at 13:04, Greg D wrote: > I don't understand exactly what the cache does. > The clue is in the name, ObjectCache is cache of Objects so they can be reused. The cache is useful for avoid objects being loaded multiple ties, especially important for textures as they consume a

Re: [osg-users] Texture Caching Problem with 3.6.3/4

2019-12-11 Thread Greg D
Thanks Robert. I moved the line to clear the cache into my calling code and out of OSG. I don't understand exactly what the cache does. If it has an expiration time and objects are removed after a minute or so (which seems to happen) it would appear it is a short-term cache, perhaps to

Re: [osg-users] Texture Caching Problem with 3.6.3/4

2019-12-10 Thread Robert Osfield
On Monday, 9 December 2019 19:57:27 UTC, Greg D wrote: > > My quick fix is to clear the cache on the first render (and call clear > thereafter). OpenFlight files open and render fine now. Is this a safe > fix? > > void ViewerBase::frame(double simulationTime) > { > >

Re: [osg-users] Texture Caching Problem with 3.6.3/4

2019-12-09 Thread Greg D
My quick fix is to clear the cache on the first render (and call clear thereafter). OpenFlight files open and render fine now. Is this a safe fix? void ViewerBase::frame(double simulationTime) { if (_done) return; // OSG_NOTICE

Re: [osg-users] Texture Caching Problem with 3.6.3/4

2019-12-09 Thread Greg D
Robert, Thanks for the information. I cleaned up the references to allow smart pointers to work for the model and viewer as intended. The explicit deletion and cleanup code was added years ago in an attempt to address a memory leak issue. Unfortunately osgDB::readRefFile() wasn't available

Re: [osg-users] Texture Caching Problem with 3.6.3/4

2019-12-07 Thread Robert Osfield
The explanation and code snippet doesn't tell us enough of what is going on in your app to be able to guess what might be wrong. The best thing I can do at this point is flag up a couple of issues in the code that could be improved, or flag up stuff that seems odd. First up a memory leak: