added support of old CC into GPU mean shift routines
This commit is contained in:
@@ -251,9 +251,11 @@ namespace cv { namespace gpu { namespace imgproc
|
||||
}
|
||||
|
||||
extern "C" void meanShiftFiltering_gpu(const DevMem2D& src, DevMem2D dst, int sp, int sr, int maxIter, float eps)
|
||||
{
|
||||
{
|
||||
printFuncAttrib(meanshift_kernel);
|
||||
|
||||
dim3 grid(1, 1, 1);
|
||||
dim3 threads(32, 16, 1);
|
||||
dim3 threads(32, 8, 1);
|
||||
grid.x = divUp(src.cols, threads.x);
|
||||
grid.y = divUp(src.rows, threads.y);
|
||||
|
||||
@@ -269,7 +271,7 @@ namespace cv { namespace gpu { namespace imgproc
|
||||
extern "C" void meanShiftProc_gpu(const DevMem2D& src, DevMem2D dstr, DevMem2D dstsp, int sp, int sr, int maxIter, float eps)
|
||||
{
|
||||
dim3 grid(1, 1, 1);
|
||||
dim3 threads(32, 16, 1);
|
||||
dim3 threads(32, 8, 1);
|
||||
grid.x = divUp(src.cols, threads.x);
|
||||
grid.y = divUp(src.rows, threads.y);
|
||||
|
||||
|
@@ -129,8 +129,6 @@ void cv::gpu::remap(const GpuMat& src, GpuMat& dst, const GpuMat& xmap, const Gp
|
||||
|
||||
void cv::gpu::meanShiftFiltering(const GpuMat& src, GpuMat& dst, int sp, int sr, TermCriteria criteria)
|
||||
{
|
||||
CV_Assert(TargetArchs::builtWith(FEATURE_SET_COMPUTE_12) && DeviceInfo().supports(FEATURE_SET_COMPUTE_12));
|
||||
|
||||
if( src.empty() )
|
||||
CV_Error( CV_StsBadArg, "The input image is empty" );
|
||||
|
||||
@@ -157,8 +155,6 @@ void cv::gpu::meanShiftFiltering(const GpuMat& src, GpuMat& dst, int sp, int sr,
|
||||
|
||||
void cv::gpu::meanShiftProc(const GpuMat& src, GpuMat& dstr, GpuMat& dstsp, int sp, int sr, TermCriteria criteria)
|
||||
{
|
||||
CV_Assert(TargetArchs::builtWith(FEATURE_SET_COMPUTE_12) && DeviceInfo().supports(FEATURE_SET_COMPUTE_12));
|
||||
|
||||
if( src.empty() )
|
||||
CV_Error( CV_StsBadArg, "The input image is empty" );
|
||||
|
||||
|
@@ -227,8 +227,6 @@ inline int dist2(const cv::Vec2s& lhs, const cv::Vec2s& rhs)
|
||||
|
||||
void cv::gpu::meanShiftSegmentation(const GpuMat& src, Mat& dst, int sp, int sr, int minsize, TermCriteria criteria)
|
||||
{
|
||||
CV_Assert(TargetArchs::builtWith(FEATURE_SET_COMPUTE_12) && DeviceInfo().supports(FEATURE_SET_COMPUTE_12));
|
||||
|
||||
CV_Assert(src.type() == CV_8UC4);
|
||||
const int nrows = src.rows;
|
||||
const int ncols = src.cols;
|
||||
|
Reference in New Issue
Block a user