diff --git a/glm/detail/_noise.hpp b/glm/detail/_noise.hpp index 5a874a02..5adfe7f5 100644 --- a/glm/detail/_noise.hpp +++ b/glm/detail/_noise.hpp @@ -17,20 +17,8 @@ namespace detail return mod289(((x * static_cast(34)) + static_cast(1)) * x); } - template - GLM_FUNC_QUALIFIER vec<2, T, Q> permute(vec<2, T, Q> const& x) - { - return mod289(((x * static_cast(34)) + static_cast(1)) * x); - } - - template - GLM_FUNC_QUALIFIER vec<3, T, Q> permute(vec<3, T, Q> const& x) - { - return mod289(((x * static_cast(34)) + static_cast(1)) * x); - } - - template - GLM_FUNC_QUALIFIER vec<4, T, Q> permute(vec<4, T, Q> const& x) + template + GLM_FUNC_QUALIFIER vec permute(vec const& x) { return mod289(((x * static_cast(34)) + static_cast(1)) * x); } @@ -41,41 +29,18 @@ namespace detail return static_cast(1.79284291400159) - static_cast(0.85373472095314) * r; } - template - GLM_FUNC_QUALIFIER vec<2, T, Q> taylorInvSqrt(vec<2, T, Q> const& r) + template + GLM_FUNC_QUALIFIER vec taylorInvSqrt(vec const& r) { return static_cast(1.79284291400159) - static_cast(0.85373472095314) * r; } - template - GLM_FUNC_QUALIFIER vec<3, T, Q> taylorInvSqrt(vec<3, T, Q> const& r) - { - return static_cast(1.79284291400159) - static_cast(0.85373472095314) * r; - } - - template - GLM_FUNC_QUALIFIER vec<4, T, Q> taylorInvSqrt(vec<4, T, Q> const& r) - { - return static_cast(1.79284291400159) - static_cast(0.85373472095314) * r; - } - - template - GLM_FUNC_QUALIFIER vec<2, T, Q> fade(vec<2, T, Q> const& t) + template + GLM_FUNC_QUALIFIER vec fade(vec const& t) { return (t * t * t) * (t * (t * static_cast(6) - static_cast(15)) + static_cast(10)); } - template - GLM_FUNC_QUALIFIER vec<3, T, Q> fade(vec<3, T, Q> const& t) - { - return (t * t * t) * (t * (t * static_cast(6) - static_cast(15)) + static_cast(10)); - } - - template - GLM_FUNC_QUALIFIER vec<4, T, Q> fade(vec<4, T, Q> const& t) - { - return (t * t * t) * (t * (t * static_cast(6) - static_cast(15)) + static_cast(10)); - } }//namespace detail }//namespace glm