nixos-config/modules/desktop/audio.nix

64 lines
2.4 KiB
Nix
Raw Normal View History

# My audio tools...
2020-08-06 15:35:49 +00:00
# I create "music" (with no experience whatsoever) so here's my "music" workflow.
# TODO: I may have to switch to Pipewire for the FUTURE.
2020-08-06 15:35:49 +00:00
{ config, options, lib, pkgs, ... }:
with lib;
let
cfg = config.modules.desktop.audio;
2020-08-06 15:35:49 +00:00
in {
options.modules.desktop.audio =
2020-08-06 15:35:49 +00:00
let mkBoolDefault = bool: mkOption {
type = types.bool;
default = bool;
}; in {
enable = mkBoolDefault false;
2020-08-16 08:33:44 +00:00
composition.enable = mkBoolDefault false;
production.enable = mkBoolDefault false;
2020-08-06 15:35:49 +00:00
};
config = mkIf cfg.enable {
# Enable JACK for the most serious audio applications.
services.jack = {
alsa.enable = true;
jackd.enable = true;
};
2020-08-16 08:33:44 +00:00
my.packages = with pkgs;
[
cadence
] ++
2020-08-06 15:35:49 +00:00
(if cfg.composition.enable then [
2020-08-16 08:33:44 +00:00
lilypond # Prevent your compositions to be forever lost when you're in grave by engraving them now (or whenever you feel like it).
musescore # A music composer for creating musical cheatsheets.
2020-08-06 15:35:49 +00:00
soundfont-fluid # A soundfont for it or something.
sonic-pi # A pie made up of them supersonic sounds created from electricity.
supercollider # Programming platform for synthesizing them 'zics.
2020-08-06 15:35:49 +00:00
] else []) ++
(if cfg.production.enable then [
ardour # A DAW focuses on hardware recording but it can be used for something else.
2020-08-16 08:33:44 +00:00
audacity # Belongs in the great city of "Simple tools for short audio samples".
2020-08-06 15:35:49 +00:00
carla # A plugin host useful for a consistent hub for them soundfonts and SFZs.
2020-08-16 08:33:44 +00:00
fluidsynth # Synth for fluid sounds.
geonkick # Create them percussions.
2020-08-06 15:35:49 +00:00
helm # A great synthesizer plugin.
2020-08-16 08:33:44 +00:00
hydrogen # Them drum beats composition will get good.
polyphone # Edit your fonts for sound.
#zrythm # An up-and-coming DAW in Linux town.
2020-08-16 08:33:44 +00:00
zynaddsubfx # Ze most advanced synthesizer I've seen so far (aside from the upcoming Vital syntehsizer).
2020-08-06 15:35:49 +00:00
# As of 2020-07-03, lmms has some trouble regarding Qt or something so at least use the "unstable" channel just to be safe.
# lmms
] else []);
# Required when enabling JACK daemon.
my.user.extraGroups = [ "jackaudio" ];
# Add the sequencer and the MIDI kernel module.
boot.kernelModules = [ "snd-seq" "snd-rawmidi" ];
2020-08-06 15:35:49 +00:00
};
}