From 11f8b66b911f303cfb8f090e40856b69ed68737b Mon Sep 17 00:00:00 2001 From: Pedro Rey Anca Date: Sat, 6 Dec 2025 13:20:09 +0100 Subject: [PATCH] Refactor gamescope --- machines/frues-pc/configuration.nix | 11 +++++++++++ modules/desktop/gaming.nix | 8 ++++++-- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/machines/frues-pc/configuration.nix b/machines/frues-pc/configuration.nix index 3c08496..910cfa3 100644 --- a/machines/frues-pc/configuration.nix +++ b/machines/frues-pc/configuration.nix @@ -22,6 +22,17 @@ services.sunshine.autoStart = true; + programs.steam.gamescopeSession = { + enable = true; + args = [ + "--prefer-output" + "DP-1,*" + "--rt" + "--adaptive-sync" + "--steam" + ]; + }; + home-manager.users.pedro.wayland.windowManager.hyprland.settings = { monitor = [ "DP-2, 1920x1080@60, 0x0, 1" diff --git a/modules/desktop/gaming.nix b/modules/desktop/gaming.nix index 29e7639..9900999 100644 --- a/modules/desktop/gaming.nix +++ b/modules/desktop/gaming.nix @@ -1,12 +1,16 @@ -{ pkgs, lib, ... }: +{ lib, ... }: { programs.steam = { enable = true; remotePlay.openFirewall = true; dedicatedServer.openFirewall = false; + gamescopeSession.enable = true; }; - environment.systemPackages = [ pkgs.gamescope ]; + programs.gamescope = { + enable = true; + capSysNice = true; + }; programs.gamemode.enable = true;