[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [53719] trunk/blender/intern/cycles/kernel /kernel_path.h: Fix #33824: cycles non-progressive render mode did not do correct path termination,
Brecht Van Lommel
brechtvanlommel at pandora.be
Thu Jan 10 20:28:18 CET 2013
Revision: 53719
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=53719
Author: blendix
Date: 2013-01-10 19:28:16 +0000 (Thu, 10 Jan 2013)
Log Message:
-----------
Fix #33824: cycles non-progressive render mode did not do correct path termination,
leading to too much noise when the min bounce setting was lower than max bounce.
Modified Paths:
--------------
trunk/blender/intern/cycles/kernel/kernel_path.h
Modified: trunk/blender/intern/cycles/kernel/kernel_path.h
===================================================================
--- trunk/blender/intern/cycles/kernel/kernel_path.h 2013-01-10 18:54:01 UTC (rev 53718)
+++ trunk/blender/intern/cycles/kernel/kernel_path.h 2013-01-10 19:28:16 UTC (rev 53719)
@@ -486,7 +486,8 @@
#ifdef __NON_PROGRESSIVE__
__device void kernel_path_indirect(KernelGlobals *kg, RNG *rng, int sample, Ray ray, __global float *buffer,
- float3 throughput, float min_ray_pdf, float ray_pdf, PathState state, int rng_offset, PathRadiance *L)
+ float3 throughput, float throughput_normalize,
+ float min_ray_pdf, float ray_pdf, PathState state, int rng_offset, PathRadiance *L)
{
#ifdef __LAMP_MIS__
float ray_t = 0.0f;
@@ -558,7 +559,7 @@
/* path termination. this is a strange place to put the termination, it's
* mainly due to the mixed in MIS that we use. gives too many unneeded
* shader evaluations, only need emission if we are going to terminate */
- float probability = path_state_terminate_probability(kg, &state, throughput);
+ float probability = path_state_terminate_probability(kg, &state, throughput*throughput_normalize);
float terminate = path_rng(kg, rng, sample, rng_offset + PRNG_TERMINATE);
if(terminate >= probability) {
@@ -946,7 +947,8 @@
#endif
kernel_path_indirect(kg, rng, sample*num_samples + j, bsdf_ray, buffer,
- tp*num_samples_inv, min_ray_pdf, bsdf_pdf, ps, rng_offset+PRNG_BOUNCE_NUM, &L);
+ tp*num_samples_inv, num_samples,
+ min_ray_pdf, bsdf_pdf, ps, rng_offset+PRNG_BOUNCE_NUM, &L);
}
}
More information about the Bf-blender-cvs
mailing list