Path: blob/master/modules/imgproc/perf/perf_bilateral.cpp
16339 views
// This file is part of OpenCV project.1// It is subject to the license terms in the LICENSE file found in the top-level directory2// of this distribution and at http://opencv.org/license.html.3#include "perf_precomp.hpp"45namespace opencv_test {67CV_ENUM(Mat_Type, CV_8UC1, CV_8UC3, CV_32FC1, CV_32FC3)89typedef TestBaseWithParam< tuple<Size, int, Mat_Type> > TestBilateralFilter;1011PERF_TEST_P( TestBilateralFilter, BilateralFilter,12Combine(13Values( szVGA, sz1080p ), // image size14Values( 3, 5 ), // d15Mat_Type::all() // image type16)17)18{19Size sz;20int d, type;21const double sigmaColor = 1., sigmaSpace = 1.;2223sz = get<0>(GetParam());24d = get<1>(GetParam());25type = get<2>(GetParam());2627Mat src(sz, type);28Mat dst(sz, type);2930declare.in(src, WARMUP_RNG).out(dst).time(20);3132TEST_CYCLE() bilateralFilter(src, dst, d, sigmaColor, sigmaSpace, BORDER_DEFAULT);3334SANITY_CHECK(dst, .01, ERROR_RELATIVE);35}3637} // namespace383940