Class Vignette
This class holds settings for the Vignette effect.
Inherited Members
Namespace: UnityEngine.Rendering.PostProcessing
Syntax
[Serializable]
public sealed class Vignette : PostProcessEffectSettings
Fields
center
Sets the vignette center point (screen center is [0.5,0.5]
).
Declaration
[Tooltip("Sets the vignette center point (screen center is [0.5, 0.5]).")]
public Vector2Parameter center
Field Value
Type | Description |
---|---|
Vector2Parameter |
color
The color to use to tint the vignette.
Declaration
[Tooltip("Vignette color.")]
public ColorParameter color
Field Value
Type | Description |
---|---|
ColorParameter |
intensity
The amount of vignetting on screen.
Declaration
[Range(0F, 1F)]
[Tooltip("Amount of vignetting on screen.")]
public FloatParameter intensity
Field Value
Type | Description |
---|---|
FloatParameter |
mask
A black and white mask to use as a vignette.
Declaration
[Tooltip("A black and white mask to use as a vignette.")]
public TextureParameter mask
Field Value
Type | Description |
---|---|
TextureParameter |
mode
Use the "Classic" mode for parametric controls. Use the "Masked" mode to use your own texture mask.
Declaration
[Tooltip("Use the \"Classic\" mode for parametric controls. Use the \"Masked\" mode to use your own texture mask.")]
public VignetteModeParameter mode
Field Value
Type | Description |
---|---|
VignetteModeParameter |
opacity
Mask opacity.
Declaration
[Range(0F, 1F)]
[Tooltip("Mask opacity.")]
public FloatParameter opacity
Field Value
Type | Description |
---|---|
FloatParameter |
rounded
Should the vignette be perfectly round or be dependent on the current aspect ratio?
Declaration
[Tooltip("Set to true to mark the vignette to be perfectly round. False will make its shape dependent on the current aspect ratio.")]
public BoolParameter rounded
Field Value
Type | Description |
---|---|
BoolParameter |
roundness
Lower values will make a square-ish vignette.
Declaration
[Range(0F, 1F)]
[Tooltip("Lower values will make a square-ish vignette.")]
public FloatParameter roundness
Field Value
Type | Description |
---|---|
FloatParameter |
smoothness
The smoothness of the vignette borders.
Declaration
[Range(0.01F, 1F)]
[Tooltip("Smoothness of the vignette borders.")]
public FloatParameter smoothness
Field Value
Type | Description |
---|---|
FloatParameter |
Methods
IsEnabledAndSupported(PostProcessRenderContext)
Returns true
if the effect is currently enabled and supported.
Declaration
public override bool IsEnabledAndSupported(PostProcessRenderContext context)
Parameters
Type | Name | Description |
---|---|---|
PostProcessRenderContext | context | The current post-processing render context |
Returns
Type | Description |
---|---|
Boolean |
|