Cycles: better path termination for transparency.
[blender.git] / intern / cycles / kernel / kernel_emission.h
index 94b0a37ce6201c0ea2f71df2330aa9bf093f840d..5875249b4049469451a8701bb6bdc9c7c0719de0 100644 (file)
@@ -67,13 +67,13 @@ ccl_device_noinline float3 direct_emissive_eval(KernelGlobals *kg,
 
                ls->Ng = emission_sd->Ng;
 
-               /* no path flag, we're evaluating this for all closures. that's weak but
-                * we'd have to do multiple evaluations otherwise */
+               /* No proper path flag, we're evaluating this for all closures. that's
+                * weak but we'd have to do multiple evaluations otherwise. */
                path_state_modify_bounce(state, true);
-               shader_eval_surface(kg, emission_sd, state, 0, 0);
+               shader_eval_surface(kg, emission_sd, state, PATH_RAY_EMISSION);
                path_state_modify_bounce(state, false);
 
-               /* evaluate emissive closure */
+               /* Evaluate emissive closure. */
                eval = shader_emissive_eval(kg, emission_sd);
        }