From 6a892a3bcdbd331e793af392916875e83e1e8b49 Mon Sep 17 00:00:00 2001 From: Joonas Rautiola Date: Tue, 3 Sep 2024 13:55:01 +0300 Subject: [PATCH] Use higher quantum to hopefully fix audio on laptop --- hosts/athens/default.nix | 10 ++++++++++ modules/desktop/sound.nix | 20 -------------------- 2 files changed, 10 insertions(+), 20 deletions(-) diff --git a/hosts/athens/default.nix b/hosts/athens/default.nix index ed0f635..b6e9adc 100644 --- a/hosts/athens/default.nix +++ b/hosts/athens/default.nix @@ -41,6 +41,16 @@ ]; }; + # the laptop cpu is not powerful enough and low quantum causes garbled audio + services.pipewire.extraConfig.pipewire."92-fix-quantum" = { + context.properties = { + default.clock.rate = 48000; + default.clock.quantum = 1024; + default.clock.min-quantum = 512; + default.clock.max-quantum = 4092; + }; + }; + services = { syncthing.settings.folders = { "camera".enable = true; diff --git a/modules/desktop/sound.nix b/modules/desktop/sound.nix index 74e7ae0..10ed8cc 100644 --- a/modules/desktop/sound.nix +++ b/modules/desktop/sound.nix @@ -11,26 +11,6 @@ "wireplumber.profiles".main."monitor.libcamera" = "disabled"; }; }; - - extraConfig.pipewire-pulse."92-low-latency" = { - "context.properties" = [ - { - name = "libpipewire-module-protocol-pulse"; - args = { }; - } - ]; - "pulse.properties" = { - "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; - }; - }; }; security.rtkit.enable = true;