Bugfix & Feature fix: Only Shadow Material options

Patch from Miika Hämäläinen.

The old Material "Only Shadow" used an ancient 'best guess'
formula using Lamp Distance and some averaging for converting
shadow values to alpha.
A couple of bug reporters already complained about the not
very predictable renders. Miika fixed this by adding two
new options, to only give the true shadow factor exclusively,
or to give a result including light intensity values.

More info:
http://projects.blender.org/tracker/index.php?func=detail&aid=26413&group_id=9&atid=127
This commit is contained in:
2011-03-08 16:08:43 +00:00
parent 3d05311d3c
commit 3a43e08deb
4 changed files with 96 additions and 19 deletions

View File

@@ -752,10 +752,13 @@ class MATERIAL_PT_shadow(MaterialButtonsPanel, bpy.types.Panel):
col = split.column()
col.prop(mat, "use_shadows", text="Receive")
col.prop(mat, "use_transparent_shadows", text="Receive Transparent")
col.prop(mat, "use_only_shadow", text="Shadows Only")
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="ShadowsOnly")
sub = col.column()
sub.active = mat.use_only_shadow
sub.prop(mat, "shadow_only_type", text="")
col = split.column()
if simple_material(base_mat):
@@ -771,6 +774,7 @@ class MATERIAL_PT_shadow(MaterialButtonsPanel, bpy.types.Panel):
col.prop(mat, "use_cast_approximate")
class MATERIAL_PT_transp_game(MaterialButtonsPanel, bpy.types.Panel):
bl_label = "Transparency"
bl_options = {'DEFAULT_CLOSED'}