diff options
author | Sam Kottler <dev@samkottler.net> | 2020-08-20 19:40:02 +0300 |
---|---|---|
committer | Sam Kottler <dev@samkottler.net> | 2020-08-20 19:40:02 +0300 |
commit | 9dd50b39a433dc09b634d70ca8533ad19b4d1d5e (patch) | |
tree | 96341c40a13f620aa7f6a92fd6783dc6883216b0 /intern/cycles/bvh/bvh_embree.cpp | |
parent | 35624cdfe5186ee916e4519a013ef5c078d9c667 (diff) | |
parent | c74b4caa724bf74de41ba3928cdd824aa9ba59d2 (diff) |
Merge remote-tracking branch 'origin/blender-v2.90-release' into soc-2020-production-ready-light-tree-2soc-2020-production-ready-light-tree-2
Diffstat (limited to 'intern/cycles/bvh/bvh_embree.cpp')
-rw-r--r-- | intern/cycles/bvh/bvh_embree.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/intern/cycles/bvh/bvh_embree.cpp b/intern/cycles/bvh/bvh_embree.cpp index 17e1f86a589..4ef873634f0 100644 --- a/intern/cycles/bvh/bvh_embree.cpp +++ b/intern/cycles/bvh/bvh_embree.cpp @@ -126,9 +126,13 @@ static void rtc_filter_occluded_func(const RTCFilterFunctionNArguments *args) } else { kernel_embree_convert_hit(kg, ray, hit, ¤t_isect); - if (ctx->local_object_id != current_isect.object) { + int object = (current_isect.object == OBJECT_NONE) ? + kernel_tex_fetch(__prim_object, current_isect.prim) : + current_isect.object; + if (ctx->local_object_id != object) { /* This tells Embree to continue tracing. */ *args->valid = 0; + break; } } |