diff options
author | Dalai Felinto <dfelinto@gmail.com> | 2018-10-23 23:12:28 +0300 |
---|---|---|
committer | Dalai Felinto <dfelinto@gmail.com> | 2018-10-23 23:12:37 +0300 |
commit | ea1c120920d1d7ddc9357d199d8d60ce423ec980 (patch) | |
tree | 78ca7d961af402b4f27c9a7ffd2ebdb1f64d49d4 /rigify | |
parent | 816407649aedfaa7836e3aca7629842db732e279 (diff) |
Rigify: Fix remaining math update (*/@)
Diffstat (limited to 'rigify')
-rw-r--r-- | rigify/legacy/utils.py | 8 | ||||
-rw-r--r-- | rigify/utils.py | 4 |
2 files changed, 6 insertions, 6 deletions
diff --git a/rigify/legacy/utils.py b/rigify/legacy/utils.py index 35bbd7b9..f70a9967 100644 --- a/rigify/legacy/utils.py +++ b/rigify/legacy/utils.py @@ -342,7 +342,7 @@ def obj_to_bone(obj, rig, bone_name): bone = rig.data.bones[bone_name] - mat = rig.matrix_world * bone.matrix_local + mat = rig.matrix_world @ bone.matrix_local obj.location = mat.to_translation() @@ -607,8 +607,8 @@ def align_bone_roll(obj, bone1, bone2): rot_mat = Matrix.Rotation(angle, 3, axis) # Roll factor - x3 = rot_mat * x1 - dot = x2 * x3 + x3 = rot_mat @ x1 + dot = x2 @ x3 if dot > 1.0: dot = 1.0 elif dot < -1.0: @@ -619,7 +619,7 @@ def align_bone_roll(obj, bone1, bone2): bone1_e.roll = roll # Check if we rolled in the right direction - x3 = rot_mat * bone1_e.x_axis + x3 = rot_mat @ bone1_e.x_axis check = x2 * x3 # If not, reverse diff --git a/rigify/utils.py b/rigify/utils.py index fdb87013..2d5ac3f5 100644 --- a/rigify/utils.py +++ b/rigify/utils.py @@ -815,8 +815,8 @@ def align_bone_roll(obj, bone1, bone2): bone1_e.roll = roll # Check if we rolled in the right direction - x3 = rot_mat * bone1_e.x_axis - check = x2 * x3 + x3 = rot_mat @ bone1_e.x_axis + check = x2 @ x3 # If not, reverse if check < 0.9999: |