fix(display): correct UI scaling and coordinate mapping across output resolutions #484

Open
github-bot wants to merge 3 commits from github-bot/gh-484 into main AGit
Owner

@⁠CristoDeveloper on GitHub · 2026-12-02 16:30 UTC · original
CristoDeveloper:fix/series-x-1080p-ui-scaling → main · +456 −42 · 16 files · 3 commits · draft

Problem

In apps/victory/src/run.rs, run() overwrote VICTORY_DISPLAY_MODE with the scanout dimensions. dxgi::modes therefore enumerated 2560×1440 even when a Series X title needed its stock 3840×2160 UI canvas. State::native_frontend_viewport could then expand the interface viewport to 4K while leaving the scissor at scanout size. The HLE display module handles HDR and shell services; the mode list lives in victory-gpu.

There is a separate host input mismatch. Host::present_planes knows where the picture was drawn, including fullscreen bars, while the title window forwarded absolute client positions and confined the OS cursor to the whole client. Raw mouse movement drives an emulated stick. The title handles selection for that stick and for physical gamepads.

Change

The new launcher choice 1080p display: Series X (1440p scanout) and PowerShell option -Res 1080 retain the tested 1440p native profile. The runner stores the logical display separately and uses scanout dimensions for scene scale, tiled reservations and upscaler planning. A failed split request stops before a stock 4K fallback. The renderer retains the title's composite viewport when it uses a separate stock 4K canvas.

The presenter shares its picture rectangle with the presenting HWND. Absolute client mouse messages and screen/client point conversions use forward and inverse mappings through that rectangle. Win32 supplies the current client dimensions in the process's DPI context. Wheel coordinates stay in desktop space, and raw mouse counts and gamepad axes keep their existing behavior.

Configuration DXGI display Scanout Scene
New Series X preset on a 1080p screen 3840×2160 2560×1440 1920×1080 without an upscaler, otherwise the selected quality
Existing Series X 1440p 2560×1440 by default, explicit 4K available 2560×1440 Existing scene scale
Stock Series X 4K Stock mode Stock output Title-selected
Series S, ultrawide and experimental 1920×1200 Existing defaults Existing outputs Existing scales

Previously the launcher's 1080p setting selected Series S. That saved option remains available. The new Series X preset uses DXGI stretch to present the 1440p scanout on a 1080p monitor. There is no additional 16:9 rendering pass or 4K host surface. DLSS Performance requests a 1280×720 scene. Frame generation uses its existing picture rectangle. No FPS or VRAM benchmark was run.

Verification

  • PASS — 18 focused Windows Rust tests, compiling the repository's actual display geometry, runner display, texture-layout and Streamline planning/ABI sources. Cases include 1080p, 1440p, 4K, four corners and centre, DPI-virtualized client sizes at 125% and 150%, a smaller borderless client, pillarboxing, letterboxing, round trips, scanout budgets and upscaler dimensions.
  • PASS — .NET Framework launcher build and a settings smoke test for the new preset and existing 1080p-class, 1440p and 4K selections.
  • PASS — staged asset policy, git diff --check and rustfmt on the new geometry module. Workspace-wide formatting reports pre-existing differences beginning in untouched apps/victory/src/agility.rs.
  • PASS — Windows Rust type checking for the display changes. After correcting the Windows binding for WM_MOUSEHOVER, the HLE and runner passed rustc metadata checks using Cargo-produced dependency metadata. This check does not link an executable.
  • BLOCKED locally — the full locked Rust build/test needs the uncached mimalloc 0.1.48 crate. The registry download host was unavailable. An isolated retry using the upstream sources for the missing crate versions reached the Windows build scripts, where Application Control blocked execution (OS error 4551). The focused run is separate from the workspace suite.
  • NOT RUN — an in-game HUD and waypoint comparison, live Windows DPI changes, hardware DLSS/FSR/frame generation, and performance measurements.

Remaining validation

On a 1080p display, compare the pause menu, minimap edges and waypoint placement at the centre and four corners using the new preset. Check fullscreen and borderless, a real pad and mouse. Coordinate round trips cannot establish how a title lays out its HUD or selects a stick-driven map waypoint. FSR 3 frame generation retains its existing full-buffer behavior on mismatched aspect ratios.

Related reports: #117, #137, #274.

**@⁠CristoDeveloper** on GitHub · 2026-12-02 16:30 UTC · [original](https://github.com/readmet3xt-lab/foxhound/pull/484) `CristoDeveloper:fix/series-x-1080p-ui-scaling` → `main` · +456 −42 · 16 files · 3 commits · draft ## Problem In apps/victory/src/run.rs, run() overwrote VICTORY_DISPLAY_MODE with the scanout dimensions. dxgi::modes therefore enumerated 2560×1440 even when a Series X title needed its stock 3840×2160 UI canvas. State::native_frontend_viewport could then expand the interface viewport to 4K while leaving the scissor at scanout size. The HLE display module handles HDR and shell services; the mode list lives in victory-gpu. There is a separate host input mismatch. Host::present_planes knows where the picture was drawn, including fullscreen bars, while the title window forwarded absolute client positions and confined the OS cursor to the whole client. Raw mouse movement drives an emulated stick. The title handles selection for that stick and for physical gamepads. ## Change The new launcher choice **1080p display: Series X (1440p scanout)** and PowerShell option **-Res 1080** retain the tested 1440p native profile. The runner stores the logical display separately and uses scanout dimensions for scene scale, tiled reservations and upscaler planning. A failed split request stops before a stock 4K fallback. The renderer retains the title's composite viewport when it uses a separate stock 4K canvas. The presenter shares its picture rectangle with the presenting HWND. Absolute client mouse messages and screen/client point conversions use forward and inverse mappings through that rectangle. Win32 supplies the current client dimensions in the process's DPI context. Wheel coordinates stay in desktop space, and raw mouse counts and gamepad axes keep their existing behavior. | Configuration | DXGI display | Scanout | Scene | |---|---|---|---| | New Series X preset on a 1080p screen | 3840×2160 | 2560×1440 | 1920×1080 without an upscaler, otherwise the selected quality | | Existing Series X 1440p | 2560×1440 by default, explicit 4K available | 2560×1440 | Existing scene scale | | Stock Series X 4K | Stock mode | Stock output | Title-selected | | Series S, ultrawide and experimental 1920×1200 | Existing defaults | Existing outputs | Existing scales | Previously the launcher's 1080p setting selected Series S. That saved option remains available. The new Series X preset uses DXGI stretch to present the 1440p scanout on a 1080p monitor. There is no additional 16:9 rendering pass or 4K host surface. DLSS Performance requests a 1280×720 scene. Frame generation uses its existing picture rectangle. No FPS or VRAM benchmark was run. ## Verification - **PASS** — 18 focused Windows Rust tests, compiling the repository's actual display geometry, runner display, texture-layout and Streamline planning/ABI sources. Cases include 1080p, 1440p, 4K, four corners and centre, DPI-virtualized client sizes at 125% and 150%, a smaller borderless client, pillarboxing, letterboxing, round trips, scanout budgets and upscaler dimensions. - **PASS** — .NET Framework launcher build and a settings smoke test for the new preset and existing 1080p-class, 1440p and 4K selections. - **PASS** — staged asset policy, git diff --check and rustfmt on the new geometry module. Workspace-wide formatting reports pre-existing differences beginning in untouched apps/victory/src/agility.rs. - **PASS** — Windows Rust type checking for the display changes. After correcting the Windows binding for WM_MOUSEHOVER, the HLE and runner passed rustc metadata checks using Cargo-produced dependency metadata. This check does not link an executable. - **BLOCKED locally** — the full locked Rust build/test needs the uncached mimalloc 0.1.48 crate. The registry download host was unavailable. An isolated retry using the upstream sources for the missing crate versions reached the Windows build scripts, where Application Control blocked execution (OS error 4551). The focused run is separate from the workspace suite. - **NOT RUN** — an in-game HUD and waypoint comparison, live Windows DPI changes, hardware DLSS/FSR/frame generation, and performance measurements. ## Remaining validation On a 1080p display, compare the pause menu, minimap edges and waypoint placement at the centre and four corners using the new preset. Check fullscreen and borderless, a real pad and mouse. Coordinate round trips cannot establish how a title lays out its HUD or selects a stick-driven map waypoint. FSR 3 frame generation retains its existing full-buffer behavior on mismatched aspect ratios. Related reports: [#117](https://git.gtahub.st/github/readmet3xt-lab--foxhound/issues/117), [#137](https://git.gtahub.st/github/readmet3xt-lab--foxhound/issues/137), [#274](https://git.gtahub.st/github/readmet3xt-lab--foxhound/issues/274).
github-bot locked as GitHub sync and limited conversation to collaborators 2026-12-02 18:29:33 +00:00
This pull request has changes conflicting with the target branch.
  • README.md
  • apps/victory/src/run.rs
  • apps/victory/src/run/display.rs
  • crates/victory-gpu/src/draw.rs
  • crates/victory-gpu/src/dxgi.rs
  • docs/title-profile-format.md
  • launcher/Launcher.cs
  • launcher/README.txt
  • scripts/play-foxhound.ps1
View command line instructions

Manual merge helper

Use this merge commit message when completing the merge manually.

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/484/head:github-bot/gh-484'
git switch 'github-bot/gh-484'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-484'
git switch 'github-bot/gh-484'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-484'
git switch 'github-bot/gh-484'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-484'
git switch 'main'
git merge --squash 'github-bot/gh-484'
git switch 'main'
git merge --ff-only 'github-bot/gh-484'
git switch 'main'
git merge 'github-bot/gh-484'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No description provided.