Audio production: Difference between revisions
imported>Deifactor update to be more generic about audio production |
De CH-latin1 (talk | contribs) m added clap to the snippet |
||
| (4 intermediate revisions by 4 users not shown) | |||
| Line 1: | Line 1: | ||
[https://github.com/musnix/musnix Musnix] | [https://github.com/musnix/musnix Musnix] provides a set of simple, high-level configuration options for doing real-time audio work in NixOS, including optimizing the kernel, applying the CONFIG_PREEMPT_RT patch to it, and adjusting various low-level system settings, eg. setting up ulimit values automatically. | ||
== Plugins not found == | == Plugins not found == | ||
| Line 5: | Line 5: | ||
Due to NixOS not using FHS paths, many DAWs will not know where to look for VSTs and other plugins. Musnix fixes this; if you don't want to use it, you can solve this by setting | Due to NixOS not using FHS paths, many DAWs will not know where to look for VSTs and other plugins. Musnix fixes this; if you don't want to use it, you can solve this by setting | ||
<syntaxhighlight lang="nix"> | <syntaxhighlight lang="nix">environment.variables = let | ||
makePluginPath = format: | makePluginPath = format: | ||
(makeSearchPath format [ | (lib.makeSearchPath format [ | ||
"$HOME/.nix-profile/lib" | "$HOME/.nix-profile/lib" | ||
"/run/current-system/sw/lib" | "/run/current-system/sw/lib" | ||
| Line 21: | Line 20: | ||
VST_PATH = makePluginPath "vst"; | VST_PATH = makePluginPath "vst"; | ||
VST3_PATH = makePluginPath "vst3"; | VST3_PATH = makePluginPath "vst3"; | ||
}; | CLAP_PATH = makePluginPath "clap"; | ||
</syntaxhighlight> | };</syntaxhighlight> | ||
Some programs may not support those and may require other means of setting VST paths. | Some programs may not support those and may require other means of setting VST paths. | ||
| Line 28: | Line 27: | ||
== Packaging plugins == | == Packaging plugins == | ||
Source-available plugins can be packaged like any other library; note that the | Source-available plugins can be packaged like any other library; note that the files should be in a subdirectory according to the plugin type e.g. <code>$out/lib/vst3</code>. | ||
If the plugin is only available as a binary, you may need to use [[Packaging/Binaries|the advice on packaging binaries]] to help. Since many plugins will not be accessible via the standard fetchers, you can always fall back on including the plugin using <code>src = ./plugin.zip</code>; note that if you're using flakes and don't want to commit the plugin to Git (an especially bad idea if your config is public!), you can use requireFile and manually add files to the store. To do this, run <code>nix-hash --flat --type sha256 plugin.zip</code>, take the output, and use it in a derivation like so: | If the plugin is only available as a binary, you may need to use [[Packaging/Binaries|the advice on packaging binaries]] to help. Since many plugins will not be accessible via the standard fetchers, you can always fall back on including the plugin using <code>src = ./plugin.zip</code>; note that if you're using flakes and don't want to commit the plugin to Git (an especially bad idea if your config is public!), you can use requireFile and manually add files to the store. To do this, run <code>nix-hash --flat --type sha256 plugin.zip</code>, take the output, and use it in a derivation like so: | ||
| Line 87: | Line 86: | ||
}; | }; | ||
</syntaxhighlight> | </syntaxhighlight> | ||
[[Category:Audio]] | |||
[[Category:NixOS]] | |||