Optimized scheduling once again.

This commit is contained in:
Faerbit 2015-06-04 11:22:27 +02:00
parent 3437ce6173
commit fe8b0a57cd

View File

@ -690,7 +690,7 @@ void Graphics::updateLights() {
// update priority of the shadow render queue
for(unsigned int i = 0; i<shadowRenderQueue.size(); i++) {
float distance = glm::distance(level->getCameraCenter()->getPosition(), shadowRenderQueue.at(i).light->getPosition());
shadowRenderQueue.at(i).priority = (int) 100*std::exp(5.0f - 0.05f * distance);
shadowRenderQueue.at(i).priority = (int) 100*std::exp(5.0f - 0.1f * distance);
}
// Build light position array