0.9.7
vector_angle.hpp
Go to the documentation of this file.
1 
44 #pragma once
45 
46 // Dependency:
47 #include "../glm.hpp"
48 #include "../gtc/epsilon.hpp"
49 #include "../gtx/quaternion.hpp"
50 #include "../gtx/rotate_vector.hpp"
51 
52 #if(defined(GLM_MESSAGES) && !defined(GLM_EXT_INCLUDED))
53 # pragma message("GLM: GLM_GTX_vector_angle extension included")
54 #endif
55 
56 namespace glm
57 {
60 
64  template <typename vecType>
65  GLM_FUNC_DECL typename vecType::value_type angle(
66  vecType const & x,
67  vecType const & y);
68 
72  template <typename T, precision P>
73  GLM_FUNC_DECL T orientedAngle(
74  tvec2<T, P> const & x,
75  tvec2<T, P> const & y);
76 
80  template <typename T, precision P>
81  GLM_FUNC_DECL T orientedAngle(
82  tvec3<T, P> const & x,
83  tvec3<T, P> const & y,
84  tvec3<T, P> const & ref);
85 
87 }// namespace glm
88 
89 #include "vector_angle.inl"
GLM_FUNC_DECL vecType::value_type angle(vecType const &x, vecType const &y)
Returns the absolute angle between two vectors Parameters need to be normalized.
Definition: _noise.hpp:40
GLM_FUNC_DECL T orientedAngle(tvec3< T, P > const &x, tvec3< T, P > const &y, tvec3< T, P > const &ref)
Returns the oriented angle between two 3d vectors based from a reference axis.