Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIRIE Shinsuke <irieshinsuke@yahoo.co.jp>2014-04-23 10:02:06 +0400
committerIRIE Shinsuke <irieshinsuke@yahoo.co.jp>2014-04-23 10:03:34 +0400
commitfc28732ba65a57bccd47940249999809c2c93eb0 (patch)
tree1ba4dbb7e6644adc029ae36f00e5ac86d27e4b1f /release
parent0e6b28e04b291dfe797432532208065c52ff3fdb (diff)
Blender Internal: Add material property "Cast" which can disable both ray and buffer shadows.
Also refactor: - Material property UI related to shadows - Preparation of OR-ed mode flags (ma->mode_l) of render materials Reviewers: brecht Reviewed By: brecht Differential Revision: https://developer.blender.org/D313
Diffstat (limited to 'release')
-rw-r--r--release/scripts/startup/bl_ui/properties_material.py29
1 files changed, 19 insertions, 10 deletions
diff --git a/release/scripts/startup/bl_ui/properties_material.py b/release/scripts/startup/bl_ui/properties_material.py
index 9e56c269b2b..03a28b609be 100644
--- a/release/scripts/startup/bl_ui/properties_material.py
+++ b/release/scripts/startup/bl_ui/properties_material.py
@@ -216,15 +216,18 @@ class MATERIAL_PT_pipeline(MaterialButtonsPanel, Panel):
sub.active = mat_type
sub.prop(mat, "use_sky")
sub.prop(mat, "invert_z")
+ col.prop(mat, "pass_index")
col = split.column()
col.active = mat_type
+ col.prop(mat, "use_cast_shadows", text="Cast")
col.prop(mat, "use_cast_shadows_only", text="Cast Only")
- col.prop(mat, "shadow_cast_alpha", text="Casting Alpha")
col.prop(mat, "use_cast_buffer_shadows")
+ sub = col.column()
+ sub.active = mat.use_cast_buffer_shadows
+ sub.prop(mat, "shadow_cast_alpha", text="Casting Alpha")
col.prop(mat, "use_cast_approximate")
- col.prop(mat, "pass_index")
class MATERIAL_PT_diffuse(MaterialButtonsPanel, Panel):
@@ -814,24 +817,30 @@ class MATERIAL_PT_shadow(MaterialButtonsPanel, Panel):
col = split.column()
col.prop(mat, "use_shadows", text="Receive")
col.prop(mat, "use_transparent_shadows", text="Receive Transparent")
- if simple_material(base_mat):
- col.prop(mat, "use_cast_shadows_only", text="Cast Only")
- col.prop(mat, "shadow_cast_alpha", text="Casting Alpha")
col.prop(mat, "use_only_shadow", text="Shadows Only")
sub = col.column()
sub.active = mat.use_only_shadow
sub.prop(mat, "shadow_only_type", text="")
- col = split.column()
+ if not simple_material(base_mat):
+ col = split.column()
+
+ col.prop(mat, "use_ray_shadow_bias", text="Auto Ray Bias")
+ sub = col.column()
+ sub.active = (not mat.use_ray_shadow_bias)
+ sub.prop(mat, "shadow_ray_bias", text="Ray Bias")
+
if simple_material(base_mat):
+ col = split.column()
+
+ col.prop(mat, "use_cast_shadows", text="Cast")
+ col.prop(mat, "use_cast_shadows_only", text="Cast Only")
col.prop(mat, "use_cast_buffer_shadows")
sub = col.column()
sub.active = mat.use_cast_buffer_shadows
+ if simple_material(base_mat):
+ sub.prop(mat, "shadow_cast_alpha", text="Casting Alpha")
sub.prop(mat, "shadow_buffer_bias", text="Buffer Bias")
- col.prop(mat, "use_ray_shadow_bias", text="Auto Ray Bias")
- sub = col.column()
- sub.active = (not mat.use_ray_shadow_bias)
- sub.prop(mat, "shadow_ray_bias", text="Ray Bias")
if simple_material(base_mat):
col.prop(mat, "use_cast_approximate")