Fix #144258: Cycles: Subsurface scattering doesn't work with shadow linking
When shadow linking is enabled, `intersect_dedicated_light` is scheduled even if the `PATH_RAY_SUBSURFACE` flag is set. This checks the flag and schedules `intersect_subsurface` instead. Pull Request: https://projects.blender.org/blender/blender/pulls/145621
This commit is contained in:
committed by
Brecht Van Lommel
parent
84e2795ee2
commit
11d98c14b7
@@ -853,8 +853,8 @@ ccl_device_forceinline void integrator_shade_surface(KernelGlobals kg,
|
||||
|
||||
#ifdef __SHADOW_LINKING__
|
||||
/* No need to cast shadow linking rays at a transparent bounce: the lights will be accumulated
|
||||
* via the main path in this case. */
|
||||
if ((continue_path_label & LABEL_TRANSPARENT) == 0) {
|
||||
* via the main path in this case. BSSRDF bounces continue with intersect_subsurface. */
|
||||
if ((continue_path_label & (LABEL_TRANSPARENT | LABEL_SUBSURFACE_SCATTER)) == 0) {
|
||||
if (shadow_linking_schedule_intersection_kernel<current_kernel>(kg, state)) {
|
||||
return;
|
||||
}
|
||||
|
||||
BIN
tests/files/render/light_linking/cycles_renders/shadow_link_subsurface.png
(Stored with Git LFS)
Normal file
BIN
tests/files/render/light_linking/cycles_renders/shadow_link_subsurface.png
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
tests/files/render/light_linking/eevee_renders/shadow_link_subsurface.png
(Stored with Git LFS)
Normal file
BIN
tests/files/render/light_linking/eevee_renders/shadow_link_subsurface.png
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
tests/files/render/light_linking/shadow_link_subsurface.blend
(Stored with Git LFS)
Normal file
BIN
tests/files/render/light_linking/shadow_link_subsurface.blend
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
tests/files/render/light_linking/storm_hydra_renders/shadow_link_subsurface.png
(Stored with Git LFS)
Normal file
BIN
tests/files/render/light_linking/storm_hydra_renders/shadow_link_subsurface.png
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
tests/files/render/light_linking/storm_usd_renders/shadow_link_subsurface.png
(Stored with Git LFS)
Normal file
BIN
tests/files/render/light_linking/storm_usd_renders/shadow_link_subsurface.png
(Stored with Git LFS)
Normal file
Binary file not shown.
BIN
tests/files/render/light_linking/workbench_renders/shadow_link_subsurface.png
(Stored with Git LFS)
Normal file
BIN
tests/files/render/light_linking/workbench_renders/shadow_link_subsurface.png
(Stored with Git LFS)
Normal file
Binary file not shown.
Reference in New Issue
Block a user