xrt: introduce XRT_ERROR_INPUT_UNSUPPORTED

Part-of: <https://gitlab.freedesktop.org/monado/monado/-/merge_requests/2271>
This commit is contained in:
Simon Zeni 2024-07-03 11:40:55 -04:00
parent 0caec59967
commit e113b532b6
3 changed files with 8 additions and 0 deletions

View file

@ -1 +1,2 @@
- xrt_device_get_tracked_pose returns xrt_result_t to improve error handling in the state tracker
- introduce XRT_ERROR_INPUT_UNSUPPORTED

View file

@ -172,6 +172,7 @@ u_pp_xrt_result(struct u_pp_delegate dg, xrt_result_t xret)
case XRT_ERROR_UNSUPPORTED_SPACE_TYPE: DG("XRT_ERROR_UNSUPPORTED_SPACE_TYPE"); return;
case XRT_ERROR_ANDROID: DG("XRT_ERROR_ANDROID"); return;
case XRT_ERROR_FEATURE_NOT_SUPPORTED: DG("XRT_ERROR_FEATURE_NOT_SUPPORTED"); return;
case XRT_ERROR_INPUT_UNSUPPORTED: DG("XRT_ERROR_INPUT_UNSUPPORTED"); return;
}
// clang-format on

View file

@ -189,6 +189,7 @@ typedef enum xrt_result
* The supplied space type is not supported for this operation.
*/
XRT_ERROR_UNSUPPORTED_SPACE_TYPE = -30,
/*!
* Some other Android error, typically a logic error that should be impossible to reach.
*/
@ -198,4 +199,9 @@ typedef enum xrt_result
* Returned when a feature is not supported by the device.
*/
XRT_ERROR_FEATURE_NOT_SUPPORTED = -32,
/*!
* The input provided is a valid value from the enum xrt_input_name but is not supported by the driver.
*/
XRT_ERROR_INPUT_UNSUPPORTED = -33,
} xrt_result_t;