Skip to content

Commit

Permalink
feat(futomaki): init OBS + config for iPhone webcam
Browse files Browse the repository at this point in the history
  • Loading branch information
nekowinston committed Feb 4, 2025
1 parent 382b321 commit 9a06107
Showing 1 changed file with 30 additions and 16 deletions.
46 changes: 30 additions & 16 deletions machines/futomaki/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
{ pkgs, ... }:
{
config,
lib,
pkgs,
...
}:
{
imports = [
./hardware.nix
Expand Down Expand Up @@ -32,21 +37,30 @@

virtualisation.podman.enable = true;

environment.systemPackages = with pkgs; [
(pkgs.wrapOBS {
plugins = with pkgs.obs-studio-plugins; [
input-overlay
obs-backgroundremoval
obs-composite-blur
obs-gstreamer
obs-move-transition
obs-pipewire-audio-capture
obs-vaapi
obs-vkcapture
wlrobs
];
})
];
programs.obs-studio = {
enable = true;
plugins = with pkgs.obs-studio-plugins; [
input-overlay
obs-backgroundremoval
obs-composite-blur
obs-gstreamer
obs-move-transition
obs-pipewire-audio-capture
obs-vaapi
obs-vkcapture
wlrobs
];
};
boot = lib.mkIf config.programs.obs-studio.enable {
kernelModules = [ "v4l2loopback" ];
extraModulePackages = [ config.boot.kernelPackages.v4l2loopback ];

# extra config for the v4l2loopback module,
# allowing for an extra loopback device created via gstreamer
extraModprobeConfig = ''
options v4l2loopback devices=2 video_nr=1,2 card_label="OBS Virtual Camera","iPhone Magic Webcam" exclusive_caps=1,1
'';
};

system.stateVersion = "24.11";
}

0 comments on commit 9a06107

Please sign in to comment.