diff options
| author | untodesu <kirill@untode.su> | 2025-09-14 19:16:44 +0500 |
|---|---|---|
| committer | untodesu <kirill@untode.su> | 2025-09-14 19:16:44 +0500 |
| commit | 8bcbd2729388edc63c82d77d314b583af1447c49 (patch) | |
| tree | 460c2b509372077f6adf95d72c4245988a580aed /core/math/vectors.hh | |
| parent | 7fc7fdb001bea8674fe0dbc1b962f3ec2702debb (diff) | |
| download | voxelius-8bcbd2729388edc63c82d77d314b583af1447c49.tar.bz2 voxelius-8bcbd2729388edc63c82d77d314b583af1447c49.zip | |
Cleanup math with qfengine ports again
Diffstat (limited to 'core/math/vectors.hh')
| -rw-r--r-- | core/math/vectors.hh | 16 |
1 files changed, 8 insertions, 8 deletions
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<math::Arithmetic T>
+template<math::arithmetic T>
constexpr static inline const T length2(const glm::vec<2, T>& vector);
-template<math::Arithmetic T>
+template<math::arithmetic T>
constexpr static inline const T length2(const glm::vec<3, T>& vector);
-template<math::Arithmetic T>
+template<math::arithmetic T>
constexpr static inline const T distance2(const glm::vec<2, T>& vector_a, const glm::vec<2, T>& vector_b);
-template<math::Arithmetic T>
+template<math::arithmetic T>
constexpr static inline const T distance2(const glm::vec<3, T>& vector_a, const glm::vec<3, T>& vector_b);
} // namespace math
-template<math::Arithmetic T>
+template<math::arithmetic T>
constexpr static inline const T math::length2(const glm::vec<2, T>& vector)
{
return (vector.x * vector.x) + (vector.y * vector.y);
}
-template<math::Arithmetic T>
+template<math::arithmetic T>
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<math::Arithmetic T>
+template<math::arithmetic T>
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<math::Arithmetic T>
+template<math::arithmetic T>
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);
|
