Bugfix: z-offset for materials was not added back yet.

This commit is contained in:
2009-10-16 10:03:39 +00:00
parent 680888419d
commit 61a88bb597
2 changed files with 8 additions and 0 deletions

View File

@@ -202,6 +202,9 @@ class MATERIAL_PT_options(MaterialButtonsPanel):
col.itemR(mat, "sky")
col.itemR(mat, "exclude_mist")
col.itemR(mat, "invert_z")
sub = col.row()
sub.itemR(mat, "z_offset")
sub.active = mat.transparency and mat.transparency_method == 'Z_TRANSPARENCY'
sub = col.column(align=True)
sub.itemL(text="Light Group:")
sub.itemR(mat, "light_group", text="")

View File

@@ -1600,6 +1600,11 @@ void RNA_def_material(BlenderRNA *brna)
RNA_def_property_boolean_sdna(prop, NULL, "mode", MA_ZINV);
RNA_def_property_ui_text(prop, "Invert Z Depth", "Renders material's faces with an inverted Z buffer (scanline only).");
RNA_def_property_update(prop, 0, "rna_Material_update");
prop= RNA_def_property(srna, "z_offset", PROP_FLOAT, PROP_NONE);
RNA_def_property_float_sdna(prop, NULL, "zoffs");
RNA_def_property_ui_text(prop, "Z Offset", "Gives faces an artificial offset in the Z buffer for Z transparency.");
RNA_def_property_update(prop, 0, "rna_Material_update");
prop= RNA_def_property(srna, "sky", PROP_BOOLEAN, PROP_NONE);
RNA_def_property_boolean_sdna(prop, NULL, "mode", MA_ENV);