From 29535189f1a0aedef919ddaf3aafd6e02bdefb8c Mon Sep 17 00:00:00 2001 From: Christophe Riccio Date: Sun, 20 Nov 2016 23:33:08 +0100 Subject: [PATCH] Optimized taylorCos --- glm/gtx/fast_trigonometry.inl | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/glm/gtx/fast_trigonometry.inl b/glm/gtx/fast_trigonometry.inl index f576c172..99ab4d44 100644 --- a/glm/gtx/fast_trigonometry.inl +++ b/glm/gtx/fast_trigonometry.inl @@ -8,10 +8,10 @@ namespace detail GLM_FUNC_QUALIFIER vecType taylorCos(vecType const & x) { return static_cast(1) - - (x * x) / 2.f - + (x * x * x * x) / 24.f - - (x * x * x * x * x * x) / 720.f - + (x * x * x * x * x * x * x * x) / 40320.f; + - (x * x) * (1.f / 2.f) + + (x * x * x * x) * (1.f / 24.f) + - (x * x * x * x * x * x) * (1.f / 720.f) + + (x * x * x * x * x * x * x * x) (1.f / 40320.f); } template