added stuff
This commit is contained in:
parent
e8d9044d2b
commit
9d0ebdfbd0
907 changed files with 70990 additions and 0 deletions
16
nyx/homes/notashelf/misc/dconf.nix
Normal file
16
nyx/homes/notashelf/misc/dconf.nix
Normal file
|
@ -0,0 +1,16 @@
|
|||
{
|
||||
dconf.settings = {
|
||||
# this is like a system-wide dark mode switch that some apps respect
|
||||
# equivalent of the following dconf command:
|
||||
# `conf write /org/gnome/desktop/interface/color-scheme "'prefer-dark'"`
|
||||
"org/gnome/desktop/interface" = {
|
||||
color-scheme = "prefer-dark";
|
||||
};
|
||||
|
||||
# tell virt-manager to use the system connection
|
||||
"org/virt-manager/virt-manager/connections" = {
|
||||
autoconnect = ["qemu:///system"];
|
||||
uris = ["qemu:///system"];
|
||||
};
|
||||
};
|
||||
}
|
6
nyx/homes/notashelf/misc/default.nix
Normal file
6
nyx/homes/notashelf/misc/default.nix
Normal file
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
imports = [
|
||||
./dconf.nix # dconf settings, courtesy of the dconf module
|
||||
./rnnoise.nix # rnnoise plugin for pipewire
|
||||
];
|
||||
}
|
56
nyx/homes/notashelf/misc/rnnoise.nix
Normal file
56
nyx/homes/notashelf/misc/rnnoise.nix
Normal file
|
@ -0,0 +1,56 @@
|
|||
{
|
||||
osConfig,
|
||||
pkgs,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
inherit (lib.modules) mkIf;
|
||||
inherit (osConfig.modules) device;
|
||||
|
||||
format = pkgs.formats.json {};
|
||||
|
||||
acceptedTypes = ["desktop" "laptop"];
|
||||
in {
|
||||
config = mkIf (builtins.elem device.type acceptedTypes) {
|
||||
# Write a PipeWire userspace configuration based on werman's noise-supression-for-voice
|
||||
# for usage instructions, see:
|
||||
# <https://github.com/werman/noise-suppression-for-voice?tab=readme-ov-file#linux>
|
||||
xdg.configFile."pipewire/pipewire.conf.d/99-input-denoising.conf".source = format.generate "99-input-denoising.conf" {
|
||||
"context.modules" = [
|
||||
{
|
||||
"name" = "libpipewire-module-filter-chain";
|
||||
"args" = {
|
||||
"node.description" = "Noise Canceling source";
|
||||
"media.name" = "Noise Canceling source";
|
||||
"filter.graph" = {
|
||||
"nodes" = [
|
||||
{
|
||||
"type" = "ladspa";
|
||||
"name" = "rnnoise";
|
||||
"plugin" = "${pkgs.rnnoise-plugin}/lib/ladspa/librnnoise_ladspa.so";
|
||||
"label" = "noise_suppressor_mono"; # or "noise_suppressor_stereo", consumes twice the resources
|
||||
"control" = {
|
||||
"VAD Threshold (%)" = 50.0;
|
||||
"VAD Grace Period (ms)" = 200;
|
||||
"Retroactive VAD Grace (ms)" = 0;
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
"audio.position" = ["FL" "FR"];
|
||||
"capture.props" = {
|
||||
"node.name" = "effect_input.rnnoise";
|
||||
"node.passive" = true;
|
||||
"audio.rate" = 48000;
|
||||
};
|
||||
"playback.props" = {
|
||||
"node.name" = "effect_output.rnnoise";
|
||||
"media.class" = "Audio/Source";
|
||||
"audio.rate" = 48000;
|
||||
};
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue