st/oxr: Fix up Monado experimental extensions

This commit is contained in:
Korcan Hussein 2023-06-29 00:01:36 +01:00 committed by Jakob Bornecrantz
parent 230c059d27
commit a8c5be8f5c
5 changed files with 72 additions and 3 deletions

View file

@ -65,6 +65,7 @@ EXTENSIONS = (
['XR_MNDX_ball_on_a_stick_controller'],
['XR_MNDX_egl_enable', 'XR_USE_PLATFORM_EGL', 'XR_USE_GRAPHICS_API_OPENGL'],
['XR_MNDX_force_feedback_curl'],
['XR_MNDX_hydra'],
)

View file

@ -0,0 +1,26 @@
// Copyright 2023, Collabora, Ltd.
// SPDX-License-Identifier: BSL-1.0
/*!
* @file
* @brief Preview header for XR_MNDX_ball_on_a_stick_controller extension
* @author Korcan Hussein <korcan.hussein@collabora.com>
* @ingroup external_openxr
*/
#ifndef XR_MNDX_BALL_ON_A_STICK_CONTROLLER_H
#define XR_MNDX_BALL_ON_A_STICK_CONTROLLER_H 1
#include <openxr/openxr.h>
#ifdef __cplusplus
extern "C" {
#endif
#define XR_MNDX_ball_on_a_stick_controller 1
#define XR_MNDX_ball_on_a_stick_controller_SPEC_VERSION 1
#define XR_MNDX_BALL_ON_A_STICK_CONTROLLER_EXTENSION_NAME "XR_MNDX_ball_on_a_stick_controller"
#ifdef __cplusplus
}
#endif
#endif

View file

@ -0,0 +1,26 @@
// Copyright 2023, Collabora, Ltd.
// SPDX-License-Identifier: BSL-1.0
/*!
* @file
* @brief Preview header for XR_MNDX_hydra extension
* @author Korcan Hussein <korcan.hussein@collabora.com>
* @ingroup external_openxr
*/
#ifndef XR_MNDX_HYDRA_H
#define XR_MNDX_HYDRA_H 1
#include <openxr/openxr.h>
#ifdef __cplusplus
extern "C" {
#endif
#define XR_MNDX_hydra 1
#define XR_MNDX_hydra_SPEC_VERSION 1
#define XR_MNDX_HYDRA_EXTENSION_NAME "XR_MNDX_hydra"
#ifdef __cplusplus
}
#endif
#endif

View file

@ -1,9 +1,10 @@
// Copyright 2018-2022, Collabora, Ltd.
// Copyright 2018-2023, Collabora, Ltd.
// SPDX-License-Identifier: BSL-1.0
/*!
* @file
* @brief Include all of the openxr headers in one place.
* @author Jakob Bornecrantz <jakob@collabora.com>
* @author Korcan Hussein <korcan.hussein@collabora.com>
* @ingroup xrt_iface
*/
@ -48,3 +49,6 @@ typedef __eglMustCastToProperFunctionPointerType (*PFNEGLGETPROCADDRESSPROC)(con
#include "openxr/openxr.h"
#include "openxr/openxr_platform.h"
#include "openxr/loader_interfaces.h"
#include "openxr/XR_MNDX_hydra.h"
#include "openxr/XR_MNDX_ball_on_a_stick_controller.h"

View file

@ -1,4 +1,4 @@
// Copyright 2019-2022, Collabora, Ltd.
// Copyright 2019-2023, Collabora, Ltd.
// SPDX-License-Identifier: BSL-1.0
/*!
* @file
@ -382,6 +382,17 @@
#define OXR_EXTENSION_SUPPORT_MNDX_force_feedback_curl(_)
#endif
/*
* XR_MNDX_hydra
*/
#if defined(XR_MNDX_hydra)
#define OXR_HAVE_MNDX_hydra
#define OXR_EXTENSION_SUPPORT_MNDX_hydra(_) _(MNDX_hydra, MNDX_HYDRA)
#else
#define OXR_EXTENSION_SUPPORT_MNDX_hydra(_)
#endif
// end of GENERATED per-extension defines - do not modify - used by scripts
/*!
@ -437,5 +448,6 @@
OXR_EXTENSION_SUPPORT_EXTX_overlay(_) \
OXR_EXTENSION_SUPPORT_MNDX_ball_on_a_stick_controller(_) \
OXR_EXTENSION_SUPPORT_MNDX_egl_enable(_) \
OXR_EXTENSION_SUPPORT_MNDX_force_feedback_curl(_)
OXR_EXTENSION_SUPPORT_MNDX_force_feedback_curl(_) \
OXR_EXTENSION_SUPPORT_MNDX_hydra(_)
// clang-format on