mirror of
https://github.com/g-truc/glm.git
synced 2026-06-08 10:33:48 +00:00
@@ -223,6 +223,11 @@ namespace bitfieldReverse
|
||||
}
|
||||
};
|
||||
|
||||
# if GLM_COMPILER & GLM_COMPILER_VC
|
||||
# pragma warning(push)
|
||||
# pragma warning(disable : 4309)
|
||||
# endif
|
||||
|
||||
template<glm::length_t L, typename T, glm::qualifier Q>
|
||||
GLM_FUNC_QUALIFIER glm::vec<L, T, Q> bitfieldReverseOps(glm::vec<L, T, Q> const& v)
|
||||
{
|
||||
@@ -236,12 +241,21 @@ namespace bitfieldReverse
|
||||
return x;
|
||||
}
|
||||
|
||||
# if GLM_COMPILER & GLM_COMPILER_VC
|
||||
# pragma warning(pop)
|
||||
# endif
|
||||
|
||||
template<typename genType>
|
||||
GLM_FUNC_QUALIFIER genType bitfieldReverseOps(genType x)
|
||||
{
|
||||
return bitfieldReverseOps(glm::vec<1, genType, glm::defaultp>(x)).x;
|
||||
}
|
||||
|
||||
#if GLM_COMPILER & GLM_COMPILER_CLANG
|
||||
# pragma clang diagnostic push
|
||||
# pragma clang diagnostic ignored "-Wpadded"
|
||||
#endif
|
||||
|
||||
template<typename genType>
|
||||
struct type
|
||||
{
|
||||
@@ -250,6 +264,10 @@ namespace bitfieldReverse
|
||||
result Result;
|
||||
};
|
||||
|
||||
#if GLM_COMPILER & GLM_COMPILER_CLANG
|
||||
# pragma clang diagnostic pop
|
||||
#endif
|
||||
|
||||
typedef type<glm::uint> typeU32;
|
||||
|
||||
typeU32 const Data32[] =
|
||||
@@ -1423,6 +1441,11 @@ namespace bitCount
|
||||
}
|
||||
};
|
||||
|
||||
# if GLM_COMPILER & GLM_COMPILER_VC
|
||||
# pragma warning(push)
|
||||
# pragma warning(disable : 4309)
|
||||
# endif
|
||||
|
||||
template<glm::length_t L, typename T, glm::qualifier Q>
|
||||
static glm::vec<L, int, Q> bitCount_bitfield(glm::vec<L, T, Q> const& v)
|
||||
{
|
||||
@@ -1436,6 +1459,10 @@ namespace bitCount
|
||||
return glm::vec<L, int, Q>(x);
|
||||
}
|
||||
|
||||
# if GLM_COMPILER & GLM_COMPILER_VC
|
||||
# pragma warning(pop)
|
||||
# endif
|
||||
|
||||
template<typename genType>
|
||||
static int bitCount_bitfield(genType x)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user