Modifiers: Add normalize weights option to vertex weight modifiers

Original patch by Cody Winchester (@CodyWinch), several fixes and
cleanup by Bastien Montagne (@mont29).

Differential revision: https://developer.blender.org/D7656
This commit is contained in:
Cody Winchester
2020-05-26 20:53:38 +02:00
committed by Bastien Montagne
parent 00674c12cc
commit de257b6366
10 changed files with 92 additions and 7 deletions

View File

@@ -1437,6 +1437,9 @@ class DATA_PT_modifiers(ModifierButtonsPanel, Panel):
if md.falloff_type == 'CURVE':
layout.template_curve_mapping(md, "map_curve")
row = layout.row(align=True)
row.prop(md, "normalize")
# Common mask options
layout.separator()
self.vertex_weight_mask(layout, ob, md)
@@ -1462,6 +1465,9 @@ class DATA_PT_modifiers(ModifierButtonsPanel, Panel):
col.label(text="Mix Set:")
col.prop(md, "mix_set", text="")
row = layout.row(align=True)
row.prop(md, "normalize")
# Common mask options
layout.separator()
self.vertex_weight_mask(layout, ob, md)
@@ -1495,6 +1501,9 @@ class DATA_PT_modifiers(ModifierButtonsPanel, Panel):
row.prop(md, "falloff_type")
row.prop(md, "invert_falloff", text="", icon='ARROW_LEFTRIGHT')
row = layout.row(align=True)
row.prop(md, "normalize")
# Common mask options
layout.separator()
self.vertex_weight_mask(layout, ob, md)