From a2d976591bb23140694b3cb219318c665896c9d4 Mon Sep 17 00:00:00 2001 From: Love Billenius Date: Wed, 22 Apr 2026 19:58:50 +0200 Subject: [PATCH] more audio prio --- modules/hosts/kronos/configuration.nix | 7 +++++-- modules/nixos/desktop-hyprland.nix | 21 +++++++++++++++++++++ 2 files changed, 26 insertions(+), 2 deletions(-) diff --git a/modules/hosts/kronos/configuration.nix b/modules/hosts/kronos/configuration.nix index 40d1220..7015349 100644 --- a/modules/hosts/kronos/configuration.nix +++ b/modules/hosts/kronos/configuration.nix @@ -13,6 +13,10 @@ let installDisk = "/dev/disk/by-id/ata-SanDisk_SD8SB8U-256G-1006_173702422853"; in { + environment.sessionVariables = { + NIXOS_OZONE_WL = "1"; + }; + _module.args = { inherit fullName @@ -51,14 +55,13 @@ in configurationLimit = 10; edk2-uefi-shell.enable = true; }; + boot.kernelPackages = pkgs.linuxPackages_zen; boot.loader.efi.canTouchEfiVariables = true; boot.loader.grub.enable = lib.mkForce false; networking.hostName = hostName; networking.hostId = "ff0b8826"; - environment.sessionVariables.NIXOS_OZONE_WL = "1"; - services.xserver.videoDrivers = [ "nvidia" ]; hardware = { graphics = { diff --git a/modules/nixos/desktop-hyprland.nix b/modules/nixos/desktop-hyprland.nix index 34f8d49..e59f7b0 100644 --- a/modules/nixos/desktop-hyprland.nix +++ b/modules/nixos/desktop-hyprland.nix @@ -41,6 +41,15 @@ alsa.support32Bit = true; pulse.enable = true; wireplumber.enable = true; + extraConfig.pipewire."10-buffer-stability" = { + context.properties = { + # Favor playback stability over minimum latency when the system is busy. + default.clock.rate = 48000; + default.clock.quantum = 1024; + default.clock.min-quantum = 1024; + default.clock.max-quantum = 2048; + }; + }; }; services.tumbler.enable = true; services.udisks2.enable = true; @@ -88,4 +97,16 @@ }; }; + systemd.user.services.pipewire.serviceConfig = { + Nice = -15; + CPUWeight = 90; + IOWeight = 90; + }; + + systemd.user.services.wireplumber.serviceConfig = { + Nice = -10; + CPUWeight = 80; + IOWeight = 80; + }; + }