diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-02-20 16:22:40 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2018-02-22 02:55:32 +0300 |
commit | 2d81758aa650256d6b6ed283e43b6c35808ed205 (patch) | |
tree | db336da6924982031bbcc30844b496d600fd407a /intern/cycles/kernel/kernel_path.h | |
parent | 84e92f9b3c50433221a4c30f3a14713d99680f3a (diff) |
Cycles: better path termination for transparency.
We now continue transparent paths after diffuse/glossy/transmission/volume
bounces are exceeded. This avoids unexpected boundaries in volumes with
transparent boundaries. It is also required for MIS to work correctly with
transparent surfaces, as we also continue through these in shadow rays.
The main visible changes is that volumes will now be lit by the background
even at volume bounces 0, same as surfaces.
Fixes T53914 and T54103.
Diffstat (limited to 'intern/cycles/kernel/kernel_path.h')
-rw-r--r-- | intern/cycles/kernel/kernel_path.h | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/intern/cycles/kernel/kernel_path.h b/intern/cycles/kernel/kernel_path.h index 4728a25a3bc..aef350b0658 100644 --- a/intern/cycles/kernel/kernel_path.h +++ b/intern/cycles/kernel/kernel_path.h @@ -446,11 +446,8 @@ ccl_device void kernel_path_indirect(KernelGlobals *kg, } /* Setup and evaluate shader. */ - shader_setup_from_ray(kg, - sd, - &isect, - ray); - shader_eval_surface(kg, sd, state, state->flag, kernel_data.integrator.max_closures); + shader_setup_from_ray(kg, sd, &isect, ray); + shader_eval_surface(kg, sd, state, state->flag); shader_prepare_closures(sd, state); /* Apply shadow catcher, holdout, emission. */ @@ -610,7 +607,7 @@ ccl_device_forceinline void kernel_path_integrate( /* Setup and evaluate shader. */ shader_setup_from_ray(kg, &sd, &isect, ray); - shader_eval_surface(kg, &sd, state, state->flag, kernel_data.integrator.max_closures); + shader_eval_surface(kg, &sd, state, state->flag); shader_prepare_closures(&sd, state); /* Apply shadow catcher, holdout, emission. */ |