UxrHapticClip Class
Describes a haptic clip. It is possible to specify an audio clip whose wave will be used as a primary source for the vibration, but also a secondary clip type that will be used if the device doesn’t support audio clips as haptic feedback. If no audio clip is specified, the fallback clip type will always be used.
Inheritance Hierarchy
System.Object
UltimateXR.Haptics.UxrHapticClip
Namespace: UltimateXR.Haptics
Assembly: UltimateXR (in UltimateXR.dll) Version: 0.0.0.0
Syntax
C#
[SerializableAttribute]
public class UxrHapticClip
The UxrHapticClip type exposes the following members.
Constructors
Name | Description | |
---|---|---|
UxrHapticClip | Public constructor. |
Properties
Name | Description | |
---|---|---|
Clip | Gets or sets the primary AudioClip to use as source for vibration. If the device does not support audio clips as sources or this value is null, FallbackClipType will be used. | |
ClipAmplitude | Gets or sets the amplitude to play Clip. Valid range is [0.0, 1.0]. | |
FallbackAmplitude | Gets or sets the amplitude to play the fallback clip (1.0f = use default). | |
FallbackClipType | Gets or sets the fallback clip: A value from a pre-defined set of procedurally generated haptic feedback clips. It will be used if the current device can’t play AudioClip as haptics or Clip is not assigned. | |
FallbackDurationSeconds | Gets or sets the duration in seconds of the fallback clip (negative = use predefined). | |
HapticMode | Gets or sets whether to replace or mix the clip with any current haptic feedback being played. |
Extension Methods
Name | Description | |
---|---|---|
ThrowIfNull | Throws an exception if the object is null. (Defined by ObjectExt.) |