Version: Unity 6 Preview (6000.0)
LanguageEnglish
  • C#

InputDevice.characteristics

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

public XR.InputDeviceCharacteristics characteristics;

Description

Read Only. A bitmask of enumerated flags describing the characteristics of this InputDevice.

Use Characteristics to determine whether an InputDevice has specific features or capabilities. For example, if the set of InputDeviceCharacteristics includes both InputDeviceCharacteristics.HeldInHand and InputDeviceCharacteristics.Left, then the device provides tracking data for the left hand.

Characteristics is a bitmask. Use the bitwise operators to test for specific flags. For example, to determine whether an InputDevice has a camera, use the conditional:

(inputDevice.characteristics & InputDeviceCharacteristics.Camera) == InputDeviceCharacteristics.Camera.