renamed device -> cuda
This commit is contained in:
@@ -43,7 +43,7 @@
|
||||
#ifndef __OPENCV_GPU_DEVICE_BLOCK_HPP__
|
||||
#define __OPENCV_GPU_DEVICE_BLOCK_HPP__
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
struct Block
|
||||
{
|
@@ -47,7 +47,7 @@
|
||||
#include "vec_traits.hpp"
|
||||
#include "vec_math.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
//////////////////////////////////////////////////////////////
|
||||
// BrdConstant
|
||||
@@ -709,6 +709,6 @@ namespace cv { namespace gpu { namespace device
|
||||
const int width;
|
||||
const D val;
|
||||
};
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_BORDER_INTERPOLATE_HPP__
|
@@ -45,7 +45,7 @@
|
||||
|
||||
#include "detail/color_detail.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
// All OPENCV_GPU_IMPLEMENT_*_TRAITS(ColorSpace1_to_ColorSpace2, ...) macros implements
|
||||
// template <typename T> class ColorSpace1_to_ColorSpace2_traits
|
||||
@@ -296,6 +296,6 @@ namespace cv { namespace gpu { namespace device
|
||||
OPENCV_GPU_IMPLEMENT_Luv2RGB_TRAITS(luv4_to_lbgra, 4, 4, false, 0)
|
||||
|
||||
#undef OPENCV_GPU_IMPLEMENT_Luv2RGB_TRAITS
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_BORDER_INTERPOLATE_HPP__
|
@@ -92,7 +92,7 @@ namespace cv { namespace gpu
|
||||
return (total + grain - 1) / grain;
|
||||
}
|
||||
|
||||
namespace device
|
||||
namespace cuda
|
||||
{
|
||||
using cv::gpu::divUp;
|
||||
|
@@ -45,7 +45,7 @@
|
||||
|
||||
#include "common.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
#if defined __CUDA_ARCH__ && __CUDA_ARCH__ >= 200
|
||||
|
||||
@@ -100,6 +100,6 @@ namespace cv { namespace gpu { namespace device
|
||||
#undef OPENCV_GPU_ASM_PTR
|
||||
|
||||
#endif // __CUDA_ARCH__ >= 200
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_DATAMOV_UTILS_HPP__
|
@@ -49,7 +49,7 @@
|
||||
#include "../limits.hpp"
|
||||
#include "../functional.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
#ifndef CV_DESCALE
|
||||
#define CV_DESCALE(x, n) (((x) + (1 << ((n)-1))) >> (n))
|
||||
@@ -149,7 +149,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_RGB2RGB_TRAITS(name, scn, dcn, bidx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2RGB<T, scn, dcn, bidx> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2RGB<T, scn, dcn, bidx> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -222,7 +222,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_RGB2RGB5x5_TRAITS(name, scn, bidx, green_bits) \
|
||||
struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2RGB5x5<scn, bidx, green_bits> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2RGB5x5<scn, bidx, green_bits> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -303,7 +303,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_RGB5x52RGB_TRAITS(name, dcn, bidx, green_bits) \
|
||||
struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB5x52RGB<dcn, bidx, green_bits> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB5x52RGB<dcn, bidx, green_bits> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -350,7 +350,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_GRAY2RGB_TRAITS(name, dcn) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::Gray2RGB<T, dcn> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::Gray2RGB<T, dcn> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -392,7 +392,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_GRAY2RGB5x5_TRAITS(name, green_bits) \
|
||||
struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::Gray2RGB5x5<green_bits> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::Gray2RGB5x5<green_bits> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -434,7 +434,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_RGB5x52GRAY_TRAITS(name, green_bits) \
|
||||
struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB5x52Gray<green_bits> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB5x52Gray<green_bits> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -486,7 +486,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_RGB2GRAY_TRAITS(name, scn, bidx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2Gray<T, scn, bidx> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2Gray<T, scn, bidx> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -539,7 +539,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_RGB2YUV_TRAITS(name, scn, dcn, bidx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2YUV<T, scn, dcn, bidx> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2YUV<T, scn, dcn, bidx> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -629,7 +629,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_YUV2RGB_TRAITS(name, scn, dcn, bidx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::YUV2RGB<T, scn, dcn, bidx> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::YUV2RGB<T, scn, dcn, bidx> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -710,7 +710,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_RGB2YCrCb_TRAITS(name, scn, dcn, bidx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2YCrCb<T, scn, dcn, bidx> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2YCrCb<T, scn, dcn, bidx> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -791,7 +791,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_YCrCb2RGB_TRAITS(name, scn, dcn, bidx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::YCrCb2RGB<T, scn, dcn, bidx> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::YCrCb2RGB<T, scn, dcn, bidx> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -869,7 +869,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_RGB2XYZ_TRAITS(name, scn, dcn, bidx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2XYZ<T, scn, dcn, bidx> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2XYZ<T, scn, dcn, bidx> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -946,7 +946,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_XYZ2RGB_TRAITS(name, scn, dcn, bidx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::XYZ2RGB<T, scn, dcn, bidx> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::XYZ2RGB<T, scn, dcn, bidx> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1086,7 +1086,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_RGB2HSV_TRAITS(name, scn, dcn, bidx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2HSV<T, scn, dcn, bidx, 180> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2HSV<T, scn, dcn, bidx, 180> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1094,7 +1094,7 @@ namespace cv { namespace gpu { namespace device
|
||||
}; \
|
||||
template <typename T> struct name ## _full_traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2HSV<T, scn, dcn, bidx, 256> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2HSV<T, scn, dcn, bidx, 256> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1102,7 +1102,7 @@ namespace cv { namespace gpu { namespace device
|
||||
}; \
|
||||
template <> struct name ## _traits<float> \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2HSV<float, scn, dcn, bidx, 360> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2HSV<float, scn, dcn, bidx, 360> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1110,7 +1110,7 @@ namespace cv { namespace gpu { namespace device
|
||||
}; \
|
||||
template <> struct name ## _full_traits<float> \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2HSV<float, scn, dcn, bidx, 360> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2HSV<float, scn, dcn, bidx, 360> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1228,7 +1228,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_HSV2RGB_TRAITS(name, scn, dcn, bidx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::HSV2RGB<T, scn, dcn, bidx, 180> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::HSV2RGB<T, scn, dcn, bidx, 180> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1236,7 +1236,7 @@ namespace cv { namespace gpu { namespace device
|
||||
}; \
|
||||
template <typename T> struct name ## _full_traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::HSV2RGB<T, scn, dcn, bidx, 255> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::HSV2RGB<T, scn, dcn, bidx, 255> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1244,7 +1244,7 @@ namespace cv { namespace gpu { namespace device
|
||||
}; \
|
||||
template <> struct name ## _traits<float> \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::HSV2RGB<float, scn, dcn, bidx, 360> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::HSV2RGB<float, scn, dcn, bidx, 360> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1252,7 +1252,7 @@ namespace cv { namespace gpu { namespace device
|
||||
}; \
|
||||
template <> struct name ## _full_traits<float> \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::HSV2RGB<float, scn, dcn, bidx, 360> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::HSV2RGB<float, scn, dcn, bidx, 360> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1363,7 +1363,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_RGB2HLS_TRAITS(name, scn, dcn, bidx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2HLS<T, scn, dcn, bidx, 180> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2HLS<T, scn, dcn, bidx, 180> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1371,7 +1371,7 @@ namespace cv { namespace gpu { namespace device
|
||||
}; \
|
||||
template <typename T> struct name ## _full_traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2HLS<T, scn, dcn, bidx, 256> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2HLS<T, scn, dcn, bidx, 256> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1379,7 +1379,7 @@ namespace cv { namespace gpu { namespace device
|
||||
}; \
|
||||
template <> struct name ## _traits<float> \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2HLS<float, scn, dcn, bidx, 360> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2HLS<float, scn, dcn, bidx, 360> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1387,7 +1387,7 @@ namespace cv { namespace gpu { namespace device
|
||||
}; \
|
||||
template <> struct name ## _full_traits<float> \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2HLS<float, scn, dcn, bidx, 360> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2HLS<float, scn, dcn, bidx, 360> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1505,7 +1505,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_HLS2RGB_TRAITS(name, scn, dcn, bidx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::HLS2RGB<T, scn, dcn, bidx, 180> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::HLS2RGB<T, scn, dcn, bidx, 180> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1513,7 +1513,7 @@ namespace cv { namespace gpu { namespace device
|
||||
}; \
|
||||
template <typename T> struct name ## _full_traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::HLS2RGB<T, scn, dcn, bidx, 255> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::HLS2RGB<T, scn, dcn, bidx, 255> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1521,7 +1521,7 @@ namespace cv { namespace gpu { namespace device
|
||||
}; \
|
||||
template <> struct name ## _traits<float> \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::HLS2RGB<float, scn, dcn, bidx, 360> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::HLS2RGB<float, scn, dcn, bidx, 360> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1529,7 +1529,7 @@ namespace cv { namespace gpu { namespace device
|
||||
}; \
|
||||
template <> struct name ## _full_traits<float> \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::HLS2RGB<float, scn, dcn, bidx, 360> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::HLS2RGB<float, scn, dcn, bidx, 360> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1674,7 +1674,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_RGB2Lab_TRAITS(name, scn, dcn, srgb, blueIdx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2Lab<T, scn, dcn, srgb, blueIdx> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2Lab<T, scn, dcn, srgb, blueIdx> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1787,7 +1787,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_Lab2RGB_TRAITS(name, scn, dcn, srgb, blueIdx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::Lab2RGB<T, scn, dcn, srgb, blueIdx> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::Lab2RGB<T, scn, dcn, srgb, blueIdx> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1886,7 +1886,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_RGB2Luv_TRAITS(name, scn, dcn, srgb, blueIdx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::RGB2Luv<T, scn, dcn, srgb, blueIdx> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::RGB2Luv<T, scn, dcn, srgb, blueIdx> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1987,7 +1987,7 @@ namespace cv { namespace gpu { namespace device
|
||||
#define OPENCV_GPU_IMPLEMENT_Luv2RGB_TRAITS(name, scn, dcn, srgb, blueIdx) \
|
||||
template <typename T> struct name ## _traits \
|
||||
{ \
|
||||
typedef ::cv::gpu::device::color_detail::Luv2RGB<T, scn, dcn, srgb, blueIdx> functor_type; \
|
||||
typedef ::cv::gpu::cuda::color_detail::Luv2RGB<T, scn, dcn, srgb, blueIdx> functor_type; \
|
||||
static __host__ __device__ __forceinline__ functor_type create_functor() \
|
||||
{ \
|
||||
return functor_type(); \
|
||||
@@ -1996,6 +1996,6 @@ namespace cv { namespace gpu { namespace device
|
||||
|
||||
#undef CV_DESCALE
|
||||
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_COLOR_DETAIL_HPP__
|
@@ -47,7 +47,7 @@
|
||||
#include "../warp.hpp"
|
||||
#include "../warp_shuffle.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
namespace reduce_detail
|
||||
{
|
@@ -47,7 +47,7 @@
|
||||
#include "../warp.hpp"
|
||||
#include "../warp_shuffle.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
namespace reduce_key_val_detail
|
||||
{
|
@@ -47,7 +47,7 @@
|
||||
#include "../vec_traits.hpp"
|
||||
#include "../functional.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
namespace transform_detail
|
||||
{
|
||||
@@ -390,6 +390,6 @@ namespace cv { namespace gpu { namespace device
|
||||
}
|
||||
};
|
||||
} // namespace transform_detail
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_TRANSFORM_DETAIL_HPP__
|
@@ -46,7 +46,7 @@
|
||||
#include "../common.hpp"
|
||||
#include "../vec_traits.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
namespace type_traits_detail
|
||||
{
|
||||
@@ -182,6 +182,6 @@ namespace cv { namespace gpu { namespace device
|
||||
enum { value = 1 };
|
||||
};
|
||||
} // namespace type_traits_detail
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_TYPE_TRAITS_DETAIL_HPP__
|
@@ -45,7 +45,7 @@
|
||||
|
||||
#include "../datamov_utils.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
namespace vec_distance_detail
|
||||
{
|
||||
@@ -112,6 +112,6 @@ namespace cv { namespace gpu { namespace device
|
||||
}
|
||||
};
|
||||
} // namespace vec_distance_detail
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_VEC_DISTANCE_DETAIL_HPP__
|
@@ -43,7 +43,7 @@
|
||||
#ifndef __OPENCV_GPU_DYNAMIC_SMEM_HPP__
|
||||
#define __OPENCV_GPU_DYNAMIC_SMEM_HPP__
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
template<class T> struct DynamicSharedMem
|
||||
{
|
@@ -45,7 +45,7 @@
|
||||
|
||||
#include "warp_reduce.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
struct Emulation
|
||||
{
|
||||
@@ -133,6 +133,6 @@ namespace cv { namespace gpu { namespace device
|
||||
}
|
||||
};
|
||||
};
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif /* OPENCV_GPU_EMULATION_HPP_ */
|
@@ -48,7 +48,7 @@
|
||||
#include "vec_math.hpp"
|
||||
#include "type_traits.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
template <typename Ptr2D> struct PointFilter
|
||||
{
|
||||
@@ -273,6 +273,6 @@ namespace cv { namespace gpu { namespace device
|
||||
float scale_x, scale_y;
|
||||
int width, haight;
|
||||
};
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_FILTERS_HPP__
|
@@ -45,7 +45,7 @@
|
||||
|
||||
#include <cstdio>
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
template<class Func>
|
||||
void printFuncAttrib(Func& func)
|
||||
@@ -66,6 +66,6 @@ namespace cv { namespace gpu { namespace device
|
||||
printf("\n");
|
||||
fflush(stdout);
|
||||
}
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif /* __OPENCV_GPU_DEVICE_FUNCATTRIB_HPP_ */
|
@@ -49,7 +49,7 @@
|
||||
#include "type_traits.hpp"
|
||||
#include "device_functions.h"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
// Function Objects
|
||||
template<typename Argument, typename Result> struct unary_function : public std::unary_function<Argument, Result> {};
|
||||
@@ -786,6 +786,6 @@ namespace cv { namespace gpu { namespace device
|
||||
|
||||
#define OPENCV_GPU_TRANSFORM_FUNCTOR_TRAITS(type) \
|
||||
template <> struct TransformFunctorTraits< type > : DefaultTransformFunctorTraits< type >
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_FUNCTIONAL_HPP__
|
@@ -46,7 +46,7 @@
|
||||
#include <limits>
|
||||
#include "common.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
template<class T> struct numeric_limits
|
||||
{
|
||||
@@ -230,6 +230,6 @@ namespace cv { namespace gpu { namespace device
|
||||
__device__ __forceinline__ static type signaling_NaN();
|
||||
static const bool is_signed = true;
|
||||
};
|
||||
}}} // namespace cv { namespace gpu { namespace device {
|
||||
}}} // namespace cv { namespace gpu { namespace cuda {
|
||||
|
||||
#endif // __OPENCV_GPU_LIMITS_GPU_HPP__
|
@@ -47,7 +47,7 @@
|
||||
#include "detail/reduce.hpp"
|
||||
#include "detail/reduce_key_val.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
template <int N, typename T, class Op>
|
||||
__device__ __forceinline__ void reduce(volatile T* smem, T& val, unsigned int tid, const Op& op)
|
@@ -45,7 +45,7 @@
|
||||
|
||||
#include "common.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
template<typename _Tp> __device__ __forceinline__ _Tp saturate_cast(uchar v) { return _Tp(v); }
|
||||
template<typename _Tp> __device__ __forceinline__ _Tp saturate_cast(schar v) { return _Tp(v); }
|
@@ -43,12 +43,12 @@
|
||||
#ifndef __OPENCV_GPU_SCAN_HPP__
|
||||
#define __OPENCV_GPU_SCAN_HPP__
|
||||
|
||||
#include "opencv2/core/device/common.hpp"
|
||||
#include "opencv2/core/device/utility.hpp"
|
||||
#include "opencv2/core/device/warp.hpp"
|
||||
#include "opencv2/core/device/warp_shuffle.hpp"
|
||||
#include "opencv2/core/cuda/common.hpp"
|
||||
#include "opencv2/core/cuda/utility.hpp"
|
||||
#include "opencv2/core/cuda/warp.hpp"
|
||||
#include "opencv2/core/cuda/warp_shuffle.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
enum ScanKind { EXCLUSIVE = 0, INCLUSIVE = 1 };
|
||||
|
||||
@@ -174,13 +174,13 @@ namespace cv { namespace gpu { namespace device
|
||||
__device__ T warpScanInclusive(T idata, volatile T* s_Data, unsigned int tid)
|
||||
{
|
||||
#if __CUDA_ARCH__ >= 300
|
||||
const unsigned int laneId = cv::gpu::device::Warp::laneId();
|
||||
const unsigned int laneId = cv::gpu::cuda::Warp::laneId();
|
||||
|
||||
// scan on shuffl functions
|
||||
#pragma unroll
|
||||
for (int i = 1; i <= (OPENCV_GPU_WARP_SIZE / 2); i *= 2)
|
||||
{
|
||||
const T n = cv::gpu::device::shfl_up(idata, i);
|
||||
const T n = cv::gpu::cuda::shfl_up(idata, i);
|
||||
if (laneId >= i)
|
||||
idata += n;
|
||||
}
|
@@ -123,7 +123,7 @@
|
||||
vmin4(a,b) per-byte unsigned minimum: min(a, b)
|
||||
*/
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
// 2
|
||||
|
@@ -51,7 +51,7 @@
|
||||
|
||||
namespace cv { namespace gpu
|
||||
{
|
||||
namespace device
|
||||
namespace cuda
|
||||
{
|
||||
template<bool expr> struct Static {};
|
||||
|
@@ -47,7 +47,7 @@
|
||||
#include "utility.hpp"
|
||||
#include "detail/transform_detail.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
template <typename T, typename D, typename UnOp, typename Mask>
|
||||
static inline void transform(PtrStepSz<T> src, PtrStepSz<D> dst, UnOp op, const Mask& mask, cudaStream_t stream)
|
@@ -45,7 +45,7 @@
|
||||
|
||||
#include "detail/type_traits_detail.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
template <typename T> struct IsSimpleParameter
|
||||
{
|
@@ -46,7 +46,7 @@
|
||||
#include "saturate_cast.hpp"
|
||||
#include "datamov_utils.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
#define OPENCV_GPU_LOG_WARP_SIZE (5)
|
||||
#define OPENCV_GPU_WARP_SIZE (1 << OPENCV_GPU_LOG_WARP_SIZE)
|
||||
@@ -208,6 +208,6 @@ namespace cv { namespace gpu { namespace device
|
||||
|
||||
return false;
|
||||
}
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_UTILITY_HPP__
|
@@ -47,7 +47,7 @@
|
||||
#include "functional.hpp"
|
||||
#include "detail/vec_distance_detail.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
template <typename T> struct L1Dist
|
||||
{
|
||||
@@ -219,6 +219,6 @@ namespace cv { namespace gpu { namespace device
|
||||
|
||||
U vec1Vals[MAX_LEN / THREAD_DIM];
|
||||
};
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_VEC_DISTANCE_HPP__
|
@@ -47,7 +47,7 @@
|
||||
#include "vec_traits.hpp"
|
||||
#include "functional.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
namespace vec_math_detail
|
||||
{
|
||||
@@ -325,6 +325,6 @@ namespace cv { namespace gpu { namespace device
|
||||
#undef OPENCV_GPU_IMPLEMENT_VEC_BINOP
|
||||
#undef OPENCV_GPU_IMPLEMENT_VEC_OP
|
||||
#undef OPENCV_GPU_IMPLEMENT_VEC_INT_OP
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_VECMATH_HPP__
|
@@ -45,7 +45,7 @@
|
||||
|
||||
#include "common.hpp"
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
template<typename T, int N> struct TypeVec;
|
||||
|
||||
@@ -275,6 +275,6 @@ namespace cv { namespace gpu { namespace device
|
||||
static __device__ __host__ __forceinline__ char8 make(schar a0, schar a1, schar a2, schar a3, schar a4, schar a5, schar a6, schar a7) {return make_char8(a0, a1, a2, a3, a4, a5, a6, a7);}
|
||||
static __device__ __host__ __forceinline__ char8 make(const schar* v) {return make_char8(v[0], v[1], v[2], v[3], v[4], v[5], v[6], v[7]);}
|
||||
};
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif // __OPENCV_GPU_VEC_TRAITS_HPP__
|
@@ -43,7 +43,7 @@
|
||||
#ifndef __OPENCV_GPU_DEVICE_WARP_HPP__
|
||||
#define __OPENCV_GPU_DEVICE_WARP_HPP__
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
struct Warp
|
||||
{
|
||||
@@ -126,6 +126,6 @@ namespace cv { namespace gpu { namespace device
|
||||
*t = value;
|
||||
}
|
||||
};
|
||||
}}} // namespace cv { namespace gpu { namespace device
|
||||
}}} // namespace cv { namespace gpu { namespace cuda
|
||||
|
||||
#endif /* __OPENCV_GPU_DEVICE_WARP_HPP__ */
|
@@ -43,7 +43,7 @@
|
||||
#ifndef OPENCV_GPU_WARP_REDUCE_HPP__
|
||||
#define OPENCV_GPU_WARP_REDUCE_HPP__
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
template <class T>
|
||||
__device__ __forceinline__ T warp_reduce(volatile T *ptr , const unsigned int tid = threadIdx.x)
|
||||
@@ -63,6 +63,6 @@ namespace cv { namespace gpu { namespace device
|
||||
|
||||
return ptr[tid - lane];
|
||||
}
|
||||
}}} // namespace cv { namespace gpu { namespace device {
|
||||
}}} // namespace cv { namespace gpu { namespace cuda {
|
||||
|
||||
#endif /* OPENCV_GPU_WARP_REDUCE_HPP__ */
|
@@ -43,7 +43,7 @@
|
||||
#ifndef __OPENCV_GPU_WARP_SHUFFLE_HPP__
|
||||
#define __OPENCV_GPU_WARP_SHUFFLE_HPP__
|
||||
|
||||
namespace cv { namespace gpu { namespace device
|
||||
namespace cv { namespace gpu { namespace cuda
|
||||
{
|
||||
template <typename T>
|
||||
__device__ __forceinline__ T shfl(T val, int srcLane, int width = warpSize)
|
@@ -148,24 +148,6 @@ namespace cv
|
||||
typedef DevMem2Db DevMem2D;
|
||||
typedef DevMem2D_<float> DevMem2Df;
|
||||
typedef DevMem2D_<int> DevMem2Di;
|
||||
|
||||
//#undef __CV_GPU_DEPR_BEFORE__
|
||||
//#undef __CV_GPU_DEPR_AFTER__
|
||||
|
||||
namespace device
|
||||
{
|
||||
using cv::gpu::PtrSz;
|
||||
using cv::gpu::PtrStep;
|
||||
using cv::gpu::PtrStepSz;
|
||||
|
||||
using cv::gpu::PtrStepSzb;
|
||||
using cv::gpu::PtrStepSzf;
|
||||
using cv::gpu::PtrStepSzi;
|
||||
|
||||
using cv::gpu::PtrStepb;
|
||||
using cv::gpu::PtrStepf;
|
||||
using cv::gpu::PtrStepi;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user