SHARE
TWEET

gimp-elsamuko-plugins - without elsamuko-eaw-sharpen

MuadDib84 Apr 13th, 2020 (edited) 8 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. # Maintainer: Piotr Rogoża <piotr.r.public at gmail dot com>
  2. # Contributor: Piotr Rogoża <piotr.r.public at gmail dot com>
  3. # edited by MuadDib 2020-04-13
  4.  
  5.  
  6. pkgbase=gimp-elsamuko-plugins
  7. # AUR workaround
  8. pkgname=gimp-elsamuko-plugins
  9. true && pkgname=(
  10. gimp-elsamuko-plugins
  11. gimp-plugin-depthmap
  12. gimp-plugin-copy-move
  13. gimp-plugin-octave
  14. gimp-plugin-temperature
  15. gimp-plugin-facedetect
  16. gimp-plugin-get-curves
  17. gimp-plugin-heatmap
  18. gimp-plugin-hsv-analysis
  19. gimp-plugin-lab-analysis
  20. )
  21. pkgver=0.1
  22. pkgrel=7
  23. arch=(i686 x86_64)
  24. url='https://sites.google.com/site/elsamuko/gimp'
  25. pkgdesc='Varoius Gimp plugins made by elsamuko'
  26. license=('GPL')
  27. depends=(gimp)
  28. makedepends=(
  29. gimp
  30. opencv2-opt
  31. unzip
  32. cimg
  33. )
  34. source=(
  35. https://sites.google.com/site/elsamuko/gimp/depthmap/elsamuko-depthmap-cv.tar.gz
  36. depthmap-cv.patch
  37. https://sites.google.com/site/elsamuko/forensics/clone-detection/elsamuko-copy-move.c
  38. # copymove2-0.6.0.tar.gz::https://github.com/elsamuko/copymove2/archive/v0.6.0.tar.gz
  39. https://sites.google.com/site/elsamuko/gimp/gimp-octave/elsamuko-gimp-octave.c
  40. https://sites.google.com/site/elsamuko/gimp/gimp-octave/filter_pack.tar.gz
  41. https://sites.google.com/site/elsamuko/gimp/temperature/elsamuko-temperature.c
  42. https://sites.google.com/site/elsamuko/gimp/facedetect/elsamuko-facedetect-cv.tar.gz
  43. face-detect-cv.patch
  44. https://sites.google.com/site/elsamuko/gimp/get-curves/elsamuko-get-curves.c
  45. https://sites.google.com/site/elsamuko/gimp/get-curves/AlienSkin-examples.zip
  46. https://sites.google.com/site/elsamuko/gimp/get-curves/elsamuko-kodachrome
  47. https://sites.google.com/site/elsamuko/gimp/heatmap/elsamuko-heatmap.c
  48. https://sites.google.com/site/elsamuko/forensics/hsv-analysis/elsamuko-hsv-analysis.c
  49. https://sites.google.com/site/elsamuko/forensics/lab-analysis/elsamuko-lab-analysis.tar.gz
  50. cimg.patch
  51. )
  52. sha256sums=('37081258b6401bcc095d86b3a313b8fc4691f2f70b75e60d6f96be26ab1eb963'
  53.             'f93871dbc6c05a00c5232412422bed81021b9a9cd5b2969f7b9f5f3740c98611'
  54.             '2cfa1516ab49d1f8d94168c694219be940c2154f4128e3b3e77a8a24e8940312'
  55.             '890e94b870278f49c1291eeb56efdcb6bffdfd8a5e6cba210dc7b47947f5bf2a'
  56.             '20c8ec08587d61d87e91989a9655d693904eb56f402c1eb574c5e4c3a13d4ad1'
  57.             'e548334b3aebc039a2ac92d1f24d0323ced5163acdfa47399e727a7853f469ed'
  58.             'f06daefe35132d87734b3854a58fa0847b7b313b86ae9f076883b651a0592d16'
  59.             '1f19dcd27e204e4f16114443eb071617270aca8ae38f3c2cbcd3372712dbd289'
  60.             '58a136880bc4c83b768663caf28bd9aedfc3dca2bfb845d44d3f099926e98a80'
  61.             '14cca94597b688aa6f2d4fff2bf807a3f9a0e7163dff897129dc685148029f6f'
  62.             'c8ccb4ee657e24d89ff9e3bb279cc6f552d8d4e3e3e8d76a107c763eafd58d91'
  63.             'f3514a0a99c2e9ebe318402f8bf1800cd11845f286763bbc5b33de38b22141d4'
  64.             '6437349ceba4a7923bb66eae5d69f0a8077137fa340d4460d71295dbaa1bdbec'
  65.             '2aa644462f919e77f8dd370dd3ed7a72f1c875f4227e99f520c89dd9a9186884'
  66.             '2cbc494ac75df79f9c783fdbf5faf5ce69548a3c711b023e300cddb7047264bf')
  67. noextract=(AlienSkin-examples.zip)
  68. # env
  69. _pluginsdir_eval='_pluginsdir="$pkgdir"/usr/lib/gimp/2.0/plug-ins'
  70. _curvesdir_eval='_curvesdir="$pkgdir"/usr/share/$pkgname/examples/curves'
  71. prepare() {
  72.   cd "$srcdir"
  73.   patch -Np1 -i depthmap-cv.patch
  74.   patch -Np1 -i face-detect-cv.patch
  75.   cd "$srcdir"/elsamuko-lab-analysis
  76.   patch -Np1 -i "$srcdir"/cimg.patch
  77.   msg2 "Fixing depthmap-cv"
  78.   cd "$srcdir"/elsamuko-depthmap-cv
  79.   sed '16 s/^/#/' -i Makefile
  80.   sed 's/opencv/opencv2/g' -i Makefile
  81. }
  82. build() {
  83.   cd "$srcdir"
  84.  
  85.   # octave, get-curves, hsv-analysis
  86.   msg2 "Building octave plugin"
  87.   gimptool --build elsamuko-gimp-octave.c
  88.   msg2 "Building get-curves plugin"
  89.   gimptool --build elsamuko-get-curves.c
  90.   msg2 "Building hsv-analysis plugin"
  91.   gimptool --build elsamuko-hsv-analysis.c
  92.   # heatmap
  93.   msg2 "Building heatmap plugin"
  94.   CC='gcc -lm' gimptool --build elsamuko-heatmap.c
  95.   # copy-move
  96.   msg2 "Building copy-move plugin"
  97.   CC=g++ CFLAGS=-O3 LIBS=-lpthread gimptool --build elsamuko-copy-move.c
  98.   # temperature
  99.   msg2 "Building temperature plugin"
  100.   CC="g++ -O3 -Wno-narrowing" gimptool --build elsamuko-temperature.c
  101.   # eaw-sharpen
  102.   # depthmap-cv
  103.   msg2 "Building depthmap-cv plugin"
  104.   cd "$srcdir"/elsamuko-depthmap-cv
  105. #   gimptool --build elsamuko-depthmap-cv.c
  106.   make
  107.   # face-detect-cv
  108.   msg2 "Building face-detect-cv plugin"
  109.   cd "$srcdir"/elsamuko-facedetect-cv
  110.   make
  111.   # lab-analysis
  112.   msg2 "Building lab-analysis plugin"
  113.   cd "$srcdir"/elsamuko-lab-analysis
  114.   CC='g++ -lX11' CFLAGS=-O3 gimptool --build elsamuko-lab-analysis.c
  115. }
  116. package_gimp-elsamuko-plugins(){
  117.   true && pkgdesc='Varoius Gimp plugins made by elsamuko, transition package to split build'
  118. }
  119. package_gimp-plugin-depthmap (){
  120.   true && pkgdesc="Generates a depthmap out of two stereoscopic images."
  121.   true && url='https://sites.google.com/site/elsamuko/gimp/depthmap'
  122.   true && depends=(gimp-elsamuko-plugins opencv2-opt)
  123.   eval $_pluginsdir_eval
  124.   cd "$srcdir"/elsamuko-depthmap-cv
  125.   install -dm755 "${_pluginsdir}"
  126.   install -Dm755 elsamuko-depthmap-cv "$_pluginsdir"/
  127. }
  128. package_gimp-plugin-copy-move (){
  129.   true && pkgdesc="Detects image manipulations which have been created with the clone tool"
  130.   true && url='https://sites.google.com/site/elsamuko/forensics/clone-detection'
  131.   true && depends=(gimp-elsamuko-plugins)
  132.   eval $_pluginsdir_eval
  133.   cd "$srcdir"
  134.   install -dm755 "${_pluginsdir}"
  135.   install -Dm755 elsamuko-copy-move "$_pluginsdir"/
  136. }
  137. package_gimp-plugin-octave (){
  138.   true && pkgdesc="Provides a simple interface between GIMP and GNU Octave"
  139.   true && url='https://sites.google.com/site/elsamuko/gimp/gimp-octave'
  140.   true && optdepends=('octave-image: run Octave script in the Gimp')
  141.   true && depends=(gimp-elsamuko-plugins)
  142.   install='gimp-plugin-octave.install'
  143.   eval $_pluginsdir_eval
  144.   cd "$srcdir"
  145.   install -dm755 "${_pluginsdir}"
  146.   install -Dm755 elsamuko-gimp-octave "$_pluginsdir"/
  147.   # examples .m files
  148.   install -dm755 "$pkgdir"/usr/share/$pkgname/examples
  149.   cp -r filter_pack "$pkgdir"/usr/share/$pkgname/examples
  150.   # doc files
  151.   install -dm755 "$pkgdir"/usr/share/doc/$pkgname
  152.   mv "$pkgdir"/usr/share/$pkgname/examples/filter_pack/README \
  153.     "$pkgdir"/usr/share/doc/$pkgname/octave-plugin.README
  154.  
  155. }
  156. package_gimp-plugin-temperature (){
  157.   true && pkgdesc="Changes the color temperature of an image via shifting it in the YUV color space"
  158.   true && url='https://sites.google.com/site/elsamuko/gimp/temperature'
  159.   true && depends=(gimp-elsamuko-plugins opencv2-opt)
  160.   eval $_pluginsdir_eval
  161.   cd "$srcdir"
  162.   install -dm755 "${_pluginsdir}"
  163.   install -Dm755 elsamuko-temperature "$_pluginsdir"/
  164. }
  165. package_gimp-plugin-facedetect (){
  166.   true && pkgdesc="Detects faces in an input image"
  167.   true && url='https://sites.google.com/site/elsamuko/gimp/facedetect'
  168.   true && depends=(gimp-elsamuko-plugins opencv2-opt)
  169.   eval $_pluginsdir_eval
  170.   cd "$srcdir"/elsamuko-facedetect-cv
  171.   install -dm755 "${_pluginsdir}"
  172.   install -Dm755 elsamuko-facedetect-cv "$_pluginsdir"/
  173.   install -Dm644 haarcascade_frontalface_alt.xml "$_pluginsdir"/
  174. }
  175. package_gimp-plugin-get-curves (){
  176.   true && pkgdesc="Calculates the color curve from two different pictures"
  177.   true && url='https://sites.google.com/site/elsamuko/gimp/get-curves'
  178.   true && depends=(gimp-elsamuko-plugins)
  179.   install='gimp-plugin-get-curves.install'
  180.   _pluginsdir="$pkgdir"/usr/lib/gimp/2.0/plug-ins
  181.   eval $_pluginsdir_eval $_curvesdir_eval
  182.   cd "$srcdir"
  183.   install -dm755 "$_curvesdir"
  184.   unzip -q AlienSkin-examples.zip -d ${_curvesdir}
  185.  
  186.   install -dm755 "${_pluginsdir}"
  187.   install -Dm755 elsamuko-get-curves "$_pluginsdir"/
  188.   # GIMP curves tool settings
  189.   install -Dm644 "$srcdir"/elsamuko-kodachrome "$_curvesdir"/
  190.   chmod 0644 "$_curvesdir"/*
  191. }
  192. package_gimp-plugin-heatmap (){
  193.   true && pkgdesc="Calculates a heatmap from a picture"
  194.   true && url='https://sites.google.com/site/elsamuko/gimp/heatmap'
  195.   true && depends=(gimp-elsamuko-plugins)
  196.   eval $_pluginsdir_eval
  197.   cd "$srcdir"
  198.   install -dm755 "${_pluginsdir}"
  199.   install -Dm755 elsamuko-heatmap "$_pluginsdir"/
  200. }
  201. package_gimp-plugin-hsv-analysis (){
  202.   true && pkgdesc="HSV analysis"
  203.   true && url='https://sites.google.com/site/elsamuko/forensics/hsv-analysis'
  204.   true && depends=(gimp-elsamuko-plugins)
  205.   eval $_pluginsdir_eval
  206.   cd "$srcdir"
  207.   install -dm755 "${_pluginsdir}"
  208.   install -Dm755 elsamuko-hsv-analysis "$_pluginsdir"/
  209. }
  210. package_gimp-plugin-lab-analysis (){
  211.   true && pkgdesc="LAB analysis"
  212.   true && url='https://sites.google.com/site/elsamuko/forensics/lab-analysis'
  213.   true && depends=(gimp-elsamuko-plugins)
  214.   eval $_pluginsdir_eval
  215.   cd "$srcdir"/elsamuko-lab-analysis
  216.   install -dm755 "${_pluginsdir}"
  217.   install -Dm755 elsamuko-lab-analysis "$_pluginsdir"/
  218. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top