nixos-config/modules/pulseaudio.nix

28 lines
641 B
Nix
Raw Normal View History

2020-12-05 13:48:06 +01:00
{ config, lib, pkgs, ... }:
2020-08-22 17:44:39 +02:00
2020-12-05 13:48:06 +01:00
lib.mkIf config.sbruder.gui {
2020-08-22 17:44:39 +02:00
sound.enable = true;
2020-11-05 15:09:12 +01:00
hardware.pulseaudio = {
enable = true;
package = pkgs.pulseaudioFull;
2020-11-05 15:31:43 +01:00
extraModules = [
pkgs.pulseaudio-modules-bt # Non-standard codecs for bluetooth
];
2020-11-05 15:09:12 +01:00
daemon.config = {
"default-sample-format" = "s16le";
"default-sample-rate" = "48000";
"alternate-sample-rate" = "44100";
"resample-method" = "soxr-hq";
"flat-volumes" = "no";
};
2020-08-22 17:44:39 +02:00
};
2020-11-05 15:31:43 +01:00
# Bluetooth support
hardware.bluetooth.enable = true;
services.blueman.enable = true;
2020-08-22 17:44:39 +02:00
environment.systemPackages = with pkgs; [
pavucontrol
];
}