diff options
Diffstat (limited to 'intern/cycles/kernel/kernel_subsurface.h')
-rw-r--r-- | intern/cycles/kernel/kernel_subsurface.h | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/intern/cycles/kernel/kernel_subsurface.h b/intern/cycles/kernel/kernel_subsurface.h index 582a20704d3..f4759b26191 100644 --- a/intern/cycles/kernel/kernel_subsurface.h +++ b/intern/cycles/kernel/kernel_subsurface.h @@ -135,7 +135,6 @@ ccl_device float3 subsurface_color_pow(float3 color, float exponent) ccl_device void subsurface_color_bump_blur(KernelGlobals *kg, ShaderData *sd, ccl_addr_space PathState *state, - int state_flag, float3 *eval, float3 *N) { @@ -148,7 +147,7 @@ ccl_device void subsurface_color_bump_blur(KernelGlobals *kg, if(bump || texture_blur > 0.0f) { /* average color and normal at incoming point */ - shader_eval_surface(kg, sd, state, state_flag, kernel_data.integrator.max_closures); + shader_eval_surface(kg, sd, state, state->flag, kernel_data.integrator.max_closures); float3 in_color = shader_bssrdf_sum(sd, (bump)? N: NULL, NULL); /* we simply divide out the average color and multiply with the average @@ -311,9 +310,7 @@ ccl_device_noinline void subsurface_scatter_multi_setup( int hit, ShaderData *sd, ccl_addr_space PathState *state, - int state_flag, - const ShaderClosure *sc, - bool all) + const ShaderClosure *sc) { #ifdef __SPLIT_KERNEL__ Ray ray_object = ss_isect->ray; @@ -333,7 +330,7 @@ ccl_device_noinline void subsurface_scatter_multi_setup( /* Optionally blur colors and bump mapping. */ float3 weight = ss_isect->weight[hit]; float3 N = sd->N; - subsurface_color_bump_blur(kg, sd, state, state_flag, &weight, &N); + subsurface_color_bump_blur(kg, sd, state, &weight, &N); /* Setup diffuse BSDF. */ subsurface_scatter_setup_diffuse_bsdf(kg, sd, sc, weight, true, N); @@ -341,7 +338,7 @@ ccl_device_noinline void subsurface_scatter_multi_setup( /* subsurface scattering step, from a point on the surface to another nearby point on the same object */ ccl_device void subsurface_scatter_step(KernelGlobals *kg, ShaderData *sd, ccl_addr_space PathState *state, - int state_flag, const ShaderClosure *sc, uint *lcg_state, float disk_u, float disk_v, bool all) + const ShaderClosure *sc, uint *lcg_state, float disk_u, float disk_v, bool all) { float3 eval = make_float3(0.0f, 0.0f, 0.0f); @@ -430,7 +427,7 @@ ccl_device void subsurface_scatter_step(KernelGlobals *kg, ShaderData *sd, ccl_a /* optionally blur colors and bump mapping */ float3 N = sd->N; - subsurface_color_bump_blur(kg, sd, state, state_flag, &eval, &N); + subsurface_color_bump_blur(kg, sd, state, &eval, &N); /* setup diffuse bsdf */ subsurface_scatter_setup_diffuse_bsdf(kg, sd, sc, eval, (ss_isect.num_hits > 0), N); |