Textures: Linear/Nearest labels; Shaders: filter pass measured, not assumed (#68); 723 checks

admin committed 2026-09-13 12:53:23 +02:00
1 parent 7af660262a
commit 7debb2370a
3 files changed
+8 -5

No files matched your search

+2 -2
@@ -12,7 +12,7 @@ npm run check # typecheck + lint + format:check + tests, the gate CI runs
# code is lost (tail's is reported), so a red run reads as green
npm run build # writes dist/ and regenerates index.html
./build.sh # the same under `set -o pipefail`, for callers that pipe the output
node tools/seed-e2e.mjs && node tools/e2e.mjs # 720 editor checks, screenshots in /tmp/gm-e2e-*.png
node tools/seed-e2e.mjs && node tools/e2e.mjs # 723 editor checks, screenshots in /tmp/gm-e2e-*.png
GM_STEPS=20 node tools/e2e.mjs # or 1-12, or 6,20 — a subset while working on one step
./e2e.sh start [GM_STEPS] # the same run detached, see below
./e2e.sh status # live progress, or the last run's result
@@ -150,4 +150,4 @@ widths to find click points. The **render device is not in this repo** — `/dev
and a 1 GB `/dev/shm` come from `container.options` in the runner's own `config.yaml`, which
applies to every job on that runner. Without them chromium falls back to llvmpipe, which gets
WebGL 1.0 only. Measured in the job container: `ANGLE (Intel, Vulkan 1.3.230, HD Graphics 630)`,
WebGL 2.0, and the same 720 checks as here.
WebGL 2.0, and the same 723 checks as here.
+4 -1
@@ -81,7 +81,10 @@ deviations while their shader is not worn.
A shader is a Pixi filter: the sprite is rendered into an intermediate texture and drawn back with
the fragment, one pass per sprite wearing one. Fine for dozens, not for thousands. The pass runs at
screen resolution, so pixel art stays sharp. Only sprites wear shaders; text objects do not. The
screen resolution, so pixel art stays sharp: measured in play at a fractional camera scale (1.43
screen pixels per world unit), a *Nearest* texture keeps its hard border pixel for pixel with a
neutral shader on, and brightness 0.5 darkens every one of those pixels — the pass runs there, and
it does not resample. Only sprites wear shaders; text objects do not. The
node set is deliberately small — no channel split, no texture sampling at other coordinates, no
time input; each is one node in `src/core/shader/nodes.ts` (a `ShaderNodeDef` with an `emit`) and
one row in the table above.
+2 -2
@@ -29,8 +29,8 @@ nothing on disk is removed. The price is that files outlive the projects that re
picture becomes ten differently coloured coins, per instance, for nothing. Without a texture
`color` is simply the fill of the box, as before.
**`filter`** is the texture's only property: *Smooth* (default) or *Pixel art*, which is the
difference between crisp and mush when a small image is scaled up. Switching it needs a
**`filter`** is the texture's only property: *Linear* (default) or *Nearest*, which is the
difference between mush and crisp when a small image is scaled up. Switching it needs a
`style.update()` on the texture source, not just the assignment: Pixi's `scaleMode` setter
writes the filters but leaves the style's cached resource id in place, and that id is the key
the GPU sampler is looked up under — so without it the picture only changes on a reload.