Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
a75cfe13
Commit
a75cfe13
authored
Jan 09, 2014
by
Andrey Pavlenko
Committed by
OpenCV Buildbot
Jan 09, 2014
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #2128 from alalek:ocl_cleanup_runtime
parents
560cfa56
70a03270
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
2 additions
and
277 deletions
+2
-277
ocl_runtime.hpp
.../core/include/opencv2/core/opencl/runtime/ocl_runtime.hpp
+0
-34
opencl_clamdfft_functions.list
...l/runtime/generator/filter/opencl_clamdfft_functions.list
+2
-2
ocl_clamdblas_runtime.cpp.in
...l/runtime/generator/template/ocl_clamdblas_runtime.cpp.in
+0
-75
ocl_clamdblas_runtime.hpp.in
...l/runtime/generator/template/ocl_clamdblas_runtime.hpp.in
+0
-25
ocl_clamdfft_runtime.cpp.in
...cl/runtime/generator/template/ocl_clamdfft_runtime.cpp.in
+0
-75
ocl_clamdfft_runtime.hpp.in
...cl/runtime/generator/template/ocl_clamdfft_runtime.hpp.in
+0
-25
ocl_runtime_impl_opencl.hpp.in
...runtime/generator/template/ocl_runtime_impl_opencl.hpp.in
+0
-10
ocl_runtime_opencl.hpp.in
...encl/runtime/generator/template/ocl_runtime_opencl.hpp.in
+0
-24
ocl_runtime_opencl_wrappers.hpp.in
...ime/generator/template/ocl_runtime_opencl_wrappers.hpp.in
+0
-7
No files found.
modules/core/include/opencv2/core/opencl/runtime/ocl_runtime.hpp
deleted
100644 → 0
View file @
560cfa56
#ifndef __OPENCV_CORE_OCL_RUNTIME_HPP__
#define __OPENCV_CORE_OCL_RUNTIME_HPP__
#ifdef HAVE_OPENCL
#if defined(HAVE_OPENCL_STATIC)
#if defined __APPLE__
#include <OpenCL/cl.h>
#else
#include <CL/cl.h>
#endif
#else // HAVE_OPENCL_STATIC
#include "ocl_runtime_opencl.hpp"
#endif // HAVE_OPENCL_STATIC
#ifndef CL_DEVICE_DOUBLE_FP_CONFIG
#define CL_DEVICE_DOUBLE_FP_CONFIG 0x1032
#endif
#ifndef CL_DEVICE_HALF_FP_CONFIG
#define CL_DEVICE_HALF_FP_CONFIG 0x1033
#endif
#ifndef CL_VERSION_1_2
#define CV_REQUIRE_OPENCL_1_2_ERROR CV_ErrorNoReturn(cv::Error::OpenCLApiCallError, "OpenCV compiled without OpenCL v1.2 support, so we can't use functionality from OpenCL v1.2")
#endif
#endif // HAVE_OPENCL
#endif // __OPENCV_CORE_OCL_RUNTIME_HPP__
modules/core/src/opencl/runtime/generator/filter/opencl_clamdfft_functions.list
View file @
a75cfe13
...
...
@@ -5,7 +5,7 @@ clAmdFftDestroyPlan
clAmdFftEnqueueTransform
//clAmdFftGetLayout
//clAmdFftGetPlanBatchSize
clAmdFftGetPlanContext
//
clAmdFftGetPlanContext
//clAmdFftGetPlanDim
//clAmdFftGetPlanDistance
//clAmdFftGetPlanInStride
...
...
@@ -22,7 +22,7 @@ clAmdFftSetPlanBatchSize
//clAmdFftSetPlanDim
clAmdFftSetPlanDistance
clAmdFftSetPlanInStride
clAmdFftSetPlanLength
//
clAmdFftSetPlanLength
clAmdFftSetPlanOutStride
clAmdFftSetPlanPrecision
clAmdFftSetPlanScale
...
...
modules/core/src/opencl/runtime/generator/template/ocl_clamdblas_runtime.cpp.in
deleted
100644 → 0
View file @
560cfa56
#include "precomp.hpp"
#ifdef HAVE_CLAMDBLAS
#include "opencv2/ocl/cl_runtime/cl_runtime.hpp"
#include "opencv2/ocl/cl_runtime/clamdblas_runtime.hpp"
#if defined(_WIN32)
static void* WinGetProcAddress(const char* name)
{
static HMODULE opencl_module = NULL;
if (!opencl_module)
{
opencl_module = GetModuleHandleA("clAmdBlas.dll");
if (!opencl_module)
{
opencl_module = LoadLibraryA("clAmdBlas.dll");
if (!opencl_module)
return NULL;
}
}
return (void*)GetProcAddress(opencl_module, name);
}
#define CV_CL_GET_PROC_ADDRESS(name) WinGetProcAddress(name)
#endif // _WIN32
#if defined(linux)
#include <dlfcn.h>
#include <stdio.h>
static void* GetProcAddress (const char* name)
{
static void* h = NULL;
if (!h)
{
h = dlopen("libclAmdBlas.so", RTLD_LAZY | RTLD_GLOBAL);
if (!h)
return NULL;
}
return dlsym(h, name);
}
#define CV_CL_GET_PROC_ADDRESS(name) GetProcAddress(name)
#endif
#ifndef CV_CL_GET_PROC_ADDRESS
#define CV_CL_GET_PROC_ADDRESS(name) NULL
#endif
@CL_FN_ENUMS@
@CL_FN_NAMES@
static void* openclamdblas_check_fn(int ID)
{
void* func = CV_CL_GET_PROC_ADDRESS(openclamdblas_fn_names[ID]);
if (!func)
{
std::ostringstream msg;
msg << "OpenCL AMD BLAS function is not available: [" << openclamdblas_fn_names[ID] << "]";
CV_Error(CV_StsBadFunc, msg.str());
}
extern void* openclamdblas_fn_ptrs[];
*(void**)(openclamdblas_fn_ptrs[ID]) = func;
return func;
}
namespace {
@CL_FN_SWITCH@
}
@CL_FN_DEFINITIONS@
@CL_FN_PTRS@
#endif
modules/core/src/opencl/runtime/generator/template/ocl_clamdblas_runtime.hpp.in
deleted
100644 → 0
View file @
560cfa56
#ifndef __OPENCV_OCL_CLAMDBLAS_RUNTIME_HPP__
#define __OPENCV_OCL_CLAMDBLAS_RUNTIME_HPP__
#ifdef HAVE_CLAMDBLAS
@CLAMDBLAS_REMAP_ORIGIN@
#include <clAmdBlas.h>
@CLAMDBLAS_REMAP_DYNAMIC@
#ifndef CL_RUNTIME_EXPORT
#if (defined(BUILD_SHARED_LIBS) || defined(OPENCV_OCL_SHARED)) && (defined WIN32 || defined _WIN32 || defined WINCE)
#define CL_RUNTIME_EXPORT __declspec(dllimport)
#else
#define CL_RUNTIME_EXPORT
#endif
#endif
@CLAMDBLAS_FN_DECLARATIONS@
#endif
#endif // __OPENCV_OCL_CLAMDBLAS_RUNTIME_HPP__
modules/core/src/opencl/runtime/generator/template/ocl_clamdfft_runtime.cpp.in
deleted
100644 → 0
View file @
560cfa56
#include "precomp.hpp"
#ifdef HAVE_CLAMDFFT
#include "opencv2/ocl/cl_runtime/cl_runtime.hpp"
#include "opencv2/ocl/cl_runtime/clamdfft_runtime.hpp"
#if defined(_WIN32)
static void* WinGetProcAddress(const char* name)
{
static HMODULE opencl_module = NULL;
if (!opencl_module)
{
opencl_module = GetModuleHandleA("clAmdFft.Runtime.dll");
if (!opencl_module)
{
opencl_module = LoadLibraryA("clAmdFft.Runtime.dll");
if (!opencl_module)
return NULL;
}
}
return (void*)GetProcAddress(opencl_module, name);
}
#define CV_CL_GET_PROC_ADDRESS(name) WinGetProcAddress(name)
#endif // _WIN32
#if defined(linux)
#include <dlfcn.h>
#include <stdio.h>
static void* GetProcAddress (const char* name)
{
static void* h = NULL;
if (!h)
{
h = dlopen("libclAmdFft.Runtime.so", RTLD_LAZY | RTLD_GLOBAL);
if (!h)
return NULL;
}
return dlsym(h, name);
}
#define CV_CL_GET_PROC_ADDRESS(name) GetProcAddress(name)
#endif
#ifndef CV_CL_GET_PROC_ADDRESS
#define CV_CL_GET_PROC_ADDRESS(name) NULL
#endif
@CL_FN_ENUMS@
@CL_FN_NAMES@
static void* openclamdfft_check_fn(int ID)
{
void* func = CV_CL_GET_PROC_ADDRESS(openclamdfft_fn_names[ID]);
if (!func)
{
std::ostringstream msg;
msg << "OpenCL AMD FFT function is not available: [" << openclamdfft_fn_names[ID] << "]";
CV_Error(CV_StsBadFunc, msg.str());
}
extern void* openclamdfft_fn_ptrs[];
*(void**)(openclamdfft_fn_ptrs[ID]) = func;
return func;
}
namespace {
@CL_FN_SWITCH@
}
@CL_FN_DEFINITIONS@
@CL_FN_PTRS@
#endif
modules/core/src/opencl/runtime/generator/template/ocl_clamdfft_runtime.hpp.in
deleted
100644 → 0
View file @
560cfa56
#ifndef __OPENCV_OCL_CLAMDFFT_RUNTIME_HPP__
#define __OPENCV_OCL_CLAMDFFT_RUNTIME_HPP__
#ifdef HAVE_CLAMDFFT
@CLAMDFFT_REMAP_ORIGIN@
#include <clAmdFft.h>
@CLAMDFFT_REMAP_DYNAMIC@
#ifndef CL_RUNTIME_EXPORT
#if (defined(BUILD_SHARED_LIBS) || defined(OPENCV_OCL_SHARED)) && (defined WIN32 || defined _WIN32 || defined WINCE)
#define CL_RUNTIME_EXPORT __declspec(dllimport)
#else
#define CL_RUNTIME_EXPORT
#endif
#endif
@CLAMDFFT_FN_DECLARATIONS@
#endif
#endif // __OPENCV_OCL_CLAMDFFT_RUNTIME_HPP__
modules/core/src/opencl/runtime/generator/template/ocl_runtime_impl_opencl.hpp.in
deleted
100644 → 0
View file @
560cfa56
@CL_FN_ENUMS@
@CL_FN_NAMES@
namespace {
@CL_FN_SWITCH@
}
@CL_FN_DEFINITIONS@
@CL_FN_PTRS@
modules/core/src/opencl/runtime/generator/template/ocl_runtime_opencl.hpp.in
deleted
100644 → 0
View file @
560cfa56
#ifndef __OPENCV_OCL_CL_RUNTIME_OPENCL_HPP__
#define __OPENCV_OCL_CL_RUNTIME_OPENCL_HPP__
@CL_REMAP_ORIGIN@
#if defined __APPLE__
#include <OpenCL/cl.h>
#else
#include <CL/cl.h>
#endif
@CL_REMAP_DYNAMIC@
#ifndef CL_RUNTIME_EXPORT
#if (defined(BUILD_SHARED_LIBS) || defined(OPENCV_OCL_SHARED)) && (defined WIN32 || defined _WIN32 || defined WINCE)
#define CL_RUNTIME_EXPORT __declspec(dllimport)
#else
#define CL_RUNTIME_EXPORT
#endif
#endif
@CL_FN_DECLARATIONS@
#endif // __OPENCV_OCL_CL_RUNTIME_OPENCL_HPP__
modules/core/src/opencl/runtime/generator/template/ocl_runtime_opencl_wrappers.hpp.in
deleted
100644 → 0
View file @
560cfa56
#ifndef __OPENCV_OCL_CL_RUNTIME_OPENCL_WRAPPERS_HPP__
#define __OPENCV_OCL_CL_RUNTIME_OPENCL_WRAPPERS_HPP__
@CL_FN_INLINE_WRAPPERS@
#endif // __OPENCV_OCL_CL_RUNTIME_OPENCL_WRAPPERS_HPP__
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment