Hi,

I am using osg::PagedLOD nodes in my project for large models visualization. 
The model is splitted into several parts (like octree) and multiresolution tree 
is made - same as VPB uses:


Code:

Group
   PagedLOD
      child 0 -> local tile geometry at low resolution
      child 1 -> external file reference

   PagedLOD
      child 0 -> local tile geometry at low resolution
      child 1 -> external file reference





I understand the system of unloading nodes by DatabasePager, when PagedLOD 
nodes count is bigger than OSG_MAX_PAGEDLOD (I hope that unloaded pagedlod 
nodes unload also corresponding data on GPU - when using VBO) 

The system works fine, but the problem is in good PagedLOD::setRangeMode and 
PagedLOD::setRange (between lower res. geode and external reference) data 
setting.  Since my model is not terrain, definition of setRange value is 
crucial. I use PIXEL_SIZE_ON_SCREEN metrics and by low setRange number the high 
resolution files are requested, high number of Geometries is loaded and openGL 
out-of-memory occurs and no new nodes are loaded. The setRange number depends 
on graphical window size, GPU memory, so it should be calculated somehow - to 
get the best performance from hardware.  

Does anyone have tip how to dynamically adjust setRange values? Or is any 
better technique with different metrics?

I have an idea to adjust setRange (or change LODScale) when an out-of-memory 
openGL error occurs. Then I would change the setRange value (it is same for all 
pagedLOD nodes), free the GPU memory and load again. 

What do you think about this idea?
How do I free occupied GPU memory? Is is enough to reconnect the subtree from 
scene?
How do I catch openGL error?

Could culling settings help here to have smaller scene? Culling in my app is 
set to OSG default.

Many thanks in advance, 
Tomas

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=33000#33000





_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to