From 5dee4371d5999019be0deb4645271c7e3a5de934 Mon Sep 17 00:00:00 2001 From: jacekpoz Date: Fri, 21 Jul 2023 00:37:48 +0200 Subject: [PATCH] ok no crackles anymore --- hosts/niks/configuration.nix | 28 ++++++++++++++++++++++++---- 1 file changed, 24 insertions(+), 4 deletions(-) diff --git a/hosts/niks/configuration.nix b/hosts/niks/configuration.nix index d891f44..67ea20d 100644 --- a/hosts/niks/configuration.nix +++ b/hosts/niks/configuration.nix @@ -109,7 +109,9 @@ in SYSTEMD_TIMEDATED_NTP_SERVICES = "chronyd.service:systemd-timesyncd.service"; }; - etc = { + etc = let + json = pkgs.formats.json {}; + in { "greetd/environments".text = '' Hyprland sway @@ -119,11 +121,29 @@ in "pipewire/pipewire.conf.d/92-low-latency.conf".text = '' context.properties = { default.clock.rate = 48000 - default.clock.quantum = 64 - default.clock.min-quantum = 64 - default.clock.max-quantum = 64 + default.clock.quantum = 128 + default.clock.min-quantum = 128 + default.clock.max-quantum = 128 } ''; + "pipewire/pipewire-pulse.d/92-low-latency.conf".source = json.generate "92-low-latency.conf" { + context.modules = [ + { + name = "libpipewire-module-protocol-pulse"; + args = { + pulse.min.req = "32/48000"; + pulse.default.req = "32/48000"; + pulse.max.req = "32/48000"; + pulse.min.quantum = "32/48000"; + pulse.max.quantum = "32/48000"; + }; + } + ]; + stream.properties = { + node.latency = "32/48000"; + resample.quality = 1; + }; + }; }; };