Fixed updating of lights.
This commit is contained in:
parent
1492a312ed
commit
df230ea677
@ -204,8 +204,10 @@ void Graphics::updateClosestLights() {
|
|||||||
std::sort(closestLights.begin(),
|
std::sort(closestLights.begin(),
|
||||||
closestLights.end(),
|
closestLights.end(),
|
||||||
[this](Light a, Light b) {return compareLightDistances(a, b); });
|
[this](Light a, Light b) {return compareLightDistances(a, b); });
|
||||||
closestLights = std::vector<Light>(&closestLights[0],
|
if (level->getLights()->size() > 32) {
|
||||||
&closestLights[31]);
|
closestLights = std::vector<Light>(&closestLights[0],
|
||||||
|
&closestLights[31]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Graphics::updateShaderLights() {
|
void Graphics::updateShaderLights() {
|
||||||
|
Loading…
Reference in New Issue
Block a user