diff options
author | IRIE Shinsuke <irieshinsuke@yahoo.co.jp> | 2014-02-11 12:06:21 +0400 |
---|---|---|
committer | IRIE Shinsuke <irieshinsuke@yahoo.co.jp> | 2014-02-11 12:06:21 +0400 |
commit | e2f9afbaabbdecc87c77261e40650da426baf168 (patch) | |
tree | 5cc11b5f91f48177da7b2154416698474e551f6e /source/blender/editors | |
parent | 2038eb10d069352cefa83abc6a6c6071807970ae (diff) |
Blender Internal: Modify material property "Cast Buffer Shadows" to affect ray shadows also, and rename it to "Cast Shadows".
This allows us to make materials that don't cast ray shadows.
Turning off this property can reduce the rendering time slightly.
Note: RNA path is changed to "use_cast_shadows" as well. The older
path "use_cast_buffer_shadows" still can be used as its alias, but
it will be removed after updating some addons.
Reviewed By: brecht
Differential Revision: https://developer.blender.org/D272
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/render/render_preview.c | 2 | ||||
-rw-r--r-- | source/blender/editors/space_view3d/drawobject.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/source/blender/editors/render/render_preview.c b/source/blender/editors/render/render_preview.c index 482c855f067..aecd4e1aa17 100644 --- a/source/blender/editors/render/render_preview.c +++ b/source/blender/editors/render/render_preview.c @@ -350,7 +350,7 @@ static Scene *preview_prepare_scene(Scene *scene, ID *id, int id_type, ShaderPre if (base->object->id.name[2] == 'c') { Material *shadmat = give_current_material(base->object, base->object->actcol); if (shadmat) { - if (mat->mode & MA_SHADBUF) shadmat->septex = 0; + if (mat->mode & MA_CASTSHADOW) shadmat->septex = 0; else shadmat->septex |= 1; } } diff --git a/source/blender/editors/space_view3d/drawobject.c b/source/blender/editors/space_view3d/drawobject.c index 8a4714eeded..0a387af7e7e 100644 --- a/source/blender/editors/space_view3d/drawobject.c +++ b/source/blender/editors/space_view3d/drawobject.c @@ -3620,7 +3620,7 @@ static bool draw_mesh_object(Scene *scene, ARegion *ar, View3D *v3d, RegionView3 if (v3d->flag2 & V3D_RENDER_SHADOW) { for (i = 0; i < ob->totcol; ++i) { Material *ma = give_current_material(ob, i); - if (ma && !(ma->mode & MA_SHADBUF)) { + if (ma && !(ma->mode & MA_CASTSHADOW)) { return true; } } |