Monado OpenXR Runtime
Loading...
Searching...
No Matches
oxr_rebinding_profile.h
Go to the documentation of this file.
1// Copyright 2026, NVIDIA CORPORATION.
2// SPDX-License-Identifier: BSL-1.0
3/*!
4 * @file
5 * @brief Runtime OpenXR-level rebinding profile data.
6 * @ingroup oxr_main
7 */
8
9#pragma once
10
11#include "xrt/xrt_device.h"
12
13#include "oxr_extension_support.h"
15#include "oxr_generated_bindings.h"
16
17
18#ifdef __cplusplus
19extern "C" {
20#endif
21
22/*!
23 * Single source-to-target binding path mapping in a rebinding profile.
24 */
26{
27 XrPath source_path;
28 XrPath target_path;
29};
30
31/*!
32 * Maps binding paths from one interaction profile onto another.
33 *
34 * Used when an app suggests bindings for a source profile that the device does
35 * not expose directly. Listed source paths are remapped to the target profile;
36 * unmapped paths are dropped.
37 *
38 * This struct is never mutated after creation from the templates.
39 */
41{
42 //! Immutable generated source template.
43 const struct oxr_rebinding_profile_template *templ;
44 //! Source interaction profile path.
46 //! Target interaction profile path.
48
49 //! Source-to-target binding path mappings.
51 size_t binding_count;
52};
53
54/*!
55 * Find a target binding path in a rebinding profile for @p source_path.
56 *
57 * @memberof oxr_rebinding_profile
58 */
59bool
60oxr_rebinding_profile_find_target(const struct oxr_rebinding_profile *profile,
61 XrPath source_path,
62 XrPath *out_target_path);
63
64
65#ifdef __cplusplus
66}
67#endif
Forward declarations for OpenXR state tracker structs.
Maps binding paths from one interaction profile onto another.
Definition oxr_rebinding_profile.h:41
XrPath target_profile_path
Target interaction profile path.
Definition oxr_rebinding_profile.h:47
struct oxr_rebinding * bindings
Source-to-target binding path mappings.
Definition oxr_rebinding_profile.h:50
const struct oxr_rebinding_profile_template * templ
Immutable generated source template.
Definition oxr_rebinding_profile.h:43
XrPath source_profile_path
Source interaction profile path.
Definition oxr_rebinding_profile.h:45
Single source-to-target binding path mapping in a rebinding profile.
Definition oxr_rebinding_profile.h:26
Header defining an xrt display or controller device.