From Jannik Heller, Wrong function call in setTextureAttributeAndModes

"From I think that this piece of code in StateSet::setTextureAttributeAndModes is a copy&paste mistake:

            OSG_NOTICE<<"Warning: non texture attribute '"<<attribute->className()<<"' passed to setTextureAttributeAndModes(unit,attr,value), "<<std::endl;
            OSG_NOTICE<<"         assuming setAttributeAndModes(attr,value) instead."<<std::endl;
            OSG_NOTICE<<"         please change calling code to use appropriate call."<<std::endl;
            setAttribute(attribute,value);

As per the warning message it should be calling setAttributeAndModes(attribute,value); ."
This commit is contained in:
Robert Osfield 2016-03-11 15:35:07 +00:00
parent faea95b5fb
commit cb2af961db
2 changed files with 1 additions and 1 deletions

View File

@ -1296,7 +1296,7 @@ void StateSet::setTextureAttributeAndModes(unsigned int unit,StateAttribute *att
OSG_NOTICE<<"Warning: non texture attribute '"<<attribute->className()<<"' passed to setTextureAttributeAndModes(unit,attr,value), "<<std::endl; OSG_NOTICE<<"Warning: non texture attribute '"<<attribute->className()<<"' passed to setTextureAttributeAndModes(unit,attr,value), "<<std::endl;
OSG_NOTICE<<" assuming setAttributeAndModes(attr,value) instead."<<std::endl; OSG_NOTICE<<" assuming setAttributeAndModes(attr,value) instead."<<std::endl;
OSG_NOTICE<<" please change calling code to use appropriate call."<<std::endl; OSG_NOTICE<<" please change calling code to use appropriate call."<<std::endl;
setAttribute(attribute,value); setAttributeAndModes(attribute,value);
} }
} }
} }