From c07af090f517a81f7bc823709c7e759d993e9062 Mon Sep 17 00:00:00 2001 From: Tomoaki Teshima Date: Thu, 18 Jun 2020 21:25:15 +0900 Subject: [PATCH] fix build error on Jetson TX1 and TX2 * enable_if_t and is_base_of is c++14 feature * override is c++11 feature --- modules/cudaimgproc/src/cuda/canny.cu | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/modules/cudaimgproc/src/cuda/canny.cu b/modules/cudaimgproc/src/cuda/canny.cu index 253287ca31..0bc3e2a671 100644 --- a/modules/cudaimgproc/src/cuda/canny.cu +++ b/modules/cudaimgproc/src/cuda/canny.cu @@ -107,7 +107,7 @@ namespace canny { __host__ SrcTexRef(int _xoff, int _yoff) : SrcTex(_xoff, _yoff) {} - __device__ __forceinline__ int operator ()(int y, int x) const override + __device__ __forceinline__ int operator ()(int y, int x) const { return tex2D(tex_src, x + xoff, y + yoff); } @@ -117,7 +117,7 @@ namespace canny { __host__ SrcTexObj(int _xoff, int _yoff, cudaTextureObject_t _tex_src_object) : SrcTex(_xoff, _yoff), tex_src_object(_tex_src_object) { } - __device__ __forceinline__ int operator ()(int y, int x) const override + __device__ __forceinline__ int operator ()(int y, int x) const { return tex2D(tex_src_object, x + xoff, y + yoff); } @@ -127,8 +127,7 @@ namespace canny template < class T, - class Norm, - typename = std::enable_if_t::value> + class Norm > __global__ void calcMagnitudeKernel(const T src, PtrStepi dx, PtrStepi dy, PtrStepSzf mag, const Norm norm) {