Class VignetteParameters
Represents the parameters to control the tunneling vignette material and customize its effects.
Inherited Members
Namespace: UnityEngine.XR.Interaction.Toolkit
Syntax
[Serializable]
public sealed class VignetteParameters
Remarks
Properties
apertureSize
The diameter of the inner transparent circle of the tunneling vignette.
Declaration
public float apertureSize { get; set; }
Property Value
Type | Description |
---|---|
Single |
Remarks
When multiple providers trigger the tunneling vignette animation, the one with the smallest aperture size
will be used. The range of this value is [0, 1]
, where 1
represents having no vignette effect.
apertureVerticalPosition
The vertical position offset of the vignette. Changing this value will change the local y-position of the GameObject that this script is attached to.
Declaration
public float apertureVerticalPosition { get; set; }
Property Value
Type | Description |
---|---|
Single |
easeInTime
The transition time (in seconds) of easing in the tunneling vignette. Set this to a non-zero value to reduce the potential distraction from instantaneously changing the user's field of view when beginning the vignette.
Declaration
public float easeInTime { get; set; }
Property Value
Type | Description |
---|---|
Single |
easeInTimeLock
Persists the easing-in transition until it is complete. Enable this option if you want the easing-in transition to persist until it is complete. This can be useful for instant changes, such as snap turn and teleportation, to trigger the full tunneling effect without easing out the vignette partway through the easing in process.
Declaration
public bool easeInTimeLock { get; set; }
Property Value
Type | Description |
---|---|
Boolean |
easeOutDelayTime
The delay time (in seconds) before starting to ease out of the tunneling vignette.
Declaration
public float easeOutDelayTime { get; set; }
Property Value
Type | Description |
---|---|
Single |
easeOutTime
The transition time (in seconds) of easing out the tunneling vignette. Set this to a non-zero value to reduce the potential distraction from instantaneously changing the user's field of view when ending the vignette.
Declaration
public float easeOutTime { get; set; }
Property Value
Type | Description |
---|---|
Single |
featheringEffect
The degree of smoothly blending the edges between the aperture and full visual cut-off. Set this to a non-zero value to add a gradual transition from the transparent aperture to the black vignette edges.
Declaration
public float featheringEffect { get; set; }
Property Value
Type | Description |
---|---|
Single |
vignetteColor
The primary color of the visual cut-off area of the vignette.
Declaration
public Color vignetteColor { get; set; }
Property Value
Type | Description |
---|---|
Color |
vignetteColorBlend
The optional color to add color blending to the visual cut-off area of the vignette.
Declaration
public Color vignetteColorBlend { get; set; }
Property Value
Type | Description |
---|---|
Color |
Methods
CopyFrom(VignetteParameters)
Copies the parameter values from the given VignetteParameters.
Declaration
public void CopyFrom(VignetteParameters parameters)
Parameters
Type | Name | Description |
---|---|---|
VignetteParameters | parameters | The VignetteParameters to copy values from. |
Exceptions
Type | Condition |
---|---|
ArgumentNullException | Throws when |