diff --git a/modules/cudaarithm/include/opencv2/cudaarithm.hpp b/modules/cudaarithm/include/opencv2/cudaarithm.hpp index 10338051e..bb74ea189 100644 --- a/modules/cudaarithm/include/opencv2/cudaarithm.hpp +++ b/modules/cudaarithm/include/opencv2/cudaarithm.hpp @@ -620,7 +620,7 @@ The function does not work with CV_64F images on GPUs with the compute capabilit @sa minMaxLoc */ -CV_EXPORTS_W void minMax(InputArray src, double* minVal, double* maxVal, InputArray mask = noArray()); +CV_EXPORTS_W void minMax(InputArray src, CV_OUT double* minVal, CV_OUT double* maxVal, InputArray mask = noArray()); /** @overload */ CV_EXPORTS_W void findMinMax(InputArray src, OutputArray dst, InputArray mask = noArray(), Stream& stream = Stream::Null()); @@ -637,7 +637,7 @@ The function does not work with CV_64F images on GPU with the compute capability @sa minMaxLoc */ -CV_EXPORTS_W void minMaxLoc(InputArray src, double* minVal, double* maxVal, Point* minLoc, Point* maxLoc, +CV_EXPORTS_W void minMaxLoc(InputArray src, CV_OUT double* minVal, CV_OUT double* maxVal, CV_OUT Point* minLoc, CV_OUT Point* maxLoc, InputArray mask = noArray()); /** @overload */ CV_EXPORTS_W void findMinMaxLoc(InputArray src, OutputArray minMaxVals, OutputArray loc, diff --git a/modules/cudaarithm/misc/python/test/test_cudaarithm.py b/modules/cudaarithm/misc/python/test/test_cudaarithm.py index bbc9527a7..1d959d791 100644 --- a/modules/cudaarithm/misc/python/test/test_cudaarithm.py +++ b/modules/cudaarithm/misc/python/test/test_cudaarithm.py @@ -154,6 +154,9 @@ class cudaarithm_test(NewOpenCVTests): cv.cuda.max(cuMat1, cuMat2, cuMatDst) self.assertTrue(np.allclose(cuMatDst.download(),cv.max(npMat1, npMat2))) + self.assertTrue(cv.cuda.minMax(cuMat1),cv.minMaxLoc(npMat1)[:2]) + self.assertTrue(cv.cuda.minMaxLoc(cuMat1),cv.minMaxLoc(npMat1)) + def test_convolution(self): npMat = (np.random.random((128, 128)) * 255).astype(np.float32) npDims = np.array(npMat.shape)