[Bf-blender-cvs] [9702eac251b] soc-2022-many-lights-sampling: Cleanup: `sample_reservoir()` should not choose -1 now

Weizhen Huang noreply at git.blender.org
Mon Nov 21 19:30:57 CET 2022


Commit: 9702eac251b8bc1f763a383b175d489276f28daa
Author: Weizhen Huang
Date:   Mon Nov 21 19:29:41 2022 +0100
Branches: soc-2022-many-lights-sampling
https://developer.blender.org/rB9702eac251b8bc1f763a383b175d489276f28daa

Cleanup: `sample_reservoir()` should not choose -1 now

===================================================================

M	intern/cycles/kernel/light/tree.h

===================================================================

diff --git a/intern/cycles/kernel/light/tree.h b/intern/cycles/kernel/light/tree.h
index 560c25e9197..58c51c529b3 100644
--- a/intern/cycles/kernel/light/tree.h
+++ b/intern/cycles/kernel/light/tree.h
@@ -432,9 +432,6 @@ ccl_device int light_tree_cluster_select_emitter(KernelGlobals kg,
                         rand);
         has_importance >>= 1;
       }
-      if (selected_index == -1) {
-        return -1;
-      }
 
       float discard;
       light_tree_emitter_importance<in_volume_segment>(



More information about the Bf-blender-cvs mailing list