0.9.6
fast_exponential.hpp
Go to the documentation of this file.
1 
39 #pragma once
40 
41 // Dependency:
42 #include "../glm.hpp"
43 
44 #if(defined(GLM_MESSAGES) && !defined(GLM_EXT_INCLUDED))
45 # pragma message("GLM: GLM_GTX_fast_exponential extension included")
46 #endif
47 
48 namespace glm
49 {
52 
55  template <typename genType>
56  GLM_FUNC_DECL genType fastPow(genType x, genType y);
57 
60  template <typename T, precision P, template <typename, precision> class vecType>
61  GLM_FUNC_DECL vecType<T, P> fastPow(vecType<T, P> const & x, vecType<T, P> const & y);
62 
65  template <typename genTypeT, typename genTypeU>
66  GLM_FUNC_DECL genTypeT fastPow(genTypeT x, genTypeU y);
67 
70  template <typename T, precision P, template <typename, precision> class vecType>
71  GLM_FUNC_DECL vecType<T, P> fastPow(vecType<T, P> const & x);
72 
75  template <typename T>
76  GLM_FUNC_DECL T fastExp(T x);
77 
80  template <typename T, precision P, template <typename, precision> class vecType>
81  GLM_FUNC_DECL vecType<T, P> fastExp(vecType<T, P> const & x);
82 
85  template <typename T>
86  GLM_FUNC_DECL T fastLog(T x);
87 
90  template <typename T, precision P, template <typename, precision> class vecType>
91  GLM_FUNC_DECL vecType<T, P> fastLog(vecType<T, P> const & x);
92 
95  template <typename T>
96  GLM_FUNC_DECL T fastExp2(T x);
97 
100  template <typename T, precision P, template <typename, precision> class vecType>
101  GLM_FUNC_DECL vecType<T, P> fastExp2(vecType<T, P> const & x);
102 
105  template <typename T>
106  GLM_FUNC_DECL T fastLog2(T x);
107 
110  template <typename T, precision P, template <typename, precision> class vecType>
111  GLM_FUNC_DECL vecType<T, P> fastLog2(vecType<T, P> const & x);
112 
114 }//namespace glm
115 
116 #include "fast_exponential.inl"
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 > 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:31
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 > fastExp2(vecType< T, P > const &x)
Faster than the common exp2 function but less accurate.