diff options
author | Campbell Barton <ideasman42@gmail.com> | 2018-08-12 08:01:26 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2018-08-12 08:22:58 +0300 |
commit | 4b6fa4d897a0bb3252b16383492b526d2cef3920 (patch) | |
tree | 2793afc516c9a97e0d23d33a62028a6a9d87e8e2 /release/scripts/modules/bpy_types.py | |
parent | 444a0202d40705b6a6f21e59e883518be577cf4e (diff) |
PyAPI: update scripts for matrix multiply operator
Operators:
- add torus
- align objects
- bake physics
- make dupli faces
- smart project
Templates:
- 3D view ray cast
Other:
- Methods for bones/edit-bones
Diffstat (limited to 'release/scripts/modules/bpy_types.py')
-rw-r--r-- | release/scripts/modules/bpy_types.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/release/scripts/modules/bpy_types.py b/release/scripts/modules/bpy_types.py index d6d4ecd6fce..96193b047c6 100644 --- a/release/scripts/modules/bpy_types.py +++ b/release/scripts/modules/bpy_types.py @@ -205,21 +205,21 @@ class _GenericBone: """ Vector pointing down the x-axis of the bone. """ from mathutils import Vector - return self.matrix.to_3x3() * Vector((1.0, 0.0, 0.0)) + return self.matrix.to_3x3() @ Vector((1.0, 0.0, 0.0)) @property def y_axis(self): """ Vector pointing down the y-axis of the bone. """ from mathutils import Vector - return self.matrix.to_3x3() * Vector((0.0, 1.0, 0.0)) + return self.matrix.to_3x3() @ Vector((0.0, 1.0, 0.0)) @property def z_axis(self): """ Vector pointing down the z-axis of the bone. """ from mathutils import Vector - return self.matrix.to_3x3() * Vector((0.0, 0.0, 1.0)) + return self.matrix.to_3x3() @ Vector((0.0, 0.0, 1.0)) @property def basename(self): @@ -378,9 +378,9 @@ class EditBone(StructRNA, _GenericBone, metaclass=StructMetaPropGroup): :type roll: bool """ from mathutils import Vector - z_vec = self.matrix.to_3x3() * Vector((0.0, 0.0, 1.0)) - self.tail = matrix * self.tail - self.head = matrix * self.head + z_vec = self.matrix.to_3x3() @ Vector((0.0, 0.0, 1.0)) + self.tail = matrix @ self.tail + self.head = matrix @ self.head if scale: scalar = matrix.median_scale @@ -388,7 +388,7 @@ class EditBone(StructRNA, _GenericBone, metaclass=StructMetaPropGroup): self.tail_radius *= scalar if roll: - self.align_roll(matrix * z_vec) + self.align_roll(matrix @ z_vec) def ord_ind(i1, i2): |