@driftengine/core 4.8.7 → 4.10.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 (263) hide show
  1. package/CHANGELOG.json +123 -11
  2. package/README.md +43 -38
  3. package/dist/index.d.ts +8 -1
  4. package/dist/index.js +11 -3
  5. package/dist/render/ambientHarmonics.d.ts +1 -1
  6. package/dist/render/ambientHarmonics.js +1 -1
  7. package/dist/render/areaLights.d.ts +4 -4
  8. package/dist/render/areaLights.js +1 -1
  9. package/dist/render/atmosphere.d.ts +13 -0
  10. package/dist/render/atmosphere.js +9 -1
  11. package/dist/render/backend/api.d.ts +19 -4
  12. package/dist/render/backend/createRenderer.d.ts +6 -0
  13. package/dist/render/backend/createRenderer.js +4 -1
  14. package/dist/render/backend/select.js +11 -5
  15. package/dist/render/backend/webgl2/boneAnimations.d.ts +29 -0
  16. package/dist/render/backend/webgl2/boneAnimations.js +80 -0
  17. package/dist/render/backend/webgl2/instanced.d.ts +5 -1
  18. package/dist/render/backend/webgl2/instanced.js +13 -1
  19. package/dist/render/backend/webgl2/renderer.d.ts +180 -4
  20. package/dist/render/backend/webgl2/renderer.js +550 -40
  21. package/dist/render/backend/webgl2/skinPaletteTexture.d.ts +5 -3
  22. package/dist/render/backend/webgl2/skinPaletteTexture.js +6 -4
  23. package/dist/render/backend/webgpu/boneAnimations.d.ts +34 -0
  24. package/dist/render/backend/webgpu/boneAnimations.js +76 -0
  25. package/dist/render/backend/webgpu/buffers.d.ts +19 -4
  26. package/dist/render/backend/webgpu/buffers.js +18 -11
  27. package/dist/render/backend/webgpu/compressedUpload.d.ts +0 -1
  28. package/dist/render/backend/webgpu/compressedUpload.js +53 -8
  29. package/dist/render/backend/webgpu/depthPass.d.ts +59 -3
  30. package/dist/render/backend/webgpu/depthPass.js +49 -14
  31. package/dist/render/backend/webgpu/device.d.ts +7 -1
  32. package/dist/render/backend/webgpu/device.js +31 -3
  33. package/dist/render/backend/webgpu/drawCommand.d.ts +18 -4
  34. package/dist/render/backend/webgpu/drawCommand.js +10 -3
  35. package/dist/render/backend/webgpu/flatPass.d.ts +100 -42
  36. package/dist/render/backend/webgpu/flatPass.js +191 -43
  37. package/dist/render/backend/webgpu/instanced.d.ts +14 -1
  38. package/dist/render/backend/webgpu/instanced.js +24 -1
  39. package/dist/render/backend/webgpu/materialStore.d.ts +101 -0
  40. package/dist/render/backend/webgpu/materialStore.js +265 -0
  41. package/dist/render/backend/webgpu/pipelineCache.d.ts +6 -0
  42. package/dist/render/backend/webgpu/pipelineCache.js +7 -0
  43. package/dist/render/backend/webgpu/postPass.d.ts +51 -9
  44. package/dist/render/backend/webgpu/postPass.js +16 -2
  45. package/dist/render/backend/webgpu/reflectionSurfacePass.d.ts +30 -0
  46. package/dist/render/backend/webgpu/reflectionSurfacePass.js +100 -0
  47. package/dist/render/backend/webgpu/renderer.d.ts +283 -37
  48. package/dist/render/backend/webgpu/renderer.js +1363 -202
  49. package/dist/render/backend/webgpu/skinPaletteRing.d.ts +7 -3
  50. package/dist/render/backend/webgpu/skinPaletteRing.js +13 -7
  51. package/dist/render/backend/webgpu/skinPaletteTexture.d.ts +6 -0
  52. package/dist/render/backend/webgpu/skinPaletteTexture.js +7 -1
  53. package/dist/render/backend/webgpu/staticBundles.d.ts +125 -0
  54. package/dist/render/backend/webgpu/staticBundles.js +241 -0
  55. package/dist/render/backend/webgpu/surfaceTexturePass.d.ts +10 -3
  56. package/dist/render/backend/webgpu/surfaceTexturePass.js +20 -2
  57. package/dist/render/backend/webgpu/uniformRing.d.ts +21 -0
  58. package/dist/render/backend/webgpu/uniformRing.js +9 -1
  59. package/dist/render/bloomChain.d.ts +3 -3
  60. package/dist/render/boneAnimation.d.ts +92 -0
  61. package/dist/render/boneAnimation.js +133 -0
  62. package/dist/render/compressedSource.d.ts +33 -13
  63. package/dist/render/compressedSource.js +70 -25
  64. package/dist/render/displayRange.d.ts +31 -0
  65. package/dist/render/displayRange.js +47 -0
  66. package/dist/render/filmicCurve.d.ts +74 -0
  67. package/dist/render/filmicCurve.js +203 -0
  68. package/dist/render/fog.d.ts +4 -1
  69. package/dist/render/fog.js +12 -2
  70. package/dist/render/frame/resources.d.ts +2 -2
  71. package/dist/render/frame/resources.js +6 -0
  72. package/dist/render/frameReflections.d.ts +40 -0
  73. package/dist/render/frameReflections.js +48 -0
  74. package/dist/render/glCompressed.js +83 -0
  75. package/dist/render/instances.d.ts +26 -0
  76. package/dist/render/lightBudget.d.ts +10 -0
  77. package/dist/render/lightBudget.js +10 -0
  78. package/dist/render/lightmap.d.ts +1 -1
  79. package/dist/render/mesh.d.ts +5 -0
  80. package/dist/render/mesh.js +6 -0
  81. package/dist/render/pass.d.ts +49 -0
  82. package/dist/render/pointLightSelection.d.ts +4 -4
  83. package/dist/render/reflectionSurfaceTargets.d.ts +28 -0
  84. package/dist/render/reflectionSurfaceTargets.js +99 -0
  85. package/dist/render/renderQuality.d.ts +39 -8
  86. package/dist/render/renderQuality.js +4 -0
  87. package/dist/render/sceneTarget.d.ts +5 -0
  88. package/dist/render/sceneTarget.js +24 -1
  89. package/dist/render/screenSpaceReflection.d.ts +7 -1
  90. package/dist/render/screenSpaceReflection.js +5 -0
  91. package/dist/render/shaders/arcane.d.ts +1 -1
  92. package/dist/render/shaders/bolt.d.ts +1 -1
  93. package/dist/render/shaders/boneAnimation.d.ts +19 -0
  94. package/dist/render/shaders/boneAnimation.js +63 -0
  95. package/dist/render/shaders/caustics.d.ts +1 -1
  96. package/dist/render/shaders/depth.d.ts +7 -0
  97. package/dist/render/shaders/depth.js +35 -10
  98. package/dist/render/shaders/film.d.ts +1 -1
  99. package/dist/render/shaders/filmLook.js +2 -1
  100. package/dist/render/shaders/fire.d.ts +1 -1
  101. package/dist/render/shaders/flat/glassTint.d.ts +1 -1
  102. package/dist/render/shaders/flat/glassTint.js +2 -0
  103. package/dist/render/shaders/flat/index.d.ts +16 -0
  104. package/dist/render/shaders/flat/index.js +33 -5
  105. package/dist/render/shaders/flat/main.d.ts +1 -1
  106. package/dist/render/shaders/flat/main.js +43 -5
  107. package/dist/render/shaders/flat/models.js +1 -1
  108. package/dist/render/shaders/flat/overlay.d.ts +16 -0
  109. package/dist/render/shaders/flat/overlay.js +117 -0
  110. package/dist/render/shaders/flat/pointShadow.js +3 -3
  111. package/dist/render/shaders/flat/preamble.js +38 -24
  112. package/dist/render/shaders/flat/reflectionSurface.d.ts +21 -0
  113. package/dist/render/shaders/flat/reflectionSurface.js +61 -0
  114. package/dist/render/shaders/fog.d.ts +1 -1
  115. package/dist/render/shaders/fog.js +9 -2
  116. package/dist/render/shaders/fringe.d.ts +29 -0
  117. package/dist/render/shaders/fringe.js +55 -0
  118. package/dist/render/shaders/generated/arcane.wgsl.d.ts +1 -1
  119. package/dist/render/shaders/generated/arcane.wgsl.js +1 -1
  120. package/dist/render/shaders/generated/bolt.wgsl.d.ts +1 -1
  121. package/dist/render/shaders/generated/bolt.wgsl.js +1 -1
  122. package/dist/render/shaders/generated/caustics.wgsl.d.ts +1 -1
  123. package/dist/render/shaders/generated/caustics.wgsl.js +1 -1
  124. package/dist/render/shaders/generated/depth.wgsl.d.ts +93 -0
  125. package/dist/render/shaders/generated/depth.wgsl.js +93 -0
  126. package/dist/render/shaders/generated/film.wgsl.d.ts +1 -1
  127. package/dist/render/shaders/generated/film.wgsl.js +1 -1
  128. package/dist/render/shaders/generated/fire.wgsl.d.ts +1 -1
  129. package/dist/render/shaders/generated/fire.wgsl.js +1 -1
  130. package/dist/render/shaders/generated/flat.wgsl.d.ts +3254 -2920
  131. package/dist/render/shaders/generated/flat.wgsl.js +3292 -2957
  132. package/dist/render/shaders/generated/line.wgsl.d.ts +1 -1
  133. package/dist/render/shaders/generated/line.wgsl.js +1 -1
  134. package/dist/render/shaders/generated/particle.wgsl.d.ts +4 -4
  135. package/dist/render/shaders/generated/particle.wgsl.js +4 -4
  136. package/dist/render/shaders/generated/rush.wgsl.d.ts +56 -26
  137. package/dist/render/shaders/generated/rush.wgsl.js +56 -26
  138. package/dist/render/shaders/generated/scatter.wgsl.d.ts +1 -1
  139. package/dist/render/shaders/generated/scatter.wgsl.js +1 -1
  140. package/dist/render/shaders/generated/smoke.wgsl.d.ts +1 -1
  141. package/dist/render/shaders/generated/smoke.wgsl.js +1 -1
  142. package/dist/render/shaders/generated/ssrResolve.wgsl.d.ts +29 -0
  143. package/dist/render/shaders/generated/ssrResolve.wgsl.js +29 -0
  144. package/dist/render/shaders/generated/ssrTrace.wgsl.d.ts +22 -2
  145. package/dist/render/shaders/generated/ssrTrace.wgsl.js +22 -2
  146. package/dist/render/shaders/generated/water.wgsl.d.ts +1 -1
  147. package/dist/render/shaders/generated/water.wgsl.js +1 -1
  148. package/dist/render/shaders/gpudriven/fog.wgsl.d.ts +2 -2
  149. package/dist/render/shaders/gpudriven/fog.wgsl.js +11 -3
  150. package/dist/render/shaders/line.d.ts +1 -1
  151. package/dist/render/shaders/outputTransform.d.ts +7 -0
  152. package/dist/render/shaders/outputTransform.js +28 -14
  153. package/dist/render/shaders/particle.d.ts +3 -3
  154. package/dist/render/shaders/rush.js +54 -11
  155. package/dist/render/shaders/scatter.d.ts +1 -1
  156. package/dist/render/shaders/smoke.d.ts +1 -1
  157. package/dist/render/shaders/ssrResolve.d.ts +17 -0
  158. package/dist/render/shaders/ssrResolve.js +51 -0
  159. package/dist/render/shaders/ssrTrace.js +26 -0
  160. package/dist/render/shaders/vertexChannel.d.ts +7 -0
  161. package/dist/render/shaders/vertexChannel.js +26 -0
  162. package/dist/render/shaders/water.d.ts +1 -1
  163. package/dist/render/ssrPass.d.ts +16 -0
  164. package/dist/render/ssrPass.js +106 -1
  165. package/dist/render/staticDraws.d.ts +47 -0
  166. package/dist/render/staticDraws.js +43 -0
  167. package/dist/render/surfaceOverlay.d.ts +132 -0
  168. package/dist/render/surfaceOverlay.js +85 -0
  169. package/dist/render/surfaceTexture.d.ts +57 -7
  170. package/dist/render/surfaceTexture.js +125 -17
  171. package/dist/render/temporalAa.d.ts +14 -0
  172. package/dist/render/temporalAa.js +20 -0
  173. package/dist/render/vertexDefaults.d.ts +17 -0
  174. package/dist/render/vertexDefaults.js +24 -0
  175. package/package.json +6 -6
  176. package/src/index.ts +24 -2
  177. package/src/render/ambientHarmonics.ts +1 -1
  178. package/src/render/areaLights.ts +4 -4
  179. package/src/render/atmosphere.ts +22 -1
  180. package/src/render/backend/api.ts +22 -3
  181. package/src/render/backend/createRenderer.ts +18 -1
  182. package/src/render/backend/select.ts +10 -5
  183. package/src/render/backend/webgl2/boneAnimations.ts +105 -0
  184. package/src/render/backend/webgl2/instanced.ts +20 -1
  185. package/src/render/backend/webgl2/renderer.ts +672 -37
  186. package/src/render/backend/webgl2/skinPaletteTexture.ts +6 -4
  187. package/src/render/backend/webgpu/boneAnimations.ts +97 -0
  188. package/src/render/backend/webgpu/buffers.ts +42 -16
  189. package/src/render/backend/webgpu/compressedUpload.ts +59 -9
  190. package/src/render/backend/webgpu/depthPass.ts +51 -10
  191. package/src/render/backend/webgpu/device.ts +42 -3
  192. package/src/render/backend/webgpu/drawCommand.ts +22 -4
  193. package/src/render/backend/webgpu/flatPass.ts +250 -40
  194. package/src/render/backend/webgpu/instanced.ts +32 -1
  195. package/src/render/backend/webgpu/materialStore.ts +276 -0
  196. package/src/render/backend/webgpu/pipelineCache.ts +7 -0
  197. package/src/render/backend/webgpu/postPass.ts +18 -0
  198. package/src/render/backend/webgpu/reflectionSurfacePass.ts +114 -0
  199. package/src/render/backend/webgpu/renderer.ts +1655 -230
  200. package/src/render/backend/webgpu/skinPaletteRing.ts +13 -7
  201. package/src/render/backend/webgpu/skinPaletteTexture.ts +7 -1
  202. package/src/render/backend/webgpu/staticBundles.ts +363 -0
  203. package/src/render/backend/webgpu/surfaceTexturePass.ts +29 -3
  204. package/src/render/backend/webgpu/uniformRing.ts +10 -1
  205. package/src/render/bloomChain.ts +3 -3
  206. package/src/render/boneAnimation.ts +223 -0
  207. package/src/render/compressedSource.ts +121 -29
  208. package/src/render/displayRange.ts +61 -0
  209. package/src/render/filmicCurve.ts +229 -0
  210. package/src/render/fog.ts +19 -3
  211. package/src/render/frame/resources.ts +6 -0
  212. package/src/render/frameReflections.ts +72 -0
  213. package/src/render/glCompressed.ts +83 -0
  214. package/src/render/instances.ts +27 -0
  215. package/src/render/lightBudget.ts +11 -0
  216. package/src/render/lightmap.ts +1 -1
  217. package/src/render/mesh.ts +6 -0
  218. package/src/render/pass.ts +53 -1
  219. package/src/render/pointLightSelection.ts +4 -4
  220. package/src/render/reflectionSurfaceTargets.ts +105 -0
  221. package/src/render/renderQuality.ts +44 -8
  222. package/src/render/sceneTarget.ts +30 -2
  223. package/src/render/screenSpaceReflection.ts +7 -1
  224. package/src/render/shaders/boneAnimation.ts +63 -0
  225. package/src/render/shaders/depth.ts +45 -10
  226. package/src/render/shaders/filmLook.ts +2 -1
  227. package/src/render/shaders/flat/glassTint.ts +5 -1
  228. package/src/render/shaders/flat/index.ts +49 -5
  229. package/src/render/shaders/flat/main.ts +43 -5
  230. package/src/render/shaders/flat/models.ts +1 -1
  231. package/src/render/shaders/flat/overlay.ts +117 -0
  232. package/src/render/shaders/flat/pointShadow.ts +3 -3
  233. package/src/render/shaders/flat/preamble.ts +38 -24
  234. package/src/render/shaders/flat/reflectionSurface.ts +61 -0
  235. package/src/render/shaders/fog.ts +9 -2
  236. package/src/render/shaders/fringe.ts +59 -0
  237. package/src/render/shaders/generated/arcane.wgsl.ts +1 -1
  238. package/src/render/shaders/generated/bolt.wgsl.ts +1 -1
  239. package/src/render/shaders/generated/caustics.wgsl.ts +1 -1
  240. package/src/render/shaders/generated/depth.wgsl.ts +95 -0
  241. package/src/render/shaders/generated/film.wgsl.ts +1 -1
  242. package/src/render/shaders/generated/fire.wgsl.ts +1 -1
  243. package/src/render/shaders/generated/flat.wgsl.ts +3292 -2957
  244. package/src/render/shaders/generated/line.wgsl.ts +1 -1
  245. package/src/render/shaders/generated/particle.wgsl.ts +4 -4
  246. package/src/render/shaders/generated/rush.wgsl.ts +56 -26
  247. package/src/render/shaders/generated/scatter.wgsl.ts +1 -1
  248. package/src/render/shaders/generated/smoke.wgsl.ts +1 -1
  249. package/src/render/shaders/generated/ssrResolve.wgsl.ts +30 -0
  250. package/src/render/shaders/generated/ssrTrace.wgsl.ts +22 -2
  251. package/src/render/shaders/generated/water.wgsl.ts +1 -1
  252. package/src/render/shaders/gpudriven/fog.wgsl.ts +11 -3
  253. package/src/render/shaders/outputTransform.ts +30 -14
  254. package/src/render/shaders/rush.ts +54 -11
  255. package/src/render/shaders/ssrResolve.ts +52 -0
  256. package/src/render/shaders/ssrTrace.ts +26 -0
  257. package/src/render/shaders/vertexChannel.ts +27 -0
  258. package/src/render/ssrPass.ts +138 -1
  259. package/src/render/staticDraws.ts +95 -0
  260. package/src/render/surfaceOverlay.ts +195 -0
  261. package/src/render/surfaceTexture.ts +161 -27
  262. package/src/render/temporalAa.ts +20 -0
  263. package/src/render/vertexDefaults.ts +28 -0
@@ -23,13 +23,16 @@ import type { TextStyle } from '../../textLayout.ts';
23
23
  import { GpuSurfaceTexture } from './surfaceTexturePass.ts';
24
24
  import { GpuClothBinding, GpuClothParticles } from './clothTextures.ts';
25
25
  import type { ComputeHost } from './computeHost.ts';
26
+ import { type SurfaceOverlay } from '../../surfaceOverlay.ts';
26
27
  import type { ClothBindingData } from '../../clothBindingData.ts';
27
- import type { CompressedTextureFormat, SurfaceSource } from '../../compressedSource.ts';
28
+ import type { CompressedTextureFormat, CompressedTextureSource, SurfaceSource } from '../../compressedSource.ts';
28
29
  import { GpuSdfText } from './sdfTextPass.ts';
29
30
  import type { SdfFont } from '../../sdfFont.ts';
30
31
  import type { SdfTextStyle } from '../../sdfTextLayout.ts';
31
32
  import type { SurfaceMaterial, SurfaceTextureOptions } from '../../surfaceTexture.ts';
32
33
  import type { RenderBackend } from '../api.ts';
34
+ import { type DisplayRange } from '../../displayRange.ts';
35
+ import { type FilmicCurve } from '../../filmicCurve.ts';
33
36
  import { type ColourGradeLut } from '../../colourGrade.ts';
34
37
  import type { CausticSheet } from '../../causticsRenderer.ts';
35
38
  import { type GpuCaustics } from './causticsPass.ts';
@@ -44,6 +47,8 @@ import type { MeshData } from '../../mesh.ts';
44
47
  import type { ShadowCasters } from '../../shadowCasters.ts';
45
48
  import { type GpuMesh } from './buffers.ts';
46
49
  import type { GpuSurface } from './device.ts';
50
+ import type { BoneAnimationClip, BoneAnimationHandle } from '../../boneAnimation.ts';
51
+ import type { StaticDrawsHandle } from '../../staticDraws.ts';
47
52
  import { type GpuScatter } from './scatterPass.ts';
48
53
  import { type GpuWater } from './waterPass.ts';
49
54
  import { type GpuPlumes } from './plumePass.ts';
@@ -140,6 +145,8 @@ export declare class WebGPURenderer implements RendererApi {
140
145
  private readonly skinnedBindGroupLayout;
141
146
  private readonly morphedBindGroupLayout;
142
147
  private readonly bothBindGroupLayout;
148
+ /** The instanced layout of a batch playing a bone animation. See `animatedGroup`. */
149
+ private readonly animatedBindGroupLayout;
143
150
  /** The morph weights the following draws use, or null for none. */
144
151
  private morphWeights;
145
152
  /**
@@ -153,13 +160,6 @@ export declare class WebGPURenderer implements RendererApi {
153
160
  * Keyed by slot instead, the groups are built once and reused for the life of the renderer.
154
161
  */
155
162
  private readonly skinnedGroups;
156
- /** The unskinned group each was built beside, for identity-based invalidation. */
157
- private readonly skinnedGroupsBeside;
158
- private readonly skinnedGroupsPalette;
159
- private readonly skinnedGroupsDeltas;
160
- /** The cloth views each skinned twin was built with, compared by identity like the palette. */
161
- private readonly skinnedGroupsCloth;
162
- private readonly skinnedGroupsClothBinding;
163
163
  /** The cloth the next skinned draws are placed by, or null. See `setCloth`. */
164
164
  private cloth;
165
165
  private clothStandCache;
@@ -227,22 +227,51 @@ export declare class WebGPURenderer implements RendererApi {
227
227
  /** Every distinct cache above, so a mesh's pipelines are built for each. One entry when aliased. */
228
228
  private readonly pipelineTargets;
229
229
  private readonly bindGroupLayout;
230
- /** One slot per draw, uploaded once a frame. See `UniformRing`. */
231
- private readonly perDraw;
232
- /** The lights, fog and camera, settled once per frame by `bindMeshPass`. */
233
- private readonly perFrame;
230
+ /** One slot per draw, uploaded once a frame. See `UniformRing`. Swapped while a static list records. */
231
+ private perDraw;
234
232
  /**
235
- * The material block as the CPU holds it, patched by the setters and copied into a slot.
233
+ * The lights, fog and camera, a slot per mesh pass a frame opens: `bindMeshPass` writes them, and
234
+ * the first draw after it takes a slot. A ring rather than one buffer because a frame opens more
235
+ * than one pass — a mirror's, a capture's, a probe face's — and a queue write does not interleave
236
+ * with the draws recorded between them. See `UniformRing`.
237
+ */
238
+ private passRing;
239
+ /** Each material's block, kept across frames for as long as it does not change. */
240
+ private readonly materialStore;
241
+ /**
242
+ * Both blocks as the CPU holds them, the pass's then the material's, patched by name and copied
243
+ * into a slot by the next draw after something changed them. See `FlatFragmentScratch`.
236
244
  *
237
245
  * Authoritative between draws: a setter changes one field here and marks the block dirty, and
238
- * the next `drawMesh` takes a slot and copies the whole thing in. That keeps a setter free of
239
- * any knowledge of slots, which is what lets it be called anywhere a scene wants.
246
+ * the next `drawMesh` places it. That keeps a setter free of any knowledge of slots, which is
247
+ * what lets it be called anywhere a scene wants.
240
248
  */
241
249
  private readonly perFrameStaging;
242
250
  private readonly perFrameFloats;
243
251
  private readonly perFrameInts;
252
+ /** The two halves of the scratch, as the words a slot is written from. */
253
+ private readonly passInts;
254
+ private readonly materialInts;
244
255
  /** The slot the open material occupies, and whether the next draw must take a new one. */
245
256
  private readonly materials;
257
+ /** The same for the pass's block: reopened by `bindMeshPass` and by nothing a material sets. */
258
+ private readonly passBlock;
259
+ /**
260
+ * The vertex stage's view block — the camera, the light's matrix, the wind — a slot a pass, and a
261
+ * second, unjittered, for a blended draw landing after the upscale. Reopened with the pass, and by
262
+ * `setWind` and `beginShadowPass`, which change what it holds.
263
+ */
264
+ private viewRing;
265
+ private readonly viewBlock;
266
+ private readonly lateViewBlock;
267
+ /** The view slot the draw being submitted bound, read by the halves it keeps for later passes. */
268
+ private drawViewOffset;
269
+ /** Pass slots asked for and refused this frame, and materials refused: what grows the two. */
270
+ private passesAsked;
271
+ private passesRefused;
272
+ private viewsAsked;
273
+ private viewsRefused;
274
+ private materialsRefused;
246
275
  /**
247
276
  * What this frame asked for against the ceilings above, reported rather than only warned about.
248
277
  *
@@ -450,7 +479,7 @@ export declare class WebGPURenderer implements RendererApi {
450
479
  private readonly variant;
451
480
  /** Whether this profile compiled the point-shadow path, and so has sentinels to write. */
452
481
  private readonly pointShadowsCompiled;
453
- /** What the generator recorded about that permutation: sizes, offsets and bindings. */
482
+ /** What the generator recorded about that permutation, as the renderer's scratch lays it out. */
454
483
  private readonly fragment;
455
484
  private depth;
456
485
  private depthView;
@@ -508,6 +537,17 @@ export declare class WebGPURenderer implements RendererApi {
508
537
  */
509
538
  private refractSnapshot;
510
539
  private refractSnapshotView;
540
+ /**
541
+ * The frame's colour as a registered pass reads it (`reads: ['colorSnapshot']`): the scene's own
542
+ * size and format, refilled at each such pass's draw. Allocated only once a pass declares the
543
+ * read, beside the frame's targets, and never in the frame loop. See `takePassColour`.
544
+ */
545
+ private passColour;
546
+ private passColourView;
547
+ /** Registered passes that read the colour, queued this frame for after the upscale. */
548
+ private readonly latePasses;
549
+ /** A late pass draws unjittered, as every late draw does. */
550
+ private readonly latePassJitter;
511
551
  /** Whether this frame has taken it. One snapshot serves every refracting draw. */
512
552
  private refractSnapshotTaken;
513
553
  /**
@@ -992,6 +1032,15 @@ export declare class WebGPURenderer implements RendererApi {
992
1032
  private readonly reflectionQueue;
993
1033
  private ssrLayout;
994
1034
  private ssrResolveLayout;
1035
+ /** The frame's materials' reflections, resolved; null where off. See `frameReflections.ts`. */
1036
+ private readonly frameReflections;
1037
+ /** Their surface half, null where they are off or cannot be drawn: `reflectionSurfacePass.ts`. */
1038
+ private readonly reflectionSurface;
1039
+ /** The material resolve: its layout, its one block (the blur) and its group over the three maps. */
1040
+ private ssrMaterialLayout;
1041
+ private ssrMaterialUniforms;
1042
+ private readonly ssrMaterialFloats;
1043
+ private ssrMaterialGroup;
995
1044
  private ssrUniforms;
996
1045
  private readonly ssrStaging;
997
1046
  private readonly ssrFloats;
@@ -1158,7 +1207,7 @@ export declare class WebGPURenderer implements RendererApi {
1158
1207
  * ones that move something *every* group holds: the shadow cubemaps, the probe fence, the cookie
1159
1208
  * atlas and the IES rows. None of those is a frame path.
1160
1209
  */
1161
- private readonly flatBindGroups;
1210
+ private flatBindGroups;
1162
1211
  /** The group holding the one-pixel stand-in, for every draw with no texture set. */
1163
1212
  private blankAlbedoBindGroup;
1164
1213
  /** Repeats across the mesh's own UV range. Per draw, because `uUvScale` is a vertex uniform. */
@@ -1215,7 +1264,7 @@ export declare class WebGPURenderer implements RendererApi {
1215
1264
  * opens is submitted by the time the next one begins.
1216
1265
  */
1217
1266
  private readonly retiredTextures;
1218
- updateSurfaceTexture(texture: GpuSurfaceTexture, source: TexImageSource): void;
1267
+ updateSurfaceTexture(texture: GpuSurfaceTexture, source: TexImageSource | CompressedTextureSource): void;
1219
1268
  disposeSurfaceTexture(texture: GpuSurfaceTexture): void;
1220
1269
  /**
1221
1270
  * Drop every bind group that may hold `texture`'s view, and rebuild the ones bound now.
@@ -1319,10 +1368,26 @@ export declare class WebGPURenderer implements RendererApi {
1319
1368
  * frame's. See `Renderer.setAmbientSH`: material state, so the next draw takes a slot of its own.
1320
1369
  */
1321
1370
  setAmbientSH(coefficients: ArrayLike<number> | null): void;
1371
+ /**
1372
+ * The overlay the following draws wear, or null for none: pass state, put back to none by
1373
+ * `bindMeshPass`. See `renderer.ts` and `surfaceOverlay.ts`. The numbers go in the material block,
1374
+ * which every variant declares; the atlas goes in a twin of each flat group (`overlayGroup`).
1375
+ */
1376
+ setSurfaceOverlay(overlay: SurfaceOverlay | null): void;
1322
1377
  /** How reflective the surfaces drawn next are. Clamped, as `renderer.ts` clamps it. */
1323
1378
  setSurfaceReflectivity(amount: number): void;
1324
1379
  /** How bright the environment the surfaces drawn next reflect is. See `renderer.ts`. */
1325
1380
  setEnvironmentGain(gain: number): void;
1381
+ /**
1382
+ * The reflectivity and environment gain the setters gave the pass, and the ones the material
1383
+ * set now states, or null where it states none (`SurfaceMaterial.reflectivity`). A draw wears the
1384
+ * material's where it has one and the pass's otherwise, the rule `renderer.ts` keeps too.
1385
+ */
1386
+ private passReflectivity;
1387
+ private passEnvironmentGain;
1388
+ private materialReflectivity;
1389
+ private materialEnvironmentGain;
1390
+ private writeEnvironmentDials;
1326
1391
  setSurfaceGrain(amount: number): void;
1327
1392
  /** Whether the surfaces drawn next meet the medium. See `renderer.ts`. */
1328
1393
  setSurfaceFog(enabled: boolean): void;
@@ -1789,14 +1854,6 @@ export declare class WebGPURenderer implements RendererApi {
1789
1854
  * its own two programs.
1790
1855
  */
1791
1856
  private writeShadowWind;
1792
- /**
1793
- * The five wind fields of one per-draw slot.
1794
- *
1795
- * **Never called for an instanced draw.** That variant declares none of these, and
1796
- * `flatPass.ts` records what writing a field a variant does not declare costs: the block is
1797
- * shorter, so the write lands on whatever occupies that offset instead.
1798
- */
1799
- private writeWind;
1800
1857
  /** Refilled per frame rather than allocated; see `resolvePointLights`. */
1801
1858
  private readonly lights;
1802
1859
  /** The fixed arm's rectangles as `uAreaLightSize` holds them. See `packAreaSizesAndDoors`. */
@@ -1916,6 +1973,9 @@ export declare class WebGPURenderer implements RendererApi {
1916
1973
  * at submit, and a texture's view is new when an update changes its size.
1917
1974
  */
1918
1975
  private readonly shadowCutoutLayout;
1976
+ /** A crowd's casters: the plain and cutout layouts with a bone animation's three textures. */
1977
+ private readonly shadowAnimatedLayout;
1978
+ private readonly shadowAnimatedCutoutLayout;
1919
1979
  private readonly cutoutGroups;
1920
1980
  private readonly cutoutPeelGroups;
1921
1981
  private shadowPeelPassUniforms;
@@ -2238,6 +2298,21 @@ export declare class WebGPURenderer implements RendererApi {
2238
2298
  * can do nothing about. Done with `complete` still false is the signal that it was abandoned.
2239
2299
  */
2240
2300
  createMeshIncremental(given: MeshData, options?: MeshOptions): IncrementalMeshHandle;
2301
+ /**
2302
+ * The copies this frame's mesh rewrites owe (`StagedRewrite`), recorded since the last submit and
2303
+ * sent at the head of the next one: one encoder however many meshes are rewritten. Null while
2304
+ * nothing is owed.
2305
+ */
2306
+ private pendingRewrites;
2307
+ /** One record handed to every staged rewrite, refilled each call, so a rewrite allocates nothing. */
2308
+ private readonly stagedRewrite;
2309
+ private rewriteCopies;
2310
+ /**
2311
+ * Submit `buffers`, led by any copies the frame's mesh rewrites owe. **Every submit of this
2312
+ * renderer goes through here**, because any of them may draw a rewritten mesh — the frame's own,
2313
+ * a mirror's, a shadow's, a probe's — and the copies must be ahead of the first that does.
2314
+ */
2315
+ private submit;
2241
2316
  /**
2242
2317
  * Rewrite a mesh's positions, and its normals where the caller has them.
2243
2318
  *
@@ -2256,15 +2331,34 @@ export declare class WebGPURenderer implements RendererApi {
2256
2331
  */
2257
2332
  bindMeshPass(camera: Camera, env: Environment): void;
2258
2333
  /**
2259
- * The slot the next draw's material lives in, taking a new one when something dirtied it.
2334
+ * The slot the next draw's material lives in, placing it when something dirtied it, with the
2335
+ * pass's slot taken first where `bindMeshPass` reopened it: `passOffset` is that one's offset.
2260
2336
  *
2261
- * **A copy per material change, not per draw.** A scene drawing a hundred meshes of one
2262
- * material spends one slot and one copy; a scene switching material every draw spends one
2263
- * each, which is what it asked for.
2337
+ * **A placement per material change, not per draw.** A scene drawing a hundred meshes of one
2338
+ * material places it once; a scene switching material every draw places one each, and a material
2339
+ * the store already holds — the same numbers as a draw before it, this frame or an earlier one —
2340
+ * is bound where it is and uploads nothing.
2264
2341
  */
2265
2342
  private materialSlotForDraw;
2343
+ /** The pass slot `materialSlotForDraw` left open, read beside the material's by every lit draw. */
2344
+ private get passOffset();
2345
+ /** A new pass: its block, and both its views, are taken afresh by the next draw. */
2346
+ private reopenPass;
2347
+ /** What a view holds changed — the wind, the light's matrix — so the next draw takes a new one. */
2348
+ private reopenViews;
2349
+ /**
2350
+ * The view slot a lit draw reads its camera from: the pass's, or its unjittered twin for a blended
2351
+ * draw landing after the upscale. Taken by the first draw that needs it after the pass, the wind or
2352
+ * the light's matrix changed, and shared by every draw until then. Null when the ring is full, which
2353
+ * skips the draw and grows the ring for the next frame, as the pass ring does.
2354
+ */
2355
+ private viewSlotFor;
2356
+ /** A view block: the camera, the light's matrix and the frame's wind, into `ring` at `slot`. */
2357
+ private writeView;
2358
+ private warnMaterialsFull;
2266
2359
  /** Said once rather than every frame, for the reason `warnedFull` gives. */
2267
2360
  private warnedMaterialsFull;
2361
+ private warnedPassesFull;
2268
2362
  private warnedSkyFull;
2269
2363
  private warnedParticlesTwice;
2270
2364
  /**
@@ -2378,6 +2472,26 @@ export declare class WebGPURenderer implements RendererApi {
2378
2472
  * the shape this repository spent a week removing.
2379
2473
  */
2380
2474
  createInstanced(mesh: GpuMesh, capacity: number, options?: InstancedOptions): GpuInstancedBatch;
2475
+ /** See `Renderer.setAnimationTime`. Every view taken after it reads the new clock. */
2476
+ setAnimationTime(seconds: number): void;
2477
+ /** The clock `setAnimationTime` set, 0 until it is. */
2478
+ private animationTime;
2479
+ /** See `Renderer.createBoneAnimation`. */
2480
+ createBoneAnimation(clip: BoneAnimationClip): BoneAnimationHandle;
2481
+ /** See `Renderer.disposeBoneAnimation`. A batch still playing it draws nothing after. */
2482
+ disposeBoneAnimation(animation: BoneAnimationHandle): void;
2483
+ /** An animated batch's clip and clocks, as its groups bind them. */
2484
+ private animationViews;
2485
+ /** An animated batch's groups, dropped wherever the renderer drops its own. */
2486
+ private freshAnimatedGroups;
2487
+ /**
2488
+ * The lit group an animated batch draws with: the material's group, or its overlay twin, again
2489
+ * with the clip's and the clocks' textures — kept on the batch by the group it was built beside,
2490
+ * as a skinned twin is kept by its palette slot.
2491
+ */
2492
+ private animatedGroup;
2493
+ /** An animated caster's shadow group, by what it cuts with and whether this is the peel. */
2494
+ private animatedDepthGroup;
2381
2495
  /** The device instance culls, built on the first culling draw. See `InstanceCullPass`. */
2382
2496
  private instanceCulls;
2383
2497
  /** Counts frames, so a batch knows when its cull slots were last taken. */
@@ -2498,6 +2612,38 @@ export declare class WebGPURenderer implements RendererApi {
2498
2612
  * face. What it replaces is a consumer re-entering its whole draw path with a second camera.
2499
2613
  */
2500
2614
  drawSceneCasters(casters: ShadowCasters): void;
2615
+ /** See `Renderer.createStaticDraws`. Recorded on its first draw, into each view it is drawn in. */
2616
+ createStaticDraws(casters: ShadowCasters): StaticDrawsHandle;
2617
+ /**
2618
+ * See `Renderer.drawStaticDraws`. One bundle executed, after a pass block and a view block are
2619
+ * written for this view; the list is recorded first where it has no recording that is current for
2620
+ * this target and starting state. See `staticBundles.ts`.
2621
+ */
2622
+ drawStaticDraws(draws: StaticDrawsHandle): void;
2623
+ /** A list drawn the way `drawSceneCasters` draws, a draw at a time, for where a bundle cannot be. */
2624
+ private replayStaticImmediately;
2625
+ /** See `Renderer.disposeStaticDraws`. Its pins let go; its meshes and materials are the caller's. */
2626
+ disposeStaticDraws(draws: StaticDrawsHandle): void;
2627
+ /** The recording to replay `list` from here, made now if none is current; null if it cannot be. */
2628
+ private staticRecordingFor;
2629
+ /** How a list's pins are let go: through the store, unless it has forgotten them since. */
2630
+ private unpinFor;
2631
+ /**
2632
+ * Record `list` into `recording`: its entries through the scene-caster path, with the list's
2633
+ * rings and group cache swapped in for the frame's and the pass and view slots held at the list's
2634
+ * first copy, so every command the path records binds the list's buffers and offsets the bundle
2635
+ * can rewrite per copy. Everything swapped is put back, whatever the path throws.
2636
+ */
2637
+ private recordStatic;
2638
+ /** The recording under way, which `recordDraw` and the side passes take their commands into. */
2639
+ private staticRecording;
2640
+ /** Whether the replay about to count its material changes recorded them, and so counted them. */
2641
+ private staticJustRecorded;
2642
+ /** A disposed list drawn, said once: the frame loop does not throw. */
2643
+ private warnStaticDisposed;
2644
+ private warnedStaticDisposed;
2645
+ /** Bumped wherever the lit groups are dropped, which a static list's own groups follow. */
2646
+ private flatGroupEpoch;
2501
2647
  drawShadowCasters(casters: ShadowCasters): void;
2502
2648
  /** Close the shadow pass and submit it, so the frame can sample what it wrote. */
2503
2649
  /**
@@ -2555,6 +2701,20 @@ export declare class WebGPURenderer implements RendererApi {
2555
2701
  private warnedNoPointShadowArray;
2556
2702
  /** Said once, for the retired ambient dial. */
2557
2703
  private warnedEnvironmentAmbient;
2704
+ /** The overlay the draws wear, `uOverlay`: see `setSurfaceOverlay`. */
2705
+ private readonly overlayFloats;
2706
+ /** Its atlas, bound where the refraction copy goes in a twin of each flat group. */
2707
+ private overlayMaps;
2708
+ /**
2709
+ * Each flat group's twin with the atlas in the refraction slot, by the group and the atlas, built
2710
+ * on the first draw that wears it and dropped wherever `flatBindGroups` is.
2711
+ */
2712
+ private readonly overlayGroups;
2713
+ /** True while a twin is built: what `flatTextures` hands the refraction slot then. */
2714
+ private overlayBinding;
2715
+ /** True between `bindSeeThrough` and `releaseSeeThrough`: that draw reads the copy, not the atlas. */
2716
+ private seeThroughBound;
2717
+ private warnedOverlayRefraction;
2558
2718
  private readonly castingWorldIndices;
2559
2719
  private readonly resolvedPointShadows;
2560
2720
  /** One face's view-projection, rebuilt per face rather than allocated. */
@@ -2618,14 +2778,23 @@ export declare class WebGPURenderer implements RendererApi {
2618
2778
  */
2619
2779
  private resolveFace;
2620
2780
  private buildFlatBindGroup;
2781
+ /**
2782
+ * The open material's flat group, or its twin with the surface overlay's atlas in the refraction
2783
+ * slot where the draw wears one and does not refract. A twin is built from the live material,
2784
+ * which `bindGroup` always is, and kept by the group and the atlas.
2785
+ *
2786
+ * **A draw that refracts, or is glass, keeps the frame's copy** and its overlay reads no image —
2787
+ * the shader asks the same of `uSeeThrough` (`overlayImagesBound`) — said once.
2788
+ */
2789
+ private overlayGroup;
2621
2790
  /**
2622
2791
  * The bind group a draw uses, skinned or not.
2623
2792
  *
2624
- * **The skinned twin is cached against the two things that can invalidate it**, rather than
2625
- * against a flag somebody has to remember to clear at six call sites: the unskinned group it was
2626
- * built beside — which is rebuilt whenever the material or a shadow slot moves — and the palette
2627
- * view, which changes only when the texture is reallocated. Comparing object identity means a
2628
- * missed invalidation is not possible rather than merely unlikely, and it is why
2793
+ * **The skinned twin is kept by palette slot and by the unskinned group it was built beside**,
2794
+ * which is one a material, and compared against the views it holds — the palette's, which
2795
+ * changes only when the slot's texture grows, the morph deltas and the cloth's — rather than
2796
+ * against a flag somebody has to remember to clear at six call sites. Comparing object identity
2797
+ * means a missed invalidation is not possible rather than merely unlikely, and it is why
2629
2798
  * `SkinPaletteTexture.view()` caches: a fresh view every call never compares equal and would
2630
2799
  * rebuild this every draw.
2631
2800
  */
@@ -2806,6 +2975,13 @@ export declare class WebGPURenderer implements RendererApi {
2806
2975
  * the grade, so they are graded exactly as they were when they were drawn into the scene.
2807
2976
  */
2808
2977
  private runLate;
2978
+ /**
2979
+ * The registered passes `drawPass` queued for after the upscale: each handed a fresh copy of the
2980
+ * reconstructed picture with every late draw in it, in the output-size texture the late
2981
+ * refraction keeps (its own reads are done by now: they were recorded before this copy), then
2982
+ * drawn over the picture in a pass of its own.
2983
+ */
2984
+ private runLatePasses;
2809
2985
  /** Whether this draw lands in the reconstructed picture. See `lateRouting.ts`. */
2810
2986
  private tracksMotionNow;
2811
2987
  /**
@@ -3010,6 +3186,16 @@ export declare class WebGPURenderer implements RendererApi {
3010
3186
  * the frame, or an order-independent set, none of which the spread reads.
3011
3187
  */
3012
3188
  private skinSplits;
3189
+ /** Whether a draw now is the frame's own, and so has a surface half to keep. */
3190
+ private reflectionSurfaceKeeps;
3191
+ /**
3192
+ * An opaque lit draw's surface half, kept for the frame's materials' reflections: the draw again,
3193
+ * with the same slots, buffers and bind group, through the pipeline with `REFLECTION_SURFACE` on —
3194
+ * which writes what the pixel reflects of its environment into the two targets
3195
+ * `reflectionSurfacePass.ts` holds and tests for the depth its frame draw wrote. Replayed when the
3196
+ * frame's pass has ended, before the trace reads them. See `shaders/flat/reflectionSurface.ts`.
3197
+ */
3198
+ private keepReflectionSurface;
3013
3199
  /**
3014
3200
  * A skin draw's diffuse and colour halves, kept for the spread: the frame's draw again, twice,
3015
3201
  * with the same slots, buffers and bind group, through the pipelines that write the diffuse's
@@ -3027,6 +3213,21 @@ export declare class WebGPURenderer implements RendererApi {
3027
3213
  */
3028
3214
  private runSkinScatter;
3029
3215
  private takeVolumeDepth;
3216
+ /** The colour copy a registered pass reads, at the scene's size and format. See `passColour`. */
3217
+ private allocatePassColour;
3218
+ /**
3219
+ * The frame's colour so far, into `passColour`, for a registered pass that reads it: the
3220
+ * boundary `takeRefractSnapshot` describes — flush, end the pass, copy what its end resolved,
3221
+ * reopen with `load` — and refused where that one is, in a mirror, a probe bake or a capture,
3222
+ * whose pictures are not the frame's. **Not latched**, unlike refraction's: each reading pass
3223
+ * sees the passes drawn before it, at a full-frame copy each.
3224
+ */
3225
+ private takePassColour;
3226
+ /**
3227
+ * The frame's pass again after a copy between passes, loading everything already drawn: the same
3228
+ * attachments the copy's caller ended, with nothing cleared.
3229
+ */
3230
+ private reopenFramePass;
3030
3231
  /**
3031
3232
  * The pass to record into, reopening one on the canvas if the frame has already gone.
3032
3233
  *
@@ -3584,6 +3785,30 @@ export declare class WebGPURenderer implements RendererApi {
3584
3785
  setOutputExposure(exposure: number): void;
3585
3786
  /** This frame's exposure into the tone curve. Starts at the profile's own. */
3586
3787
  private exposure;
3788
+ /**
3789
+ * The `filmic` curve every later frame is graded through, until it is set again. See
3790
+ * `RendererApi.setFilmicCurve`; the constants are solved here once, not per frame or per pixel.
3791
+ */
3792
+ setFilmicCurve(curve: FilmicCurve): void;
3793
+ private warnedFilmClamped;
3794
+ /** The curve last set, so a new headroom can solve it again. */
3795
+ private filmCurve;
3796
+ /** The display's peak over paper white; 1 on a standard range. See `setDisplayLuminance`. */
3797
+ private headroom;
3798
+ /** The range the frame goes out in. See `RendererApi.displayRange`. */
3799
+ get displayRange(): DisplayRange;
3800
+ /** Why it is that range, in words. */
3801
+ get displayRangeReason(): string;
3802
+ /**
3803
+ * How bright paper white and the display's peak are, in any one unit (nits, usually), held until
3804
+ * changed: their ratio is how far above white the highlights may run on a high range display,
3805
+ * and nothing changes on a standard one. See `RendererApi.setDisplayLuminance`.
3806
+ */
3807
+ setDisplayLuminance(paperWhite: number, peak: number): void;
3808
+ /** The curve's eight constants, and the two views the composite uploads them through. */
3809
+ private readonly filmConstants;
3810
+ private readonly filmA;
3811
+ private readonly filmB;
3587
3812
  private bloomScale;
3588
3813
  /** The draw's own ambient, as `packAmbientSH` writes it; zeros are the frame's. */
3589
3814
  private readonly ambientSH;
@@ -3607,6 +3832,8 @@ export declare class WebGPURenderer implements RendererApi {
3607
3832
  private readonly veilColor;
3608
3833
  private veilAlpha;
3609
3834
  private vignette;
3835
+ /** The lens's colour fringe: red's and green's pull and where it begins. See `fringe.ts`. */
3836
+ private readonly fringe;
3610
3837
  private grain;
3611
3838
  private grainSeed;
3612
3839
  private warnedLookWithoutComposite;
@@ -3622,6 +3849,14 @@ export declare class WebGPURenderer implements RendererApi {
3622
3849
  * see `filmLook.ts`. Needs `screenEffects`, and says so once rather than doing nothing.
3623
3850
  */
3624
3851
  setVignette(strength: number): void;
3852
+ /**
3853
+ * The lens's colour fringe, held until changed: `intensity` is a percentage, 0 is none, and red
3854
+ * and green are pulled toward the centre by their wavelength's distance from blue, growing from
3855
+ * `start` — a share of the half-frame, 0 the centre — to the whole of it at the edge. Applied to
3856
+ * scene light at the composite's first read. Needs `screenEffects`, and says so once rather than
3857
+ * doing nothing. See `shaders/fringe.ts`.
3858
+ */
3859
+ setChromaticAberration(intensity: number, start?: number): void;
3625
3860
  /**
3626
3861
  * Film grain, held until changed: an amplitude in display values (0 is none, 0.03 is a fine
3627
3862
  * grain) and this frame's seed. **The seed is the caller's**, because the engine takes time from
@@ -3667,8 +3902,19 @@ export declare class WebGPURenderer implements RendererApi {
3667
3902
  setGlobalMedium(density: number, albedo?: number, anisotropy?: number, maxDistance?: number): void;
3668
3903
  /** How much speed blur the frame should resolve with, 0 to 1. */
3669
3904
  setSpeedRush(strength: number): void;
3670
- /** How much of the frame's camera motion blur to apply, 0 to 1. */
3671
- setCameraMotionBlur(scale: number): void;
3905
+ /**
3906
+ * How much of the frame's motion blur to apply, 0 to 1, and the longest smear as a share of the
3907
+ * frame, both held until changed. See `RendererApi.setCameraMotionBlur`.
3908
+ */
3909
+ setCameraMotionBlur(scale: number, maxShare?: number): void;
3910
+ /** The longest smear, as a share of the frame. See `setCameraMotionBlur`. */
3911
+ private motionBlurMax;
3912
+ private warnedObjectBlur;
3913
+ /**
3914
+ * Said once: a draw named where it was last frame while the frame blurs, and this frame keeps no
3915
+ * motion target to blur it by — the camera's motion alone smears it. See `OBJECT_BLUR_UNKEPT`.
3916
+ */
3917
+ private warnObjectBlur;
3672
3918
  /**
3673
3919
  * The camera has cut: this frame is a new shot, not the next moment of the last one.
3674
3920
  *