@woosh/meep-engine 3.46.0 → 3.49.0

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 (827) hide show
  1. package/build/bundle-worker-terrain.js +1 -1
  2. package/editor/actions/concrete/TransformModifyAction.d.ts.map +1 -1
  3. package/editor/actions/concrete/TransformModifyAction.js +10 -2
  4. package/editor/ecs/component/FieldDescriptor.js +15 -0
  5. package/editor/ecs/component/createObjectEditor.js +41 -12
  6. package/editor/ecs/component/editors/ecs/Transform64Editor.d.ts.map +1 -1
  7. package/editor/ecs/component/editors/ecs/Transform64Editor.js +77 -70
  8. package/editor/particles/effect/ParticleReferenceSimulation.d.ts +1 -2
  9. package/editor/particles/effect/ParticleReferenceSimulation.d.ts.map +1 -1
  10. package/editor/particles/effect/ParticleReferenceSimulation.js +2 -4
  11. package/editor/tools/TransformToolV2.d.ts.map +1 -1
  12. package/editor/tools/TransformToolV2.js +4 -0
  13. package/editor/tools/v2/TransformControls.d.ts.map +1 -1
  14. package/editor/tools/v2/TransformControls.js +7 -0
  15. package/editor/view/ecs/EntityEditor.d.ts.map +1 -1
  16. package/editor/view/ecs/EntityEditor.js +4 -2
  17. package/editor/view/particles/effect/ParticleGraphEditorView.js +1 -1
  18. package/package.json +1 -1
  19. package/src/core/collection/array/array_insert_at.d.ts +16 -0
  20. package/src/core/collection/array/array_insert_at.d.ts.map +1 -0
  21. package/src/core/collection/array/array_insert_at.js +32 -0
  22. package/src/core/collection/array/array_remove_at.d.ts +15 -0
  23. package/src/core/collection/array/array_remove_at.d.ts.map +1 -0
  24. package/src/core/collection/array/array_remove_at.js +30 -0
  25. package/src/core/geom/3d/quaternion/quat3_look_rotation.d.ts +37 -0
  26. package/src/core/geom/3d/quaternion/quat3_look_rotation.d.ts.map +1 -0
  27. package/src/core/geom/3d/quaternion/quat3_look_rotation.js +172 -0
  28. package/src/core/geom/Quaternion.d.ts +1 -0
  29. package/src/core/geom/Quaternion.d.ts.map +1 -1
  30. package/src/core/geom/Quaternion.js +12 -48
  31. package/src/engine/Engine.d.ts.map +1 -1
  32. package/src/engine/Engine.js +9 -4
  33. package/src/engine/ecs/async/WORKER_SYSTEM_PLAN.md +27 -11
  34. package/src/engine/ecs/storage/populateEngineSerializationRegistry.d.ts.map +1 -1
  35. package/src/engine/ecs/storage/populateEngineSerializationRegistry.js +21 -0
  36. package/src/engine/ecs/transform/t64_look_rotation.d.ts +4 -4
  37. package/src/engine/ecs/transform/t64_look_rotation.d.ts.map +1 -1
  38. package/src/engine/ecs/transform/t64_look_rotation.js +7 -18
  39. package/src/engine/graphics/ecs/camera/topdown/TopDownCameraControllerSystem.d.ts.map +1 -1
  40. package/src/engine/graphics/ecs/camera/topdown/TopDownCameraControllerSystem.js +30 -1
  41. package/src/engine/graphics/ecs/particles/ParticleEffect.d.ts +2 -2
  42. package/src/engine/graphics/ecs/particles/ParticleEffect.d.ts.map +1 -1
  43. package/src/engine/graphics/ecs/particles/ParticleEffect.js +7 -7
  44. package/src/engine/graphics/ecs/particles/ParticleEffectSerializationAdapter.d.ts +8 -0
  45. package/src/engine/graphics/ecs/particles/ParticleEffectSerializationAdapter.d.ts.map +1 -1
  46. package/src/engine/graphics/ecs/particles/ParticleEffectSerializationAdapter.js +11 -3
  47. package/src/engine/graphics/ecs/particles/ParticleEffectSerializationUpgrader_1_2.d.ts +26 -0
  48. package/src/engine/graphics/ecs/particles/ParticleEffectSerializationUpgrader_1_2.d.ts.map +1 -0
  49. package/src/engine/graphics/ecs/particles/ParticleEffectSerializationUpgrader_1_2.js +91 -0
  50. package/src/engine/graphics3/GPUParticleEmitterSystem.d.ts +6 -0
  51. package/src/engine/graphics3/GPUParticleEmitterSystem.d.ts.map +1 -1
  52. package/src/engine/graphics3/GPUParticleEmitterSystem.js +72 -29
  53. package/src/engine/graphics3/GraphicsEngine.d.ts.map +1 -1
  54. package/src/engine/graphics3/GraphicsEngine.js +8 -1
  55. package/src/engine/graphics3/ParticipatingMedia.d.ts +84 -1
  56. package/src/engine/graphics3/ParticipatingMedia.d.ts.map +1 -1
  57. package/src/engine/graphics3/ParticipatingMedia.js +139 -5
  58. package/src/engine/graphics3/ParticipatingMediaSerializationAdapter.d.ts +6 -2
  59. package/src/engine/graphics3/ParticipatingMediaSerializationAdapter.d.ts.map +1 -1
  60. package/src/engine/graphics3/ParticipatingMediaSerializationAdapter.js +29 -4
  61. package/src/engine/graphics3/ParticipatingMediaSerializationUpgrader_0_1.d.ts +10 -0
  62. package/src/engine/graphics3/ParticipatingMediaSerializationUpgrader_0_1.d.ts.map +1 -0
  63. package/src/engine/graphics3/ParticipatingMediaSerializationUpgrader_0_1.js +38 -0
  64. package/src/engine/graphics3/ParticipatingMediaSystem.d.ts.map +1 -1
  65. package/src/engine/graphics3/ParticipatingMediaSystem.js +46 -3
  66. package/src/engine/input/devices/KeyboardDevice.d.ts +1 -0
  67. package/src/engine/input/devices/KeyboardDevice.d.ts.map +1 -1
  68. package/src/engine/input/devices/KeyboardDevice.js +7 -6
  69. package/src/engine/navigation/ecs/path_following/PathFollowingSystem.d.ts.map +1 -1
  70. package/src/engine/navigation/ecs/path_following/PathFollowingSystem.js +15 -2
  71. package/src/engine/network/CONGESTION_CONTROL.md +9 -9
  72. package/src/engine/network/MESSAGE_TRANSPORT.md +364 -0
  73. package/src/engine/network/NetworkSession.d.ts +47 -16
  74. package/src/engine/network/NetworkSession.d.ts.map +1 -1
  75. package/src/engine/network/NetworkSession.js +556 -292
  76. package/src/engine/network/README.md +104 -28
  77. package/src/engine/network/SMOOTHNESS_DESIGN.md +13 -5
  78. package/src/engine/network/diagnostics/BandwidthMeter.d.ts +1 -1
  79. package/src/engine/network/diagnostics/BandwidthMeter.js +1 -1
  80. package/src/engine/network/orchestrator/HostJoin.d.ts +111 -0
  81. package/src/engine/network/orchestrator/HostJoin.d.ts.map +1 -0
  82. package/src/engine/network/orchestrator/HostJoin.js +271 -0
  83. package/src/engine/network/orchestrator/NetworkPeer.d.ts +151 -112
  84. package/src/engine/network/orchestrator/NetworkPeer.d.ts.map +1 -1
  85. package/src/engine/network/orchestrator/NetworkPeer.js +450 -499
  86. package/src/engine/network/orchestrator/PendingSlices.d.ts +30 -0
  87. package/src/engine/network/orchestrator/PendingSlices.d.ts.map +1 -0
  88. package/src/engine/network/orchestrator/PendingSlices.js +83 -0
  89. package/src/engine/network/orchestrator/ReliableFrames.d.ts +34 -0
  90. package/src/engine/network/orchestrator/ReliableFrames.d.ts.map +1 -0
  91. package/src/engine/network/orchestrator/ReliableFrames.js +96 -0
  92. package/src/engine/network/orchestrator/ServerAuthoritativeClient.d.ts +77 -10
  93. package/src/engine/network/orchestrator/ServerAuthoritativeClient.d.ts.map +1 -1
  94. package/src/engine/network/orchestrator/ServerAuthoritativeClient.js +236 -61
  95. package/src/engine/network/orchestrator/ServerAuthoritativeServer.d.ts +59 -23
  96. package/src/engine/network/orchestrator/ServerAuthoritativeServer.d.ts.map +1 -1
  97. package/src/engine/network/orchestrator/ServerAuthoritativeServer.js +213 -198
  98. package/src/engine/network/replication/Replicator.d.ts +15 -4
  99. package/src/engine/network/replication/Replicator.d.ts.map +1 -1
  100. package/src/engine/network/replication/Replicator.js +57 -17
  101. package/src/engine/network/sim/ActionLog.d.ts +32 -5
  102. package/src/engine/network/sim/ActionLog.d.ts.map +1 -1
  103. package/src/engine/network/sim/ActionLog.js +47 -5
  104. package/src/engine/network/sim/SimActionExecutor.d.ts +42 -2
  105. package/src/engine/network/sim/SimActionExecutor.d.ts.map +1 -1
  106. package/src/engine/network/sim/SimActionExecutor.js +100 -4
  107. package/src/engine/network/sim/Snapshotter.d.ts +12 -0
  108. package/src/engine/network/sim/Snapshotter.d.ts.map +1 -1
  109. package/src/engine/network/sim/Snapshotter.js +43 -0
  110. package/src/engine/network/state/Baseline.d.ts +1 -1
  111. package/src/engine/network/state/Baseline.js +1 -1
  112. package/src/engine/network/state/FrameBufferRing.d.ts +25 -6
  113. package/src/engine/network/state/FrameBufferRing.d.ts.map +1 -1
  114. package/src/engine/network/state/FrameBufferRing.js +51 -6
  115. package/src/engine/network/state/InputRing.d.ts +4 -0
  116. package/src/engine/network/state/InputRing.d.ts.map +1 -1
  117. package/src/engine/network/state/InputRing.js +7 -0
  118. package/src/engine/network/state/RecordArrivalRing.d.ts +57 -0
  119. package/src/engine/network/state/RecordArrivalRing.d.ts.map +1 -0
  120. package/src/engine/network/state/RecordArrivalRing.js +144 -0
  121. package/src/engine/network/transport/DeferredTransport.d.ts.map +1 -1
  122. package/src/engine/network/transport/DeferredTransport.js +1 -0
  123. package/src/engine/network/transport/LoopbackTransport.d.ts.map +1 -1
  124. package/src/engine/network/transport/LoopbackTransport.js +4 -2
  125. package/src/engine/network/transport/Transport.d.ts +7 -0
  126. package/src/engine/network/transport/Transport.d.ts.map +1 -1
  127. package/src/engine/network/transport/Transport.js +8 -0
  128. package/src/engine/network/transport/adapters/NodeUDPTransport.d.ts.map +1 -1
  129. package/src/engine/network/transport/adapters/NodeUDPTransport.js +20 -5
  130. package/src/engine/network/transport/adapters/WebRTCDataChannelTransport.d.ts.map +1 -1
  131. package/src/engine/network/transport/adapters/WebRTCDataChannelTransport.js +8 -0
  132. package/src/engine/network/transport/adapters/WebTransportTransport.d.ts.map +1 -1
  133. package/src/engine/network/transport/adapters/WebTransportTransport.js +6 -0
  134. package/src/engine/network/transport/connection/Connection.d.ts +191 -0
  135. package/src/engine/network/transport/connection/Connection.d.ts.map +1 -0
  136. package/src/engine/network/transport/connection/Connection.js +1262 -0
  137. package/src/engine/network/transport/connection/RangeSet.d.ts +94 -0
  138. package/src/engine/network/transport/connection/RangeSet.d.ts.map +1 -0
  139. package/src/engine/network/transport/connection/RangeSet.js +260 -0
  140. package/src/engine/network/transport/connection/RxStream.d.ts +48 -0
  141. package/src/engine/network/transport/connection/RxStream.d.ts.map +1 -0
  142. package/src/engine/network/transport/connection/RxStream.js +211 -0
  143. package/src/engine/network/transport/connection/TxStream.d.ts +90 -0
  144. package/src/engine/network/transport/connection/TxStream.d.ts.map +1 -0
  145. package/src/engine/network/transport/connection/TxStream.js +243 -0
  146. package/src/engine/network/transport/connection/bytes_copy.d.ts +17 -0
  147. package/src/engine/network/transport/connection/bytes_copy.d.ts.map +1 -0
  148. package/src/engine/network/transport/connection/bytes_copy.js +34 -0
  149. package/src/engine/network/transport/connection/varint.d.ts +46 -0
  150. package/src/engine/network/transport/connection/varint.d.ts.map +1 -0
  151. package/src/engine/network/transport/connection/varint.js +107 -0
  152. package/src/engine/physics/cloth/MEASUREMENTS.md +354 -0
  153. package/src/engine/physics/cloth/PLAN.md +85 -5
  154. package/src/engine/physics/cloth/ecs/ClothInstance.d.ts +0 -12
  155. package/src/engine/physics/cloth/ecs/ClothInstance.d.ts.map +1 -1
  156. package/src/engine/physics/cloth/ecs/ClothInstance.js +0 -13
  157. package/src/engine/physics/cloth/ecs/ClothSystem.d.ts +2 -1
  158. package/src/engine/physics/cloth/ecs/ClothSystem.d.ts.map +1 -1
  159. package/src/engine/physics/cloth/ecs/ClothSystem.js +7 -1
  160. package/src/engine/physics/cloth/ecs/ClothWorld.d.ts.map +1 -1
  161. package/src/engine/physics/cloth/ecs/ClothWorld.js +4 -15
  162. package/src/engine/physics/cloth/ecs/WorkerClothSystem.d.ts +2 -1
  163. package/src/engine/physics/cloth/ecs/WorkerClothSystem.d.ts.map +1 -1
  164. package/src/engine/physics/cloth/ecs/WorkerClothSystem.js +6 -1
  165. package/src/engine/physics/cloth/ecs/cloth_build_rows.d.ts.map +1 -1
  166. package/src/engine/physics/cloth/ecs/cloth_build_rows.js +20 -10
  167. package/src/engine/physics/cloth/playground/collide.html +5 -3
  168. package/src/engine/physics/cloth/playground/collide_main.js +14 -13
  169. package/src/engine/physics/cloth/solver/ClothState.d.ts +30 -2
  170. package/src/engine/physics/cloth/solver/ClothState.d.ts.map +1 -1
  171. package/src/engine/physics/cloth/solver/ClothState.js +62 -4
  172. package/src/engine/physics/cloth/solver/cloth_self_find.d.ts +11 -3
  173. package/src/engine/physics/cloth/solver/cloth_self_find.d.ts.map +1 -1
  174. package/src/engine/physics/cloth/solver/cloth_self_find.js +52 -11
  175. package/src/engine/physics/cloth/solver/cloth_self_radius.d.ts +42 -0
  176. package/src/engine/physics/cloth/solver/cloth_self_radius.d.ts.map +1 -0
  177. package/src/engine/physics/cloth/solver/cloth_self_radius.js +64 -0
  178. package/src/engine/physics/cloth/solver/cloth_solver_constants.d.ts +99 -24
  179. package/src/engine/physics/cloth/solver/cloth_solver_constants.d.ts.map +1 -1
  180. package/src/engine/physics/cloth/solver/cloth_solver_constants.js +102 -25
  181. package/src/engine/physics/cloth/solver/cloth_step.d.ts +5 -1
  182. package/src/engine/physics/cloth/solver/cloth_step.d.ts.map +1 -1
  183. package/src/engine/physics/cloth/solver/cloth_step.js +13 -3
  184. package/src/engine/physics/cloth/solver/cloth_step_instance.d.ts +0 -1
  185. package/src/engine/physics/cloth/solver/cloth_step_instance.d.ts.map +1 -1
  186. package/src/engine/physics/cloth/solver/cloth_step_instance.js +12 -14
  187. package/src/engine/physics/cloth/solver/constraint/cloth_contact_row.d.ts +23 -4
  188. package/src/engine/physics/cloth/solver/constraint/cloth_contact_row.d.ts.map +1 -1
  189. package/src/engine/physics/cloth/solver/constraint/cloth_contact_row.js +36 -8
  190. package/src/engine/physics/cloth/solver/constraint/cloth_self_row.d.ts.map +1 -1
  191. package/src/engine/physics/cloth/solver/constraint/cloth_self_row.js +4 -2
  192. package/src/engine/physics/fluid/ecs/FluidObstacleSystem.d.ts +4 -4
  193. package/src/engine/sound/ecs/audio/AudioEmitter.d.ts +38 -7
  194. package/src/engine/sound/ecs/audio/AudioEmitter.d.ts.map +1 -1
  195. package/src/engine/sound/ecs/audio/AudioEmitter.js +35 -7
  196. package/src/engine/sound/ecs/audio/AudioEmitterSerializationAdapter.d.ts.map +1 -1
  197. package/src/engine/sound/ecs/audio/AudioEmitterSerializationAdapter.js +5 -1
  198. package/src/engine/sound/ecs/audio/AudioEmitterSerializationUpgrader_0_1.d.ts +18 -0
  199. package/src/engine/sound/ecs/audio/AudioEmitterSerializationUpgrader_0_1.d.ts.map +1 -0
  200. package/src/engine/sound/ecs/audio/AudioEmitterSerializationUpgrader_0_1.js +48 -0
  201. package/src/engine/sound/ecs/audio/AudioEmitterSystem.d.ts +12 -2
  202. package/src/engine/sound/ecs/audio/AudioEmitterSystem.d.ts.map +1 -1
  203. package/src/engine/sound/ecs/audio/AudioEmitterSystem.js +173 -9
  204. package/src/engine/sound/ecs/audio/LiveEmitterSet.d.ts +9 -3
  205. package/src/engine/sound/ecs/audio/LiveEmitterSet.d.ts.map +1 -1
  206. package/src/engine/sound/ecs/audio/LiveEmitterSet.js +28 -8
  207. package/src/engine/sound/ecs/trigger/AudioEventTrigger.d.ts +8 -0
  208. package/src/engine/sound/ecs/trigger/AudioEventTrigger.d.ts.map +1 -1
  209. package/src/engine/sound/ecs/trigger/AudioEventTriggerSerializationAdapter.d.ts.map +1 -1
  210. package/src/engine/sound/ecs/trigger/AudioEventTriggerSerializationAdapter.js +5 -1
  211. package/src/engine/sound/ecs/trigger/AudioEventTriggerSerializationUpgrader_0_1.d.ts +18 -0
  212. package/src/engine/sound/ecs/trigger/AudioEventTriggerSerializationUpgrader_0_1.d.ts.map +1 -0
  213. package/src/engine/sound/ecs/trigger/AudioEventTriggerSerializationUpgrader_0_1.js +51 -0
  214. package/src/engine/sound/ecs/trigger/AudioEventTriggerSystem.d.ts.map +1 -1
  215. package/src/engine/sound/ecs/trigger/AudioEventTriggerSystem.js +15 -1
  216. package/src/engine/sound/sopra/README.md +768 -644
  217. package/src/engine/sound/sopra/SopraEngine.d.ts +104 -8
  218. package/src/engine/sound/sopra/SopraEngine.d.ts.map +1 -1
  219. package/src/engine/sound/sopra/SopraEngine.js +327 -12
  220. package/src/engine/sound/sopra/definition/EventDescription.d.ts +28 -2
  221. package/src/engine/sound/sopra/definition/EventDescription.d.ts.map +1 -1
  222. package/src/engine/sound/sopra/definition/EventDescription.js +55 -5
  223. package/src/engine/sound/sopra/definition/EventDescriptionSerializationAdapter.d.ts +10 -0
  224. package/src/engine/sound/sopra/definition/EventDescriptionSerializationAdapter.d.ts.map +1 -1
  225. package/src/engine/sound/sopra/definition/EventDescriptionSerializationAdapter.js +77 -55
  226. package/src/engine/sound/sopra/definition/EventDescriptionSerializationUpgrader_0_1.d.ts +31 -0
  227. package/src/engine/sound/sopra/definition/EventDescriptionSerializationUpgrader_0_1.d.ts.map +1 -0
  228. package/src/engine/sound/sopra/definition/EventDescriptionSerializationUpgrader_0_1.js +75 -0
  229. package/src/engine/sound/sopra/definition/effect/AbstractAudioEffect.d.ts +38 -9
  230. package/src/engine/sound/sopra/definition/effect/AbstractAudioEffect.d.ts.map +1 -1
  231. package/src/engine/sound/sopra/definition/effect/AbstractAudioEffect.js +34 -5
  232. package/src/engine/sound/sopra/definition/effect/CompressorEffect.d.ts +7 -2
  233. package/src/engine/sound/sopra/definition/effect/CompressorEffect.d.ts.map +1 -1
  234. package/src/engine/sound/sopra/definition/effect/CompressorEffect.js +137 -122
  235. package/src/engine/sound/sopra/definition/effect/EqEffect.d.ts +3 -1
  236. package/src/engine/sound/sopra/definition/effect/EqEffect.d.ts.map +1 -1
  237. package/src/engine/sound/sopra/definition/effect/EqEffect.js +146 -131
  238. package/src/engine/sound/sopra/definition/effect/ReverbEffect.d.ts +1 -0
  239. package/src/engine/sound/sopra/definition/effect/ReverbEffect.d.ts.map +1 -1
  240. package/src/engine/sound/sopra/definition/effect/ReverbEffect.js +6 -1
  241. package/src/engine/sound/sopra/runtime/BusGraph.d.ts +44 -2
  242. package/src/engine/sound/sopra/runtime/BusGraph.d.ts.map +1 -1
  243. package/src/engine/sound/sopra/runtime/BusGraph.js +83 -43
  244. package/src/engine/sound/sopra/runtime/EffectChain.d.ts +96 -0
  245. package/src/engine/sound/sopra/runtime/EffectChain.d.ts.map +1 -0
  246. package/src/engine/sound/sopra/runtime/EffectChain.js +286 -0
  247. package/src/engine/sound/sopra/runtime/EffectParamOverrides.d.ts +123 -0
  248. package/src/engine/sound/sopra/runtime/EffectParamOverrides.d.ts.map +1 -0
  249. package/src/engine/sound/sopra/runtime/EffectParamOverrides.js +320 -0
  250. package/src/engine/sound/sopra/runtime/EventInstance.d.ts +55 -5
  251. package/src/engine/sound/sopra/runtime/EventInstance.d.ts.map +1 -1
  252. package/src/engine/sound/sopra/runtime/EventInstance.js +201 -26
  253. package/src/engine/sound/sopra/serialization/populateSopraSerializationRegistry.d.ts +2 -1
  254. package/src/engine/sound/sopra/serialization/populateSopraSerializationRegistry.d.ts.map +1 -1
  255. package/src/engine/sound/sopra/serialization/populateSopraSerializationRegistry.js +6 -1
  256. package/src/engine/sound/sopra/serialization/sopraSerializationHarness.d.ts +15 -0
  257. package/src/engine/sound/sopra/serialization/sopraSerializationHarness.d.ts.map +1 -1
  258. package/src/engine/sound/sopra/serialization/sopraSerializationHarness.js +32 -0
  259. package/src/engine/sound/sopra/util/MockAudioContext.d.ts.map +1 -1
  260. package/src/engine/sound/sopra/util/MockAudioContext.js +3 -0
  261. package/src/engine/sound/sopra/util/fadeOutAndStop.d.ts +13 -3
  262. package/src/engine/sound/sopra/util/fadeOutAndStop.d.ts.map +1 -1
  263. package/src/engine/sound/sopra/util/fadeOutAndStop.js +25 -13
  264. package/src/shade/RENDERER_CONTRACT.md +6 -3
  265. package/src/shade/device/SHADE_DEVICE_FLOOR.d.ts +24 -0
  266. package/src/shade/device/SHADE_DEVICE_FLOOR.d.ts.map +1 -0
  267. package/src/shade/device/SHADE_DEVICE_FLOOR.js +34 -0
  268. package/src/shade/device/ShadeDeviceFailure.d.ts +12 -5
  269. package/src/shade/device/ShadeDeviceFailure.d.ts.map +1 -1
  270. package/src/shade/device/ShadeDeviceFailure.js +17 -8
  271. package/src/shade/device/ShadeDeviceFailureReason.d.ts +1 -1
  272. package/src/shade/device/ShadeDeviceFailureReason.js +2 -2
  273. package/src/shade/device/mock/SoftwareGPUDevice.d.ts +15 -0
  274. package/src/shade/device/mock/SoftwareGPUDevice.d.ts.map +1 -1
  275. package/src/shade/device/mock/SoftwareGPUDevice.js +21 -0
  276. package/src/shade/device/pipeline/ComputePipelineManager.d.ts +20 -0
  277. package/src/shade/device/pipeline/ComputePipelineManager.d.ts.map +1 -1
  278. package/src/shade/device/pipeline/ComputePipelineManager.js +80 -6
  279. package/src/shade/device/pipeline/PipelineEnquiry.d.ts +52 -0
  280. package/src/shade/device/pipeline/PipelineEnquiry.d.ts.map +1 -0
  281. package/src/shade/device/pipeline/PipelineEnquiry.js +63 -0
  282. package/src/shade/device/pipeline/RenderPipelineManager.d.ts +21 -0
  283. package/src/shade/device/pipeline/RenderPipelineManager.d.ts.map +1 -1
  284. package/src/shade/device/pipeline/RenderPipelineManager.js +84 -4
  285. package/src/shade/device/shade_device_floor_unmet.d.ts +13 -0
  286. package/src/shade/device/shade_device_floor_unmet.d.ts.map +1 -0
  287. package/src/shade/device/shade_device_floor_unmet.js +32 -0
  288. package/src/shade/playground/contact_shadows/ContactShadowLab.d.ts +137 -0
  289. package/src/shade/playground/contact_shadows/ContactShadowLab.d.ts.map +1 -0
  290. package/src/shade/playground/contact_shadows/ContactShadowLab.js +654 -0
  291. package/src/shade/playground/contact_shadows/README.md +126 -0
  292. package/src/shade/playground/contact_shadows/index.html +191 -0
  293. package/src/shade/playground/contact_shadows/main.d.ts +2 -0
  294. package/src/shade/playground/contact_shadows/main.d.ts.map +1 -0
  295. package/src/shade/playground/contact_shadows/main.js +888 -0
  296. package/src/shade/playground/contact_shadows/scenes.d.ts +48 -0
  297. package/src/shade/playground/contact_shadows/scenes.d.ts.map +1 -0
  298. package/src/shade/playground/contact_shadows/scenes.js +620 -0
  299. package/src/shade/playground/contact_shadows/shader_contact_lab_composite.d.ts +36 -0
  300. package/src/shade/playground/contact_shadows/shader_contact_lab_composite.d.ts.map +1 -0
  301. package/src/shade/playground/contact_shadows/shader_contact_lab_composite.js +245 -0
  302. package/src/shade/playground/contact_shadows/shader_contact_lab_reference.d.ts +15 -0
  303. package/src/shade/playground/contact_shadows/shader_contact_lab_reference.d.ts.map +1 -0
  304. package/src/shade/playground/contact_shadows/shader_contact_lab_reference.js +120 -0
  305. package/src/shade/playground/contact_shadows/shader_contact_lab_stats.d.ts +55 -0
  306. package/src/shade/playground/contact_shadows/shader_contact_lab_stats.d.ts.map +1 -0
  307. package/src/shade/playground/contact_shadows/shader_contact_lab_stats.js +216 -0
  308. package/src/shade/playground/contact_shadows/shader_contact_lab_view.d.ts +20 -0
  309. package/src/shade/playground/contact_shadows/shader_contact_lab_view.d.ts.map +1 -0
  310. package/src/shade/playground/contact_shadows/shader_contact_lab_view.js +114 -0
  311. package/src/shade/playground/contact_shadows/shader_contact_shadow_march.d.ts +11 -0
  312. package/src/shade/playground/contact_shadows/shader_contact_shadow_march.d.ts.map +1 -0
  313. package/src/shade/playground/contact_shadows/shader_contact_shadow_march.js +90 -0
  314. package/src/shade/playground/contact_shadows/textures.d.ts +16 -0
  315. package/src/shade/playground/contact_shadows/textures.d.ts.map +1 -0
  316. package/src/shade/playground/contact_shadows/textures.js +123 -0
  317. package/src/shade/playground/particle_ecs/README.md +1 -1
  318. package/src/shade/playground/particle_ecs/effects/flame.json +1932 -1881
  319. package/src/shade/playground/particle_ecs/effects/smoke.json +99 -1
  320. package/src/shade/playground/particle_ecs/effects/soot.json +152 -145
  321. package/src/shade/playground/tonemap_sdr/README.md +90 -0
  322. package/src/shade/playground/tonemap_sdr/ToneMapCompare.d.ts +105 -0
  323. package/src/shade/playground/tonemap_sdr/ToneMapCompare.d.ts.map +1 -0
  324. package/src/shade/playground/tonemap_sdr/ToneMapCompare.js +380 -0
  325. package/src/shade/playground/tonemap_sdr/chunk_tonemap_gt7_sdr_reference.d.ts +32 -0
  326. package/src/shade/playground/tonemap_sdr/chunk_tonemap_gt7_sdr_reference.d.ts.map +1 -0
  327. package/src/shade/playground/tonemap_sdr/chunk_tonemap_gt7_sdr_reference.js +104 -0
  328. package/src/shade/playground/tonemap_sdr/index.html +90 -0
  329. package/src/shade/playground/tonemap_sdr/main.d.ts +2 -0
  330. package/src/shade/playground/tonemap_sdr/main.d.ts.map +1 -0
  331. package/src/shade/playground/tonemap_sdr/main.js +306 -0
  332. package/src/shade/playground/tonemap_sdr/scenes.d.ts +26 -0
  333. package/src/shade/playground/tonemap_sdr/scenes.d.ts.map +1 -0
  334. package/src/shade/playground/tonemap_sdr/scenes.js +404 -0
  335. package/src/shade/playground/volumetrics_froxel/main.d.ts.map +1 -1
  336. package/src/shade/playground/volumetrics_froxel/main.js +85 -4
  337. package/src/shade/playground/water_refraction/README.md +26 -18
  338. package/src/shade/playground/water_refraction/index.html +1 -1
  339. package/src/shade/renderer/Renderer.d.ts +37 -3
  340. package/src/shade/renderer/Renderer.d.ts.map +1 -1
  341. package/src/shade/renderer/Renderer.js +237 -67
  342. package/src/shade/renderer/ShadeToneMappingMode.d.ts +14 -0
  343. package/src/shade/renderer/ShadeToneMappingMode.d.ts.map +1 -0
  344. package/src/shade/renderer/ShadeToneMappingMode.js +30 -0
  345. package/src/shade/renderer/animation/GPUAnimationManager.d.ts +9 -0
  346. package/src/shade/renderer/animation/GPUAnimationManager.d.ts.map +1 -1
  347. package/src/shade/renderer/animation/GPUAnimationManager.js +14 -0
  348. package/src/shade/renderer/animation/skinning/shader_meshlet_apply_skinning.d.ts.map +1 -1
  349. package/src/shade/renderer/animation/skinning/shader_meshlet_apply_skinning.js +5 -3
  350. package/src/shade/renderer/buffer/GPUBufferAllocator.d.ts.map +1 -1
  351. package/src/shade/renderer/buffer/GPUBufferAllocator.js +9 -0
  352. package/src/shade/renderer/buffer/buffer_pool_ops.d.ts +21 -12
  353. package/src/shade/renderer/buffer/buffer_pool_ops.d.ts.map +1 -1
  354. package/src/shade/renderer/buffer/buffer_pool_ops.js +18 -19
  355. package/src/shade/renderer/buffer/table/GPUDatabase.d.ts +7 -0
  356. package/src/shade/renderer/buffer/table/GPUDatabase.d.ts.map +1 -1
  357. package/src/shade/renderer/buffer/table/GPUDatabase.js +12 -0
  358. package/src/shade/renderer/buffer/table/single/GPUSingleTypeTable.d.ts +8 -0
  359. package/src/shade/renderer/buffer/table/single/GPUSingleTypeTable.d.ts.map +1 -1
  360. package/src/shade/renderer/buffer/table/single/GPUSingleTypeTable.js +12 -0
  361. package/src/shade/renderer/camera/GPUCameraContext.d.ts.map +1 -1
  362. package/src/shade/renderer/camera/GPUCameraContext.js +19 -8
  363. package/src/shade/renderer/deferred/chunk_read_gBuffer_material.d.ts.map +1 -1
  364. package/src/shade/renderer/deferred/chunk_read_gBuffer_material.js +4 -0
  365. package/src/shade/renderer/deferred/chunk_shade_standard_material_direct.d.ts.map +1 -1
  366. package/src/shade/renderer/deferred/chunk_shade_standard_material_direct.js +4 -0
  367. package/src/shade/renderer/deferred/chunk_shade_standard_material_direct_restir.d.ts.map +1 -1
  368. package/src/shade/renderer/deferred/chunk_shade_standard_material_direct_restir.js +4 -0
  369. package/src/shade/renderer/deferred/shader_deferred_main.d.ts.map +1 -1
  370. package/src/shade/renderer/deferred/shader_deferred_main.js +3 -0
  371. package/src/shade/renderer/deferred/shader_tonemap_HDR.d.ts +6 -0
  372. package/src/shade/renderer/deferred/shader_tonemap_HDR.d.ts.map +1 -1
  373. package/src/shade/renderer/deferred/shader_tonemap_HDR.js +13 -3
  374. package/src/shade/renderer/deferred/shader_tonemap_HDR_none.d.ts +9 -0
  375. package/src/shade/renderer/deferred/shader_tonemap_HDR_none.d.ts.map +1 -0
  376. package/src/shade/renderer/deferred/shader_tonemap_HDR_none.js +63 -0
  377. package/src/shade/renderer/deferred/shader_tonemap_HDR_pbr_neutral.d.ts +10 -0
  378. package/src/shade/renderer/deferred/shader_tonemap_HDR_pbr_neutral.d.ts.map +1 -0
  379. package/src/shade/renderer/deferred/shader_tonemap_HDR_pbr_neutral.js +87 -0
  380. package/src/shade/renderer/deferred/shader_tonemap_LDR.d.ts +6 -0
  381. package/src/shade/renderer/deferred/shader_tonemap_LDR.d.ts.map +1 -1
  382. package/src/shade/renderer/deferred/shader_tonemap_LDR.js +23 -5
  383. package/src/shade/renderer/deferred/shader_tonemap_LDR_none.d.ts +9 -0
  384. package/src/shade/renderer/deferred/shader_tonemap_LDR_none.d.ts.map +1 -0
  385. package/src/shade/renderer/deferred/shader_tonemap_LDR_none.js +68 -0
  386. package/src/shade/renderer/deferred/shader_tonemap_LDR_pbr_neutral.d.ts +10 -0
  387. package/src/shade/renderer/deferred/shader_tonemap_LDR_pbr_neutral.d.ts.map +1 -0
  388. package/src/shade/renderer/deferred/shader_tonemap_LDR_pbr_neutral.js +73 -0
  389. package/src/shade/renderer/geometry/meshlet/MeshletBatch.d.ts.map +1 -1
  390. package/src/shade/renderer/geometry/meshlet/MeshletBatch.js +58 -9
  391. package/src/shade/renderer/geometry/sdf/GPUGeometrySDFManager.d.ts +35 -25
  392. package/src/shade/renderer/geometry/sdf/GPUGeometrySDFManager.d.ts.map +1 -1
  393. package/src/shade/renderer/geometry/sdf/GPUGeometrySDFManager.js +97 -196
  394. package/src/shade/renderer/geometry/sdf/shader_build_sdf.d.ts.map +1 -1
  395. package/src/shade/renderer/geometry/sdf/shader_build_sdf.js +121 -129
  396. package/src/shade/renderer/global_illumination/brick4/gpu/bake/brick4_bake_basic.d.ts.map +1 -1
  397. package/src/shade/renderer/global_illumination/brick4/gpu/bake/brick4_bake_basic.js +3 -0
  398. package/src/shade/renderer/global_illumination/brick4/gpu/bake/shader_brick4_bake_probes.d.ts.map +1 -1
  399. package/src/shade/renderer/global_illumination/brick4/gpu/bake/shader_brick4_bake_probes.js +4 -0
  400. package/src/shade/renderer/global_illumination/brick4/gpu/draw/shader_brick4_indirect_lighting.d.ts.map +1 -1
  401. package/src/shade/renderer/global_illumination/brick4/gpu/draw/shader_brick4_indirect_lighting.js +4 -0
  402. package/src/shade/renderer/global_illumination/lpv/bake/GPULightProbeVolumeRenderer.d.ts.map +1 -1
  403. package/src/shade/renderer/global_illumination/lpv/bake/GPULightProbeVolumeRenderer.js +3 -0
  404. package/src/shade/renderer/global_illumination/lpv/deprecated/probe_trace_compute_shader_code.d.ts.map +1 -1
  405. package/src/shade/renderer/global_illumination/lpv/deprecated/probe_trace_compute_shader_code.js +4 -0
  406. package/src/shade/renderer/global_illumination/probe/octahedral/graph_sample_light_probes.d.ts.map +1 -1
  407. package/src/shade/renderer/global_illumination/probe/octahedral/graph_sample_light_probes.js +4 -0
  408. package/src/shade/renderer/global_illumination/shader_resolve_indirect_lighting.d.ts.map +1 -1
  409. package/src/shade/renderer/global_illumination/shader_resolve_indirect_lighting.js +4 -0
  410. package/src/shade/renderer/gpu_primitive/bvh/GPU_BVH_BUILD_PLAN.md +131 -1
  411. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_delta.d.ts +7 -0
  412. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_delta.d.ts.map +1 -1
  413. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_delta.js +45 -38
  414. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_determine_range.d.ts +2 -0
  415. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_determine_range.d.ts.map +1 -1
  416. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_determine_range.js +81 -79
  417. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_find_split.d.ts +2 -0
  418. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_find_split.d.ts.map +1 -1
  419. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_find_split.js +5 -3
  420. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_internal_children.d.ts +21 -0
  421. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_internal_children.d.ts.map +1 -0
  422. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_internal_children.js +42 -0
  423. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_morton_code.d.ts +19 -0
  424. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_morton_code.d.ts.map +1 -0
  425. package/src/shade/renderer/gpu_primitive/bvh/chunk_bvh_morton_code.js +44 -0
  426. package/src/shade/renderer/gpu_primitive/bvh/graph_bvh_build_lbvh.d.ts +23 -5
  427. package/src/shade/renderer/gpu_primitive/bvh/graph_bvh_build_lbvh.d.ts.map +1 -1
  428. package/src/shade/renderer/gpu_primitive/bvh/graph_bvh_build_lbvh.js +139 -23
  429. package/src/shade/renderer/gpu_primitive/bvh/shader_bvh_build_single_workgroup.d.ts +25 -0
  430. package/src/shade/renderer/gpu_primitive/bvh/shader_bvh_build_single_workgroup.d.ts.map +1 -0
  431. package/src/shade/renderer/gpu_primitive/bvh/shader_bvh_build_single_workgroup.js +179 -0
  432. package/src/shade/renderer/gpu_primitive/bvh/shader_bvh_emit_hierarchy.d.ts +2 -2
  433. package/src/shade/renderer/gpu_primitive/bvh/shader_bvh_emit_hierarchy.d.ts.map +1 -1
  434. package/src/shade/renderer/gpu_primitive/bvh/shader_bvh_emit_hierarchy.js +7 -16
  435. package/src/shade/renderer/gpu_primitive/bvh/shader_bvh_morton.d.ts +3 -4
  436. package/src/shade/renderer/gpu_primitive/bvh/shader_bvh_morton.d.ts.map +1 -1
  437. package/src/shade/renderer/gpu_primitive/bvh/shader_bvh_morton.js +6 -23
  438. package/src/shade/renderer/gpu_primitive/indirect/IndirectComputeCommandBuildPass.d.ts +11 -0
  439. package/src/shade/renderer/gpu_primitive/indirect/IndirectComputeCommandBuildPass.d.ts.map +1 -1
  440. package/src/shade/renderer/gpu_primitive/indirect/IndirectComputeCommandBuildPass.js +14 -3
  441. package/src/shade/renderer/gpu_primitive/indirect/build_indirect_draw_command.d.ts +10 -0
  442. package/src/shade/renderer/gpu_primitive/indirect/build_indirect_draw_command.d.ts.map +1 -1
  443. package/src/shade/renderer/gpu_primitive/indirect/build_indirect_draw_command.js +13 -3
  444. package/src/shade/renderer/gpu_primitive/prefix_sum/v1/graph_prefix_scan_csdldf.d.ts +10 -0
  445. package/src/shade/renderer/gpu_primitive/prefix_sum/v1/graph_prefix_scan_csdldf.d.ts.map +1 -1
  446. package/src/shade/renderer/gpu_primitive/prefix_sum/v1/graph_prefix_scan_csdldf.js +14 -0
  447. package/src/shade/renderer/gpu_primitive/sort/chunk_sort_bitonic_comparator.d.ts +26 -0
  448. package/src/shade/renderer/gpu_primitive/sort/chunk_sort_bitonic_comparator.d.ts.map +1 -0
  449. package/src/shade/renderer/gpu_primitive/sort/chunk_sort_bitonic_comparator.js +52 -0
  450. package/src/shade/renderer/gpu_primitive/sort/chunk_sort_bitonic_workgroup.d.ts +32 -0
  451. package/src/shade/renderer/gpu_primitive/sort/chunk_sort_bitonic_workgroup.d.ts.map +1 -0
  452. package/src/shade/renderer/gpu_primitive/sort/chunk_sort_bitonic_workgroup.js +89 -0
  453. package/src/shade/renderer/gpu_primitive/sort/graph_radix_sort.d.ts +10 -0
  454. package/src/shade/renderer/gpu_primitive/sort/graph_radix_sort.d.ts.map +1 -1
  455. package/src/shade/renderer/gpu_primitive/sort/graph_radix_sort.js +20 -1
  456. package/src/shade/renderer/gpu_primitive/test/gpu_test.d.ts.map +1 -1
  457. package/src/shade/renderer/gpu_primitive/test/gpu_test.js +8 -11
  458. package/src/shade/renderer/hiz/HierarchicalZBuffer.d.ts +10 -0
  459. package/src/shade/renderer/hiz/HierarchicalZBuffer.d.ts.map +1 -1
  460. package/src/shade/renderer/hiz/HierarchicalZBuffer.js +294 -281
  461. package/src/shade/renderer/light/GPULightCollection.d.ts +8 -0
  462. package/src/shade/renderer/light/GPULightCollection.d.ts.map +1 -1
  463. package/src/shade/renderer/light/GPULightCollection.js +18 -1
  464. package/src/shade/renderer/light/cluster/cull/graph_cull_lights.d.ts +8 -0
  465. package/src/shade/renderer/light/cluster/cull/graph_cull_lights.d.ts.map +1 -1
  466. package/src/shade/renderer/light/cluster/cull/graph_cull_lights.js +234 -218
  467. package/src/shade/renderer/light/cluster/graph_assign_clsuters.d.ts +7 -0
  468. package/src/shade/renderer/light/cluster/graph_assign_clsuters.d.ts.map +1 -1
  469. package/src/shade/renderer/light/cluster/graph_assign_clsuters.js +13 -0
  470. package/src/shade/renderer/light/cluster/graph_build_light_clusters.d.ts +7 -0
  471. package/src/shade/renderer/light/cluster/graph_build_light_clusters.d.ts.map +1 -1
  472. package/src/shade/renderer/light/cluster/graph_build_light_clusters.js +16 -2
  473. package/src/shade/renderer/light/environment/execute_filter_environment_map.d.ts +10 -0
  474. package/src/shade/renderer/light/environment/execute_filter_environment_map.d.ts.map +1 -1
  475. package/src/shade/renderer/light/environment/execute_filter_environment_map.js +13 -0
  476. package/src/shade/renderer/lightmap/GPULightMap.d.ts.map +1 -1
  477. package/src/shade/renderer/lightmap/GPULightMap.js +3 -0
  478. package/src/shade/renderer/lightmap/bake/shader_lightmap_viz_to_irradiance_flat.d.ts.map +1 -1
  479. package/src/shade/renderer/lightmap/bake/shader_lightmap_viz_to_irradiance_flat.js +4 -0
  480. package/src/shade/renderer/lightmap/bake/shader_lightmap_viz_to_sh.d.ts.map +1 -1
  481. package/src/shade/renderer/lightmap/bake/shader_lightmap_viz_to_sh.js +4 -0
  482. package/src/shade/renderer/loader/gltf/tiny-gltf.d.ts +1 -1
  483. package/src/shade/renderer/material/GPUMaterialManager.d.ts +16 -4
  484. package/src/shade/renderer/material/GPUMaterialManager.d.ts.map +1 -1
  485. package/src/shade/renderer/material/GPUMaterialManager.js +38 -8
  486. package/src/shade/renderer/particles/DESIGN.md +49 -7
  487. package/src/shade/renderer/particles/ORIENTATION_PLAN_2026_10_15.md +453 -0
  488. package/src/shade/renderer/particles/data/PARTICLE_EMITTER_STRUCT.d.ts +5 -1
  489. package/src/shade/renderer/particles/data/PARTICLE_EMITTER_STRUCT.d.ts.map +1 -1
  490. package/src/shade/renderer/particles/data/PARTICLE_EMITTER_STRUCT.js +13 -5
  491. package/src/shade/renderer/particles/data/particle_emitter_record.js +2 -2
  492. package/src/shade/renderer/particles/graph/groups/particle_builtin_groups.d.ts.map +1 -1
  493. package/src/shade/renderer/particles/graph/groups/particle_builtin_groups.js +12 -0
  494. package/src/shade/renderer/particles/graph/groups/particle_groups_geometry.d.ts +60 -0
  495. package/src/shade/renderer/particles/graph/groups/particle_groups_geometry.d.ts.map +1 -1
  496. package/src/shade/renderer/particles/graph/groups/particle_groups_geometry.js +156 -0
  497. package/src/shade/renderer/particles/runtime/ParticleEmitter.d.ts +2 -2
  498. package/src/shade/renderer/particles/runtime/ParticleEmitter.d.ts.map +1 -1
  499. package/src/shade/renderer/particles/runtime/ParticleEmitter.js +8 -8
  500. package/src/shade/renderer/particles/shaders/chunk_particle_billboard_vertex.d.ts.map +1 -1
  501. package/src/shade/renderer/particles/shaders/chunk_particle_billboard_vertex.js +6 -4
  502. package/src/shade/renderer/particles/shaders/chunk_particle_render_math.d.ts +7 -6
  503. package/src/shade/renderer/particles/shaders/chunk_particle_render_math.d.ts.map +1 -1
  504. package/src/shade/renderer/particles/shaders/chunk_particle_render_math.js +91 -58
  505. package/src/shade/renderer/path_tracer/accumulating/AccumulatingPathTracer.d.ts.map +1 -1
  506. package/src/shade/renderer/path_tracer/accumulating/AccumulatingPathTracer.js +10 -0
  507. package/src/shade/renderer/path_tracer/accumulating/shader_accumulating_path_tracer.d.ts.map +1 -1
  508. package/src/shade/renderer/path_tracer/accumulating/shader_accumulating_path_tracer.js +5 -1
  509. package/src/shade/renderer/path_tracer/graph_path_trace_scene.d.ts.map +1 -1
  510. package/src/shade/renderer/path_tracer/graph_path_trace_scene.js +6 -0
  511. package/src/shade/renderer/pool/TransientResourcePool.d.ts +24 -0
  512. package/src/shade/renderer/pool/TransientResourcePool.d.ts.map +1 -1
  513. package/src/shade/renderer/pool/TransientResourcePool.js +41 -10
  514. package/src/shade/renderer/postprocess/bloom/graph_postprocess_bloom.d.ts +7 -0
  515. package/src/shade/renderer/postprocess/bloom/graph_postprocess_bloom.d.ts.map +1 -1
  516. package/src/shade/renderer/postprocess/bloom/graph_postprocess_bloom.js +18 -0
  517. package/src/shade/renderer/postprocess/denoise/LigmaDenoiser.d.ts.map +1 -1
  518. package/src/shade/renderer/postprocess/denoise/LigmaDenoiser.js +1 -0
  519. package/src/shade/renderer/postprocess/denoise/shader_temporal_reprojection_luma.d.ts.map +1 -1
  520. package/src/shade/renderer/postprocess/denoise/shader_temporal_reprojection_luma.js +6 -4
  521. package/src/shade/renderer/postprocess/eye/GPUCameraExposureManager.d.ts +11 -0
  522. package/src/shade/renderer/postprocess/eye/GPUCameraExposureManager.d.ts.map +1 -1
  523. package/src/shade/renderer/postprocess/eye/GPUCameraExposureManager.js +16 -0
  524. package/src/shade/renderer/postprocess/gtao/GTAO.d.ts +10 -0
  525. package/src/shade/renderer/postprocess/gtao/GTAO.d.ts.map +1 -1
  526. package/src/shade/renderer/postprocess/gtao/GTAO.js +16 -0
  527. package/src/shade/renderer/postprocess/gtao/fragment_shader_gtao.d.ts.map +1 -1
  528. package/src/shade/renderer/postprocess/gtao/fragment_shader_gtao.js +32 -10
  529. package/src/shade/renderer/postprocess/nss/NSS.d.ts +1 -1
  530. package/src/shade/renderer/postprocess/ssr/reproject/chunk_ssr_temporal_accumulate.d.ts.map +1 -1
  531. package/src/shade/renderer/postprocess/ssr/reproject/chunk_ssr_temporal_accumulate.js +3 -0
  532. package/src/shade/renderer/postprocess/ssr/resolve/build_ssr_resolve_shader.d.ts.map +1 -1
  533. package/src/shade/renderer/postprocess/ssr/resolve/build_ssr_resolve_shader.js +6 -3
  534. package/src/shade/renderer/postprocess/taa/TAA.d.ts +12 -0
  535. package/src/shade/renderer/postprocess/taa/TAA.d.ts.map +1 -1
  536. package/src/shade/renderer/postprocess/taa/TAA.js +15 -0
  537. package/src/shade/renderer/postprocess/velocity/graph_add_per_object_velocity.d.ts +7 -0
  538. package/src/shade/renderer/postprocess/velocity/graph_add_per_object_velocity.d.ts.map +1 -1
  539. package/src/shade/renderer/postprocess/velocity/graph_add_per_object_velocity.js +13 -0
  540. package/src/shade/renderer/rasterize/TemplatePassDescriptor.d.ts +31 -3
  541. package/src/shade/renderer/rasterize/TemplatePassDescriptor.d.ts.map +1 -1
  542. package/src/shade/renderer/rasterize/TemplatePassDescriptor.js +79 -4
  543. package/src/shade/renderer/rasterize/bucket/graph_meshlets_rasterize_by_bucket.d.ts +17 -0
  544. package/src/shade/renderer/rasterize/bucket/graph_meshlets_rasterize_by_bucket.d.ts.map +1 -1
  545. package/src/shade/renderer/rasterize/bucket/graph_meshlets_rasterize_by_bucket.js +35 -4
  546. package/src/shade/renderer/rasterize/compute/graph_mesh_frustum_cull.d.ts +7 -0
  547. package/src/shade/renderer/rasterize/compute/graph_mesh_frustum_cull.d.ts.map +1 -1
  548. package/src/shade/renderer/rasterize/compute/graph_mesh_frustum_cull.js +182 -169
  549. package/src/shade/renderer/rasterize/expand/bucket/mesh/graph_meshes_classify_buckets.d.ts +10 -0
  550. package/src/shade/renderer/rasterize/expand/bucket/mesh/graph_meshes_classify_buckets.d.ts.map +1 -1
  551. package/src/shade/renderer/rasterize/expand/bucket/mesh/graph_meshes_classify_buckets.js +20 -1
  552. package/src/shade/renderer/rasterize/expand/bucket/meshlet/graph_extract_meshlets_from_bucket.d.ts +10 -0
  553. package/src/shade/renderer/rasterize/expand/bucket/meshlet/graph_extract_meshlets_from_bucket.d.ts.map +1 -1
  554. package/src/shade/renderer/rasterize/expand/bucket/meshlet/graph_extract_meshlets_from_bucket.js +18 -1
  555. package/src/shade/renderer/rasterize/expand/bucket/meshlet/graph_sort_meshlets_by_bucket_id.d.ts +10 -0
  556. package/src/shade/renderer/rasterize/expand/bucket/meshlet/graph_sort_meshlets_by_bucket_id.d.ts.map +1 -1
  557. package/src/shade/renderer/rasterize/expand/bucket/meshlet/graph_sort_meshlets_by_bucket_id.js +20 -1
  558. package/src/shade/renderer/rasterize/expand/graph_mesh_filter_one_way.d.ts +7 -0
  559. package/src/shade/renderer/rasterize/expand/graph_mesh_filter_one_way.d.ts.map +1 -1
  560. package/src/shade/renderer/rasterize/expand/graph_mesh_filter_one_way.js +187 -170
  561. package/src/shade/renderer/rasterize/expand/graph_meshlets_filter_one_way.d.ts +10 -0
  562. package/src/shade/renderer/rasterize/expand/graph_meshlets_filter_one_way.d.ts.map +1 -1
  563. package/src/shade/renderer/rasterize/expand/graph_meshlets_filter_one_way.js +19 -1
  564. package/src/shade/renderer/rasterize/expand/graph_meshlets_rasterize.d.ts +13 -0
  565. package/src/shade/renderer/rasterize/expand/graph_meshlets_rasterize.d.ts.map +1 -1
  566. package/src/shade/renderer/rasterize/expand/graph_meshlets_rasterize.js +25 -1
  567. package/src/shade/renderer/rasterize/expand/mesh/graph_expand_meshes_to_meshlets.d.ts +10 -0
  568. package/src/shade/renderer/rasterize/expand/mesh/graph_expand_meshes_to_meshlets.d.ts.map +1 -1
  569. package/src/shade/renderer/rasterize/expand/mesh/graph_expand_meshes_to_meshlets.js +20 -0
  570. package/src/shade/renderer/rasterize/forward/chunk_forward_shade_standard_fragment_brick4.d.ts.map +1 -1
  571. package/src/shade/renderer/rasterize/forward/chunk_forward_shade_standard_fragment_brick4.js +6 -0
  572. package/src/shade/renderer/rasterize/forward/chunk_forward_shade_standard_fragment_ibl.d.ts.map +1 -1
  573. package/src/shade/renderer/rasterize/forward/chunk_forward_shade_standard_fragment_ibl.js +6 -0
  574. package/src/shade/renderer/rasterize/native/avboit/AVBOITSideChannel.d.ts +3 -2
  575. package/src/shade/renderer/rasterize/native/avboit/AVBOITSideChannel.d.ts.map +1 -1
  576. package/src/shade/renderer/rasterize/native/avboit/AVBOITSideChannel.js +3 -2
  577. package/src/shade/renderer/rasterize/native/avboit/graph_rasterize_meshes_transparent_avboit.d.ts +7 -2
  578. package/src/shade/renderer/rasterize/native/avboit/graph_rasterize_meshes_transparent_avboit.d.ts.map +1 -1
  579. package/src/shade/renderer/rasterize/native/avboit/graph_rasterize_meshes_transparent_avboit.js +12 -4
  580. package/src/shade/renderer/rasterize/native/avboit/shader_avboit_draw_brick4.d.ts.map +1 -1
  581. package/src/shade/renderer/rasterize/native/avboit/shader_avboit_draw_brick4.js +4 -3
  582. package/src/shade/renderer/rasterize/native/avboit/shader_avboit_draw_ibl.d.ts.map +1 -1
  583. package/src/shade/renderer/rasterize/native/avboit/shader_avboit_draw_ibl.js +4 -3
  584. package/src/shade/renderer/rasterize/native/oit/graph_rasterize_meshes_transparent_oit.d.ts +2 -1
  585. package/src/shade/renderer/rasterize/native/oit/graph_rasterize_meshes_transparent_oit.d.ts.map +1 -1
  586. package/src/shade/renderer/rasterize/native/oit/graph_rasterize_meshes_transparent_oit.js +11 -3
  587. package/src/shade/renderer/rasterize/native/oit/shader_oit_resolve_moments.d.ts.map +1 -1
  588. package/src/shade/renderer/rasterize/native/oit/shader_oit_resolve_moments.js +4 -3
  589. package/src/shade/renderer/rasterize/native/oit/shader_oit_resolve_moments_ibl.d.ts.map +1 -1
  590. package/src/shade/renderer/rasterize/native/oit/shader_oit_resolve_moments_ibl.js +4 -3
  591. package/src/shade/renderer/rasterize/standard/graph_rasterize_partial_opaque.d.ts +15 -0
  592. package/src/shade/renderer/rasterize/standard/graph_rasterize_partial_opaque.d.ts.map +1 -1
  593. package/src/shade/renderer/rasterize/standard/graph_rasterize_partial_opaque.js +35 -2
  594. package/src/shade/renderer/rasterize/standard/graph_rasterize_remaining_opaque.d.ts +14 -0
  595. package/src/shade/renderer/rasterize/standard/graph_rasterize_remaining_opaque.d.ts.map +1 -1
  596. package/src/shade/renderer/rasterize/standard/graph_rasterize_remaining_opaque.js +32 -4
  597. package/src/shade/renderer/rasterize/standard/graph_rasterize_scene.d.ts +17 -0
  598. package/src/shade/renderer/rasterize/standard/graph_rasterize_scene.d.ts.map +1 -1
  599. package/src/shade/renderer/rasterize/standard/graph_rasterize_scene.js +34 -4
  600. package/src/shade/renderer/restir/di/chunk_restir_resolve.d.ts +5 -3
  601. package/src/shade/renderer/restir/di/chunk_restir_resolve.d.ts.map +1 -1
  602. package/src/shade/renderer/restir/di/chunk_restir_resolve.js +8 -3
  603. package/src/shade/renderer/restir/di/graph_restir_di.d.ts.map +1 -1
  604. package/src/shade/renderer/restir/di/graph_restir_di.js +1 -0
  605. package/src/shade/renderer/restir/di/shader_restir_di_resolve.d.ts.map +1 -1
  606. package/src/shade/renderer/restir/di/shader_restir_di_resolve.js +5 -1
  607. package/src/shade/renderer/restir/reservoir/shader.d.ts.map +1 -1
  608. package/src/shade/renderer/restir/reservoir/shader.js +7 -4
  609. package/src/shade/renderer/scene/GPUInstancesAccelerationStructure.d.ts +7 -0
  610. package/src/shade/renderer/scene/GPUInstancesAccelerationStructure.d.ts.map +1 -1
  611. package/src/shade/renderer/scene/GPUInstancesAccelerationStructure.js +13 -1
  612. package/src/shade/renderer/scene/GPUSceneContext.d.ts +10 -0
  613. package/src/shade/renderer/scene/GPUSceneContext.d.ts.map +1 -1
  614. package/src/shade/renderer/scene/GPUSceneContext.js +19 -0
  615. package/src/shade/renderer/scene/SceneManager.d.ts +9 -0
  616. package/src/shade/renderer/scene/SceneManager.d.ts.map +1 -1
  617. package/src/shade/renderer/scene/SceneManager.js +11 -0
  618. package/src/shade/renderer/scene/hierarchy/graph_nodes_update_transform_hierarchy.d.ts +11 -0
  619. package/src/shade/renderer/scene/hierarchy/graph_nodes_update_transform_hierarchy.d.ts.map +1 -1
  620. package/src/shade/renderer/scene/hierarchy/graph_nodes_update_transform_hierarchy.js +17 -0
  621. package/src/shade/renderer/scene/hierarchy/graph_scene_update_transform_hierarchy.d.ts +11 -0
  622. package/src/shade/renderer/scene/hierarchy/graph_scene_update_transform_hierarchy.d.ts.map +1 -1
  623. package/src/shade/renderer/scene/hierarchy/graph_scene_update_transform_hierarchy.js +18 -1
  624. package/src/shade/renderer/shader/ComputeShader.d.ts +12 -0
  625. package/src/shade/renderer/shader/ComputeShader.d.ts.map +1 -1
  626. package/src/shade/renderer/shader/ComputeShader.js +71 -2
  627. package/src/shade/renderer/shader/ImageShader.d.ts +27 -8
  628. package/src/shade/renderer/shader/ImageShader.d.ts.map +1 -1
  629. package/src/shade/renderer/shader/ImageShader.js +299 -218
  630. package/src/shade/renderer/shader/ShaderDescriptor.d.ts +21 -0
  631. package/src/shade/renderer/shader/ShaderDescriptor.d.ts.map +1 -1
  632. package/src/shade/renderer/shader/ShaderDescriptor.js +71 -1
  633. package/src/shade/renderer/shader/chunk/camera/chunk_project_view_position_from_depth.d.ts +17 -0
  634. package/src/shade/renderer/shader/chunk/camera/chunk_project_view_position_from_depth.d.ts.map +1 -0
  635. package/src/shade/renderer/shader/chunk/camera/chunk_project_view_position_from_depth.js +45 -0
  636. package/src/shade/renderer/shader/chunk/camera/chunk_screen_coordinate_to_view.js +3 -3
  637. package/src/shade/renderer/shader/chunk/color/iCtCp/chunk_eotf_st2084.d.ts +1 -1
  638. package/src/shade/renderer/shader/chunk/color/iCtCp/chunk_eotf_st2084.js +62 -62
  639. package/src/shade/renderer/shader/chunk/color/tonemap/HDR_TONE_MAPPING_FORMS_BRIEF_2026_10_16.md +318 -0
  640. package/src/shade/renderer/shader/chunk/color/tonemap/SDR_TONE_MAPPING_BRIEF_2026_10_16.md +237 -0
  641. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_PAPER_WHITE_NITS.d.ts +17 -0
  642. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_PAPER_WHITE_NITS.d.ts.map +1 -0
  643. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_PAPER_WHITE_NITS.js +22 -0
  644. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_tonemap_khronos_pbr.d.ts +14 -1
  645. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_tonemap_khronos_pbr.d.ts.map +1 -1
  646. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_tonemap_khronos_pbr.js +28 -15
  647. package/src/shade/renderer/shader/chunk/color/tonemap/gt7/chunk_tonemap_gt7.d.ts +12 -0
  648. package/src/shade/renderer/shader/chunk/color/tonemap/gt7/chunk_tonemap_gt7.d.ts.map +1 -1
  649. package/src/shade/renderer/shader/chunk/color/tonemap/gt7/chunk_tonemap_gt7.js +128 -110
  650. package/src/shade/renderer/shader/chunk/geometry/ray/chunk_offset_ray_from_depth.d.ts +20 -0
  651. package/src/shade/renderer/shader/chunk/geometry/ray/chunk_offset_ray_from_depth.d.ts.map +1 -0
  652. package/src/shade/renderer/shader/chunk/geometry/ray/chunk_offset_ray_from_depth.js +33 -0
  653. package/src/shade/renderer/shader/chunk/light/chunk_compute_multiscattering_specular.d.ts +4 -0
  654. package/src/shade/renderer/shader/chunk/light/chunk_compute_multiscattering_specular.d.ts.map +1 -1
  655. package/src/shade/renderer/shader/chunk/light/chunk_compute_multiscattering_specular.js +12 -1
  656. package/src/shade/renderer/shader/chunk/material/MATERIAL_SHADING_INFO_STRUCT.d.ts.map +1 -1
  657. package/src/shade/renderer/shader/chunk/material/MATERIAL_SHADING_INFO_STRUCT.js +7 -0
  658. package/src/shade/renderer/shader/chunk/material/MULTISCATTER.md +108 -0
  659. package/src/shade/renderer/shader/chunk/material/chunk_compute_indirect_specular.d.ts.map +1 -1
  660. package/src/shade/renderer/shader/chunk/material/chunk_compute_indirect_specular.js +23 -4
  661. package/src/shade/renderer/shader/chunk/material/chunk_re_direct_multiscatter.d.ts +18 -0
  662. package/src/shade/renderer/shader/chunk/material/chunk_re_direct_multiscatter.d.ts.map +1 -0
  663. package/src/shade/renderer/shader/chunk/material/chunk_re_direct_multiscatter.js +56 -0
  664. package/src/shade/renderer/shader/chunk/material/chunk_re_indirect_specular_physical.d.ts.map +1 -1
  665. package/src/shade/renderer/shader/chunk/material/chunk_re_indirect_specular_physical.js +2 -0
  666. package/src/shade/renderer/shader/chunk/screen_space/chunk_screen_space_linear_ray.d.ts +43 -0
  667. package/src/shade/renderer/shader/chunk/screen_space/chunk_screen_space_linear_ray.d.ts.map +1 -0
  668. package/src/shade/renderer/shader/chunk/screen_space/chunk_screen_space_linear_ray.js +319 -0
  669. package/src/shade/renderer/shader/compiler/CodeChunk.d.ts +33 -0
  670. package/src/shade/renderer/shader/compiler/CodeChunk.d.ts.map +1 -1
  671. package/src/shade/renderer/shader/compiler/CodeChunk.js +140 -0
  672. package/src/shade/renderer/shader/compiler/CodeChunkChoice.d.ts +74 -0
  673. package/src/shade/renderer/shader/compiler/CodeChunkChoice.d.ts.map +1 -0
  674. package/src/shade/renderer/shader/compiler/CodeChunkChoice.js +166 -0
  675. package/src/shade/renderer/shader/compiler/SHADER_SWITCH_PROPOSAL_2026_10_16.md +680 -0
  676. package/src/shade/renderer/shader/compiler/ShaderSwitch.d.ts +86 -0
  677. package/src/shade/renderer/shader/compiler/ShaderSwitch.d.ts.map +1 -0
  678. package/src/shade/renderer/shader/compiler/ShaderSwitch.js +178 -0
  679. package/src/shade/renderer/shader/compiler/ShaderSwitchSet.d.ts +67 -0
  680. package/src/shade/renderer/shader/compiler/ShaderSwitchSet.d.ts.map +1 -0
  681. package/src/shade/renderer/shader/compiler/ShaderSwitchSet.js +205 -0
  682. package/src/shade/renderer/shadow/contact/CONTACT_SHADOW_WAVE_SIZE.d.ts +14 -0
  683. package/src/shade/renderer/shadow/contact/CONTACT_SHADOW_WAVE_SIZE.d.ts.map +1 -0
  684. package/src/shade/renderer/shadow/contact/CONTACT_SHADOW_WAVE_SIZE.js +13 -0
  685. package/src/shade/renderer/shadow/contact/ContactShadowDispatchList.d.ts +65 -0
  686. package/src/shade/renderer/shadow/contact/ContactShadowDispatchList.d.ts.map +1 -0
  687. package/src/shade/renderer/shadow/contact/ContactShadowDispatchList.js +252 -0
  688. package/src/shade/renderer/shadow/contact/FINDINGS.md +413 -0
  689. package/src/shade/renderer/shadow/contact/chunk_contact_shadow_wavefront_extents.d.ts +29 -0
  690. package/src/shade/renderer/shadow/contact/chunk_contact_shadow_wavefront_extents.d.ts.map +1 -0
  691. package/src/shade/renderer/shadow/contact/chunk_contact_shadow_wavefront_extents.js +105 -0
  692. package/src/shade/renderer/shadow/contact/graph_contact_shadow_linear.d.ts +29 -0
  693. package/src/shade/renderer/shadow/contact/graph_contact_shadow_linear.d.ts.map +1 -0
  694. package/src/shade/renderer/shadow/contact/graph_contact_shadow_linear.js +39 -0
  695. package/src/shade/renderer/shadow/contact/graph_contact_shadow_wavefront.d.ts +29 -0
  696. package/src/shade/renderer/shadow/contact/graph_contact_shadow_wavefront.d.ts.map +1 -0
  697. package/src/shade/renderer/shadow/contact/graph_contact_shadow_wavefront.js +92 -0
  698. package/src/shade/renderer/shadow/contact/shader_contact_shadow_linear.d.ts +29 -0
  699. package/src/shade/renderer/shadow/contact/shader_contact_shadow_linear.d.ts.map +1 -0
  700. package/src/shade/renderer/shadow/contact/shader_contact_shadow_linear.js +128 -0
  701. package/src/shade/renderer/shadow/contact/shader_contact_shadow_wavefront.d.ts +52 -0
  702. package/src/shade/renderer/shadow/contact/shader_contact_shadow_wavefront.d.ts.map +1 -0
  703. package/src/shade/renderer/shadow/contact/shader_contact_shadow_wavefront.js +358 -0
  704. package/src/shade/renderer/shadow/map/ShadowDirectionalTechnique.d.ts +10 -0
  705. package/src/shade/renderer/shadow/map/ShadowDirectionalTechnique.d.ts.map +1 -0
  706. package/src/shade/renderer/shadow/map/ShadowDirectionalTechnique.js +12 -0
  707. package/src/shade/renderer/shadow/map/shader/SHADOW_DIRECTIONAL_TECHNIQUE.d.ts +13 -0
  708. package/src/shade/renderer/shadow/map/shader/SHADOW_DIRECTIONAL_TECHNIQUE.d.ts.map +1 -0
  709. package/src/shade/renderer/shadow/map/shader/SHADOW_DIRECTIONAL_TECHNIQUE.js +14 -0
  710. package/src/shade/renderer/shadow/map/shader/chunk_shadowmap_sample_directional.d.ts +14 -8
  711. package/src/shade/renderer/shadow/map/shader/chunk_shadowmap_sample_directional.d.ts.map +1 -1
  712. package/src/shade/renderer/shadow/map/shader/chunk_shadowmap_sample_directional.js +20 -86
  713. package/src/shade/renderer/shadow/map/shader/chunk_shadowmap_sample_directional_cascades.d.ts +14 -0
  714. package/src/shade/renderer/shadow/map/shader/chunk_shadowmap_sample_directional_cascades.d.ts.map +1 -0
  715. package/src/shade/renderer/shadow/map/shader/chunk_shadowmap_sample_directional_cascades.js +79 -0
  716. package/src/shade/renderer/shadow/ray/shader_ray_shadow_code.d.ts.map +1 -1
  717. package/src/shade/renderer/shadow/ray/shader_ray_shadow_code.js +12 -12
  718. package/src/shade/renderer/shadow/ray/staged/gen/shader_generate_rays.d.ts.map +1 -1
  719. package/src/shade/renderer/shadow/ray/staged/gen/shader_generate_rays.js +153 -151
  720. package/src/shade/renderer/shadow/vsm/shader/chunk_shadowmap_sample_directional_virtual.d.ts +13 -0
  721. package/src/shade/renderer/shadow/vsm/shader/chunk_shadowmap_sample_directional_virtual.d.ts.map +1 -0
  722. package/src/shade/renderer/shadow/vsm/shader/chunk_shadowmap_sample_directional_virtual.js +48 -0
  723. package/src/shade/renderer/texture/GPUTextureContext.d.ts +10 -0
  724. package/src/shade/renderer/texture/GPUTextureContext.d.ts.map +1 -1
  725. package/src/shade/renderer/texture/GPUTextureContext.js +24 -0
  726. package/src/shade/renderer/texture/atlas/GPUTileAtlas3D.d.ts +219 -0
  727. package/src/shade/renderer/texture/atlas/GPUTileAtlas3D.d.ts.map +1 -0
  728. package/src/shade/renderer/texture/atlas/GPUTileAtlas3D.js +671 -0
  729. package/src/shade/renderer/volumetrics/GPUSceneVolumetrics.d.ts +26 -2
  730. package/src/shade/renderer/volumetrics/GPUSceneVolumetrics.d.ts.map +1 -1
  731. package/src/shade/renderer/volumetrics/GPUSceneVolumetrics.js +108 -4
  732. package/src/shade/renderer/volumetrics/GPUViewVolumetrics.d.ts +5 -1
  733. package/src/shade/renderer/volumetrics/GPUViewVolumetrics.d.ts.map +1 -1
  734. package/src/shade/renderer/volumetrics/GPUViewVolumetrics.js +6 -0
  735. package/src/shade/renderer/volumetrics/NOTES.md +50 -0
  736. package/src/shade/renderer/volumetrics/PARTICIPATING_MEDIA_VOLUME_STRUCT.d.ts.map +1 -1
  737. package/src/shade/renderer/volumetrics/PARTICIPATING_MEDIA_VOLUME_STRUCT.js +30 -1
  738. package/src/shade/renderer/volumetrics/ParticipatingMediaVolume.d.ts +51 -13
  739. package/src/shade/renderer/volumetrics/ParticipatingMediaVolume.d.ts.map +1 -1
  740. package/src/shade/renderer/volumetrics/ParticipatingMediaVolume.js +98 -13
  741. package/src/shade/renderer/volumetrics/SceneVolumetrics.d.ts +9 -0
  742. package/src/shade/renderer/volumetrics/SceneVolumetrics.d.ts.map +1 -1
  743. package/src/shade/renderer/volumetrics/SceneVolumetrics.js +78 -68
  744. package/src/shade/renderer/volumetrics/VOLUMETRIC_NOISE_PLAN_2026_10_15.md +326 -0
  745. package/src/shade/renderer/volumetrics/chunk_participating_media_volume_sample.d.ts +7 -4
  746. package/src/shade/renderer/volumetrics/chunk_participating_media_volume_sample.d.ts.map +1 -1
  747. package/src/shade/renderer/volumetrics/chunk_participating_media_volume_sample.js +21 -9
  748. package/src/shade/renderer/volumetrics/chunk_volumetrics_froxel_uvw_from_clip.d.ts +19 -0
  749. package/src/shade/renderer/volumetrics/chunk_volumetrics_froxel_uvw_from_clip.d.ts.map +1 -0
  750. package/src/shade/renderer/volumetrics/chunk_volumetrics_froxel_uvw_from_clip.js +53 -0
  751. package/src/shade/renderer/volumetrics/chunk_volumetrics_sample_froxel_extinction.d.ts +12 -3
  752. package/src/shade/renderer/volumetrics/chunk_volumetrics_sample_froxel_extinction.d.ts.map +1 -1
  753. package/src/shade/renderer/volumetrics/chunk_volumetrics_sample_froxel_extinction.js +85 -48
  754. package/src/shade/renderer/volumetrics/graph_build_froxel_irradiance.d.ts +4 -1
  755. package/src/shade/renderer/volumetrics/graph_build_froxel_irradiance.d.ts.map +1 -1
  756. package/src/shade/renderer/volumetrics/graph_build_froxel_irradiance.js +4 -1
  757. package/src/shade/renderer/volumetrics/graph_build_volumetrics.d.ts +4 -1
  758. package/src/shade/renderer/volumetrics/graph_build_volumetrics.d.ts.map +1 -1
  759. package/src/shade/renderer/volumetrics/graph_build_volumetrics.js +21 -1
  760. package/src/shade/renderer/volumetrics/noise/PARTICIPATING_MEDIA_NOISE.d.ts +98 -0
  761. package/src/shade/renderer/volumetrics/noise/PARTICIPATING_MEDIA_NOISE.d.ts.map +1 -0
  762. package/src/shade/renderer/volumetrics/noise/PARTICIPATING_MEDIA_NOISE.js +115 -0
  763. package/src/shade/renderer/volumetrics/noise/VOLUMETRICS_NOISE_TILE_BAKE_SETTINGS_STRUCT.d.ts +9 -0
  764. package/src/shade/renderer/volumetrics/noise/VOLUMETRICS_NOISE_TILE_BAKE_SETTINGS_STRUCT.d.ts.map +1 -0
  765. package/src/shade/renderer/volumetrics/noise/VOLUMETRICS_NOISE_TILE_BAKE_SETTINGS_STRUCT.js +24 -0
  766. package/src/shade/renderer/volumetrics/noise/bake_volumetrics_noise_tile.d.ts +27 -0
  767. package/src/shade/renderer/volumetrics/noise/bake_volumetrics_noise_tile.d.ts.map +1 -0
  768. package/src/shade/renderer/volumetrics/noise/bake_volumetrics_noise_tile.js +91 -0
  769. package/src/shade/renderer/volumetrics/noise/chunk_participating_media_noise.d.ts +35 -0
  770. package/src/shade/renderer/volumetrics/noise/chunk_participating_media_noise.d.ts.map +1 -0
  771. package/src/shade/renderer/volumetrics/noise/chunk_participating_media_noise.js +92 -0
  772. package/src/shade/renderer/volumetrics/noise/shader_volumetrics_noise_tile_bake.d.ts +10 -0
  773. package/src/shade/renderer/volumetrics/noise/shader_volumetrics_noise_tile_bake.d.ts.map +1 -0
  774. package/src/shade/renderer/volumetrics/noise/shader_volumetrics_noise_tile_bake.js +121 -0
  775. package/src/shade/renderer/volumetrics/shader_volumetrics_build_participating_media.d.ts.map +1 -1
  776. package/src/shade/renderer/volumetrics/shader_volumetrics_build_participating_media.js +38 -3
  777. package/src/shade/renderer/volumetrics/shader_volumetrics_build_sun_shadow_volume.d.ts.map +1 -1
  778. package/src/shade/renderer/volumetrics/shader_volumetrics_build_sun_shadow_volume.js +311 -290
  779. package/src/shade/renderer/volumetrics/volumetrics_position_world_to_froxel_uvw.d.ts.map +1 -1
  780. package/src/shade/renderer/volumetrics/volumetrics_position_world_to_froxel_uvw.js +28 -49
  781. package/src/shade/renderer/water/GPUWaterRenderer.d.ts +3 -1
  782. package/src/shade/renderer/water/GPUWaterRenderer.d.ts.map +1 -1
  783. package/src/shade/renderer/water/GPUWaterRenderer.js +24 -18
  784. package/src/shade/renderer/water/chunk_water_transport.d.ts +0 -1
  785. package/src/shade/renderer/water/chunk_water_transport.d.ts.map +1 -1
  786. package/src/shade/renderer/water/chunk_water_transport.js +0 -17
  787. package/src/shade/renderer/water/shader_water.d.ts +4 -2
  788. package/src/shade/renderer/water/shader_water.d.ts.map +1 -1
  789. package/src/shade/renderer/water/shader_water.js +27 -16
  790. package/src/shade/renderer/water/shader_water_avboit.d.ts +0 -4
  791. package/src/shade/renderer/water/shader_water_avboit.d.ts.map +1 -1
  792. package/src/shade/renderer/water/shader_water_avboit.js +0 -63
  793. package/src/shade/wgsl/emulator/WGSLJavaScriptCompiler.d.ts.map +1 -1
  794. package/src/shade/wgsl/emulator/WGSLJavaScriptCompiler.js +43 -9
  795. package/src/view/graphics/GraphicsContextFailureView.d.ts +1 -2
  796. package/src/view/graphics/GraphicsContextFailureView.d.ts.map +1 -1
  797. package/src/view/graphics/GraphicsContextFailureView.js +1 -2
  798. package/src/engine/network/transport/Channel.d.ts +0 -85
  799. package/src/engine/network/transport/Channel.d.ts.map +0 -1
  800. package/src/engine/network/transport/Channel.js +0 -336
  801. package/src/engine/network/transport/ReliableCommandPipeline.d.ts +0 -155
  802. package/src/engine/network/transport/ReliableCommandPipeline.d.ts.map +0 -1
  803. package/src/engine/network/transport/ReliableCommandPipeline.js +0 -335
  804. package/src/engine/network/transport/fragments/FragmentAssembler.d.ts +0 -105
  805. package/src/engine/network/transport/fragments/FragmentAssembler.d.ts.map +0 -1
  806. package/src/engine/network/transport/fragments/FragmentAssembler.js +0 -350
  807. package/src/engine/network/transport/fragments/FragmentRetention.d.ts +0 -103
  808. package/src/engine/network/transport/fragments/FragmentRetention.d.ts.map +0 -1
  809. package/src/engine/network/transport/fragments/FragmentRetention.js +0 -191
  810. package/src/engine/network/transport/fragments/fragment_send.d.ts +0 -61
  811. package/src/engine/network/transport/fragments/fragment_send.d.ts.map +0 -1
  812. package/src/engine/network/transport/fragments/fragment_send.js +0 -157
  813. package/src/engine/network/transport/fragments/packet_size.d.ts +0 -99
  814. package/src/engine/network/transport/fragments/packet_size.d.ts.map +0 -1
  815. package/src/engine/network/transport/fragments/packet_size.js +0 -107
  816. package/src/shade/renderer/shader/chunk/color/sRGB/chunk_RRTAndODTFit.d.ts +0 -6
  817. package/src/shade/renderer/shader/chunk/color/sRGB/chunk_RRTAndODTFit.d.ts.map +0 -1
  818. package/src/shade/renderer/shader/chunk/color/sRGB/chunk_RRTAndODTFit.js +0 -16
  819. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_tonemap_aces.d.ts +0 -7
  820. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_tonemap_aces.d.ts.map +0 -1
  821. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_tonemap_aces.js +0 -46
  822. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_tonemap_agx.d.ts +0 -10
  823. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_tonemap_agx.d.ts.map +0 -1
  824. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_tonemap_agx.js +0 -127
  825. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_tonemap_pbr_neutral.d.ts +0 -7
  826. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_tonemap_pbr_neutral.d.ts.map +0 -1
  827. package/src/shade/renderer/shader/chunk/color/tonemap/chunk_tonemap_pbr_neutral.js +0 -39
@@ -4909,3 +4909,357 @@ reached the block. A mutant that changes `θ` by a part in a thousand in one arm
4909
4909
  fails those two runs and no other. The extended cloth specs 10, unchanged. The whole physics suite
4910
4910
  with its slow, bench and extended specs (`--mode all`): 187 files and 1,898 tests, green,
4911
4911
  `cloth_pathology` among them. `check-types` 18 against a budget of 19.
4912
+
4913
+ ---
4914
+
4915
+ ## 67. The cloth-skirt example: a contact that arrives soft, and a self radius capped by the waistband
4916
+
4917
+ The website's cloth-skirt example (`meep-website/examples-src/cloth-skirt`, engine 3.46.0, whose cloth
4918
+ code is this tree's) shows "a bunch of visible penetrations". This section is the replay that found
4919
+ them, the two mechanisms behind them, the fix that landed for one, and three candidates measured for the
4920
+ other. Scripts, raw logs and frame renders are in the session's scratchpad (`probes/`), named below.
4921
+
4922
+ ### The example, replayed headlessly
4923
+
4924
+ `skirt_repro.probe.js` rebuilds the example through the real `ClothSystem`: the 64×13 circle skirt from
4925
+ `cloth_proxy_from_mesh` (832 particles, rows from 9.8 mm at the waistband to 54 mm at the hem), the
4926
+ mannequin's eleven cloth colliders driven by `rumba-track.json` at 60 Hz (thighs to 2.8 m/s, their tips
4927
+ to 4.9), the waistband pinned to the abdomen, bend 0.63, damping 0.0125, 6 mm, 2×4, self-collision on.
4928
+ 25 s, 1,500 steps; the dance is steps 96 onward (1,404 steps). Every metric is in **vertex order** —
4929
+ `ClothState#position` is colour-permuted and `ClothInstance#particle_of_node` maps back; read in particle
4930
+ order the triangle metrics are garbage (30,000 "crossings" on a flat ring). Per step: how far any free
4931
+ particle is inside any body collider and short of the 6 mm contact offset; how far the rendered surface
4932
+ (triangle centroids, edge midpoints) is inside one, and separately the **sag**, surface inside with every
4933
+ corner outside; pinches (inside one collider, within the offset of another); forearms or hands through the
4934
+ surface; contact-slot overflow; inside-episode lengths; and every 30 steps §31's crossings, edges through
4935
+ triangles they share no vertex with.
4936
+
4937
+ ```
4938
+ dance, 1,404 steps shipped 2×4 4×8 budget 128×25 mesh at 2×4
4939
+
4940
+ steps with a particle inside 12.7% 0.0% 11.5%
4941
+ deepest particle penetration 12.6 mm 3.8 mm 13.8 mm
4942
+ short of the 6 mm offset by > 1 mm 8.1 mean 0.4 14.1
4943
+ inside episodes, median / max steps 1 / 6 1 / 1 1 / 4
4944
+ surface sag > 5 mm, corners outside 1.4% (8 mm) 0% 0%
4945
+ self-crossings a sample, mean / max 406 / 584 272 / 683 2,132 / 2,716
4946
+ pinched particles 1.4%, max 2 0 1.0%, max 12
4947
+ forearm or hand through the surface never never never
4948
+ contact slots full mean 0.04 0.01 0.21
4949
+ ```
4950
+
4951
+ **Two mechanisms, and they separate on the first two columns.** The thighs through the skirt vanish at
4952
+ 4×8 and do not move with resolution, so they are the contact row's convergence under a sweeping collider.
4953
+ The crossings do not move with the budget, so they are the self-collision model. Neither is the descent.
4954
+
4955
+ ### Why the thigh showed: the ramp, in ratio terms
4956
+
4957
+ A thigh advances 17 mm a substep. A new contact starts at `CLOTH_CONTACT_K_MIN_RATIO = 0.25` of
4958
+ `m/h²` — 72 N/m for a 20 g particle at two substeps — and climbed by `β·|C| = 1e3 × 0.017 = 17 N/m` an
4959
+ iteration against a ceiling of `8·m/h² = 2,300 N/m`. In the band's own units that is **0.003 of the band
4960
+ per contact offset of violation per iteration**: against a limb the penalty never left the floor, the
4961
+ multiplier had to carry the push and was rebuilt from a quarter every substep, and four iterations
4962
+ built about 60% of it. The thigh sat 5 to 13 mm through for one to six steps on every forward swing.
4963
+ The measurement that chose `β` (§17) was a sheet landing on a floor, where the violation per substep
4964
+ after touchdown is `h²g`, a third of a millimetre. The reference 2D implementation (Giles et al.) ramps
4965
+ at `β = 1e5` against `m/h² ≈ 3,600` and a floor of 1, which is about eight times this engine's rate
4966
+ relative to the inertial scale, and ramps active rows only.
4967
+
4968
+ `cloth_contact_dual_update` now climbs by `ρ·k_max·|C|/(thickness + inflation)`,
4969
+ `ρ = CLOTH_CONTACT_RAMP_RATIO`. The sweep, dance steps with any particle inside / the deepest shortfall of
4970
+ the offset / the peak particle speed in the dance:
4971
+
4972
+ ```
4973
+ variant inside shortfall peak m/s
4974
+ shipped, floor ¼, β = 1e3 12.7% 18.6 mm 3.95
4975
+ floor 1× 1.9% 19.1 3.47
4976
+ floor 8× (the ceiling) 1.1% 17.6 6.02 episodes median 4: slaps
4977
+ β = 1e4 0.2% 13.2 8.41 a spike
4978
+ β = 1e5 0.6% 17.7 3.84
4979
+ ratio ρ = 0.03 0.5% 13.1 4.79
4980
+ ratio ρ = 0.05 0.1% 10.4 3.63
4981
+ ratio ρ = 0.1 0.1% 7.7 3.73
4982
+ ratio ρ = 0.15 0.0% 5.0 3.49
4983
+ ratio ρ = 1 0.1% 7.3 3.23
4984
+ ratio ρ = 4 0.3% 16.0 4.25
4985
+ ρ = 0.1, active rows only 1.0% 15.5 3.93
4986
+ ρ = 1, active rows only 0.4% 12.7 3.27
4987
+ ρ = 0.1, seeded from the predicted violation at discovery, then active only
4988
+ 0.4% 13.9 3.81
4989
+ ```
4990
+
4991
+ The plateau starts at 0.05. Ramping active rows only — the reference's form, and the one-sided ramp §54
4992
+ rejected under `β` — leaves the thigh through ten times as often and takes the thrown particle's stopped
4993
+ speed (`cloth_contact_row.spec`'s capsule) from 6 to 4 m/s at two substeps and 12 to 9 at four; seeding
4994
+ a new row's penalty from Lewin's semi-continuous estimate of its violation over the step, then ramping
4995
+ active rows only, does no better. The pre-stiffening of speculative rows is what a fast arrival hits,
4996
+ twice measured, and it stays. The tunnelling threshold does not move at any ρ: 6 m/s at two substeps,
4997
+ 12 at four, the substep bound §7 P3 states; the speeds just past it are chaotic (8 m/s is stopped under
4998
+ one ramp and not another), which is why the gate now pins 10 and 12.
4999
+
5000
+ ### What a ratio ramp does to resting cloth, and the decay
5001
+
5002
+ With the ratio ramp every row violated by millimetres while a pile lands is at the ceiling for good, and
5003
+ at the ceiling §53's limit cycle is too large for silk to sleep. `cloth_sheet.slow.spec`'s three scenes
5004
+ under each form (the twirled skirt's gate is "settles within 2 mm of where it hung"):
5005
+
5006
+ ```
5007
+ form ribbon pile skirt settle draped sheet carried
5008
+ shipped β asleep at 166 0.9 mm 338°
5009
+ ρ = 0.1, unconditional never 17.1 mm 316° (gate ≥ 320°)
5010
+ ρ = 0.1, active rows only never 2.2 mm 318°
5011
+ ρ = 0.1, seeded + active never 2.4 mm pass
5012
+ ρ = 0.1, penalties decay 0.9 pass 26.2 mm pass
5013
+ ρ = 0.1, penalties decay 0.8 pass pass pass
5014
+ ρ = 0.1, penalties decay 0.5 pass 3.2 mm pass
5015
+ ```
5016
+
5017
+ Active rows only fails it too, and that is the tell: the problem is not the pre-stiffening of
5018
+ speculative rows but the penalty a row is *left with* once it has been violated. The resolution is the
5019
+ one §18 named when it recorded the coupling, a `γ < 1` for contacts: `CLOTH_CONTACT_GAMMA` decays a
5020
+ contact's two penalties per substep at the warm start, the multiplier's `α·γ` untouched, so a quiet row
5021
+ sinks back to the floor in a few steps while the multiplier carries its load, and a violated one
5022
+ re-climbs within an iteration. `rope_sleep.probe.js`, the 6-link rope of §53 on a floor, asleep at step:
5023
+
5024
+ ```
5025
+ penalties decayed both, γ_c 1 0.95 0.9 0.8 0.5
5026
+ floor, friction 0 326 501 377 308 1005
5027
+ floor, friction 0.5 193 208 194 196 353
5028
+ cotton rope, floor 0.5 347 220 247 264 277
5029
+ rope on a sphere 368 369 369 369 399
5030
+
5031
+ normal penalty only, γ_c 1 0.85 0.8 0.75 0.7
5032
+ floor, friction 0 326 377 308 376 never
5033
+ floor, friction 0.5 193 189 never never 209
5034
+ ```
5035
+
5036
+ Decaying the normal penalty alone makes the resting rope's sleep a coin toss; decaying both sleeps every
5037
+ scene from 0.5 to 0.95. **0.8** passes the three slow gates; 0.7, 0.75 and 0.85 leave the twirled skirt
5038
+ 2.7–2.9 mm from where it hung against a 2 mm gate, and 0.9 and 0.5 further. That settle is a chaotic
5039
+ quantity — folds fall differently — and 0.8 passing it is luck as much as merit; its real argument is the
5040
+ rope table, where 0.8 is in the middle of the flat region. On the skirt the decay changes nothing:
5041
+ 0.1% of steps inside at 0.8, 0.5% at 0.9.
5042
+
5043
+ ### Against the measurements that chose the shipped constants
5044
+
5045
+ `cloth_m2_measure.mjs`, the shipped build against the ratio ramp alone and with the decay:
5046
+
5047
+ ```
5048
+ shipped β ρ = 0.1 ρ = 0.1, γ_c = 0.8
5049
+ §17 sheet landing at 3 m/s, floor 1/32:
5050
+ worst penetration 1.10 mm 0.68 mm 0.69 mm
5051
+ kinetic energy at step 240 8.6e-9 J 1.1e-9 7.9e-9
5052
+ peak contact force 1.42 N 1.56 N 1.56 N
5053
+ §17 at 8 m/s: penetration / peak speed 1.69 / 3.64 0.72 / 3.44 0.70 / 3.44
5054
+ §6 capsule swept through a hanging sheet
5055
+ at 2 m/s, worst penetration 17.1 mm 1.8 mm 1.7 mm
5056
+ §5 sheet on a slope, metres slid in 4 s:
5057
+ 20°, μ = 0.4 (Coulomb: sticks) 0.194 0.000 0.553
5058
+ 10°, μ = 0.2 (Coulomb: sticks) 0.000 0.000 0.070
5059
+ 30°, μ = 0.7 (sticks) 0.000 0.000 0.0003
5060
+ 50°, μ = 1.2 (slides) 2.71 0.31 3.53
5061
+ ```
5062
+
5063
+ The ramp alone is better than the shipped build on every row, friction included — the marginal slope
5064
+ case sticks exactly as Coulomb says. The decay gives the friction back: a sheet that should stick creeps
5065
+ 0.2–0.3 mm in four seconds, and the marginal case slides 0.55 m where the shipped build slid 0.19. The
5066
+ friction row's penalty decays too because the normal-only decay is the erratic column above; the friction
5067
+ cap reads the current iteration's normal force (§8.3), which is what couples the two. That is the trade
5068
+ the pair makes, and it is recorded rather than tuned around: ρ = 0.1 with γ_c = 0.8 ships, both as
5069
+ `CLOTH_SOLVER_TUNING` fields, and the friction exactness is the cost.
5070
+
5071
+ ### What it costs elsewhere
5072
+
5073
+ A rope seeded with its tail 20 mm inside a sphere — `cloth_collision.spec`'s "far side of the room"
5074
+ rope — is ejected at 6.75 m/s in the shipped build and at 9.5 under ρ = 0.1; the gate noticed only
5075
+ because the rope left the sphere's gather reach two steps sooner. The sphere now sits beside the rope's
5076
+ middle, 22 mm off the links, gathered and never touched. The three gates in `cloth_contact_row.spec`
5077
+ that pinned the old arithmetic re-pin to the ratio, and a new one holds M2 §6's capsule at 2 m/s to
5078
+ "never inside the surface" (17 mm red on the shipped ramp, 1.8 mm green). The gather and warm-start
5079
+ costs nothing: paired in one process, five skirts stepped alternately, the ratio ramp reads 0.97× the
5080
+ shipped step.
5081
+
5082
+ ### Self-collision: three candidates against the hem
5083
+
5084
+ The hem's problem is that `ClothState#self_radius` is one number, `max(thickness, ½·shortest row)` capped
5085
+ at `0.4 × closest free pair`, and both lengths are measured over the whole cloth: the waistband's 9.8 mm
5086
+ rows and 19.6 mm closest free pair give the 54 mm hem a 6 mm radius. §18 carries it. Three answers were
5087
+ measured on the skirt (dance, ρ = 0.1, γ_c = 0.8 throughout) and on §64's eleven ribbon piles
5088
+ (`ribbons.probe.js`: silk strips 16×3 at 3 cm on a floor with friction 0.5, 2,400 steps or asleep):
5089
+
5090
+ ```
5091
+ skirt inside shortfall crossings mean / max kinetic J pairs step cost
5092
+ pair row as shipped 0.1% 10.4 mm 432 / 632 2.58 44
5093
+ per-particle radius 0.0% 5.1 102 / 180 2.87 135 0.94×
5094
+ predicted travel in the search 0.1% 8.8 412 / 620 2.56 54
5095
+ frozen pair normal 1.9% 14.8 424 / 663 2.60 46
5096
+ travel + frozen 0.0% 4.3 443 / 715 2.43 55
5097
+ frozen, gated on the live distance 1.1% 13.0 438 / 697 2.52
5098
+ travel + per-particle 1.2% 16.2 38 / 144 2.86
5099
+ travel + frozen + per-particle 1.3% 17.3 35 / 125 2.80 79
5100
+ travel + gated frozen + per-particle 0.7% 14.6 27 / 101 2.79
5101
+ point-triangle rows + pair 6.3% 58.2 197 / 463 5.39, peak 18.8 m/s
5102
+ point-triangle + per-particle 6.6% 56.4 89 / 322 6.81, peak 18.8
5103
+ point-triangle + travel + frozen + pp 5.3% 55.3 56 / 273 6.33, peak 18.8
5104
+ point-triangle alone 6.5% 45.3 237 / 1,015 5.61, peak 18.8
5105
+
5106
+ ribbon piles, 11 scenes asleep clean (no crossing ever) order kept worst crossings, mean
5107
+ pair row as shipped 11 6 7 7.5
5108
+ predicted travel in the search 11 9 9 5.7
5109
+ frozen pair normal 11 9 9 1.6
5110
+ travel + frozen 11 10 11 0.2
5111
+ travel + frozen, gated on the distance 11 10 11 0.2
5112
+ point-triangle alone 5 7 9 34.2
5113
+ point-triangle + pair 11 7 10 1.6
5114
+ point-triangle + pair + travel + frozen 11 11 11 0.0
5115
+ ```
5116
+
5117
+ **The per-particle radius** — the shipped formula applied locally,
5118
+ `r_i = clamp(thickness, ½·shortest row incident on i, 0.4 × closest free pair of i)` (the prototype used
5119
+ the sheet's analytic cap, `0.8·row`; the real one measures it) — takes the skirt's crossings down by
5120
+ three quarters with no collider cost and a cheaper step, because the hem holds itself apart and makes
5121
+ fewer contacts. It is still the sphere model. On the uniform ribbons it is the shipped row.
5122
+
5123
+ **Lewin's two moves on the pair row** (GDC 2018, "Cloth Self Collision with Predictive Contacts") are
5124
+ the semi-continuous candidate test — the relative displacement over the step projected on the separating
5125
+ direction, which is §35's missing travel term — and the pair's normal frozen for the step, which turns
5126
+ the row into a half-space no pair can pass through however far the other rows shove it. On the ribbon
5127
+ piles they are worth more than anything else measured: every pile asleep, ten of eleven never crossing,
5128
+ all eleven in order, the worst crossings 7.5 → 0.2 a scene. On the skirt they do not touch the
5129
+ crossings, which are the radius, and they cost limbs there: 1.9% of steps with a thigh through under
5130
+ the frozen normal against 0.1%, 1.1% with it gated on the live distance (a half-space stays active
5131
+ after its pair has slid apart tangentially, the artefact the talk names), and 1.2% for the travel term
5132
+ on top of the per-particle radius, where the two together take the crossings to 38. The piles keep
5133
+ their result under the gate. Why a wider or stickier pair row puts a hem particle into a thigh is not
5134
+ measured; the shape of it is a particle pinched between a fold and the limb, with the pair row a plain
5135
+ penalty whose shares over several pairs sum past one. It is the number that keeps the two moves from
5136
+ landing with the radius.
5137
+
5138
+ **Predictive point-triangle rows** were prototyped as the talk's self collision (`pt_rows.mjs`): a
5139
+ triangle-AABB hash grid extruded by displacement, the closest point for the weights and the fat-triangle
5140
+ test, the face normal signed to the point's side, `C = n̂·(x_p − Σ w x) − 2·thickness ≥ 0` frozen for the
5141
+ step, up to four rows a vertex, as plain penalties into the self row's Jacobi scratch. Three things were
5142
+ learned, each by a trace of two stacked ribbons (`ribbons_trace.probe.js`):
5143
+
5144
+ - As a penalty at the pair row's ratio the row cannot stop a ribbon landing at 10 mm a step inside
5145
+ 8 mm of separation; it ends 4 mm through, the next step's detection sides every row the other way,
5146
+ and the rows push the pile inside out. That is the talk's own "failures in collision detection cannot
5147
+ be corrected in subsequent frames", and why it shipped with authored layer order.
5148
+ - Stiffer is worse, explosively (peak speeds 3–6 m/s at 4× and 8×). A four-particle row updated
5149
+ Jacobi-style over-corrects: the participants' expected corrections sum to `κ/(1+κ) + 3κ/(9+κ)` for a
5150
+ centroid row, 1.03 at the prototype's κ = 1.5 and 2.6 at 8×. The pair row at ratio 2 sits at exactly 1,
5151
+ which is a mechanism for §65's "the stiffest ratio at which cloth resting on itself comes to rest".
5152
+ With each participant taking its mass-weighted share of the row the sum is 1 at any stiffness, and the
5153
+ landing ribbon is then stopped and rests at 7.7 mm.
5154
+ - With the split, on their own they sleep five of eleven piles, push the lowest ribbon into the floor
5155
+ and leave 34 crossings; with the pair row they add the eleventh clean pile; on the skirt every form is
5156
+ unstable — peak speeds at the velocity clamp, a thigh through in 5–7% of steps — with ~1,000 rows a
5157
+ step over 832 particles, where the shares of several rows on one particle sum past 1 again.
5158
+
5159
+ So the row that would close §9's gap is a hard row with a multiplier under a Gauss-Seidel treatment, not
5160
+ a penalty in the Jacobi scratch, and the talk's cost figures (20 ms to 1 s a frame for the general
5161
+ method; 0.1–0.2 ms with authored layers and cached contacts) say what that buys. M4b stays open.
5162
+
5163
+ ### Gates
5164
+
5165
+ Cloth suite 370 (from 369): `cloth_contact_row.spec` gains the swept capsule at 2 m/s, red on the
5166
+ shipped ramp at 17 mm. Three of its tests re-pin to the ratio ramp, and `cloth_collision.spec`'s far-side
5167
+ rope moves its near sphere beside the rope. The extended cloth specs 10, green on the decayed ramp and
5168
+ red without the decay (the ribbon pile, the twirled skirt, the draped sheet). `check-types` not re-run.
5169
+ The probe hooks that measured the self-collision candidates are reverted; the scripts are in the
5170
+ session scratchpad with `probe_hooks.patch`.
5171
+
5172
+ ## 68. The self radius is the particle's own
5173
+
5174
+ §67 left one answer measured and not landed: the self-collision radius built from the particle's own
5175
+ two lengths rather than the cloth's. This lands it. `ClothState` carries two regions filled at seed —
5176
+ `self_row`, the shortest stretch row incident on each particle, and `self_free_pair`, the closest pair
5177
+ no row governs within twice the longest row (`cloth_self_closest_free_pair`, which used to return one
5178
+ number into `ClothInstance#closest_free_pair`) — and `cloth_self_radius_update` fills `self_radius`
5179
+ per particle at the top of every step from them and the fabric's thickness,
5180
+ `r_i = min(max(t, ½·row_i), 0.4·free_i)`. The pair search tests `d² < (r_i + r_j)²` and hashes at a
5181
+ cell of twice the largest radius; the row's rest is `r_i + r_j`. `ClothStepParam.SELF_RADIUS` is gone
5182
+ (the stride 15 → 14), and so is `ClothInstance#closest_free_pair`. On a uniform sheet every particle
5183
+ gets the number the cloth used to get, to the float.
5184
+
5185
+ **The dance, paired.** The example's skirt (64 × 13, 832 particles, 6 mm thick, 2 × 4) on the rumba
5186
+ track, two scenes in one process stepped alternately with the order rotated each step, 1,500 steps, the
5187
+ dance steps 96–1,499 scored. Arm A has its two lengths flattened to the cloth's minima after the first
5188
+ step, which is the old radius at every particle — 6 mm, the thickness, since half the 9.8 mm waistband
5189
+ row is below it; arm B is the build.
5190
+
5191
+ | arm | radius | steps with a limb through | deepest | crossings mean / worst | pairs a step | ms mean / median / p90 |
5192
+ |---|---|---|---|---|---|---|
5193
+ | A, one per cloth | 6.0 mm | 0.6% | 8.3 mm | 422 / 618 | 43 | 13.389 / 13.876 / 16.986 |
5194
+ | B, per particle | 6.0–18.8 mm | 0.0% | −0.9 mm | 102 / 180 | 135 | 12.944 / 13.352 / 16.434 |
5195
+
5196
+ Paired B/A: 0.967 of the mean, 0.962 of the median, 0.963 the median of the per-step ratios. The step
5197
+ is cheaper with three times the pairs, and a 300-step re-run that counted contact rows says where: A
5198
+ carries 324 contact rows a step (worst 464), B 255 (worst 424), the hem's flutes held apart rather than
5199
+ tangled against the legs; the step there 9.015 → 8.799 ms, B/A 0.976 (a quieter box; the ratio is what
5200
+ is paired). §67's 432 → 102 is reproduced at 422 → 102.
5201
+
5202
+ **The code path, isolated.** The previous `cloth_self_find` and `cloth_self_accumulate_scratch`
5203
+ (HEAD's files, reading a scalar) against the new, on the same skirt state frozen 400 steps into the
5204
+ dance, search plus scratch, 300 interleaved reps:
5205
+
5206
+ | | median | mean | pairs | to the old |
5207
+ |---|---|---|---|---|
5208
+ | old code, 6 mm | 465 µs | 498 µs | 7 | 1.000 |
5209
+ | new code, 6 mm everywhere | 462 µs | 493 µs | 7 | 0.993 |
5210
+ | new code, per particle | 562 µs | 598 µs | 203 | 1.207 |
5211
+
5212
+ A busier first run gave 665 / 664 / 796 µs, 0.999 and 1.197. Reading the radius from an array costs
5213
+ nothing; the per-particle radii find 29× the pairs on that frame for 21% more search and scratch, about
5214
+ 100 µs of a 13 ms step.
5215
+
5216
+ **§64's eleven ribbon piles, as the control.** The same two arms. On the 5, 6 and 8 cm piles the radii
5217
+ coincide — 15 mm, half the 30 mm row — and on the 3.2 cm piles they differ as designed: a particle with
5218
+ a second ribbon within 32 mm at seed is capped at 12.8–12.9 mm and the rest keep 15 mm, where one
5219
+ radius per cloth gave every particle the 12.8.
5220
+
5221
+ | scene | A asleep | A worst / end crossings | A order | B asleep | B worst / end crossings | B order | B/A ms |
5222
+ |---|---|---|---|---|---|---|---|
5223
+ | 2 parallel, 3.2 cm | 188 | 0 / 0 | kept | 188 | 0 / 0 | kept | 1.021 |
5224
+ | 2 parallel, 8 cm | 225 | 5 / 2 | swapped | 208 | 4 / 4 | swapped | 1.062 |
5225
+ | 2 at 90°, 3.2 cm | 111 | 0 / 0 | kept | 111 | 0 / 0 | kept | 0.992 |
5226
+ | 2 at 90°, 8 cm | 126 | 0 / 0 | kept | 126 | 0 / 0 | kept | 1.027 |
5227
+ | 3 at 90°, 3.2 cm | 272 | 2 / 2 | kept | 273 | 2 / 2 | kept | 1.021 |
5228
+ | 3 at 90°, 8 cm | 251 | 0 / 0 | swapped | 251 | 0 / 0 | swapped | 1.017 |
5229
+ | 3 at 30°, 3.2 cm | 256 | 0 / 0 | kept | 273 | 0 / 0 | kept | 1.000 |
5230
+ | 3 at 30°, 8 cm | 324 | 10 / 7 | kept | 324 | 10 / 7 | kept | 1.009 |
5231
+ | 6 at 30°, 3.2 cm | 224 | 52 / 37 | swapped | 322 | 46 / 16 | swapped | 1.014 |
5232
+ | 6 at 30°, 6 cm | 401 | 14 / 0 | swapped | 474 | 13 / 0 | swapped | 0.998 |
5233
+ | 3 at 60°, 5 cm (the gate) | 264 | 0 / 0 | kept | 265 | 0 / 0 | kept | 1.042 |
5234
+
5235
+ Both arms: 11 of 11 asleep, 6 clean, 7 in order; the worst crossings a scene 7.5 (A) and 6.8 (B); the
5236
+ step 1.018× paired (0.992–1.062). The sleep steps that differ where the radii coincide measure a pile's
5237
+ chaos, not the change: two bit-identical copies of each scene stepped side by side stay bit-identical
5238
+ to the end (checked on all eleven), while arm A's flattening takes the minimum over `Float32` rows that
5239
+ differ by 1.3e-8 m between particles, so its radii sit 6.5e-9 m under some of B's, the pair search flips
5240
+ a comparison at step 4–8, and the sleep step moves by up to 98 (224 against 322). A difference of that
5241
+ size between two piles is noise, measured.
5242
+
5243
+ **The twirled skirt gate** (`cloth_sheet.slow.spec`'s 32 × 7 cotton annulus on turning hips: 29 mm rows
5244
+ round the waistband, 60 mm rows out to the hem). The hem had the waistband's 14.7 mm and now has 30:
5245
+
5246
+ | | radius | draped at | asleep after the stop | hem height from rest | hem radius from rest | deepest in the hips | crossings, worst step |
5247
+ |---|---|---|---|---|---|---|---|
5248
+ | one per cloth | 14.7 mm | 196 | 412 | 0.35 mm | −13.3 mm | −6.73 mm | 16 |
5249
+ | per particle | 14.7–30 mm | 196 | 290 | 5.62 mm | 0.1 mm | −6.72 mm | 0 |
5250
+
5251
+ The 16 are the hem's flutes meeting during the twirl at a quarter of their spacing. With its own radius
5252
+ the hem comes back to its radius and stands 5.6 mm higher, a fold resting on a fold with a 30 mm shell
5253
+ rather than 14.7; the gate's 2 mm on the height, pinned on a measured 0.9, re-pins at 10 mm, and it
5254
+ gains `crossed === 0`, red at 16 on the old radius. Nothing is closer to the hips.
5255
+
5256
+ ### Gates
5257
+
5258
+ Cloth suite 373 (from 370): `cloth_self_radius.spec` — an annulus's waist and hem radii from their own
5259
+ rows, a uniform sheet unchanged from the cloth-wide number, a particle with no row at the thickness.
5260
+ `ClothState.spec`'s layout carries the three regions. `cloth_self_find.spec`, `cloth_self_row.spec` and
5261
+ its slow spec fill the array. The extended cloth specs 10, green; the twirled skirt re-pinned and gated
5262
+ as above, red on one radius per cloth. `check-types` 18 against 19. The A/B is `ab_radius.probe.js`
5263
+ with `ab_scenes.mjs` in the session scratchpad, the control `ribbon_determinism.probe.js` and
5264
+ `ribbon_diff.probe.js`, and the slow spec's old arm an alias of `cloth_self_radius.js` that flattens
5265
+ (`vitest.slow_flat.config.mjs`).
@@ -529,10 +529,15 @@ iterate repeat `iterations` times:
529
529
  dual update, for each HARD constraint c:
530
530
  λ_c ← clamp(k_c·C_c + λ_c, fmin_c, fmax_c)
531
531
  k_c ← min(k_c + β·|C_c|, k_max·s_c)
532
+ (a contact's normal row: k_c ← min(k_c + ρ·k_max·s_c·|C_c|/offset, k_max·s_c))
532
533
 
533
534
  integrate v_i = (x_i - x_i^prev)/h
534
535
  ```
535
536
 
537
+ A contact's warm start differs in one line from the listing above: its two penalties decay by
538
+ `γ_c = CLOTH_CONTACT_GAMMA` rather than `γ`, the multipliers by `α·γ` as every hard row's do. The
539
+ correction below is why.
540
+
536
541
  The Hessian contribution is gated on the row being *active*. A clamped row's force is constant with
537
542
  respect to position, so its true second derivative is zero; adding `k·ggᵀ` anyway would make an
538
543
  inactive unilateral constraint resist motion it should not touch. It contributes its (constant) force
@@ -586,6 +591,30 @@ a decision rather than an omission — nothing measured since has asked for a de
586
591
  one place it would help is recorded in §18 as a coupling rather than as a bug — but it is an
587
592
  **unmeasured** constant and the only one left in the set, so it is named here as one.
588
593
 
594
+ **The cloth-skirt example corrected the contact's ramp and gave it a decay (`MEASUREMENTS.md` §67).**
595
+ A thigh advancing 17 mm a substep into a hanging skirt showed through it in 12.7% of the dance's
596
+ steps, up to 13 mm, and four times the iteration budget made that zero: the row was arriving soft.
597
+ `β = 1e3 N/m²` against that garment's band of 72 to 2,300 N/m is **0.003 of the band per contact
598
+ offset of violation**, so against a limb the penalty never left the floor and the multiplier, rebuilt
599
+ from a quarter every substep, could not carry the push in four iterations. The ramp is a ratio now,
600
+ `ρ = CLOTH_CONTACT_RAMP_RATIO = 0.1` of the band per offset of violation per iteration, which keeps the
601
+ shape the M2 measurement picked in the units the contact is defined in: 12.7% → 0.1% of steps, M2's
602
+ landing sheet 1.10 → 0.68 mm, M2 §6's swept capsule 17 → 1.8 mm, the tunnelling threshold unmoved.
603
+ It ramps whether or not the row is active, as before: ramping active rows only, the reference
604
+ implementation's form, leaves the thigh through ten times as often and takes the thrown particle's
605
+ stopped speed from 6 to 4 m/s at two substeps, which is §18's one-sided finding again.
606
+
607
+ What a ratio ramp does to a **resting** contact is what §18 predicted: every row violated by
608
+ millimetres while a pile lands is at the ceiling for good, where §53's limit cycle is too large for
609
+ silk to sleep — §64's ribbon pile never slept, the twirled skirt settled 17 mm from where it hung, the
610
+ draped sheet was carried 4° less. The resolution is the one §18 named, a `γ < 1` for contacts:
611
+ `γ_c = CLOTH_CONTACT_GAMMA = 0.8` decays a contact's two penalties per substep while the multiplier
612
+ carries the load, and every scene sleeps as before (erratic at 0.7, slow at 0.5; decaying the normal
613
+ penalty alone leaves the resting rope's sleep a coin toss, so both decay). Its cost is static
614
+ friction's exactness: a sheet on a slope it should stick to creeps 0.2–0.3 mm in four seconds, and
615
+ the marginal case, μ a tenth over the tangent, slides 0.55 m where the old ramp slid 0.19 — the ratio
616
+ ramp without the decay made that case stick exactly, so the two together are a trade, not a free win.
617
+
589
618
  **Adaptive initialisation** is VBD's: seed the iteration at `x + h·v + h²·ã` where `ã` interpolates
590
619
  between zero and full external acceleration according to whether the previous step looked like free
591
620
  fall or like resting contact. Without it, a low iteration count over-stretches under gravity on the
@@ -1257,15 +1286,19 @@ It reads as the same `r` a collider contact uses, which is `ClothDynamics#thickn
1257
1286
  a fold are almost never in contact and the row finds 1.6 to 3.7 pairs across a whole garment. The
1258
1287
  radius is a property of **the proxy**: `ClothState#self_radius`, `max(thickness, shortest_row/2)`,
1259
1288
  so the row's diameter is one particle spacing. At the fabric's own 6 mm the row removes 21% of a
1260
- sheet's self-intersections; at half the shortest row it removes 82%. `MEASUREMENTS.md` §31.
1289
+ sheet's self-intersections; at half the shortest row it removes 82%. `MEASUREMENTS.md` §31. And the
1290
+ row is **the particle's own** (`ClothState#self_row`), a pair's reach the sum of its two radii: a circle
1291
+ skirt's hem has rows five times the waistband's, and one radius per cloth gave it the waistband's, a
1292
+ fifth of its spacing, with the flutes through each other at every sample. §67, §68.
1261
1293
 
1262
1294
  **It also needs a ceiling, and the ceiling is a measured length.** A diameter that reaches the
1263
1295
  closest pair *no row governs* puts a cloth which is not folded at all in permanent contact with
1264
1296
  itself — leather, 20 mm thick on a 20 mm proxy, found 1,398 pairs a step across 576 particles
1265
1297
  standing still (§36). On a sheet that distance is two hops and could have been assumed; on a
1266
1298
  rigged garment, whose proxy is strips with nothing joining one to the next, it is the gap the
1267
- artist left between strips and is half what the link length implies. So `ClothInstance` measures
1268
- it once at seed, in the bind pose, and the ceiling is two fifths of it. `MEASUREMENTS.md` §37.
1299
+ artist left between strips and is half what the link length implies. So `cloth_build_rows` measures
1300
+ it once at seed, in the bind pose, per particle into `ClothState#self_free_pair`, and the ceiling is
1301
+ two fifths of it. `MEASUREMENTS.md` §37, §68.
1269
1302
 
1270
1303
  "O(n) with a small constant" is right about the shape and optimistic about the constant: the pair
1271
1304
  search is linear in particles with no term in the pair count, and it is **12% of a frame** at the
@@ -2213,8 +2246,8 @@ case and found 1,398 pairs a step on a 576-particle sheet that was barely folded
2213
2246
  distance has to be **measured** rather than assumed to be two hops, because two hops is a fact
2214
2247
  about sheets: the playground's cape has 8 cm links and an 8.5 cm gap between strips, half what the
2215
2248
  link length implies, and the assumed ceiling left it with three pairs permanently in contact at
2216
- rest. `ClothInstance#closest_free_pair` is measured once at seed and the ceiling is two fifths of
2217
- it. On a sheet the two rules agree exactly, so §31–36 stand. `MEASUREMENTS.md` §37.
2249
+ rest. `ClothState#self_free_pair` is measured once at seed, per particle, and the ceiling is two
2250
+ fifths of it. On a sheet the two rules agree exactly, so §31–36 stand. `MEASUREMENTS.md` §37, §68.
2218
2251
 
2219
2252
  **And the playground earned its keep.** Every measurement from §31 to §36 is on a sheet, because a
2220
2253
  sheet is the only thing here with a surface to pass through. Put the same row on the geometry M3
@@ -2609,6 +2642,14 @@ visible, for a hair rope creeping for thirty-seven seconds instead of three, whi
2609
2642
  rather than fixed; the thing that would actually resolve it is a `γ < 1` for contacts, which is
2610
2643
  §5.2's own open number. `MEASUREMENTS.md` §54.
2611
2644
 
2645
+ **— RESOLVED the way it said, when the ramp became a ratio.** The cloth-skirt example turned the ramp
2646
+ into `CLOTH_CONTACT_RAMP_RATIO` (§5.2), which made the pre-stiffening total — every row violated by
2647
+ millimetres at the ceiling for good — and a resting pile stopped sleeping. `CLOTH_CONTACT_GAMMA = 0.8`
2648
+ is the `γ < 1` for contacts, on both penalties. The one-sided ramp was measured again in ratio form and
2649
+ lost again (a sweeping thigh through ten times as often, 6 → 4 m/s stopped at two substeps), so the
2650
+ pre-stiffening stays and the decay is what bounds it. What the pair costs is static friction's
2651
+ exactness, stated in §5.2. `MEASUREMENTS.md` §67.
2652
+
2612
2653
  **Open — a rigid collider driven through pinned cloth wraps rather than parts.** A contact row bounds
2613
2654
  the interpenetration; it cannot prevent it, because the cloth has nowhere to go. The playground's
2614
2655
  spinning-bar scene is the case, and it settles at 18 mm inside a 25 mm bar. This is not a solver
@@ -2845,6 +2886,45 @@ rest" is not enough, because a ribbon can land right through another and lie und
2845
2886
  and not this:* piles land through themselves, 90 of 225 at 2, every one of them while landing. That is
2846
2887
  §35's missing travel term in the pair search. `MEASUREMENTS.md` §64, §65.
2847
2888
 
2889
+ **The self radius is one per cloth, and a circle skirt's hem gets the waistband's. — FIXED: the
2890
+ radius is the particle's own (§68); Lewin's two pair-row moves wait on their limb cost.**
2891
+ `ClothState#self_radius` was `max(thickness, ½·shortest row)` capped at `0.4 × closest free pair`,
2892
+ with both the shortest row and the closest free pair measured over the whole cloth. The cloth-skirt
2893
+ example's rows run from 9.8 mm at
2894
+ the waistband to 54 mm at the hem, so the hem gets a 6 mm radius against a 37–54 mm spacing — a row
2895
+ diameter a fifth of the spacing where §9 wants one spacing — and the flutes pass through each other
2896
+ at every sample: ~400 edge-through-triangle crossings, budget-independent (272 at 4×8), the example's
2897
+ own README says "the flutes sometimes cross". `MEASUREMENTS.md` §67 measured three answers:
2898
+
2899
+ - **The shipped formula applied per particle — LANDED (§68)**, `r_i = clamp(thickness, ½·shortest
2900
+ row incident on i, 0.4 × closest free pair of i)`, pairs tested at `r_i + r_j`, both lengths seeded
2901
+ into `ClothState#self_row` and `#self_free_pair` and the radius filled each step by
2902
+ `cloth_self_radius_update`. Paired on the dance: crossings 422 → 102 a step (worst 618 → 180), a
2903
+ thigh through in 0.6% → 0.0% of steps, the step 0.96× for 70 fewer contact rows with the hem held
2904
+ off the legs, search and scratch 1.2× on three times the pairs; the twirled skirt's 16 crossings → 0,
2905
+ and its gate pinned. It is still the sphere model, and a sharp fold still slips between particles.
2906
+ - **Lewin's two moves on the pair row (GDC 2018):** the particle's predicted travel in the pair
2907
+ search's reach — §35's missing term — and the pair's normal frozen for the step, which makes the row
2908
+ a half-space a pair cannot pass through however far the other rows shove it. On §64's eleven ribbon
2909
+ piles they take the pair row from 6 clean and 7 in order to 10 clean and 11 in order, every pile
2910
+ asleep, the worst crossings 7.5 → 0.2 a scene, at no new row kind. On the skirt they do not touch
2911
+ the crossings and they cost limbs: a thigh through in 1.1–1.9% of steps against 0.1%, and 1.2% for
2912
+ the travel term on top of the per-particle radius (crossings 38). A half-space stays active after
2913
+ its pair has slid apart tangentially, the artefact the talk names; gating it on the live distance
2914
+ halves the cost and keeps the piles' result. Why a wider or stickier pair row puts a hem particle
2915
+ into a thigh is not measured, and it is what keeps the two moves from landing with the radius.
2916
+ - **Predictive point-triangle rows, as the talk's self collision,** as plain penalties into the
2917
+ self row's Jacobi scratch: a four-particle row is only Jacobi-stable with each participant taking
2918
+ its mass-weighted share of the correction (the pair row at ratio 2 sits exactly at the share sum
2919
+ of 1, which is why §65 found it the stiffest that comes to rest), and with that split a ribbon
2920
+ landing from 10 mm a step is stopped at 8 mm of separation. On their own they sleep 5 of 11 piles
2921
+ and push the lowest ribbon into the floor; on the skirt they are unstable at every form tried (peak
2922
+ speeds at the clamp, a thigh through in 5–7% of steps). They add the last pile only on top of the
2923
+ pair row with Lewin's moves. The talk's own numbers say the same: 20 ms to 1 s a frame for the
2924
+ general method, 0.1–0.2 ms only with authored layer order and cached contact sets. M4b stays what
2925
+ it was: the thin-surface closure, not a quick win, and in this solver it wants a hard row with a
2926
+ multiplier and a Gauss-Seidel treatment, not a penalty in the Jacobi scratch.
2927
+
2848
2928
  ---
2849
2929
 
2850
2930
  ## 19. Attachment points
@@ -575,18 +575,6 @@ export class ClothInstance {
575
575
  offset: Int32Array;
576
576
  partner: Int32Array;
577
577
  } | null;
578
- /**
579
- * How close two particles get in the **bind pose** with no row between them,
580
- * metres — or `Infinity` when nothing is within reach of anything.
581
- *
582
- * The ceiling on a self-collision row's radius, and the reason it is a
583
- * measured length rather than a multiple of {@link shortest_row}: on a
584
- * triangulated sheet the two agree, and on a rigged garment — strips with
585
- * nothing joining one to the next — they do not agree at all.
586
- * `CLOTH_SELF_RADIUS_MAX_RATIO` and `MEASUREMENTS.md` §37.
587
- * @type {number}
588
- */
589
- closest_free_pair: number;
590
578
  /**
591
579
  * Self-collision pairs the last step found. Diagnostic, and the one to
592
580
  * watch: a garment pinned at `CLOTH_SELF_PAIRS_PER_PARTICLE` per particle is
@@ -1 +1 @@
1
- {"version":3,"file":"ClothInstance.d.ts","sourceRoot":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,EAAE,UAAU,CAAC;QAAC,OAAO,EAAE,UAAU,CAAA;KAAC,GAAC,IAAI,CAEjC;IAEvB;;;;;;;;;;OAUG;IACH,mBAFU,MAAM,CAEa;IAE7B;;;;;OAKG;IACH,YAFU,MAAM,CAED;IAEf;;;;;OAKG;IACH,eAFU,MAAM,CAEE;IAElB;;;;;OAKG;IACH,SAFU,OAAO,CAED;IAEhB;;;;;;;;;OASG;IACH,UAFU,YAAY,CAES;IAE/B;;;;;;OAMG;IACH,YAFU,OAAO,CAEE;IAEnB;;;;;;;;;;;;;;;;OAgBG;IACH,KAFU,MAAM,CAER;IAER;;;;;;;;;;;OAWG;IACH,eAFU,UAAU,CAEiC;IAErD;;OAEG;IACH,oBAFU,MAAM,CAEO;IAEvB;;;;OAIG;IACH,oBAFU,WAAW,CAEsC;IAE3D;;;;;OAKG;IACH,6BAFU,WAAW,CAE+C;IAEpE;;;;;;OAMG;IACH,cAFU,MAAM,CAEC;IAEjB;;;;;OAKG;IACH,aAFU,MAAM,EAAE,GAAC,IAAI,CAEJ;IAEnB;;;;;;;;;;OAUG;IACH,iBAFU,YAAY,GAAC,IAAI,CAEJ;IAEvB;;;;;OAKG;IACH,gBAFU,MAAM,CAEG;CACtB;4BA7xB2B,uCAAuC;8BAErC,oBAAoB"}
1
+ {"version":3,"file":"ClothInstance.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/physics/cloth/ecs/ClothInstance.js"],"names":[],"mappings":"AAIA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyCG;AACH;IAEI;;;;OAIG;IACH,QAFU,MAAM,CAEJ;IAEZ;;OAEG;IACH,OAFU,QAAM,IAAI,CAEP;IAEb;;;;OAIG;IACH,WAFU,WAAW,GAAC,IAAI,CAET;IAEjB;;;;OAIG;IACH,cAFU,MAAM,CAEE;IAElB;;;;;;OAMG;IACH,aAFU,UAAU,GAAC,IAAI,CAEN;IAEnB;;;;;;;;;;;OAWG;IACH,eAFU,YAAY,G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ACH,oBAFU,MAAM,CAEO;IAEvB;;;;OAIG;IACH,oBAFU,WAAW,CAEsC;IAE3D;;;;;OAKG;IACH,6BAFU,WAAW,CAE+C;IAEpE;;;;;;OAMG;IACH,cAFU,MAAM,CAEC;IAEjB;;;;;OAKG;IACH,aAFU,MAAM,EAAE,GAAC,IAAI,CAEJ;IAEnB;;;;;;;;;;OAUG;IACH,iBAFU,YAAY,GAAC,IAAI,CAEJ;IAEvB;;;;;OAKG;IACH,gBAFU,MAAM,CAEG;CACtB;4BAhxB2B,uCAAuC;8BAErC,oBAAoB"}
@@ -647,19 +647,6 @@ export class ClothInstance {
647
647
  */
648
648
  self_exclusions = null;
649
649
 
650
- /**
651
- * How close two particles get in the **bind pose** with no row between them,
652
- * metres — or `Infinity` when nothing is within reach of anything.
653
- *
654
- * The ceiling on a self-collision row's radius, and the reason it is a
655
- * measured length rather than a multiple of {@link shortest_row}: on a
656
- * triangulated sheet the two agree, and on a rigged garment — strips with
657
- * nothing joining one to the next — they do not agree at all.
658
- * `CLOTH_SELF_RADIUS_MAX_RATIO` and `MEASUREMENTS.md` §37.
659
- * @type {number}
660
- */
661
- closest_free_pair = Infinity;
662
-
663
650
  /**
664
651
  * Self-collision pairs the last step found. Diagnostic, and the one to
665
652
  * watch: a garment pinned at `CLOTH_SELF_PAIRS_PER_PARTICLE` per particle is
@@ -48,7 +48,7 @@
48
48
  export class ClothSystem extends System<any> {
49
49
  constructor();
50
50
  dependencies: (typeof Transform64 | typeof Cloth)[];
51
- components_used: (ResourceAccessSpecification<typeof Transform64> | ResourceAccessSpecification<typeof TransformAttachment> | ResourceAccessSpecification<typeof GPUStateAuthority> | ResourceAccessSpecification<typeof ParentEntity> | ResourceAccessSpecification<typeof ClothCollider> | ResourceAccessSpecification<typeof Cloth> | ResourceAccessSpecification<typeof ClothExclude> | ResourceAccessSpecification<typeof ClothRig> | ResourceAccessSpecification<typeof ClothPin>)[];
51
+ components_used: (ResourceAccessSpecification<typeof Transform64> | ResourceAccessSpecification<typeof TransformAttachment> | ResourceAccessSpecification<typeof GPUStateAuthority> | ResourceAccessSpecification<typeof ParentEntity> | ResourceAccessSpecification<typeof ClothCollider> | ResourceAccessSpecification<typeof Cloth> | ResourceAccessSpecification<typeof ClothExclude> | ResourceAccessSpecification<typeof ClothRig> | ResourceAccessSpecification<typeof ClothPin> | ResourceAccessSpecification<typeof FluidComponent>)[];
52
52
  /**
53
53
  * @type {ClothWorld}
54
54
  */
@@ -164,5 +164,6 @@ import { ClothCollider } from "./ClothCollider.js";
164
164
  import { ClothExclude } from "./ClothExclude.js";
165
165
  import { ClothRig } from "./ClothRig.js";
166
166
  import { ClothPin } from "./ClothPin.js";
167
+ import { FluidComponent } from "../../fluid/ecs/FluidComponent.js";
167
168
  import { ClothWorld } from "./ClothWorld.js";
168
169
  //# sourceMappingURL=ClothSystem.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"ClothSystem.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/physics/cloth/ecs/ClothSystem.js"],"names":[],"mappings":"AAiBA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AACH;;IAEI,oDAAoC;IAEpC,2dAYE;IAEF;;OAEG;IACH,OAFU,UAAU,CAEK;IAEzB;;;;;;;;;;;;OAYG;IACH,iBAAyD;IAEzD;;;;;;OAMG;IACH,qBAAkB;IAUlB;;OAEG;IACH,iCAEC;IAbD;;;OAGG;IACH,4BAEC;IAkBD;;OAEG;IACH,qBAEC;IAdD;;;;OAIG;IACH,gBAEC;IASD;;;;OAIG;IACH,iCAEC;IAGD;;;OAGG;IACH,uCAFa,QAAQ,IAAI,CAAC,CAIzB;IAED;;;OAGG;IACH,wDAFa,IAAI,CAIhB;IAED;;;OAGG;IACH,wDAFa,IAAI,CAIhB;IAED;;;;OAIG;IACH,YAJW,KAAK,aACL,WAAW,UACX,MAAM,QAIhB;IAED;;;;OAIG;IACH,cAJW,KAAK,aACL,WAAW,UACX,MAAM,QAIhB;IAED;;;;OAIG;IACH,eAHW,MAAM,GACJ,IAAI,CAIhB;IAED;;;;OAIG;IACH,aAHW,MAAM,GACJ,IAAI,CAIhB;IAED;;;OAGG;IACH,mBAHW,MAAM,GACJ,gBAAc,SAAS,CAInC;IAED;;;;;;OAMG;IACH,mBAJW,MAAM,UACN,MAAM,GACJ,MAAM,CAIlB;CA2EJ;uBA9SsB,wBAAwB;4BAInB,uCAAuC;sBAE7C,YAAY;4CAPU,uDAAuD;oCAI5F,0DAA0D;kCAQ/B,uCAAuC;6BAC5C,qCAAqC;8BALpC,oBAAoB;6BACrB,mBAAmB;yBAEvB,eAAe;yBADf,eAAe;2BAIb,iBAAiB"}
1
+ {"version":3,"file":"ClothSystem.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/physics/cloth/ecs/ClothSystem.js"],"names":[],"mappings":"AAkBA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AACH;;IAEI,oDAAoC;IAEpC,ghBAiBE;IAEF;;OAEG;IACH,OAFU,UAAU,CAEK;IAEzB;;;;;;;;;;;;OAYG;IACH,iBAAyD;IAEzD;;;;;;OAMG;IACH,qBAAkB;IAUlB;;OAEG;IACH,iCAEC;IAbD;;;OAGG;IACH,4BAEC;IAkBD;;OAEG;IACH,qBAEC;IAdD;;;;OAIG;IACH,gBAEC;IASD;;;;OAIG;IACH,iCAEC;IAGD;;;OAGG;IACH,uCAFa,QAAQ,IAAI,CAAC,CAIzB;IAED;;;OAGG;IACH,wDAFa,IAAI,CAIhB;IAED;;;OAGG;IACH,wDAFa,IAAI,CAIhB;IAED;;;;OAIG;IACH,YAJW,KAAK,aACL,WAAW,UACX,MAAM,QAIhB;IAED;;;;OAIG;IACH,cAJW,KAAK,aACL,WAAW,UACX,MAAM,QAIhB;IAED;;;;OAIG;IACH,eAHW,MAAM,GACJ,IAAI,CAIhB;IAED;;;;OAIG;IACH,aAHW,MAAM,GACJ,IAAI,CAIhB;IAED;;;OAGG;IACH,mBAHW,MAAM,GACJ,gBAAc,SAAS,CAInC;IAED;;;;;;OAMG;IACH,mBAJW,MAAM,UACN,MAAM,GACJ,MAAM,CAIlB;CA2EJ;uBApTsB,wBAAwB;4BAKnB,uCAAuC;sBAE7C,YAAY;4CARU,uDAAuD;oCAI5F,0DAA0D;kCAS/B,uCAAuC;6BAC5C,qCAAqC;8BALpC,oBAAoB;6BACrB,mBAAmB;yBAEvB,eAAe;yBADf,eAAe;+BANT,mCAAmC;2BAUvC,iBAAiB"}
@@ -4,6 +4,7 @@ import { System } from "../../../ecs/System.js";
4
4
  import {
5
5
  TransformAttachment
6
6
  } from "../../../ecs/transform-attachment/TransformAttachment.js";
7
+ import { FluidComponent } from "../../fluid/ecs/FluidComponent.js";
7
8
  import { Transform64 } from "../../../ecs/transform/Transform64.js";
8
9
  import { CLOTH_STEP_PARAM_STRIDE, cloth_step_instance } from "../solver/cloth_step_instance.js";
9
10
  import { Cloth } from "./Cloth.js";
@@ -77,7 +78,12 @@ export class ClothSystem extends System {
77
78
  // model it belongs to and who composes its transform.
78
79
  ResourceAccessSpecification.from(ClothPin, ResourceAccessKind.Read),
79
80
  ResourceAccessSpecification.from(ParentEntity, ResourceAccessKind.Read),
80
- ResourceAccessSpecification.from(GPUStateAuthority, ResourceAccessKind.Read)
81
+ ResourceAccessSpecification.from(GPUStateAuthority, ResourceAccessKind.Read),
82
+ // The air `ClothFluidWind` samples. Every fluid system also reads the
83
+ // `Transform64` written above, which makes this a cycle, and the score
84
+ // runs cloth first: before `WorkerFluidSystem` hands the field to its
85
+ // worker, which is the only safe side of it (`cloth_wind.spec.js`).
86
+ ResourceAccessSpecification.from(FluidComponent, ResourceAccessKind.Read)
81
87
  ];
82
88
 
83
89
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"ClothWorld.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/physics/cloth/ecs/ClothWorld.js"],"names":[],"mappings":"AAyEA;;;;;;;;;;;;;;;;;;;;;;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Aa,mCAEb,MAAM,GACJ,OAAO,CA8BnB;IAED;;;;;;;OAOG;IACH,iBAJW,aAAa,gCAEX,IAAI,CA4ChB;IAyFD;;;;;;;;;;;;OAYG;IACH,kBAPW,aAAa,MACb,MAAM,UACN,YAAY,UACZ,MAAM,GACJ,OAAO,CA6TnB;;CA0GJ;8BAtiD6B,oBAAoB;0CApB3C,gEAAgE;oCAgBnC,0BAA0B;sBA+BxC,YAAY;4BA1C3B,uCAAuC"}
1
+ {"version":3,"file":"ClothWorld.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/physics/cloth/ecs/ClothWorld.js"],"names":[],"mappings":"AAwEA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgGG;AACH;IAEI;;;OAGG;IACH,SAFU,YAAY,CAEoB;IAE1C;;;;;;;;;;;;OAYG;IACH,WAFU,aAAa,EAAE,CAEV;IAEf;;OAEG;IACH,eAFU,gBAAc,IAAI,CAEP;IAErB;;OAEG;IACH,aAFU,yBAAyB,GAAC,IAAI,CAErB;IAEnB;;;;;;OAMG;IACH,WAFU,mBAAmB,GAAC,IAAI,CAEjB;IAEjB;;;;;;;;;;;;;;;;;;OAkBG;IACH,MAFU,oBAAkB,IAAI,CAEpB;IAEZ;;;;;;;;;;;;;;;;;;;OAmBG;IACH,MAFU,MAAM,CAEP;IAET;;;;;OAKG;IACH,uBAAmB;IAEnB;;;;;OAKG;IACH,cAFU,OAAO,CAEI;IAErB;;;OAGG;IACH,oBAAwB;IAExB;;;;;;;;;;;;;;;;;;;;OAoBG;IACH,uBAKE;IAEF;;;;;;OAMG;IACH,uBAKE;IA0BF;;;;;OAKG;IACH,2CAaC;IAED;;;;;OAKG;IACH,YALW,KAAK,aACL,WAAW,UACX,MAAM,GACJ,aAAa,CAczB;IAED;;;;;;;;OAQG;IACH,iDAFa,IAAI,CAehB;IAED;;;OAGG;I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