From cdbac018a2744949683b9206cec1f3e5ea64b679 Mon Sep 17 00:00:00 2001 From: Thomas Dinges Date: Fri, 3 Oct 2014 20:41:38 +0200 Subject: [PATCH] Cycles, some tweaks to scene_intersect_shadow_all() * Function returns a bool, not an uint. * Remove GPU ifdefs, this is CPU only due to malloc / qsort. --- intern/cycles/kernel/geom/geom_bvh.h | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) diff --git a/intern/cycles/kernel/geom/geom_bvh.h b/intern/cycles/kernel/geom/geom_bvh.h index 807b23d15e5..26efddc78e0 100644 --- a/intern/cycles/kernel/geom/geom_bvh.h +++ b/intern/cycles/kernel/geom/geom_bvh.h @@ -250,14 +250,8 @@ uint scene_intersect_subsurface(KernelGlobals *kg, const Ray *ray, Intersection } #endif -/* to work around titan bug when using arrays instead of textures */ #ifdef __SHADOW_RECORD_ALL__ -#if !defined(__KERNEL_CUDA__) || defined(__KERNEL_CUDA_TEX_STORAGE__) -ccl_device_inline -#else -ccl_device_noinline -#endif -uint scene_intersect_shadow_all(KernelGlobals *kg, const Ray *ray, Intersection *isect, uint max_hits, uint *num_hits) +ccl_device_inline bool scene_intersect_shadow_all(KernelGlobals *kg, const Ray *ray, Intersection *isect, uint max_hits, uint *num_hits) { #ifdef __OBJECT_MOTION__ if(kernel_data.bvh.have_motion) { @@ -275,23 +269,12 @@ uint scene_intersect_shadow_all(KernelGlobals *kg, const Ray *ray, Intersection return bvh_intersect_shadow_all_hair(kg, ray, isect, max_hits, num_hits); #endif /* __HAIR__ */ -#ifdef __KERNEL_CPU__ - #ifdef __INSTANCING__ if(kernel_data.bvh.have_instancing) return bvh_intersect_shadow_all_instancing(kg, ray, isect, max_hits, num_hits); #endif /* __INSTANCING__ */ return bvh_intersect_shadow_all(kg, ray, isect, max_hits, num_hits); -#else /* __KERNEL_CPU__ */ - -#ifdef __INSTANCING__ - return bvh_intersect_shadow_all_instancing(kg, ray, isect, max_hits, num_hits); -#else - return bvh_intersect_shadow_all(kg, ray, isect, max_hits, num_hits); -#endif /* __INSTANCING__ */ - -#endif /* __KERNEL_CPU__ */ } #endif