-->

How do I configure HDR and Wayland environment variables in Proton for supported Steam games

How to activate "PROTON_ENABLE_WAYLAND=1" permanently? - Issues &  Assistance - CachyOS Forum

Configuring HDR and native Wayland rendering for Steam games running through Proton requires coordination between your desktop environment, Vulkan translation layers (DXVK/VKD3D-Proton), and a compatible Proton runner.

1. Prerequisites

Before setting launch options in Steam, ensure your desktop stack supports HDR:

  1. Enable HDR in your Desktop Environment:

    • KDE Plasma 6+: Enable HDR in System Settings > Display Configuration.

    • GNOME 48+: Enable the HDR toggle under Settings > Displays.

    • Hyprland: Ensure cm = "hdr" and bitdepth = 10 are configured for your monitor.

  2. Use Proton-GE / Custom Proton:

    • Official Valve Proton defaults to XWayland for compatibility reasons. Custom builds like GE-Proton (or Proton-CachyOS) contain the necessary patches for the native Wine Wayland driver and HDR integration. Install the latest GE-Proton via ProtonUp-Qt or ProtonPlus.

Method A: Direct Native Wayland + HDR (Recommended)

This method tells Proton to bypass XWayland entirely, using Wine's native Wayland driver to expose HDR capabilities directly to the game.

Steam Launch Options:

Right-click your game in Steam > Properties > General > Launch Options, then enter:

Bash

PROTON_ENABLE_WAYLAND=1 PROTON_ENABLE_HDR=1 %command%
Key Environment Variables Explained:

Variable
Description

PROTON_ENABLE_WAYLAND=1
Forces Proton to use the native Wine Wayland display backend instead of XWayland.

PROTON_ENABLE_HDR=1
Exposes HDR display capabilities to the Windows application and automatically enables DXVK_HDR=1.

DXVK_HDR=1
Directs DXVK to enable HDR swapchain creation for DirectX 11 games.

ENABLE_HDR_WSI=1
Activates the Vulkan Wayland HDR WSI layer (often necessary on NVIDIA GPUs or custom Vulkan layers).

For NVIDIA GPUs: Add ENABLE_HDR_WSI=1 if the HDR toggle remains greyed out in-game:

Bash

PROTON_ENABLE_WAYLAND=1 PROTON_ENABLE_HDR=1 ENABLE_HDR_WSI=1 %command%

Method B: Using Gamescope Wrapper

If a game has rendering glitches under pure Wayland, or if you prefer using Valve's nested compositor, you can run the game inside Gamescope with HDR enabled.

Steam Launch Options:

Bash

DXVK_HDR=1 gamescope -f -W 3840 -H 2160 -r 144 --hdr-enabled -- %command%

(Replace 3840, 2160, and 144 with your monitor's native width, height, and refresh rate).

3. Known Trade-offs & Limitations

  • Steam Overlay: Enabling native Wayland (PROTON_ENABLE_WAYLAND=1) can occasionally disable or cause visual glitches with the Steam In-Game Overlay, as the overlay still primarily targets XWayland.

  • Steam Input / Controllers: Certain gamepad configurations or virtual controllers may require switching back to XWayland if input isn't captured properly.

  • In-Game Settings: Once launched with HDR options, open the game's display/graphics menu and manually toggle HDR On. Adjust the peak brightness slider to match your display's nit rating.

Share on Google Plus

About Giampaolo Rossi.

Fond of computer and video games. Stay informed of the latest news on games for Linux and Android. The future of gaming is in Linux. All you need to know about How to play Windows games on Linux.
    Blogger Comment
    Facebook Comment

0 commenti:

Post a Comment

Random Posts