From c4bec8a5c5eb12a6112857b3c875ec8d0cbb3f9f Mon Sep 17 00:00:00 2001 From: Sh0 Date: Fri, 13 Feb 2015 16:01:48 +0900 Subject: [PATCH] Function cuda::integral() does not require an extra buffer any more. --- modules/xfeatures2d/include/opencv2/xfeatures2d/cuda.hpp | 2 +- modules/xfeatures2d/src/surf.cuda.cpp | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/modules/xfeatures2d/include/opencv2/xfeatures2d/cuda.hpp b/modules/xfeatures2d/include/opencv2/xfeatures2d/cuda.hpp index 3dc57c7ff..16039a5a7 100644 --- a/modules/xfeatures2d/include/opencv2/xfeatures2d/cuda.hpp +++ b/modules/xfeatures2d/include/opencv2/xfeatures2d/cuda.hpp @@ -152,7 +152,7 @@ public: //! max keypoints = min(keypointsRatio * img.size().area(), 65535) float keypointsRatio; - GpuMat sum, mask1, maskSum, intBuffer; + GpuMat sum, mask1, maskSum; GpuMat det, trace; diff --git a/modules/xfeatures2d/src/surf.cuda.cpp b/modules/xfeatures2d/src/surf.cuda.cpp index 208156c98..6f7a0f45f 100644 --- a/modules/xfeatures2d/src/surf.cuda.cpp +++ b/modules/xfeatures2d/src/surf.cuda.cpp @@ -146,13 +146,13 @@ namespace bindImgTex(img); - cuda::integral(img, surf_.sum, surf_.intBuffer); + cuda::integral(img, surf_.sum); sumOffset = bindSumTex(surf_.sum); if (use_mask) { cuda::min(mask, 1.0, surf_.mask1); - cuda::integral(surf_.mask1, surf_.maskSum, surf_.intBuffer); + cuda::integral(surf_.mask1, surf_.maskSum); maskOffset = bindMaskSumTex(surf_.maskSum); } } @@ -425,7 +425,6 @@ void cv::cuda::SURF_CUDA::releaseMemory() sum.release(); mask1.release(); maskSum.release(); - intBuffer.release(); det.release(); trace.release(); maxPosBuffer.release();