Skip to content

Commit

Permalink
DestroyOpenXRDebugUtilsMessenger: return XrResult
Browse files Browse the repository at this point in the history
  • Loading branch information
TheMostDiligent committed Dec 16, 2024
1 parent 1560ed3 commit 969047c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Graphics/GraphicsTools/interface/OpenXRUtilities.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ XrDebugUtilsMessengerEXT DILIGENT_GLOBAL_FUNCTION(CreateOpenXRDebugUtilsMessenge
XrDebugUtilsMessageSeverityFlagsEXT xrMessageSeverities);

/// Destroys OpenXR debug utils messenger.
void DILIGENT_GLOBAL_FUNCTION(DestroyOpenXRDebugUtilsMessenger)(XrDebugUtilsMessengerEXT xrDebugUtilsMessenger);
XrResult DILIGENT_GLOBAL_FUNCTION(DestroyOpenXRDebugUtilsMessenger)(XrDebugUtilsMessengerEXT xrDebugUtilsMessenger);

/// Allocates OpenXR swapchain image data, i.e. an array of appropriate structures for each device
/// type (XrSwapchainImageVulkanKHR, XrSwapchainImageD3D11KHR, etc.).
Expand Down
6 changes: 4 additions & 2 deletions Graphics/GraphicsTools/src/OpenXRUtilities.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -343,12 +343,14 @@ XrDebugUtilsMessengerEXT CreateOpenXRDebugUtilsMessenger(XrInstance
return debugUtilsMessenger;
}

void DestroyOpenXRDebugUtilsMessenger(XrDebugUtilsMessengerEXT debugUtilsMessenger)
XrResult DestroyOpenXRDebugUtilsMessenger(XrDebugUtilsMessengerEXT debugUtilsMessenger)
{
XrResult Res = XR_ERROR_FUNCTION_UNSUPPORTED;
if (xrDestroyDebugUtilsMessengerEXT)
{
xrDestroyDebugUtilsMessengerEXT(debugUtilsMessenger);
Res = xrDestroyDebugUtilsMessengerEXT(debugUtilsMessenger);
}
return Res;
}

} // namespace Diligent
Expand Down

0 comments on commit 969047c

Please sign in to comment.