Merge branch 'master' of github.com:Faerbit/swp

This commit is contained in:
Jasper 2015-02-13 17:36:11 +01:00
commit 3d59fb43c8

View File

@ -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); });
if (level->getLights()->size() > 32) {
closestLights = std::vector<Light>(&closestLights[0], closestLights = std::vector<Light>(&closestLights[0],
&closestLights[31]); &closestLights[31]);
}
} }
void Graphics::updateShaderLights() { void Graphics::updateShaderLights() {