| Commit message (Collapse) | Author | Age |
| |
|
|
|
|
|
|
| |
copies, identical to their sources, go, and so does the label saying which was used
shaders/prebuilt/*.glsl were byte-identical to shaders/X.glsl or to prefix.glsl + post/X.glsl (checked with cmp, all 14), kept only so a -Dprebuilt-shaders build could name them; EffectCode and Config then labelled the GUI's shader source as live or prebuilt. The GUI embeds shaderSource (a concatenation, no glslc) either way now; the prebuilt SPIR-V stays, and zig build shaders refreshes only it. Config's report and EffectCode lose their GUI shader source line.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Three bundled Shadertoy passes beside Crt, each `Bloom|Vignette|Grain
0..3` (off by default, nothing drawn while off), in shaders/post/:
- Bloom: what is brighter than the page (a channel's linear peak over
0.75/0.7/0.6 and over the page's own + 0.15, so a light page does not
bloom) glows, 2/3.5/5% (§8.2's budget). The glow is a dual Kawase blur
in RGBA16F textures at half size and down, 3/4/5 steps by level
(shaders/bloom-down, bloom-up; Post.bloomChain), composited in linear
light and dithered.
- Vignette: round, from halfway to a corner, 10/18/28% at the far corners,
in linear light, dithered.
- Grain: a still, triangular-spread grain of 1.5/3/5 of 255 on
page-coloured pixels only, a logical pixel big; still, so it asks for no
frames.
Focus rule: the shell passes every bundled pass the rectangles of the tags
with their grips, the column and workspace tags, the notices and the
cursor (pardesSpare, at most 32, neighbours on one row merged), and a
bundled pass leaves them as they are; and a per-theme ceiling (pardesCap,
Post.capsOf) keeps the page's text and the selection's text at min(their
contrast, 4.5) under each pass at its strongest. User files get no
ceiling and no spared rectangles.
Fix found on the way: SDL GPU binds at most 4 KiB of a uniform block, so
every Shadertoy colour after iPalette (iBackgroundColor, iForegroundColor,
the cursor and selection colours, iPalette[>=4]) read zero. The prefix's
block is cut in three (Globals, Palette, Colors) with ghostty's names and
order, each pushed as a slice of the one struct; pardes's own block moves
to binding 3.
Tests: the caps hold over every native theme; each uniform slice fits
4 KiB; the prefix's members in ghostty's order across its blocks.
Gates: tty/gui unit-test and core-test pass; snap fails only
nested-optout; GUI goldens 01-08 byte-identical (09-18 wait on
wkzlsqvy, as in somtrmsz); web builds. Feel review material:
.scratch/render/{bloom,vignette,grain}/ (levels on forge, dusk, acme,
crops, a levels mp4).
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
separators and focus tints
Density: dp() in gui.zig draws every size given in pixels in logical
pixels (SDL's window display scale, rounded, at least one), as acme scales
Border, ButtonBorder and Scrollgap: the rules (rule_px), the tag rule, the
grip's ring, its dirty gap and mode bars, the rail's gap to the text and
its minimum, the thumb's inset, the rim, a bar cursor's minimum width,
underline and strikethrough thickness (the atlas is dropped on a scale
change), the rule-grab margin, and the Crt's scanline and mask periods
(pardesScale in the post prefix). Cell- and tagline-measured sizes stay:
the rail's width, Lift's blur and offsets, every motion; iResolution,
fragCoord and iMouse stay in the display's pixels, as ghostty's.
PARDES_TEST_SCALE forces a density in a harness (a test window is 1x
otherwise, whatever display it lands on) and sizes the test font with it.
Colours: a separator that stands off its page by less than 1.5:1 is lifted
toward the text to 1.6:1 (helix, atelier, paper; a theme with no page,
dark, is judged against #121212), and empty_col follows it. forge's own
rule already stands at 3.83:1; what hid it was density: 2 device pixels
on a 3x screen, now 6 (dp). A focused tag's tint closer than 1.5:1 to the
plain tag on a dark page (1.25:1 on a light one) is pushed further the way
it leans, as far as its text keeps its own contrast or 4.5: forge
1.23 -> 1.51 (#2d3440 -> #374253), and likewise dusk, orchard, ink,
lagoon, clay, harvest, spectrum, solarium, forge_soft; daybreak, atelier,
paper to 1.25. dark and helix gain a tint of their own (dark: #484566
under #c8c8c8, 1.54:1; helix: ramp 237 under 250, 1.65:1).
Tag caret: past a full row's end, the G3 glide box sits on the tag's right
edge, where the layer's caret and the pixel shell's are.
Tests: every native theme's separator >= 1.5 and every dark one has a
tint >= 1.25 with readable text; forge keeps its own border; the tag caret
glide box at a full row; at 2x the spine, tag rule, ring, rail start and
gap, and bar cursor double. Legacy-ThemeFile test strips helix's new pair.
Goldens: snapshot goldens change in colour rows only, the tints (orchard
#283a2f -> #314738 at boot, forge, helix and dark in theme/themesel).
GUI goldens: the harness's single Del of the renamed wide pane is refused
since ysqnkyoy (a rename counted as unsaved; fixed on the 9P line in
wkzlsqvy), so scenes 09-17 were recorded with that pane open and the file
was stale since the merge (08 and 18 also moved with ykvnltvs's full-row
tag wrap). The goldens here were recorded with that pane closed (as
wkzlsqvy will close it); against the parent's binary under the same
conditions they differ only in the tints: 01-13 forge's (#2d3440 ->
#374253, and the glyph edges on it), 14 ink's; 15-18 are byte-identical.
Until wkzlsqvy is merged, a run here fails 09-17. Each commit reproduces its own
recorded goldens on this machine (checked at kvtmqkyn). A test window is
1x unless PARDES_TEST_SCALE says otherwise, whatever display it opens on.
Prebuilt shaders refreshed from their sources.
Captures: .scratch/render/dark-borders/{before,after,compare,scale2,scale3}.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Coordinator's request: `Crt 0..3` (likewise Ripple, Glitch), 0 off, `on`
the default level 2 (the polished rewrite), `off` and a bare word as
before. The level is one uniform (pardesLevel, beside pardesOpaque in the
prefix's own block); each pass picks its constants by it. Level 3 is at
least as strong as the old effects, measured as pixels changed by more
than 8 in a channel against a plain frame: Crt 18.3% (old 17.4%), Ripple
11.1% (9.5%), Glitch 9.3% a frame (8.1%); Glitch's level raises how often
it bursts as well as how hard. Config and ctl report `Crt 2` / `Crt off`.
Shared files touched: ninep/ctl.zig (the report line). Not touched:
pardes.zig, Messages.zig, mouse.zig, gui.zig, detached/*.
|
|
|
rewritten as Shadertoy files
Stage 9 of docs/render-pipeline.md. src/gui/Post.zig runs the chain over
the finished frame: each pass reads the one before, ping-pong textures
between, the last writes the window; an empty chain is the direct path.
The prefix (shaders/post/prefix.glsl) is ghostty's uniform block, name
for name and offset for offset (tested against a copy of its Uniforms, the
selection colours by their GLSL names), at SDL GPU's bindings, y down.
A user's file (Shader <path>) is compiled by glslc with compileGlsl's own
flags on a thread of its own, taken in at the next loop step; errors name
the file's own lines; a failed compile keeps the last good pipeline;
glslc missing is said once. The bundled passes compile with the build,
through the same prefix.
Crt, Ripple and Glitch are Shadertoy files, rewritten: no barrel (input is
identity, tested), everything in linear light and dithered, keyed to iTime.
scene_effects, crt.zig and crt.frag.glsl are gone; the core keeps no clock
for the chain. ShaderAnimation off|on|always drives redraw level A: the
chain alone over the retained frame (34 us CPU a redraw, measured).
Shared files touched: pardes.zig (nextWake loses the scene line,
disableSceneEffects empties the chain, two tests), builtins.zig (one switch
arm), ninep/ctl.zig (two switch arms), macos.zig (flags from the chain),
gui.zig. Not touched: Messages.zig, mouse.zig, detached/*, host_io, tty.
|