diff options
author | Mai Lavelle <mai.lavelle@gmail.com> | 2017-11-09 08:49:15 +0300 |
---|---|---|
committer | Mai Lavelle <mai.lavelle@gmail.com> | 2017-11-09 09:04:06 +0300 |
commit | 087331c495b04ebd37903c0dc0e46262354cf026 (patch) | |
tree | ef63fbab4859021585d002f4782840d6e91365a2 /intern/cycles/kernel/split/kernel_next_iteration_setup.h | |
parent | 6febe6e725381456f39966e0f685da67cfe52bce (diff) |
Cycles: Replace __MAX_CLOSURE__ build option with runtime integrator variable
Goal is to reduce OpenCL kernel recompilations.
Currently viewport renders are still set to use 64 closures as this seems to
be faster and we don't want to cause a performance regression there. Needs
to be investigated.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D2775
Diffstat (limited to 'intern/cycles/kernel/split/kernel_next_iteration_setup.h')
-rw-r--r-- | intern/cycles/kernel/split/kernel_next_iteration_setup.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/intern/cycles/kernel/split/kernel_next_iteration_setup.h b/intern/cycles/kernel/split/kernel_next_iteration_setup.h index c3373174582..bb6bf1cc7e6 100644 --- a/intern/cycles/kernel/split/kernel_next_iteration_setup.h +++ b/intern/cycles/kernel/split/kernel_next_iteration_setup.h @@ -58,7 +58,7 @@ ccl_device void kernel_split_branched_indirect_light_end(KernelGlobals *kg, int kernel_split_branched_path_indirect_loop_end(kg, ray_index); ccl_global float3 *throughput = &kernel_split_state.throughput[ray_index]; - ShaderData *sd = &kernel_split_state.sd[ray_index]; + ShaderData *sd = kernel_split_sd(sd, ray_index); ccl_global PathState *state = &kernel_split_state.path_state[ray_index]; ccl_global Ray *ray = &kernel_split_state.ray[ray_index]; @@ -126,7 +126,7 @@ ccl_device void kernel_next_iteration_setup(KernelGlobals *kg, if(active) { ccl_global float3 *throughput = &kernel_split_state.throughput[ray_index]; ccl_global Ray *ray = &kernel_split_state.ray[ray_index]; - ShaderData *sd = &kernel_split_state.sd[ray_index]; + ShaderData *sd = kernel_split_sd(sd, ray_index); ccl_global PathState *state = &kernel_split_state.path_state[ray_index]; PathRadiance *L = &kernel_split_state.path_radiance[ray_index]; |