Utilize std::any_of.

We have <algorithm>. Let's use it.
This commit is contained in:
Jason Felds
2013-04-28 16:50:41 -04:00
parent 201e355c12
commit cb1b5f5fba
+2 -6
View File
@@ -760,12 +760,8 @@ void Model::SetSecondsIntoAnimation( float fSeconds )
bool Model::MaterialsNeedNormals() const
{
for (msMaterial const &m : m_Materials)
{
if( m.NeedsNormals() )
return true;
}
return false;
return std::any_of(m_Materials.begin(), m_Materials.end(),
[&](msMaterial const m) { return m.NeedsNormals(); });
}
// lua start