HairResolvePPLL.pass 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152
  1. {
  2. "Type": "JsonSerialization",
  3. "Version": 1,
  4. "ClassName": "PassAsset",
  5. "ClassData": {
  6. "PassTemplate": {
  7. "Name": "HairPPLLResolvePassTemplate",
  8. "PassClass": "HairPPLLResolvePass",
  9. "Slots": [
  10. //------ General Input/Output resources and Render Target ------
  11. {
  12. "Name": "RenderTargetInputOutput",
  13. "SlotType": "InputOutput",
  14. "ScopeAttachmentUsage": "RenderTarget",
  15. "LoadStoreAction": {
  16. "LoadAction": "Load",
  17. "StoreAction": "Store"
  18. }
  19. },
  20. { // Will be used to get the background color for the hair blending
  21. "Name": "RenderTargetCopy",
  22. "SlotType": "Input",
  23. "ScopeAttachmentUsage": "Shader",
  24. "ShaderInputName": "m_frameBuffer"
  25. },
  26. { // Used to get the transform from screen space to world space.
  27. "Name": "DepthLinear",
  28. "SlotType": "Input",
  29. "ShaderInputName": "m_linearDepth",
  30. "ScopeAttachmentUsage": "Shader"
  31. },
  32. { // The depth buffer will be used to write the closest hair fragment depth
  33. "Name": "Depth",
  34. "SlotType": "InputOutput",
  35. "ScopeAttachmentUsage": "DepthStencil",
  36. "LoadStoreAction": {
  37. "LoadAction": "Load",
  38. "StoreAction": "Store"
  39. }
  40. },
  41. //------------- Shadowing Resources -------------
  42. {
  43. "Name": "DirectionalShadowmap",
  44. "ShaderInputName": "m_directionalLightShadowmap",
  45. "SlotType": "Input",
  46. "ScopeAttachmentUsage": "Shader",
  47. "ImageViewDesc": {
  48. "IsArray": 1
  49. }
  50. },
  51. {
  52. "Name": "DirectionalESM",
  53. "ShaderInputName": "m_directionalLightExponentialShadowmap",
  54. "SlotType": "Input",
  55. "ScopeAttachmentUsage": "Shader",
  56. "ImageViewDesc": {
  57. "IsArray": 1
  58. }
  59. },
  60. {
  61. "Name": "ProjectedShadowmap",
  62. "ShaderInputName": "m_projectedShadowmaps",
  63. "SlotType": "Input",
  64. "ScopeAttachmentUsage": "Shader",
  65. "ImageViewDesc": {
  66. "IsArray": 1
  67. }
  68. },
  69. {
  70. "Name": "ProjectedESM",
  71. "ShaderInputName": "m_projectedExponentialShadowmap",
  72. "SlotType": "Input",
  73. "ScopeAttachmentUsage": "Shader",
  74. "ImageViewDesc": {
  75. "IsArray": 1
  76. }
  77. },
  78. //------------- Lighting Resources -------------
  79. {
  80. "Name": "BRDFTextureInput",
  81. "ShaderInputName": "m_brdfMap",
  82. "SlotType": "Input",
  83. "ScopeAttachmentUsage": "Shader"
  84. },
  85. {
  86. "Name": "TileLightData",
  87. "SlotType": "Input",
  88. "ShaderInputName": "m_tileLightData",
  89. "ScopeAttachmentUsage": "Shader"
  90. },
  91. {
  92. "Name": "LightListRemapped",
  93. "SlotType": "Input",
  94. "ShaderInputName": "m_lightListRemapped",
  95. "ScopeAttachmentUsage": "Shader"
  96. },
  97. //---------- PPLL Resources -----------
  98. {
  99. "Name": "PerPixelListHead",
  100. "ShaderInputName": "m_fragmentListHead",
  101. "SlotType": "Input", // Read only - the reset is done before the fill pass
  102. "ScopeAttachmentUsage": "Shader",
  103. "LoadStoreAction": {
  104. "LoadAction": "Load",
  105. "StoreAction": "DontCare"
  106. }
  107. },
  108. {
  109. "Name": "PerPixelLinkedList",
  110. "ShaderInputName": "m_linkedListNodes",
  111. "SlotType": "Input",
  112. "ScopeAttachmentUsage": "Shader",
  113. "LoadStoreAction": {
  114. "LoadAction": "Load",
  115. "StoreAction": "DontCare"
  116. }
  117. }
  118. ],
  119. "ImageAttachments": [
  120. {
  121. "Name": "BRDFTexture",
  122. "Lifetime": "Imported",
  123. "AssetRef": {
  124. "FilePath": "Textures/BRDFTexture.attimage"
  125. }
  126. }
  127. ],
  128. "Connections": [
  129. {
  130. "LocalSlot": "BRDFTextureInput",
  131. "AttachmentRef": {
  132. "Pass": "This",
  133. "Attachment": "BRDFTexture"
  134. }
  135. }
  136. ],
  137. "PassData": {
  138. "$type": "FullscreenTrianglePassData",
  139. "BindViewSrg": true,
  140. "ShaderAsset": {
  141. // Looking for it in the Shaders directory relative to the Assets directory
  142. "FilePath": "Shaders/HairRenderingResolvePPLL.shader"
  143. }
  144. }
  145. }
  146. }
  147. }