gamescope: hide the boot splash on the first mapped window, as X11 does (payload 20261023.3)

Merged
UT
18d ago
+44-22

Description

Both display servers now hide the "Launching game" splash by the same rule, and nothing blue is shown in between.

Under X11 the splash hides on the first mapped window and the user sees black until the game's first frame, because the renderers never draw explorer. Under gamescope the splash instead waited for a game-window note from the shim's present path or from gamescope's commit-rate scan, because an early hide showed Wine's blue desktop wallpaper and taskbar, which gamescope composites. That gate kept the splash up long after there was something to show: on a Poco F6, Balatro hid 16 s later than under X11 and L.A. Noire loaded for 25 s behind it.

Two changes:

  • Game sessions get a black desktop background with no wallpaper and explorer's shell turned off for the "shell" desktop (EnableShell=0, ShowSystray=0), via WineThemeManager.gameSessionTheme and the enableShell flag of apply, applied in setupWineSystemFiles for launches that are not bootToContainer. The container's light/dark theme is kept. This is a no-op under X11 (explorer is never drawn there) and removes the blue and the taskbar under gamescope. "Open container" keeps the user's theme and taskbar.
  • Payload 20261023.3 (re-uploaded with the final content, same number since nothing of this is on master yet): gamescope A43 reworked to send the game-window note on the first top-level X map, like the X11 rule, with a once-a-second resend (GameNative/gamescope#6); the shim without its own game-window report (GameNative/gamenative-drm#12) on top of the device-gated proc lookup (GameNative/gamenative-drm#11). The archive is live on both CDN URLs.
  • libgamenative_drm.so in jniLibs is the daemon from gamenative-drm#12: it clears the splash as soon as the note arrives instead of on the next published frame.
  • The gamescope_system_libs links to the system libcrypto.so (#2223) and libjpeg.so (#2225) are dropped. They only existed because libgndrm_shim.so linked libandroid.so and its OEM deps resolved against imagefs's same-named libs; the shim no longer links libandroid (gamenative-drm#9, #2228), so the gamescope LD_LIBRARY_PATH now starts at gamescope/lib. Verified on the Poco F6 (HyperOS, the libjpeg case): gamescope and Xwayland start with no link errors and both test games render.
  • New containers default to gamescope only when the GL renderer is Adreno, X11 otherwise (Container.defaultDisplayServer, resolved once in setContainerDefaults from the cached renderer string). Adreno 735/750/830/840 are verified; Mali-G710 works but a Mali-G68 (Exynos 1380) cannot create gamescope's compute pipelines, and Xclipse/PowerVR are untested. Existing containers, known configs, the per-container setting and an explicit global preference are unchanged.

For a local test without the CDN the same change plus the payload as an APK asset is pushed on joshuatam/GameNative fix/gamescope-build-14 (PR #2226), as gamescope-gamenative-20261023-14.tzst.

Recording

Poco F6 (HyperOS, Adreno 735), 1 Hz screenshots classified by dominant colour, before and after:

Game (gamescope)Splash hidden, before → afterBetween splash and first frameFirst game frame
Balatro (GL through X, zink)+29.2 s → +20.6 sblack+32 s → +28 s
Blazing Chrome (32-bit, Vulkan)+24.3 s → +12.7 sblack, no taskbar+26 s → +26 s
L.A. Noire (64-bit, long load)+85.1 s → +21.7 sblack, loading screen visiblenot reached in 90 s → +52 s

Balatro under X11 is unchanged (black between splash and first frame). No blue frame in any run. The splash hides within 20 ms of xwm: first top-level map 0x400002: game window note sent (1/3). With the shell off, Blazing Chrome's gap no longer shows Wine's taskbar at the bottom (it was there from t16 to t27 before). The first gamescope launch of this build downloaded and installed the payload itself (3 s on the Poco's Wi-Fi). Final build of this branch, same device: Balatro +19.84 s note, +19.86 s hidden; Blazing Chrome +12.63 s, +12.66 s; Balatro X11 +12.83 s with a black gap as before. "Open container" still boots the Wine file manager on the blue wallpaper with the Start taskbar, and the next Play of the same container writes the black background and the shell-off values back before launching.

Type of Change

  • Bug fix
  • Performance / stability improvement
  • Compatibility improvements
  • Other (requires prior approval)

Checklist

  • If I have access to #code-changes, I have discussed this change there and it has been green-lighted. If I do not have access, I have still provided clear context in this PR. If I skip both, I accept that this change may face delays in review, may not be reviewed at all, or may be closed.
  • This change aligns with the current project scope (core functionality, stability, or performance). If not, it has been explicitly approved beforehand.
  • I have attached a recording of the change.
  • I have read and agree to the contribution guidelines in CONTRIBUTING.md.

Summary by CodeRabbit

  • Improvements
    • Game sessions retain the selected light or dark theme while using a black background.
    • Wine’s desktop shell and system tray are configured according to the session type.
    • Container boots continue to use the configured desktop theme.
    • The default display server is now selected based on the device’s graphics renderer: Gamescope for Adreno and X11 otherwise.