Skip to content

Reduce moving-background shimmer in Godot terminal games - #41

Draft
nicodes wants to merge 5 commits into
mainfrom
perf/godot-terminal-pacing
Draft

nicodes wants to merge 5 commits into
mainfrom
perf/godot-terminal-pacing

Conversation

@nicodes

@nicodes nicodes commented Oct 11, 2026 •

Copy link
Copy Markdown
Member

Moving Godot backgrounds shimmer on small terminal grids because the previous low-resolution render and bilinear reduction undersample fine detail. Default smooth sampling renders at up to twice the previous scale, capped at the authored viewport size, then uses Godot's mipmap-based trilinear reduction. The game keeps its camera, logical coordinates, physics and native text overlays. Honeyvale needs no source changes.

TERMCADE_GODOT_SAMPLING=fast retains the cheaper previous sampling; smooth or unset selects the new default. Fine detail is softer, and rendering costs more. No temporal blur, camera snapping or game-specific adjustments are introduced. Existing packages require re-exporting.

A real exported fixture pans a camera diagonally over high-frequency detail. After four settling frames, 24 measured frames show mean per-pixel brightness change falling from 82.12 to 2.16; the regression requires at least 75% reduction. Honeyvale's warmed diagonal replay at 96×28 quadrant cells measured 4.74 ms fast versus 6.68 ms smooth exchange; at 160×45 smooth exchange measured 11.75 ms plus 2.49 ms terminal composition. Measurements exclude startup and emulator paint.

Validation: full local Make shipping gates and refined camera-pan race test; owned Honeyvale PTY with readable Play/HUD/bag controls and clean exit; five-platform archives and actual exported engine/CLI tests. Canonical docs retain immutable measurements and source hashes.

This draft includes and supersedes the earlier unmerged Godot exporter/native-text draft #40. The experimental Linux native runtime requires trusted games, Godot 4.7.2, Xvfb and Mesa. No marketplace adoption, release, merge or deployment is included.


View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need. Autofix is disabled.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant