diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2022-07-28 10:39:33 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-07-28 10:39:33 +0200 |
commit | a5f12f9c21ed8065767ffe574b8a09d155e02e17 (patch) | |
tree | 469db3706dd38d6eefd95ee2557ceb23629663a4 /core/math | |
parent | f99f5a588746ba0b417ecb3a6cd79ee9459db57c (diff) | |
parent | 4211e68d8019a757a54a435e1c4e240a784b463b (diff) |
Merge pull request #63532 from TokageItLab/rename-cubic-slerp
Diffstat (limited to 'core/math')
-rw-r--r-- | core/math/quaternion.cpp | 2 | ||||
-rw-r--r-- | core/math/quaternion.h | 2 | ||||
-rw-r--r-- | core/math/transform_3d.cpp | 2 | ||||
-rw-r--r-- | core/math/transform_3d.h | 2 |
4 files changed, 4 insertions, 4 deletions
diff --git a/core/math/quaternion.cpp b/core/math/quaternion.cpp index bb3b1ca63c..252c108166 100644 --- a/core/math/quaternion.cpp +++ b/core/math/quaternion.cpp @@ -183,7 +183,7 @@ Quaternion Quaternion::slerpni(const Quaternion &p_to, const real_t &p_weight) c invFactor * from.w + newFactor * p_to.w); } -Quaternion Quaternion::cubic_slerp(const Quaternion &p_b, const Quaternion &p_pre_a, const Quaternion &p_post_b, const real_t &p_weight) const { +Quaternion Quaternion::spherical_cubic_interpolate(const Quaternion &p_b, const Quaternion &p_pre_a, const Quaternion &p_post_b, const real_t &p_weight) const { #ifdef MATH_CHECKS ERR_FAIL_COND_V_MSG(!is_normalized(), Quaternion(), "The start quaternion must be normalized."); ERR_FAIL_COND_V_MSG(!p_b.is_normalized(), Quaternion(), "The end quaternion must be normalized."); diff --git a/core/math/quaternion.h b/core/math/quaternion.h index 684e7cb091..cb54a6f540 100644 --- a/core/math/quaternion.h +++ b/core/math/quaternion.h @@ -71,7 +71,7 @@ struct _NO_DISCARD_ Quaternion { Quaternion slerp(const Quaternion &p_to, const real_t &p_weight) const; Quaternion slerpni(const Quaternion &p_to, const real_t &p_weight) const; - Quaternion cubic_slerp(const Quaternion &p_b, const Quaternion &p_pre_a, const Quaternion &p_post_b, const real_t &p_weight) const; + Quaternion spherical_cubic_interpolate(const Quaternion &p_b, const Quaternion &p_pre_a, const Quaternion &p_post_b, const real_t &p_weight) const; Vector3 get_axis() const; real_t get_angle() const; diff --git a/core/math/transform_3d.cpp b/core/math/transform_3d.cpp index 96dd88676d..c497a276f3 100644 --- a/core/math/transform_3d.cpp +++ b/core/math/transform_3d.cpp @@ -86,7 +86,7 @@ void Transform3D::set_look_at(const Vector3 &p_eye, const Vector3 &p_target, con origin = p_eye; } -Transform3D Transform3D::sphere_interpolate_with(const Transform3D &p_transform, real_t p_c) const { +Transform3D Transform3D::spherical_interpolate_with(const Transform3D &p_transform, real_t p_c) const { /* not sure if very "efficient" but good enough? */ Transform3D interp; diff --git a/core/math/transform_3d.h b/core/math/transform_3d.h index a746e80dfe..1f8026043f 100644 --- a/core/math/transform_3d.h +++ b/core/math/transform_3d.h @@ -100,7 +100,7 @@ struct _NO_DISCARD_ Transform3D { void operator*=(const real_t p_val); Transform3D operator*(const real_t p_val) const; - Transform3D sphere_interpolate_with(const Transform3D &p_transform, real_t p_c) const; + Transform3D spherical_interpolate_with(const Transform3D &p_transform, real_t p_c) const; Transform3D interpolate_with(const Transform3D &p_transform, real_t p_c) const; _FORCE_INLINE_ Transform3D inverse_xform(const Transform3D &t) const { |