mirror of
https://github.com/g-truc/glm.git
synced 2026-06-08 10:33:48 +00:00
Use C++14 deprecate attribute
This commit is contained in:
@@ -355,20 +355,12 @@
|
||||
// Qualifiers
|
||||
|
||||
#if (GLM_COMPILER & GLM_COMPILER_VC) || ((GLM_COMPILER & GLM_COMPILER_INTEL) && (GLM_PLATFORM & GLM_PLATFORM_WINDOWS))
|
||||
# define GLM_DEPRECATED __declspec(deprecated)
|
||||
# define GLM_ALIGNED_TYPEDEF(type, name, alignment) typedef __declspec(align(alignment)) type name
|
||||
#elif GLM_COMPILER & (GLM_COMPILER_GCC | GLM_COMPILER_CLANG | GLM_COMPILER_INTEL)
|
||||
# if GLM_LANG & GLM_LANG_CXX14_FLAG
|
||||
# define GLM_DEPRECATED [[deprecated]]
|
||||
# else
|
||||
# define GLM_DEPRECATED __attribute__((__deprecated__))
|
||||
# endif
|
||||
# define GLM_ALIGNED_TYPEDEF(type, name, alignment) typedef type name __attribute__((aligned(alignment)))
|
||||
#elif (GLM_COMPILER & GLM_COMPILER_CUDA) || (GLM_COMPILER & GLM_COMPILER_HIP)
|
||||
# define GLM_DEPRECATED
|
||||
# define GLM_ALIGNED_TYPEDEF(type, name, alignment) typedef type name __align__(x)
|
||||
#else
|
||||
# define GLM_DEPRECATED
|
||||
# define GLM_ALIGNED_TYPEDEF(type, name, alignment) typedef type name
|
||||
#endif
|
||||
|
||||
|
||||
@@ -41,12 +41,12 @@ namespace glm
|
||||
GLM_FUNC_DECL vec<L, T, Q> highestBitValue(vec<L, T, Q> const& value);
|
||||
|
||||
/// Return the power of two number which value is just higher the input value.
|
||||
/// Deprecated, use ceilPowerOfTwo from GTC_round instead
|
||||
///
|
||||
/// @see gtc_round
|
||||
/// @see gtx_bit
|
||||
template<typename genIUType>
|
||||
GLM_DEPRECATED GLM_FUNC_DECL genIUType powerOfTwoAbove(genIUType Value);
|
||||
[[deprecated("Use ceilPowerOfTwo from GTC_round instead")]]
|
||||
GLM_FUNC_DECL genIUType powerOfTwoAbove(genIUType Value);
|
||||
|
||||
/// Return the power of two number which value is just higher the input value.
|
||||
/// Deprecated, use ceilPowerOfTwo from GTC_round instead
|
||||
@@ -54,39 +54,40 @@ namespace glm
|
||||
/// @see gtc_round
|
||||
/// @see gtx_bit
|
||||
template<length_t L, typename T, qualifier Q>
|
||||
GLM_DEPRECATED GLM_FUNC_DECL vec<L, T, Q> powerOfTwoAbove(vec<L, T, Q> const& value);
|
||||
[[deprecated("Use ceilPowerOfTwo from GTC_round instead")]]
|
||||
GLM_FUNC_DECL vec<L, T, Q> powerOfTwoAbove(vec<L, T, Q> const& value);
|
||||
|
||||
/// Return the power of two number which value is just lower the input value.
|
||||
/// Deprecated, use floorPowerOfTwo from GTC_round instead
|
||||
///
|
||||
/// @see gtc_round
|
||||
/// @see gtx_bit
|
||||
template<typename genIUType>
|
||||
GLM_DEPRECATED GLM_FUNC_DECL genIUType powerOfTwoBelow(genIUType Value);
|
||||
[[deprecated("Use floorPowerOfTwo from GTC_round instead")]]
|
||||
GLM_FUNC_DECL genIUType powerOfTwoBelow(genIUType Value);
|
||||
|
||||
/// Return the power of two number which value is just lower the input value.
|
||||
/// Deprecated, use floorPowerOfTwo from GTC_round instead
|
||||
///
|
||||
/// @see gtc_round
|
||||
/// @see gtx_bit
|
||||
template<length_t L, typename T, qualifier Q>
|
||||
GLM_DEPRECATED GLM_FUNC_DECL vec<L, T, Q> powerOfTwoBelow(vec<L, T, Q> const& value);
|
||||
[[deprecated("Use floorPowerOfTwo from GTC_round instead")]]
|
||||
GLM_FUNC_DECL vec<L, T, Q> powerOfTwoBelow(vec<L, T, Q> const& value);
|
||||
|
||||
/// Return the power of two number which value is the closet to the input value.
|
||||
/// Deprecated, use roundPowerOfTwo from GTC_round instead
|
||||
///
|
||||
/// @see gtc_round
|
||||
/// @see gtx_bit
|
||||
template<typename genIUType>
|
||||
GLM_DEPRECATED GLM_FUNC_DECL genIUType powerOfTwoNearest(genIUType Value);
|
||||
[[deprecated("Use roundPowerOfTwo from GTC_round instead")]]
|
||||
GLM_FUNC_DECL genIUType powerOfTwoNearest(genIUType Value);
|
||||
|
||||
/// Return the power of two number which value is the closet to the input value.
|
||||
/// Deprecated, use roundPowerOfTwo from GTC_round instead
|
||||
///
|
||||
/// @see gtc_round
|
||||
/// @see gtx_bit
|
||||
template<length_t L, typename T, qualifier Q>
|
||||
GLM_DEPRECATED GLM_FUNC_DECL vec<L, T, Q> powerOfTwoNearest(vec<L, T, Q> const& value);
|
||||
[[deprecated("Use roundPowerOfTwo from GTC_round instead")]]
|
||||
GLM_FUNC_DECL vec<L, T, Q> powerOfTwoNearest(vec<L, T, Q> const& value);
|
||||
|
||||
/// @}
|
||||
} //namespace glm
|
||||
|
||||
Reference in New Issue
Block a user