Hi Maciej,
Thanks for your submission! I've applied the patch to my svn trunk and
tested it in my application and it works:) Robert, I hope you can merge
in this submission into svn trunk now that OSG 2.6 is out the door.
Just one small thing: the current submission does not compile with
wrappers turned on. However, I couldn't figure out how to fix the wrappers.
Best regards,
John
Maciej Krol wrote:
Hi all,
I have implement frame based expiration of PagedLOD children. Sorry, I
forgot to attach the files last time.
New attribute DatabasePager::_expiryFrames sets number of frames a
PagedLOD child is kept in memory. The attribute is set with
DatabasePager::setExpiryFrames method or OSG_EXPIRY_FRAMES environmental
variable.
New attribute PagedLOD::PerRangeData::_
frameNumber contains frame number of last cull traversal.
Children of PagedLOD are expired when time _AND_ number of frames since
last cull traversal exceed OSG_EXPIRY_DELAY _AND_ OSG_EXPIRY_FRAMES
respectively. By default OSG_EXPIRY_FRAMES = 1 which means that nodes
from last cull/rendering
traversal will not be expired even if last cull time exceeds
OSG_EXPIRY_DELAY. Setting OSG_EXPIRY_FRAMES = 0 revokes previous
behaviour of PagedLOD.
Setting OSG_EXPIRY_FRAMES > 0 fixes problems of children reloading in
lazy rendering applications. Required behaviour is achieved by
manipulating OSG_EXPIRY_DELAY and OSG_EXPIRY_FRAMES together.
Two interface changes are made:
DatabasePager::updateSceneGraph(double currentFrameTime) is replaced by
DatabasePager::updateSceneGraph(const osg::FrameStamp &frameStamp). The
previous method is in #if 0 clause in the header file. Robert, decide if
You want to include it.
PagedLOD::removeExpiredChildren(double expiryTime, NodeList
&removedChildren) is deprecated (warning is printed), when subclassing
use PagedLOD::removeExpiredChildren(double expiryTime, int expiryFrame,
NodeList &removedChildren) instead.
Regards,
Maciej Krol
--
This message has been scanned for viruses and
dangerous content by *MailScanner* <http://www.mailscanner.info/>, and is
believed to be clean.
------------------------------------------------------------------------
_______________________________________________
osg-submissions mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org
--
Best regards,
John
WeatherOne
--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.
_______________________________________________
osg-submissions mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org