| 1.0.0 API documentation

rotate_normalized_axis.hpp
Go to the documentation of this file.
1
15 #pragma once
16
17 // Dependency:
18 #include "../glm.hpp"
19 #include "../gtc/epsilon.hpp"
20 #include "../gtc/quaternion.hpp"
21
22 #ifndef GLM_ENABLE_EXPERIMENTAL
23 # error "GLM: GLM_GTX_rotate_normalized_axis is an experimental extension and may change in the future. Use #define GLM_ENABLE_EXPERIMENTAL before including it, if you really want to use it."
24 #elif GLM_MESSAGES == GLM_ENABLE && !defined(GLM_EXT_INCLUDED)
25 # pragma message("GLM: GLM_GTX_rotate_normalized_axis extension included")
26 #endif
27
28 namespace glm
29 {
32
44 template<typename T, qualifier Q>
45 GLM_FUNC_DECL mat<4, 4, T, Q> rotateNormalizedAxis(
46 mat<4, 4, T, Q> const& m,
47 T const& angle,
48 vec<3, T, Q> const& axis);
49
57 template<typename T, qualifier Q>
58 GLM_FUNC_DECL qua<T, Q> rotateNormalizedAxis(
59 qua<T, Q> const& q,
60 T const& angle,
61 vec<3, T, Q> const& axis);
62
64 }//namespace glm
65
66 #include "rotate_normalized_axis.inl"
glm::angle
GLM_FUNC_DECL T angle(qua< T, Q > const &x)
Returns the quaternion rotation angle.
glm::rotateNormalizedAxis
GLM_FUNC_DECL qua< T, Q > rotateNormalizedAxis(qua< T, Q > const &q, T const &angle, vec< 3, T, Q > const &axis)
Rotates a quaternion from a vector of 3 components normalized axis and an angle.
glm::axis
GLM_FUNC_DECL vec< 3, T, Q > axis(qua< T, Q > const &x)
Returns the q rotation axis.