Monado OpenXR Runtime
Loading...
Searching...
No Matches
oxr_hand_tracking.h
Go to the documentation of this file.
1// Copyright 2018-2024, Collabora, Ltd.
2// Copyright 2025-2026, NVIDIA CORPORATION.
3// SPDX-License-Identifier: BSL-1.0
4/*!
5 * @file
6 * @brief Hand tracking objects and functions.
7 * @author Christoph Haag <christoph.haag@collabora.com>
8 * @author Korcan Hussein <korcan.hussein@collabora.com>
9 * @ingroup oxr_main
10 */
11
12#pragma once
13
16
17#include "oxr_handle_base.h"
18
19
20/*
21 *
22 * Structs and defines.
23 *
24 */
25
26struct oxr_session;
27
28/*!
29 * A hand tracker.
30 *
31 * Parent type/handle is @ref oxr_instance
32 *
33 *
34 * @obj{XrHandTrackerEXT}
35 * @extends oxr_handle_base
36 */
38{
39 //! Common structure for things referred to by OpenXR handles.
41
42 //! Owner of this hand tracker.
44
45 //! XRT hand tracker backing this OpenXR handle.
47
48 //! Whether any sources were requested by the application.
50
51 XrHandEXT hand;
52 XrHandJointSetEXT hand_joint_set;
53};
54
55
56/*
57 *
58 * Functions.
59 *
60 */
61
62XrResult
63oxr_hand_tracker_create(struct oxr_logger *log,
64 struct oxr_session *sess,
65 const XrHandTrackerCreateInfoEXT *createInfo,
66 struct xrt_device *override_xdev,
67 struct oxr_hand_tracker **out_hand_tracker);
68
69XrResult
70oxr_hand_tracker_joints(struct oxr_logger *log,
71 struct oxr_hand_tracker *hand_tracker,
72 const XrHandJointsLocateInfoEXT *locateInfo,
73 XrHandJointLocationsEXT *locations);
74
75XrResult
76oxr_hand_tracker_apply_force_feedback(struct oxr_logger *log,
77 struct oxr_hand_tracker *hand_tracker,
78 const XrForceFeedbackCurlApplyLocationsMNDX *locations);
Contains handle-related functions and defines only required in a few locations.
A hand tracker.
Definition oxr_hand_tracking.h:38
struct xrt_hand_tracker * xht
XRT hand tracker backing this OpenXR handle.
Definition oxr_hand_tracking.h:46
bool has_requested_sources
Whether any sources were requested by the application.
Definition oxr_hand_tracking.h:49
struct oxr_session * sess
Owner of this hand tracker.
Definition oxr_hand_tracking.h:43
struct oxr_handle_base handle
Common structure for things referred to by OpenXR handles.
Definition oxr_hand_tracking.h:40
Used to hold diverse child handles and ensure orderly destruction.
Definition oxr_handle_base.h:61
Logger struct that lives on the stack, one for each call client call.
Definition oxr_logger.h:44
Object that client program interact with.
Definition oxr_objects.h:1343
A single HMD or input device.
Definition xrt_device.h:311
A hand tracker that owns device/source selection policy.
Definition xrt_hand_tracker.h:76
Header defining xrt hand tracker.
Include all of the openxr headers in one place.