Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source/blender/ikplugin/intern/iksolver_plugin.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source/blender/ikplugin/intern/iksolver_plugin.c b/source/blender/ikplugin/intern/iksolver_plugin.c
index 41700b96acc..8d4d01b7e97 100644
--- a/source/blender/ikplugin/intern/iksolver_plugin.c
+++ b/source/blender/ikplugin/intern/iksolver_plugin.c
@@ -347,11 +347,15 @@ static void execute_posetree(struct Scene *scene, Object *ob, PoseTree *tree)
/* first set the goal inverse transform, assuming the root of tree was done ok! */
pchan= tree->pchan[0];
- if (pchan->parent)
+ if (pchan->parent) {
/* transform goal by parent mat, so this rotation is not part of the
* segment's basis. otherwise rotation limits do not work on the
* local transform of the segment itself. */
copy_m4_m4(rootmat, pchan->parent->pose_mat);
+ /* However, we do not want to get (i.e. reverse) parent's scale, as it generates [#31008]
+ * kind of nasty bugs... */
+ normalize_m4(rootmat);
+ }
else
unit_m4(rootmat);
copy_v3_v3(rootmat[3], pchan->pose_head);