2009-06-14 01:30:12 +00:00
|
|
|
# install these packages into your profile. Then add
|
|
|
|
# ~/.nix-profile/gimp-version-plugins to your plugin list you can find at
|
|
|
|
# preferences -> Folders -> Plug-ins
|
|
|
|
# same applies for the scripts
|
|
|
|
|
|
|
|
{ pkgs, gimp }:
|
|
|
|
let
|
2017-05-04 13:44:59 +00:00
|
|
|
inherit (pkgs) stdenv fetchurl pkgconfig intltool glib fetchFromGitHub;
|
2016-02-25 21:24:45 +00:00
|
|
|
inherit (gimp) targetPluginDir targetScriptDir;
|
2009-06-14 01:30:12 +00:00
|
|
|
|
|
|
|
pluginDerivation = a: stdenv.mkDerivation ({
|
|
|
|
prePhases = "extraLib";
|
|
|
|
extraLib = ''
|
|
|
|
installScripts(){
|
2017-12-22 07:59:08 +00:00
|
|
|
mkdir -p $out/${targetScriptDir};
|
|
|
|
for p in "$@"; do cp "$p" $out/${targetScriptDir}; done
|
2009-06-14 01:30:12 +00:00
|
|
|
}
|
|
|
|
installPlugins(){
|
2017-12-22 07:59:08 +00:00
|
|
|
mkdir -p $out/${targetPluginDir};
|
|
|
|
for p in "$@"; do cp "$p" $out/${targetPluginDir}; done
|
2009-06-14 01:30:12 +00:00
|
|
|
}
|
|
|
|
'';
|
|
|
|
}
|
|
|
|
// a
|
|
|
|
# don't call this gimp-* unless you want nix replace gimp by a plugin :-)
|
2017-05-01 14:52:29 +00:00
|
|
|
// {
|
|
|
|
name = "${a.name}-${gimp.name}-plugin";
|
2017-05-02 06:26:10 +00:00
|
|
|
buildInputs = [ gimp gimp.gtk glib ] ++ (a.buildInputs or []);
|
2017-05-04 13:44:59 +00:00
|
|
|
nativeBuildInputs = [ pkgconfig intltool ] ++ (a.nativeBuildInputs or []);
|
2017-05-01 14:52:29 +00:00
|
|
|
}
|
2009-06-14 01:30:12 +00:00
|
|
|
);
|
|
|
|
|
|
|
|
scriptDerivation = {name, src} : pluginDerivation {
|
|
|
|
inherit name; phases = "extraLib installPhase";
|
|
|
|
installPhase = "installScripts ${src}";
|
|
|
|
};
|
|
|
|
|
|
|
|
in
|
|
|
|
rec {
|
2010-02-11 15:08:05 +00:00
|
|
|
gap = pluginDerivation {
|
|
|
|
/* menu:
|
|
|
|
Video
|
|
|
|
*/
|
|
|
|
name = "gap-2.6.0";
|
|
|
|
src = fetchurl {
|
2016-02-25 21:22:12 +00:00
|
|
|
url = http://ftp.gimp.org/pub/gimp/plug-ins/v2.6/gap/gimp-gap-2.6.0.tar.bz2;
|
2010-02-11 15:08:05 +00:00
|
|
|
sha256 = "1jic7ixcmsn4kx2cn32nc5087rk6g8xsrz022xy11yfmgvhzb0ql";
|
|
|
|
};
|
|
|
|
patchPhase = ''
|
|
|
|
sed -e 's,^\(GIMP_PLUGIN_DIR=\).*,\1'"$out/${gimp.name}-plugins", \
|
|
|
|
-e 's,^\(GIMP_DATA_DIR=\).*,\1'"$out/share/${gimp.name}", -i configure
|
|
|
|
'';
|
2016-10-13 20:50:55 +00:00
|
|
|
hardeningDisable = [ "format" ];
|
2015-05-27 19:56:04 +00:00
|
|
|
meta = with stdenv.lib; {
|
2010-02-11 15:08:05 +00:00
|
|
|
description = "The GIMP Animation Package";
|
|
|
|
homepage = http://www.gimp.org;
|
|
|
|
# The main code is given in GPLv3, but it has ffmpeg in it, and I think ffmpeg license
|
|
|
|
# falls inside "free".
|
2015-05-27 19:56:04 +00:00
|
|
|
license = with licenses; [ gpl3 free ];
|
2010-02-11 15:08:05 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2013-11-10 19:16:37 +00:00
|
|
|
fourier = pluginDerivation rec {
|
2009-06-14 01:30:12 +00:00
|
|
|
/* menu:
|
|
|
|
Filters/Generic/FFT Forward
|
|
|
|
Filters/Generic/FFT Inverse
|
|
|
|
*/
|
2013-11-10 19:16:37 +00:00
|
|
|
name = "fourier-0.4.1";
|
2017-05-02 06:26:10 +00:00
|
|
|
buildInputs = with pkgs; [ fftw ];
|
2009-06-14 01:30:12 +00:00
|
|
|
postInstall = "fail";
|
|
|
|
installPhase = "installPlugins fourier";
|
|
|
|
src = fetchurl {
|
2013-11-10 19:16:37 +00:00
|
|
|
url = "http://registry.gimp.org/files/${name}.tar.gz";
|
|
|
|
sha256 = "1pr3y3zl9w8xs1circdrxpr98myz9m8wfzy022al79z4pdanwvs1";
|
2009-06-14 01:30:12 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2014-07-20 19:28:50 +00:00
|
|
|
focusblur = pluginDerivation rec {
|
|
|
|
/* menu:
|
|
|
|
Blur/Focus Blur
|
|
|
|
*/
|
|
|
|
name = "focusblur-3.2.6";
|
2017-05-02 06:26:10 +00:00
|
|
|
buildInputs = with pkgs; [ fftwSinglePrec ];
|
2014-07-20 19:28:50 +00:00
|
|
|
patches = [ ./patches/focusblur-glib.patch ];
|
|
|
|
postInstall = "fail";
|
|
|
|
installPhase = "installPlugins src/focusblur";
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://registry.gimp.org/files/${name}.tar.bz2";
|
|
|
|
sha256 = "1gqf3hchz7n7v5kpqkhqh8kwnxbsvlb5cr2w2n7ngrvl56f5xs1h";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2009-06-14 01:30:12 +00:00
|
|
|
resynthesizer = pluginDerivation {
|
|
|
|
/* menu:
|
|
|
|
Filters/Map/Resynthesize
|
|
|
|
Filters/Enhance/Smart enlarge
|
|
|
|
Filters/Enhance/Smart sharpen
|
|
|
|
Filters/Enhance/Smart remove selection
|
|
|
|
*/
|
|
|
|
name = "resynthesizer-0.16";
|
2017-05-01 14:52:29 +00:00
|
|
|
buildInputs = with pkgs; [ fftw ];
|
2009-06-14 01:30:12 +00:00
|
|
|
src = fetchurl {
|
|
|
|
url = http://www.logarithmic.net/pfh-files/resynthesizer/resynthesizer-0.16.tar.gz;
|
|
|
|
sha256 = "1k90a1jzswxmajn56rdxa4r60v9v34fmqsiwfdxqcvx3yf4yq96x";
|
|
|
|
};
|
|
|
|
|
|
|
|
installPhase = "
|
|
|
|
installPlugins resynth
|
|
|
|
installScripts smart-{enlarge,remove}.scm
|
|
|
|
";
|
|
|
|
};
|
|
|
|
|
2016-10-11 17:57:26 +00:00
|
|
|
resynthesizer2 = pluginDerivation {
|
|
|
|
/* menu:
|
|
|
|
Filters/Map/Resynthesize
|
|
|
|
Filters/Enhance/Smart enlarge
|
|
|
|
Filters/Enhance/Smart sharpen
|
|
|
|
Filters/Enhance/Smart remove selection
|
|
|
|
*/
|
|
|
|
name = "resynthesizer-2.0.1";
|
2017-05-02 06:26:10 +00:00
|
|
|
buildInputs = with pkgs; [ fftw ];
|
2017-05-04 13:44:59 +00:00
|
|
|
nativeBuildInputs = with pkgs; [ autoreconfHook ];
|
2016-10-11 17:57:26 +00:00
|
|
|
makeFlags = "GIMP_LIBDIR=$out/lib/gimp/2.0/";
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "bootchk";
|
|
|
|
repo = "resynthesizer";
|
|
|
|
rev = "2.0.1";
|
|
|
|
sha256 = "1d214s0jsqxz83l9dd8vhnz3siw9fyw7xdhhir25ra7jiwxc99hd";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2009-06-14 01:30:12 +00:00
|
|
|
texturize = pluginDerivation {
|
2017-11-16 00:55:49 +00:00
|
|
|
name = "texturize-2.2.2017-07-28";
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "lmanul";
|
|
|
|
repo = "gimp-texturize";
|
|
|
|
rev = "de4367f71e40fe6d82387eaee68611a80a87e0e1";
|
|
|
|
sha256 = "1zzvbczly7k456c0y6s92a1i8ph4ywmbvdl8i4rcc29l4qd2z8fw";
|
2009-06-14 01:30:12 +00:00
|
|
|
};
|
|
|
|
installPhase = "installPlugins src/texturize";
|
|
|
|
};
|
|
|
|
|
|
|
|
waveletSharpen = pluginDerivation {
|
|
|
|
/* menu:
|
|
|
|
Filters/Enhance/Wavelet sharpen
|
|
|
|
*/
|
|
|
|
name = "wavelet-sharpen-0.1.2";
|
|
|
|
src = fetchurl {
|
|
|
|
url = http://registry.gimp.org/files/wavelet-sharpen-0.1.2.tar.gz;
|
|
|
|
sha256 = "0vql1k67i21g5ivaa1jh56rg427m0icrkpryrhg75nscpirfxxqw";
|
|
|
|
};
|
|
|
|
installPhase = "installPlugins src/wavelet-sharpen"; # TODO translations are not copied .. How to do this on nix?
|
|
|
|
};
|
|
|
|
|
|
|
|
lqrPlugin = pluginDerivation {
|
|
|
|
/* menu:
|
|
|
|
Layer/Liquid Rescale
|
|
|
|
*/
|
|
|
|
name = "lqr-plugin-0.6.1";
|
2018-04-12 20:02:37 +00:00
|
|
|
buildInputs = with pkgs; [ liblqr1 ];
|
2009-06-14 01:30:12 +00:00
|
|
|
src = fetchurl {
|
|
|
|
url = http://registry.gimp.org/files/gimp-lqr-plugin-0.6.1.tar.bz2;
|
|
|
|
sha256 = "00hklkpcimcbpjly4rjhfipaw096cpy768g9wixglwrsyqhil7l9";
|
|
|
|
};
|
2018-04-12 20:02:37 +00:00
|
|
|
#postInstall = ''mkdir -p $out/nix-support; echo "${liblqr1}" > "$out/nix-support/propagated-user-env-packages"'';
|
2009-06-14 01:30:12 +00:00
|
|
|
installPhase = "installPlugins src/gimp-lqr-plugin";
|
|
|
|
};
|
|
|
|
|
2009-06-26 16:52:35 +00:00
|
|
|
gmic =
|
2015-07-16 16:00:45 +00:00
|
|
|
pluginDerivation rec {
|
2017-02-10 17:56:46 +00:00
|
|
|
inherit (pkgs.gmic) name src meta;
|
2015-07-16 16:00:45 +00:00
|
|
|
|
2017-05-01 14:52:29 +00:00
|
|
|
buildInputs = with pkgs; [ fftw opencv curl ];
|
2015-07-16 16:00:45 +00:00
|
|
|
|
2013-11-10 22:33:45 +00:00
|
|
|
sourceRoot = "${name}/src";
|
2015-07-16 16:00:45 +00:00
|
|
|
|
|
|
|
buildFlags = "gimp";
|
|
|
|
|
2013-11-10 22:33:45 +00:00
|
|
|
installPhase = "installPlugins gmic_gimp";
|
2009-06-26 16:52:35 +00:00
|
|
|
};
|
|
|
|
|
2018-04-29 00:59:26 +00:00
|
|
|
ufraw = pkgs.ufraw.gimpPlugin;
|
2009-06-30 16:14:34 +00:00
|
|
|
|
2011-09-03 17:31:10 +00:00
|
|
|
gimplensfun = pluginDerivation rec {
|
2016-11-11 10:27:08 +00:00
|
|
|
version = "0.2.4";
|
|
|
|
name = "gimplensfun-${version}";
|
2011-09-03 17:31:10 +00:00
|
|
|
|
2016-11-11 10:27:08 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "seebk";
|
|
|
|
repo = "GIMP-Lensfun";
|
|
|
|
rev = version;
|
|
|
|
sha256 = "0zlmp9v732qmzj083mnk5z421s57mnckmpjhiw890wmmwzj2lhxz";
|
2011-09-03 17:31:10 +00:00
|
|
|
};
|
|
|
|
|
2017-05-01 14:52:29 +00:00
|
|
|
buildInputs = with pkgs; [ lensfun exiv2 ];
|
2011-09-03 17:31:10 +00:00
|
|
|
|
|
|
|
installPhase = "
|
2016-11-11 10:27:08 +00:00
|
|
|
installPlugins gimp-lensfun
|
2011-09-03 17:31:10 +00:00
|
|
|
";
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "GIMP plugin to correct lens distortion using the lensfun library and database";
|
|
|
|
|
|
|
|
homepage = http://lensfun.sebastiankraft.net/;
|
|
|
|
|
2014-06-19 04:19:00 +00:00
|
|
|
license = stdenv.lib.licenses.gpl3Plus;
|
2015-01-13 21:33:24 +00:00
|
|
|
maintainers = [ ];
|
2011-09-03 17:31:10 +00:00
|
|
|
platforms = stdenv.lib.platforms.gnu;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2009-06-14 01:30:12 +00:00
|
|
|
/* =============== simple script files ==================== */
|
|
|
|
|
2015-11-14 20:32:51 +00:00
|
|
|
# also have a look at enblend-enfuse in all-packages.nix
|
2009-06-30 16:14:34 +00:00
|
|
|
exposureBlend = scriptDerivation {
|
|
|
|
name = "exposure-blend";
|
|
|
|
src = fetchurl {
|
|
|
|
url = http://tir.astro.utoledo.edu/jdsmith/code/eb/exposure-blend.scm;
|
|
|
|
sha256 = "1b6c9wzpklqras4wwsyw3y3jp6fjmhnnskqiwm5sabs8djknfxla";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2009-06-14 01:30:12 +00:00
|
|
|
lightning = scriptDerivation {
|
|
|
|
name = "Lightning";
|
|
|
|
src = fetchurl {
|
|
|
|
url = http://registry.gimp.org/files/Lightning.scm;
|
|
|
|
sha256 = "c14a8f4f709695ede3f77348728a25b3f3ded420da60f3f8de3944b7eae98a49";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
/* space in name trouble ?
|
|
|
|
|
|
|
|
rainbowPlasma = scriptDerivation {
|
|
|
|
# http://registry.gimp.org/node/164
|
|
|
|
name = "rainbow-plasma";
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://registry.gimp.org/files/Rainbow Plasma.scm";
|
|
|
|
sha256 = "34308d4c9441f9e7bafa118af7ec9540f10ea0df75e812e2f3aa3fd7b5344c23";
|
|
|
|
name = "Rainbow-Plasma.scm"; # nix doesn't like spaces, does it?
|
|
|
|
};
|
|
|
|
};
|
|
|
|
*/
|
|
|
|
|
|
|
|
/* doesn't seem to be working :-(
|
|
|
|
lightningGate = scriptDerivation {
|
|
|
|
# http://registry.gimp.org/node/153
|
|
|
|
name = "lightning-gate";
|
|
|
|
src = fetchurl {
|
|
|
|
url = http://registry.gimp.org/files/LightningGate.scm;
|
|
|
|
sha256 = "181w1zi9a99kn2mfxjp43wkwcgw5vbb6iqjas7a9mhm8p04csys2";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
*/
|
|
|
|
|
|
|
|
}
|