From d750d182e58f2a236bbf0a04806f2702a518b97e Mon Sep 17 00:00:00 2001 From: Brecht Van Lommel Date: Thu, 14 Sep 2017 21:53:00 +0200 Subject: Code cleanup: remove hack to avoid seeing transparent objects in noise. Previously the Sobol pattern suffered from some correlation issues that made the outline of objects like a smoke domain visible. This helps simplify the code and also makes some other optimizations possible. --- intern/cycles/kernel/kernel_volume.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'intern/cycles/kernel/kernel_volume.h') diff --git a/intern/cycles/kernel/kernel_volume.h b/intern/cycles/kernel/kernel_volume.h index d8e8e192ab2..bdaba2e2e4b 100644 --- a/intern/cycles/kernel/kernel_volume.h +++ b/intern/cycles/kernel/kernel_volume.h @@ -379,13 +379,13 @@ ccl_device VolumeIntegrateResult kernel_volume_integrate_homogeneous( /* pick random color channel, we use the Veach one-sample * model with balance heuristic for the channels */ - float rphase = path_state_rng_1D_for_decision(kg, state, PRNG_PHASE); + float rphase = path_state_rng_1D(kg, state, PRNG_PHASE); int channel = (int)(rphase*3.0f); sd->randb_closure = rphase*3.0f - channel; /* decide if we will hit or miss */ bool scatter = true; - float xi = path_state_rng_1D_for_decision(kg, state, PRNG_SCATTER_DISTANCE); + float xi = path_state_rng_1D(kg, state, PRNG_SCATTER_DISTANCE); if(probalistic_scatter) { float sample_sigma_t = kernel_volume_channel_get(sigma_t, channel); @@ -483,8 +483,8 @@ ccl_device VolumeIntegrateResult kernel_volume_integrate_heterogeneous_distance( /* pick random color channel, we use the Veach one-sample * model with balance heuristic for the channels */ - float xi = path_state_rng_1D_for_decision(kg, state, PRNG_SCATTER_DISTANCE); - float rphase = path_state_rng_1D_for_decision(kg, state, PRNG_PHASE); + float xi = path_state_rng_1D(kg, state, PRNG_SCATTER_DISTANCE); + float rphase = path_state_rng_1D(kg, state, PRNG_PHASE); int channel = (int)(rphase*3.0f); sd->randb_closure = rphase*3.0f - channel; bool has_scatter = false; -- cgit v1.2.3