Fix Cycles area light using MIS when the spread is zero
area light with zero spread was introduced in bf18032977
. Such paths can
only be sampled with NEE, so MIS should not be used.
This fixes the discrepancy when Direct Light Sampling is set to MIS or NEE.
Pull Request: #118584
This commit is contained in:
parent
f7c94754a0
commit
95d11b0d33
|
@ -1331,7 +1331,7 @@ void LightManager::device_update_lights(Device *device, DeviceScene *dscene, Sce
|
|||
|
||||
float3 dir = safe_normalize(light->get_dir());
|
||||
|
||||
if (light->use_mis && area != 0.0f) {
|
||||
if (light->use_mis && area != 0.0f && light->spread > 0.0f) {
|
||||
shader_id |= SHADER_USE_MIS;
|
||||
}
|
||||
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit 582cf6fcb4e7456a6d29eb016280943646e6bc68
|
||||
Subproject commit 6dd81d3f24ec18cec2ab70d1c4159be3900ccd55
|
Loading…
Reference in New Issue