diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-11-04 14:41:05 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-11-04 14:41:05 +0300 |
commit | e8f08c612b307f6b1d4acf3d3d9f548c0f39445f (patch) | |
tree | d305786491609871ee597421e0a6fecf787268c5 /source/blender/render | |
parent | e32a81cba293db363e9106e8a6960053edd309ed (diff) |
Fix #24523: deep shadows are rendered although object's shadow casting is disabled.
Diffstat (limited to 'source/blender/render')
-rw-r--r-- | source/blender/render/intern/source/strand.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/source/blender/render/intern/source/strand.c b/source/blender/render/intern/source/strand.c index 88d042e7b97..be17d640b66 100644 --- a/source/blender/render/intern/source/strand.c +++ b/source/blender/render/intern/source/strand.c @@ -825,6 +825,8 @@ int zbuffer_strands_abuf(Render *re, RenderPart *pa, APixstrand *apixbuf, ListBa /* for all object instances */ for(obi=re->instancetable.first, i=0; obi; obi=obi->next, i++) { + Material *ma; + obr= obi->obr; if(!obr->strandbuf || !(obr->strandbuf->lay & lay)) @@ -836,6 +838,14 @@ int zbuffer_strands_abuf(Render *re, RenderPart *pa, APixstrand *apixbuf, ListBa else copy_m4_m4(obwinmat, winmat); + /* test if we should skip it */ + ma = obr->strandbuf->ma; + + if(shadow && !(ma->mode & MA_SHADBUF)) + continue; + else if(!shadow && (ma->mode & MA_ONLYCAST)) + continue; + if(clip_render_object(obi->obr->boundbox, bounds, winmat)) continue; |