Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'intern/cycles/render/light.cpp')
-rw-r--r--intern/cycles/render/light.cpp12
1 files changed, 5 insertions, 7 deletions
diff --git a/intern/cycles/render/light.cpp b/intern/cycles/render/light.cpp
index 8c7a21da561..dc3f7c8f8ac 100644
--- a/intern/cycles/render/light.cpp
+++ b/intern/cycles/render/light.cpp
@@ -221,13 +221,11 @@ void LightManager::disable_ineffective_light(Scene *scene)
*/
Shader *shader = (scene->background->shader) ? scene->background->shader :
scene->default_background;
- bool disable_mis = !(has_portal || shader->has_surface_spatial_varying);
- if (disable_mis) {
- VLOG(1) << "Background MIS has been disabled.\n";
- foreach (Light *light, scene->lights) {
- if (light->type == LIGHT_BACKGROUND) {
- light->is_enabled = false;
- }
+ const bool disable_mis = !(has_portal || shader->has_surface_spatial_varying);
+ VLOG_IF(1, disable_mis) << "Background MIS has been disabled.\n";
+ foreach (Light *light, scene->lights) {
+ if (light->type == LIGHT_BACKGROUND) {
+ light->is_enabled = !disable_mis;
}
}
}