Post

Gamescope - Valve's upscaler

Gamescope - Valve's upscaler

Gamescope is a microcompositor from Valve that is used on the Steam Deck. Its goal is to provide an isolated compositor that is tailored towards gaming and supports many gaming-centric features such as:

  • Spoofing resolutions
  • Upscaling using AMD FidelityFX™ Super Resolution (FSR) or NVIDIA Image Scaling (NIS)
  • Limiting framerates.

Requirements

  • AMD: Mesa 20.3 or above
  • Intel: Mesa 21.2 or above
  • NVIDIA: proprietary drivers 515.43.04 or above, and the nvidia-drm.modeset=1 kernel parameter

Installation

1
sudo pacman -S gamescope

Nvidia

Better understanding of how Nvidia DRM Modeset is designed found in Nvidia forum by an official called “aplattner”.

[…] All it really does is enable the DRIVER_MODESET capability flag in the nvidia-drm devices so that DRM clients can use the various modesetting APIs. In addition to allowing clients that talk to the low-level DRM interface to work, it’s also necessary for some PRIME-related interoperability features. […]

To set it you have to add it nvidia-drm.modeset=1 to the kernel (linux) command line in bootloaders, like for GRUB you have to edit /etc/default/grub as root.

1
GRUB_CMDLINE_LINUX_DEFAULT="loglevel=3 quiet nvidia-drm.modeset=1"

Apply the changes and restart afterwards.

1
grub-mkconfig -o /boot/grub/grub.cfg

For bootloaders other than GRUB checkout Arch Wiki > Kernel paramters

Usage

Gamescope offers many options, far too many to cover here. For a full list use the gamescope --help command from a terminal.

1
gamescope -h 720 -H 1080 -F fsr -f --expose-wayland --
parameterdescription
-W, –output-widthoutput width (of display)
-H, –output-heightoutput height (of display)
-w, –nested-widthgame width
-h, –nested-heightgame height
-r, –nested-refreshgame refresh rate (frames per second)
-F, –filterupscaler filter (linear, nearest, fsr, nis, pixel)
-b, –borderlessmake the window borderless
-f, –fullscreenmake the window fullscreen
–expose-waylandAllow support for wayland clients using xdg-shell

fsr => AMD FidelityFX™ Super Resolution 1.0

nis => NVIDIA Image Scaling v1.0.3

Steam

If you’re using Proton Experimental or all other official builds then edit your start options per-game this way:

1
gamemoderun gamescope -h 720 -H 1080 -F fsr -f -- %command%

If you’re using Proton-GE custom build then edit your start options per-game this way:

1
WINE_FULLSCREEN_FSR=1 WINE_FULLSCREEN_FSR_MODE=balanced WINE_FULLSCREEN_FSR_STRENGTH=1 %command%

Any other lauchners

… have options for this, for example: gamescope-lutris gamescope-heroic

Examples

my Setup(s):

PCCPUCores / ThreadsRAMGPU
Gigabyte BRIX sAMD Ryzen 7 4800U8 / 1632 GBAMD Radeon RX Vega 8
Asus TUF FX504GEIntel Core i7-8750H6 / 1216 GBNvidia Geforce 1050 Ti Mobile

The Elder Scrolls V - Skyrim (Special Edition)

  • Used Proton-GE (latest)
  • Launch options in Steam:
    1
    
    WINE_FULLSCREEN_FSR=1 WINE_FULLSCREEN_FSR_CUSTOM_MODE=1280x720 WINE_FULLSCREEN_FSR_MODE=quality WINE_FULLSCREEN_FSR_STRENGTH=2 %command%
    
  • Settings ingame: gamescope-tesiv-settings

  • Final result: gamescope-tesiv-fps

    I don’t know how accurate MangoHUD is, but the game runs smooth.

More games will follow.

This post is licensed under CC BY 4.0 by the author.