Path: blob/master/thirdparty/openxr/src/loader/xr_generated_loader.cpp
9917 views
// Copyright (c) 2017-2025 The Khronos Group Inc.1// Copyright (c) 2017-2019 Valve Corporation2// Copyright (c) 2017-2019 LunarG, Inc.3// SPDX-License-Identifier: Apache-2.0 OR MIT4// *********** THIS FILE IS GENERATED - DO NOT EDIT ***********5// See loader_source_generator.py for modifications6// ************************************************************78// Copyright (c) 2017-2025 The Khronos Group Inc.9// Copyright (c) 2017-2019 Valve Corporation10// Copyright (c) 2017-2019 LunarG, Inc.11//12// SPDX-License-Identifier: Apache-2.013//14// Licensed under the Apache License, Version 2.0 (the "License");15// you may not use this file except in compliance with the License.16// You may obtain a copy of the License at17//18// http://www.apache.org/licenses/LICENSE-2.019//20// Unless required by applicable law or agreed to in writing, software21// distributed under the License is distributed on an "AS IS" BASIS,22// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.23// See the License for the specific language governing permissions and24// limitations under the License.25//26// Author: Mark Young <[email protected]>27//2829#include "xr_generated_loader.hpp"3031#include "api_layer_interface.hpp"32#include "exception_handling.hpp"33#include "hex_and_handles.h"34#include "loader_instance.hpp"35#include "loader_logger.hpp"36#include "loader_platform.hpp"37#include "runtime_interface.hpp"38#include "xr_generated_dispatch_table_core.h"3940#include "xr_dependencies.h"41#include <openxr/openxr.h>42#include <openxr/openxr_platform.h>4344#include <cstring>45#include <memory>46#include <new>47#include <string>48#include <unordered_map>495051// Automatically generated instance trampolines and terminators52extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetInstanceProperties(53XrInstance instance,54XrInstanceProperties* instanceProperties) XRLOADER_ABI_TRY {55LoaderInstance* loader_instance;56XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrGetInstanceProperties");57if (XR_SUCCEEDED(result)) {58result = loader_instance->DispatchTable()->GetInstanceProperties(instance, instanceProperties);59}60return result;61}62XRLOADER_ABI_CATCH_FALLBACK6364extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrPollEvent(65XrInstance instance,66XrEventDataBuffer* eventData) XRLOADER_ABI_TRY {67LoaderInstance* loader_instance;68XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrPollEvent");69if (XR_SUCCEEDED(result)) {70result = loader_instance->DispatchTable()->PollEvent(instance, eventData);71}72return result;73}74XRLOADER_ABI_CATCH_FALLBACK7576extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrResultToString(77XrInstance instance,78XrResult value,79char buffer[XR_MAX_RESULT_STRING_SIZE]) XRLOADER_ABI_TRY {80LoaderInstance* loader_instance;81XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrResultToString");82if (XR_SUCCEEDED(result)) {83result = loader_instance->DispatchTable()->ResultToString(instance, value, buffer);84}85return result;86}87XRLOADER_ABI_CATCH_FALLBACK8889extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrStructureTypeToString(90XrInstance instance,91XrStructureType value,92char buffer[XR_MAX_STRUCTURE_NAME_SIZE]) XRLOADER_ABI_TRY {93LoaderInstance* loader_instance;94XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrStructureTypeToString");95if (XR_SUCCEEDED(result)) {96result = loader_instance->DispatchTable()->StructureTypeToString(instance, value, buffer);97}98return result;99}100XRLOADER_ABI_CATCH_FALLBACK101102extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetSystem(103XrInstance instance,104const XrSystemGetInfo* getInfo,105XrSystemId* systemId) XRLOADER_ABI_TRY {106LoaderInstance* loader_instance;107XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrGetSystem");108if (XR_SUCCEEDED(result)) {109result = loader_instance->DispatchTable()->GetSystem(instance, getInfo, systemId);110}111return result;112}113XRLOADER_ABI_CATCH_FALLBACK114115extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetSystemProperties(116XrInstance instance,117XrSystemId systemId,118XrSystemProperties* properties) XRLOADER_ABI_TRY {119LoaderInstance* loader_instance;120XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrGetSystemProperties");121if (XR_SUCCEEDED(result)) {122result = loader_instance->DispatchTable()->GetSystemProperties(instance, systemId, properties);123}124return result;125}126XRLOADER_ABI_CATCH_FALLBACK127128extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateEnvironmentBlendModes(129XrInstance instance,130XrSystemId systemId,131XrViewConfigurationType viewConfigurationType,132uint32_t environmentBlendModeCapacityInput,133uint32_t* environmentBlendModeCountOutput,134XrEnvironmentBlendMode* environmentBlendModes) XRLOADER_ABI_TRY {135LoaderInstance* loader_instance;136XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrEnumerateEnvironmentBlendModes");137if (XR_SUCCEEDED(result)) {138result = loader_instance->DispatchTable()->EnumerateEnvironmentBlendModes(instance, systemId, viewConfigurationType, environmentBlendModeCapacityInput, environmentBlendModeCountOutput, environmentBlendModes);139}140return result;141}142XRLOADER_ABI_CATCH_FALLBACK143144extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrCreateSession(145XrInstance instance,146const XrSessionCreateInfo* createInfo,147XrSession* session) XRLOADER_ABI_TRY {148LoaderInstance* loader_instance;149XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrCreateSession");150if (XR_SUCCEEDED(result)) {151result = loader_instance->DispatchTable()->CreateSession(instance, createInfo, session);152}153return result;154}155XRLOADER_ABI_CATCH_FALLBACK156157extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrDestroySession(158XrSession session) XRLOADER_ABI_TRY {159LoaderInstance* loader_instance;160XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrDestroySession");161if (XR_SUCCEEDED(result)) {162result = loader_instance->DispatchTable()->DestroySession(session);163}164return result;165}166XRLOADER_ABI_CATCH_FALLBACK167168extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateReferenceSpaces(169XrSession session,170uint32_t spaceCapacityInput,171uint32_t* spaceCountOutput,172XrReferenceSpaceType* spaces) XRLOADER_ABI_TRY {173LoaderInstance* loader_instance;174XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrEnumerateReferenceSpaces");175if (XR_SUCCEEDED(result)) {176result = loader_instance->DispatchTable()->EnumerateReferenceSpaces(session, spaceCapacityInput, spaceCountOutput, spaces);177}178return result;179}180XRLOADER_ABI_CATCH_FALLBACK181182extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrCreateReferenceSpace(183XrSession session,184const XrReferenceSpaceCreateInfo* createInfo,185XrSpace* space) XRLOADER_ABI_TRY {186LoaderInstance* loader_instance;187XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrCreateReferenceSpace");188if (XR_SUCCEEDED(result)) {189result = loader_instance->DispatchTable()->CreateReferenceSpace(session, createInfo, space);190}191return result;192}193XRLOADER_ABI_CATCH_FALLBACK194195extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetReferenceSpaceBoundsRect(196XrSession session,197XrReferenceSpaceType referenceSpaceType,198XrExtent2Df* bounds) XRLOADER_ABI_TRY {199LoaderInstance* loader_instance;200XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrGetReferenceSpaceBoundsRect");201if (XR_SUCCEEDED(result)) {202result = loader_instance->DispatchTable()->GetReferenceSpaceBoundsRect(session, referenceSpaceType, bounds);203}204return result;205}206XRLOADER_ABI_CATCH_FALLBACK207208extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrCreateActionSpace(209XrSession session,210const XrActionSpaceCreateInfo* createInfo,211XrSpace* space) XRLOADER_ABI_TRY {212LoaderInstance* loader_instance;213XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrCreateActionSpace");214if (XR_SUCCEEDED(result)) {215result = loader_instance->DispatchTable()->CreateActionSpace(session, createInfo, space);216}217return result;218}219XRLOADER_ABI_CATCH_FALLBACK220221extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrLocateSpace(222XrSpace space,223XrSpace baseSpace,224XrTime time,225XrSpaceLocation* location) XRLOADER_ABI_TRY {226LoaderInstance* loader_instance;227XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrLocateSpace");228if (XR_SUCCEEDED(result)) {229result = loader_instance->DispatchTable()->LocateSpace(space, baseSpace, time, location);230}231return result;232}233XRLOADER_ABI_CATCH_FALLBACK234235extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrDestroySpace(236XrSpace space) XRLOADER_ABI_TRY {237LoaderInstance* loader_instance;238XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrDestroySpace");239if (XR_SUCCEEDED(result)) {240result = loader_instance->DispatchTable()->DestroySpace(space);241}242return result;243}244XRLOADER_ABI_CATCH_FALLBACK245246extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateViewConfigurations(247XrInstance instance,248XrSystemId systemId,249uint32_t viewConfigurationTypeCapacityInput,250uint32_t* viewConfigurationTypeCountOutput,251XrViewConfigurationType* viewConfigurationTypes) XRLOADER_ABI_TRY {252LoaderInstance* loader_instance;253XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrEnumerateViewConfigurations");254if (XR_SUCCEEDED(result)) {255result = loader_instance->DispatchTable()->EnumerateViewConfigurations(instance, systemId, viewConfigurationTypeCapacityInput, viewConfigurationTypeCountOutput, viewConfigurationTypes);256}257return result;258}259XRLOADER_ABI_CATCH_FALLBACK260261extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetViewConfigurationProperties(262XrInstance instance,263XrSystemId systemId,264XrViewConfigurationType viewConfigurationType,265XrViewConfigurationProperties* configurationProperties) XRLOADER_ABI_TRY {266LoaderInstance* loader_instance;267XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrGetViewConfigurationProperties");268if (XR_SUCCEEDED(result)) {269result = loader_instance->DispatchTable()->GetViewConfigurationProperties(instance, systemId, viewConfigurationType, configurationProperties);270}271return result;272}273XRLOADER_ABI_CATCH_FALLBACK274275extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateViewConfigurationViews(276XrInstance instance,277XrSystemId systemId,278XrViewConfigurationType viewConfigurationType,279uint32_t viewCapacityInput,280uint32_t* viewCountOutput,281XrViewConfigurationView* views) XRLOADER_ABI_TRY {282LoaderInstance* loader_instance;283XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrEnumerateViewConfigurationViews");284if (XR_SUCCEEDED(result)) {285result = loader_instance->DispatchTable()->EnumerateViewConfigurationViews(instance, systemId, viewConfigurationType, viewCapacityInput, viewCountOutput, views);286}287return result;288}289XRLOADER_ABI_CATCH_FALLBACK290291extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateSwapchainFormats(292XrSession session,293uint32_t formatCapacityInput,294uint32_t* formatCountOutput,295int64_t* formats) XRLOADER_ABI_TRY {296LoaderInstance* loader_instance;297XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrEnumerateSwapchainFormats");298if (XR_SUCCEEDED(result)) {299result = loader_instance->DispatchTable()->EnumerateSwapchainFormats(session, formatCapacityInput, formatCountOutput, formats);300}301return result;302}303XRLOADER_ABI_CATCH_FALLBACK304305extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrCreateSwapchain(306XrSession session,307const XrSwapchainCreateInfo* createInfo,308XrSwapchain* swapchain) XRLOADER_ABI_TRY {309LoaderInstance* loader_instance;310XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrCreateSwapchain");311if (XR_SUCCEEDED(result)) {312result = loader_instance->DispatchTable()->CreateSwapchain(session, createInfo, swapchain);313}314return result;315}316XRLOADER_ABI_CATCH_FALLBACK317318extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrDestroySwapchain(319XrSwapchain swapchain) XRLOADER_ABI_TRY {320LoaderInstance* loader_instance;321XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrDestroySwapchain");322if (XR_SUCCEEDED(result)) {323result = loader_instance->DispatchTable()->DestroySwapchain(swapchain);324}325return result;326}327XRLOADER_ABI_CATCH_FALLBACK328329extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateSwapchainImages(330XrSwapchain swapchain,331uint32_t imageCapacityInput,332uint32_t* imageCountOutput,333XrSwapchainImageBaseHeader* images) XRLOADER_ABI_TRY {334LoaderInstance* loader_instance;335XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrEnumerateSwapchainImages");336if (XR_SUCCEEDED(result)) {337result = loader_instance->DispatchTable()->EnumerateSwapchainImages(swapchain, imageCapacityInput, imageCountOutput, images);338}339return result;340}341XRLOADER_ABI_CATCH_FALLBACK342343extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrAcquireSwapchainImage(344XrSwapchain swapchain,345const XrSwapchainImageAcquireInfo* acquireInfo,346uint32_t* index) XRLOADER_ABI_TRY {347LoaderInstance* loader_instance;348XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrAcquireSwapchainImage");349if (XR_SUCCEEDED(result)) {350result = loader_instance->DispatchTable()->AcquireSwapchainImage(swapchain, acquireInfo, index);351}352return result;353}354XRLOADER_ABI_CATCH_FALLBACK355356extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrWaitSwapchainImage(357XrSwapchain swapchain,358const XrSwapchainImageWaitInfo* waitInfo) XRLOADER_ABI_TRY {359LoaderInstance* loader_instance;360XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrWaitSwapchainImage");361if (XR_SUCCEEDED(result)) {362result = loader_instance->DispatchTable()->WaitSwapchainImage(swapchain, waitInfo);363}364return result;365}366XRLOADER_ABI_CATCH_FALLBACK367368extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrReleaseSwapchainImage(369XrSwapchain swapchain,370const XrSwapchainImageReleaseInfo* releaseInfo) XRLOADER_ABI_TRY {371LoaderInstance* loader_instance;372XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrReleaseSwapchainImage");373if (XR_SUCCEEDED(result)) {374result = loader_instance->DispatchTable()->ReleaseSwapchainImage(swapchain, releaseInfo);375}376return result;377}378XRLOADER_ABI_CATCH_FALLBACK379380extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrBeginSession(381XrSession session,382const XrSessionBeginInfo* beginInfo) XRLOADER_ABI_TRY {383LoaderInstance* loader_instance;384XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrBeginSession");385if (XR_SUCCEEDED(result)) {386result = loader_instance->DispatchTable()->BeginSession(session, beginInfo);387}388return result;389}390XRLOADER_ABI_CATCH_FALLBACK391392extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEndSession(393XrSession session) XRLOADER_ABI_TRY {394LoaderInstance* loader_instance;395XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrEndSession");396if (XR_SUCCEEDED(result)) {397result = loader_instance->DispatchTable()->EndSession(session);398}399return result;400}401XRLOADER_ABI_CATCH_FALLBACK402403extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrRequestExitSession(404XrSession session) XRLOADER_ABI_TRY {405LoaderInstance* loader_instance;406XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrRequestExitSession");407if (XR_SUCCEEDED(result)) {408result = loader_instance->DispatchTable()->RequestExitSession(session);409}410return result;411}412XRLOADER_ABI_CATCH_FALLBACK413414extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrWaitFrame(415XrSession session,416const XrFrameWaitInfo* frameWaitInfo,417XrFrameState* frameState) XRLOADER_ABI_TRY {418LoaderInstance* loader_instance;419XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrWaitFrame");420if (XR_SUCCEEDED(result)) {421result = loader_instance->DispatchTable()->WaitFrame(session, frameWaitInfo, frameState);422}423return result;424}425XRLOADER_ABI_CATCH_FALLBACK426427extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrBeginFrame(428XrSession session,429const XrFrameBeginInfo* frameBeginInfo) XRLOADER_ABI_TRY {430LoaderInstance* loader_instance;431XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrBeginFrame");432if (XR_SUCCEEDED(result)) {433result = loader_instance->DispatchTable()->BeginFrame(session, frameBeginInfo);434}435return result;436}437XRLOADER_ABI_CATCH_FALLBACK438439extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEndFrame(440XrSession session,441const XrFrameEndInfo* frameEndInfo) XRLOADER_ABI_TRY {442LoaderInstance* loader_instance;443XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrEndFrame");444if (XR_SUCCEEDED(result)) {445result = loader_instance->DispatchTable()->EndFrame(session, frameEndInfo);446}447return result;448}449XRLOADER_ABI_CATCH_FALLBACK450451extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrLocateViews(452XrSession session,453const XrViewLocateInfo* viewLocateInfo,454XrViewState* viewState,455uint32_t viewCapacityInput,456uint32_t* viewCountOutput,457XrView* views) XRLOADER_ABI_TRY {458LoaderInstance* loader_instance;459XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrLocateViews");460if (XR_SUCCEEDED(result)) {461result = loader_instance->DispatchTable()->LocateViews(session, viewLocateInfo, viewState, viewCapacityInput, viewCountOutput, views);462}463return result;464}465XRLOADER_ABI_CATCH_FALLBACK466467extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrStringToPath(468XrInstance instance,469const char* pathString,470XrPath* path) XRLOADER_ABI_TRY {471LoaderInstance* loader_instance;472XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrStringToPath");473if (XR_SUCCEEDED(result)) {474result = loader_instance->DispatchTable()->StringToPath(instance, pathString, path);475}476return result;477}478XRLOADER_ABI_CATCH_FALLBACK479480extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrPathToString(481XrInstance instance,482XrPath path,483uint32_t bufferCapacityInput,484uint32_t* bufferCountOutput,485char* buffer) XRLOADER_ABI_TRY {486LoaderInstance* loader_instance;487XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrPathToString");488if (XR_SUCCEEDED(result)) {489result = loader_instance->DispatchTable()->PathToString(instance, path, bufferCapacityInput, bufferCountOutput, buffer);490}491return result;492}493XRLOADER_ABI_CATCH_FALLBACK494495extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrCreateActionSet(496XrInstance instance,497const XrActionSetCreateInfo* createInfo,498XrActionSet* actionSet) XRLOADER_ABI_TRY {499LoaderInstance* loader_instance;500XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrCreateActionSet");501if (XR_SUCCEEDED(result)) {502result = loader_instance->DispatchTable()->CreateActionSet(instance, createInfo, actionSet);503}504return result;505}506XRLOADER_ABI_CATCH_FALLBACK507508extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrDestroyActionSet(509XrActionSet actionSet) XRLOADER_ABI_TRY {510LoaderInstance* loader_instance;511XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrDestroyActionSet");512if (XR_SUCCEEDED(result)) {513result = loader_instance->DispatchTable()->DestroyActionSet(actionSet);514}515return result;516}517XRLOADER_ABI_CATCH_FALLBACK518519extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrCreateAction(520XrActionSet actionSet,521const XrActionCreateInfo* createInfo,522XrAction* action) XRLOADER_ABI_TRY {523LoaderInstance* loader_instance;524XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrCreateAction");525if (XR_SUCCEEDED(result)) {526result = loader_instance->DispatchTable()->CreateAction(actionSet, createInfo, action);527}528return result;529}530XRLOADER_ABI_CATCH_FALLBACK531532extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrDestroyAction(533XrAction action) XRLOADER_ABI_TRY {534LoaderInstance* loader_instance;535XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrDestroyAction");536if (XR_SUCCEEDED(result)) {537result = loader_instance->DispatchTable()->DestroyAction(action);538}539return result;540}541XRLOADER_ABI_CATCH_FALLBACK542543extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrSuggestInteractionProfileBindings(544XrInstance instance,545const XrInteractionProfileSuggestedBinding* suggestedBindings) XRLOADER_ABI_TRY {546LoaderInstance* loader_instance;547XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrSuggestInteractionProfileBindings");548if (XR_SUCCEEDED(result)) {549result = loader_instance->DispatchTable()->SuggestInteractionProfileBindings(instance, suggestedBindings);550}551return result;552}553XRLOADER_ABI_CATCH_FALLBACK554555extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrAttachSessionActionSets(556XrSession session,557const XrSessionActionSetsAttachInfo* attachInfo) XRLOADER_ABI_TRY {558LoaderInstance* loader_instance;559XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrAttachSessionActionSets");560if (XR_SUCCEEDED(result)) {561result = loader_instance->DispatchTable()->AttachSessionActionSets(session, attachInfo);562}563return result;564}565XRLOADER_ABI_CATCH_FALLBACK566567extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetCurrentInteractionProfile(568XrSession session,569XrPath topLevelUserPath,570XrInteractionProfileState* interactionProfile) XRLOADER_ABI_TRY {571LoaderInstance* loader_instance;572XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrGetCurrentInteractionProfile");573if (XR_SUCCEEDED(result)) {574result = loader_instance->DispatchTable()->GetCurrentInteractionProfile(session, topLevelUserPath, interactionProfile);575}576return result;577}578XRLOADER_ABI_CATCH_FALLBACK579580extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetActionStateBoolean(581XrSession session,582const XrActionStateGetInfo* getInfo,583XrActionStateBoolean* state) XRLOADER_ABI_TRY {584LoaderInstance* loader_instance;585XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrGetActionStateBoolean");586if (XR_SUCCEEDED(result)) {587result = loader_instance->DispatchTable()->GetActionStateBoolean(session, getInfo, state);588}589return result;590}591XRLOADER_ABI_CATCH_FALLBACK592593extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetActionStateFloat(594XrSession session,595const XrActionStateGetInfo* getInfo,596XrActionStateFloat* state) XRLOADER_ABI_TRY {597LoaderInstance* loader_instance;598XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrGetActionStateFloat");599if (XR_SUCCEEDED(result)) {600result = loader_instance->DispatchTable()->GetActionStateFloat(session, getInfo, state);601}602return result;603}604XRLOADER_ABI_CATCH_FALLBACK605606extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetActionStateVector2f(607XrSession session,608const XrActionStateGetInfo* getInfo,609XrActionStateVector2f* state) XRLOADER_ABI_TRY {610LoaderInstance* loader_instance;611XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrGetActionStateVector2f");612if (XR_SUCCEEDED(result)) {613result = loader_instance->DispatchTable()->GetActionStateVector2f(session, getInfo, state);614}615return result;616}617XRLOADER_ABI_CATCH_FALLBACK618619extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetActionStatePose(620XrSession session,621const XrActionStateGetInfo* getInfo,622XrActionStatePose* state) XRLOADER_ABI_TRY {623LoaderInstance* loader_instance;624XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrGetActionStatePose");625if (XR_SUCCEEDED(result)) {626result = loader_instance->DispatchTable()->GetActionStatePose(session, getInfo, state);627}628return result;629}630XRLOADER_ABI_CATCH_FALLBACK631632extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrSyncActions(633XrSession session,634const XrActionsSyncInfo* syncInfo) XRLOADER_ABI_TRY {635LoaderInstance* loader_instance;636XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrSyncActions");637if (XR_SUCCEEDED(result)) {638result = loader_instance->DispatchTable()->SyncActions(session, syncInfo);639}640return result;641}642XRLOADER_ABI_CATCH_FALLBACK643644extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrEnumerateBoundSourcesForAction(645XrSession session,646const XrBoundSourcesForActionEnumerateInfo* enumerateInfo,647uint32_t sourceCapacityInput,648uint32_t* sourceCountOutput,649XrPath* sources) XRLOADER_ABI_TRY {650LoaderInstance* loader_instance;651XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrEnumerateBoundSourcesForAction");652if (XR_SUCCEEDED(result)) {653result = loader_instance->DispatchTable()->EnumerateBoundSourcesForAction(session, enumerateInfo, sourceCapacityInput, sourceCountOutput, sources);654}655return result;656}657XRLOADER_ABI_CATCH_FALLBACK658659extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrGetInputSourceLocalizedName(660XrSession session,661const XrInputSourceLocalizedNameGetInfo* getInfo,662uint32_t bufferCapacityInput,663uint32_t* bufferCountOutput,664char* buffer) XRLOADER_ABI_TRY {665LoaderInstance* loader_instance;666XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrGetInputSourceLocalizedName");667if (XR_SUCCEEDED(result)) {668result = loader_instance->DispatchTable()->GetInputSourceLocalizedName(session, getInfo, bufferCapacityInput, bufferCountOutput, buffer);669}670return result;671}672XRLOADER_ABI_CATCH_FALLBACK673674extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrApplyHapticFeedback(675XrSession session,676const XrHapticActionInfo* hapticActionInfo,677const XrHapticBaseHeader* hapticFeedback) XRLOADER_ABI_TRY {678LoaderInstance* loader_instance;679XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrApplyHapticFeedback");680if (XR_SUCCEEDED(result)) {681result = loader_instance->DispatchTable()->ApplyHapticFeedback(session, hapticActionInfo, hapticFeedback);682}683return result;684}685XRLOADER_ABI_CATCH_FALLBACK686687extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrStopHapticFeedback(688XrSession session,689const XrHapticActionInfo* hapticActionInfo) XRLOADER_ABI_TRY {690LoaderInstance* loader_instance;691XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrStopHapticFeedback");692if (XR_SUCCEEDED(result)) {693result = loader_instance->DispatchTable()->StopHapticFeedback(session, hapticActionInfo);694}695return result;696}697XRLOADER_ABI_CATCH_FALLBACK698699extern "C" LOADER_EXPORT XRAPI_ATTR XrResult XRAPI_CALL xrLocateSpaces(700XrSession session,701const XrSpacesLocateInfo* locateInfo,702XrSpaceLocations* spaceLocations) XRLOADER_ABI_TRY {703LoaderInstance* loader_instance;704XrResult result = ActiveLoaderInstance::Get(&loader_instance, "xrLocateSpaces");705if (XR_SUCCEEDED(result)) {706result = loader_instance->DispatchTable()->LocateSpaces(session, locateInfo, spaceLocations);707}708return result;709}710XRLOADER_ABI_CATCH_FALLBACK711712713714715