diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2016-02-07 04:18:51 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2016-02-07 04:20:06 +0300 |
commit | 578f70f28869aacd354abe85298b731f92d0e5be (patch) | |
tree | 32c73e35958a4c6901667a6ccc2141bba87e6ee9 /intern | |
parent | 76eac1ae70001f5b2b0fe1d064f260db8509b246 (diff) |
Cycles: Fix access uninitialized light after recent refactor/fixes
Diffstat (limited to 'intern')
-rw-r--r-- | intern/cycles/render/light.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/intern/cycles/render/light.cpp b/intern/cycles/render/light.cpp index 8bb5fec959f..1637045ce84 100644 --- a/intern/cycles/render/light.cpp +++ b/intern/cycles/render/light.cpp @@ -206,7 +206,7 @@ void LightManager::device_update_distribution(Device *device, DeviceScene *dscen bool background_mis = false; foreach(Light *light, scene->lights) { - if(light->has_contribution(scene)) + if(light->is_enabled) num_lights++; } @@ -345,7 +345,7 @@ void LightManager::device_update_distribution(Device *device, DeviceScene *dscen int light_index = 0; foreach(Light *light, scene->lights) { - if(!light->has_contribution(scene)) + if(!light->is_enabled) continue; distribution[offset].x = totarea; |