![]() ![]() You define which Ids map to which devices, with the only constraint being that you cannot use the same Id for two devices connected at the same time. Consider these identifiers to be unique IDs that both Unity and a provider share to reference a specific device. UnityXRInternalInputDeviceIdĪ UnityXRInternalInputDeviceId identifies all devices. For a list of common usages available to all, see the Feature usages section below. You can create your own usages, but you need to use as many Unity-developed usages as possible, because they enable cross-platform utility for developers. Usage can also inform the developer that a one-dimensional axis feature is reporting battery life. For example, the feature can be a 2D axis, but the usage tells the developer it’s a touchpad. It identifies how the developer should use the feature. These are the currently supported data types that can be on an input device: UnityXRInputFeatureTypeĪ usage provides context to a feature. ![]() They are grouped into various types of data, identified by UnityXRInputFeatureType. That can be a button, or a positional tracking element, or battery life. Input Features are anything you can get sensor or user modified data from. A device has a fixed number of features that you cannot change while the device is connected. This can be something concrete, like a gamepad or headset, or it can represent abstract objects such as a detected hand skeleton. A device is a container of input features referenced by a unique ID that you choose. Most Input Subsystem APIs rely on devices. This guide uses the following terms: Devices Report your device layouts to the new input system. ![]() Respond to all relevant events and queries. ![]() Update the device’s state whenever Unity requests this.Fill in all connected device’s definition information.Report your device connections and disconnections.To create a basic, working XR Input provider, follow these steps: Unity reports your input information to InputDevices and the Input System depending on the type of information available. This is the core subsystem for getting user-controlled data into the various input endpoints of the Unity engine. The XR SDK Input Subsystem is an interface for reporting button, axis, and tracking device information. ![]()
0 Comments
Leave a Reply. |