Нема описа
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.

UniversalRenderPipelineDebugShaders.cs 2.2KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. using System;
  2. namespace UnityEngine.Rendering.Universal
  3. {
  4. /// <summary>
  5. /// Class containing debug shader resources used in URP.
  6. /// </summary>
  7. [Serializable]
  8. [SupportedOnRenderPipeline(typeof(UniversalRenderPipelineAsset))]
  9. [Categorization.CategoryInfo(Name = "R: Debug Shaders", Order = 1000), HideInInspector]
  10. public class UniversalRenderPipelineDebugShaders : IRenderPipelineResources
  11. {
  12. /// <summary>
  13. /// Version of the Debug Shader resources
  14. /// </summary>
  15. public int version => 0;
  16. bool IRenderPipelineGraphicsSettings.isAvailableInPlayerBuild =>
  17. #if DEVELOPMENT_BUILD || UNITY_EDITOR
  18. true;
  19. #else
  20. false;
  21. #endif
  22. [SerializeField]
  23. [ResourcePath("Shaders/Debug/DebugReplacement.shader")]
  24. Shader m_DebugReplacementPS;
  25. /// <summary>
  26. /// Debug shader used to output interpolated vertex attributes.
  27. /// </summary>
  28. public Shader debugReplacementPS
  29. {
  30. get => m_DebugReplacementPS;
  31. set => this.SetValueAndNotify(ref m_DebugReplacementPS, value, nameof(m_DebugReplacementPS));
  32. }
  33. [SerializeField]
  34. [ResourcePath("Shaders/Debug/HDRDebugView.shader")]
  35. Shader m_HdrDebugViewPS;
  36. /// <summary>
  37. /// Debug shader used to output HDR Chromacity mapping.
  38. /// </summary>
  39. public Shader hdrDebugViewPS
  40. {
  41. get => m_HdrDebugViewPS;
  42. set => this.SetValueAndNotify(ref m_HdrDebugViewPS, value, nameof(m_HdrDebugViewPS));
  43. }
  44. [SerializeField]
  45. [ResourcePath("Shaders/Debug/ProbeVolumeSamplingDebugPositionNormal.compute")]
  46. ComputeShader m_ProbeVolumeSamplingDebugComputeShader;
  47. /// <summary>
  48. /// Debug shader used to output world position and world normal for the pixel under the cursor.
  49. /// </summary>
  50. public ComputeShader probeVolumeSamplingDebugComputeShader
  51. {
  52. get => m_ProbeVolumeSamplingDebugComputeShader;
  53. set => this.SetValueAndNotify(ref m_ProbeVolumeSamplingDebugComputeShader, value, nameof(m_ProbeVolumeSamplingDebugComputeShader));
  54. }
  55. }
  56. }