mirror of
https://gitlab.freedesktop.org/monado/monado.git
synced 2024-12-29 11:06:18 +00:00
st/oxr: Add view index verify helper
This commit is contained in:
parent
5656f86c47
commit
c1ce722d6d
|
@ -196,6 +196,14 @@ extern "C" {
|
|||
} \
|
||||
} while (false)
|
||||
|
||||
#define OXR_VERIFY_VIEW_INDEX(log, index) \
|
||||
do { \
|
||||
if (index > 2) { \
|
||||
return oxr_error(log, XR_ERROR_VALIDATION_FAILURE, \
|
||||
"Invalid view index %d, only 2 views supported", index); \
|
||||
} \
|
||||
} while (false)
|
||||
|
||||
#define OXR_VERIFY_SWAPCHAIN_USAGE_FLAGS_NOT_MUTUALLY_EXCLUSIVE(log, flags, mutually_exclusive_a, \
|
||||
mutually_exclusive_b) \
|
||||
do { \
|
||||
|
|
Loading…
Reference in a new issue