Qarning fixes, and updated the date in NEWS to reflect todays release of 0.8.45
This commit is contained in:
@@ -28,7 +28,7 @@ extern osg::Node *makeClouds( void );
|
||||
struct MoveEarthySkyWithEyePointCallback : public osg::Transform::ComputeTransformCallback
|
||||
{
|
||||
/** Get the transformation matrix which moves from local coords to world coords.*/
|
||||
virtual const bool computeLocalToWorldMatrix(osg::Matrix& matrix,const osg::Transform* transform, osg::NodeVisitor* nv) const
|
||||
virtual const bool computeLocalToWorldMatrix(osg::Matrix& matrix,const osg::Transform*, osg::NodeVisitor* nv) const
|
||||
{
|
||||
osgUtil::CullVisitor* cv = dynamic_cast<osgUtil::CullVisitor*>(nv);
|
||||
if (cv)
|
||||
@@ -40,7 +40,7 @@ struct MoveEarthySkyWithEyePointCallback : public osg::Transform::ComputeTransfo
|
||||
}
|
||||
|
||||
/** Get the transformation matrix which moves from world coords to local coords.*/
|
||||
virtual const bool computeWorldToLocalMatrix(osg::Matrix& matrix,const osg::Transform* transform, osg::NodeVisitor* nv) const
|
||||
virtual const bool computeWorldToLocalMatrix(osg::Matrix& matrix,const osg::Transform*, osg::NodeVisitor* nv) const
|
||||
{
|
||||
osgUtil::CullVisitor* cv = dynamic_cast<osgUtil::CullVisitor*>(nv);
|
||||
if (cv)
|
||||
|
||||
@@ -52,7 +52,7 @@ bool Group_writeLocalData(const Object& obj, Output& fw)
|
||||
const Group& group = static_cast<const Group&>(obj);
|
||||
|
||||
fw.indent() << "num_children " << group.getNumChildren() << std::endl;
|
||||
for(int i=0;i<group.getNumChildren();++i)
|
||||
for(unsigned int i=0;i<group.getNumChildren();++i)
|
||||
{
|
||||
fw.writeObject(*group.getChild(i));
|
||||
}
|
||||
|
||||
@@ -90,7 +90,7 @@ bool LOD_writeLocalData(const Object& obj, Output& fw)
|
||||
fw.indent() << "Ranges {"<< std::endl;
|
||||
fw.moveIn();
|
||||
|
||||
for(int i=0; i<lod.getNumRanges();++i)
|
||||
for(unsigned int i=0; i<lod.getNumRanges();++i)
|
||||
{
|
||||
fw.indent() << lod.getRange(i) << std::endl;
|
||||
}
|
||||
|
||||
@@ -144,12 +144,12 @@ void InsertImpostorsVisitor::insertImpostors()
|
||||
osg::Impostor* impostor = osgNew Impostor;
|
||||
|
||||
// standard LOD settings
|
||||
for(int ci=0;ci<lod->getNumChildren();++ci)
|
||||
for(unsigned int ci=0;ci<lod->getNumChildren();++ci)
|
||||
{
|
||||
impostor->addChild(lod->getChild(ci));
|
||||
}
|
||||
|
||||
for(int ri=0;ri<lod->getNumRanges();++ri)
|
||||
for(unsigned int ri=0;ri<lod->getNumRanges();++ri)
|
||||
{
|
||||
impostor->setRange(ri,lod->getRange(ri));
|
||||
}
|
||||
|
||||
@@ -380,7 +380,7 @@ void Optimizer::FlattenStaticTransformsVisitor::doTransform(osg::Object* obj,osg
|
||||
lod->setCenter(lod->getCenter()*matrix);
|
||||
|
||||
// adjust ranges to new scale.
|
||||
for(int i=0;i<lod->getNumRanges();++i)
|
||||
for(unsigned int i=0;i<lod->getNumRanges();++i)
|
||||
{
|
||||
lod->setRange(i,lod->getRange(i)*ratio);
|
||||
}
|
||||
@@ -528,16 +528,15 @@ void Optimizer::FlattenStaticTransformsVisitor::removeTransforms()
|
||||
osg::ref_ptr<osg::Transform> transform = titr->first;
|
||||
osg::ref_ptr<osg::Group> group = osgNew osg::Group;
|
||||
|
||||
int i;
|
||||
for(i=0;i<transform->getNumChildren();++i)
|
||||
for(unsigned int i=0;i<transform->getNumChildren();++i)
|
||||
{
|
||||
for(int j=0;j<transform->getNumParents();++j)
|
||||
for(unsigned int j=0;j<transform->getNumParents();++j)
|
||||
{
|
||||
group->addChild(transform->getChild(i));
|
||||
}
|
||||
}
|
||||
|
||||
for(i=transform->getNumParents()-1;i>=0;--i)
|
||||
for(int i=transform->getNumParents()-1;i>=0;--i)
|
||||
{
|
||||
transform->getParent(i)->replaceChild(transform.get(),group.get());
|
||||
}
|
||||
@@ -623,7 +622,7 @@ void Optimizer::RemoveRedundentNodesVisitor::removeRedundentNodes()
|
||||
////////////////////////////////////////////////////////////////////////////
|
||||
void Optimizer::CombineLODsVisitor::apply(osg::LOD& lod)
|
||||
{
|
||||
for(int i=0;i<lod.getNumParents();++i)
|
||||
for(unsigned int i=0;i<lod.getNumParents();++i)
|
||||
{
|
||||
if (typeid(*lod.getParent(i))==typeid(osg::Group))
|
||||
{
|
||||
@@ -646,7 +645,7 @@ void Optimizer::CombineLODsVisitor::combineLODs()
|
||||
|
||||
LODSet lodChildren;
|
||||
|
||||
for(int i=0;i<group->getNumChildren();++i)
|
||||
for(unsigned int i=0;i<group->getNumChildren();++i)
|
||||
{
|
||||
osg::Node* child = group->getChild(i);
|
||||
osg::LOD* lod = dynamic_cast<osg::LOD*>(child);
|
||||
@@ -686,7 +685,7 @@ void Optimizer::CombineLODsVisitor::combineLODs()
|
||||
{
|
||||
|
||||
osg::LOD* lod = *lod_itr;
|
||||
for(int i=0;i<lod->getNumRanges()-1;++i)
|
||||
for(unsigned int i=0;i<lod->getNumRanges()-1;++i)
|
||||
{
|
||||
if (maxRange<lod->getRange(i+1)) maxRange = lod->getRange(i+1);
|
||||
rangeMap.insert(RangeMap::value_type(RangePair(lod->getRange(i),lod->getRange(i+1)),lod->getChild(i)));
|
||||
|
||||
Reference in New Issue
Block a user