diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2017-08-24 04:33:33 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2017-08-24 04:43:02 +0300 |
commit | 76b74a93a860d55c36879b4773f1ff8576cd236f (patch) | |
tree | 23c2bf5be9b06dcbb196548a964249a6f72728de /intern/cycles/kernel/osl | |
parent | b85d36d8118f14cbc50d86fd90c9ac6c1a9d8a97 (diff) |
Fix Cycles CUDA transparent shadow error after recent fix in c22b52c.
Fishy cat benchmark was rendering with wrong shadows. Cause is unclear,
adding printf or rearranging code seems to avoid this issue, possibly a
compiler bug. This reverts the fix and solves the OSL bug elsewhere.
Diffstat (limited to 'intern/cycles/kernel/osl')
-rw-r--r-- | intern/cycles/kernel/osl/osl_services.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/intern/cycles/kernel/osl/osl_services.cpp b/intern/cycles/kernel/osl/osl_services.cpp index 1535496c73d..8ad2e12b067 100644 --- a/intern/cycles/kernel/osl/osl_services.cpp +++ b/intern/cycles/kernel/osl/osl_services.cpp @@ -1197,8 +1197,9 @@ bool OSLRenderServices::trace(TraceOpt &options, OSL::ShaderGlobals *sg, tracedata->init = true; tracedata->sd.osl_globals = sd->osl_globals; - /* raytrace */ - return scene_intersect(sd->osl_globals, ray, PATH_RAY_ALL_VISIBILITY, &tracedata->isect, NULL, 0.0f, 0.0f); + /* Raytrace, leaving out shadow opaque to avoid early exit. */ + uint visibility = PATH_RAY_ALL_VISIBILITY - PATH_RAY_SHADOW_OPAQUE; + return scene_intersect(sd->osl_globals, ray, visibility, &tracedata->isect, NULL, 0.0f, 0.0f); } |