You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

43 lines
1.1 KiB

  1. using System;
  2. namespace UnityEngine.PostProcessing
  3. {
  4. [Serializable]
  5. public class ChromaticAberrationModel : PostProcessingModel
  6. {
  7. [Serializable]
  8. public struct Settings
  9. {
  10. [Tooltip("Shift the hue of chromatic aberrations.")]
  11. public Texture2D spectralTexture;
  12. [Range(0f, 1f), Tooltip("Amount of tangential distortion.")]
  13. public float intensity;
  14. public static Settings defaultSettings
  15. {
  16. get
  17. {
  18. return new Settings
  19. {
  20. spectralTexture = null,
  21. intensity = 0.1f
  22. };
  23. }
  24. }
  25. }
  26. [SerializeField]
  27. Settings m_Settings = Settings.defaultSettings;
  28. public Settings settings
  29. {
  30. get { return m_Settings; }
  31. set { m_Settings = value; }
  32. }
  33. public override void Reset()
  34. {
  35. m_Settings = Settings.defaultSettings;
  36. }
  37. }
  38. }