Add Easy_Weight to Addons #47

Merged
Nick Alberelli merged 48 commits from feature/easy_weights into main 2023-05-17 22:13:57 +02:00
Showing only changes of commit d344af2ebb - Show all commits

View File

@ -161,7 +161,7 @@ def get_referenced_vgroups(mesh_ob: bpy.types.Object, py_ob: object) -> List[bpy
continue continue
vg = mesh_ob.vertex_groups.get(value) vg = mesh_ob.vertex_groups.get(value)
if vg: if vg:
referenced_vgroups.append(vg.name) referenced_vgroups.append(vg)
return referenced_vgroups return referenced_vgroups
def get_shape_key_mask_vgroups(mesh_ob) -> List[bpy.types.VertexGroup]: def get_shape_key_mask_vgroups(mesh_ob) -> List[bpy.types.VertexGroup]:
@ -172,6 +172,7 @@ def get_shape_key_mask_vgroups(mesh_ob) -> List[bpy.types.VertexGroup]:
vg = mesh_ob.vertex_groups.get(sk.vertex_group) vg = mesh_ob.vertex_groups.get(sk.vertex_group)
if vg and vg.name not in mask_vgroups: if vg and vg.name not in mask_vgroups:
mask_vgroups.append(vg) mask_vgroups.append(vg)
return mask_vgroups
def delete_unused_vgroups(mesh_ob) -> List[str]: def delete_unused_vgroups(mesh_ob) -> List[str]:
non_deform_vgroups = get_non_deforming_vgroups(mesh_ob) non_deform_vgroups = get_non_deforming_vgroups(mesh_ob)