gamescope icon indicating copy to clipboard operation
gamescope copied to clipboard

[Feature Request] Expose zoomScaleRatio as a command-line option

Open mmatis opened this issue 1 year ago • 3 comments

On steam deck, the Magnifier feature scales the screen about +50%. I think this is controlled by the zoomScaleRatio float in steamcompmgr.cpp, though I'm not sure where that default of +50% magnification comes from. There are many cases where this level of magnification is not enough for people with visual impairments. It's probably too much to ask for this to get added as an option in the Steam Client, but it would be an excellent start if gamescope made the default magnifier zoom scale configurable via a command-line option. Even better would be zoom in/out hotkeys so it can be changed on-the-fly mid-game.

mmatis avatar Aug 17 '23 00:08 mmatis

I had a glance through the code and found this:

if ( zoomScaleRatio != 1.0 ) { scaledX += ((sourceWidth / 2) - winX) * currentScaleRatio_x; scaledY += ((sourceHeight / 2) - winY) * currentScaleRatio_y; }

If I’m not mistaken, this is dividing the source window in half and adding that to the current window scale. There are other references to how it handles the overscan, cursor and so on. But if you could build a plugin to change this math to add more than just 50% (Removing the /2?) would give you a 200% zoom.

it seems like zoomScaleRatio might be an obfuscated book value rather than a true integer.

the code also references something to do with atoms.screenZoomAtom and SCREEN_MAGNIFICATION_PROP but I have no idea what they are referencing.

NB. I only have a rudimentary understanding of code but I’m tired of this being ignored, and the number of games with unnecessarily small text is slowly edging people like me with vision impairments out of gaming entirely.

Lvsoar avatar Mar 04 '24 19:03 Lvsoar

Well, I've had enough of this as well and thrown together a workaround that lets zooming in as much as one needs in Gaming mode: https://github.com/arkareth/steam-deck-improved-magnification

Readme is a bit messy, but you should be able to figure it out.

I hope this helps until Valve (hopefully) comes up with a proper solution, folks. Any questions or help needed - just let me know.

arkareth avatar Jun 02 '24 17:06 arkareth

Thanks for the suggestion.

The steam client now exposes a configurable zoom ratio under settings-> display.

lostgoat avatar Jun 18 '24 03:06 lostgoat

Well, I've had enough of this as well and thrown together a workaround that lets zooming in as much as one needs in Gaming mode: https://github.com/arkareth/steam-deck-improved-magnification

Readme is a bit messy, but you should be able to figure it out.

I hope this helps until Valve (hopefully) comes up with a proper solution, folks. Any questions or help needed - just let me know.

Absolute HERO!!! (and thanks for the shout-out!)

mmatis avatar Jul 30 '24 15:07 mmatis

There is a slider in Steam now

misyltoad avatar Jul 30 '24 16:07 misyltoad