From 08048f7cceb82826bb520a2ca04f0bc38271faa9 Mon Sep 17 00:00:00 2001 From: Philipp Oeser Date: Tue, 28 Apr 2020 19:20:07 +0200 Subject: Fix T75810: Child bone frozen when both Auto IK and X-Axis mirror are used Caused by {rBa6a9a12e8f32} Other relevant commits: rBb8ca806b7798e2f8dd6effca8f0d081b3cd8c23f rBde530a95dc7b482dc22c933b9b8b2a98c79b5663 The issue is caused by some leftover BONE_TRANSFORM_MIRROR flags on a bone from previous runs (file in the report had the flag still on forearm.R). With these false leftover flags still set, `pose_grab_with_ik()` cannot work correctly. Culprit commit above removed the early clearing of this flag on all bones, this should be restored [this happened in `count_set_pose_transflags()`]. This should only be done in the beginning of the transform process, so now still clear the flags early in 'createTransPose()' [but dont restore this in 'count_set_pose_transflags()' -- this will be called from special_aftertrans_update again, so placing the clearance here only complicates things (autokeyframe_pose() still needs to work as well)...] Maniphest Tasks: T75810 Differential Revision: https://developer.blender.org/D7527 --- source/blender/editors/transform/transform_convert_armature.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'source') diff --git a/source/blender/editors/transform/transform_convert_armature.c b/source/blender/editors/transform/transform_convert_armature.c index 91b8b1ff657..779257ef671 100644 --- a/source/blender/editors/transform/transform_convert_armature.c +++ b/source/blender/editors/transform/transform_convert_armature.c @@ -685,6 +685,9 @@ void createTransPose(TransInfo *t) if (mirror) { int total_mirrored = 0; LISTBASE_FOREACH (bPoseChannel *, pchan, &ob->pose->chanbase) { + /* Clear the MIRROR flag from previous runs. */ + pchan->bone->flag &= ~BONE_TRANSFORM_MIRROR; + if ((pchan->bone->flag & BONE_TRANSFORM) && BKE_pose_channel_get_mirrored(ob->pose, pchan->name)) { total_mirrored++; -- cgit v1.2.3