diff --git a/hosts/tsuki/default.nix b/hosts/tsuki/default.nix index 2c5ff7e..b69523c 100755 --- a/hosts/tsuki/default.nix +++ b/hosts/tsuki/default.nix @@ -41,7 +41,7 @@ pulse.enable = true; wireplumber.enable = true; lowLatency = { - enable = false; # disabled due to upstream issue + enable = true; quantum = 64; rate = 48000; }; @@ -62,7 +62,6 @@ services.hyprlock = {}; }; }; - programs = { gamemode.enable = true; appimage = { diff --git a/hosts/tsuki/hardware.nix b/hosts/tsuki/hardware.nix index 39f9368..9c2c226 100755 --- a/hosts/tsuki/hardware.nix +++ b/hosts/tsuki/hardware.nix @@ -10,6 +10,9 @@ boot = { kernelModules = ["kvm-amd"]; + extraModulePackages = with config.boot.kernelPackages; [ + v4l2loopback.out + ]; loader = { systemd-boot = { enable = true; @@ -26,6 +29,8 @@ }; }; + hardware.wooting.enable = true; + fileSystems = { "/" = { device = "/dev/disk/by-uuid/a423d32f-ac5d-4ea2-82fb-f94b05afce29"; diff --git a/hosts/tsuki/services/default.nix b/hosts/tsuki/services/default.nix index 018e016..18692c6 100644 --- a/hosts/tsuki/services/default.nix +++ b/hosts/tsuki/services/default.nix @@ -5,5 +5,6 @@ ./hydroxide.nix ./sunshine.nix ./wivrn.nix + ./rnnoise.nix ]; } diff --git a/hosts/tsuki/services/rnnoise.nix b/hosts/tsuki/services/rnnoise.nix new file mode 100644 index 0000000..bd2935a --- /dev/null +++ b/hosts/tsuki/services/rnnoise.nix @@ -0,0 +1,40 @@ +{pkgs, ...}: { + services.pipewire.extraConfig.pipewire."00-rnnoise.conf" = { + "context.modules" = [ + { + "name" = "libpipewire-module-filter-chain"; + "args" = { + "node.description" = "Noise Cancelling source"; + "media.name" = "Noise Cancelling source"; + "filter.graph" = { + "nodes" = [ + { + "type" = "ladspa"; + "name" = "rnnoise"; + "plugin" = "${pkgs.rnnoise-plugin}/lib/ladspa/librnnoise_ladspa.so"; + "label" = "noise_suppressor_stereo"; + "control" = { + "VAD Threshold (%)" = 50.0; + "VAD Grace Period (ms)" = 1000; + "Retroactive VAD Grace (ms)" = 100; + }; + } + ]; + }; + "audio.position" = ["FL" "FR"]; + "capture.props" = { + "node.name" = "capture.rnnoise_source"; + "node.passive" = true; + "audio.rate" = 48000; + }; + "playback.props" = { + "node.name" = "rnnoise_source"; + "media.class" = "Audio/Source"; + "media.role" = "Communication"; + "audio.rate" = 48000; + }; + }; + } + ]; + }; +}