Commit f15b4201 authored by Vladislav Vinogradov's avatar Vladislav Vinogradov Committed by Alexander Smorkalov

fix nonfree module compilation without CUDA(cherry picked from commit…

fix nonfree module compilation without CUDA(cherry picked from commit 3e1f74f2)
parent f9e9ae85
...@@ -51,17 +51,14 @@ ...@@ -51,17 +51,14 @@
#include "opencv2/imgproc/imgproc.hpp" #include "opencv2/imgproc/imgproc.hpp"
#include "opencv2/core/internal.hpp" #include "opencv2/core/internal.hpp"
#if defined(HAVE_OPENCV_GPU) && !defined(DYNAMIC_CUDA_SUPPORT) #include "opencv2/nonfree/gpu.hpp"
#include "opencv2/nonfree/gpu.hpp"
#if defined(HAVE_CUDA) #if defined(HAVE_CUDA) && defined(HAVE_OPENCV_GPU) && !defined(DYNAMIC_CUDA_SUPPORT)
#include "opencv2/gpu/stream_accessor.hpp" #include "opencv2/gpu/stream_accessor.hpp"
#include "opencv2/gpu/device/common.hpp" #include "opencv2/gpu/device/common.hpp"
static inline void throw_nogpu() { CV_Error(CV_StsNotImplemented, "The called functionality is disabled for current build or platform"); }
static inline void throw_nogpu() { CV_Error(CV_StsNotImplemented, "The called functionality is disabled for current build or platform"); } #else
#else static inline void throw_nogpu() { CV_Error(CV_GpuNotSupported, "The library is compiled without GPU support"); }
static inline void throw_nogpu() { CV_Error(CV_GpuNotSupported, "The library is compiled without GPU support"); }
#endif
#endif #endif
#ifdef HAVE_OPENCV_OCL #ifdef HAVE_OPENCV_OCL
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment