PR #10 split: native macOS backend (Metal/CoreAudio/GameController) — PENDING - #13
Closed
mstan wants to merge 3 commits into
Closed
PR #10 split: native macOS backend (Metal/CoreAudio/GameController) — PENDING#13mstan wants to merge 3 commits into
mstan wants to merge 3 commits into
Conversation
Broken out of PR #10 (navjack). Vendors the Dear ImGui core (1.92.9 WIP, core + SDL2/OpenGL3 backends only — demo/examples/docs not imported) under third_party/imgui and replaces snesrecomp_target_launcher_ng() with a local mmx_target_launcher_ng() that builds the engine's launcher C sources against this repo's ImGui copy. The engine launcher bundles 1.91.9b; platform UI backends added on top of this (Metal, SDL_Renderer2) need the newer API, and linking both copies would create duplicate symbols. Also sets CXX/C++17 on the CMake project, which the vendored backends need. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Broken out of PR #10 (navjack). Adds src/linux_ui.{cpp,h}: a Dear ImGui overlay for the Linux/Steam Deck runtime with F1 toggle, widescreen enable/active status, and save/load-state slot controls. Renders through either the SDL_Renderer2 or OpenGL3 ImGui backend to match the active output method; keyboard focus is captured while the menu is open. Stacked on pr10/widescreen (MmxDisplay_* API) and the vendored ImGui commit (backends). Note for review: F1 collides with the default LoadState slot-1 binding; on Linux the menu toggle now wins. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Broken out of PR #10 (navjack). Adds a native macOS runtime: - src/macos_backend.{h,m}: Metal presenter (implements RendererFuncs incl. GetOutputSize), Core Audio output paced by the negotiated device format, GameController.framework gamepad polling with Steam Deck fallback - src/macos_ui.mm: F1 ImGui menu (widescreen toggle, NTSC CRT display options, save/load states) via the vendored imgui_impl_metal backend - third_party/ntsc-crt (crt_core/crt_snes + LICENSE/README only; test image zip and unrelated console variants not imported) - config: Metal output method (Apple-only enum entry), Metal default on Apple; main.c APPLE paths replace SDL audio/gamecontroller init - CMake: OBJCXX, Apple frameworks, MACOSX_BUNDLE packaging with resources/Info.plist + assets/MegaManX.icns NOT imported from the PR: prebuilt MegaManX.app payload (binaries, libSDL2 dylib) and the MegaManXSNESRecomp-steamdeck-x86_64 binary payload — releases should never commit build artifacts. Note for review: this commit also changes the non-Apple default OutputMethod from SDL to OpenGL when config.ini has no explicit value (faithful to the PR; flag if unwanted on Windows). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of the PR #10 breakup (navjack, "Add macOS/Linux support, true widescreen, and Steam Deck validation"). Original authorship preserved.
What this is
Native macOS backend from PR #10: Metal presentation,
GameController.framework(Xbox/PlayStation/Switch pads), a Core Audio output AudioUnit, anInfo.plist+.icns, and the CMake macOS glue. Also vendors NTSC-CRT (third_party/ntsc-crt) for the optional CRT display mode. Stacked onpr10/linux-ingame-ui+pr10/imgui-vendor-launcher(their commits appear here too, since none are inmain).Disposition: PENDING — wanted, needs work before merge
The native backend itself is desirable and cleanly separable —
macos_backend.m/.hare pure system-framework + SDL (no ImGui), portable as-is. Before it can land:main.cdiff wires the native backend together with the superseded in-tree ImGui menu (macos_ui.mm,linux_ui.*); that wiring must be rebased onto the current recomp-ui world.third_party/imgui(~65k lines) andthird_party/ntsc-crtshould not be re-imported here — recomp-ui owns ImGui; NTSC-CRT is a separate opt-in decision.OutputMethodSDL→OpenGL — intentional? (faithful to the original PR, but worth a decision).Prebuilt
MegaManX.appand Steam Deck binaries are deliberately excluded.Kept open for discussion + eventual rework as part of the PR #10 close-out. Base is
main.