From: Vladislav Vinogradov Date: Mon, 26 Aug 2013 07:17:06 +0000 (+0400) Subject: fixed warnings X-Git-Tag: accepted/tizen/6.0/unified/20201030.111113~3715^2~11 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=bbd519be42b7fb4ce9529fc176ef6d473659a4bf;p=platform%2Fupstream%2Fopencv.git fixed warnings --- diff --git a/modules/cudev/include/opencv2/cudev/grid/detail/reduce.hpp b/modules/cudev/include/opencv2/cudev/grid/detail/reduce.hpp index 21a95ea..7ccdd05 100644 --- a/modules/cudev/include/opencv2/cudev/grid/detail/reduce.hpp +++ b/modules/cudev/include/opencv2/cudev/grid/detail/reduce.hpp @@ -389,7 +389,7 @@ namespace grid_reduce_detail // glob_reduce template - __global__ void glob_reduce(const SrcPtr src, ResType* result, const MaskPtr mask, const int rows, const int cols) + __global__ void reduce(const SrcPtr src, ResType* result, const MaskPtr mask, const int rows, const int cols) { const int x0 = blockIdx.x * blockDim.x * PATCH_X + threadIdx.x; const int y0 = blockIdx.y * blockDim.y * PATCH_Y + threadIdx.y; @@ -413,12 +413,12 @@ namespace grid_reduce_detail } template - __host__ void glob_reduce(const SrcPtr& src, ResType* result, const MaskPtr& mask, int rows, int cols, cudaStream_t stream) + __host__ void reduce(const SrcPtr& src, ResType* result, const MaskPtr& mask, int rows, int cols, cudaStream_t stream) { const dim3 block(Policy::block_size_x, Policy::block_size_y); const dim3 grid(divUp(cols, block.x * Policy::patch_size_x), divUp(rows, block.y * Policy::patch_size_y)); - glob_reduce<<>>(src, result, mask, rows, cols); + reduce<<>>(src, result, mask, rows, cols); CV_CUDEV_SAFE_CALL( cudaGetLastError() ); if (stream == 0) @@ -433,7 +433,7 @@ namespace grid_reduce_detail typedef typename PtrTraits::value_type src_type; typedef typename VecTraits::elem_type res_elem_type; - glob_reduce, Policy>(src, (res_elem_type*) result, mask, rows, cols, stream); + reduce, Policy>(src, (res_elem_type*) result, mask, rows, cols, stream); } template @@ -441,7 +441,7 @@ namespace grid_reduce_detail { typedef typename PtrTraits::value_type src_type; - glob_reduce, src_type, ResType>, Policy>(src, result, mask, rows, cols, stream); + reduce, src_type, ResType>, Policy>(src, result, mask, rows, cols, stream); } template @@ -449,7 +449,7 @@ namespace grid_reduce_detail { typedef typename PtrTraits::value_type src_type; - glob_reduce, src_type, ResType>, Policy>(src, result, mask, rows, cols, stream); + reduce, src_type, ResType>, Policy>(src, result, mask, rows, cols, stream); } template @@ -457,7 +457,7 @@ namespace grid_reduce_detail { typedef typename PtrTraits::value_type src_type; - glob_reduce, Policy>(src, result, mask, rows, cols, stream); + reduce, Policy>(src, result, mask, rows, cols, stream); } } diff --git a/modules/cudev/include/opencv2/cudev/grid/reduce.hpp b/modules/cudev/include/opencv2/cudev/grid/reduce.hpp index f300946..24f2a7c 100644 --- a/modules/cudev/include/opencv2/cudev/grid/reduce.hpp +++ b/modules/cudev/include/opencv2/cudev/grid/reduce.hpp @@ -61,7 +61,7 @@ __host__ void gridCalcSum_(const SrcPtr& src, GpuMat_& dst, const MaskP { typedef typename PtrTraits::value_type src_type; - CV_StaticAssert( VecTraits::cn == VecTraits::cn, "" ); + CV_StaticAssert( unsigned(VecTraits::cn) == unsigned(VecTraits::cn), "" ); dst.create(1, 1); dst.setTo(0, stream); @@ -83,7 +83,7 @@ __host__ void gridCalcSum_(const SrcPtr& src, GpuMat_& dst, Stream& str { typedef typename PtrTraits::value_type src_type; - CV_StaticAssert( VecTraits::cn == VecTraits::cn, "" ); + CV_StaticAssert( unsigned(VecTraits::cn) == unsigned(VecTraits::cn), "" ); dst.create(1, 1); dst.setTo(0, stream);