@babylonjs/core 7.52.1 → 7.52.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (247) hide show
  1. package/AudioV2/abstractAudio/abstractAudioBus.d.ts +11 -0
  2. package/AudioV2/abstractAudio/abstractAudioBus.js +10 -0
  3. package/AudioV2/abstractAudio/abstractAudioBus.js.map +1 -1
  4. package/AudioV2/abstractAudio/abstractSound.d.ts +11 -5
  5. package/AudioV2/abstractAudio/abstractSound.js +11 -5
  6. package/AudioV2/abstractAudio/abstractSound.js.map +1 -1
  7. package/AudioV2/abstractAudio/audioBus.d.ts +5 -6
  8. package/AudioV2/abstractAudio/audioBus.js +1 -5
  9. package/AudioV2/abstractAudio/audioBus.js.map +1 -1
  10. package/AudioV2/abstractAudio/audioEngineV2.d.ts +1 -2
  11. package/AudioV2/abstractAudio/audioEngineV2.js +1 -5
  12. package/AudioV2/abstractAudio/audioEngineV2.js.map +1 -1
  13. package/AudioV2/abstractAudio/components/spatialAudioAttacherComponent.d.ts +43 -0
  14. package/AudioV2/abstractAudio/components/spatialAudioAttacherComponent.js +71 -0
  15. package/AudioV2/abstractAudio/components/spatialAudioAttacherComponent.js.map +1 -0
  16. package/AudioV2/abstractAudio/mainAudioBus.d.ts +2 -2
  17. package/AudioV2/abstractAudio/mainAudioBus.js.map +1 -1
  18. package/AudioV2/abstractAudio/staticSound.d.ts +6 -6
  19. package/AudioV2/abstractAudio/staticSound.js +5 -5
  20. package/AudioV2/abstractAudio/staticSound.js.map +1 -1
  21. package/AudioV2/abstractAudio/streamingSound.d.ts +2 -2
  22. package/AudioV2/abstractAudio/streamingSound.js +3 -3
  23. package/AudioV2/abstractAudio/streamingSound.js.map +1 -1
  24. package/AudioV2/abstractAudio/subNodes/abstractAudioSubGraph.d.ts +30 -6
  25. package/AudioV2/abstractAudio/subNodes/abstractAudioSubGraph.js +44 -21
  26. package/AudioV2/abstractAudio/subNodes/abstractAudioSubGraph.js.map +1 -1
  27. package/AudioV2/abstractAudio/subNodes/audioAnalyzerSubNode.d.ts +24 -0
  28. package/AudioV2/abstractAudio/subNodes/audioAnalyzerSubNode.js +30 -0
  29. package/AudioV2/abstractAudio/subNodes/audioAnalyzerSubNode.js.map +1 -0
  30. package/AudioV2/abstractAudio/subNodes/audioSubNode.d.ts +1 -0
  31. package/AudioV2/abstractAudio/subNodes/audioSubNode.js +1 -0
  32. package/AudioV2/abstractAudio/subNodes/audioSubNode.js.map +1 -1
  33. package/AudioV2/abstractAudio/subNodes/spatialAudioSubNode.d.ts +15 -0
  34. package/AudioV2/abstractAudio/subNodes/spatialAudioSubNode.js +38 -3
  35. package/AudioV2/abstractAudio/subNodes/spatialAudioSubNode.js.map +1 -1
  36. package/AudioV2/abstractAudio/subNodes/stereoAudioSubNode.js.map +1 -1
  37. package/AudioV2/abstractAudio/subProperties/abstractAudioAnalyzer.d.ts +86 -0
  38. package/AudioV2/abstractAudio/subProperties/abstractAudioAnalyzer.js +29 -0
  39. package/AudioV2/abstractAudio/subProperties/abstractAudioAnalyzer.js.map +1 -0
  40. package/AudioV2/abstractAudio/subProperties/abstractSpatialAudio.d.ts +29 -8
  41. package/AudioV2/abstractAudio/subProperties/abstractSpatialAudio.js +1 -0
  42. package/AudioV2/abstractAudio/subProperties/abstractSpatialAudio.js.map +1 -1
  43. package/AudioV2/abstractAudio/subProperties/abstractSpatialAudioListener.d.ts +28 -1
  44. package/AudioV2/abstractAudio/subProperties/abstractSpatialAudioListener.js +5 -1
  45. package/AudioV2/abstractAudio/subProperties/abstractSpatialAudioListener.js.map +1 -1
  46. package/AudioV2/abstractAudio/subProperties/audioAnalyzer.d.ts +35 -0
  47. package/AudioV2/abstractAudio/subProperties/audioAnalyzer.js +96 -0
  48. package/AudioV2/abstractAudio/subProperties/audioAnalyzer.js.map +1 -0
  49. package/AudioV2/abstractAudio/subProperties/index.d.ts +1 -0
  50. package/AudioV2/abstractAudio/subProperties/index.js +1 -0
  51. package/AudioV2/abstractAudio/subProperties/index.js.map +1 -1
  52. package/AudioV2/abstractAudio/subProperties/spatialAudio.d.ts +16 -1
  53. package/AudioV2/abstractAudio/subProperties/spatialAudio.js +48 -14
  54. package/AudioV2/abstractAudio/subProperties/spatialAudio.js.map +1 -1
  55. package/AudioV2/abstractAudio/subProperties/spatialAudioListener.d.ts +21 -0
  56. package/AudioV2/abstractAudio/subProperties/spatialAudioListener.js +39 -4
  57. package/AudioV2/abstractAudio/subProperties/spatialAudioListener.js.map +1 -1
  58. package/AudioV2/index.d.ts +1 -0
  59. package/AudioV2/index.js +1 -0
  60. package/AudioV2/index.js.map +1 -1
  61. package/AudioV2/spatialAudioAttachmentType.d.ts +5 -0
  62. package/AudioV2/spatialAudioAttachmentType.js +7 -0
  63. package/AudioV2/spatialAudioAttachmentType.js.map +1 -0
  64. package/AudioV2/webAudio/components/spatialWebAudioUpdaterComponent.d.ts +13 -0
  65. package/AudioV2/webAudio/components/spatialWebAudioUpdaterComponent.js +38 -0
  66. package/AudioV2/webAudio/components/spatialWebAudioUpdaterComponent.js.map +1 -0
  67. package/AudioV2/webAudio/subNodes/spatialWebAudioSubNode.d.ts +13 -14
  68. package/AudioV2/webAudio/subNodes/spatialWebAudioSubNode.js +39 -39
  69. package/AudioV2/webAudio/subNodes/spatialWebAudioSubNode.js.map +1 -1
  70. package/AudioV2/webAudio/subNodes/webAudioAnalyzerSubNode.d.ts +37 -0
  71. package/AudioV2/webAudio/subNodes/webAudioAnalyzerSubNode.js +85 -0
  72. package/AudioV2/webAudio/subNodes/webAudioAnalyzerSubNode.js.map +1 -0
  73. package/AudioV2/webAudio/subNodes/webAudioBaseSubGraph.d.ts +5 -3
  74. package/AudioV2/webAudio/subNodes/webAudioBaseSubGraph.js +25 -2
  75. package/AudioV2/webAudio/subNodes/webAudioBaseSubGraph.js.map +1 -1
  76. package/AudioV2/webAudio/subNodes/webAudioBusAndSoundSubGraph.d.ts +2 -1
  77. package/AudioV2/webAudio/subNodes/webAudioBusAndSoundSubGraph.js +32 -17
  78. package/AudioV2/webAudio/subNodes/webAudioBusAndSoundSubGraph.js.map +1 -1
  79. package/AudioV2/webAudio/subProperties/spatialWebAudio.d.ts +6 -2
  80. package/AudioV2/webAudio/subProperties/spatialWebAudio.js +13 -15
  81. package/AudioV2/webAudio/subProperties/spatialWebAudio.js.map +1 -1
  82. package/AudioV2/webAudio/subProperties/spatialWebAudioListener.d.ts +1 -1
  83. package/AudioV2/webAudio/subProperties/spatialWebAudioListener.js +41 -56
  84. package/AudioV2/webAudio/subProperties/spatialWebAudioListener.js.map +1 -1
  85. package/AudioV2/webAudio/webAudioBus.d.ts +3 -0
  86. package/AudioV2/webAudio/webAudioBus.js +23 -2
  87. package/AudioV2/webAudio/webAudioBus.js.map +1 -1
  88. package/AudioV2/webAudio/webAudioEngine.d.ts +3 -1
  89. package/AudioV2/webAudio/webAudioEngine.js +11 -3
  90. package/AudioV2/webAudio/webAudioEngine.js.map +1 -1
  91. package/AudioV2/webAudio/webAudioStaticSound.d.ts +3 -0
  92. package/AudioV2/webAudio/webAudioStaticSound.js +23 -2
  93. package/AudioV2/webAudio/webAudioStaticSound.js.map +1 -1
  94. package/AudioV2/webAudio/webAudioStreamingSound.d.ts +3 -0
  95. package/AudioV2/webAudio/webAudioStreamingSound.js +23 -2
  96. package/AudioV2/webAudio/webAudioStreamingSound.js.map +1 -1
  97. package/Engines/WebGPU/webgpuTextureManager.d.ts +0 -1
  98. package/Engines/WebGPU/webgpuTextureManager.js +2 -57
  99. package/Engines/WebGPU/webgpuTextureManager.js.map +1 -1
  100. package/Engines/abstractEngine.d.ts +6 -0
  101. package/Engines/abstractEngine.js +3 -3
  102. package/Engines/abstractEngine.js.map +1 -1
  103. package/Engines/engine.common.js +4 -0
  104. package/Engines/engine.common.js.map +1 -1
  105. package/Engines/nativeEngine.d.ts +1 -0
  106. package/Engines/nativeEngine.js +3 -0
  107. package/Engines/nativeEngine.js.map +1 -1
  108. package/Engines/nullEngine.d.ts +1 -0
  109. package/Engines/nullEngine.js +1 -0
  110. package/Engines/nullEngine.js.map +1 -1
  111. package/Engines/thinEngine.d.ts +1 -0
  112. package/Engines/thinEngine.js +7 -4
  113. package/Engines/thinEngine.js.map +1 -1
  114. package/Engines/webgpuEngine.d.ts +2 -1
  115. package/Engines/webgpuEngine.js +12 -9
  116. package/Engines/webgpuEngine.js.map +1 -1
  117. package/FlowGraph/Blocks/Data/flowGraphDataSwitchBlock.d.ts +48 -0
  118. package/FlowGraph/Blocks/Data/flowGraphDataSwitchBlock.js +54 -0
  119. package/FlowGraph/Blocks/Data/flowGraphDataSwitchBlock.js.map +1 -0
  120. package/FlowGraph/Blocks/Data/index.d.ts +1 -0
  121. package/FlowGraph/Blocks/Data/index.js +1 -0
  122. package/FlowGraph/Blocks/Data/index.js.map +1 -1
  123. package/FlowGraph/Blocks/Execution/Animation/flowGraphPlayAnimationBlock.d.ts +1 -0
  124. package/FlowGraph/Blocks/Execution/Animation/flowGraphPlayAnimationBlock.js +19 -13
  125. package/FlowGraph/Blocks/Execution/Animation/flowGraphPlayAnimationBlock.js.map +1 -1
  126. package/FlowGraph/Blocks/Execution/Animation/flowGraphStopAnimationBlock.js +3 -5
  127. package/FlowGraph/Blocks/Execution/Animation/flowGraphStopAnimationBlock.js.map +1 -1
  128. package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphCancelDelayBlock.js +1 -1
  129. package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphCancelDelayBlock.js.map +1 -1
  130. package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphSetDelayBlock.js +2 -4
  131. package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphSetDelayBlock.js.map +1 -1
  132. package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphThrottleBlock.js +1 -1
  133. package/FlowGraph/Blocks/Execution/ControlFlow/flowGraphThrottleBlock.js.map +1 -1
  134. package/FlowGraph/Blocks/Execution/flowGraphSetPropertyBlock.js +1 -2
  135. package/FlowGraph/Blocks/Execution/flowGraphSetPropertyBlock.js.map +1 -1
  136. package/FlowGraph/Blocks/flowGraphBlockFactory.js +2 -0
  137. package/FlowGraph/Blocks/flowGraphBlockFactory.js.map +1 -1
  138. package/FlowGraph/Blocks/flowGraphBlockNames.d.ts +2 -1
  139. package/FlowGraph/Blocks/flowGraphBlockNames.js +1 -0
  140. package/FlowGraph/Blocks/flowGraphBlockNames.js.map +1 -1
  141. package/FlowGraph/CustomTypes/flowGraphInteger.d.ts +1 -0
  142. package/FlowGraph/CustomTypes/flowGraphInteger.js +3 -0
  143. package/FlowGraph/CustomTypes/flowGraphInteger.js.map +1 -1
  144. package/FlowGraph/CustomTypes/flowGraphMatrix.d.ts +2 -0
  145. package/FlowGraph/CustomTypes/flowGraphMatrix.js +6 -0
  146. package/FlowGraph/CustomTypes/flowGraphMatrix.js.map +1 -1
  147. package/FlowGraph/flowGraphExecutionBlock.d.ts +1 -0
  148. package/FlowGraph/flowGraphExecutionBlock.js +4 -0
  149. package/FlowGraph/flowGraphExecutionBlock.js.map +1 -1
  150. package/FlowGraph/utils.d.ts +2 -1
  151. package/FlowGraph/utils.js +7 -2
  152. package/FlowGraph/utils.js.map +1 -1
  153. package/FrameGraph/Node/Blocks/PostProcesses/bloomPostProcessBlock.js +2 -2
  154. package/FrameGraph/Node/Blocks/PostProcesses/bloomPostProcessBlock.js.map +1 -1
  155. package/FrameGraph/Node/Blocks/PostProcesses/depthOfFieldPostProcessBlock.js +2 -2
  156. package/FrameGraph/Node/Blocks/PostProcesses/depthOfFieldPostProcessBlock.js.map +1 -1
  157. package/FrameGraph/Node/Blocks/PostProcesses/ssrPostProcessBlock.d.ts +126 -0
  158. package/FrameGraph/Node/Blocks/PostProcesses/ssrPostProcessBlock.js +497 -0
  159. package/FrameGraph/Node/Blocks/PostProcesses/ssrPostProcessBlock.js.map +1 -0
  160. package/FrameGraph/Node/Blocks/Rendering/geometryRendererBlock.d.ts +6 -0
  161. package/FrameGraph/Node/Blocks/Rendering/geometryRendererBlock.js +30 -4
  162. package/FrameGraph/Node/Blocks/Rendering/geometryRendererBlock.js.map +1 -1
  163. package/FrameGraph/Node/Blocks/index.d.ts +1 -0
  164. package/FrameGraph/Node/Blocks/index.js +1 -0
  165. package/FrameGraph/Node/Blocks/index.js.map +1 -1
  166. package/FrameGraph/Node/nodeRenderGraph.js +1 -1
  167. package/FrameGraph/Node/nodeRenderGraph.js.map +1 -1
  168. package/FrameGraph/Tasks/PostProcesses/bloomTask.d.ts +2 -3
  169. package/FrameGraph/Tasks/PostProcesses/bloomTask.js +3 -4
  170. package/FrameGraph/Tasks/PostProcesses/bloomTask.js.map +1 -1
  171. package/FrameGraph/Tasks/PostProcesses/blurTask.js +2 -2
  172. package/FrameGraph/Tasks/PostProcesses/blurTask.js.map +1 -1
  173. package/FrameGraph/Tasks/PostProcesses/depthOfFieldTask.d.ts +2 -3
  174. package/FrameGraph/Tasks/PostProcesses/depthOfFieldTask.js +4 -5
  175. package/FrameGraph/Tasks/PostProcesses/depthOfFieldTask.js.map +1 -1
  176. package/FrameGraph/Tasks/PostProcesses/postProcessTask.d.ts +6 -0
  177. package/FrameGraph/Tasks/PostProcesses/postProcessTask.js +14 -0
  178. package/FrameGraph/Tasks/PostProcesses/postProcessTask.js.map +1 -1
  179. package/FrameGraph/Tasks/PostProcesses/ssrBlurTask.d.ts +11 -0
  180. package/FrameGraph/Tasks/PostProcesses/ssrBlurTask.js +18 -0
  181. package/FrameGraph/Tasks/PostProcesses/ssrBlurTask.js.map +1 -0
  182. package/FrameGraph/Tasks/PostProcesses/ssrRenderingPipelineTask.d.ts +76 -0
  183. package/FrameGraph/Tasks/PostProcesses/ssrRenderingPipelineTask.js +170 -0
  184. package/FrameGraph/Tasks/PostProcesses/ssrRenderingPipelineTask.js.map +1 -0
  185. package/FrameGraph/Tasks/PostProcesses/ssrTask.d.ts +16 -0
  186. package/FrameGraph/Tasks/PostProcesses/ssrTask.js +45 -0
  187. package/FrameGraph/Tasks/PostProcesses/ssrTask.js.map +1 -0
  188. package/FrameGraph/Tasks/Rendering/geometryRendererTask.d.ts +10 -0
  189. package/FrameGraph/Tasks/Rendering/geometryRendererTask.js +29 -0
  190. package/FrameGraph/Tasks/Rendering/geometryRendererTask.js.map +1 -1
  191. package/FrameGraph/frameGraph.d.ts +7 -3
  192. package/FrameGraph/frameGraph.js +10 -4
  193. package/FrameGraph/frameGraph.js.map +1 -1
  194. package/FrameGraph/frameGraphTextureManager.d.ts +2 -1
  195. package/FrameGraph/frameGraphTextureManager.js +4 -3
  196. package/FrameGraph/frameGraphTextureManager.js.map +1 -1
  197. package/FrameGraph/index.d.ts +1 -0
  198. package/FrameGraph/index.js +1 -0
  199. package/FrameGraph/index.js.map +1 -1
  200. package/Materials/PBR/pbrBaseMaterial.js +1 -1
  201. package/Materials/PBR/pbrBaseMaterial.js.map +1 -1
  202. package/Materials/effectRenderer.js +1 -1
  203. package/Materials/effectRenderer.js.map +1 -1
  204. package/Materials/material.js +5 -3
  205. package/Materials/material.js.map +1 -1
  206. package/Materials/materialHelper.geometryrendering.d.ts +7 -5
  207. package/Materials/materialHelper.geometryrendering.js +8 -3
  208. package/Materials/materialHelper.geometryrendering.js.map +1 -1
  209. package/Materials/standardMaterial.js +1 -1
  210. package/Materials/standardMaterial.js.map +1 -1
  211. package/Meshes/geometry.js +18 -7
  212. package/Meshes/geometry.js.map +1 -1
  213. package/Meshes/mesh.vertexData.d.ts +1 -1
  214. package/Meshes/mesh.vertexData.js +2 -1
  215. package/Meshes/mesh.vertexData.js.map +1 -1
  216. package/Particles/particleSystemComponent.d.ts +2 -1
  217. package/Particles/particleSystemComponent.js +2 -2
  218. package/Particles/particleSystemComponent.js.map +1 -1
  219. package/PostProcesses/RenderPipeline/Pipelines/ssrRenderingPipeline.d.ts +23 -30
  220. package/PostProcesses/RenderPipeline/Pipelines/ssrRenderingPipeline.js +226 -411
  221. package/PostProcesses/RenderPipeline/Pipelines/ssrRenderingPipeline.js.map +1 -1
  222. package/PostProcesses/RenderPipeline/Pipelines/thinSSRRenderingPipeline.d.ts +222 -0
  223. package/PostProcesses/RenderPipeline/Pipelines/thinSSRRenderingPipeline.js +373 -0
  224. package/PostProcesses/RenderPipeline/Pipelines/thinSSRRenderingPipeline.js.map +1 -0
  225. package/PostProcesses/thinDepthOfFieldEffect.d.ts +4 -4
  226. package/PostProcesses/thinDepthOfFieldEffect.js.map +1 -1
  227. package/PostProcesses/thinSSRBlurCombinerPostProcess.d.ts +41 -0
  228. package/PostProcesses/thinSSRBlurCombinerPostProcess.js +185 -0
  229. package/PostProcesses/thinSSRBlurCombinerPostProcess.js.map +1 -0
  230. package/PostProcesses/thinSSRBlurPostProcess.d.ts +18 -0
  231. package/PostProcesses/thinSSRBlurPostProcess.js +47 -0
  232. package/PostProcesses/thinSSRBlurPostProcess.js.map +1 -0
  233. package/PostProcesses/thinSSRPostProcess.d.ts +94 -0
  234. package/PostProcesses/thinSSRPostProcess.js +416 -0
  235. package/PostProcesses/thinSSRPostProcess.js.map +1 -0
  236. package/Rendering/IBLShadows/iblShadowsRenderPipeline.d.ts +2 -0
  237. package/Rendering/IBLShadows/iblShadowsRenderPipeline.js +2 -0
  238. package/Rendering/IBLShadows/iblShadowsRenderPipeline.js.map +1 -1
  239. package/Rendering/iblCdfGenerator.js +1 -1
  240. package/Rendering/iblCdfGenerator.js.map +1 -1
  241. package/Shaders/screenSpaceReflection2BlurCombiner.fragment.js +13 -2
  242. package/Shaders/screenSpaceReflection2BlurCombiner.fragment.js.map +1 -1
  243. package/ShadersWGSL/geometry.fragment.js +1 -1
  244. package/ShadersWGSL/geometry.fragment.js.map +1 -1
  245. package/ShadersWGSL/screenSpaceReflection2BlurCombiner.fragment.js +13 -2
  246. package/ShadersWGSL/screenSpaceReflection2BlurCombiner.fragment.js.map +1 -1
  247. package/package.json +1 -1
@@ -0,0 +1,497 @@
1
+ import { __decorate } from "../../../../tslib.es6.js";
2
+
3
+ import { RegisterClass } from "../../../../Misc/typeStore.js";
4
+ import { NodeRenderGraphBlockConnectionPointTypes } from "../../Types/nodeRenderGraphTypes.js";
5
+ import { editableInPropertyPage } from "../../../../Decorators/nodeDecorator.js";
6
+ import { FrameGraphSSRRenderingPipelineTask } from "../../../Tasks/PostProcesses/ssrRenderingPipelineTask.js";
7
+ import { NodeRenderGraphBasePostProcessBlock } from "./basePostProcessBlock.js";
8
+ /**
9
+ * Block that implements the SSR post process
10
+ */
11
+ export class NodeRenderGraphSSRPostProcessBlock extends NodeRenderGraphBasePostProcessBlock {
12
+ /**
13
+ * Gets the frame graph task associated with this block
14
+ */
15
+ get task() {
16
+ return this._frameGraphTask;
17
+ }
18
+ /**
19
+ * Create a new NodeRenderGraphSSRPostProcessBlock
20
+ * @param name defines the block name
21
+ * @param frameGraph defines the hosting frame graph
22
+ * @param scene defines the hosting scene
23
+ * @param textureType The texture type used by the different post processes created by SSR (default: 0)
24
+ */
25
+ constructor(name, frameGraph, scene, textureType = 0) {
26
+ super(name, frameGraph, scene);
27
+ this._additionalConstructionParameters = [textureType];
28
+ this.registerInput("camera", NodeRenderGraphBlockConnectionPointTypes.Camera);
29
+ this.registerInput("geomDepth", NodeRenderGraphBlockConnectionPointTypes.TextureViewDepth);
30
+ this.registerInput("geomNormal", NodeRenderGraphBlockConnectionPointTypes.TextureViewNormal);
31
+ this.registerInput("geomReflectivity", NodeRenderGraphBlockConnectionPointTypes.TextureReflectivity);
32
+ this.registerInput("geomBackDepth", NodeRenderGraphBlockConnectionPointTypes.TextureViewDepth, true);
33
+ this.geomNormal.addAcceptedConnectionPointTypes(NodeRenderGraphBlockConnectionPointTypes.TextureWorldNormal);
34
+ this.geomDepth.addAcceptedConnectionPointTypes(NodeRenderGraphBlockConnectionPointTypes.TextureScreenDepth);
35
+ this.geomBackDepth.addAcceptedConnectionPointTypes(NodeRenderGraphBlockConnectionPointTypes.TextureScreenDepth);
36
+ this._finalizeInputOutputRegistering();
37
+ this._frameGraphTask = new FrameGraphSSRRenderingPipelineTask(this.name, frameGraph, textureType);
38
+ }
39
+ _createTask(textureType) {
40
+ const sourceSamplingMode = this.sourceSamplingMode;
41
+ const maxDistance = this.maxDistance;
42
+ const step = this.step;
43
+ const thickness = this.thickness;
44
+ const strength = this.strength;
45
+ const reflectionSpecularFalloffExponent = this.reflectionSpecularFalloffExponent;
46
+ const maxSteps = this.maxSteps;
47
+ const roughnessFactor = this.roughnessFactor;
48
+ const selfCollisionNumSkip = this.selfCollisionNumSkip;
49
+ const reflectivityThreshold = this.reflectivityThreshold;
50
+ const ssrDownsample = this.ssrDownsample;
51
+ const blurDispersionStrength = this.blurDispersionStrength;
52
+ const blurDownsample = this.blurDownsample;
53
+ const enableSmoothReflections = this.enableSmoothReflections;
54
+ const attenuateScreenBorders = this.attenuateScreenBorders;
55
+ const attenuateIntersectionDistance = this.attenuateIntersectionDistance;
56
+ const attenuateIntersectionIterations = this.attenuateIntersectionIterations;
57
+ const attenuateFacingCamera = this.attenuateFacingCamera;
58
+ const attenuateBackfaceReflection = this.attenuateBackfaceReflection;
59
+ const clipToFrustum = this.clipToFrustum;
60
+ const enableAutomaticThicknessComputation = this.enableAutomaticThicknessComputation;
61
+ const useFresnel = this.useFresnel;
62
+ const inputTextureColorIsInGammaSpace = this.inputTextureColorIsInGammaSpace;
63
+ const generateOutputInGammaSpace = this.generateOutputInGammaSpace;
64
+ const debug = this.debug;
65
+ this._frameGraphTask.dispose();
66
+ this._frameGraphTask = new FrameGraphSSRRenderingPipelineTask(this.name, this._frameGraph, textureType);
67
+ this.sourceSamplingMode = sourceSamplingMode;
68
+ this.maxDistance = maxDistance;
69
+ this.step = step;
70
+ this.thickness = thickness;
71
+ this.strength = strength;
72
+ this.reflectionSpecularFalloffExponent = reflectionSpecularFalloffExponent;
73
+ this.maxSteps = maxSteps;
74
+ this.roughnessFactor = roughnessFactor;
75
+ this.selfCollisionNumSkip = selfCollisionNumSkip;
76
+ this.reflectivityThreshold = reflectivityThreshold;
77
+ this.ssrDownsample = ssrDownsample;
78
+ this.blurDispersionStrength = blurDispersionStrength;
79
+ this.blurDownsample = blurDownsample;
80
+ this.enableSmoothReflections = enableSmoothReflections;
81
+ this.attenuateScreenBorders = attenuateScreenBorders;
82
+ this.attenuateIntersectionDistance = attenuateIntersectionDistance;
83
+ this.attenuateIntersectionIterations = attenuateIntersectionIterations;
84
+ this.attenuateFacingCamera = attenuateFacingCamera;
85
+ this.attenuateBackfaceReflection = attenuateBackfaceReflection;
86
+ this.clipToFrustum = clipToFrustum;
87
+ this.useFresnel = useFresnel;
88
+ this.enableAutomaticThicknessComputation = enableAutomaticThicknessComputation;
89
+ this.inputTextureColorIsInGammaSpace = inputTextureColorIsInGammaSpace;
90
+ this.generateOutputInGammaSpace = generateOutputInGammaSpace;
91
+ this.debug = debug;
92
+ this._additionalConstructionParameters = [textureType];
93
+ }
94
+ /** The texture type used by the different post processes created by SSR */
95
+ get textureType() {
96
+ return this._frameGraphTask.textureType;
97
+ }
98
+ set textureType(value) {
99
+ this._createTask(value);
100
+ }
101
+ /** Gets or sets a boolean indicating if the effect should be rendered in debug mode */
102
+ get debug() {
103
+ return this._frameGraphTask.ssr.debug;
104
+ }
105
+ set debug(value) {
106
+ this._frameGraphTask.ssr.debug = value;
107
+ }
108
+ /** Gets or sets the current reflection strength. 1.0 is an ideal value but can be increased/decreased for particular results */
109
+ get strength() {
110
+ return this._frameGraphTask.ssr.strength;
111
+ }
112
+ set strength(value) {
113
+ this._frameGraphTask.ssr.strength = value;
114
+ }
115
+ /** Gets or sets the falloff exponent used to compute the reflection strength. Higher values lead to fainter reflections */
116
+ get reflectionSpecularFalloffExponent() {
117
+ return this._frameGraphTask.ssr.reflectionSpecularFalloffExponent;
118
+ }
119
+ set reflectionSpecularFalloffExponent(value) {
120
+ this._frameGraphTask.ssr.reflectionSpecularFalloffExponent = value;
121
+ }
122
+ /** Gets or sets the minimum value for one of the reflectivity component of the material to consider it for SSR */
123
+ get reflectivityThreshold() {
124
+ return this._frameGraphTask.ssr.reflectivityThreshold;
125
+ }
126
+ set reflectivityThreshold(value) {
127
+ this._frameGraphTask.ssr.reflectivityThreshold = value;
128
+ }
129
+ /** Gets or sets the thickness value used as tolerance when computing the intersection between the reflected ray and the scene */
130
+ get thickness() {
131
+ return this._frameGraphTask.ssr.thickness;
132
+ }
133
+ set thickness(value) {
134
+ this._frameGraphTask.ssr.thickness = value;
135
+ }
136
+ /** Gets or sets the step size used to iterate until the effect finds the color of the reflection's pixel */
137
+ get step() {
138
+ return this._frameGraphTask.ssr.step;
139
+ }
140
+ set step(value) {
141
+ this._frameGraphTask.ssr.step = value;
142
+ }
143
+ /** Gets or sets whether or not smoothing reflections is enabled */
144
+ get enableSmoothReflections() {
145
+ return this._frameGraphTask.ssr.enableSmoothReflections;
146
+ }
147
+ set enableSmoothReflections(value) {
148
+ this._frameGraphTask.ssr.enableSmoothReflections = value;
149
+ }
150
+ /** Maximum number of steps during the ray marching process after which we consider an intersection could not be found */
151
+ get maxSteps() {
152
+ return this._frameGraphTask.ssr.maxSteps;
153
+ }
154
+ set maxSteps(value) {
155
+ this._frameGraphTask.ssr.maxSteps = value;
156
+ }
157
+ /** Gets or sets the max distance used to define how far we look for reflection during the ray-marching on the reflected ray */
158
+ get maxDistance() {
159
+ return this._frameGraphTask.ssr.maxDistance;
160
+ }
161
+ set maxDistance(value) {
162
+ this._frameGraphTask.ssr.maxDistance = value;
163
+ }
164
+ /** Gets or sets the factor applied when computing roughness */
165
+ get roughnessFactor() {
166
+ return this._frameGraphTask.ssr.roughnessFactor;
167
+ }
168
+ set roughnessFactor(value) {
169
+ this._frameGraphTask.ssr.roughnessFactor = value;
170
+ }
171
+ /** Number of steps to skip at start when marching the ray to avoid self collisions */
172
+ get selfCollisionNumSkip() {
173
+ return this._frameGraphTask.ssr.selfCollisionNumSkip;
174
+ }
175
+ set selfCollisionNumSkip(value) {
176
+ this._frameGraphTask.ssr.selfCollisionNumSkip = value;
177
+ }
178
+ /** Gets or sets the downsample factor used to reduce the size of the texture used to compute the SSR contribution */
179
+ get ssrDownsample() {
180
+ return this._frameGraphTask.ssr.ssrDownsample;
181
+ }
182
+ set ssrDownsample(value) {
183
+ this._frameGraphTask.ssr.ssrDownsample = value;
184
+ }
185
+ /** Gets or sets a boolean indicating if the ray should be clipped to the frustum */
186
+ get clipToFrustum() {
187
+ return this._frameGraphTask.ssr.clipToFrustum;
188
+ }
189
+ set clipToFrustum(value) {
190
+ this._frameGraphTask.ssr.clipToFrustum = value;
191
+ }
192
+ /** Gets or sets a boolean defining if geometry thickness should be computed automatically */
193
+ get enableAutomaticThicknessComputation() {
194
+ return this._frameGraphTask.ssr.enableAutomaticThicknessComputation;
195
+ }
196
+ set enableAutomaticThicknessComputation(value) {
197
+ this._frameGraphTask.ssr.enableAutomaticThicknessComputation = value;
198
+ }
199
+ /** Gets or sets a boolean indicating whether the blending between the current color pixel and the reflection color should be done with a Fresnel coefficient */
200
+ get useFresnel() {
201
+ return this._frameGraphTask.ssr.useFresnel;
202
+ }
203
+ set useFresnel(value) {
204
+ this._frameGraphTask.ssr.useFresnel = value;
205
+ }
206
+ /** Gets or sets the blur dispersion strength. Set this value to 0 to disable blurring */
207
+ get blurDispersionStrength() {
208
+ return this._frameGraphTask.ssr.blurDispersionStrength;
209
+ }
210
+ set blurDispersionStrength(value) {
211
+ this._frameGraphTask.ssr.blurDispersionStrength = value;
212
+ }
213
+ /** Gets or sets the downsample factor used to reduce the size of the textures used to blur the reflection effect */
214
+ get blurDownsample() {
215
+ return this._frameGraphTask.ssr.blurDownsample;
216
+ }
217
+ set blurDownsample(value) {
218
+ this._frameGraphTask.ssr.blurDownsample = value;
219
+ }
220
+ /** Gets or sets a boolean indicating if the reflections should be attenuated at the screen borders */
221
+ get attenuateScreenBorders() {
222
+ return this._frameGraphTask.ssr.attenuateScreenBorders;
223
+ }
224
+ set attenuateScreenBorders(value) {
225
+ this._frameGraphTask.ssr.attenuateScreenBorders = value;
226
+ }
227
+ /** Gets or sets a boolean indicating if the reflections should be attenuated according to the distance of the intersection */
228
+ get attenuateIntersectionDistance() {
229
+ return this._frameGraphTask.ssr.attenuateIntersectionDistance;
230
+ }
231
+ set attenuateIntersectionDistance(value) {
232
+ this._frameGraphTask.ssr.attenuateIntersectionDistance = value;
233
+ }
234
+ /** Gets or sets a boolean indicating if the reflections should be attenuated according to the number of iterations performed to find the intersection */
235
+ get attenuateIntersectionIterations() {
236
+ return this._frameGraphTask.ssr.attenuateIntersectionIterations;
237
+ }
238
+ set attenuateIntersectionIterations(value) {
239
+ this._frameGraphTask.ssr.attenuateIntersectionIterations = value;
240
+ }
241
+ /** Gets or sets a boolean indicating if the reflections should be attenuated when the reflection ray is facing the camera (the view direction) */
242
+ get attenuateFacingCamera() {
243
+ return this._frameGraphTask.ssr.attenuateFacingCamera;
244
+ }
245
+ set attenuateFacingCamera(value) {
246
+ this._frameGraphTask.ssr.attenuateFacingCamera = value;
247
+ }
248
+ /** Gets or sets a boolean indicating if the backface reflections should be attenuated */
249
+ get attenuateBackfaceReflection() {
250
+ return this._frameGraphTask.ssr.attenuateBackfaceReflection;
251
+ }
252
+ set attenuateBackfaceReflection(value) {
253
+ this._frameGraphTask.ssr.attenuateBackfaceReflection = value;
254
+ }
255
+ /** Gets or sets a boolean defining if the input color texture is in gamma space */
256
+ get inputTextureColorIsInGammaSpace() {
257
+ return this._frameGraphTask.ssr.inputTextureColorIsInGammaSpace;
258
+ }
259
+ set inputTextureColorIsInGammaSpace(value) {
260
+ this._frameGraphTask.ssr.inputTextureColorIsInGammaSpace = value;
261
+ }
262
+ /** Gets or sets a boolean defining if the output color texture generated by the SSR pipeline should be in gamma space */
263
+ get generateOutputInGammaSpace() {
264
+ return this._frameGraphTask.ssr.generateOutputInGammaSpace;
265
+ }
266
+ set generateOutputInGammaSpace(value) {
267
+ this._frameGraphTask.ssr.generateOutputInGammaSpace = value;
268
+ }
269
+ /**
270
+ * Gets the current class name
271
+ * @returns the class name
272
+ */
273
+ getClassName() {
274
+ return "NodeRenderGraphSSRPostProcessBlock";
275
+ }
276
+ /**
277
+ * Gets the camera input component
278
+ */
279
+ get camera() {
280
+ return this._inputs[2];
281
+ }
282
+ /**
283
+ * Gets the geometry depth input component
284
+ */
285
+ get geomDepth() {
286
+ return this._inputs[3];
287
+ }
288
+ /**
289
+ * Gets the geometry normal input component
290
+ */
291
+ get geomNormal() {
292
+ return this._inputs[4];
293
+ }
294
+ /**
295
+ * Gets the geometry reflectivity input component
296
+ */
297
+ get geomReflectivity() {
298
+ return this._inputs[5];
299
+ }
300
+ /**
301
+ * Gets the geometry back depth input component
302
+ */
303
+ get geomBackDepth() {
304
+ return this._inputs[6];
305
+ }
306
+ _buildBlock(state) {
307
+ super._buildBlock(state);
308
+ this._frameGraphTask.normalTexture = this.geomNormal.connectedPoint?.value;
309
+ this._frameGraphTask.depthTexture = this.geomDepth.connectedPoint?.value;
310
+ this._frameGraphTask.reflectivityTexture = this.geomReflectivity.connectedPoint?.value;
311
+ this._frameGraphTask.backDepthTexture = this.geomBackDepth.connectedPoint?.value;
312
+ this._frameGraphTask.camera = this.camera.connectedPoint?.value;
313
+ if (this.enableAutomaticThicknessComputation) {
314
+ if (!this._frameGraphTask.backDepthTexture) {
315
+ throw new Error(`SSR post process "${this.name}": Automatic thickness computation requires a back depth texture to be connected!`);
316
+ }
317
+ const ownerBlock = this.geomBackDepth.connectedPoint.ownerBlock;
318
+ if (ownerBlock.getClassName() === "NodeRenderGraphGeometryRendererBlock") {
319
+ const geometryRendererBlock = ownerBlock;
320
+ if (!geometryRendererBlock.reverseCulling) {
321
+ throw new Error(`SSR post process "${this.name}": Automatic thickness computation requires the geometry renderer block for the back depth texture to have reverse culling enabled!`);
322
+ }
323
+ }
324
+ }
325
+ if (this.geomNormal.connectedPoint) {
326
+ if (this.geomNormal.connectedPoint.type === NodeRenderGraphBlockConnectionPointTypes.TextureWorldNormal) {
327
+ this._frameGraphTask.ssr.normalsAreInWorldSpace = true;
328
+ this._frameGraphTask.ssr.normalsAreUnsigned = true;
329
+ }
330
+ }
331
+ if (this.geomDepth.connectedPoint) {
332
+ if (this.geomDepth.connectedPoint.type === NodeRenderGraphBlockConnectionPointTypes.TextureScreenDepth) {
333
+ this._frameGraphTask.ssr.useScreenspaceDepth = true;
334
+ }
335
+ }
336
+ }
337
+ _dumpPropertiesCode() {
338
+ const codes = [];
339
+ codes.push(`${this._codeVariableName}.debug = ${this.debug};`);
340
+ codes.push(`${this._codeVariableName}.strength = ${this.strength};`);
341
+ codes.push(`${this._codeVariableName}.reflectionSpecularFalloffExponent = ${this.reflectionSpecularFalloffExponent};`);
342
+ codes.push(`${this._codeVariableName}.reflectivityThreshold = ${this.reflectivityThreshold};`);
343
+ codes.push(`${this._codeVariableName}.thickness = ${this.thickness};`);
344
+ codes.push(`${this._codeVariableName}.step = ${this.step};`);
345
+ codes.push(`${this._codeVariableName}.enableSmoothReflections = ${this.enableSmoothReflections};`);
346
+ codes.push(`${this._codeVariableName}.maxSteps = ${this.maxSteps};`);
347
+ codes.push(`${this._codeVariableName}.maxDistance = ${this.maxDistance};`);
348
+ codes.push(`${this._codeVariableName}.roughnessFactor = ${this.roughnessFactor};`);
349
+ codes.push(`${this._codeVariableName}.selfCollisionNumSkip = ${this.selfCollisionNumSkip};`);
350
+ codes.push(`${this._codeVariableName}.ssrDownsample = ${this.ssrDownsample};`);
351
+ codes.push(`${this._codeVariableName}.clipToFrustum = ${this.clipToFrustum};`);
352
+ codes.push(`${this._codeVariableName}.useFresnel = ${this.useFresnel};`);
353
+ codes.push(`${this._codeVariableName}.enableAutomaticThicknessComputation = ${this.enableAutomaticThicknessComputation};`);
354
+ codes.push(`${this._codeVariableName}.blurDispersionStrength = ${this.blurDispersionStrength};`);
355
+ codes.push(`${this._codeVariableName}.blurDownsample = ${this.blurDownsample};`);
356
+ codes.push(`${this._codeVariableName}.attenuateScreenBorders = ${this.attenuateScreenBorders};`);
357
+ codes.push(`${this._codeVariableName}.attenuateIntersectionDistance = ${this.attenuateIntersectionDistance};`);
358
+ codes.push(`${this._codeVariableName}.attenuateIntersectionIterations = ${this.attenuateIntersectionIterations};`);
359
+ codes.push(`${this._codeVariableName}.attenuateFacingCamera = ${this.attenuateFacingCamera};`);
360
+ codes.push(`${this._codeVariableName}.attenuateBackfaceReflection = ${this.attenuateBackfaceReflection};`);
361
+ codes.push(`${this._codeVariableName}.inputTextureColorIsInGammaSpace = ${this.inputTextureColorIsInGammaSpace};`);
362
+ codes.push(`${this._codeVariableName}.generateOutputInGammaSpace = ${this.generateOutputInGammaSpace};`);
363
+ return super._dumpPropertiesCode() + codes.join("\n");
364
+ }
365
+ serialize() {
366
+ const serializationObject = super.serialize();
367
+ serializationObject.debug = this.debug;
368
+ serializationObject.strength = this.strength;
369
+ serializationObject.reflectionSpecularFalloffExponent = this.reflectionSpecularFalloffExponent;
370
+ serializationObject.reflectivityThreshold = this.reflectivityThreshold;
371
+ serializationObject.thickness = this.thickness;
372
+ serializationObject.step = this.step;
373
+ serializationObject.enableSmoothReflections = this.enableSmoothReflections;
374
+ serializationObject.maxSteps = this.maxSteps;
375
+ serializationObject.maxDistance = this.maxDistance;
376
+ serializationObject.roughnessFactor = this.roughnessFactor;
377
+ serializationObject.selfCollisionNumSkip = this.selfCollisionNumSkip;
378
+ serializationObject.ssrDownsample = this.ssrDownsample;
379
+ serializationObject.clipToFrustum = this.clipToFrustum;
380
+ serializationObject.useFresnel = this.useFresnel;
381
+ serializationObject.enableAutomaticThicknessComputation = this.enableAutomaticThicknessComputation;
382
+ serializationObject.blurDispersionStrength = this.blurDispersionStrength;
383
+ serializationObject.blurDownsample = this.blurDownsample;
384
+ serializationObject.attenuateScreenBorders = this.attenuateScreenBorders;
385
+ serializationObject.attenuateIntersectionDistance = this.attenuateIntersectionDistance;
386
+ serializationObject.attenuateIntersectionIterations = this.attenuateIntersectionIterations;
387
+ serializationObject.attenuateFacingCamera = this.attenuateFacingCamera;
388
+ serializationObject.attenuateBackfaceReflection = this.attenuateBackfaceReflection;
389
+ serializationObject.inputTextureColorIsInGammaSpace = this.inputTextureColorIsInGammaSpace;
390
+ serializationObject.generateOutputInGammaSpace = this.generateOutputInGammaSpace;
391
+ return serializationObject;
392
+ }
393
+ _deserialize(serializationObject) {
394
+ super._deserialize(serializationObject);
395
+ this.debug = serializationObject.debug;
396
+ this.strength = serializationObject.strength;
397
+ this.reflectionSpecularFalloffExponent = serializationObject.reflectionSpecularFalloffExponent;
398
+ this.reflectivityThreshold = serializationObject.reflectivityThreshold;
399
+ this.thickness = serializationObject.thickness;
400
+ this.step = serializationObject.step;
401
+ this.enableSmoothReflections = serializationObject.enableSmoothReflections;
402
+ this.maxSteps = serializationObject.maxSteps;
403
+ this.maxDistance = serializationObject.maxDistance;
404
+ this.roughnessFactor = serializationObject.roughnessFactor;
405
+ this.selfCollisionNumSkip = serializationObject.selfCollisionNumSkip;
406
+ this.ssrDownsample = serializationObject.ssrDownsample;
407
+ this.clipToFrustum = serializationObject.clipToFrustum;
408
+ this.useFresnel = serializationObject.useFresnel;
409
+ this.enableAutomaticThicknessComputation = serializationObject.enableAutomaticThicknessComputation;
410
+ this.blurDispersionStrength = serializationObject.blurDispersionStrength;
411
+ this.blurDownsample = serializationObject.blurDownsample;
412
+ this.attenuateScreenBorders = serializationObject.attenuateScreenBorders;
413
+ this.attenuateIntersectionDistance = serializationObject.attenuateIntersectionDistance;
414
+ this.attenuateIntersectionIterations = serializationObject.attenuateIntersectionIterations;
415
+ this.attenuateFacingCamera = serializationObject.attenuateFacingCamera;
416
+ this.attenuateBackfaceReflection = serializationObject.attenuateBackfaceReflection;
417
+ this.inputTextureColorIsInGammaSpace = serializationObject.inputTextureColorIsInGammaSpace;
418
+ this.generateOutputInGammaSpace = serializationObject.generateOutputInGammaSpace;
419
+ }
420
+ }
421
+ __decorate([
422
+ editableInPropertyPage("Texture type", 8 /* PropertyTypeForEdition.TextureType */, "SSR")
423
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "textureType", null);
424
+ __decorate([
425
+ editableInPropertyPage("Debug", 0 /* PropertyTypeForEdition.Boolean */, "SSR")
426
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "debug", null);
427
+ __decorate([
428
+ editableInPropertyPage("Strength", 1 /* PropertyTypeForEdition.Float */, "SSR", { min: 0, max: 5 })
429
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "strength", null);
430
+ __decorate([
431
+ editableInPropertyPage("Reflection exponent", 1 /* PropertyTypeForEdition.Float */, "SSR", { min: 0, max: 5 })
432
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "reflectionSpecularFalloffExponent", null);
433
+ __decorate([
434
+ editableInPropertyPage("Reflectivity threshold", 1 /* PropertyTypeForEdition.Float */, "SSR", { min: 0, max: 1 })
435
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "reflectivityThreshold", null);
436
+ __decorate([
437
+ editableInPropertyPage("Thickness", 1 /* PropertyTypeForEdition.Float */, "SSR", { min: 0, max: 10 })
438
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "thickness", null);
439
+ __decorate([
440
+ editableInPropertyPage("Step", 2 /* PropertyTypeForEdition.Int */, "SSR", { min: 1, max: 50 })
441
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "step", null);
442
+ __decorate([
443
+ editableInPropertyPage("Smooth reflections", 0 /* PropertyTypeForEdition.Boolean */, "SSR")
444
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "enableSmoothReflections", null);
445
+ __decorate([
446
+ editableInPropertyPage("Max steps", 2 /* PropertyTypeForEdition.Int */, "SSR", { min: 1, max: 3000 })
447
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "maxSteps", null);
448
+ __decorate([
449
+ editableInPropertyPage("Max distance", 1 /* PropertyTypeForEdition.Float */, "SSR", { min: 1, max: 3000 })
450
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "maxDistance", null);
451
+ __decorate([
452
+ editableInPropertyPage("Roughness factor", 1 /* PropertyTypeForEdition.Float */, "SSR", { min: 0, max: 1 })
453
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "roughnessFactor", null);
454
+ __decorate([
455
+ editableInPropertyPage("Self collision skips", 2 /* PropertyTypeForEdition.Int */, "SSR", { min: 1, max: 10 })
456
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "selfCollisionNumSkip", null);
457
+ __decorate([
458
+ editableInPropertyPage("SSR downsample", 2 /* PropertyTypeForEdition.Int */, "SSR", { min: 0, max: 5 })
459
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "ssrDownsample", null);
460
+ __decorate([
461
+ editableInPropertyPage("Clip to frustum", 0 /* PropertyTypeForEdition.Boolean */, "SSR")
462
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "clipToFrustum", null);
463
+ __decorate([
464
+ editableInPropertyPage("Automatic thickness computation", 0 /* PropertyTypeForEdition.Boolean */, "SSR")
465
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "enableAutomaticThicknessComputation", null);
466
+ __decorate([
467
+ editableInPropertyPage("Use Fresnel", 0 /* PropertyTypeForEdition.Boolean */, "SSR")
468
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "useFresnel", null);
469
+ __decorate([
470
+ editableInPropertyPage("Strength", 1 /* PropertyTypeForEdition.Float */, "Blur", { min: 0, max: 0.15 })
471
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "blurDispersionStrength", null);
472
+ __decorate([
473
+ editableInPropertyPage("Blur downsample", 2 /* PropertyTypeForEdition.Int */, "Blur", { min: 0, max: 5 })
474
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "blurDownsample", null);
475
+ __decorate([
476
+ editableInPropertyPage("Screen borders", 0 /* PropertyTypeForEdition.Boolean */, "ATTENUATIONS")
477
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "attenuateScreenBorders", null);
478
+ __decorate([
479
+ editableInPropertyPage("Distance", 0 /* PropertyTypeForEdition.Boolean */, "ATTENUATIONS")
480
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "attenuateIntersectionDistance", null);
481
+ __decorate([
482
+ editableInPropertyPage("Step iterations", 0 /* PropertyTypeForEdition.Boolean */, "ATTENUATIONS")
483
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "attenuateIntersectionIterations", null);
484
+ __decorate([
485
+ editableInPropertyPage("Facing camera", 0 /* PropertyTypeForEdition.Boolean */, "ATTENUATIONS")
486
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "attenuateFacingCamera", null);
487
+ __decorate([
488
+ editableInPropertyPage("Backface reflections", 0 /* PropertyTypeForEdition.Boolean */, "ATTENUATIONS")
489
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "attenuateBackfaceReflection", null);
490
+ __decorate([
491
+ editableInPropertyPage("Input is in gamma space", 0 /* PropertyTypeForEdition.Boolean */, "Color space")
492
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "inputTextureColorIsInGammaSpace", null);
493
+ __decorate([
494
+ editableInPropertyPage("Output to gamma space", 0 /* PropertyTypeForEdition.Boolean */, "Color space")
495
+ ], NodeRenderGraphSSRPostProcessBlock.prototype, "generateOutputInGammaSpace", null);
496
+ RegisterClass("BABYLON.NodeRenderGraphSSRPostProcessBlock", NodeRenderGraphSSRPostProcessBlock);
497
+ //# sourceMappingURL=ssrPostProcessBlock.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ssrPostProcessBlock.js","sourceRoot":"","sources":["../../../../../../../dev/core/src/FrameGraph/Node/Blocks/PostProcesses/ssrPostProcessBlock.ts"],"names":[],"mappings":";AAUA,OAAO,EAAE,SAAS,EAAE,yCAA+B;AACnD,OAAO,EAAE,aAAa,EAAE,MAAM,4BAA4B,CAAC;AAC3D,OAAO,EAAE,wCAAwC,EAAE,MAAM,kCAAkC,CAAC;AAC5F,OAAO,EAAE,sBAAsB,EAA0B,MAAM,sCAAsC,CAAC;AACtG,OAAO,EAAE,kCAAkC,EAAE,MAAM,uDAAuD,CAAC;AAC3G,OAAO,EAAE,mCAAmC,EAAE,MAAM,wBAAwB,CAAC;AAE7E;;GAEG;AACH,MAAM,OAAO,kCAAm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GAAG,EAAE,CAAC,EAAE,CAAC;uEAG/F;AAQD;IADC,sBAAsB,CAAC,iBAAiB,0CAAkC,KAAK,CAAC;uEAGhF;AAQD;IADC,sBAAsB,CAAC,iCAAiC,0CAAkC,KAAK,CAAC;6FAGhG;AAQD;IADC,sBAAsB,CAAC,aAAa,0CAAkC,KAAK,CAAC;oEAG5E;AAQD;IADC,sBAAsB,CAAC,UAAU,wCAAgC,MAAM,EAAE,EAAE,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,IAAI,EAAE,CAAC;gFAG/F;AAQD;IADC,sBAAsB,CAAC,iBAAiB,sCAA8B,MAAM,EAAE,EAAE,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC,EAAE,CAAC;wEAGjG;AAQD;IADC,sBAAsB,CAAC,gBAAgB,0CAAkC,cAAc,CAAC;gFAGxF;AAQD;IADC,sBAAsB,CAAC,UAAU,0CAAkC,cAAc,CAAC;uFAGlF;AAQD;IADC,sBAAsB,CAAC,iBAAiB,0CAAkC,cAAc,CAAC;yFAGzF;AAQD;IADC,sBAAsB,CAAC,eAAe,0CAAkC,cAAc,CAAC;+EAGvF;AAQD;IADC,sBAAsB,CAAC,sBAAsB,0CAAkC,cAAc,CAAC;qFAG9F;AAQD;IADC,sBAAsB,CAAC,yBAAyB,0CAAkC,aAAa,CAAC;yFAGhG;AAQD;IADC,sBAAsB,CAAC,uBAAuB,0CAAkC,aAAa,CAAC;oFAG9F;AA8KL,aAAa,CAAC,4CAA4C,EAAE,kCAAkC,CAAC,CAAC","sourcesContent":["import type {\r\n Scene,\r\n FrameGraph,\r\n NodeRenderGraphConnectionPoint,\r\n NodeRenderGraphBuildState,\r\n FrameGraphTextureHandle,\r\n Camera,\r\n NodeRenderGraphGeometryRendererBlock,\r\n // eslint-disable-next-line import/no-internal-modules\r\n} from \"core/index\";\r\nimport { Constants } from \"core/Engines/constants\";\r\nimport { RegisterClass } from \"../../../../Misc/typeStore\";\r\nimport { NodeRenderGraphBlockConnectionPointTypes } from \"../../Types/nodeRenderGraphTypes\";\r\nimport { editableInPropertyPage, PropertyTypeForEdition } from \"../../../../Decorators/nodeDecorator\";\r\nimport { FrameGraphSSRRenderingPipelineTask } from \"../../../Tasks/PostProcesses/ssrRenderingPipelineTask\";\r\nimport { NodeRenderGraphBasePostProcessBlock } from \"./basePostProcessBlock\";\r\n\r\n/**\r\n * Block that implements the SSR post process\r\n */\r\nexport class NodeRenderGraphSSRPostProcessBlock extends NodeRenderGraphBasePostProcessBlock {\r\n protected override _frameGraphTask: FrameGraphSSRRenderingPipelineTask;\r\n\r\n /**\r\n * Gets the frame graph task associated with this block\r\n */\r\n public override get task() {\r\n return this._frameGraphTask;\r\n }\r\n\r\n /**\r\n * Create a new NodeRenderGraphSSRPostProcessBlock\r\n * @param name defines the block name\r\n * @param frameGraph defines the hosting frame graph\r\n * @param scene defines the hosting scene\r\n * @param textureType The texture type used by the different post processes created by SSR (default: Constants.TEXTURETYPE_UNSIGNED_BYTE)\r\n */\r\n public constructor(name: string, frameGraph: FrameGraph, scene: Scene, textureType = Constants.TEXTURETYPE_UNSIGNED_BYTE) {\r\n super(name, frameGraph, scene);\r\n\r\n this._additionalConstructionParameters = [textureType];\r\n\r\n this.registerInput(\"camera\", NodeRenderGraphBlockConnectionPointTypes.Camera);\r\n this.registerInput(\"geomDepth\", NodeRenderGraphBlockConnectionPointTypes.TextureViewDepth);\r\n this.registerInput(\"geomNormal\", NodeRenderGraphBlockConnectionPointTypes.TextureViewNormal);\r\n this.registerInput(\"geomReflectivity\", NodeRenderGraphBlockConnectionPointTypes.TextureReflectivity);\r\n this.registerInput(\"geomBackDepth\", NodeRenderGraphBlockConnectionPointTypes.TextureViewDepth, true);\r\n\r\n this.geomNormal.addAcceptedConnectionPointTypes(NodeRenderGraphBlockConnectionPointTypes.TextureWorldNormal);\r\n this.geomDepth.addAcceptedConnectionPointTypes(NodeRenderGraphBlockConnectionPointTypes.TextureScreenDepth);\r\n this.geomBackDepth.addAcceptedConnectionPointTypes(NodeRenderGraphBlockConnectionPointTypes.TextureScreenDepth);\r\n\r\n this._finalizeInputOutputRegistering();\r\n\r\n this._frameGraphTask = new FrameGraphSSRRenderingPipelineTask(this.name, frameGraph, textureType);\r\n }\r\n\r\n private _createTask(textureType: number) {\r\n const sourceSamplingMode = this.sourceSamplingMode;\r\n const maxDistance = this.maxDistance;\r\n const step = this.step;\r\n const thickness = this.thickness;\r\n const strength = this.strength;\r\n const reflectionSpecularFalloffExponent = this.reflectionSpecularFalloffExponent;\r\n const maxSteps = this.maxSteps;\r\n const roughnessFactor = this.roughnessFactor;\r\n const selfCollisionNumSkip = this.selfCollisionNumSkip;\r\n const reflectivityThreshold = this.reflectivityThreshold;\r\n const ssrDownsample = this.ssrDownsample;\r\n const blurDispersionStrength = this.blurDispersionStrength;\r\n const blurDownsample = this.blurDownsample;\r\n const enableSmoothReflections = this.enableSmoothReflections;\r\n const attenuateScreenBorders = this.attenuateScreenBorders;\r\n const attenuateIntersectionDistance = this.attenuateIntersectionDistance;\r\n const attenuateIntersectionIterations = this.attenuateIntersectionIterations;\r\n const attenuateFacingCamera = this.attenuateFacingCamera;\r\n const attenuateBackfaceReflection = this.attenuateBackfaceReflection;\r\n const clipToFrustum = this.clipToFrustum;\r\n const enableAutomaticThicknessComputation = this.enableAutomaticThicknessComputation;\r\n const useFresnel = this.useFresnel;\r\n const inputTextureColorIsInGammaSpace = this.inputTextureColorIsInGammaSpace;\r\n const generateOutputInGammaSpace = this.generateOutputInGammaSpace;\r\n const debug = this.debug;\r\n\r\n this._frameGraphTask.dispose();\r\n this._frameGraphTask = new FrameGraphSSRRenderingPipelineTask(this.name, this._frameGraph, textureType);\r\n\r\n this.sourceSamplingMode = sourceSamplingMode;\r\n this.maxDistance = maxDistance;\r\n this.step = step;\r\n this.thickness = thickness;\r\n this.strength = strength;\r\n this.reflectionSpecularFalloffExponent = reflectionSpecularFalloffExponent;\r\n this.maxSteps = maxSteps;\r\n this.roughnessFactor = roughnessFactor;\r\n this.selfCollisionNumSkip = selfCollisionNumSkip;\r\n this.reflectivityThreshold = reflectivityThreshold;\r\n this.ssrDownsample = ssrDownsample;\r\n this.blurDispersionStrength = blurDispersionStrength;\r\n this.blurDownsample = blurDownsample;\r\n this.enableSmoothReflections = enableSmoothReflections;\r\n this.attenuateScreenBorders = attenuateScreenBorders;\r\n this.attenuateIntersectionDistance = attenuateIntersectionDistance;\r\n this.attenuateIntersectionIterations = attenuateIntersectionIterations;\r\n this.attenuateFacingCamera = attenuateFacingCamera;\r\n this.attenuateBackfaceReflection = attenuateBackfaceReflection;\r\n this.clipToFrustum = clipToFrustum;\r\n this.useFresnel = useFresnel;\r\n this.enableAutomaticThicknessComputation = enableAutomaticThicknessComputation;\r\n this.inputTextureColorIsInGammaSpace = inputTextureColorIsInGammaSpace;\r\n this.generateOutputInGammaSpace = generateOutputInGammaSpace;\r\n this.debug = debug;\r\n\r\n this._additionalConstructionParameters = [textureType];\r\n }\r\n\r\n /** The texture type used by the different post processes created by SSR */\r\n @editableInPropertyPage(\"Texture type\", PropertyTypeForEdition.TextureType, \"SSR\")\r\n public get textureType() {\r\n return this._frameGraphTask.textureType;\r\n }\r\n\r\n public set textureType(value: number) {\r\n this._createTask(value);\r\n }\r\n\r\n /** Gets or sets a boolean indicating if the effect should be rendered in debug mode */\r\n @editableInPropertyPage(\"Debug\", PropertyTypeForEdition.Boolean, \"SSR\")\r\n public get debug() {\r\n return this._frameGraphTask.ssr.debug;\r\n }\r\n\r\n public set debug(value: boolean) {\r\n this._frameGraphTask.ssr.debug = value;\r\n }\r\n\r\n /** Gets or sets the current reflection strength. 1.0 is an ideal value but can be increased/decreased for particular results */\r\n @editableInPropertyPage(\"Strength\", PropertyTypeForEdition.Float, \"SSR\", { min: 0, max: 5 })\r\n public get strength() {\r\n return this._frameGraphTask.ssr.strength;\r\n }\r\n\r\n public set strength(value: number) {\r\n this._frameGraphTask.ssr.strength = value;\r\n }\r\n\r\n /** Gets or sets the falloff exponent used to compute the reflection strength. Higher values lead to fainter reflections */\r\n @editableInPropertyPage(\"Reflection exponent\", PropertyTypeForEdition.Float, \"SSR\", { min: 0, max: 5 })\r\n public get reflectionSpecularFalloffExponent() {\r\n return this._frameGraphTask.ssr.reflectionSpecularFalloffExponent;\r\n }\r\n\r\n public set reflectionSpecularFalloffExponent(value: number) {\r\n this._frameGraphTask.ssr.reflectionSpecularFalloffExponent = value;\r\n }\r\n\r\n /** Gets or sets the minimum value for one of the reflectivity component of the material to consider it for SSR */\r\n @editableInPropertyPage(\"Reflectivity threshold\", PropertyTypeForEdition.Float, \"SSR\", { min: 0, max: 1 })\r\n public get reflectivityThreshold() {\r\n return this._frameGraphTask.ssr.reflectivityThreshold;\r\n }\r\n\r\n public set reflectivityThreshold(value: number) {\r\n this._frameGraphTask.ssr.reflectivityThreshold = value;\r\n }\r\n\r\n /** Gets or sets the thickness value used as tolerance when computing the intersection between the reflected ray and the scene */\r\n @editableInPropertyPage(\"Thickness\", PropertyTypeForEdition.Float, \"SSR\", { min: 0, max: 10 })\r\n public get thickness() {\r\n return this._frameGraphTask.ssr.thickness;\r\n }\r\n\r\n public set thickness(value: number) {\r\n this._frameGraphTask.ssr.thickness = value;\r\n }\r\n\r\n /** Gets or sets the step size used to iterate until the effect finds the color of the reflection's pixel */\r\n @editableInPropertyPage(\"Step\", PropertyTypeForEdition.Int, \"SSR\", { min: 1, max: 50 })\r\n public get step() {\r\n return this._frameGraphTask.ssr.step;\r\n }\r\n\r\n public set step(value: number) {\r\n this._frameGraphTask.ssr.step = value;\r\n }\r\n\r\n /** Gets or sets whether or not smoothing reflections is enabled */\r\n @editableInPropertyPage(\"Smooth reflections\", PropertyTypeForEdition.Boolean, \"SSR\")\r\n public get enableSmoothReflections() {\r\n return this._frameGraphTask.ssr.enableSmoothReflections;\r\n }\r\n\r\n public set enableSmoothReflections(value: boolean) {\r\n this._frameGraphTask.ssr.enableSmoothReflections = value;\r\n }\r\n\r\n /** Maximum number of steps during the ray marching process after which we consider an intersection could not be found */\r\n @editableInPropertyPage(\"Max steps\", PropertyTypeForEdition.Int, \"SSR\", { min: 1, max: 3000 })\r\n public get maxSteps() {\r\n return this._frameGraphTask.ssr.maxSteps;\r\n }\r\n\r\n public set maxSteps(value: number) {\r\n this._frameGraphTask.ssr.maxSteps = value;\r\n }\r\n\r\n /** Gets or sets the max distance used to define how far we look for reflection during the ray-marching on the reflected ray */\r\n @editableInPropertyPage(\"Max distance\", PropertyTypeForEdition.Float, \"SSR\", { min: 1, max: 3000 })\r\n public get maxDistance() {\r\n return this._frameGraphTask.ssr.maxDistance;\r\n }\r\n\r\n public set maxDistance(value: number) {\r\n this._frameGraphTask.ssr.maxDistance = value;\r\n }\r\n\r\n /** Gets or sets the factor applied when computing roughness */\r\n @editableInPropertyPage(\"Roughness factor\", PropertyTypeForEdition.Float, \"SSR\", { min: 0, max: 1 })\r\n public get roughnessFactor() {\r\n return this._frameGraphTask.ssr.roughnessFactor;\r\n }\r\n\r\n public set roughnessFactor(value: number) {\r\n this._frameGraphTask.ssr.roughnessFactor = value;\r\n }\r\n\r\n /** Number of steps to skip at start when marching the ray to avoid self collisions */\r\n @editableInPropertyPage(\"Self collision skips\", PropertyTypeForEdition.Int, \"SSR\", { min: 1, max: 10 })\r\n public get selfCollisionNumSkip() {\r\n return this._frameGraphTask.ssr.selfCollisionNumSkip;\r\n }\r\n\r\n public set selfCollisionNumSkip(value: number) {\r\n this._frameGraphTask.ssr.selfCollisionNumSkip = value;\r\n }\r\n\r\n /** Gets or sets the downsample factor used to reduce the size of the texture used to compute the SSR contribution */\r\n @editableInPropertyPage(\"SSR downsample\", PropertyTypeForEdition.Int, \"SSR\", { min: 0, max: 5 })\r\n public get ssrDownsample() {\r\n return this._frameGraphTask.ssr.ssrDownsample;\r\n }\r\n\r\n public set ssrDownsample(value: number) {\r\n this._frameGraphTask.ssr.ssrDownsample = value;\r\n }\r\n\r\n /** Gets or sets a boolean indicating if the ray should be clipped to the frustum */\r\n @editableInPropertyPage(\"Clip to frustum\", PropertyTypeForEdition.Boolean, \"SSR\")\r\n public get clipToFrustum() {\r\n return this._frameGraphTask.ssr.clipToFrustum;\r\n }\r\n\r\n public set clipToFrustum(value: boolean) {\r\n this._frameGraphTask.ssr.clipToFrustum = value;\r\n }\r\n\r\n /** Gets or sets a boolean defining if geometry thickness should be computed automatically */\r\n @editableInPropertyPage(\"Automatic thickness computation\", PropertyTypeForEdition.Boolean, \"SSR\")\r\n public get enableAutomaticThicknessComputation() {\r\n return this._frameGraphTask.ssr.enableAutomaticThicknessComputation;\r\n }\r\n\r\n public set enableAutomaticThicknessComputation(value: boolean) {\r\n this._frameGraphTask.ssr.enableAutomaticThicknessComputation = value;\r\n }\r\n\r\n /** Gets or sets a boolean indicating whether the blending between the current color pixel and the reflection color should be done with a Fresnel coefficient */\r\n @editableInPropertyPage(\"Use Fresnel\", PropertyTypeForEdition.Boolean, \"SSR\")\r\n public get useFresnel() {\r\n return this._frameGraphTask.ssr.useFresnel;\r\n }\r\n\r\n public set useFresnel(value: boolean) {\r\n this._frameGraphTask.ssr.useFresnel = value;\r\n }\r\n\r\n /** Gets or sets the blur dispersion strength. Set this value to 0 to disable blurring */\r\n @editableInPropertyPage(\"Strength\", PropertyTypeForEdition.Float, \"Blur\", { min: 0, max: 0.15 })\r\n public get blurDispersionStrength() {\r\n return this._frameGraphTask.ssr.blurDispersionStrength;\r\n }\r\n\r\n public set blurDispersionStrength(value: number) {\r\n this._frameGraphTask.ssr.blurDispersionStrength = value;\r\n }\r\n\r\n /** Gets or sets the downsample factor used to reduce the size of the textures used to blur the reflection effect */\r\n @editableInPropertyPage(\"Blur downsample\", PropertyTypeForEdition.Int, \"Blur\", { min: 0, max: 5 })\r\n public get blurDownsample() {\r\n return this._frameGraphTask.ssr.blurDownsample;\r\n }\r\n\r\n public set blurDownsample(value: number) {\r\n this._frameGraphTask.ssr.blurDownsample = value;\r\n }\r\n\r\n /** Gets or sets a boolean indicating if the reflections should be attenuated at the screen borders */\r\n @editableInPropertyPage(\"Screen borders\", PropertyTypeForEdition.Boolean, \"ATTENUATIONS\")\r\n public get attenuateScreenBorders() {\r\n return this._frameGraphTask.ssr.attenuateScreenBorders;\r\n }\r\n\r\n public set attenuateScreenBorders(value: boolean) {\r\n this._frameGraphTask.ssr.attenuateScreenBorders = value;\r\n }\r\n\r\n /** Gets or sets a boolean indicating if the reflections should be attenuated according to the distance of the intersection */\r\n @editableInPropertyPage(\"Distance\", PropertyTypeForEdition.Boolean, \"ATTENUATIONS\")\r\n public get attenuateIntersectionDistance() {\r\n return this._frameGraphTask.ssr.attenuateIntersectionDistance;\r\n }\r\n\r\n public set attenuateIntersectionDistance(value: boolean) {\r\n this._frameGraphTask.ssr.attenuateIntersectionDistance = value;\r\n }\r\n\r\n /** Gets or sets a boolean indicating if the reflections should be attenuated according to the number of iterations performed to find the intersection */\r\n @editableInPropertyPage(\"Step iterations\", PropertyTypeForEdition.Boolean, \"ATTENUATIONS\")\r\n public get attenuateIntersectionIterations() {\r\n return this._frameGraphTask.ssr.attenuateIntersectionIterations;\r\n }\r\n\r\n public set attenuateIntersectionIterations(value: boolean) {\r\n this._frameGraphTask.ssr.attenuateIntersectionIterations = value;\r\n }\r\n\r\n /** Gets or sets a boolean indicating if the reflections should be attenuated when the reflection ray is facing the camera (the view direction) */\r\n @editableInPropertyPage(\"Facing camera\", PropertyTypeForEdition.Boolean, \"ATTENUATIONS\")\r\n public get attenuateFacingCamera() {\r\n return this._frameGraphTask.ssr.attenuateFacingCamera;\r\n }\r\n\r\n public set attenuateFacingCamera(value: boolean) {\r\n this._frameGraphTask.ssr.attenuateFacingCamera = value;\r\n }\r\n\r\n /** Gets or sets a boolean indicating if the backface reflections should be attenuated */\r\n @editableInPropertyPage(\"Backface reflections\", PropertyTypeForEdition.Boolean, \"ATTENUATIONS\")\r\n public get attenuateBackfaceReflection() {\r\n return this._frameGraphTask.ssr.attenuateBackfaceReflection;\r\n }\r\n\r\n public set attenuateBackfaceReflection(value: boolean) {\r\n this._frameGraphTask.ssr.attenuateBackfaceReflection = value;\r\n }\r\n\r\n /** Gets or sets a boolean defining if the input color texture is in gamma space */\r\n @editableInPropertyPage(\"Input is in gamma space\", PropertyTypeForEdition.Boolean, \"Color space\")\r\n public get inputTextureColorIsInGammaSpace() {\r\n return this._frameGraphTask.ssr.inputTextureColorIsInGammaSpace;\r\n }\r\n\r\n public set inputTextureColorIsInGammaSpace(value: boolean) {\r\n this._frameGraphTask.ssr.inputTextureColorIsInGammaSpace = value;\r\n }\r\n\r\n /** Gets or sets a boolean defining if the output color texture generated by the SSR pipeline should be in gamma space */\r\n @editableInPropertyPage(\"Output to gamma space\", PropertyTypeForEdition.Boolean, \"Color space\")\r\n public get generateOutputInGammaSpace() {\r\n return this._frameGraphTask.ssr.generateOutputInGammaSpace;\r\n }\r\n\r\n public set generateOutputInGammaSpace(value: boolean) {\r\n this._frameGraphTask.ssr.generateOutputInGammaSpace = value;\r\n }\r\n\r\n /**\r\n * Gets the current class name\r\n * @returns the class name\r\n */\r\n public override getClassName() {\r\n return \"NodeRenderGraphSSRPostProcessBlock\";\r\n }\r\n\r\n /**\r\n * Gets the camera input component\r\n */\r\n public get camera(): NodeRenderGraphConnectionPoint {\r\n return this._inputs[2];\r\n }\r\n\r\n /**\r\n * Gets the geometry depth input component\r\n */\r\n public get geomDepth(): NodeRenderGraphConnectionPoint {\r\n return this._inputs[3];\r\n }\r\n\r\n /**\r\n * Gets the geometry normal input component\r\n */\r\n public get geomNormal(): NodeRenderGraphConnectionPoint {\r\n return this._inputs[4];\r\n }\r\n\r\n /**\r\n * Gets the geometry reflectivity input component\r\n */\r\n public get geomReflectivity(): NodeRenderGraphConnectionPoint {\r\n return this._inputs[5];\r\n }\r\n\r\n /**\r\n * Gets the geometry back depth input component\r\n */\r\n public get geomBackDepth(): NodeRenderGraphConnectionPoint {\r\n return this._inputs[6];\r\n }\r\n\r\n protected override _buildBlock(state: NodeRenderGraphBuildState) {\r\n super._buildBlock(state);\r\n\r\n this._frameGraphTask.normalTexture = this.geomNormal.connectedPoint?.value as FrameGraphTextureHandle;\r\n this._frameGraphTask.depthTexture = this.geomDepth.connectedPoint?.value as FrameGraphTextureHandle;\r\n this._frameGraphTask.reflectivityTexture = this.geomReflectivity.connectedPoint?.value as FrameGraphTextureHandle;\r\n this._frameGraphTask.backDepthTexture = this.geomBackDepth.connectedPoint?.value as FrameGraphTextureHandle;\r\n this._frameGraphTask.camera = this.camera.connectedPoint?.value as Camera;\r\n\r\n if (this.enableAutomaticThicknessComputation) {\r\n if (!this._frameGraphTask.backDepthTexture) {\r\n throw new Error(`SSR post process \"${this.name}\": Automatic thickness computation requires a back depth texture to be connected!`);\r\n }\r\n\r\n const ownerBlock = this.geomBackDepth.connectedPoint!.ownerBlock!;\r\n if (ownerBlock.getClassName() === \"NodeRenderGraphGeometryRendererBlock\") {\r\n const geometryRendererBlock = ownerBlock as NodeRenderGraphGeometryRendererBlock;\r\n if (!geometryRendererBlock.reverseCulling) {\r\n throw new Error(\r\n `SSR post process \"${this.name}\": Automatic thickness computation requires the geometry renderer block for the back depth texture to have reverse culling enabled!`\r\n );\r\n }\r\n }\r\n }\r\n\r\n if (this.geomNormal.connectedPoint) {\r\n if (this.geomNormal.connectedPoint.type === NodeRenderGraphBlockConnectionPointTypes.TextureWorldNormal) {\r\n this._frameGraphTask.ssr.normalsAreInWorldSpace = true;\r\n this._frameGraphTask.ssr.normalsAreUnsigned = true;\r\n }\r\n }\r\n if (this.geomDepth.connectedPoint) {\r\n if (this.geomDepth.connectedPoint.type === NodeRenderGraphBlockConnectionPointTypes.TextureScreenDepth) {\r\n this._frameGraphTask.ssr.useScreenspaceDepth = true;\r\n }\r\n }\r\n }\r\n\r\n protected override _dumpPropertiesCode() {\r\n const codes: string[] = [];\r\n codes.push(`${this._codeVariableName}.debug = ${this.debug};`);\r\n codes.push(`${this._codeVariableName}.strength = ${this.strength};`);\r\n codes.push(`${this._codeVariableName}.reflectionSpecularFalloffExponent = ${this.reflectionSpecularFalloffExponent};`);\r\n codes.push(`${this._codeVariableName}.reflectivityThreshold = ${this.reflectivityThreshold};`);\r\n codes.push(`${this._codeVariableName}.thickness = ${this.thickness};`);\r\n codes.push(`${this._codeVariableName}.step = ${this.step};`);\r\n codes.push(`${this._codeVariableName}.enableSmoothReflections = ${this.enableSmoothReflections};`);\r\n codes.push(`${this._codeVariableName}.maxSteps = ${this.maxSteps};`);\r\n codes.push(`${this._codeVariableName}.maxDistance = ${this.maxDistance};`);\r\n codes.push(`${this._codeVariableName}.roughnessFactor = ${this.roughnessFactor};`);\r\n codes.push(`${this._codeVariableName}.selfCollisionNumSkip = ${this.selfCollisionNumSkip};`);\r\n codes.push(`${this._codeVariableName}.ssrDownsample = ${this.ssrDownsample};`);\r\n codes.push(`${this._codeVariableName}.clipToFrustum = ${this.clipToFrustum};`);\r\n codes.push(`${this._codeVariableName}.useFresnel = ${this.useFresnel};`);\r\n codes.push(`${this._codeVariableName}.enableAutomaticThicknessComputation = ${this.enableAutomaticThicknessComputation};`);\r\n codes.push(`${this._codeVariableName}.blurDispersionStrength = ${this.blurDispersionStrength};`);\r\n codes.push(`${this._codeVariableName}.blurDownsample = ${this.blurDownsample};`);\r\n codes.push(`${this._codeVariableName}.attenuateScreenBorders = ${this.attenuateScreenBorders};`);\r\n codes.push(`${this._codeVariableName}.attenuateIntersectionDistance = ${this.attenuateIntersectionDistance};`);\r\n codes.push(`${this._codeVariableName}.attenuateIntersectionIterations = ${this.attenuateIntersectionIterations};`);\r\n codes.push(`${this._codeVariableName}.attenuateFacingCamera = ${this.attenuateFacingCamera};`);\r\n codes.push(`${this._codeVariableName}.attenuateBackfaceReflection = ${this.attenuateBackfaceReflection};`);\r\n codes.push(`${this._codeVariableName}.inputTextureColorIsInGammaSpace = ${this.inputTextureColorIsInGammaSpace};`);\r\n codes.push(`${this._codeVariableName}.generateOutputInGammaSpace = ${this.generateOutputInGammaSpace};`);\r\n return super._dumpPropertiesCode() + codes.join(\"\\n\");\r\n }\r\n\r\n public override serialize(): any {\r\n const serializationObject = super.serialize();\r\n serializationObject.debug = this.debug;\r\n serializationObject.strength = this.strength;\r\n serializationObject.reflectionSpecularFalloffExponent = this.reflectionSpecularFalloffExponent;\r\n serializationObject.reflectivityThreshold = this.reflectivityThreshold;\r\n serializationObject.thickness = this.thickness;\r\n serializationObject.step = this.step;\r\n serializationObject.enableSmoothReflections = this.enableSmoothReflections;\r\n serializationObject.maxSteps = this.maxSteps;\r\n serializationObject.maxDistance = this.maxDistance;\r\n serializationObject.roughnessFactor = this.roughnessFactor;\r\n serializationObject.selfCollisionNumSkip = this.selfCollisionNumSkip;\r\n serializationObject.ssrDownsample = this.ssrDownsample;\r\n serializationObject.clipToFrustum = this.clipToFrustum;\r\n serializationObject.useFresnel = this.useFresnel;\r\n serializationObject.enableAutomaticThicknessComputation = this.enableAutomaticThicknessComputation;\r\n serializationObject.blurDispersionStrength = this.blurDispersionStrength;\r\n serializationObject.blurDownsample = this.blurDownsample;\r\n serializationObject.attenuateScreenBorders = this.attenuateScreenBorders;\r\n serializationObject.attenuateIntersectionDistance = this.attenuateIntersectionDistance;\r\n serializationObject.attenuateIntersectionIterations = this.attenuateIntersectionIterations;\r\n serializationObject.attenuateFacingCamera = this.attenuateFacingCamera;\r\n serializationObject.attenuateBackfaceReflection = this.attenuateBackfaceReflection;\r\n serializationObject.inputTextureColorIsInGammaSpace = this.inputTextureColorIsInGammaSpace;\r\n serializationObject.generateOutputInGammaSpace = this.generateOutputInGammaSpace;\r\n return serializationObject;\r\n }\r\n\r\n public override _deserialize(serializationObject: any) {\r\n super._deserialize(serializationObject);\r\n this.debug = serializationObject.debug;\r\n this.strength = serializationObject.strength;\r\n this.reflectionSpecularFalloffExponent = serializationObject.reflectionSpecularFalloffExponent;\r\n this.reflectivityThreshold = serializationObject.reflectivityThreshold;\r\n this.thickness = serializationObject.thickness;\r\n this.step = serializationObject.step;\r\n this.enableSmoothReflections = serializationObject.enableSmoothReflections;\r\n this.maxSteps = serializationObject.maxSteps;\r\n this.maxDistance = serializationObject.maxDistance;\r\n this.roughnessFactor = serializationObject.roughnessFactor;\r\n this.selfCollisionNumSkip = serializationObject.selfCollisionNumSkip;\r\n this.ssrDownsample = serializationObject.ssrDownsample;\r\n this.clipToFrustum = serializationObject.clipToFrustum;\r\n this.useFresnel = serializationObject.useFresnel;\r\n this.enableAutomaticThicknessComputation = serializationObject.enableAutomaticThicknessComputation;\r\n this.blurDispersionStrength = serializationObject.blurDispersionStrength;\r\n this.blurDownsample = serializationObject.blurDownsample;\r\n this.attenuateScreenBorders = serializationObject.attenuateScreenBorders;\r\n this.attenuateIntersectionDistance = serializationObject.attenuateIntersectionDistance;\r\n this.attenuateIntersectionIterations = serializationObject.attenuateIntersectionIterations;\r\n this.attenuateFacingCamera = serializationObject.attenuateFacingCamera;\r\n this.attenuateBackfaceReflection = serializationObject.attenuateBackfaceReflection;\r\n this.inputTextureColorIsInGammaSpace = serializationObject.inputTextureColorIsInGammaSpace;\r\n this.generateOutputInGammaSpace = serializationObject.generateOutputInGammaSpace;\r\n }\r\n}\r\n\r\nRegisterClass(\"BABYLON.NodeRenderGraphSSRPostProcessBlock\", NodeRenderGraphSSRPostProcessBlock);\r\n"]}
@@ -39,6 +39,12 @@ export declare class NodeRenderGraphGeometryRendererBlock extends NodeRenderGrap
39
39
  /** Number of samples of the geometry texture */
40
40
  get samples(): number;
41
41
  set samples(value: number);
42
+ /** Indicates if culling must be reversed */
43
+ get reverseCulling(): boolean;
44
+ set reverseCulling(value: boolean);
45
+ /** Indicates if a mesh shouldn't be rendered when its material has depth write disabled */
46
+ get dontRenderWhenMaterialDepthWriteIsDisabled(): boolean;
47
+ set dontRenderWhenMaterialDepthWriteIsDisabled(value: boolean);
42
48
  viewDepthFormat: number;
43
49
  viewDepthType: number;
44
50
  screenDepthFormat: number;