From 8b0215f79c3d300af37fcf686cd62ea5628c7d27 Mon Sep 17 00:00:00 2001 From: Martin Wimpress Date: Wed, 26 Apr 2023 22:56:29 +0100 Subject: [PATCH] obs-studio-plugins.obs-shaderfilter: init at v1.22 --- .../video/obs-studio/plugins/default.nix | 2 + .../obs-studio/plugins/obs-shaderfilter.nix | 41 +++++++++++++++++++ 2 files changed, 43 insertions(+) create mode 100644 pkgs/applications/video/obs-studio/plugins/obs-shaderfilter.nix diff --git a/pkgs/applications/video/obs-studio/plugins/default.nix b/pkgs/applications/video/obs-studio/plugins/default.nix index 90206246b38e..65c2ecfd5d79 100644 --- a/pkgs/applications/video/obs-studio/plugins/default.nix +++ b/pkgs/applications/video/obs-studio/plugins/default.nix @@ -32,6 +32,8 @@ obs-pipewire-audio-capture = callPackage ./obs-pipewire-audio-capture.nix { }; + obs-shaderfilter = qt6Packages.callPackage ./obs-shaderfilter.nix { }; + obs-source-clone = callPackage ./obs-source-clone.nix { }; obs-source-record = callPackage ./obs-source-record.nix { }; diff --git a/pkgs/applications/video/obs-studio/plugins/obs-shaderfilter.nix b/pkgs/applications/video/obs-studio/plugins/obs-shaderfilter.nix new file mode 100644 index 000000000000..ea412261e0ab --- /dev/null +++ b/pkgs/applications/video/obs-studio/plugins/obs-shaderfilter.nix @@ -0,0 +1,41 @@ +{ lib +, stdenv +, fetchFromGitHub +, cmake +, obs-studio +, qtbase +}: + +stdenv.mkDerivation rec { + pname = "obs-shaderfilter"; + version = "v1.22"; + + src = fetchFromGitHub { + owner = "exeldro"; + repo = "obs-shaderfilter"; + rev = version; + sha256 = "sha256-CqqYzGRhlHO8Zva+so8uo9+EIlzTfoFVl3NzZMsE7Xc="; + }; + + nativeBuildInputs = [ cmake ]; + buildInputs = [ obs-studio qtbase ]; + + cmakeFlags = [ + "-DBUILD_OUT_OF_TREE=On" + ]; + + dontWrapQtApps = true; + + postInstall = '' + rm -rf $out/obs-plugins + mv $out/data $out/share/obs + ''; + + meta = with lib; { + description = "OBS Studio filter for applying an arbitrary shader to a source."; + homepage = "https://github.com/exeldro/obs-shaderfilter"; + maintainers = with maintainers; [ flexiondotorg ]; + license = licenses.gpl2Plus; + platforms = [ "x86_64-linux" "i686-linux" ]; + }; +}