Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
godotengine
GitHub Repository: godotengine/godot
Path: blob/master/thirdparty/openxr/src/loader/xr_generated_loader.hpp
9917 views
1
// Copyright (c) 2017-2025 The Khronos Group Inc.
2
// Copyright (c) 2017-2019 Valve Corporation
3
// Copyright (c) 2017-2019 LunarG, Inc.
4
// SPDX-License-Identifier: Apache-2.0 OR MIT
5
// *********** THIS FILE IS GENERATED - DO NOT EDIT ***********
6
// See loader_source_generator.py for modifications
7
// ************************************************************
8
9
// Copyright (c) 2017-2025 The Khronos Group Inc.
10
// Copyright (c) 2017-2019 Valve Corporation
11
// Copyright (c) 2017-2019 LunarG, Inc.
12
//
13
// SPDX-License-Identifier: Apache-2.0
14
//
15
// Licensed under the Apache License, Version 2.0 (the "License");
16
// you may not use this file except in compliance with the License.
17
// You may obtain a copy of the License at
18
//
19
// http://www.apache.org/licenses/LICENSE-2.0
20
//
21
// Unless required by applicable law or agreed to in writing, software
22
// distributed under the License is distributed on an "AS IS" BASIS,
23
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
24
// See the License for the specific language governing permissions and
25
// limitations under the License.
26
//
27
// Author: Mark Young <[email protected]>
28
//
29
30
#pragma once
31
#include <unordered_map>
32
#include <thread>
33
#include <mutex>
34
35
#include "xr_dependencies.h"
36
#include "openxr/openxr.h"
37
#include "openxr/openxr_loader_negotiation.h"
38
#include "openxr/openxr_platform.h"
39
40
#include "loader_instance.hpp"
41
42
#include "loader_platform.hpp"
43
44
45
#ifdef __cplusplus
46
extern "C" {
47
#endif
48
49
// Loader manually generated function prototypes
50
51
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetInstanceProperties(
52
XrInstance instance,
53
XrInstanceProperties* instanceProperties);
54
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrPollEvent(
55
XrInstance instance,
56
XrEventDataBuffer* eventData);
57
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrResultToString(
58
XrInstance instance,
59
XrResult value,
60
char buffer[XR_MAX_RESULT_STRING_SIZE]);
61
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrStructureTypeToString(
62
XrInstance instance,
63
XrStructureType value,
64
char buffer[XR_MAX_STRUCTURE_NAME_SIZE]);
65
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetSystem(
66
XrInstance instance,
67
const XrSystemGetInfo* getInfo,
68
XrSystemId* systemId);
69
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetSystemProperties(
70
XrInstance instance,
71
XrSystemId systemId,
72
XrSystemProperties* properties);
73
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateEnvironmentBlendModes(
74
XrInstance instance,
75
XrSystemId systemId,
76
XrViewConfigurationType viewConfigurationType,
77
uint32_t environmentBlendModeCapacityInput,
78
uint32_t* environmentBlendModeCountOutput,
79
XrEnvironmentBlendMode* environmentBlendModes);
80
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrCreateSession(
81
XrInstance instance,
82
const XrSessionCreateInfo* createInfo,
83
XrSession* session);
84
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrDestroySession(
85
XrSession session);
86
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateReferenceSpaces(
87
XrSession session,
88
uint32_t spaceCapacityInput,
89
uint32_t* spaceCountOutput,
90
XrReferenceSpaceType* spaces);
91
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrCreateReferenceSpace(
92
XrSession session,
93
const XrReferenceSpaceCreateInfo* createInfo,
94
XrSpace* space);
95
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetReferenceSpaceBoundsRect(
96
XrSession session,
97
XrReferenceSpaceType referenceSpaceType,
98
XrExtent2Df* bounds);
99
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrCreateActionSpace(
100
XrSession session,
101
const XrActionSpaceCreateInfo* createInfo,
102
XrSpace* space);
103
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrLocateSpace(
104
XrSpace space,
105
XrSpace baseSpace,
106
XrTime time,
107
XrSpaceLocation* location);
108
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrDestroySpace(
109
XrSpace space);
110
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateViewConfigurations(
111
XrInstance instance,
112
XrSystemId systemId,
113
uint32_t viewConfigurationTypeCapacityInput,
114
uint32_t* viewConfigurationTypeCountOutput,
115
XrViewConfigurationType* viewConfigurationTypes);
116
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetViewConfigurationProperties(
117
XrInstance instance,
118
XrSystemId systemId,
119
XrViewConfigurationType viewConfigurationType,
120
XrViewConfigurationProperties* configurationProperties);
121
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateViewConfigurationViews(
122
XrInstance instance,
123
XrSystemId systemId,
124
XrViewConfigurationType viewConfigurationType,
125
uint32_t viewCapacityInput,
126
uint32_t* viewCountOutput,
127
XrViewConfigurationView* views);
128
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateSwapchainFormats(
129
XrSession session,
130
uint32_t formatCapacityInput,
131
uint32_t* formatCountOutput,
132
int64_t* formats);
133
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrCreateSwapchain(
134
XrSession session,
135
const XrSwapchainCreateInfo* createInfo,
136
XrSwapchain* swapchain);
137
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrDestroySwapchain(
138
XrSwapchain swapchain);
139
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateSwapchainImages(
140
XrSwapchain swapchain,
141
uint32_t imageCapacityInput,
142
uint32_t* imageCountOutput,
143
XrSwapchainImageBaseHeader* images);
144
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrAcquireSwapchainImage(
145
XrSwapchain swapchain,
146
const XrSwapchainImageAcquireInfo* acquireInfo,
147
uint32_t* index);
148
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrWaitSwapchainImage(
149
XrSwapchain swapchain,
150
const XrSwapchainImageWaitInfo* waitInfo);
151
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrReleaseSwapchainImage(
152
XrSwapchain swapchain,
153
const XrSwapchainImageReleaseInfo* releaseInfo);
154
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrBeginSession(
155
XrSession session,
156
const XrSessionBeginInfo* beginInfo);
157
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEndSession(
158
XrSession session);
159
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrRequestExitSession(
160
XrSession session);
161
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrWaitFrame(
162
XrSession session,
163
const XrFrameWaitInfo* frameWaitInfo,
164
XrFrameState* frameState);
165
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrBeginFrame(
166
XrSession session,
167
const XrFrameBeginInfo* frameBeginInfo);
168
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEndFrame(
169
XrSession session,
170
const XrFrameEndInfo* frameEndInfo);
171
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrLocateViews(
172
XrSession session,
173
const XrViewLocateInfo* viewLocateInfo,
174
XrViewState* viewState,
175
uint32_t viewCapacityInput,
176
uint32_t* viewCountOutput,
177
XrView* views);
178
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrStringToPath(
179
XrInstance instance,
180
const char* pathString,
181
XrPath* path);
182
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrPathToString(
183
XrInstance instance,
184
XrPath path,
185
uint32_t bufferCapacityInput,
186
uint32_t* bufferCountOutput,
187
char* buffer);
188
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrCreateActionSet(
189
XrInstance instance,
190
const XrActionSetCreateInfo* createInfo,
191
XrActionSet* actionSet);
192
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrDestroyActionSet(
193
XrActionSet actionSet);
194
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrCreateAction(
195
XrActionSet actionSet,
196
const XrActionCreateInfo* createInfo,
197
XrAction* action);
198
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrDestroyAction(
199
XrAction action);
200
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrSuggestInteractionProfileBindings(
201
XrInstance instance,
202
const XrInteractionProfileSuggestedBinding* suggestedBindings);
203
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrAttachSessionActionSets(
204
XrSession session,
205
const XrSessionActionSetsAttachInfo* attachInfo);
206
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetCurrentInteractionProfile(
207
XrSession session,
208
XrPath topLevelUserPath,
209
XrInteractionProfileState* interactionProfile);
210
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetActionStateBoolean(
211
XrSession session,
212
const XrActionStateGetInfo* getInfo,
213
XrActionStateBoolean* state);
214
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetActionStateFloat(
215
XrSession session,
216
const XrActionStateGetInfo* getInfo,
217
XrActionStateFloat* state);
218
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetActionStateVector2f(
219
XrSession session,
220
const XrActionStateGetInfo* getInfo,
221
XrActionStateVector2f* state);
222
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetActionStatePose(
223
XrSession session,
224
const XrActionStateGetInfo* getInfo,
225
XrActionStatePose* state);
226
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrSyncActions(
227
XrSession session,
228
const XrActionsSyncInfo* syncInfo);
229
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateBoundSourcesForAction(
230
XrSession session,
231
const XrBoundSourcesForActionEnumerateInfo* enumerateInfo,
232
uint32_t sourceCapacityInput,
233
uint32_t* sourceCountOutput,
234
XrPath* sources);
235
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetInputSourceLocalizedName(
236
XrSession session,
237
const XrInputSourceLocalizedNameGetInfo* getInfo,
238
uint32_t bufferCapacityInput,
239
uint32_t* bufferCountOutput,
240
char* buffer);
241
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrApplyHapticFeedback(
242
XrSession session,
243
const XrHapticActionInfo* hapticActionInfo,
244
const XrHapticBaseHeader* hapticFeedback);
245
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrStopHapticFeedback(
246
XrSession session,
247
const XrHapticActionInfo* hapticActionInfo);
248
extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrLocateSpaces(
249
XrSession session,
250
const XrSpacesLocateInfo* locateInfo,
251
XrSpaceLocations* spaceLocations);
252
#ifdef __cplusplus
253
} // extern "C"
254
#endif
255
256
257