From 8bcbd2729388edc63c82d77d314b583af1447c49 Mon Sep 17 00:00:00 2001 From: untodesu Date: Sun, 14 Sep 2025 19:16:44 +0500 Subject: Cleanup math with qfengine ports again --- core/math/vectors.hh | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'core/math/vectors.hh') diff --git a/core/math/vectors.hh b/core/math/vectors.hh index 9b9e762..ff2b8c9 100644 --- a/core/math/vectors.hh +++ b/core/math/vectors.hh @@ -8,35 +8,35 @@ namespace math { -template +template constexpr static inline const T length2(const glm::vec<2, T>& vector); -template +template constexpr static inline const T length2(const glm::vec<3, T>& vector); -template +template constexpr static inline const T distance2(const glm::vec<2, T>& vector_a, const glm::vec<2, T>& vector_b); -template +template constexpr static inline const T distance2(const glm::vec<3, T>& vector_a, const glm::vec<3, T>& vector_b); } // namespace math -template +template constexpr static inline const T math::length2(const glm::vec<2, T>& vector) { return (vector.x * vector.x) + (vector.y * vector.y); } -template +template constexpr static inline const T math::length2(const glm::vec<3, T>& vector) { return (vector.x * vector.x) + (vector.y * vector.y) + (vector.z * vector.z); } -template +template constexpr static inline const T math::distance2(const glm::vec<2, T>& vector_a, const glm::vec<2, T>& vector_b) { return math::length2(vector_a - vector_b); } -template +template constexpr static inline const T math::distance2(const glm::vec<3, T>& vector_a, const glm::vec<3, T>& vector_b) { return math::length2(vector_a - vector_b); -- cgit