Files
dotfiles/modules/system/camera.nix
T
2026-05-30 19:03:33 +09:00

36 lines
578 B
Nix

{
pkgs,
lib,
config,
...
}:
let
cfg = config.my.system.camera;
in
{
options.my.system.camera = {
enable = lib.mkEnableOption "camera support";
};
config = lib.mkIf cfg.enable {
boot.kernelModules = [ "uvcvideo" ];
environment.systemPackages = with pkgs; [
v4l-utils
ffmpeg-full
];
services.pipewire = {
enable = true;
alsa.enable = true;
pulse.enable = true;
};
security.rtkit.enable = true;
xdg.portal = {
enable = true;
extraPortals = [ pkgs.xdg-desktop-portal-gtk ];
};
};
}