42 #include "../detail/setup.hpp"
43 #include "../detail/precision.hpp"
44 #include "../detail/type_int.hpp"
45 #include "../detail/_vectorize.hpp"
48 #if(defined(GLM_MESSAGES) && !defined(GLM_EXT_INCLUDED))
49 # pragma message("GLM: GLM_GTC_bitfield extension included")
60 template <
typename genIUType>
61 GLM_FUNC_DECL genIUType
mask(genIUType Bits);
66 template <
typename T, precision P,
template <
typename, precision>
class vecIUType>
67 GLM_FUNC_DECL vecIUType<T, P>
mask(vecIUType<T, P>
const & v);
72 template <
typename genIUType>
78 template <
typename T, precision P,
template <
typename, precision>
class vecType>
84 template <
typename genIUType>
90 template <
typename T, precision P,
template <
typename, precision>
class vecType>
96 template <
typename genIUType>
97 GLM_FUNC_DECL genIUType
bitfieldFillOne(genIUType Value,
int FirstBit,
int BitCount);
102 template <
typename T, precision P,
template <
typename, precision>
class vecType>
103 GLM_FUNC_DECL vecType<T, P>
bitfieldFillOne(vecType<T, P>
const & Value,
int FirstBit,
int BitCount);
108 template <
typename genIUType>
109 GLM_FUNC_DECL genIUType
bitfieldFillZero(genIUType Value,
int FirstBit,
int BitCount);
114 template <
typename T, precision P,
template <
typename, precision>
class vecType>
115 GLM_FUNC_DECL vecType<T, P>
bitfieldFillZero(vecType<T, P>
const & Value,
int FirstBit,
int BitCount);
232 #include "bitfield.inl"
GLM_FUNC_DECL vecType< T, P > bitfieldRotateLeft(vecType< T, P > const &In, int Shift)
Rotate all bits to the left.
GLM_FUNC_DECL uint64 bitfieldInterleave(uint16 x, uint16 y, uint16 z, uint16 w)
Interleaves the bits of x, y, z and w.
GLM_FUNC_DECL vecIUType< T, P > mask(vecIUType< T, P > const &v)
Build a mask of 'count' bits.
GLM_FUNC_DECL vecType< T, P > bitfieldFillZero(vecType< T, P > const &Value, int FirstBit, int BitCount)
Set to 0 a range of bits.
GLM_FUNC_DECL vecType< T, P > bitfieldFillOne(vecType< T, P > const &Value, int FirstBit, int BitCount)
Set to 1 a range of bits.
GLM_FUNC_DECL vecType< T, P > bitfieldRotateRight(vecType< T, P > const &In, int Shift)
Rotate all bits to the right.