Documentation
IContactGloveManager
An interface that provides access to the ContactGlove API. ContactGloveManagerWithSteamVR implements this interface.
GetFingerRotationAmplitude
Gets the rotation amplitude of a finger joint.
declaration
float GetFingerRotationAmplitude(HandSides hand, FingerRotationAmplitude_e index)parameters
| name | type | description |
|---|---|---|
| hand | HandSides | Left or right hand |
| index | FingerRotationAmplitude_e | The finger joint |
return
| type | description |
|---|---|
| float | Rotation amplitude (0.0 ~ 1.0) |
GetFingerTransform
Gets the Transform of a finger.
declaration
Transform GetFingerTransform(HandSides hand, FingerRotationAmplitude_e bone)parameters
| name | type | description |
|---|---|---|
| hand | HandSides | Left or right hand |
| index | FingerRotationAmplitude_e | The finger joint |
return
| type | description |
|---|---|
| Transform | The finger's Transform |
SetVibration
Vibrates the glove.
declaration
public void SetVibration(HandSides hand, float amplitude, float frequency, float duration)parameters
| name | type | description |
|---|---|---|
| hand | HandSides | Left or right hand |
| amplitude | float | Vibration amplitude (0.0 ~ 1.0) |
| frequency | float | Vibration frequency (Hz) |
| duration | float | Vibration duration (seconds) |
GetVibration
Gets the glove's vibration strength.
declaration
public VibrationType GetVibration(HandSides hand)parameters
| name | type | description |
|---|---|---|
| hand | HandSides | Left or right hand |
return
| type | description |
|---|---|
| VibrationType | Vibration amplitude and frequency |
SetHaptics
Activates the glove's haptic module.
Note
This function can only be used on models equipped with the haptic module, which are available for corporate sales only.
Standard models only support vibration via SetVibration.
declaration
public void SetHaptics(HandSides hand, ColliderFinger_e section, bool enable)parameters
| name | type | description |
|---|---|---|
| hand | HandSides | Left or right hand |
| section | ColliderFinger_e | The type of finger section |
| enable | bool | Whether to enable or not |
GetControllerInput(Bool)
This function has been removed in v1.1.0 and later.
Gets the bool-type controller input.
declaration
public bool GetControllerInput(HandSides hand, ControllerBoolInputType type)parameters
| name | type | description |
|---|---|---|
| hand | HandSides | Left or right hand |
| type | ControllerBoolInputType | The type of input |
return
| type | description |
|---|---|
| bool | The state of the input |
GetControllerInput (ButtonState)
This function was added in v1.1.0.
Gets the ButtonState-type controller input.
declaration
public ButtonState GetControllerInput(HandSides hand, ControllerButtonType type)parameters
| name | type | description |
|---|---|---|
| hand | HandSides | Left or right hand |
| type | ControllerButtonType | The type of input |
return
| type | description |
|---|---|
| ButtonState | The state of the input |
GetControllerInput (Float)
Gets the float-type controller input.
declaration
public float GetControllerInput(HandSides hand, ControllerFloatInputType type)parameters
| name | type | description |
|---|---|---|
| hand | HandSides | Left or right hand |
| type | ControllerFloatInputType | The type of input |
return
| type | description |
|---|---|
| float | The state of the input |
AddOnControllerInputHandler
Adds a handler to be called when the controller input changes from Off to On.
declaration
public void AddOnControllerInputHandler(HandSides hand, ControllerButtonType type, ControllerInputHandler handler)parameters
| name | type | description |
|---|---|---|
| hand | HandSides | Left or right hand |
| type | ControllerButtonType | The type of input |
| handler | ControllerInputHandler | The handler |
Before v1.1.0
declaration
public void AddOnControllerInputHandler(HandSides hand, ControllerBoolInputType type, ControllerInputHandler handler)parameters
| name | type | description |
|---|---|---|
| hand | HandSides | Left or right hand |
| type | ControllerBoolInputType | The type of input |
| handler | ControllerInputHandler | The handler |
AddOffControllerInputHandler
Adds a handler to be called when the controller input changes from On to Off.
declaration
public void AddOffControllerInputHandler(HandSides hand, ControllerButtonType type, ControllerInputHandler handler)parameters
| name | type | description |
|---|---|---|
| hand | HandSides | Left or right hand |
| type | ControllerButtonType | The type of input |
| handler | ControllerInputHandler | The handler |
Before v1.1.0
declaration
public void AddOffControllerInputHandler(HandSides hand, ControllerBoolInputType type, ControllerInputHandler handler)parameters
| name | type | description |
|---|---|---|
| hand | HandSides | Left or right hand |
| type | ControllerBoolInputType | The type of input |
| handler | ControllerInputHandler | The handler |
HandSides
An enum representing the left or right hand.
declaration
public enum HandSidesfields
| name | type | description |
|---|---|---|
| Left | HandSides | Left hand |
| Right | HandSides | Right hand |
FingerRotationAmplitude_e
An enum representing the rotation amplitude of finger joints.
declaration
public enum FingerRotationAmplitude_efields
| name | type | description |
|---|---|---|
| LittleProximal | FingerRotationAmplitude_e | Little finger proximal joint |
| LittleIntermediate | FingerRotationAmplitude_e | Little finger intermediate joint |
| LittleDistal | FingerRotationAmplitude_e | Little finger distal joint |
| RingProximal | FingerRotationAmplitude_e | Ring finger proximal joint |
| RingIntermediate | FingerRotationAmplitude_e | Ring finger intermediate joint |
| RingDistal | FingerRotationAmplitude_e | Ring finger distal joint |
| MiddleProximal | FingerRotationAmplitude_e | Middle finger proximal joint |
| MiddleIntermediate | FingerRotationAmplitude_e | Middle finger intermediate joint |
| MiddleDistal | FingerRotationAmplitude_e | Middle finger distal joint |
| IndexProximal | FingerRotationAmplitude_e | Index finger proximal joint |
| IndexIntermediate | FingerRotationAmplitude_e | Index finger intermediate joint |
| IndexDistal | FingerRotationAmplitude_e | Index finger distal joint |
| ThumbProximal | FingerRotationAmplitude_e | Thumb proximal joint |
| ThumbIntermediate | FingerRotationAmplitude_e | Thumb intermediate joint |
| ThumbDistal | FingerRotationAmplitude_e | Thumb base |
| ThumbAbduction | FingerRotationAmplitude_e | Thumb base rotation |
ControllerBoolInputType
This enum has been removed in v1.1.0 and later.
An enum representing bool-type controller inputs.
declaration
public enum ControllerBoolInputTypefields
| name | type | description |
|---|---|---|
| A | ControllerBoolInputType | A button |
| B | ControllerBoolInputType | B button |
| Home | ControllerBoolInputType | Home button |
| JoystickButton | ControllerBoolInputType | Joystick button |
| TrackpadTouch | ControllerBoolInputType | Trackpad touch |
ControllerButtonType
This enum was added in v1.1.0.
An enum representing button-type controller inputs.
declaration
public enum ControllerButtonTypefields
| name | type | description |
|---|---|---|
| A | ControllerButtonType | A button |
| B | ControllerButtonType | B button |
| System | ControllerButtonType | System button |
| TriggerButton | ControllerButtonType | Trigger button |
| JoystickButton | ControllerButtonType | Joystick button |
| TrackpadTouch | ControllerButtonType | Trackpad touch |
ButtonState
This enum was added in v1.1.0.
An enum representing the input state for button-type controller inputs.
declaration
public enum ButtonStatefields
| name | type | description |
|---|---|---|
| Idle | ButtonState | Button is not pressed |
| Touched | ButtonState | Button is touched |
| Pressed | ButtonState | Button is pressed |
ControllerFloatInputType
An enum representing float-type controller inputs.
declaration
public enum ControllerFloatInputTypefields
| name | type | description |
|---|---|---|
| JoystickX | ControllerFloatInputType | Joystick X-axis |
| JoystickY | ControllerFloatInputType | Joystick Y-axis |
| Trigger | ControllerFloatInputType | Trigger value |
| GripValue | ControllerFloatInputType | Grip value |
| GripForce | ControllerFloatInputType | Grip force |