Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2016-01-14 17:58:22 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2016-01-28 20:59:27 +0300
commite2161ca854da03bae8c17c7cfac6dbcd9d62f33b (patch)
tree6e5a2e0afc4fca9ae226dce79caefad82cc5b07a /intern/cycles/kernel/kernel_shadow.h
parent53ef03d20f5ce1dc0c6cb49c759f0be3f467340f (diff)
Cycles: Remove few function arguments needed only for the split kernel
Use KernelGlobals to access all the global arrays for the intermediate storage instead of passing all this storage things explicitly. Tested here with Intel OpenCL, NVIDIA GTX580 and AMD Fiji, didn't see any artifacts, so guess it's all good. Reviewers: juicyfruit, dingto, lukasstockner97 Differential Revision: https://developer.blender.org/D1736
Diffstat (limited to 'intern/cycles/kernel/kernel_shadow.h')
-rw-r--r--intern/cycles/kernel/kernel_shadow.h10
1 files changed, 3 insertions, 7 deletions
diff --git a/intern/cycles/kernel/kernel_shadow.h b/intern/cycles/kernel/kernel_shadow.h
index e86051095a5..aefa5d5be85 100644
--- a/intern/cycles/kernel/kernel_shadow.h
+++ b/intern/cycles/kernel/kernel_shadow.h
@@ -186,11 +186,7 @@ ccl_device_inline bool shadow_blocked(KernelGlobals *kg, PathState *state, Ray *
ccl_device_noinline bool shadow_blocked(KernelGlobals *kg,
ccl_addr_space PathState *state,
ccl_addr_space Ray *ray_input,
- float3 *shadow
-#ifdef __SPLIT_KERNEL__
- , ShaderData *sd_mem, Intersection *isect_mem
-#endif
- )
+ float3 *shadow)
{
*shadow = make_float3(1.0f, 1.0f, 1.0f);
@@ -205,7 +201,7 @@ ccl_device_noinline bool shadow_blocked(KernelGlobals *kg,
#endif
#ifdef __SPLIT_KERNEL__
- Intersection *isect = isect_mem;
+ Intersection *isect = &kg->isect_shadow[TIDX];
#else
Intersection isect_object;
Intersection *isect = &isect_object;
@@ -254,7 +250,7 @@ ccl_device_noinline bool shadow_blocked(KernelGlobals *kg,
/* setup shader data at surface */
#ifdef __SPLIT_KERNEL__
- ShaderData *sd = sd_mem;
+ ShaderData *sd = kg->sd_input;
#else
ShaderData sd_object;
ShaderData *sd = &sd_object;