Backport patch to fix build from upstream git master
This commit is contained in:
parent
e11a841058
commit
74a653ff8d
|
@ -0,0 +1,139 @@
|
|||
From 81958d302494e137f98a8b1d7869841532f90388 Mon Sep 17 00:00:00 2001
|
||||
From: JaimeIvanCervantes <jimmycc80@hotmail.com>
|
||||
Date: Fri, 16 Jun 2017 13:21:45 -0700
|
||||
Subject: [PATCH] multi_convolution: Fix for incorrect template parameter type
|
||||
when using unsigned int N for TinyVector SIZE. (Fixes #414)
|
||||
|
||||
---
|
||||
include/vigra/multi_convolution.hxx | 28 ++++++++++++++--------------
|
||||
1 file changed, 14 insertions(+), 14 deletions(-)
|
||||
|
||||
diff --git a/include/vigra/multi_convolution.hxx b/include/vigra/multi_convolution.hxx
|
||||
index 1b5efa740..ec89bcf58 100644
|
||||
--- a/include/vigra/multi_convolution.hxx
|
||||
+++ b/include/vigra/multi_convolution.hxx
|
||||
@@ -1426,7 +1426,7 @@ gaussianSmoothMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
class T2, class S2>
|
||||
void
|
||||
gaussianGradientMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
- MultiArrayView<N, TinyVector<T2, N>, S2> dest,
|
||||
+ MultiArrayView<N, TinyVector<T2, int(N)>, S2> dest,
|
||||
double sigma,
|
||||
ConvolutionOptions<N> opt = ConvolutionOptions<N>());
|
||||
|
||||
@@ -1435,7 +1435,7 @@ gaussianSmoothMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
class T2, class S2>
|
||||
void
|
||||
gaussianGradientMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
- MultiArrayView<N, TinyVector<T2, N>, S2> dest,
|
||||
+ MultiArrayView<N, TinyVector<T2, int(N)>, S2> dest,
|
||||
ConvolutionOptions<N> opt);
|
||||
|
||||
// likewise, but execute algorithm in parallel
|
||||
@@ -1443,7 +1443,7 @@ gaussianSmoothMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
class T2, class S2>
|
||||
void
|
||||
gaussianGradientMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
- MultiArrayView<N, TinyVector<T2, N>, S2> dest,
|
||||
+ MultiArrayView<N, TinyVector<T2, int(N)>, S2> dest,
|
||||
BlockwiseConvolutionOptions<N> opt);
|
||||
}
|
||||
\endcode
|
||||
@@ -1590,7 +1590,7 @@ template <unsigned int N, class T1, class S1,
|
||||
class T2, class S2>
|
||||
inline void
|
||||
gaussianGradientMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
- MultiArrayView<N, TinyVector<T2, N>, S2> dest,
|
||||
+ MultiArrayView<N, TinyVector<T2, int(N)>, S2> dest,
|
||||
ConvolutionOptions<N> opt )
|
||||
{
|
||||
if(opt.to_point != typename MultiArrayShape<N>::type())
|
||||
@@ -1614,7 +1614,7 @@ template <unsigned int N, class T1, class S1,
|
||||
class T2, class S2>
|
||||
inline void
|
||||
gaussianGradientMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
- MultiArrayView<N, TinyVector<T2, N>, S2> dest,
|
||||
+ MultiArrayView<N, TinyVector<T2, int(N)>, S2> dest,
|
||||
double sigma,
|
||||
ConvolutionOptions<N> opt = ConvolutionOptions<N>())
|
||||
{
|
||||
@@ -1653,7 +1653,7 @@ gaussianGradientMagnitudeImpl(MultiArrayView<N+1, T1, S1> const & src,
|
||||
dest.init(0.0);
|
||||
|
||||
typedef typename NumericTraits<T1>::RealPromote TmpType;
|
||||
- MultiArray<N, TinyVector<TmpType, N> > grad(dest.shape());
|
||||
+ MultiArray<N, TinyVector<TmpType, int(N)> > grad(dest.shape());
|
||||
|
||||
using namespace multi_math;
|
||||
|
||||
@@ -1771,7 +1771,7 @@ gaussianGradientMagnitude(MultiArrayView<N+1, Multiband<T1>, S1> const & src,
|
||||
class T2, class S2>
|
||||
void
|
||||
symmetricGradientMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
- MultiArrayView<N, TinyVector<T2, N>, S2> dest,
|
||||
+ MultiArrayView<N, TinyVector<T2, int(N)>, S2> dest,
|
||||
ConvolutionOptions<N> opt = ConvolutionOptions<N>());
|
||||
|
||||
// execute algorithm in parallel
|
||||
@@ -1779,7 +1779,7 @@ gaussianGradientMagnitude(MultiArrayView<N+1, Multiband<T1>, S1> const & src,
|
||||
class T2, class S2>
|
||||
void
|
||||
symmetricGradientMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
- MultiArrayView<N, TinyVector<T2, N>, S2> dest,
|
||||
+ MultiArrayView<N, TinyVector<T2, int(N)>, S2> dest,
|
||||
BlockwiseConvolutionOptions<N> opt);
|
||||
}
|
||||
\endcode
|
||||
@@ -1895,7 +1895,7 @@ template <unsigned int N, class T1, class S1,
|
||||
class T2, class S2>
|
||||
inline void
|
||||
symmetricGradientMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
- MultiArrayView<N, TinyVector<T2, N>, S2> dest,
|
||||
+ MultiArrayView<N, TinyVector<T2, int(N)>, S2> dest,
|
||||
ConvolutionOptions<N> opt = ConvolutionOptions<N>())
|
||||
{
|
||||
if(opt.to_point != typename MultiArrayShape<N>::type())
|
||||
@@ -2214,14 +2214,14 @@ laplacianOfGaussianMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
template <unsigned int N, class T1, class S1,
|
||||
class T2, class S2>
|
||||
void
|
||||
- gaussianDivergenceMultiArray(MultiArrayView<N, TinyVector<T1, N>, S1> const & vectorField,
|
||||
+ gaussianDivergenceMultiArray(MultiArrayView<N, TinyVector<T1, int(N)>, S1> const & vectorField,
|
||||
MultiArrayView<N, T2, S2> divergence,
|
||||
ConvolutionOptions<N> const & opt);
|
||||
|
||||
template <unsigned int N, class T1, class S1,
|
||||
class T2, class S2>
|
||||
void
|
||||
- gaussianDivergenceMultiArray(MultiArrayView<N, TinyVector<T1, N>, S1> const & vectorField,
|
||||
+ gaussianDivergenceMultiArray(MultiArrayView<N, TinyVector<T1, int(N)>, S1> const & vectorField,
|
||||
MultiArrayView<N, T2, S2> divergence,
|
||||
double sigma,
|
||||
ConvolutionOptions<N> opt = ConvolutionOptions<N>());
|
||||
@@ -2231,7 +2231,7 @@ laplacianOfGaussianMultiArray(MultiArrayView<N, T1, S1> const & source,
|
||||
template <unsigned int N, class T1, class S1,
|
||||
class T2, class S2>
|
||||
void
|
||||
- gaussianDivergenceMultiArray(MultiArrayView<N, TinyVector<T1, N>, S1> const & vectorField,
|
||||
+ gaussianDivergenceMultiArray(MultiArrayView<N, TinyVector<T1, int(N)>, S1> const & vectorField,
|
||||
MultiArrayView<N, T2, S2> divergence,
|
||||
BlockwiseConvolutionOptions<N> const & opt);
|
||||
}
|
||||
@@ -2324,7 +2324,7 @@ gaussianDivergenceMultiArray(Iterator vectorField, Iterator vectorFieldEnd,
|
||||
template <unsigned int N, class T1, class S1,
|
||||
class T2, class S2>
|
||||
inline void
|
||||
-gaussianDivergenceMultiArray(MultiArrayView<N, TinyVector<T1, N>, S1> const & vectorField,
|
||||
+gaussianDivergenceMultiArray(MultiArrayView<N, TinyVector<T1, int(N)>, S1> const & vectorField,
|
||||
MultiArrayView<N, T2, S2> divergence,
|
||||
ConvolutionOptions<N> const & opt)
|
||||
{
|
||||
@@ -2338,7 +2338,7 @@ gaussianDivergenceMultiArray(MultiArrayView<N, TinyVector<T1, N>, S1> const & ve
|
||||
template <unsigned int N, class T1, class S1,
|
||||
class T2, class S2>
|
||||
inline void
|
||||
-gaussianDivergenceMultiArray(MultiArrayView<N, TinyVector<T1, N>, S1> const & vectorField,
|
||||
+gaussianDivergenceMultiArray(MultiArrayView<N, TinyVector<T1, int(N)>, S1> const & vectorField,
|
||||
MultiArrayView<N, T2, S2> divergence,
|
||||
double sigma,
|
||||
ConvolutionOptions<N> opt = ConvolutionOptions<N>())
|
12
vigra.spec
12
vigra.spec
|
@ -16,6 +16,12 @@ Group: Development/Libraries
|
|||
# tar zcf vigra-1.11.1-src-clean.tar.gz vigra-1.11.1/
|
||||
Source0: %{name}-%{version}-src-clean.tar.gz
|
||||
Source1: vigra-config.sh
|
||||
# Backported from upstream master, fixes a build failure:
|
||||
# https://github.com/ukoethe/vigra/issues/414
|
||||
Patch0: https://github.com/ukoethe/vigra/commit/81958d302494e137f98a8b1d7869841532f90388.patch
|
||||
# Avoid attempt to install non-free 'lenna' files
|
||||
Patch1: vigra-1.10.0-no-lenna.patch
|
||||
Patch2: vigra-1.11.1.docdir.patch
|
||||
URL: http://ukoethe.github.io/vigra/
|
||||
BuildRequires: gcc-c++ zlib-devel libjpeg-devel libpng-devel libtiff-devel fftw-devel >= 3
|
||||
BuildRequires: cmake boost-devel doxygen
|
||||
|
@ -26,8 +32,6 @@ BuildRequires: python3-numpy-f2py boost-python3
|
|||
%else
|
||||
Requires: python
|
||||
%endif
|
||||
Patch2: vigra-1.10.0-no-lenna.patch
|
||||
Patch3: vigra-1.11.1.docdir.patch
|
||||
|
||||
%description
|
||||
VIGRA stands for "Vision with Generic Algorithms". It's a novel computer vision
|
||||
|
@ -78,9 +82,7 @@ The python3-vigra package provides python 3 bindings for vigra
|
|||
%endif
|
||||
|
||||
%prep
|
||||
%setup -q
|
||||
%patch2 -p1 -b .no-lenna
|
||||
%patch3 -p1
|
||||
%autosetup -p1
|
||||
|
||||
%build
|
||||
# Will need to set LEMON_DIR to /usr/share/coin-or-lemon/cmake to compile WITH_LEMON
|
||||
|
|
Loading…
Reference in New Issue