17 #pragma GCC diagnostic push 18 #pragma GCC diagnostic ignored "-Wpragmas" 19 #pragma GCC diagnostic ignored "-Wswitch-enum" 22 #include "xrtraits/traits/APITraitsImpl.h" 25 #pragma GCC diagnostic pop 31 #include <openxr/openxr.h> 32 #include <openxr/openxr_reflection.h> 35 #include <type_traits> 42 #ifndef XRTRAITS_DOXYGEN 44 using std::remove_const_t;
45 using std::remove_cv_t;
46 using std::remove_pointer_t;
47 using std::remove_reference_t;
52 using remove_reference_pointer_t =
53 remove_pointer_t<remove_reference_t<T>>;
58 using remove_reference_pointer_cv_t =
59 remove_cv_t<remove_reference_pointer_t<T>>;
63 std::is_const<remove_pointer_t<decltype(T::next)>>::value;
65 #define XRTRAITS_MAKE_STRINGIFY_CASE(SYM, _) \ 69 structureTypeEnumToString(XrStructureType tag)
73 if (tag == XR_STRUCTURE_TYPE_MAX_ENUM) {
78 XR_LIST_ENUM_XrStructureType(
79 XRTRAITS_MAKE_STRINGIFY_CASE);
84 #undef XRTRAITS_MAKE_STRINGIFY_CASE 87 #endif // !XRTRAITS_DOXYGEN 101 detail::remove_reference_pointer_cv_t<T>>;
114 template <
typename T>
116 detail::remove_reference_pointer_cv_t<T>>;
124 template <
typename T>
126 detail::remove_reference_pointer_cv_t<T>>;
133 template <
typename T>
136 detail::remove_reference_pointer_cv_t<T>>;
143 return detail::structureTypeEnumToString(t);
151 return detail::structureTypeEnumToTypeNameString(t);
155 template <
typename SourceType,
typename TargetType>
157 is_const_v<TargetType>);
Main namespace for these C++ OpenXR utilities.
Definition: GetChained.h:26
constexpr XrStructureType xr_type_tag_v
Definition: APITraits.h:125
constexpr bool is_xr_tagged_type_v
Definition: APITraits.h:100
constexpr bool has_xr_type_tag_v
Definition: APITraits.h:115
constexpr const char * to_string(XrStructureType t)
Definition: APITraits.h:141
Header with common utilities used by multiple headers.
constexpr bool has_const_next_pointer_v
Definition: APITraits.h:134
constexpr const char * getTypeName(XrStructureType t)
Definition: APITraits.h:149
constexpr bool same_constness
Do SourceType and TargetType have the same const-qualifications?
Definition: APITraits.h:156