diff options
Diffstat (limited to 'intern/cycles/kernel/split')
-rw-r--r-- | intern/cycles/kernel/split/kernel_shader_eval.h | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/intern/cycles/kernel/split/kernel_shader_eval.h b/intern/cycles/kernel/split/kernel_shader_eval.h index c792c4adb0e..7032461b04a 100644 --- a/intern/cycles/kernel/split/kernel_shader_eval.h +++ b/intern/cycles/kernel/split/kernel_shader_eval.h @@ -52,8 +52,14 @@ ccl_device void kernel_shader_eval(KernelGlobals *kg) shader_eval_surface(kg, &kernel_split_state.sd[ray_index], state, state->flag); #ifdef __BRANCHED_PATH__ - shader_merge_closures(&kernel_split_state.sd[ray_index]); -#endif /* __BRANCHED_PATH__ */ + if(kernel_data.integrator.branched) { + shader_merge_closures(&kernel_split_state.sd[ray_index]); + } + else +#endif + { + shader_prepare_closures(&kernel_split_state.sd[ray_index], state); + } } } |