From 93e573f7b1d5661261cfe4863bf75df5495324ea Mon Sep 17 00:00:00 2001 From: Gottfried Leibniz <37632412+gottfriedleibniz@users.noreply.github.com> Date: Tue, 22 Sep 2020 00:35:07 -0300 Subject: [PATCH] fix: axisAngle invalid epsilon comparison --- glm/gtx/matrix_interpolation.inl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/glm/gtx/matrix_interpolation.inl b/glm/gtx/matrix_interpolation.inl index de40b7d7..bd58d2f3 100644 --- a/glm/gtx/matrix_interpolation.inl +++ b/glm/gtx/matrix_interpolation.inl @@ -78,7 +78,7 @@ namespace glm if (glm::abs(s) < T(0.001)) s = static_cast(1); T const angleCos = (m[0][0] + m[1][1] + m[2][2] - static_cast(1)) * static_cast(0.5); - if(angleCos - static_cast(1) < epsilon) + if(abs(angleCos - static_cast(1)) < epsilon) angle = pi() * static_cast(0.25); else angle = acos(angleCos);