Hi Tim,

On Thu, May 27, 2010 at 5:02 PM, Tim Moore <[email protected]> wrote:
> Hi Robert,
> Here are some cleanup patches for removeExpiredSubgraphs. The main feature
> is removing the need for the localChildrenRemoved vectors. I also replaced a
> couple of loops with STL constructs where I thought it made the code
> clearer. Finally, changed some of the variables like numToPrune to
> consistantly be of type size_t.

Jikes, not sure I agree that using STL algorithms here make the code
cleaner, rather it adds an extra functor into the fix just to use the
algorithms but in doing so obscures what the code is doing.    Perhaps
the best thing to have done would have been to have a convenience
traverse method in CountPagedLODVisitor that traversed the NodeList
between the specified children.

Changing to type to size_t is not safe as the maths done in the method
can result in negative values, int's were used for a reason so just
discarding them is not safe.  None of the containers that the pager
will be working with will get any where the limits of int so I'm not
sure what these changes are for.  Is it a warning that you were trying
to clean up?

Robert.
_______________________________________________
osg-submissions mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-submissions-openscenegraph.org

Reply via email to