Monado OpenXR Runtime
xrt_results.h
Go to the documentation of this file.
1// Copyright 2020-2023, Collabora, Ltd.
2// SPDX-License-Identifier: BSL-1.0
3/*!
4 * @file
5 * @brief Internal result type for XRT.
6 * @author Christoph Haag <christoph.haag@collabora.com>
7 * @ingroup xrt_iface
8 */
9
10#pragma once
11
12/*!
13 * Result type used across Monado.
14 *
15 * 0 is @ref XRT_SUCCESS, positive values are "special" non-error return codes (like timeout), negative values are
16 * errors.
17 *
18 * @see u_pp_xrt_result
19 * @ingroup xrt_iface
20 */
21typedef enum xrt_result
22{
23 /*!
24 * The operation succeeded
25 */
27
28 /*!
29 * The operation was given a timeout and timed out.
30 *
31 * The value 2 picked so it matches VK_TIMEOUT.
32 */
34
35 /*!
36 * The space’s bounds are not known at the moment.
37 */
39
40 /*!
41 * A problem occurred either with the IPC transport itself, with invalid commands from the client, or with
42 * invalid responses from the server.
43 */
45
46 /*!
47 * Returned when trying to acquire or release an image and there is no image left to acquire/no space in the
48 * queue left to release to
49 */
51
52 /*!
53 * Other unspecified error related to Vulkan
54 */
56
57 /*!
58 * Other unspecified error related to OpenGL
59 */
61
62 /*!
63 * The function tried to submit Vulkan commands but received an error.
64 */
66
67 /*!
68 *
69 * Returned when a swapchain create flag is passed that is valid, but
70 * not supported by the main compositor (and lack of support is also
71 * valid).
72 *
73 * For use when e.g. the protected content image flag is requested but
74 * isn't supported.
75 */
77
78 /*!
79 * Could not allocate native image buffer(s).
80 */
82
83 /*!
84 * The pose is no longer active, this happens when the application
85 * tries to get a pose that is no longer active.
86 */
88
89 /*!
90 * Creating a fence failed.
91 */
93
94 /*!
95 * Getting or giving the native fence handle caused a error.
96 */
98
99 /*!
100 * Multiple not supported on this layer level (IPC, compositor).
101 */
103
104 /*!
105 * The requested format is not supported by Monado.
106 */
108
109 /*!
110 * The given config was EGL_NO_CONFIG_KHR and EGL_KHR_no_config_context
111 * is not supported by the display.
112 */
114
115 /*!
116 * Failed to initialize threading components.
117 */
119
120 /*!
121 * The client has not created a session on this IPC connection,
122 * which is needed for the given command.
123 */
125
126 /*!
127 * The client has already created a session on this IPC connection.
128 */
130 /*!
131 * The prober list has not been locked before this call.
132 */
134 /*!
135 * Creating the @ref xrt_prober failed.
136 */
138 /*!
139 * The prober list is locked (already).
140 */
142 /*!
143 * The prober list has not been locked before this call.
144 */
146 /*!
147 * The probring failed.
148 */
150 /*!
151 * Creating a @ref xrt_device failed.
152 */
154 /*!
155 * Some D3D error, from code shared between D3D11 and D3D12
156 */
158 /*!
159 * Some D3D11 error
160 */
162 /*!
163 * Some D3D12 error
164 */
166 /*!
167 * The @ref xrt_space_overseer doesn't support recentering driven from
168 * the application side of things.
169 */
171 /*!
172 * The system doesn't support compositor, this error can be returned
173 * when trying to create the system compositor or trying to create the
174 * native compositor.
175 */
177 /*!
178 * The client has not created a compositor on this IPC connection,
179 * which is needed for the given command.
180 */
182
183 /*!
184 * The interface function called is not implemented by its interface.
185 */
187
188 /*!
189 * The supplied space type is not supported for this operation.
190 */
192
193 /*!
194 * Some other Android error, typically a logic error that should be impossible to reach.
195 */
197
198 /*!
199 * Returned when a feature is not supported by the device.
200 */
202
203 /*!
204 * The input provided is a valid value from the enum xrt_input_name but is not supported by the driver.
205 */
enum xrt_result xrt_result_t
Result type used across Monado.
xrt_result
Result type used across Monado.
Definition: xrt_results.h:22
@ XRT_ERROR_EGL_CONFIG_MISSING
The given config was EGL_NO_CONFIG_KHR and EGL_KHR_no_config_context is not supported by the display.
Definition: xrt_results.h:113
@ XRT_ERROR_INPUT_UNSUPPORTED
The input provided is a valid value from the enum xrt_input_name but is not supported by the driver.
Definition: xrt_results.h:206
@ XRT_ERROR_NATIVE_HANDLE_FENCE_ERROR
Getting or giving the native fence handle caused a error.
Definition: xrt_results.h:97
@ XRT_ERROR_IPC_SESSION_ALREADY_CREATED
The client has already created a session on this IPC connection.
Definition: xrt_results.h:129
@ XRT_ERROR_DEVICE_CREATION_FAILED
Creating a xrt_device failed.
Definition: xrt_results.h:153
@ XRT_ERROR_FENCE_CREATE_FAILED
Creating a fence failed.
Definition: xrt_results.h:92
@ XRT_ERROR_PROBING_FAILED
The probring failed.
Definition: xrt_results.h:149
@ XRT_ERROR_SWAPCHAIN_FLAG_VALID_BUT_UNSUPPORTED
Returned when a swapchain create flag is passed that is valid, but not supported by the main composit...
Definition: xrt_results.h:76
@ XRT_ERROR_UNSUPPORTED_SPACE_TYPE
The supplied space type is not supported for this operation.
Definition: xrt_results.h:191
@ XRT_ERROR_OPENGL
Other unspecified error related to OpenGL.
Definition: xrt_results.h:60
@ XRT_ERROR_VULKAN
Other unspecified error related to Vulkan.
Definition: xrt_results.h:55
@ XRT_ERROR_IPC_COMPOSITOR_NOT_CREATED
The client has not created a compositor on this IPC connection, which is needed for the given command...
Definition: xrt_results.h:181
@ XRT_ERROR_FAILED_TO_SUBMIT_VULKAN_COMMANDS
The function tried to submit Vulkan commands but received an error.
Definition: xrt_results.h:65
@ XRT_ERROR_POSE_NOT_ACTIVE
The pose is no longer active, this happens when the application tries to get a pose that is no longer...
Definition: xrt_results.h:87
@ XRT_ERROR_COMPOSITOR_NOT_SUPPORTED
The system doesn't support compositor, this error can be returned when trying to create the system co...
Definition: xrt_results.h:176
@ XRT_ERROR_THREADING_INIT_FAILURE
Failed to initialize threading components.
Definition: xrt_results.h:118
@ XRT_ERROR_NO_IMAGE_AVAILABLE
Returned when trying to acquire or release an image and there is no image left to acquire/no space in...
Definition: xrt_results.h:50
@ XRT_ERROR_MULTI_SESSION_NOT_IMPLEMENTED
Multiple not supported on this layer level (IPC, compositor).
Definition: xrt_results.h:102
@ XRT_ERROR_ALLOCATION
Could not allocate native image buffer(s).
Definition: xrt_results.h:81
@ XRT_SPACE_BOUNDS_UNAVAILABLE
The space’s bounds are not known at the moment.
Definition: xrt_results.h:38
@ XRT_ERROR_PROBER_NOT_SUPPORTED
The prober list has not been locked before this call.
Definition: xrt_results.h:133
@ XRT_ERROR_ANDROID
Some other Android error, typically a logic error that should be impossible to reach.
Definition: xrt_results.h:196
@ XRT_ERROR_PROBER_LIST_LOCKED
The prober list is locked (already).
Definition: xrt_results.h:141
@ XRT_ERROR_SWAPCHAIN_FORMAT_UNSUPPORTED
The requested format is not supported by Monado.
Definition: xrt_results.h:107
@ XRT_ERROR_D3D12
Some D3D12 error.
Definition: xrt_results.h:165
@ XRT_ERROR_IPC_SESSION_NOT_CREATED
The client has not created a session on this IPC connection, which is needed for the given command.
Definition: xrt_results.h:124
@ XRT_SUCCESS
The operation succeeded.
Definition: xrt_results.h:26
@ XRT_ERROR_PROBER_CREATION_FAILED
Creating the xrt_prober failed.
Definition: xrt_results.h:137
@ XRT_TIMEOUT
The operation was given a timeout and timed out.
Definition: xrt_results.h:33
@ XRT_ERROR_D3D
Some D3D error, from code shared between D3D11 and D3D12.
Definition: xrt_results.h:157
@ XRT_ERROR_NOT_IMPLEMENTED
The interface function called is not implemented by its interface.
Definition: xrt_results.h:186
@ XRT_ERROR_IPC_FAILURE
A problem occurred either with the IPC transport itself, with invalid commands from the client,...
Definition: xrt_results.h:44
@ XRT_ERROR_D3D11
Some D3D11 error.
Definition: xrt_results.h:161
@ XRT_ERROR_RECENTERING_NOT_SUPPORTED
The xrt_space_overseer doesn't support recentering driven from the application side of things.
Definition: xrt_results.h:170
@ XRT_ERROR_PROBER_LIST_NOT_LOCKED
The prober list has not been locked before this call.
Definition: xrt_results.h:145
@ XRT_ERROR_FEATURE_NOT_SUPPORTED
Returned when a feature is not supported by the device.
Definition: xrt_results.h:201