@displayxr/inline3d 1.13.0 → 1.13.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -5,6 +5,24 @@ entry points (`.`, `./three`) are frozen for 1.x, while the **scene subpaths** (
5
5
  `./splat`, `./model`) are a preview tier whose options may change in any release. Entries below say
6
6
  which tier they touch, because that is what tells you whether an upgrade can move your pixels.
7
7
 
8
+ ## 1.13.1 — 2026-09-24
9
+
10
+ Touches the **preview tier** (`./splat`, `engine: 'playcanvas'` only). No pixel change.
11
+
12
+ ### Fixed
13
+
14
+ - **An asset kept re-rendering its work buffer, and re-sorting, every frame after any entity-scope
15
+ effect had ended**: the `wavefront` and `flip` transitions, a load-time `reveal`, a `setSource`
16
+ `reveal`, and `playEffect`/`setEffect` with `scope: 'entity'`. The effects runner ended an effect
17
+ with `workBufferUpdate = ONCE`. The engine's placement setter treats ONCE as a one-shot re-render
18
+ and never leaves ALWAYS, so the photo shown after a wavefront paid a full work-buffer copy, a CPU
19
+ sort and a 4.7 MB order-texture upload every frame until the next swap. Removal now sets AUTO,
20
+ then ONCE, for one clean re-render. Measured on an M1 (headless Chrome, 1,179,648 gaussians,
21
+ steady state after a `wavefront`, 3 runs): sorts went from 60/s (every frame) to 0. Main-thread
22
+ frame time at 4× CPU throttling went from 1.9–2.1 ms to 0.2–0.7 ms. GPU-synced frame time at 1×
23
+ went from 16.0 ms to 14.4–14.6 ms, the same as after a `crossfade` (14.3–14.7 ms), which never
24
+ had the bug.
25
+
8
26
  ## 1.13.0 — 2026-09-24
9
27
 
10
28
  Touches the **preview tier** (`./splat`, `engine: 'playcanvas'` only), additively. A page that
@@ -57,6 +57,7 @@ export {
57
57
  RenderTarget,
58
58
  FILTER_NEAREST,
59
59
  // splats
60
+ WORKBUFFER_UPDATE_AUTO,
60
61
  WORKBUFFER_UPDATE_ALWAYS,
61
62
  WORKBUFFER_UPDATE_ONCE,
62
63
  // tone mapping (TONE_MAPPINGS)
@@ -1052,7 +1052,13 @@ export class SplatEffects {
1052
1052
  if ('workBufferUpdate' in g) g.workBufferUpdate = pc.WORKBUFFER_UPDATE_ALWAYS ?? 2;
1053
1053
  } else {
1054
1054
  g.setWorkBufferModifier?.(null);
1055
- if ('workBufferUpdate' in g) g.workBufferUpdate = pc.WORKBUFFER_UPDATE_ONCE ?? 1;
1055
+ if ('workBufferUpdate' in g) {
1056
+ // AUTO first: the engine's placement setter treats ONCE as a one-shot re-render and never
1057
+ // leaves ALWAYS, so ONCE alone kept the asset re-rendering its work buffer (and re-sorting)
1058
+ // every frame after its effect had ended.
1059
+ g.workBufferUpdate = pc.WORKBUFFER_UPDATE_AUTO ?? 0;
1060
+ g.workBufferUpdate = pc.WORKBUFFER_UPDATE_ONCE ?? 1;
1061
+ }
1056
1062
  this.scopes.delete(key);
1057
1063
  this._installed.delete(key);
1058
1064
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@displayxr/inline3d",
3
- "version": "1.13.0",
3
+ "version": "1.13.1",
4
4
  "description": "Turn any HTML <canvas> into a glasses-free-3D window on a DisplayXR display, inside an ordinary web page. Dependency-free; progressive enhancement (falls back to plain 2D everywhere else).",
5
5
  "type": "module",
6
6
  "types": "./index.d.ts",