created wrappers for new NPP functions

removed void integral(const GpuMat& src, GpuMat& sum, GpuMat& sqsum, Stream& stream) - it fails with NPP_NOT_IMPLEMENTED error
updated docs, accuracy and performance tests
This commit is contained in:
Vladislav Vinogradov
2012-02-22 10:00:53 +00:00
parent e426dfc396
commit 2d30480982
37 changed files with 1984 additions and 566 deletions

View File

@@ -2377,6 +2377,49 @@ INSTANTIATE_TEST_CASE_P(ImgProc, CvtColor, Combine(
Values(CV_8U, CV_16U, CV_32F),
USE_ROI));
///////////////////////////////////////////////////////////////////////////////////////////////////////
// swapChannels
PARAM_TEST_CASE(SwapChannels, cv::gpu::DeviceInfo, UseRoi)
{
cv::gpu::DeviceInfo devInfo;
bool useRoi;
cv::Mat img;
cv::Mat dst_gold;
virtual void SetUp()
{
devInfo = GET_PARAM(0);
useRoi = GET_PARAM(1);
cv::gpu::setDevice(devInfo.deviceID());
cv::Mat imgBase = readImage("stereobm/aloe-L.png");
ASSERT_FALSE(imgBase.empty());
cv::cvtColor(imgBase, img, cv::COLOR_BGR2BGRA);
cv::cvtColor(img, dst_gold, cv::COLOR_BGRA2RGBA);
}
};
TEST_P(SwapChannels, Accuracy)
{
cv::gpu::GpuMat gpuImage = loadMat(img, useRoi);
const int dstOrder[] = {2, 1, 0, 3};
cv::gpu::swapChannels(gpuImage, dstOrder);
cv::Mat dst;
gpuImage.download(dst);
EXPECT_MAT_NEAR(dst_gold, dst, 0.0);
}
INSTANTIATE_TEST_CASE_P(ImgProc, SwapChannels, Combine(ALL_DEVICES, USE_ROI));
///////////////////////////////////////////////////////////////////////////////////////////////////////
// histograms