I did not see "updateTimeStampOfObjectsInCacheWithExtenalReferences" which does
the same.

So, why am I reloading textures? They are not referenced by the geometry?

Lionel Lagarde wrote:
You were right. It was a memory problem. I run out of texture memory.

I have added these lines to osgviewer.cpp :
osgDB::ReaderWriter::Options *options = new osgDB::ReaderWriter::Options();
   options->setObjectCacheHint(osgDB::ReaderWriter::Options::CACHE_ALL);
   osgDB::Registry::instance()->setOptions(options);

It work well for the firsts loaded meshes.

But the DatabasePager, in the method "removeExpiredSubgraphs" calls :
   osgDB::Registry::instance()->removeExpiredObjectsInCache(expiryTime);

My terrain is paged, so there are things in the cache that have been loaded
a long time ago (like textures) and are remove from the cache.

I think the proper way to update the cache is to check the ref count of the
objects. An entry can be removed if :
- it's ref count == 1 (only the cache references it)
- timestamp < expiryTime
Robert Osfield wrote:
On 6/2/06, Lionel Lagarde <[EMAIL PROTECTED]> wrote:
So you think that I run out of video memory. I have an ATI 9600 with
128Mo.

I can only have a stab in the dark, its your dataset and your machine.

My terrain tiles are not so big. The biggest file: 278Ko (ive format).
I will check the number of faces.

Do you know how to disable display lists? I want to use immediate mode
so no data is uploaded to the GPU memory.

drawable->setUseDisplayList(false);

Or use the osgUtil::GLObjectsVisitor which can run through your whole
scene graph set various OpenGL object releated behaviors.

The OSG by default enables display lists, while Performer doesn't.

Also try sourcing up to date drivers.  ATI drivers have been
historically very poor at OpenGL.

Robert.
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/


_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/

Reply via email to