Class ColorParameter
A VolumeParameter that holds a Color
value.
Inherited Members
Namespace: UnityEngine.Rendering
Assembly: Unity.RenderPipelines.Core.Runtime.dll
Syntax
[Serializable]
public class ColorParameter : VolumeParameter<Color>, ICloneable, IEquatable<VolumeParameter<Color>>
Constructors
ColorParameter(Color, bool)
Creates a new ColorParameter instance.
Declaration
public ColorParameter(Color value, bool overrideState = false)
Parameters
Type | Name | Description |
---|---|---|
Color | value | The initial value to store in the parameter. |
bool | overrideState | The initial override state for the parameter. |
See Also
ColorParameter(Color, bool, bool, bool, bool)
Creates a new ColorParameter instance.
Declaration
public ColorParameter(Color value, bool hdr, bool showAlpha, bool showEyeDropper, bool overrideState = false)
Parameters
Type | Name | Description |
---|---|---|
Color | value | The initial value to store in the parameter. |
bool | hdr | Specifies whether the color is HDR or not. |
bool | showAlpha | Specifies whether you can edit the alpha channel in the Inspector or not. |
bool | showEyeDropper | Specifies whether the eye dropper is visible in the editor or not. |
bool | overrideState | The initial override state for the parameter. |
See Also
Fields
hdr
Is this color HDR?
Declaration
[NonSerialized]
public bool hdr
Field Value
Type | Description |
---|---|
bool |
See Also
showAlpha
Should the alpha channel be editable in the editor?
Declaration
[NonSerialized]
public bool showAlpha
Field Value
Type | Description |
---|---|
bool |
See Also
showEyeDropper
Should the eye dropper be visible in the editor?
Declaration
[NonSerialized]
public bool showEyeDropper
Field Value
Type | Description |
---|---|
bool |
See Also
Methods
Interp(Color, Color, float)
Interpolates between two Color
values.
Declaration
public override void Interp(Color from, Color to, float t)
Parameters
Type | Name | Description |
---|---|---|
Color | from | The start value. |
Color | to | The end value. |
float | t | The interpolation factor in range [0,1]. |
Overrides
Remarks
For performance reasons, this function interpolates the RGBA channels directly.