ValveSoftware / ValveSoftware/Proton
Stretched scaling in Jazz Jackrabbit 2 in windowed mode (fshack)
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 32.8k
- Forks
- 1.6k
- PR merge metrics
- PR metrics pending
Description
When playing Jazz Jackrabbit 2 in windowed mode, Proton in gamescope crops away the titlebar, menubar and border, which is great. But then it gets the scaling/cropped window size wrong, and it stretches the game pixels. For example when running the game at 640x480 it gets stretched to 653x531. Here is a screenshot with integer scaling, to prove that it is not scaling properly (tested on Steam Deck):

Screenshot from the game:

For reference, when running JJ2 on a GNOME desktop, you can see the menus and border:

The game has a fullscreen (DirectDraw) mode, but it seems to draw more power on the Deck so I would prefer to run it windowed (and fshack crops and scales it up with gamescope).
Proton logfile with WINEDEBUG=+fshack,+x11drv: steam-10702214918549012480.log
Some notable lines:
013c:trace:x11drv:X11DRV_create_win_data win 0x20082/1600003 window (0,0)-(653,531) whole (0,0)-(653,531) client (0,0)-(653,531)
013c:trace:fshack:fs_hack_monitor_from_rect rect (0,0)-(653,531)
013c:trace:fshack:fs_hack_monitor_from_hwnd hwnd 0x20082 rect (0,0)-(653,531)
Jazz Jackrabbit 2 TSF running with the Plus patch, installed from GOG, running on proton-7.0-2.
I first posted an issue to gamescope, but I think I found out that it is fshack inside Proton that's cause it, or gamescope getting the wrong size. https://github.com/Plagman/gamescope/issues/475
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The report points to Proton's fshack path and includes a WINEDEBUG=+fshack,+x11drv logfile; begin by tracing the reported 653x531 window dimensions and compare them with the linked gamescope issue. Done means the 640x480 window is cropped and scaled without stretching in windowed mode.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- desktop-dev, game-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100