mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2025-01-27 23:44:04 +00:00
community/gmic to 2.7.0-1
This commit is contained in:
parent
082e4592c3
commit
53f41504d2
2 changed files with 26 additions and 42 deletions
|
@ -11,15 +11,15 @@ highmem=1
|
|||
|
||||
pkgbase=gmic
|
||||
pkgname=(gmic zart gimp-plugin-gmic krita-plugin-gmic)
|
||||
pkgver=2.6.7
|
||||
pkgver=2.7.0
|
||||
pkgrel=1
|
||||
arch=(x86_64)
|
||||
url="https://gmic.eu/"
|
||||
license=(custom:CeCILL)
|
||||
makedepends=(gimp qt5-base fftw openexr opencv eigen)
|
||||
source=(https://gmic.eu/files/source/gmic_$pkgver.tar.gz zart-opencv4.patch)
|
||||
sha256sums=('2e5535d1bae66254136e928428750aac8efcef6f4413fc352b6de9ce8ac8b0ff'
|
||||
'182c6723708302a8cee92bfb45a40ff09b8903c649ce856d0d8cd10aab0ee39b')
|
||||
sha256sums=('8629c39ca5fa02c44a462727d36f50557e1397af2feeddf39628608c028824d3'
|
||||
'f4295a2b9a6730060e1dd763c602bd5156570d623bc69c2214dfd11e94943296')
|
||||
|
||||
prepare() {
|
||||
sed -e 's|/etc/bash_completion.d|/usr/share/bash-completion/completions|g' -i gmic-$pkgver/src/Makefile
|
||||
|
@ -28,7 +28,8 @@ prepare() {
|
|||
-e 's/pkg-config opencv/pkg-config opencv4/' -i gmic-$pkgver/src/Makefile
|
||||
# fix build with openCV 4.0
|
||||
cd gmic-$pkgver/zart
|
||||
patch -p1 -i "$srcdir"/zart-opencv4.patch
|
||||
patch -p1 -i ../../zart-opencv4.patch
|
||||
sed -e 's|opencv|opencv4|' -i zart.pro
|
||||
|
||||
cd ..
|
||||
sed -i "s|-mtune=generic|${CFLAGS}|" src/Makefile
|
||||
|
|
|
@ -1,39 +1,22 @@
|
|||
diff --git a/include/VideoFileSource.h b/include/VideoFileSource.h
|
||||
index 0fda14e..8c15178 100644
|
||||
--- a/include/VideoFileSource.h
|
||||
+++ b/include/VideoFileSource.h
|
||||
@@ -50,6 +50,8 @@
|
||||
#if defined(HAS_OPENCV2_HEADERS) || defined(OPENCV2_HEADERS)
|
||||
#include <opencv2/core/core_c.h>
|
||||
#include <opencv2/highgui/highgui_c.h>
|
||||
+#include <opencv2/videoio.hpp>
|
||||
+#include <opencv2/videoio/videoio_c.h>
|
||||
#else
|
||||
#include <cv.h>
|
||||
#include <highgui.h>
|
||||
diff --git a/include/WebcamSource.h b/include/WebcamSource.h
|
||||
index 8c1911a..9194385 100644
|
||||
--- a/include/WebcamSource.h
|
||||
+++ b/include/WebcamSource.h
|
||||
@@ -51,6 +51,8 @@
|
||||
#if defined(HAS_OPENCV2_HEADERS) || defined(OPENCV2_HEADERS)
|
||||
#include <opencv2/core/core_c.h>
|
||||
#include <opencv2/highgui/highgui_c.h>
|
||||
+#include <opencv2/videoio.hpp>
|
||||
+#include <opencv2/videoio/videoio_c.h>
|
||||
#else
|
||||
#include <cv.h>
|
||||
#include <highgui.h>
|
||||
diff --git a/zart.pro b/zart.pro
|
||||
index d98a192..ddb2d3b 100644
|
||||
--- a/zart.pro
|
||||
+++ b/zart.pro
|
||||
@@ -19,7 +19,7 @@ greaterThan(QT_MAJOR_VERSION, 4): CONFIG += c++11
|
||||
CONFIG += warn_on
|
||||
QT_CONFIG -= no-pkg-config
|
||||
CONFIG += link_pkgconfig
|
||||
-PKGCONFIG += opencv fftw3 zlib
|
||||
+PKGCONFIG += opencv4 fftw3 zlib
|
||||
# LIBS += -lfftw3_threads
|
||||
DEFINES += cimg_use_fftw3 cimg_use_zlib
|
||||
diff --git a/src/ImageConverter.cpp b/src/ImageConverter.cpp
|
||||
index dc7605b..56f59db 100644
|
||||
--- a/src/ImageConverter.cpp
|
||||
+++ b/src/ImageConverter.cpp
|
||||
@@ -70,7 +70,7 @@ void ImageConverter::convert(const cv::Mat * in, QImage * out)
|
||||
|
||||
cv::Mat tmp(in->cols, in->rows, in->depth());
|
||||
|
||||
- cvtColor(*in, tmp, (in->channels() == 1) ? CV_GRAY2RGB : CV_BGR2RGB);
|
||||
+ cvtColor(*in, tmp, (in->channels() == 1) ? cv::COLOR_GRAY2RGB : cv::COLOR_BGR2RGB);
|
||||
|
||||
const unsigned int w3 = 3 * tmp.cols;
|
||||
unsigned char * src = reinterpret_cast<unsigned char *>(tmp.ptr());
|
||||
@@ -106,7 +106,7 @@ void ImageConverter::convert(const QImage & in, cv::Mat ** out)
|
||||
dst += step;
|
||||
}
|
||||
}
|
||||
- cvtColor(**out, **out, CV_BGR2RGB);
|
||||
+ cvtColor(**out, **out, cv::COLOR_BGR2RGB);
|
||||
}
|
||||
|
||||
void ImageConverter::convert(const cimg_library::CImg<float> & in, QImage * out)
|
||||
|
|
Loading…
Reference in a new issue