mirror of
https://github.com/g-truc/glm.git
synced 2024-11-26 02:04:35 +00:00
Merge pull request #1028 from gottfriedleibniz/patch-axisangle
fix: matrix axisAngle #1028
This commit is contained in:
commit
0fe622b020
@ -78,7 +78,7 @@ namespace glm
|
||||
if (glm::abs(s) < T(0.001))
|
||||
s = static_cast<T>(1);
|
||||
T const angleCos = (m[0][0] + m[1][1] + m[2][2] - static_cast<T>(1)) * static_cast<T>(0.5);
|
||||
if(angleCos - static_cast<T>(1) < epsilon)
|
||||
if(abs(angleCos - static_cast<T>(1)) < epsilon)
|
||||
angle = pi<T>() * static_cast<T>(0.25);
|
||||
else
|
||||
angle = acos(angleCos);
|
||||
|
Loading…
Reference in New Issue
Block a user