diff options
author | Shashank Shekhar <secondary.cmdr2@gmail.com> | 2022-05-07 05:39:17 +0300 |
---|---|---|
committer | Peter Kim <pk15950@gmail.com> | 2022-05-07 05:39:26 +0300 |
commit | 23be3294ff50b9a1f9eebfbde71b44252520c51f (patch) | |
tree | 1584ae44520814c4340344a53d7348b133f1db62 /intern | |
parent | 98a04ed4524234b1840dc039c2f356db5ac57f26 (diff) |
XR: Expose the OpenXR user paths in the event data for XR events
The use-case is to allow an event handler (in C or a plugin) to
distinguish which hand produced the XR event.
The alternative is to register separate actions for each hand (e.g.
"trigger_left" and "trigger_right"), and duplicate the device bindings
(Oculus, HTC Vive, etc) for each action. Other than the problem of code
duplication, this isn't conceptually efficient since "trigger_left" and
"trigger_right" both represent the same event "trigger", and the
identity of the hand that produced that event is just a property of
that event.
Adds two string fields to the XrEventData called user_path and
user_path_other. The user_path_other field will be populated if the
event is a bimanual one (i.e. two-handed). This follows the pattern
used by the rest of the XrEventData struct for bimanual events (e.g.
state, state_other).
Reviewed By: muxed-reality
Diffstat (limited to 'intern')
0 files changed, 0 insertions, 0 deletions