[Bf-blender-cvs] [eaf9ae643bf] blender-v2.91-release: Fix T82624: Skin modifiers root bone cannot be moved

Philipp Oeser noreply at git.blender.org
Thu Nov 12 11:22:35 CET 2020


Commit: eaf9ae643bfacfac9055db87c1daadc79e1e92e5
Author: Philipp Oeser
Date:   Wed Nov 11 18:07:53 2020 +0100
Branches: blender-v2.91-release
https://developer.blender.org/rBeaf9ae643bfacfac9055db87c1daadc79e1e92e5

Fix T82624: Skin modifiers root bone cannot be moved

When creating an armature from the skin modifier, resulting bones would
always be flagged BONE_CONNECTED.
Those bones cannot be transformed (just rotated).

Now only flag bones that really have a parent BONE_CONNECTED.

Maniphest Tasks: T82624

Differential Revision: https://developer.blender.org/D9534

===================================================================

M	source/blender/editors/object/object_modifier.c

===================================================================

diff --git a/source/blender/editors/object/object_modifier.c b/source/blender/editors/object/object_modifier.c
index 4eed9187d66..7f87577b630 100644
--- a/source/blender/editors/object/object_modifier.c
+++ b/source/blender/editors/object/object_modifier.c
@@ -2308,7 +2308,9 @@ static void skin_armature_bone_create(Object *skin_ob,
     EditBone *bone = ED_armature_ebone_add(arm, "Bone");
 
     bone->parent = parent_bone;
-    bone->flag |= BONE_CONNECTED;
+    if (parent_bone != NULL) {
+      bone->flag |= BONE_CONNECTED;
+    }
 
     copy_v3_v3(bone->head, mvert[parent_v].co);
     copy_v3_v3(bone->tail, mvert[v].co);



More information about the Bf-blender-cvs mailing list