2022-05-26 22:22:43 +02:00
|
|
|
{ lib, vapoursynthPlugins, buildPythonPackage, fetchFromGitHub, python, vapoursynth }:
|
2021-01-23 19:55:21 +01:00
|
|
|
let
|
|
|
|
propagatedBinaryPlugins = with vapoursynthPlugins; [
|
|
|
|
adaptivegrain
|
|
|
|
addgrain
|
|
|
|
bm3d
|
|
|
|
descale
|
|
|
|
fmtconv
|
|
|
|
knlmeanscl
|
|
|
|
retinex
|
|
|
|
tcanny
|
|
|
|
wwxd
|
|
|
|
];
|
|
|
|
in
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "kagefunc";
|
2021-10-15 19:19:57 +02:00
|
|
|
version = "0.1.0";
|
2021-01-23 19:55:21 +01:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "Irrational-Encoding-Wizardry";
|
|
|
|
repo = pname;
|
2021-10-15 19:19:57 +02:00
|
|
|
rev = version;
|
|
|
|
sha256 = "sha256-9OpFSVLQspa6+xkCFqD5xeo3akCfwnpwtFuCCsQxAvQ=";
|
2021-01-23 19:55:21 +01:00
|
|
|
};
|
|
|
|
|
|
|
|
patches = [
|
|
|
|
./skip-opencl-test.diff
|
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = (with vapoursynthPlugins; [
|
|
|
|
fvsfunc
|
|
|
|
mvsfunc
|
|
|
|
vsutil
|
|
|
|
]) ++ propagatedBinaryPlugins;
|
|
|
|
|
|
|
|
format = "other";
|
|
|
|
|
|
|
|
installPhase = ''
|
2022-05-26 22:22:43 +02:00
|
|
|
install -D kagefunc.py $out/${python.sitePackages}/kagefunc.py
|
2021-01-23 19:55:21 +01:00
|
|
|
'';
|
|
|
|
|
|
|
|
checkInputs = [ (vapoursynth.withPlugins propagatedBinaryPlugins) ];
|
|
|
|
checkPhase = ''
|
2022-05-26 22:22:43 +02:00
|
|
|
PYTHONPATH=$out/${python.sitePackages}:$PYTHONPATH
|
2021-01-23 19:55:21 +01:00
|
|
|
python3 tests.py
|
|
|
|
'';
|
|
|
|
pythonImportsCheck = [ "kagefunc" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A collection of Vapoursynth functions.";
|
|
|
|
homepage = "https://github.com/Irrational-Encoding-Wizardry/kagefunc";
|
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ sbruder ];
|
|
|
|
platforms = platforms.all;
|
|
|
|
};
|
|
|
|
}
|