From Daniel Stien, "When removing a child from a osg::Group, childRemoved is called after the
node has already been erased from the node list, causing childRemoved to be performed on the consecutive node. Lines 180 and 182 are swapped in the attached Group.cpp. "
This commit is contained in:
parent
2d407a8c0c
commit
4b05e84d59
@ -177,10 +177,10 @@ bool Group::removeChildren(unsigned int pos,unsigned int numChildrenToRemove)
|
||||
|
||||
}
|
||||
|
||||
_children.erase(_children.begin()+pos,_children.begin()+endOfRemoveRange);
|
||||
|
||||
childRemoved(pos,endOfRemoveRange-pos);
|
||||
|
||||
_children.erase(_children.begin()+pos,_children.begin()+endOfRemoveRange);
|
||||
|
||||
if (updateCallbackRemoved)
|
||||
{
|
||||
setNumChildrenRequiringUpdateTraversal(getNumChildrenRequiringUpdateTraversal()-updateCallbackRemoved);
|
||||
|
Loading…
Reference in New Issue
Block a user