mirror of
https://github.com/opencv/opencv.git
synced 2026-07-30 15:53:03 +04:00
ocl: correct disabling of OpenCL code
This commit is contained in:
@@ -54,7 +54,9 @@
|
||||
|
||||
#include "opencv2/core/private.hpp"
|
||||
#include "opencv2/core/private.cuda.hpp"
|
||||
#ifdef HAVE_OPENCL
|
||||
#include "opencv2/core/ocl.hpp"
|
||||
#endif
|
||||
|
||||
#include "opencv2/hal.hpp"
|
||||
|
||||
@@ -262,7 +264,11 @@ struct ImplCollector
|
||||
|
||||
struct CoreTLSData
|
||||
{
|
||||
CoreTLSData() : device(0), useOpenCL(-1), useIPP(-1)
|
||||
CoreTLSData() :
|
||||
#ifdef HAVE_OPENCL
|
||||
device(0), useOpenCL(-1),
|
||||
#endif
|
||||
useIPP(-1)
|
||||
{
|
||||
#ifdef HAVE_TEGRA_OPTIMIZATION
|
||||
useTegra = -1;
|
||||
@@ -270,9 +276,11 @@ struct CoreTLSData
|
||||
}
|
||||
|
||||
RNG rng;
|
||||
#ifdef HAVE_OPENCL
|
||||
int device;
|
||||
ocl::Queue oclQueue;
|
||||
int useOpenCL; // 1 - use, 0 - do not use, -1 - auto/not initialized
|
||||
#endif
|
||||
int useIPP; // 1 - use, 0 - do not use, -1 - auto/not initialized
|
||||
#ifdef HAVE_TEGRA_OPTIMIZATION
|
||||
int useTegra; // 1 - use, 0 - do not use, -1 - auto/not initialized
|
||||
|
||||
Reference in New Issue
Block a user