merge new setUseOptimizations function with existed setUseOptimized

pull/3764/head
Vladislav Vinogradov 10 years ago
parent 4800a34be3
commit 4254e35f6a
  1. 2
      modules/core/include/opencv2/core/base.hpp
  2. 19
      modules/core/src/system.cpp
  3. 2
      modules/ts/include/opencv2/ts/cuda_test.hpp

@ -727,8 +727,6 @@ CV_EXPORTS void setUseIPP(bool flag);
} // ipp
CV_EXPORTS void setUseOptimizations(bool enabled);
//! @endcond
//! @} core_utils

@ -385,6 +385,12 @@ void setUseOptimized( bool flag )
useOptimizedFlag = flag;
currentFeatures = flag ? &featuresEnabled : &featuresDisabled;
USE_SSE2 = currentFeatures->have[CV_CPU_SSE2];
ipp::setUseIPP(flag);
ocl::setUseOpenCL(flag);
#ifdef HAVE_TEGRA_OPTIMIZATION
::tegra::setUseTegra(flag);
#endif
}
bool useOptimized(void)
@ -1289,17 +1295,4 @@ void setUseTegra(bool flag)
#endif
namespace cv {
void setUseOptimizations(bool enabled)
{
ipp::setUseIPP(enabled);
ocl::setUseOpenCL(enabled);
#ifdef HAVE_TEGRA_OPTIMIZATION
::tegra::setUseTegra(enabled);
#endif
}
} // namespace cv
/* End of file. */

@ -352,7 +352,7 @@ namespace cv { namespace cuda
#ifdef HAVE_CUDA
#define CV_CUDA_TEST_MAIN(resourcesubdir) \
CV_TEST_MAIN(resourcesubdir, cvtest::parseCudaDeviceOptions(argc, argv), cvtest::printCudaInfo(), cv::setUseOptimizations(false))
CV_TEST_MAIN(resourcesubdir, cvtest::parseCudaDeviceOptions(argc, argv), cvtest::printCudaInfo(), cv::setUseOptimized(false))
#else // HAVE_CUDA

Loading…
Cancel
Save