summaryrefslogtreecommitdiff
path: root/core/math/transform.cpp
diff options
context:
space:
mode:
authortagcup <tagcup@yahoo.com>2018-04-14 15:53:25 -0400
committertagcup <tagcup@yahoo.com>2018-04-14 15:53:25 -0400
commita5e0bb447c339365d99dba772ea733c997c21200 (patch)
tree5b8642f6207485bc8dff4796489bef6fe05cdc7a /core/math/transform.cpp
parente7445c3d82b60eae2d02e201d21990f0aac096ae (diff)
Avoid converting Quat to Euler angles when not necessary.
Also ensure that get_scale doesn't arbitrarlity change the signs of scales, ensuring that the combination of get_rotation and get_scale gives the correct basis. Added various missing functions and constructors. Should close #17968.
Diffstat (limited to 'core/math/transform.cpp')
-rw-r--r--core/math/transform.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/math/transform.cpp b/core/math/transform.cpp
index f727d00e30..7cd186ca60 100644
--- a/core/math/transform.cpp
+++ b/core/math/transform.cpp
@@ -119,11 +119,11 @@ Transform Transform::interpolate_with(const Transform &p_transform, real_t p_c)
/* not sure if very "efficient" but good enough? */
- Vector3 src_scale = basis.get_signed_scale();
+ Vector3 src_scale = basis.get_scale();
Quat src_rot = basis.orthonormalized();
Vector3 src_loc = origin;
- Vector3 dst_scale = p_transform.basis.get_signed_scale();
+ Vector3 dst_scale = p_transform.basis.get_scale();
Quat dst_rot = p_transform.basis;
Vector3 dst_loc = p_transform.origin;