using System; namespace UnityEngine.Rendering.HighDefinition { /// /// A volume component that holds settings for the Lift, Gamma, Gain effect. /// [Serializable, VolumeComponentMenu("Post-processing/Lift, Gamma, Gain")] [HelpURL(Documentation.baseURL + Documentation.version + Documentation.subURL + "Post-Processing-Lift-Gamma-Gain" + Documentation.endURL)] public sealed class LiftGammaGain : VolumeComponent, IPostProcessComponent { /// /// Controls the dark tones of the render. /// [Tooltip("Controls the dark tones of the render.")] public Vector4Parameter lift = new Vector4Parameter(new Vector4(1f, 1f, 1f, 0f)); /// /// Controls the mid-range tones of the render with a power function. /// [Tooltip("Controls the mid-range tones of the render with a power function.")] public Vector4Parameter gamma = new Vector4Parameter(new Vector4(1f, 1f, 1f, 0f)); /// /// Controls the highlights of the render. /// [Tooltip("Controls the highlights of the render.")] public Vector4Parameter gain = new Vector4Parameter(new Vector4(1f, 1f, 1f, 0f)); /// /// Tells if the effect needs to be rendered or not. /// /// true if the effect should be rendered, false otherwise. public bool IsActive() { var defaultState = new Vector4(1f, 1f, 1f, 0f); return lift != defaultState || gamma != defaultState || gain != defaultState; } LiftGammaGain() => displayName = "Lift, Gamma, Gain"; } }