pixi-effects 0.47.5 → 0.48.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/README.md +8 -6
  3. package/ai/chat-template.html +3 -3
  4. package/dist/Composition-BOLWGT2R.js +7 -0
  5. package/dist/{Composition-ZCRJHBB5.js.map → Composition-BOLWGT2R.js.map} +1 -1
  6. package/dist/Composition-ZZEOEETS.cjs +16 -0
  7. package/dist/{Composition-PMWLJQPI.cjs.map → Composition-ZZEOEETS.cjs.map} +1 -1
  8. package/dist/Controller.cjs +3 -0
  9. package/dist/Controller.cjs.map +1 -1
  10. package/dist/Controller.js +3 -0
  11. package/dist/Controller.js.map +1 -1
  12. package/dist/{Spans-KTUPDFSR.cjs → Spans-MWYFG7RI.cjs} +9 -9
  13. package/dist/{Spans-KTUPDFSR.cjs.map → Spans-MWYFG7RI.cjs.map} +1 -1
  14. package/dist/{Spans-FMAVPATS.js → Spans-PGXRMD6J.js} +4 -4
  15. package/dist/{Spans-FMAVPATS.js.map → Spans-PGXRMD6J.js.map} +1 -1
  16. package/dist/{chunk-UI7CEUTP.js → chunk-AJWUCFGM.js} +3 -3
  17. package/dist/{chunk-UI7CEUTP.js.map → chunk-AJWUCFGM.js.map} +1 -1
  18. package/dist/{chunk-LHUIEFMH.js → chunk-IY5YTIK3.js} +56 -41
  19. package/dist/chunk-IY5YTIK3.js.map +1 -0
  20. package/dist/chunk-K3XOEC3C.js +53 -0
  21. package/dist/chunk-K3XOEC3C.js.map +1 -0
  22. package/dist/{chunk-4PYVHLIK.js → chunk-L3MEZZAV.js} +17 -14
  23. package/dist/chunk-L3MEZZAV.js.map +1 -0
  24. package/dist/{chunk-2AT5WSSV.cjs → chunk-L3XC464G.cjs} +101 -86
  25. package/dist/chunk-L3XC464G.cjs.map +1 -0
  26. package/dist/{chunk-OGLRSR6C.cjs → chunk-M2LFQY2E.cjs} +63 -63
  27. package/dist/{chunk-OGLRSR6C.cjs.map → chunk-M2LFQY2E.cjs.map} +1 -1
  28. package/dist/{chunk-ECLBZV4N.cjs → chunk-V3VBHSK6.cjs} +17 -14
  29. package/dist/chunk-V3VBHSK6.cjs.map +1 -0
  30. package/dist/chunk-VQXZ2NOI.cjs +56 -0
  31. package/dist/chunk-VQXZ2NOI.cjs.map +1 -0
  32. package/dist/index.cjs +38 -33
  33. package/dist/index.d.cts +18 -1
  34. package/dist/index.d.ts +18 -1
  35. package/dist/index.js +4 -3
  36. package/dist/loader.css +1 -1
  37. package/dist/present.cjs +4 -3
  38. package/dist/present.cjs.map +1 -1
  39. package/dist/present.js +4 -3
  40. package/dist/present.js.map +1 -1
  41. package/dist/three.cjs +5 -5
  42. package/dist/three.js +1 -1
  43. package/docs/api.md +15 -0
  44. package/llms-full.txt +17 -2
  45. package/package.json +1 -1
  46. package/skills/pixi-effects/SKILL.md +1 -1
  47. package/skills/pixi-effects/reference/pitfalls.md +1 -1
  48. package/skills/pixi-effects/template.html +6 -6
  49. package/dist/Composition-PMWLJQPI.cjs +0 -16
  50. package/dist/Composition-ZCRJHBB5.js +0 -7
  51. package/dist/chunk-2AT5WSSV.cjs.map +0 -1
  52. package/dist/chunk-4PYVHLIK.js.map +0 -1
  53. package/dist/chunk-ECLBZV4N.cjs.map +0 -1
  54. package/dist/chunk-LHUIEFMH.js.map +0 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.48.1
4
+
5
+ Two fixes, nothing breaks: `movie.destroy()` no longer makes PixiJS print hundreds of warnings, and a missing pixi-filters names the filters that need it.
6
+
7
+ - **Fixed: `movie.destroy()` on a movie that had just played printed PixiJS's "a textureSource was destroyed while still bound to a shader" a few hundred times on WebGPU** (closing a modal with a movie in it, for example). The movie never draws again, so the warning said nothing; `destroy()` now silences that one message during its synchronous teardown, as a rebuild already did. Any other warning goes through, and `console.warn` is put back. A test film (`warnings-none-at-destroy`) holds it.
8
+ - **Fixed: when `pixi-filters` could not be loaded, the error named no filter** (`the filter "(see the type in your filters)"`). It now names each filter that needs the package and the layer that uses it: `the filters "glow" (layer "title"), "crt" come from the pixi-filters package …`.
9
+
10
+ ## 0.48.0
11
+
12
+ A page that only plays no longer loads mediabunny (about 180 KB gzipped, a third of what such a page loaded). Nothing breaks.
13
+
14
+ - **mediabunny is fetched the first time something needs it:** the first `movie.render()` (or the download button), or a movie with a `video` asset at `init`. Before, every page imported it at load, and a page whose import map had no `"mediabunny"` entry failed to load at all. Now the entry is needed only to export or for a video layer; a bundler puts it in a chunk of its own.
15
+ - **New: `useMediabunny(source)`** says where it comes from: the module itself, a URL to `import()`, or a function that returns the module. With nothing said, the bare name `'mediabunny'` is imported as before. When it cannot be loaded, the export rejects with a sentence that says what to add, and the next call tries again.
16
+ - A test film (`export-mediabunny-on-demand`) holds it: no fetch while playing, the export and the video layer fetch it, the error and the retry.
17
+
3
18
  ## 0.47.5
4
19
 
5
20
  An island inside a hole no longer draws a wedge, and `init({ loudness })` is never quieter than the plain gain. Nothing breaks.
package/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # pixi-effects
2
2
 
3
- > **Status**: experimental — current release `0.47.5`. The API may still change between minor versions; see the [CHANGELOG](./CHANGELOG.md) for what each release changed.
3
+ > **Status**: experimental — current release `0.48.1`. The API may still change between minor versions; see the [CHANGELOG](./CHANGELOG.md) for what each release changed.
4
4
 
5
5
  **[Gallery →](https://yjmtmtk.github.io/pixi-effects/examples/gallery/)** · 43 pieces written as plain data by AI models · **[For AI →](https://yjmtmtk.github.io/pixi-effects/for-ai.html)** · what an AI reads and runs · **[Playground →](https://yjmtmtk.github.io/pixi-effects/examples/playground.html)** in the browser.
6
6
 
@@ -29,7 +29,7 @@ Declarative composition and video rendering for the web. After Effects-style tim
29
29
  - **Built-in player UI — or your own** — a drop-in HTML5-`<video>`-style overlay controller (play, scrub, mute, volume, fullscreen, export-to-file) whose colours are one option (`theme: { accent: '#ff4d6d' }`); or build a player yourself on the movie's `<video>`-named events (`play pause ended seeking seeked volumechange error`).
30
30
  - **MP4 / WebM / MOV export** — pick container and quality from the controller, call `movie.render()` from code, or render headless from the command line (`pixi-effects render`).
31
31
  - **A timeline you can read and scrub** — `movie.timelineChart()` draws every layer as a bar on a time axis; `pixi-effects view` opens the page with that timeline under it, zoomable, with a playhead you can drag.
32
- - **Tiny dependency surface** — only `mediabunny` (runtime) plus PixiJS (a peer dep). three.js is an *optional* peer, needed only if you import `pixi-effects/three`.
32
+ - **Tiny dependency surface** — only `mediabunny` (runtime) plus PixiJS (a peer dep). three.js is an *optional* peer, needed only if you import `pixi-effects/three`. mediabunny is fetched only when you export or use a video layer: a page that only plays never loads it.
33
33
 
34
34
  ## Install
35
35
 
@@ -49,8 +49,8 @@ Drop the imports into an [importmap](https://developer.mozilla.org/docs/Web/HTML
49
49
  "imports": {
50
50
  "pixi.js": "https://esm.sh/pixi.js@8.22.0?bundle-deps",
51
51
  "mediabunny": "https://esm.sh/mediabunny",
52
- "pixi-effects": "https://cdn.jsdelivr.net/npm/pixi-effects@0.47.5/dist/index.js",
53
- "pixi-effects/controller": "https://cdn.jsdelivr.net/npm/pixi-effects@0.47.5/dist/Controller.js"
52
+ "pixi-effects": "https://cdn.jsdelivr.net/npm/pixi-effects@0.48.1/dist/index.js",
53
+ "pixi-effects/controller": "https://cdn.jsdelivr.net/npm/pixi-effects@0.48.1/dist/Controller.js"
54
54
  }
55
55
  }
56
56
  </script>
@@ -61,7 +61,9 @@ Drop the imports into an [importmap](https://developer.mozilla.org/docs/Web/HTML
61
61
  </script>
62
62
  ```
63
63
 
64
- Load the `dist/` files **as they are** (jsDelivr's `/npm/…/dist/…`, or unpkg's `https://unpkg.com/pixi-effects@0.47.5/dist/index.js`) rather than a CDN-rebundled build such as `esm.sh/pixi-effects` or jsDelivr's `+esm`: the entries (`pixi-effects`, `…/controller`, `…/three`) share internal chunks, which only works when each file is served untouched.
64
+ The `mediabunny` line is needed only to export (the download button, `movie.render()`) or for a `video` layer; a page that only plays can leave it out and never fetches it (or call `useMediabunny(url)` instead, see [the API](docs/api.md#where-the-encoder-comes-from-usemediabunnysource)).
65
+
66
+ Load the `dist/` files **as they are** (jsDelivr's `/npm/…/dist/…`, or unpkg's `https://unpkg.com/pixi-effects@0.48.1/dist/index.js`) rather than a CDN-rebundled build such as `esm.sh/pixi-effects` or jsDelivr's `+esm`: the entries (`pixi-effects`, `…/controller`, `…/three`) share internal chunks, which only works when each file is served untouched.
65
67
 
66
68
  > **Using three.js?** Add two more entries (`three` and `pixi-effects/three`) to this importmap — see [Adding three.js](#adding-threejs-optional) below.
67
69
  >
@@ -78,7 +80,7 @@ Add two more entries to the importmap above: three.js itself, and the `pixi-effe
78
80
  "...": "(everything from the importmap above)",
79
81
  "three": "https://esm.sh/three@0.178.0",
80
82
  "three/addons/": "https://cdn.jsdelivr.net/npm/three@0.178.0/examples/jsm/",
81
- "pixi-effects/three": "https://cdn.jsdelivr.net/npm/pixi-effects@0.47.5/dist/three.js"
83
+ "pixi-effects/three": "https://cdn.jsdelivr.net/npm/pixi-effects@0.48.1/dist/three.js"
82
84
  }
83
85
  }
84
86
  </script>
@@ -59,9 +59,9 @@
59
59
  "imports": {
60
60
  "pixi.js": "https://cdn.jsdelivr.net/npm/pixi.js@8.22.0/dist/pixi.min.mjs",
61
61
  "mediabunny": "https://cdn.jsdelivr.net/npm/mediabunny@1.61.3/+esm",
62
- "pixi-effects": "https://cdn.jsdelivr.net/npm/pixi-effects@0.47.5/dist/index.js",
63
- "pixi-effects/controller": "https://cdn.jsdelivr.net/npm/pixi-effects@0.47.5/dist/Controller.js",
64
- "pixi-effects/present": "https://cdn.jsdelivr.net/npm/pixi-effects@0.47.5/dist/present.js"
62
+ "pixi-effects": "https://cdn.jsdelivr.net/npm/pixi-effects@0.48.1/dist/index.js",
63
+ "pixi-effects/controller": "https://cdn.jsdelivr.net/npm/pixi-effects@0.48.1/dist/Controller.js",
64
+ "pixi-effects/present": "https://cdn.jsdelivr.net/npm/pixi-effects@0.48.1/dist/present.js"
65
65
  }
66
66
  }
67
67
  </script>
@@ -0,0 +1,7 @@
1
+ export { CompositionSequence } from './chunk-AJWUCFGM.js';
2
+ import './chunk-L3MEZZAV.js';
3
+ import './chunk-JBDBICS2.js';
4
+ import './chunk-BFRWSV3R.js';
5
+ import './chunk-WGRWFQOB.js';
6
+ //# sourceMappingURL=Composition-BOLWGT2R.js.map
7
+ //# sourceMappingURL=Composition-BOLWGT2R.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":[],"names":[],"mappings":"","file":"Composition-ZCRJHBB5.js"}
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"Composition-BOLWGT2R.js"}
@@ -0,0 +1,16 @@
1
+ 'use strict';
2
+
3
+ var chunkM2LFQY2E_cjs = require('./chunk-M2LFQY2E.cjs');
4
+ require('./chunk-V3VBHSK6.cjs');
5
+ require('./chunk-WYR2AU4W.cjs');
6
+ require('./chunk-NGJXVJB7.cjs');
7
+ require('./chunk-DOLTCXCL.cjs');
8
+
9
+
10
+
11
+ Object.defineProperty(exports, "CompositionSequence", {
12
+ enumerable: true,
13
+ get: function () { return chunkM2LFQY2E_cjs.CompositionSequence; }
14
+ });
15
+ //# sourceMappingURL=Composition-ZZEOEETS.cjs.map
16
+ //# sourceMappingURL=Composition-ZZEOEETS.cjs.map
@@ -1 +1 @@
1
- {"version":3,"sources":[],"names":[],"mappings":"","file":"Composition-PMWLJQPI.cjs"}
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"Composition-ZZEOEETS.cjs"}
@@ -1,5 +1,6 @@
1
1
  'use strict';
2
2
 
3
+ var chunkVQXZ2NOI_cjs = require('./chunk-VQXZ2NOI.cjs');
3
4
  var chunkDOLTCXCL_cjs = require('./chunk-DOLTCXCL.cjs');
4
5
 
5
6
  // src/controller/css.ts
@@ -1098,6 +1099,8 @@ var Controller = class _Controller {
1098
1099
  this.hideTimer = null;
1099
1100
  }
1100
1101
  this.setVisible(true);
1102
+ chunkVQXZ2NOI_cjs.loadMediabunny().catch(() => {
1103
+ });
1101
1104
  } else {
1102
1105
  this.kickIdleTimer();
1103
1106
  }