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:
authorLukas Stockner <lukasstockner97>2019-12-08 23:19:37 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2019-12-12 15:04:43 +0300
commit3437c9c3bf3d16a5ae070226d927a3a329239c8c (patch)
treef7ad2b332a4200caa8d57ac85199ac760fc6bfeb /intern/cycles/kernel/kernel_path_branched.h
parent85b7d397f7620b57ce4014ee7b0119eef64578d9 (diff)
Cycles: perform clamping per light contribution instead of whole path
With upcoming light group passes, for them to sum up correctly to the combined pass the clamping must be more fine grained. This also has the advantage that if one light is particularly noisy, it does not diminish the contribution from other lights which do not need as much clamping. Clamp values on existing scenes will need to be tweaked to get similar results, there is no automatic conversion possible which would give the same results as before. Implemented by Lukas, with tweaks by Brecht. Part of D4837
Diffstat (limited to 'intern/cycles/kernel/kernel_path_branched.h')
-rw-r--r--intern/cycles/kernel/kernel_path_branched.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/intern/cycles/kernel/kernel_path_branched.h b/intern/cycles/kernel/kernel_path_branched.h
index 39309379f0c..f75e4ab4c97 100644
--- a/intern/cycles/kernel/kernel_path_branched.h
+++ b/intern/cycles/kernel/kernel_path_branched.h
@@ -55,7 +55,7 @@ ccl_device_inline void kernel_branched_path_ao(KernelGlobals *kg,
if (!shadow_blocked(kg, sd, emission_sd, state, &light_ray, &ao_shadow)) {
path_radiance_accum_ao(
- L, state, throughput * num_samples_inv, ao_alpha, ao_bsdf, ao_shadow);
+ kg, L, state, throughput * num_samples_inv, ao_alpha, ao_bsdf, ao_shadow);
}
else {
path_radiance_accum_total_ao(L, state, throughput * num_samples_inv, ao_bsdf);
@@ -146,7 +146,7 @@ ccl_device_forceinline void kernel_branched_path_volume(KernelGlobals *kg,
/* emission and transmittance */
if (volume_segment.closure_flag & SD_EMISSION)
- path_radiance_accum_emission(L, state, *throughput, volume_segment.accum_emission);
+ path_radiance_accum_emission(kg, L, state, *throughput, volume_segment.accum_emission);
*throughput *= volume_segment.accum_transmittance;
/* free cached steps */
@@ -376,7 +376,7 @@ ccl_device void kernel_branched_path_integrate(KernelGlobals *kg,
/* initialize */
float3 throughput = make_float3(1.0f, 1.0f, 1.0f);
- path_radiance_init(L, kernel_data.film.use_light_pass);
+ path_radiance_init(kg, L);
/* shader data memory used for both volumes and surfaces, saves stack space */
ShaderData sd;