Commit Graph
7 Commits
Author SHA1 Message Date
Brian Degenhardt 1daeee29d5 SDL: report argument errors on stderr instead of into the void
ParseCommandLineArgs reported bad arguments through Console.Error*, but argument
parsing runs before the console and file log sinks exist, so the message reached
neither the terminal nor emulog.txt. An unrecognised flag exited silently with
no diagnostic anywhere, which reads as a crash.

Write them to stderr, as --help in the same function already does. The unknown-
argument case also names the trap it exists to catch: this frontend takes none
of the Qt frontend's flags, so -fullscreen or -bigpicture land here, and both
are things it already does unprompted.
2026-07-25 17:10:09 -07:00
J1coding 80feae5f31 iOS: route RetroAchievements through native UI instead of ImGui FullscreenUI
The iOS app renders its own SwiftUI UI, so the shared core's ImGui
FullscreenUI overlay never appears on screen. Before this change every
RetroAchievements event still initialized FullscreenUI and posted the
notification through it, adding per-frame render work for an overlay that
is invisible on iOS, and the native toast layer never saw the events at all.

Add two Host callbacks so a platform can take over notification rendering:

  bool Host::HasNativeAchievementNotifications()
  void Host::OnAchievementNotification(key, duration, title, message, badge_path)

When HasNativeAchievementNotifications() is true the shared core hands each
RA event (unlocks, mastery, leaderboard start/submit/scoreboard,
login, connect/disconnect, summary) to OnAchievementNotification and skips
ImGuiManager::InitializeFullscreenUI() entirely — in BeginLoadingScreen,
ClientLoadGameCallback, DisplayHardcoreDeferredMessage, and
SetHardcoreMode — so the invisible overlay and its render loop stay down.
The existing ImGui path is unchanged for desktop/Android, which return
false from the new callback. Every frontend (eerunner, gsrunner, libretro,
sdl, qt, android, test stub, macOS stubs) gets a no-op implementation; iOS
provides the real one, posting the notification to its SwiftUI toast layer
through ARMSX2_PostRetroAchievementsNotification. The notification now also
carries the configured display duration.

Also flesh out Achievements::GetCurrentUserStats / GetCurrentGameStats /
GetCurrentAchievementList, which were previously unimplemented stubs
returning false. The iOS bridge already wired these up to the
RetroAchievements panel; they now return the logged-in user's score, the
active game's unlock progress, and a bucket-ordered achievement list so the
native panel has real data instead of an empty state.

Stray RetroAchievements debug fprintf spam in the iOS bridge and overlay
defaults is dropped.
2026-07-24 12:15:28 +02:00
Brian Degenhardt 0b4d0bd03d sdl: fall back to a Wayland Vulkan surface when a compositor is present
The SDL frontend previously only ever reported WindowInfo::Type::VulkanDirect
and relied on VK_KHR_display to acquire the display. That fails when the
frontend is launched inside a Wayland session, where a compositor owns the
display (desktop, phone, or an embedded gamescope-style compositor).

BuildWindowInfo() now checks WAYLAND_DISPLAY: when set, it brings up an SDL3
SDL_WINDOW_VULKAN window on the wayland video driver and hands its wl_display /
wl_surface to the Vulkan backend as a Type::Wayland surface (the backend's
vkCreateWaylandSurfaceKHR path already existed). Any failure logs a warning and
falls through to the existing VK_KHR_display path, so bare kmsdrm devices are
unaffected. The whole block is gated on WAYLAND_API.

Enable WAYLAND_API in the clang-handheld preset so this path compiles. Pure
kmsdrm targets without the ECM / Wayland-Egl headers can still build
VulkanDirect-only via -DWAYLAND_API=OFF.
2026-07-23 08:45:47 -07:00
Brian Degenhardt fabccaa4fb libretro: rebrand core to armsx2_libretro, wire libretro+SDL CI into build-all
Rename the imported yaps2 libretro core (output .so, .info, core-option
prefixes, ini name, Vulkan app/engine identity) to ARMSX2. The core is
still gated behind ENABLE_LIBRETRO (default OFF) and needs X11_API=OFF
WAYLAND_API=OFF (headless Vulkan-context-negotiation build, same as the
CI job). Exports remain retro_* only via link.T.

The yaps2 nightly_release.yml is dropped — ARMSX2 has its own release
process — and the reusable libretro/SDL build workflows are instead
invoked from build-all.yml, so PR runs cover them. armsx2-sdl keeps the
kmsdrm handheld frontend buildable for Rocknix-style downstreams.
2026-07-19 10:37:07 -07:00
Brian DegenhardtandClaude Opus 4.8 85b1c522ed CMake: bundle resources with the SDL frontend like the Qt build
Only pcsx2-qt called setup_main_executable(), which POST_BUILD-copies
bin/resources/* (GameDB, shaders, fonts, icons, sounds) + docs next to
the binary and installs them under PACKAGE_MODE. pcsx2-sdl never did, so
the handheld build produced a bare binary and bailed at startup with
"Resources directory is missing." (EmuFolders::SetResourcesDirectory
looks for AppRoot/resources).

Extract the resource/docs copy loop into a reusable
pcsx2_copy_runtime_resources() helper, call it from both frontends, and
add the matching PACKAGE_MODE resources install to pcsx2-sdl.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-13 19:00:55 -07:00
Brian DegenhardtandClaude Opus 4.8 5bb52bef60 build: emit yaps2-qt / yaps2-sdl binaries for the fork
Rename the two shipped application frontends' output files from pcsx2-qt / pcsx2-sdl to yaps2-qt / yaps2-sdl via OUTPUT_NAME. The CMake target names are unchanged, so the build graph, install() rules and ctest references keep working; only the produced binary file name changes.

Also repoint the Linux packaging that launches the app at the new name: the .desktop Exec, the AppImage BINARY/--executable, and the Flatpak command. The desktop app-id (net.pcsx2.PCSX2), window class, config dir (~/.config/PCSX2) and the dev/test runners are intentionally left as-is; a full display-name/app-id rebrand is a separate change.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-03 15:36:51 -07:00
ff1abc36b8 arm64: SDL/kmsdrm frontend, headless runners, and handheld defaults (fork-only)
pcsx2-sdl (SDL3/kmsdrm handheld frontend), pcsx2-eerunner / pcsx2-vurunner headless
JIT regression+divergence tools, the gsrunner libmali CLI flags + Wayland scanner
wiring, and the heterogeneous-CPU thread-pinning default. Fork-only tooling/frontends.

Co-Authored-By: Ryan Walklin <ryan@testtoast.com>
Co-Authored-By: Brian Degenhardt <bmd@bmdhacks.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-20 20:27:56 -07:00