25 lines
914 B
C#
25 lines
914 B
C#
using System;
|
|
using UnityEngine;
|
|
using UnityEngine.Rendering;
|
|
using UnityEngine.Rendering.Universal;
|
|
|
|
[Serializable]
|
|
[VolumeComponentMenu("Post-processing/Bansonic/Global Afterimage")]
|
|
[SupportedOnRenderPipeline(typeof(UniversalRenderPipelineAsset))]
|
|
public sealed class GlobalAfterimageVolume : VolumeComponent, IPostProcessComponent
|
|
{
|
|
[Tooltip("Base afterimage opacity from the volume profile.")]
|
|
public ClampedFloatParameter opacity = new ClampedFloatParameter(0f, 0f, 1f);
|
|
|
|
[Tooltip("Scale multiplier of the copied image.")]
|
|
public ClampedFloatParameter scale = new ClampedFloatParameter(1.05f, 1f, 2f);
|
|
|
|
[Tooltip("Whether this effect should run in SceneView cameras.")]
|
|
public BoolParameter affectSceneView = new BoolParameter(false);
|
|
|
|
public bool IsActive() => opacity.value > 0.0001f;
|
|
|
|
[Obsolete("Unused #from(2023.1)", false)]
|
|
public bool IsTileCompatible() => false;
|
|
}
|