Files
hyperframes/registry/blocks/godrays/source/README.md
Miguel Ángel 63a7ec692f feat(registry): eight more WebGPU shader backgrounds and a bundle with thirty new shaders (#5191)
* feat(registry): eight more WebGPU shader backgrounds and a bundle with thirty new shaders

* refactor(registry): simpler bundle copy step in the shader build

* test(registry): every shader block ships the same bundle and names a shader in it

* refactor(registry): one block loader for the shader block tests

* test(registry): name the stale block and match only shader names

* chore(registry): shorter licence line at the top of the shader bundle

* test(registry): every shader block installs the bundle's licences
2026-10-09 08:52:03 +00:00

22 lines
888 B
Markdown

# Source for lib/shaders.iife.js
One bundle drives every shader block (each lists `lib/shaders.iife.js` in its registry-item.json).
Each installs it into the project's shared compositions/lib folder, and the canvas's `data-shader`
attribute picks the shader.
- `driver.js` renders the canvas from HyperFrames time: on every `hf-seek` it steps the library's
clock to that exact time, so preview and render draw the same frame.
- `build.mjs` bundles the driver with `shaders@4.0.0` and only the shaders it lists, then copies the
result and its licence file into each shader block's `lib/`. A new block lists both lib files in its
registry-item.json, like godrays, and adds its shader to that list; the build fills its `lib/`.
## Build
```sh
npm ci
npm run build
```
`package-lock.json` pins every bundled package; their licenses are in
`../lib/shaders.THIRD-PARTY-LICENSES.txt`.