Cockpit scales both ways and re-fits on resize, aspect locked
The canvas was capped at 100%, so a bigger monitor got a 1920x1080 cockpit in the corner of the screen and maximising did nothing - the layout only ran once at startup. Now the fit is one uniform scale with no ceiling, recomputed whenever the window changes size (maximise, restore, drag), and the canvas is centred in whatever client area it gets. Uniform scale is what locks the aspect: a wider-than-16:9 desktop letterboxes with even black bars instead of stretching the cockpit. Panes gained Resize() so the glass and its button banks re-scale with the canvas; the pixel buffers keep their native source resolution. Scaling up is free quality on the MFDs - their glass is a downscale of a native 640x480 channel until about 200%. Verified on the 3440x1392 ultrawide: opens at 125% (2400x1350) instead of 100%, maximises to 126% centred with even bars, a 1884x661 window fits 61% letterboxed left/right, 1084x961 fits 56% letterboxed top/ bottom, and a 2584x1461 client scales up to 134%. The 3D still renders at -res and D3D stretches it to the canvas, so raise -res to match a large screen for 1:1 pixels; start-windowed.bat and the README say so. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
+9
-1
@@ -234,7 +234,10 @@ RP412STEAM=1
|
||||
Set-Content -Path "$dist\start-windowed.bat" -Encoding ascii -Value @"
|
||||
@echo off
|
||||
rem Red Planet 4.12 - desktop prototype. Boots into the game-setup
|
||||
rem front end; the cockpit canvas is 1920x1080 and -res matches it.
|
||||
rem front end. The cockpit fits itself to the window and keeps 16:9,
|
||||
rem so a wider screen letterboxes rather than stretching. -res sets the
|
||||
rem 3D render size - raise it to match a big screen for sharper pixels,
|
||||
rem e.g. -res 2560 1440.
|
||||
rem (Add -egg TEST.EGG to skip the menu and run the canned mission.)
|
||||
cd /d "%~dp0"
|
||||
start rpl4opt.exe -windowed -res 1920 1080
|
||||
@@ -263,6 +266,11 @@ documented default layout on first run; delete it to restore).
|
||||
F1-F12 secondary / screen columns
|
||||
Alt+Q abort the mission (score banked)
|
||||
|
||||
The cockpit scales to whatever window you give it - maximise it and it
|
||||
grows, keeping its 16:9 shape (an ultrawide gets black bars rather than
|
||||
a stretched cockpit). The 3D itself renders at whatever -res says, so
|
||||
on a big screen raise it to match: rpl4opt.exe -windowed -res 2560 1440.
|
||||
|
||||
The full pod cockpit comes up in a single window: three green MFDs
|
||||
across the top, the 3D viewscreen centered with the orange plasma glass
|
||||
at its left, and the lower MFDs flanking the portrait map. The red
|
||||
|
||||
Reference in New Issue
Block a user