Pre-Flight — WP-104 — 2026-11-28
Filled-in copy of docs/reference/pre-flight for WP-104. The verdict is at the bottom. The checklist is EC-015, and the execution prompt is session-WP-104-2026-11-28.
Nothing had been done before this session (checked 2026-11-28): no
wp-104branch locally or on the fork’sorigin, no fork PR mentioning WP-104, and no fork worktree. Every fact below comes from a command run in this session.
Header
- WP:
WP-104 - Title: TV app theme and branding
- Pre-flight date:
2026-11-28 - Signed against: public
main1ff7d87(with WP-104’s decisions, #272); forkorigin/scooby-engine50e43fc73579cf548b030099ac969dfc86e2de90. - Follows: the 2026-11-28 WP-104 decisions (D1–D7).
- Targets generation(s): N-A. No engine code changes.
- Targets disc(s): N-A. The device check uses the games already in the TV app’s library; no disc data is read or copied.
Pre-flight intent
Validating readiness for
WP-104. Not implementing, not building the reskin, not making art. Verdict only, plus the claim (the fork worktree), EC-015 and the execution prompt.
Dependency check
| Prereq | Status in WORK_INDEX |
Locked on | Notes |
|---|---|---|---|
| WP-085 | 🚧 In progress | — (identity injection merged 2026-11-27, 0d5a69c769) |
Bypass, Jeff’s call (below). WP-104 builds on WP-085’s build-time identity (99d611a9d8, milestone 1), which is verified on the TCL and merged. Only WP-085’s exit criterion 3, an import route without a computer, is open, and WP-104 doesn’t use import |
| WP-104 D1–D7 | Answered | 2026-11-28 | DECISIONS. D4 holds only if the test build proves the overlay |
Rule check and bypass. pre-flight.md says any prereq that isn’t ✅ makes the verdict NOT READY. WP-104 needs only the finished part of WP-085. Asked on 2026-11-28, Jeff answered “Note the bypass (Rec)”, as he did for WP-096. It’s recorded here; nothing else is bypassed.
Repo + device state
Repos:
- Public docs work is in the worktree
C:\claude-worktrees\scooby-engine-wp-104-preflight, branchdocs/wp-104-preflight, offorigin/main1ff7d87. - The claim (fork worktree).
tools\New-ForkWorktree.ps1 -Branch wp-104-tv-reskin→C:\claude-worktrees\scummvm-wp-104-tv-reskin, branchwp-104-tv-reskin, baseorigin/scooby-engine @ 50e43fc735. The branch is pushed toorigin(no commits of its own), so the claim shows there too. The base checkoutC:\dev\scummvmis clean (git status --porcelainempty) onscooby-engine. - No collision:
git branch -a --list '*104*'was empty in the fork before the claim, andgh pr list -R barefootbetters/scummvm --state all --search WP-104is empty. - The WP’s citations still hold.
git diff --stat 1604799960 50e43fc735 -- gui base dists/android backends/platform/android backends/graphics/android Makefile.common configure common/zip-set.cpp graphicsshows only WP-096’s twoadvanced/files.
Code facts checked at 50e43fc735 (execution relies on them):
| Fact | Where | Consequence for WP-104 |
|---|---|---|
initBackend() runs before the GUI manager is created |
base/main.cpp:579 and :652 |
A default the Android backend registers exists before the GUI starts |
GuiManager registers gui_theme = scummremastered unconditionally |
gui/gui-manager.cpp:88 |
It would overwrite a backend default. Scope 1.2 needs a guard: register only if (!ConfMan.hasDefault("gui_theme")) (common/config-manager.h:156) |
| The Android backend makes the grid the default | backends/platform/android/android.cpp:370 |
D7: remove that line. Upstream’s default, the list, then applies |
tvAppResDir is a second res.srcDirs in main |
dists/android/build.gradle:157-160 |
D4: move it to the debug and release source sets (:166-173), which take priority over main when resources merge |
| Build-type source sets already exist for the advanced mode | build.gradle:166-173 |
The overlay adds res and assets dirs there; it doesn’t restructure the file |
About’s text is assembled in buildLines(), the copyright and GPL blocks first |
gui/about.cpp:105-127, 221-222 |
Scope 1.5 prepends the header there and leaves the rest unchanged |
Theme zips are found through SearchMan and the theme path |
gui/ThemeEngine.cpp:2052-2066 |
A theme zip shipped as an app asset is listed with the built-in themes |
AndroidAssetArchive exposes the APK’s assets |
backends/platform/android/asset-archive.h:34 |
The backend can read a small defaults file from the assets (engineering call 2) |
Toolchain (WSL 2 Ubuntu, /opt/android-sdk; same as WP-096’s pre-flight,
re-proven today): the fork tip 55c8b6b32a was built in
/opt/build/wt/reskin-label (armeabi-v7a, --enable-engine=terraglyph,sky,
--with-png-prefix=/opt/build/png-v7a), packaged and installed on the TCL in
this session. aapt2 dump badging showed the injected label and banner.
Fonts: Raleway 4.026 (static TTFs, including Regular, Medium, SemiBold and
Bold) is installed in C:\Windows\Fonts; its name table carries “Copyright
2010 The Raleway Project Authors … Reserved Font Name”. The OFL 1.1 text
ScummVM already ships (LICENSES/COPYING.OFL) is the same license. Playfair
Display isn’t installed; Jeff approved downloading it at execution (Q3).
Art: none exists yet. There’s no art-masters folder on pCloud yet (its path is in the private requirements, R3);
the private identity folder holds only WP-085’s placeholder icon (192 px) and
banner (320×180). Jeff chose vector art from the studio mark (Q2). The
studio’s vector mark is in C:\pcloud\BB\brand\studio-logo\ (mark-*.svg,
plus Build-StudioLogo.ps1).
Device: the TCL 65Q77K
Captured 2026-11-28 with Windows adb (the TV is listed twice, so every
command was pinned with -s <serial>); the app’s id is replaced:
pm list packages → <app-id> org.scummvm.scummvm.debug
dumpsys package <app-id> → versionCode=26041005 versionName=2026.4.1-reskin.1
wm density → Physical density: 320
wm size → Physical size: 3840x2160 Override size: 1920x1080
df /data → 21523300 total, 16796460 KiB available (≈16.0 GiB)
scummvm.ini gui_* → gui_launcher_chooser=list (no gui_scale, no gui_theme)
- The next build is versionCode 26041006 or higher (WP-096 lesson 4).
- Baseline captured: the launcher in Remastered at scale ≈1.67: list capitals 13 px, rows 21 px on a 1080-line frame.
- Library to keep: Beneath a Steel Sky, Phantom of the Knight and Showdown in Ghost Town, and their saves.
Questions put to Jeff
Asked 2026-11-28, recommendation first. The answers are the labels Jeff picked.
| # | Question | Jeff’s answer |
|---|---|---|
| Q1 | WP-085 is 🚧 (only its import criterion is open), and WP-104 builds on its finished identity injection. How should the gate treat it? | “Note the bypass (Rec)” |
| Q2 | No WP-104 art exists. What does execution use for the must-have art? | “Vector from studio mark (Rec)”: built by hand in SVG from the studio’s footprint mark plus Playfair/Raleway type, per the art brief; no AI generation; Jeff reviews it, and an artist can replace any file later under the same name |
| Q3 | May execution download Playfair Display (SIL OFL 1.1) from the google/fonts GitHub repository? |
“Yes, download it (Rec)” |
Engineering calls (Claude’s, with reasoning)
- One overlay for resources and assets (D4).
tvAppResDirmoves to thedebugandreleasesource sets, and a new optional property,tvAppAssetsDir, adds an assets folder there too. The build-type sets overridemain, so a same-named file replaces ScummVM’s:scummvm_logo(the splash),colorPrimary/colorBackground, and the strings. Unset, nothing changes. This is the D4 test: if the merge refuses or ignores an override, execution stops and asks. - The theme and the defaults ship as app assets, not through the
Makefile. For Android,
tvAppAssetsDircarriestvapp.zip(the theme, idtvapp) andtvapp.ini. The backend readstvapp.inifrom the assets ininitBackend()and registers its keys as defaults:gui_theme,gui_scale, andapp_name. It’s brand-free code; the values live only in the private identity folder. This replaces the WP’s “extra-themes make variable” and “build-time default theme” (scope 1.1 and 1.2) for Android without widening scope. The Windows hook goes with D5. The theme id and file name are neutral (tvapp, matchingtvapp_icon/tvapp_banner), so nothing branded shows in build logs. gui-manager.cpp:88gets ahasDefaultguard (the code fact above). That’s the only change outside Android to make a build-provided theme the default.- D7 is one deleted line (
android.cpp:370). The fork returns to upstream’s list default. A player’s choice is still saved inscummvm.ini. - About (scope 1.5): if the assets hold
tvapp-about.txt,buildLines()adds its lines, then a blank line, before ScummVM’s version, copyright, GPL and credits. Those are unchanged and stay (D6). - Player-facing strings (scope 1.6, D6): where a TV-path string names
ScummVM (launcher buttons and tooltips, the in-game menu, the add-game
errors), the code uses
ConfMan.get("app_name")when it’s set, and the existing string when it isn’t. The set strings are new message ids, so they show in English until translated; plain builds keep today’s translations. The list of strings goes in the WP’s §Result. - Art is vector, by hand (Q2): logos, wordmark, banner, icon layers and
splash are SVG built from
mark-*.svgwith Playfair Display and Raleway, then exported to PNG at the asset list’s sizes with Inkscape’s CLI (installed: Inkscape 1.4.3,C:\Program Files\Inkscape\bin\inkscape.com). No image generator is used for anything in this WP.
Scope lock
Anything not listed is forbidden.
Fork (C:\claude-worktrees\scummvm-wp-104-tv-reskin, branch
wp-104-tv-reskin):
dists/android/build.gradle (the overlay and tvAppAssetsDir)
backends/platform/android/android.cpp (tvapp.ini defaults; remove the grid default)
backends/platform/android/android.h (only if a declaration is needed)
gui/gui-manager.cpp (the hasDefault guard)
gui/about.cpp (the optional header)
gui/launcher.cpp (app_name in TV-path strings)
engines/dialogs.cpp (app_name in the in-game menu's strings)
Public docs repo (barefootbetters/terraglyph-engine):
docs/work-packets/WP-104-tv-reskin-theme-branding.md
docs/execution-checklists/EC-015-tv-reskin-theme-branding.md
docs/reference/pre-flight-WP-104-2026-11-28.md (§Lessons learned only)
docs/reference/scummvm-smart-tv.md (only the tvAppAssetsDir property, if the build steps need it)
docs/work-packets/WORK_INDEX.md (the WP-104 row and the Last updated line)
Private repo (barefootbetters/scooby-engine-private):
private/tv-app-identity/** (res/, assets/ with tvapp.zip, tvapp.ini, tvapp-about.txt; theme/ source; README; template)
private/tv-reskin-*.md (status notes only)
Local, not in any repo: art masters and the Playfair download in
the art-masters folder on pCloud (private requirements, R3); the WSL copy in /opt/build/tv-app-identity/;
/root/.gradle/gradle.properties (adding tvAppAssetsDir); build trees under
/opt/build/wt/.
Forbidden (any change fails the WP):
engines/terraglyph/**,backends/platform/android/advanced*/**,gui/themes/**(ScummVM’s own themes),po/**,common/**,base/**.- Any branded file or value in the fork or a public file: the app name, the package id, logos, icons, the banner, the theme, the strings’ values (WP-085 Q1, the 2026-11-26 naming decision).
- Removing or rewording ScummVM’s copyright, GPL text or credits in About, or any license file (D6).
- Image-generator output anywhere in this WP (Q2).
- Game data, signing keys, credentials.
- Uninstalling the TV app or clearing its data (the library and saves stay).
Exit check (before every commit):
git diff --cached --name-only # each repo; match the lists above
git diff origin/scooby-engine..HEAD --name-only # the fork branch, before the PR
Also grep every staged fork and public diff for the private identity values
(the app name, its distinctive word, the package id). Any hit is a leak: git restore --staged and remove it.
Risk review
| Risk | Likelihood | Impact | Mitigation |
|---|---|---|---|
The overlay doesn’t override (duplicate-resource error, or main wins) |
med | med | It’s the D4 test, run first (EC-015 Step 2) with one resource of each kind. On failure, stop and ask Jeff; never rename resources in the fork |
tvapp.ini isn’t readable from the assets in initBackend() |
med | med | Read it through AndroidAssetArchive and log what was registered. Fallback: Java reads the asset and passes the values through the existing start-up arguments. Either way it’s checked on the TV with a log line |
The theme fails to parse, and ScummVM silently falls back to builtin |
med | med | Check logcat for ThemeParser / “falling back to builtin” after every theme change; load the theme on Windows with --themepath first |
| A branded value leaks into the fork or a public file | low | high | The grep exit check; the theme is named tvapp; values live only in the private folder |
| The About attribution is lost or moved below the fold | low | high | Exit criterion 6, with a capture of the whole About scroll |
| New message ids leave some languages in English | high | low | Expected and accepted for the TV path (English first); plain builds unchanged. Listed in §Result |
| Raleway renders poorly at small sizes, or a glyph is missing | low | med | Exit criterion 5 (a non-Latin language through Noto) and the 3 m check |
| An install downgrades or wipes the TV app | low | high | versionCode ≥ 26041006; adb install -r only; never -d, never uninstall |
| Another session tests on the same TV | med | low | Check dumpsys package before each install; the fork tip is a superset of merged work |
| Device evidence claimed without a capture (the 2026-11-21 lesson) | low | high | No EC-015 box is checked without a screenshot, logcat excerpt or command output; Jeff’s 3 m judgement is quoted as his |
Verdict
- READY TO EXECUTE. Every section above carries concrete content. The claim is made. The code facts, toolchain, fonts and device state are checked. Q1–Q3 are answered, and the one rule bypass (WP-085’s 🚧) is Jeff’s and is recorded.
- NOT READY
Carried forward: the TV’s safe area (G6 in the private requirements) is still unmeasured; EC-015 Step 5 measures it. D4 is conditional by Jeff’s decision, and EC-015 Step 2 is its test.
Reviewer: Claude (Opus 5.5), pre-flight for Jeff Date: 2026-11-28
A READY verdict authorizes opening the execution session. It doesn’t
authorize any change beyond the §Scope lock. It goes stale if public main
or origin/scooby-engine moves in a way that touches WP-104, EC-015, gui/,
dists/android/ or backends/platform/android/
(wp-lifecycle §Phase 2).
After execution: lessons learned
Execution 2026-11-28 (WP-104 §Result).
- Check the build’s features, not just the code paths. The pre-flight
checked where theme TTFs are found but not that the Android build had
FreeType. It didn’t (
#undef USE_FREETYPE2), so Raleway and the Noto fallbacks were dead until FreeType was added to the build machine. For a theme or font packet, readconfig.hof the build tree. - A registered default isn’t a key.
ConfMan.hasKey()ignores defaults, so engineering call 2’sgui_scaledid nothing untilgui-manager.cppalso checkedhasDefault(). Grep the consumers of every key a default is meant to drive. - Asset location matters on Android. Files under
assets/assets/are extracted only whenMD5SUMSchanges, andMD5SUMSdoesn’t cover an overlay, so packaged assets go at the root and are read from the APK. - “Shows on the TV” claims need the TV’s Android version. Android 14
draws no legacy splash, so the splash part of D4’s test could not pass on
this device for reasons unrelated to the overlay. The device check proved
the overlay with
aapt2; the splash itself is open. adbinput isn’t the remote. Injected arrows (D-pad, keyboard and gamepad sources) move ScummVM’s pointer, not the list selection, so criterion 10’s arrows need the physical remote.- Scale and safe area are one budget. At the TV scale the stock layouts overflow: the launcher’s button column, the centred 750×550 options and the save/load inset all needed theme changes, each measured from a capture.