C Specification
The xrGetBoundSourcesForAction function is defined as:
XrResult xrGetBoundSourcesForAction(
XrAction action,
uint32_t sourceCapacityInput,
uint32_t* sourceCountOutput,
XrPath* sources);
Parameters
Description
An application can use the xrGetBoundSourcesForAction and
xrGetInputSourceLocalizedName calls to prompt the user which physical inputs
to use in order to perform an action.
A source is the physical control that the action is bound to.
An action may be bound to multiple sources at one time, for example an action
named hold
could be bound to both the X and A buttons.
If an action is unbound, xrGetBoundSourcesForAction will assign 0 to the
value pointed-to by sourceCountOutput
and not modify the array.
Once the semantic paths for the action’s source are obtained, the application can gather additional information about the source. xrGetInputSourceLocalizedName returns a localized human-readable string describing the source, e.g. 'A Button'.
If the parent session of action
is not running, the runtime must return XR_ERROR_SESSION_NOT_RUNNING
.
Document Notes
For more information, see the OpenXR Specification at URL
This page is extracted from the OpenXR Specification. Fixes and changes should be made to the Specification, not directly.
Copyright
Copyright (c) 2014-2019 Khronos Group. This work is licensed under a Creative Commons Attribution 4.0 International License.