@woosh/meep-engine 3.77.0 → 3.78.1

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 (227) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/README.md +1 -1
  3. package/package.json +3 -2
  4. package/src/engine/EngineHarness.d.ts +4 -6
  5. package/src/engine/EngineHarness.d.ts.map +1 -1
  6. package/src/engine/EngineHarness.js +11 -19
  7. package/src/engine/graphics3/GraphicsEngine.d.ts +19 -1
  8. package/src/engine/graphics3/GraphicsEngine.d.ts.map +1 -1
  9. package/src/engine/graphics3/GraphicsEngine.js +24 -2
  10. package/src/engine/physics/cloth/solver/cloth_step.d.ts.map +1 -1
  11. package/src/engine/physics/cloth/solver/cloth_step.js +4 -1
  12. package/src/engine/physics/cloth/solver/constraint/cloth_contact_row.d.ts +36 -2
  13. package/src/engine/physics/cloth/solver/constraint/cloth_contact_row.d.ts.map +1 -1
  14. package/src/engine/physics/cloth/solver/constraint/cloth_contact_row.js +60 -3
  15. package/src/engine/sound/sopra/runtime/EventInstance.d.ts +0 -1
  16. package/src/engine/sound/sopra/runtime/EventInstance.d.ts.map +1 -1
  17. package/src/engine/sound/sopra/runtime/EventInstance.js +0 -1
  18. package/src/shade/device/pipeline/ComputePipelineManager.d.ts +8 -0
  19. package/src/shade/device/pipeline/ComputePipelineManager.d.ts.map +1 -1
  20. package/src/shade/device/pipeline/ComputePipelineManager.js +18 -0
  21. package/src/shade/device/pipeline/RenderPipelineManager.d.ts +8 -0
  22. package/src/shade/device/pipeline/RenderPipelineManager.d.ts.map +1 -1
  23. package/src/shade/device/pipeline/RenderPipelineManager.js +17 -0
  24. package/src/shade/playground/avboit_footprint/index.html +20 -0
  25. package/src/shade/playground/avboit_footprint/main.d.ts +2 -0
  26. package/src/shade/playground/avboit_footprint/main.d.ts.map +1 -0
  27. package/src/shade/playground/avboit_footprint/main.js +428 -0
  28. package/src/shade/playground/probe_clipmap/main.d.ts.map +1 -1
  29. package/src/shade/playground/probe_clipmap/main.js +7 -3
  30. package/src/shade/playground/screen_probes/main.d.ts.map +1 -1
  31. package/src/shade/playground/screen_probes/main.js +7 -3
  32. package/src/shade/renderer/Renderer.d.ts +18 -8
  33. package/src/shade/renderer/Renderer.d.ts.map +1 -1
  34. package/src/shade/renderer/Renderer.js +201 -16
  35. package/src/shade/renderer/RendererConfiguration.d.ts +95 -0
  36. package/src/shade/renderer/RendererConfiguration.d.ts.map +1 -0
  37. package/src/shade/renderer/RendererConfiguration.js +119 -0
  38. package/src/shade/renderer/extension/ShadowAtlas.d.ts +4 -2
  39. package/src/shade/renderer/extension/ShadowAtlas.d.ts.map +1 -1
  40. package/src/shade/renderer/extension/ShadowAtlas.js +4 -2
  41. package/src/shade/renderer/geometry/sdf/GPUGeometrySDFManager.d.ts +8 -0
  42. package/src/shade/renderer/geometry/sdf/GPUGeometrySDFManager.d.ts.map +1 -1
  43. package/src/shade/renderer/geometry/sdf/GPUGeometrySDFManager.js +34 -0
  44. package/src/shade/renderer/geometry/sdf/surface/GPUMeshSurfaceCaches.d.ts +7 -0
  45. package/src/shade/renderer/geometry/sdf/surface/GPUMeshSurfaceCaches.d.ts.map +1 -1
  46. package/src/shade/renderer/geometry/sdf/surface/GPUMeshSurfaceCaches.js +15 -0
  47. package/src/shade/renderer/global_illumination/probe_clipmap/GPUProbeClipmapGI.d.ts +10 -2
  48. package/src/shade/renderer/global_illumination/probe_clipmap/GPUProbeClipmapGI.d.ts.map +1 -1
  49. package/src/shade/renderer/global_illumination/probe_clipmap/GPUProbeClipmapGI.js +37 -3
  50. package/src/shade/renderer/global_illumination/probe_clipmap/ProbeClipmapSettings.d.ts +6 -0
  51. package/src/shade/renderer/global_illumination/probe_clipmap/ProbeClipmapSettings.d.ts.map +1 -1
  52. package/src/shade/renderer/global_illumination/probe_clipmap/ProbeClipmapSettings.js +31 -0
  53. package/src/shade/renderer/global_illumination/probe_clipmap/brick/GPUBrickClipmap.d.ts +7 -0
  54. package/src/shade/renderer/global_illumination/probe_clipmap/brick/GPUBrickClipmap.d.ts.map +1 -1
  55. package/src/shade/renderer/global_illumination/probe_clipmap/brick/GPUBrickClipmap.js +20 -0
  56. package/src/shade/renderer/global_illumination/probe_clipmap/brick/GPUSceneBrickClipmap.d.ts +8 -0
  57. package/src/shade/renderer/global_illumination/probe_clipmap/brick/GPUSceneBrickClipmap.d.ts.map +1 -1
  58. package/src/shade/renderer/global_illumination/probe_clipmap/brick/GPUSceneBrickClipmap.js +14 -0
  59. package/src/shade/renderer/global_illumination/probe_clipmap/brick/mesh/MeshSDFBrickProvider.d.ts +7 -0
  60. package/src/shade/renderer/global_illumination/probe_clipmap/brick/mesh/MeshSDFBrickProvider.d.ts.map +1 -1
  61. package/src/shade/renderer/global_illumination/probe_clipmap/brick/mesh/MeshSDFBrickProvider.js +13 -0
  62. package/src/shade/renderer/global_illumination/probe_clipmap/material/GPUBrickMaterial.d.ts +6 -0
  63. package/src/shade/renderer/global_illumination/probe_clipmap/material/GPUBrickMaterial.d.ts.map +1 -1
  64. package/src/shade/renderer/global_illumination/probe_clipmap/material/GPUBrickMaterial.js +9 -0
  65. package/src/shade/renderer/global_illumination/probe_clipmap/probe/GPUProbeClipmap.d.ts +11 -0
  66. package/src/shade/renderer/global_illumination/probe_clipmap/probe/GPUProbeClipmap.d.ts.map +1 -1
  67. package/src/shade/renderer/global_illumination/probe_clipmap/probe/GPUProbeClipmap.js +71 -1
  68. package/src/shade/renderer/global_illumination/probe_clipmap/probe/ProbeClipmapHitWants.d.ts +6 -0
  69. package/src/shade/renderer/global_illumination/probe_clipmap/probe/ProbeClipmapHitWants.d.ts.map +1 -1
  70. package/src/shade/renderer/global_illumination/probe_clipmap/probe/ProbeClipmapHitWants.js +9 -0
  71. package/src/shade/renderer/global_illumination/probe_clipmap/probe/ProbeClipmapScreenWants.d.ts +6 -0
  72. package/src/shade/renderer/global_illumination/probe_clipmap/probe/ProbeClipmapScreenWants.d.ts.map +1 -1
  73. package/src/shade/renderer/global_illumination/probe_clipmap/probe/ProbeClipmapScreenWants.js +9 -0
  74. package/src/shade/renderer/global_illumination/probe_clipmap/probe/graph_probe_clipmap_want_meshlets.d.ts +6 -0
  75. package/src/shade/renderer/global_illumination/probe_clipmap/probe/graph_probe_clipmap_want_meshlets.d.ts.map +1 -1
  76. package/src/shade/renderer/global_illumination/probe_clipmap/probe/graph_probe_clipmap_want_meshlets.js +13 -0
  77. package/src/shade/renderer/global_illumination/screen_probe/GPUScreenProbeGI.d.ts +9 -0
  78. package/src/shade/renderer/global_illumination/screen_probe/GPUScreenProbeGI.d.ts.map +1 -1
  79. package/src/shade/renderer/global_illumination/screen_probe/GPUScreenProbeGI.js +47 -0
  80. package/src/shade/renderer/global_illumination/screen_probe/ScreenProbeSettings.d.ts +6 -0
  81. package/src/shade/renderer/global_illumination/screen_probe/ScreenProbeSettings.d.ts.map +1 -1
  82. package/src/shade/renderer/global_illumination/screen_probe/ScreenProbeSettings.js +17 -0
  83. package/src/shade/renderer/hair/hair_shadow_draw.d.ts +2 -2
  84. package/src/shade/renderer/hair/hair_shadow_draw.js +2 -2
  85. package/src/shade/renderer/particles/GPUParticleSystem.d.ts +8 -0
  86. package/src/shade/renderer/particles/GPUParticleSystem.d.ts.map +1 -1
  87. package/src/shade/renderer/particles/GPUParticleSystem.js +20 -1
  88. package/src/shade/renderer/particles/bounds/graph_particle_bounds.d.ts +6 -0
  89. package/src/shade/renderer/particles/bounds/graph_particle_bounds.d.ts.map +1 -1
  90. package/src/shade/renderer/particles/bounds/graph_particle_bounds.js +11 -1
  91. package/src/shade/renderer/particles/coherence/graph_particle_bucket.d.ts +6 -0
  92. package/src/shade/renderer/particles/coherence/graph_particle_bucket.d.ts.map +1 -1
  93. package/src/shade/renderer/particles/coherence/graph_particle_bucket.js +15 -0
  94. package/src/shade/renderer/particles/graph_particles.d.ts +8 -0
  95. package/src/shade/renderer/particles/graph_particles.d.ts.map +1 -1
  96. package/src/shade/renderer/particles/graph_particles.js +28 -3
  97. package/src/shade/renderer/particles/graph_particles_avboit.d.ts +7 -0
  98. package/src/shade/renderer/particles/graph_particles_avboit.d.ts.map +1 -1
  99. package/src/shade/renderer/particles/graph_particles_avboit.js +14 -0
  100. package/src/shade/renderer/particles/shaders/shader_particle_avboit_draw.d.ts.map +1 -1
  101. package/src/shade/renderer/particles/shaders/shader_particle_avboit_draw.js +5 -7
  102. package/src/shade/renderer/particles/warmup/graph_particle_warmup.d.ts +7 -0
  103. package/src/shade/renderer/particles/warmup/graph_particle_warmup.d.ts.map +1 -1
  104. package/src/shade/renderer/particles/warmup/graph_particle_warmup.js +15 -0
  105. package/src/shade/renderer/path_tracer/accumulating/AccumulatingPathTracer.d.ts +6 -0
  106. package/src/shade/renderer/path_tracer/accumulating/AccumulatingPathTracer.d.ts.map +1 -1
  107. package/src/shade/renderer/path_tracer/accumulating/AccumulatingPathTracer.js +16 -2
  108. package/src/shade/renderer/path_tracer/accumulating/graph_float32rgba_to_float16rgba.d.ts +6 -0
  109. package/src/shade/renderer/path_tracer/accumulating/graph_float32rgba_to_float16rgba.d.ts.map +1 -1
  110. package/src/shade/renderer/path_tracer/accumulating/graph_float32rgba_to_float16rgba.js +9 -0
  111. package/src/shade/renderer/path_tracer/accumulating/graph_flood_fill.d.ts +11 -0
  112. package/src/shade/renderer/path_tracer/accumulating/graph_flood_fill.d.ts.map +1 -1
  113. package/src/shade/renderer/path_tracer/accumulating/graph_flood_fill.js +10 -0
  114. package/src/shade/renderer/postprocess/dof/gather/DepthOfFieldU.d.ts +6 -0
  115. package/src/shade/renderer/postprocess/dof/gather/DepthOfFieldU.d.ts.map +1 -1
  116. package/src/shade/renderer/postprocess/dof/gather/DepthOfFieldU.js +10 -1
  117. package/src/shade/renderer/postprocess/dof/gather/graph_postprocess_dof2.d.ts +7 -0
  118. package/src/shade/renderer/postprocess/dof/gather/graph_postprocess_dof2.d.ts.map +1 -1
  119. package/src/shade/renderer/postprocess/dof/gather/graph_postprocess_dof2.js +21 -0
  120. package/src/shade/renderer/postprocess/dof/raymarch/DepthOfField.d.ts +7 -0
  121. package/src/shade/renderer/postprocess/dof/raymarch/DepthOfField.d.ts.map +1 -1
  122. package/src/shade/renderer/postprocess/dof/raymarch/DepthOfField.js +11 -1
  123. package/src/shade/renderer/postprocess/dof/raymarch/graph_postprocess_dof.d.ts +9 -0
  124. package/src/shade/renderer/postprocess/dof/raymarch/graph_postprocess_dof.d.ts.map +1 -1
  125. package/src/shade/renderer/postprocess/dof/raymarch/graph_postprocess_dof.js +29 -0
  126. package/src/shade/renderer/postprocess/motion_blur/MotionBlur.d.ts +6 -0
  127. package/src/shade/renderer/postprocess/motion_blur/MotionBlur.d.ts.map +1 -1
  128. package/src/shade/renderer/postprocess/motion_blur/MotionBlur.js +13 -1
  129. package/src/shade/renderer/postprocess/motion_blur/graph_postprocess_motion_blur.d.ts +6 -0
  130. package/src/shade/renderer/postprocess/motion_blur/graph_postprocess_motion_blur.d.ts.map +1 -1
  131. package/src/shade/renderer/postprocess/motion_blur/graph_postprocess_motion_blur.js +11 -0
  132. package/src/shade/renderer/postprocess/nss/NSS.d.ts +9 -0
  133. package/src/shade/renderer/postprocess/nss/NSS.d.ts.map +1 -1
  134. package/src/shade/renderer/postprocess/nss/NSS.js +33 -18
  135. package/src/shade/renderer/postprocess/ssr/SSR.d.ts +8 -0
  136. package/src/shade/renderer/postprocess/ssr/SSR.d.ts.map +1 -1
  137. package/src/shade/renderer/postprocess/ssr/SSR.js +42 -2
  138. package/src/shade/renderer/postprocess/ssr/ssr_graph_denoise_tiles.d.ts +6 -0
  139. package/src/shade/renderer/postprocess/ssr/ssr_graph_denoise_tiles.d.ts.map +1 -1
  140. package/src/shade/renderer/postprocess/ssr/ssr_graph_denoise_tiles.js +10 -0
  141. package/src/shade/renderer/postprocess/ssr/ssr_graph_prefilter_color.d.ts +6 -0
  142. package/src/shade/renderer/postprocess/ssr/ssr_graph_prefilter_color.d.ts.map +1 -1
  143. package/src/shade/renderer/postprocess/ssr/ssr_graph_prefilter_color.js +11 -0
  144. package/src/shade/renderer/rasterize/bucket/prepare_meshlet_draw_commands_by_material.d.ts +8 -0
  145. package/src/shade/renderer/rasterize/bucket/prepare_meshlet_draw_commands_by_material.d.ts.map +1 -1
  146. package/src/shade/renderer/rasterize/bucket/prepare_meshlet_draw_commands_by_material.js +27 -3
  147. package/src/shade/renderer/rasterize/draw/chunk_meshlet_draw_vertex.d.ts +7 -4
  148. package/src/shade/renderer/rasterize/draw/chunk_meshlet_draw_vertex.d.ts.map +1 -1
  149. package/src/shade/renderer/rasterize/draw/chunk_meshlet_draw_vertex.js +66 -14
  150. package/src/shade/renderer/rasterize/native/avboit/AVBOITSettings.d.ts +6 -0
  151. package/src/shade/renderer/rasterize/native/avboit/AVBOITSettings.d.ts.map +1 -1
  152. package/src/shade/renderer/rasterize/native/avboit/AVBOITSettings.js +10 -0
  153. package/src/shade/renderer/rasterize/native/avboit/AVBOITSideChannel.d.ts +5 -4
  154. package/src/shade/renderer/rasterize/native/avboit/AVBOITSideChannel.d.ts.map +1 -1
  155. package/src/shade/renderer/rasterize/native/avboit/AVBOITSideChannel.js +5 -4
  156. package/src/shade/renderer/rasterize/native/avboit/AVBOIT_CONSTANTS.d.ts +3 -3
  157. package/src/shade/renderer/rasterize/native/avboit/AVBOIT_CONSTANTS.js +3 -3
  158. package/src/shade/renderer/rasterize/native/avboit/avboit_draw_fragment_body.d.ts.map +1 -1
  159. package/src/shade/renderer/rasterize/native/avboit/avboit_draw_fragment_body.js +5 -7
  160. package/src/shade/renderer/rasterize/native/avboit/avboit_unlit_draw.d.ts.map +1 -1
  161. package/src/shade/renderer/rasterize/native/avboit/avboit_unlit_draw.js +5 -7
  162. package/src/shade/renderer/rasterize/native/avboit/chunk_avboit_footprint_depth.d.ts +34 -0
  163. package/src/shade/renderer/rasterize/native/avboit/chunk_avboit_footprint_depth.d.ts.map +1 -0
  164. package/src/shade/renderer/rasterize/native/avboit/chunk_avboit_footprint_depth.js +42 -0
  165. package/src/shade/renderer/rasterize/native/avboit/chunk_avboit_integral_depth_coordinate.d.ts +5 -4
  166. package/src/shade/renderer/rasterize/native/avboit/chunk_avboit_integral_depth_coordinate.d.ts.map +1 -1
  167. package/src/shade/renderer/rasterize/native/avboit/chunk_avboit_integral_depth_coordinate.js +8 -7
  168. package/src/shade/renderer/rasterize/native/avboit/chunk_avboit_sample_transmittance.d.ts +2 -2
  169. package/src/shade/renderer/rasterize/native/avboit/chunk_avboit_sample_transmittance.d.ts.map +1 -1
  170. package/src/shade/renderer/rasterize/native/avboit/chunk_avboit_sample_transmittance.js +4 -5
  171. package/src/shade/renderer/rasterize/native/avboit/graph_rasterize_meshes_transparent_avboit.d.ts +9 -0
  172. package/src/shade/renderer/rasterize/native/avboit/graph_rasterize_meshes_transparent_avboit.d.ts.map +1 -1
  173. package/src/shade/renderer/rasterize/native/avboit/graph_rasterize_meshes_transparent_avboit.js +18 -0
  174. package/src/shade/renderer/rasterize/native/depth/shadow_cascade_rasterization_pass_descriptor.d.ts +20 -0
  175. package/src/shade/renderer/rasterize/native/depth/shadow_cascade_rasterization_pass_descriptor.d.ts.map +1 -0
  176. package/src/shade/renderer/rasterize/native/depth/shadow_cascade_rasterization_pass_descriptor.js +149 -0
  177. package/src/shade/renderer/rasterize/native/depth/shadow_rasterization_alpha_tested_pass_descriptor.d.ts +8 -0
  178. package/src/shade/renderer/rasterize/native/depth/shadow_rasterization_alpha_tested_pass_descriptor.d.ts.map +1 -1
  179. package/src/shade/renderer/rasterize/native/depth/shadow_rasterization_alpha_tested_pass_descriptor.js +100 -33
  180. package/src/shade/renderer/rasterize/native/oit/graph_rasterize_meshes_transparent_oit.d.ts +9 -0
  181. package/src/shade/renderer/rasterize/native/oit/graph_rasterize_meshes_transparent_oit.d.ts.map +1 -1
  182. package/src/shade/renderer/rasterize/native/oit/graph_rasterize_meshes_transparent_oit.js +15 -0
  183. package/src/shade/renderer/rasterize/native/rasterization_shader_resources.d.ts +11 -0
  184. package/src/shade/renderer/rasterize/native/rasterization_shader_resources.d.ts.map +1 -1
  185. package/src/shade/renderer/rasterize/native/rasterization_shader_resources.js +24 -11
  186. package/src/shade/renderer/restir/di/ReSTIRDI.d.ts +6 -0
  187. package/src/shade/renderer/restir/di/ReSTIRDI.d.ts.map +1 -1
  188. package/src/shade/renderer/restir/di/ReSTIRDI.js +10 -1
  189. package/src/shade/renderer/restir/di/graph_restir_di.d.ts +9 -0
  190. package/src/shade/renderer/restir/di/graph_restir_di.d.ts.map +1 -1
  191. package/src/shade/renderer/restir/di/graph_restir_di.js +19 -1
  192. package/src/shade/renderer/restir/di/graph_restir_di_denoise.d.ts +6 -0
  193. package/src/shade/renderer/restir/di/graph_restir_di_denoise.d.ts.map +1 -1
  194. package/src/shade/renderer/restir/di/graph_restir_di_denoise.js +9 -0
  195. package/src/shade/renderer/scene/movers/graph_scene_movers.d.ts +7 -0
  196. package/src/shade/renderer/scene/movers/graph_scene_movers.d.ts.map +1 -1
  197. package/src/shade/renderer/scene/movers/graph_scene_movers.js +11 -0
  198. package/src/shade/renderer/shader/chunk/geometry/meshlet/chunk_read_meshlet_vertex_normal.d.ts +13 -0
  199. package/src/shade/renderer/shader/chunk/geometry/meshlet/chunk_read_meshlet_vertex_normal.d.ts.map +1 -0
  200. package/src/shade/renderer/shader/chunk/geometry/meshlet/chunk_read_meshlet_vertex_normal.js +42 -0
  201. package/src/shade/renderer/shadow/map/GPUSceneShadowmapContext.d.ts +10 -0
  202. package/src/shade/renderer/shadow/map/GPUSceneShadowmapContext.d.ts.map +1 -1
  203. package/src/shade/renderer/shadow/map/GPUSceneShadowmapContext.js +39 -6
  204. package/src/shade/renderer/shadow/map/shader/chunk_sample_shadowmap_cascade.d.ts +34 -0
  205. package/src/shade/renderer/shadow/map/shader/chunk_sample_shadowmap_cascade.d.ts.map +1 -0
  206. package/src/shade/renderer/shadow/map/shader/chunk_sample_shadowmap_cascade.js +106 -0
  207. package/src/shade/renderer/shadow/map/shader/chunk_shadow_cascade_caster_position.d.ts +16 -0
  208. package/src/shade/renderer/shadow/map/shader/chunk_shadow_cascade_caster_position.d.ts.map +1 -0
  209. package/src/shade/renderer/shadow/map/shader/chunk_shadow_cascade_caster_position.js +50 -0
  210. package/src/shade/renderer/shadow/map/shader/chunk_shadow_caster_depth_bias.d.ts +25 -0
  211. package/src/shade/renderer/shadow/map/shader/chunk_shadow_caster_depth_bias.d.ts.map +1 -0
  212. package/src/shade/renderer/shadow/map/shader/chunk_shadow_caster_depth_bias.js +42 -0
  213. package/src/shade/renderer/shadow/map/shader/chunk_shadowmap_sample_directional_cascades.d.ts +1 -1
  214. package/src/shade/renderer/shadow/map/shader/chunk_shadowmap_sample_directional_cascades.js +5 -5
  215. package/src/shade/renderer/shadow/vsm/graph_vsm_feedback.d.ts +7 -0
  216. package/src/shade/renderer/shadow/vsm/graph_vsm_feedback.d.ts.map +1 -1
  217. package/src/shade/renderer/shadow/vsm/graph_vsm_feedback.js +14 -0
  218. package/src/shade/renderer/text/shaders/shader_text_avboit.d.ts.map +1 -1
  219. package/src/shade/renderer/text/shaders/shader_text_avboit.js +5 -7
  220. package/src/shade/renderer/volumetrics/irradiance_clipmap/GPUIrradianceClipmap.d.ts +9 -1
  221. package/src/shade/renderer/volumetrics/irradiance_clipmap/GPUIrradianceClipmap.d.ts.map +1 -1
  222. package/src/shade/renderer/volumetrics/irradiance_clipmap/GPUIrradianceClipmap.js +16 -1
  223. package/src/shade/renderer/water/shader_water_avboit.d.ts.map +1 -1
  224. package/src/shade/renderer/water/shader_water_avboit.js +16 -13
  225. package/src/shade/renderer/rasterize/native/avboit/chunk_avboit_footprint_bias.d.ts +0 -33
  226. package/src/shade/renderer/rasterize/native/avboit/chunk_avboit_footprint_bias.d.ts.map +0 -1
  227. package/src/shade/renderer/rasterize/native/avboit/chunk_avboit_footprint_bias.js +0 -45
@@ -1,3 +1,10 @@
1
+ /**
2
+ * Offer the pipelines {@link graph_vsm_feedback} dispatches — see {@link PipelineEnquiry}. The scene's mover list
3
+ * it reads is recorded with pipelines of its own, for whoever turns virtual shadow maps on to offer beside these.
4
+ *
5
+ * @param {import("../../../device/pipeline/PipelineEnquiry.js").PipelineEnquiry} enquiry
6
+ */
7
+ export function enquire_vsm_feedback_pipelines(enquiry: import("../../../device/pipeline/PipelineEnquiry.js").PipelineEnquiry): void;
1
8
  /**
2
9
  * Record a frame's virtual shadow map feedback into the `Shading` graph, once the main view's depth
3
10
  * exists, and read it back.
@@ -1 +1 @@
1
- {"version":3,"file":"graph_vsm_feedback.d.ts","sourceRoot":"","sources":["../../../../../../src/shade/renderer/shadow/vsm/graph_vsm_feedback.js"],"names":[],"mappings":"AAiBA;;;;;;;;;;;;;;;;;;;;GAoBG;AACH;IAP+B,KAAK;IACsC,IAAI,EAAnE,OAAO,8BAA8B,EAAE,cAAc;IACrC,KAAK,EAArB,MAAM;IACsB,IAAI,EAAhC,kBAAkB;IACF,MAAM,EAAtB,MAAM;IACe,cAAc;SAwB7C;AApDD;;;;;;GAMG;AACH,sCAFU,MAAM,CAEyB"}
1
+ {"version":3,"file":"graph_vsm_feedback.d.ts","sourceRoot":"","sources":["../../../../../../src/shade/renderer/shadow/vsm/graph_vsm_feedback.js"],"names":[],"mappings":"AAiBA;;;;;GAKG;AACH,wDAFW,OAAO,6CAA6C,EAAE,eAAe,QAQ/E;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH;IAP+B,KAAK;IACsC,IAAI,EAAnE,OAAO,8BAA8B,EAAE,cAAc;IACrC,KAAK,EAArB,MAAM;IACsB,IAAI,EAAhC,kBAAkB;IACF,MAAM,EAAtB,MAAM;IACe,cAAc;SAwB7C;AAlED;;;;;;GAMG;AACH,sCAFU,MAAM,CAEyB"}
@@ -15,6 +15,20 @@ import { vsm_feedback_word_count } from "./VSM_FEEDBACK_LAYOUT.js";
15
15
  */
16
16
  export const VSM_READBACKS_IN_FLIGHT = 3;
17
17
 
18
+ /**
19
+ * Offer the pipelines {@link graph_vsm_feedback} dispatches — see {@link PipelineEnquiry}. The scene's mover list
20
+ * it reads is recorded with pipelines of its own, for whoever turns virtual shadow maps on to offer beside these.
21
+ *
22
+ * @param {import("../../../device/pipeline/PipelineEnquiry.js").PipelineEnquiry} enquiry
23
+ */
24
+ export function enquire_vsm_feedback_pipelines(enquiry) {
25
+ enquiry.compute.push(shader_vsm_stale_args.pipeline);
26
+ enquiry.compute.push(shader_vsm_stale.pipeline);
27
+ enquiry.compute.push(shader_vsm_demand.pipeline);
28
+ enquiry.compute.push(shader_vsm_gather_counts.pipeline);
29
+ enquiry.compute.push(shader_vsm_stale_compact.pipeline);
30
+ }
31
+
18
32
  /**
19
33
  * Record a frame's virtual shadow map feedback into the `Shading` graph, once the main view's depth
20
34
  * exists, and read it back.
@@ -1 +1 @@
1
- {"version":3,"file":"shader_text_avboit.d.ts","sourceRoot":"","sources":["../../../../../../src/shade/renderer/text/shaders/shader_text_avboit.js"],"names":[],"mappings":"AAuBA;;;GAGG;AACH,2CAFU,MAAM,CAE8B;AAuH9C,4IAIG;AAEH,sEAA2D;AAE3D,yDAAyD;AACzD,wDAAyD;AAuFzD,2IAIG;AAEH,qEAAyD;AAEzD,wDAAwD;AACxD,uDAAuD;4CAxOX,sDAAsD;iCACjE,kCAAkC"}
1
+ {"version":3,"file":"shader_text_avboit.d.ts","sourceRoot":"","sources":["../../../../../../src/shade/renderer/text/shaders/shader_text_avboit.js"],"names":[],"mappings":"AAsBA;;;GAGG;AACH,2CAFU,MAAM,CAE8B;AAuH9C,4IAIG;AAEH,sEAA2D;AAE3D,yDAAyD;AACzD,wDAAyD;AAsFzD,2IAIG;AAEH,qEAAyD;AAEzD,wDAAwD;AACxD,uDAAuD;4CAvOX,sDAAsD;iCACjE,kCAAkC"}
@@ -8,13 +8,12 @@ import {
8
8
  AVBOIT_UNLIT_SPLAT_SAMPLES
9
9
  } from "../../rasterize/native/avboit/avboit_unlit_splat.js";
10
10
  import { chunk_avboit_coverage } from "../../rasterize/native/avboit/chunk_avboit_coverage.js";
11
- import { chunk_avboit_footprint_bias } from "../../rasterize/native/avboit/chunk_avboit_footprint_bias.js";
11
+ import { chunk_avboit_footprint_depth } from "../../rasterize/native/avboit/chunk_avboit_footprint_depth.js";
12
12
  import { chunk_avboit_premultiplied_contribution } from "../../rasterize/native/avboit/chunk_avboit_premultiplied_contribution.js";
13
13
  import { chunk_avboit_sample_transmittance } from "../../rasterize/native/avboit/chunk_avboit_sample_transmittance.js";
14
14
  import { chunk_avboit_splat_slice } from "../../rasterize/native/avboit/chunk_avboit_splat_slice.js";
15
15
  import { chunk_avboit_transmittance_to_extinction } from "../../rasterize/native/avboit/chunk_avboit_transmittance_to_extinction.js";
16
16
  import { chunk_avboit_view_depth_to_physical } from "../../rasterize/native/avboit/chunk_avboit_view_depth_to_physical.js";
17
- import { chunk_avboit_view_depth_to_virtual } from "../../rasterize/native/avboit/chunk_avboit_view_depth_to_virtual.js";
18
17
  import { AVBOIT_SPLAT_VOLUME_GROUP } from "../../rasterize/native/avboit/shader_avboit_splat.js";
19
18
  import { CodeChunk } from "../../shader/compiler/CodeChunk.js";
20
19
  import { ShaderResourceSetDescriptor } from "../../shader/resource/ShaderResourceSetDescriptor.js";
@@ -187,8 +186,8 @@ fn vs_main(@builtin(vertex_index) vertex_index : u32, @builtin(instance_index) i
187
186
  @fragment
188
187
  fn fs_main(fragment : TextAVBOITVaryings) -> TextAVBOITDrawOutput {
189
188
  // both taken first, in uniform control flow. A text seen at an angle runs through depth across a voxel; see
190
- // avboit_footprint_bias
191
- let footprint = avboit_footprint_bias(&warp, fwidth(avboit_view_depth_to_virtual(&warp, fragment.view_depth)));
189
+ // avboit_footprint_depth
190
+ let footprint = avboit_footprint_depth(fragment.view_depth, fwidth(1.0 / fragment.view_depth));
192
191
  let pixels_per_unit = 1.0 / fwidth(fragment.position);
193
192
 
194
193
  let cover = contour_fill_coverage(
@@ -206,7 +205,7 @@ fn fs_main(fragment : TextAVBOITVaryings) -> TextAVBOITDrawOutput {
206
205
 
207
206
  let screen_uv = fragment.clip.xy / vec2<f32>(f32(view.width), f32(view.height));
208
207
 
209
- let transmittance = avboit_sample_transmittance(&warp, tIntegral, sLinear, screen_uv, fragment.view_depth, footprint);
208
+ let transmittance = avboit_sample_transmittance(&warp, tIntegral, sLinear, screen_uv, footprint);
210
209
 
211
210
  if (all(transmittance <= vec3<f32>(${AVBOIT_EXTINCT_TRANSMITTANCE}))) {
212
211
  // nothing this fragment contributes survives what is in front of it
@@ -231,8 +230,7 @@ fn fs_main(fragment : TextAVBOITVaryings) -> TextAVBOITDrawOutput {
231
230
  `, [
232
231
  chunk_text_avboit_varyings,
233
232
  chunk_contour_fill_coverage,
234
- chunk_avboit_view_depth_to_virtual,
235
- chunk_avboit_footprint_bias,
233
+ chunk_avboit_footprint_depth,
236
234
  chunk_avboit_sample_transmittance,
237
235
  chunk_sample_volumetrics,
238
236
  chunk_avboit_premultiplied_contribution,
@@ -27,6 +27,14 @@ export class GPUIrradianceClipmap {
27
27
  cell_size?: number;
28
28
  blend_skirt?: number;
29
29
  });
30
+ /**
31
+ * Offer the pipelines {@link graph_update} dispatches — see {@link PipelineEnquiry}. For whoever reads the
32
+ * clipmap: a frame nothing reads it in culls its build.
33
+ *
34
+ * @param {import("../../../device/pipeline/PipelineEnquiry.js").PipelineEnquiry} enquiry
35
+ * @param {ShaderSwitchSet} shader_switches the renderer's, which the build is made for
36
+ */
37
+ enquirePipelines(enquiry: import("../../../device/pipeline/PipelineEnquiry.js").PipelineEnquiry, shader_switches: ShaderSwitchSet): void;
30
38
  /**
31
39
  * @returns {GPUTileAtlas3D}
32
40
  */
@@ -111,7 +119,7 @@ export class GPUIrradianceClipmap {
111
119
  #private;
112
120
  }
113
121
  export type GPUTextureContext = import("../../texture/GPUTextureContext.js").GPUTextureContext;
122
+ import { ShaderSwitchSet } from "../../shader/compiler/ShaderSwitchSet.js";
114
123
  import { GPUTileAtlas3D } from "../../texture/atlas/GPUTileAtlas3D.js";
115
124
  import { IrradianceCascadePlacement } from "./IrradianceCascadePlacement.js";
116
- import { ShaderSwitchSet } from "../../shader/compiler/ShaderSwitchSet.js";
117
125
  //# sourceMappingURL=GPUIrradianceClipmap.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"GPUIrradianceClipmap.d.ts","sourceRoot":"","sources":["../../../../../../src/shade/renderer/volumetrics/irradiance_clipmap/GPUIrradianceClipmap.js"],"names":[],"mappings":"AAiDA;;;;;;;;;;;;;GAaG;AACH;IA2CI;;;;;;;OAOG;IACH;QAL4B,aAAa,GAA9B,MAAM;QAC6B,UAAU,GAA7C,MAAM,GAAC,UAAU,MAAM,CAAC;QACP,SAAS,GAA1B,MAAM;QACW,WAAW,GAA5B,MAAM;OA+DhB;IAED;;OAEG;IACH,4BAEC;IAED;;OAEG;IACH,gFAEC;IAED;;OAEG;IACH,mFAEC;IAED;;OAEG;IACH,yBAEC;IAED;;OAEG;IACH,4BAEC;IAED;;;OAGG;IACH,0BAEC;IAED;;OAEG;IACH,4CAEC;IAED;;OAEG;IACH,uBAEC;IAED;;;;;;;;OAQG;IACH,oBALW,MAAM,KACN,MAAM,KACN,MAAM,oBACN,eAAe,QAgFzB;IAED;;;;;;;;;;;;;;;;;;;OAmBG;IACH;QAXsG,KAAK,EAAhG,OAAO,8DAA8D,EAAE,UAAU;QACZ,MAAM,EAA3E,OAAO,kCAAkC,EAAE,gBAAgB;QACO,SAAS,EAA3E,OAAO,gCAAgC,EAAE,eAAe;QACxC,eAAe,EAA/B,MAAM;QACoB,eAAe,GAAzC,eAAe;QACuE,MAAM,GAA5F,OAAO,oDAAoD,EAAE,cAAc;QACuB,MAAM,EAAxG,OAAO,8DAA8D,EAAE,iBAAiB;QAErE,YAAY;QAC7B;QAAC,CAAC,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAC,CA2ItD;IAED;;OAEG;IACH,gBAQC;;CACJ;gCAheY,OAAO,oCAAoC,EAAE,iBAAiB;+BAJ5C,uCAAuC;2CAmB3B,iCAAiC;gCAxB5C,0CAA0C"}
1
+ {"version":3,"file":"GPUIrradianceClipmap.d.ts","sourceRoot":"","sources":["../../../../../../src/shade/renderer/volumetrics/irradiance_clipmap/GPUIrradianceClipmap.js"],"names":[],"mappings":"AAoDA;;;;;;;;;;;;;GAaG;AACH;IAuDI;;;;;;;OAOG;IACH;QAL4B,aAAa,GAA9B,MAAM;QAC6B,UAAU,GAA7C,MAAM,GAAC,UAAU,MAAM,CAAC;QACP,SAAS,GAA1B,MAAM;QACW,WAAW,GAA5B,MAAM;OA+DhB;IAxHD;;;;;;OAMG;IACH,0BAHW,OAAO,6CAA6C,EAAE,eAAe,mBACrE,eAAe,QAKzB;IAgHD;;OAEG;IACH,4BAEC;IAED;;OAEG;IACH,gFAEC;IAED;;OAEG;IACH,mFAEC;IAED;;OAEG;IACH,yBAEC;IAED;;OAEG;IACH,4BAEC;IAED;;;OAGG;IACH,0BAEC;IAED;;OAEG;IACH,4CAEC;IAED;;OAEG;IACH,uBAEC;IAED;;;;;;;;OAQG;IACH,oBALW,MAAM,KACN,MAAM,KACN,MAAM,oBACN,eAAe,QAgFzB;IAED;;;;;;;;;;;;;;;;;;;OAmBG;IACH;QAXsG,KAAK,EAAhG,OAAO,8DAA8D,EAAE,UAAU;QACZ,MAAM,EAA3E,OAAO,kCAAkC,EAAE,gBAAgB;QACO,SAAS,EAA3E,OAAO,gCAAgC,EAAE,eAAe;QACxC,eAAe,EAA/B,MAAM;QACoB,eAAe,GAAzC,eAAe;QACuE,MAAM,GAA5F,OAAO,oDAAoD,EAAE,cAAc;QACuB,MAAM,EAAxG,OAAO,8DAA8D,EAAE,iBAAiB;QAErE,YAAY;QAC7B;QAAC,CAAC,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,CAAA;KAAC,CA2ItD;IAED;;OAEG;IACH,gBAQC;;CACJ;gCA5eY,OAAO,oCAAoC,EAAE,iBAAiB;gCAT3C,0CAA0C;+BAK3C,uCAAuC;2CAmB3B,iCAAiC"}
@@ -1,7 +1,10 @@
1
1
  import { assert } from "../../../../core/assert.js";
2
2
  import { fluid_cascade_ruler } from "../../fluid/fluid_cascade_ruler.js";
3
3
  import { INDIRECT_LIGHTING } from "../../INDIRECT_LIGHTING.js";
4
- import { graph_build_world_light_clusters } from "../../light/world_cluster/graph_build_world_light_clusters.js";
4
+ import {
5
+ enquire_build_world_light_clusters_pipelines,
6
+ graph_build_world_light_clusters
7
+ } from "../../light/world_cluster/graph_build_world_light_clusters.js";
5
8
  import { CLIPMAP_LEVEL_STRUCT } from "../../shader/chunk/clipmap/CLIPMAP_LEVEL_STRUCT.js";
6
9
  import { ShaderSwitchSet } from "../../shader/compiler/ShaderSwitchSet.js";
7
10
  import { graph_import_buffer } from "../../shader/graph/graph_import_buffer.js";
@@ -65,6 +68,18 @@ export class GPUIrradianceClipmap {
65
68
  /** @type {GPUDevice} */
66
69
  #device;
67
70
 
71
+ /**
72
+ * Offer the pipelines {@link graph_update} dispatches — see {@link PipelineEnquiry}. For whoever reads the
73
+ * clipmap: a frame nothing reads it in culls its build.
74
+ *
75
+ * @param {import("../../../device/pipeline/PipelineEnquiry.js").PipelineEnquiry} enquiry
76
+ * @param {ShaderSwitchSet} shader_switches the renderer's, which the build is made for
77
+ */
78
+ enquirePipelines(enquiry, shader_switches) {
79
+ enquire_build_world_light_clusters_pipelines(enquiry);
80
+ enquiry.compute.push(shader_irradiance_clipmap_build.variant(shader_switches).pipeline);
81
+ }
82
+
68
83
  /** @type {GPUTileAtlas3D} */
69
84
  #atlas;
70
85
 
@@ -1 +1 @@
1
- {"version":3,"file":"shader_water_avboit.d.ts","sourceRoot":"","sources":["../../../../../src/shade/renderer/water/shader_water_avboit.js"],"names":[],"mappings":"AAkCA,mDAwBG;AAQH,+CAqCG;AAUH,4CA4BG;AAOH,uDAYG;AAOH,6CAqCG;8BA3L2B,4BAA4B;4BAC9B,0BAA0B"}
1
+ {"version":3,"file":"shader_water_avboit.d.ts","sourceRoot":"","sources":["../../../../../src/shade/renderer/water/shader_water_avboit.js"],"names":[],"mappings":"AAiCA,mDAwBG;AAQH,+CAyCG;AAUH,4CA4BG;AAOH,uDAYG;AAOH,6CAqCG;8BA/L2B,4BAA4B;4BAC9B,0BAA0B"}
@@ -3,7 +3,7 @@ import { chunk_sample_volumetrics } from "../deferred/chunk_sample_volumetrics.j
3
3
  import { AVBOIT_OCCUPANCY_WORDS, AVBOIT_VOXEL_DOWNSCALE } from "../rasterize/native/avboit/AVBOIT_CONSTANTS.js";
4
4
  import { AVBOIT_WARP_STRUCT } from "../rasterize/native/avboit/AVBOIT_WARP_STRUCT.js";
5
5
  import { AVBOIT_DRAW_TARGETS } from "../rasterize/native/avboit/avboit_draw_fragment_body.js";
6
- import { chunk_avboit_footprint_bias } from "../rasterize/native/avboit/chunk_avboit_footprint_bias.js";
6
+ import { chunk_avboit_footprint_depth } from "../rasterize/native/avboit/chunk_avboit_footprint_depth.js";
7
7
  import { chunk_avboit_occupancy_mark } from "../rasterize/native/avboit/chunk_avboit_occupancy_mark.js";
8
8
  import { chunk_avboit_rgb_contribution } from "../rasterize/native/avboit/chunk_avboit_rgb_contribution.js";
9
9
  import { chunk_avboit_sample_transmittance } from "../rasterize/native/avboit/chunk_avboit_sample_transmittance.js";
@@ -11,7 +11,6 @@ import { chunk_avboit_splat_slice } from "../rasterize/native/avboit/chunk_avboi
11
11
  import { chunk_avboit_split_counts } from "../rasterize/native/avboit/chunk_avboit_split_counts.js";
12
12
  import { chunk_avboit_transmittance_to_extinction } from "../rasterize/native/avboit/chunk_avboit_transmittance_to_extinction.js";
13
13
  import { chunk_avboit_view_depth_to_physical } from "../rasterize/native/avboit/chunk_avboit_view_depth_to_physical.js";
14
- import { chunk_avboit_view_depth_to_virtual } from "../rasterize/native/avboit/chunk_avboit_view_depth_to_virtual.js";
15
14
  import { AVBOIT_OCCUPANCY_SETTINGS_STRUCT } from "../rasterize/native/avboit/shader_avboit_occupancy.js";
16
15
  import { chunk_get_view_space_depth } from "../shader/chunk/depth/chunk_get_view_space_depth.js";
17
16
  import { CodeChunk } from "../shader/compiler/CodeChunk.js";
@@ -75,7 +74,8 @@ fn main(@builtin(global_invocation_id) id: vec3u) {
75
74
  let hi = min(lo + vec2u(${AVBOIT_VOXEL_DOWNSCALE}u), size);
76
75
  var total_t = vec3f(0.0);
77
76
  var samples = 0.0;
78
- var nearest = 1e30;
77
+ var wet = 0.0;
78
+ var wet_depth = 0.0;
79
79
  for (var y = lo.y; y < hi.y; y++) {
80
80
  for (var x = lo.x; x < hi.x; x++) {
81
81
  let coord = vec2u(x, y);
@@ -83,16 +83,19 @@ fn main(@builtin(global_invocation_id) id: vec3u) {
83
83
  var t = vec3f(1.0);
84
84
  if (d > 0.0) {
85
85
  t = textureLoad(transmission, coord, 0).rgb;
86
- nearest = min(nearest, get_view_space_depth(d, camera));
86
+ wet += 1.0; wet_depth += d;
87
87
  }
88
88
  total_t += t; samples += 1.0;
89
89
  }
90
90
  }
91
- if (nearest == 1e30 || samples == 0.0) { return; }
92
- // One area-averaged event, not 64 full-coverage layers. Dry samples retain T=1.
91
+ if (wet == 0.0) { return; }
92
+ // One area-averaged event, not 64 full-coverage layers. Dry samples retain T=1. It goes where every
93
+ // source's does, at the depth under the column's centre (avboit_footprint_depth): device depth is linear
94
+ // across the screen for a plane, so the wet samples' mean is the surface's depth under their centre.
95
+ let z_splat = get_view_space_depth(wet_depth / wet, camera);
93
96
  let extinction = avboit_transmittance_to_extinction(total_t / samples);
94
97
  let counts = avboit_extinction_to_counts(extinction);
95
- let p = avboit_view_depth_to_physical(&warp, nearest) - 0.5;
98
+ let p = avboit_view_depth_to_physical(&warp, z_splat) - 0.5;
96
99
  let slice = i32(floor(p));
97
100
  let upper = avboit_split_counts(counts, fract(p));
98
101
  let column = id.y * warp.voxel_width + id.x;
@@ -124,19 +127,19 @@ fn main(@builtin(position) coord: vec4f) -> WaterContribution {
124
127
  let d = textureLoad(interface_depth, pixel, 0).r;
125
128
  let z = get_view_space_depth(d, camera);
126
129
  // the water splats into the volume too, and a plane seen at an angle runs through depth across a
127
- // voxel (avboit_footprint_bias). Taken before the discard, in uniform control flow; a dry pixel's
128
- // virtual coordinate clamps, so the derivative at the shore stays finite and the cap holds it
129
- let footprint = avboit_footprint_bias(&warp, fwidth(avboit_view_depth_to_virtual(&warp, z)));
130
+ // voxel (avboit_footprint_depth). Taken before the discard, in uniform control flow; a dry pixel's
131
+ // depth is the far plane's, so the derivative at the shore stays finite
132
+ let footprint = avboit_footprint_depth(z, fwidth(1.0 / z));
130
133
  if (d <= 0.0) { discard; }
131
134
  let uv = coord.xy / vec2f(textureDimensions(interface_depth, 0));
132
- let front = avboit_sample_transmittance(&warp, tIntegral, sLinear, uv, z, footprint);
135
+ let front = avboit_sample_transmittance(&warp, tIntegral, sLinear, uv, footprint);
133
136
  let t = textureLoad(transmission, pixel, 0).rgb;
134
137
  let w = textureLoad(radiance, pixel, 0).rgb;
135
138
  let fog = sample_volumetrics(z, uv, coord.xy);
136
139
  let c = avboit_rgb_contribution(w, t, front, fog);
137
140
  return WaterContribution(c.color, c.norm, c.extinction, c.emission);
138
141
  }
139
- `, [chunk_get_view_space_depth, chunk_avboit_view_depth_to_virtual, chunk_avboit_footprint_bias,
142
+ `, [chunk_get_view_space_depth, chunk_avboit_footprint_depth,
140
143
  chunk_avboit_sample_transmittance, chunk_avboit_rgb_contribution, chunk_sample_volumetrics]),
141
144
  }), targets: AVBOIT_DRAW_TARGETS,
142
145
  });
@@ -193,7 +196,7 @@ fn main(@builtin(position) coord: vec4f) -> @location(0) vec4f {
193
196
  let z = get_view_space_depth(textureLoad(interface_depth, pixel, 0).r, camera);
194
197
  // without the draw's footprint (a derivative this switch cannot take): where the water is
195
198
  // seen at an angle this also shows it occluding itself, which the draw looks past
196
- let front = avboit_sample_transmittance(&warp, tIntegral, sLinear, uv, z, 0.0);
199
+ let front = avboit_sample_transmittance(&warp, tIntegral, sLinear, uv, z);
197
200
  color = select(front, (1.0 - t.rgb) * front, inspection.mode == 9u);
198
201
  }
199
202
  default: {}
@@ -1,33 +0,0 @@
1
- /**
2
- * How much further toward the camera, in virtual slices, a fragment has to look the integral up so
3
- * that its own surface does not occlude it through the neighbouring voxel columns — given
4
- * `virtual_fwidth`, the fragment's `fwidth` of its virtual slice coordinate
5
- * (`avboit_view_depth_to_virtual`), which the caller takes in the fragment stage.
6
- *
7
- * The volume is 1/8 resolution and every column holds a surface at the depth under the column's
8
- * centre. The draw reads the four nearest columns bilinearly, up to one voxel away. On a surface
9
- * tilted away from the camera, the neighbour on its near side holds the same surface nearer by the
10
- * surface's depth change over that distance, and once that exceeds the two-slice base bias the
11
- * surface occludes itself — by an amount that depends on where the pixel sits in its voxel, so an
12
- * overlapping layer showed 8-pixel stripes (ledger entry 26: 3–5 sRGB codes on the device at 45–60°).
13
- * A voxel's width of the surface's own depth change, `AVBOIT_VOXEL_DOWNSCALE × fwidth`, covers the
14
- * farthest column the lookup reaches. The virtual coordinate is convex along a plane seen in
15
- * perspective, so its derivative at the fragment bounds the change toward the near side.
16
- *
17
- * What it costs: a tilted fragment is not occluded by what lies within that band in front of it, the
18
- * depth the volume cannot tell apart from the surface itself at this resolution. The band is capped at
19
- * the base bias of the coarsest slicing, `V / P` base biases — the separation every surface already
20
- * has whenever the volume is full and the warp halves down to `V = P` — so where the derivative runs
21
- * away, at a silhouette or a grazing angle, the extra a fragment ignores is never more than that. The
22
- * whole reach is the base bias plus the band: at most `2 + 2 V / P` virtual slices, twice the coarsest
23
- * separation when the volume is full, about the coarsest separation at `V = 4096`. Past the cap (about
24
- * 85° at 1080p in a sparse volume) the stripes can return.
25
- *
26
- * A fragment that writes nothing into the volume — an additive particle's — has nothing of its own there
27
- * to occlude it and takes no footprint.
28
- *
29
- * @type {CodeChunk}
30
- */
31
- export const chunk_avboit_footprint_bias: CodeChunk;
32
- import { CodeChunk } from "../../../shader/compiler/CodeChunk.js";
33
- //# sourceMappingURL=chunk_avboit_footprint_bias.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"chunk_avboit_footprint_bias.d.ts","sourceRoot":"","sources":["../../../../../../../src/shade/renderer/rasterize/native/avboit/chunk_avboit_footprint_bias.js"],"names":[],"mappings":"AAIA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,0CAFU,SAAS,CAYjB;0BA5CwB,uCAAuC"}
@@ -1,45 +0,0 @@
1
- import { CodeChunk } from "../../../shader/compiler/CodeChunk.js";
2
- import { AVBOIT_SAMPLE_BIAS_SLICES, AVBOIT_VOXEL_DOWNSCALE } from "./AVBOIT_CONSTANTS.js";
3
- import { AVBOIT_WARP_STRUCT } from "./AVBOIT_WARP_STRUCT.js";
4
-
5
- /**
6
- * How much further toward the camera, in virtual slices, a fragment has to look the integral up so
7
- * that its own surface does not occlude it through the neighbouring voxel columns — given
8
- * `virtual_fwidth`, the fragment's `fwidth` of its virtual slice coordinate
9
- * (`avboit_view_depth_to_virtual`), which the caller takes in the fragment stage.
10
- *
11
- * The volume is 1/8 resolution and every column holds a surface at the depth under the column's
12
- * centre. The draw reads the four nearest columns bilinearly, up to one voxel away. On a surface
13
- * tilted away from the camera, the neighbour on its near side holds the same surface nearer by the
14
- * surface's depth change over that distance, and once that exceeds the two-slice base bias the
15
- * surface occludes itself — by an amount that depends on where the pixel sits in its voxel, so an
16
- * overlapping layer showed 8-pixel stripes (ledger entry 26: 3–5 sRGB codes on the device at 45–60°).
17
- * A voxel's width of the surface's own depth change, `AVBOIT_VOXEL_DOWNSCALE × fwidth`, covers the
18
- * farthest column the lookup reaches. The virtual coordinate is convex along a plane seen in
19
- * perspective, so its derivative at the fragment bounds the change toward the near side.
20
- *
21
- * What it costs: a tilted fragment is not occluded by what lies within that band in front of it, the
22
- * depth the volume cannot tell apart from the surface itself at this resolution. The band is capped at
23
- * the base bias of the coarsest slicing, `V / P` base biases — the separation every surface already
24
- * has whenever the volume is full and the warp halves down to `V = P` — so where the derivative runs
25
- * away, at a silhouette or a grazing angle, the extra a fragment ignores is never more than that. The
26
- * whole reach is the base bias plus the band: at most `2 + 2 V / P` virtual slices, twice the coarsest
27
- * separation when the volume is full, about the coarsest separation at `V = 4096`. Past the cap (about
28
- * 85° at 1080p in a sparse volume) the stripes can return.
29
- *
30
- * A fragment that writes nothing into the volume — an additive particle's — has nothing of its own there
31
- * to occlude it and takes no footprint.
32
- *
33
- * @type {CodeChunk}
34
- */
35
- export const chunk_avboit_footprint_bias = CodeChunk.from(
36
- //language=WGSL
37
- `
38
- fn avboit_footprint_bias(warp: ptr<storage, ${AVBOIT_WARP_STRUCT.wgsl_ref}, read>, virtual_fwidth: f32) -> f32 {
39
- let cap = ${AVBOIT_SAMPLE_BIAS_SLICES.toFixed(1)} * f32((*warp).virtual_count) / f32(max((*warp).physical_count, 1u));
40
- return min(${AVBOIT_VOXEL_DOWNSCALE.toFixed(1)} * virtual_fwidth, cap);
41
- }
42
- `, [
43
- AVBOIT_WARP_STRUCT.declaration_chunk,
44
- ]
45
- );