Fixed possible compile error (Thanks to MrFraggy)
Former-commit-id: cc58636d84925229808da26436e41331e6ee8482
This commit is contained in:
@@ -170,7 +170,7 @@ void NzScene::Draw()
|
|||||||
std::sort(visibleLights.begin(), visibleLights.end(), lightComparator);
|
std::sort(visibleLights.begin(), visibleLights.end(), lightComparator);
|
||||||
|
|
||||||
const unsigned int maxLightPerObject = 3; ///TODO: Config
|
const unsigned int maxLightPerObject = 3; ///TODO: Config
|
||||||
unsigned int max = std::min(std::min(maxLights - lightIndex, maxLightPerObject), visibleLights.size());
|
unsigned int max = std::min(std::min(maxLights - lightIndex, maxLightPerObject), static_cast<unsigned int>(visibleLights.size()));
|
||||||
for (unsigned int i = 0; i < max; ++i)
|
for (unsigned int i = 0; i < max; ++i)
|
||||||
visibleLights[i]->Apply(shader, lightIndex + i);
|
visibleLights[i]->Apply(shader, lightIndex + i);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user