0.9.7
fast_exponential.hpp
Go to the documentation of this file.
1 
43 #pragma once
44 
45 // Dependency:
46 #include "../glm.hpp"
47 
48 #if(defined(GLM_MESSAGES) && !defined(GLM_EXT_INCLUDED))
49 # pragma message("GLM: GLM_GTX_fast_exponential extension included")
50 #endif
51 
52 namespace glm
53 {
56 
59  template <typename genType>
60  GLM_FUNC_DECL genType fastPow(genType x, genType y);
61 
64  template <typename T, precision P, template <typename, precision> class vecType>
65  GLM_FUNC_DECL vecType<T, P> fastPow(vecType<T, P> const & x, vecType<T, P> const & y);
66 
69  template <typename genTypeT, typename genTypeU>
70  GLM_FUNC_DECL genTypeT fastPow(genTypeT x, genTypeU y);
71 
74  template <typename T, precision P, template <typename, precision> class vecType>
75  GLM_FUNC_DECL vecType<T, P> fastPow(vecType<T, P> const & x);
76 
79  template <typename T>
80  GLM_FUNC_DECL T fastExp(T x);
81 
84  template <typename T, precision P, template <typename, precision> class vecType>
85  GLM_FUNC_DECL vecType<T, P> fastExp(vecType<T, P> const & x);
86 
89  template <typename T>
90  GLM_FUNC_DECL T fastLog(T x);
91 
94  template <typename T, precision P, template <typename, precision> class vecType>
95  GLM_FUNC_DECL vecType<T, P> fastLog(vecType<T, P> const & x);
96 
99  template <typename T>
100  GLM_FUNC_DECL T fastExp2(T x);
101 
104  template <typename T, precision P, template <typename, precision> class vecType>
105  GLM_FUNC_DECL vecType<T, P> fastExp2(vecType<T, P> const & x);
106 
109  template <typename T>
110  GLM_FUNC_DECL T fastLog2(T x);
111 
114  template <typename T, precision P, template <typename, precision> class vecType>
115  GLM_FUNC_DECL vecType<T, P> fastLog2(vecType<T, P> const & x);
116 
118 }//namespace glm
119 
120 #include "fast_exponential.inl"
GLM_FUNC_DECL vecType< T, P > fastLog(vecType< T, P > const &x)
Faster than the common exp2 function but less accurate.
GLM_FUNC_DECL vecType< T, P > fastPow(vecType< T, P > const &x)
Faster than the common pow function but less accurate.
Definition: _noise.hpp:40
GLM_FUNC_DECL vecType< T, P > fastExp(vecType< T, P > const &x)
Faster than the common exp function but less accurate.
GLM_FUNC_DECL vecType< T, P > fastLog2(vecType< T, P > const &x)
Faster than the common log2 function but less accurate.
GLM_FUNC_DECL vecType< T, P > fastExp2(vecType< T, P > const &x)
Faster than the common exp2 function but less accurate.