mirror of
https://github.com/intel/compute-runtime.git
synced 2025-12-19 06:24:51 +08:00
Update OCL headers
Update headers to the OpenCL-Headers-2022.05.18 release: https://github.com/KhronosGroup/OpenCL-Headers/releases/tag/v2022.05.18 Related-to: NEO-7102 Signed-off-by: Naklicki, Mateusz <mateusz.naklicki@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
c86c518bc4
commit
fd867c1621
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2021 Intel Corporation
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -7,7 +7,7 @@
|
||||
|
||||
#include "level_zero/core/source/image/image_format_desc_helper.h"
|
||||
|
||||
#include "third_party/opencl_headers/CL/cl_ext_intel.h"
|
||||
#include "third_party/opencl_headers/CL/cl_ext.h"
|
||||
|
||||
namespace L0 {
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
#include "level_zero/core/test/unit_tests/mocks/mock_device.h"
|
||||
#include "level_zero/core/test/unit_tests/mocks/mock_image.h"
|
||||
|
||||
#include "third_party/opencl_headers/CL/cl_ext_intel.h"
|
||||
#include "third_party/opencl_headers/CL/cl_ext.h"
|
||||
|
||||
namespace L0 {
|
||||
namespace ult {
|
||||
|
||||
@@ -6,7 +6,9 @@
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "CL/cl.h"
|
||||
#include "CL/cl_ext.h"
|
||||
|
||||
/**********************************
|
||||
* Internal only queue properties *
|
||||
@@ -50,13 +52,16 @@
|
||||
**************************/
|
||||
|
||||
using cl_execution_info_kernel_type_intel = cl_uint;
|
||||
using cl_mem_flags_intel = cl_mem_flags;
|
||||
using cl_unified_shared_memory_capabilities_intel = cl_bitfield;
|
||||
|
||||
#if !defined(cl_intel_unified_shared_memory)
|
||||
using cl_mem_alloc_flags_intel = cl_bitfield;
|
||||
using cl_mem_properties_intel = cl_bitfield;
|
||||
using cl_mem_flags_intel = cl_mem_flags;
|
||||
using cl_mem_info_intel = cl_uint;
|
||||
using cl_mem_advice_intel = cl_uint;
|
||||
using cl_unified_shared_memory_type_intel = cl_uint;
|
||||
using cl_unified_shared_memory_capabilities_intel = cl_bitfield;
|
||||
#endif
|
||||
|
||||
/******************************
|
||||
* Internal only cl_mem_flags *
|
||||
@@ -84,6 +89,8 @@ using cl_unified_shared_memory_capabilities_intel = cl_bitfield;
|
||||
* UNIFIED MEMORY *
|
||||
*******************************/
|
||||
|
||||
#if !defined(cl_intel_unified_shared_memory)
|
||||
|
||||
/* cl_device_info */
|
||||
#define CL_DEVICE_HOST_MEM_CAPABILITIES_INTEL 0x4190
|
||||
#define CL_DEVICE_DEVICE_MEM_CAPABILITIES_INTEL 0x4191
|
||||
@@ -102,7 +109,6 @@ using cl_unified_shared_memory_capabilities_intel = cl_bitfield;
|
||||
#define CL_MEM_ALLOC_USE_HOST_PTR_INTEL 0x1000F
|
||||
|
||||
/* cl_mem_alloc_flags_intel - bitfield */
|
||||
#define CL_MEM_ALLOC_DEFAULT_INTEL 0
|
||||
#define CL_MEM_ALLOC_WRITE_COMBINED_INTEL (1 << 0)
|
||||
#define CL_MEM_ALLOC_INITIAL_PLACEMENT_DEVICE_INTEL (1 << 1)
|
||||
#define CL_MEM_ALLOC_INITIAL_PLACEMENT_HOST_INTEL (1 << 2)
|
||||
@@ -120,12 +126,22 @@ using cl_unified_shared_memory_capabilities_intel = cl_bitfield;
|
||||
#define CL_MEM_TYPE_SHARED_INTEL 0x4199
|
||||
|
||||
/* cl_command_type */
|
||||
#define CL_COMMAND_MEMSET_INTEL 0x4204
|
||||
#define CL_COMMAND_MEMFILL_INTEL 0x4204
|
||||
#define CL_COMMAND_MEMCPY_INTEL 0x4205
|
||||
#define CL_COMMAND_MIGRATEMEM_INTEL 0x4206
|
||||
#define CL_COMMAND_MEMADVISE_INTEL 0x4207
|
||||
|
||||
#endif
|
||||
|
||||
/* cl_mem_alloc_flags_intel - bitfield */
|
||||
#define CL_MEM_ALLOC_DEFAULT_INTEL 0
|
||||
|
||||
/* cl_mem_properties_intel */
|
||||
#define CL_MEM_ALLOC_USE_HOST_PTR_INTEL 0x1000F
|
||||
|
||||
/* cl_command_type */
|
||||
#define CL_COMMAND_MEMSET_INTEL 0x4204
|
||||
|
||||
/******************************
|
||||
* THREAD ARBITRATION POLICY *
|
||||
*******************************/
|
||||
@@ -134,10 +150,12 @@ using cl_unified_shared_memory_capabilities_intel = cl_bitfield;
|
||||
#define CL_DEVICE_SUPPORTED_THREAD_ARBITRATION_POLICY_INTEL 0x4208
|
||||
|
||||
/* cl_kernel_exec_info */
|
||||
#if !defined(cl_intel_unified_shared_memory)
|
||||
#define CL_KERNEL_EXEC_INFO_INDIRECT_HOST_ACCESS_INTEL 0x4200
|
||||
#define CL_KERNEL_EXEC_INFO_INDIRECT_DEVICE_ACCESS_INTEL 0x4201
|
||||
#define CL_KERNEL_EXEC_INFO_INDIRECT_SHARED_ACCESS_INTEL 0x4202
|
||||
#define CL_KERNEL_EXEC_INFO_USM_PTRS_INTEL 0x4203
|
||||
#endif
|
||||
|
||||
#define CL_KERNEL_EXEC_INFO_THREAD_ARBITRATION_POLICY_OLDEST_FIRST_INTEL 0x10022
|
||||
#define CL_KERNEL_EXEC_INFO_THREAD_ARBITRATION_POLICY_ROUND_ROBIN_INTEL 0x10023
|
||||
@@ -159,6 +177,8 @@ using cl_unified_shared_memory_capabilities_intel = cl_bitfield;
|
||||
* QUEUE FAMILY SELECTING *
|
||||
*******************************/
|
||||
|
||||
#if !defined(cl_intel_command_queue_families)
|
||||
|
||||
/* cl_device_info */
|
||||
#define CL_DEVICE_QUEUE_FAMILY_PROPERTIES_INTEL 0x418B
|
||||
|
||||
@@ -167,7 +187,7 @@ using cl_unified_shared_memory_capabilities_intel = cl_bitfield;
|
||||
#define CL_QUEUE_INDEX_INTEL 0x418D
|
||||
|
||||
/* cl_command_queue_capabilities_intel */
|
||||
#define CL_QUEUE_DEFAULT_CAPABILITIES_INTEL 0u
|
||||
#define CL_QUEUE_DEFAULT_CAPABILITIES_INTEL 0
|
||||
#define CL_QUEUE_CAPABILITY_CREATE_SINGLE_QUEUE_EVENTS_INTEL (1 << 0)
|
||||
#define CL_QUEUE_CAPABILITY_CREATE_CROSS_QUEUE_EVENTS_INTEL (1 << 1)
|
||||
#define CL_QUEUE_CAPABILITY_SINGLE_QUEUE_EVENT_WAIT_LIST_INTEL (1 << 2)
|
||||
@@ -195,10 +215,14 @@ typedef struct _cl_queue_family_properties_intel {
|
||||
char name[CL_QUEUE_FAMILY_MAX_NAME_SIZE_INTEL];
|
||||
} cl_queue_family_properties_intel;
|
||||
|
||||
#endif
|
||||
|
||||
/******************************
|
||||
* DEVICE ATTRIBUTE QUERY *
|
||||
*******************************/
|
||||
|
||||
#if !defined(cl_intel_device_attribute_query)
|
||||
|
||||
/* For GPU devices, version 1.0.0: */
|
||||
#define CL_DEVICE_IP_VERSION_INTEL 0x4250
|
||||
#define CL_DEVICE_ID_INTEL 0x4251
|
||||
@@ -213,6 +237,8 @@ typedef cl_bitfield cl_device_feature_capabilities_intel;
|
||||
/* For GPU devices, version 1.0.0: */
|
||||
#define CL_DEVICE_FEATURE_FLAG_DP4A_INTEL (1 << 0)
|
||||
|
||||
#endif
|
||||
|
||||
////// RESOURCE BARRIER EXT
|
||||
#define CL_COMMAND_RESOURCE_BARRIER 0x10010
|
||||
|
||||
@@ -237,6 +263,9 @@ typedef struct _cl_resource_barrier_descriptor_intel {
|
||||
/****************************************
|
||||
* cl_khr_pci_bus_info extension *
|
||||
***************************************/
|
||||
|
||||
#if !defined(cl_khr_pci_bus_info)
|
||||
|
||||
#define cl_khr_pci_bus_info 1
|
||||
|
||||
// New queries for clGetDeviceInfo:
|
||||
@@ -249,6 +278,8 @@ typedef struct _cl_device_pci_bus_info_khr {
|
||||
cl_uint pci_function;
|
||||
} cl_device_pci_bus_info_khr;
|
||||
|
||||
#endif
|
||||
|
||||
/************************************************
|
||||
* cl_intel_mem_compression_hints extension *
|
||||
*************************************************/
|
||||
@@ -271,6 +302,8 @@ typedef cl_bitfield cl_command_queue_mdapi_properties_intel;
|
||||
* cl_khr_external_memory extension *
|
||||
*************************************************/
|
||||
|
||||
#if !defined(cl_khr_external_memory)
|
||||
|
||||
/* clGetPlatformInfo */
|
||||
#define CL_PLATFORM_EXTERNAL_MEMORY_IMPORT_HANDLE_TYPES_KHR 0x2044
|
||||
|
||||
@@ -281,11 +314,24 @@ typedef cl_bitfield cl_command_queue_mdapi_properties_intel;
|
||||
#define CL_DEVICE_HANDLE_LIST_KHR 0x2051
|
||||
#define CL_DEVICE_HANDLE_LIST_END_KHR 0
|
||||
|
||||
#endif
|
||||
|
||||
#if !defined(cl_khr_external_memory_opaque_fd)
|
||||
#define CL_EXTERNAL_MEMORY_HANDLE_OPAQUE_FD_KHR 0x2060
|
||||
#endif
|
||||
|
||||
#if !defined(cl_khr_external_memory_win32)
|
||||
#define CL_EXTERNAL_MEMORY_HANDLE_OPAQUE_WIN32_KHR 0x2061
|
||||
#define CL_EXTERNAL_MEMORY_HANDLE_OPAQUE_WIN32_KMT_KHR 0x2062
|
||||
#endif
|
||||
|
||||
#if !defined(cl_khr_external_memory_dx)
|
||||
#define CL_EXTERNAL_MEMORY_HANDLE_D3D11_TEXTURE_KHR 0x2063
|
||||
#define CL_EXTERNAL_MEMORY_HANDLE_D3D11_TEXTURE_KMT_KHR 0x2064
|
||||
#define CL_EXTERNAL_MEMORY_HANDLE_D3D12_HEAP_KHR 0x2065
|
||||
#define CL_EXTERNAL_MEMORY_HANDLE_D3D12_RESOURCE_KHR 0x2066
|
||||
#endif
|
||||
|
||||
#if !defined(cl_khr_external_memory_dma_buf)
|
||||
#define CL_EXTERNAL_MEMORY_HANDLE_DMA_BUF_KHR 0x2067
|
||||
#endif
|
||||
|
||||
@@ -3821,7 +3821,7 @@ clSetPerformanceConfigurationINTEL(
|
||||
return CL_INVALID_OPERATION;
|
||||
}
|
||||
|
||||
void *clHostMemAllocINTEL(
|
||||
CL_API_ENTRY void *CL_API_CALL clHostMemAllocINTEL(
|
||||
cl_context context,
|
||||
const cl_mem_properties_intel *properties,
|
||||
size_t size,
|
||||
@@ -3861,7 +3861,7 @@ void *clHostMemAllocINTEL(
|
||||
return neoContext->getSVMAllocsManager()->createHostUnifiedMemoryAllocation(size, unifiedMemoryProperties);
|
||||
}
|
||||
|
||||
void *clDeviceMemAllocINTEL(
|
||||
CL_API_ENTRY void *CL_API_CALL clDeviceMemAllocINTEL(
|
||||
cl_context context,
|
||||
cl_device_id device,
|
||||
const cl_mem_properties_intel *properties,
|
||||
@@ -3909,7 +3909,7 @@ void *clDeviceMemAllocINTEL(
|
||||
return neoContext->getSVMAllocsManager()->createUnifiedMemoryAllocation(size, unifiedMemoryProperties);
|
||||
}
|
||||
|
||||
void *clSharedMemAllocINTEL(
|
||||
CL_API_ENTRY void *CL_API_CALL clSharedMemAllocINTEL(
|
||||
cl_context context,
|
||||
cl_device_id device,
|
||||
const cl_mem_properties_intel *properties,
|
||||
@@ -3967,9 +3967,9 @@ void *clSharedMemAllocINTEL(
|
||||
return ptr;
|
||||
}
|
||||
|
||||
cl_int clMemFreeCommon(cl_context context,
|
||||
const void *ptr,
|
||||
bool blocking) {
|
||||
CL_API_ENTRY cl_int CL_API_CALL clMemFreeCommon(cl_context context,
|
||||
const void *ptr,
|
||||
bool blocking) {
|
||||
Context *neoContext = nullptr;
|
||||
auto retVal = validateObjects(withCastToInternal(context, &neoContext));
|
||||
|
||||
@@ -3988,19 +3988,19 @@ cl_int clMemFreeCommon(cl_context context,
|
||||
return CL_SUCCESS;
|
||||
}
|
||||
|
||||
cl_int clMemFreeINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clMemFreeINTEL(
|
||||
cl_context context,
|
||||
void *ptr) {
|
||||
return clMemFreeCommon(context, ptr, false);
|
||||
}
|
||||
|
||||
cl_int clMemBlockingFreeINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clMemBlockingFreeINTEL(
|
||||
cl_context context,
|
||||
void *ptr) {
|
||||
return clMemFreeCommon(context, ptr, true);
|
||||
}
|
||||
|
||||
cl_int clGetMemAllocInfoINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clGetMemAllocInfoINTEL(
|
||||
cl_context context,
|
||||
const void *ptr,
|
||||
cl_mem_info_intel paramName,
|
||||
@@ -4073,14 +4073,14 @@ cl_int clGetMemAllocInfoINTEL(
|
||||
return CL_INVALID_VALUE;
|
||||
}
|
||||
|
||||
cl_int clSetKernelArgMemPointerINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clSetKernelArgMemPointerINTEL(
|
||||
cl_kernel kernel,
|
||||
cl_uint argIndex,
|
||||
const void *argValue) {
|
||||
return clSetKernelArgSVMPointer(kernel, argIndex, argValue);
|
||||
}
|
||||
|
||||
cl_int clEnqueueMemsetINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clEnqueueMemsetINTEL(
|
||||
cl_command_queue commandQueue,
|
||||
void *dstPtr,
|
||||
cl_int value,
|
||||
@@ -4104,7 +4104,7 @@ cl_int clEnqueueMemsetINTEL(
|
||||
return retVal;
|
||||
}
|
||||
|
||||
cl_int clEnqueueMemFillINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clEnqueueMemFillINTEL(
|
||||
cl_command_queue commandQueue,
|
||||
void *dstPtr,
|
||||
const void *pattern,
|
||||
@@ -4130,7 +4130,7 @@ cl_int clEnqueueMemFillINTEL(
|
||||
return retVal;
|
||||
}
|
||||
|
||||
cl_int clEnqueueMemcpyINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clEnqueueMemcpyINTEL(
|
||||
cl_command_queue commandQueue,
|
||||
cl_bool blocking,
|
||||
void *dstPtr,
|
||||
@@ -4155,7 +4155,7 @@ cl_int clEnqueueMemcpyINTEL(
|
||||
return retVal;
|
||||
}
|
||||
|
||||
cl_int clEnqueueMigrateMemINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clEnqueueMigrateMemINTEL(
|
||||
cl_command_queue commandQueue,
|
||||
const void *ptr,
|
||||
size_t size,
|
||||
@@ -4180,7 +4180,7 @@ cl_int clEnqueueMigrateMemINTEL(
|
||||
return retVal;
|
||||
}
|
||||
|
||||
cl_int clEnqueueMemAdviseINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clEnqueueMemAdviseINTEL(
|
||||
cl_command_queue commandQueue,
|
||||
const void *ptr,
|
||||
size_t size,
|
||||
|
||||
@@ -921,7 +921,7 @@ extern CL_API_ENTRY cl_event CL_API_CALL
|
||||
clCreateEventFromGLsyncKHR(
|
||||
cl_context context,
|
||||
cl_GLsync sync,
|
||||
cl_int *errcodeRet) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
cl_int *errcodeRet) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
extern CL_API_ENTRY cl_program CL_API_CALL clCreateProgramWithILKHR(
|
||||
cl_context context,
|
||||
@@ -937,14 +937,14 @@ extern CL_API_ENTRY cl_int CL_API_CALL clGetKernelSuggestedLocalWorkSizeKHR(
|
||||
const size_t *globalWorkSize,
|
||||
size_t *suggestedLocalWorkSize) CL_API_SUFFIX__VERSION_3_0;
|
||||
|
||||
void *clHostMemAllocINTEL(
|
||||
CL_API_ENTRY void *CL_API_CALL clHostMemAllocINTEL(
|
||||
cl_context context,
|
||||
const cl_mem_properties_intel *properties,
|
||||
size_t size,
|
||||
cl_uint alignment,
|
||||
cl_int *errcodeRet);
|
||||
|
||||
void *clDeviceMemAllocINTEL(
|
||||
CL_API_ENTRY void *CL_API_CALL clDeviceMemAllocINTEL(
|
||||
cl_context context,
|
||||
cl_device_id device,
|
||||
const cl_mem_properties_intel *properties,
|
||||
@@ -952,7 +952,7 @@ void *clDeviceMemAllocINTEL(
|
||||
cl_uint alignment,
|
||||
cl_int *errcodeRet);
|
||||
|
||||
void *clSharedMemAllocINTEL(
|
||||
CL_API_ENTRY void *CL_API_CALL clSharedMemAllocINTEL(
|
||||
cl_context context,
|
||||
cl_device_id device,
|
||||
const cl_mem_properties_intel *properties,
|
||||
@@ -960,15 +960,15 @@ void *clSharedMemAllocINTEL(
|
||||
cl_uint alignment,
|
||||
cl_int *errcodeRet);
|
||||
|
||||
cl_int clMemFreeINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clMemFreeINTEL(
|
||||
cl_context context,
|
||||
void *ptr);
|
||||
|
||||
cl_int clMemBlockingFreeINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clMemBlockingFreeINTEL(
|
||||
cl_context context,
|
||||
void *ptr);
|
||||
|
||||
cl_int clGetMemAllocInfoINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clGetMemAllocInfoINTEL(
|
||||
cl_context context,
|
||||
const void *ptr,
|
||||
cl_mem_info_intel paramName,
|
||||
@@ -976,12 +976,12 @@ cl_int clGetMemAllocInfoINTEL(
|
||||
void *paramValue,
|
||||
size_t *paramValueSizeRet);
|
||||
|
||||
cl_int clSetKernelArgMemPointerINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clSetKernelArgMemPointerINTEL(
|
||||
cl_kernel kernel,
|
||||
cl_uint argIndex,
|
||||
const void *argValue);
|
||||
|
||||
cl_int clEnqueueMemsetINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clEnqueueMemsetINTEL(
|
||||
cl_command_queue commandQueue,
|
||||
void *dstPtr,
|
||||
cl_int value,
|
||||
@@ -990,7 +990,7 @@ cl_int clEnqueueMemsetINTEL(
|
||||
const cl_event *eventWaitList,
|
||||
cl_event *event);
|
||||
|
||||
cl_int clEnqueueMemFillINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clEnqueueMemFillINTEL(
|
||||
cl_command_queue commandQueue,
|
||||
void *dstPtr,
|
||||
const void *pattern,
|
||||
@@ -1000,7 +1000,7 @@ cl_int clEnqueueMemFillINTEL(
|
||||
const cl_event *eventWaitList,
|
||||
cl_event *event);
|
||||
|
||||
cl_int clEnqueueMemcpyINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clEnqueueMemcpyINTEL(
|
||||
cl_command_queue commandQueue,
|
||||
cl_bool blocking,
|
||||
void *dstPtr,
|
||||
@@ -1010,7 +1010,7 @@ cl_int clEnqueueMemcpyINTEL(
|
||||
const cl_event *eventWaitList,
|
||||
cl_event *event);
|
||||
|
||||
cl_int clEnqueueMigrateMemINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clEnqueueMigrateMemINTEL(
|
||||
cl_command_queue commandQueue,
|
||||
const void *ptr,
|
||||
size_t size,
|
||||
@@ -1019,7 +1019,7 @@ cl_int clEnqueueMigrateMemINTEL(
|
||||
const cl_event *eventWaitList,
|
||||
cl_event *event);
|
||||
|
||||
cl_int clEnqueueMemAdviseINTEL(
|
||||
CL_API_ENTRY cl_int CL_API_CALL clEnqueueMemAdviseINTEL(
|
||||
cl_command_queue commandQueue,
|
||||
const void *ptr,
|
||||
size_t size,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2021 Intel Corporation
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -9,9 +9,7 @@
|
||||
|
||||
#include "CL/cl.h"
|
||||
#include "CL/cl_ext.h"
|
||||
#include "CL/cl_ext_intel.h"
|
||||
#include "CL/cl_gl.h"
|
||||
#include "CL/cl_gl_ext.h"
|
||||
#if defined(_WIN32)
|
||||
#include <d3d10_1.h>
|
||||
|
||||
@@ -21,7 +19,7 @@
|
||||
#define CL_DX9_MEDIA_SHARING_INTEL_EXT
|
||||
#include "shared/source/os_interface/windows/windows_wrapper.h"
|
||||
|
||||
#include "CL/cl_dx9_media_sharing_intel.h"
|
||||
#include "CL/cl_dx9_media_sharing.h"
|
||||
#else
|
||||
#define CL_CONTEXT_D3D10_DEVICE_KHR 0x4014
|
||||
#define CL_CONTEXT_D3D10_PREFER_SHARED_RESOURCES_KHR 0x402C
|
||||
@@ -149,7 +147,7 @@ typedef CL_API_ENTRY cl_mem(CL_API_CALL *KHRpfn_clCreateBuffer)(
|
||||
void *hostPtr,
|
||||
cl_int *errcodeRet) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED
|
||||
typedef CL_API_ENTRY CL_API_PREFIX__VERSION_1_1_DEPRECATED
|
||||
cl_mem(CL_API_CALL *KHRpfn_clCreateImage2D)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
@@ -158,9 +156,9 @@ cl_mem(CL_API_CALL *KHRpfn_clCreateImage2D)(
|
||||
size_t imageHeight,
|
||||
size_t imageRowPitch,
|
||||
void *hostPtr,
|
||||
cl_int *errcodeRet) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
cl_int *errcodeRet) CL_API_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
typedef CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED
|
||||
typedef CL_API_ENTRY CL_API_PREFIX__VERSION_1_1_DEPRECATED
|
||||
cl_mem(CL_API_CALL *KHRpfn_clCreateImage3D)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
@@ -171,7 +169,7 @@ cl_mem(CL_API_CALL *KHRpfn_clCreateImage3D)(
|
||||
size_t imageRowPitch,
|
||||
size_t imageSlicePitch,
|
||||
void *hostPtr,
|
||||
cl_int *errcodeRet) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
cl_int *errcodeRet) CL_API_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
typedef CL_API_ENTRY cl_int(CL_API_CALL *KHRpfn_clRetainMemObject)(
|
||||
cl_mem memobj) CL_API_SUFFIX__VERSION_1_0;
|
||||
@@ -273,8 +271,8 @@ typedef CL_API_ENTRY cl_int(CL_API_CALL *KHRpfn_clBuildProgram)(
|
||||
prog_logging_fn funcNotify,
|
||||
void *userData) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED
|
||||
cl_int(CL_API_CALL *KHRpfn_clUnloadCompiler)() CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
typedef CL_API_ENTRY CL_API_PREFIX__VERSION_1_1_DEPRECATED
|
||||
cl_int(CL_API_CALL *KHRpfn_clUnloadCompiler)() CL_API_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
typedef CL_API_ENTRY cl_int(CL_API_CALL *KHRpfn_clGetProgramInfo)(
|
||||
cl_program program,
|
||||
@@ -520,23 +518,23 @@ typedef CL_API_ENTRY cl_int(CL_API_CALL *KHRpfn_clEnqueueNativeKernel)(
|
||||
const cl_event *eventWaitList,
|
||||
cl_event *event) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED
|
||||
typedef CL_API_ENTRY CL_API_PREFIX__VERSION_1_1_DEPRECATED
|
||||
cl_int(CL_API_CALL *KHRpfn_clEnqueueMarker)(
|
||||
cl_command_queue commandQueue,
|
||||
cl_event *event) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
cl_event *event) CL_API_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
typedef CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED
|
||||
typedef CL_API_ENTRY CL_API_PREFIX__VERSION_1_1_DEPRECATED
|
||||
cl_int(CL_API_CALL *KHRpfn_clEnqueueWaitForEvents)(
|
||||
cl_command_queue commandQueue,
|
||||
cl_uint numEvents,
|
||||
const cl_event *eventList) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
const cl_event *eventList) CL_API_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
typedef CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED
|
||||
typedef CL_API_ENTRY CL_API_PREFIX__VERSION_1_1_DEPRECATED
|
||||
cl_int(CL_API_CALL *KHRpfn_clEnqueueBarrier)(
|
||||
cl_command_queue commandQueue) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
cl_command_queue commandQueue) CL_API_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
typedef CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED void *(CL_API_CALL *KHRpfn_clGetExtensionFunctionAddress)(
|
||||
const char *functionName)CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
typedef CL_API_ENTRY CL_API_PREFIX__VERSION_1_1_DEPRECATED void *(CL_API_CALL *KHRpfn_clGetExtensionFunctionAddress)(
|
||||
const char *functionName)CL_API_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
typedef CL_API_ENTRY cl_mem(CL_API_CALL *KHRpfn_clCreateFromGLBuffer)(
|
||||
cl_context context,
|
||||
@@ -552,21 +550,21 @@ typedef CL_API_ENTRY cl_mem(CL_API_CALL *KHRpfn_clCreateFromGLTexture)(
|
||||
cl_GLuint texture,
|
||||
cl_int *errcodeRet) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED cl_mem(CL_API_CALL *KHRpfn_clCreateFromGLTexture2D)(
|
||||
typedef CL_API_ENTRY CL_API_PREFIX__VERSION_1_1_DEPRECATED cl_mem(CL_API_CALL *KHRpfn_clCreateFromGLTexture2D)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_GLenum textureTarget,
|
||||
cl_GLint miplevel,
|
||||
cl_GLuint texture,
|
||||
cl_int *errcodeRet) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
cl_int *errcodeRet) CL_API_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
typedef CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED cl_mem(CL_API_CALL *KHRpfn_clCreateFromGLTexture3D)(
|
||||
typedef CL_API_ENTRY CL_API_PREFIX__VERSION_1_1_DEPRECATED cl_mem(CL_API_CALL *KHRpfn_clCreateFromGLTexture3D)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_GLenum textureTarget,
|
||||
cl_GLint miplevel,
|
||||
cl_GLuint texture,
|
||||
cl_int *errcodeRet) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
cl_int *errcodeRet) CL_API_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
typedef CL_API_ENTRY cl_mem(CL_API_CALL *KHRpfn_clCreateFromGLRenderbuffer)(
|
||||
cl_context context,
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2021 Intel Corporation
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -12,7 +12,7 @@
|
||||
#include "opencl/source/cl_device/cl_device.h"
|
||||
#include "opencl/source/cl_device/cl_device_info.h"
|
||||
|
||||
#include "CL/cl_ext_intel.h"
|
||||
#include "CL/cl_ext.h"
|
||||
#include <CL/cl.h>
|
||||
#include <CL/cl_ext.h>
|
||||
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2021 Intel Corporation
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
#include "CL/cl_ext_intel.h"
|
||||
#include "CL/cl_ext.h"
|
||||
|
||||
namespace NEO {
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
#pragma once
|
||||
|
||||
#include "CL/cl.h"
|
||||
#include "CL/cl_gl_ext.h"
|
||||
#include "CL/cl_gl.h"
|
||||
|
||||
#include <string>
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2020-2021 Intel Corporation
|
||||
* Copyright (C) 2020-2022 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -10,7 +10,7 @@
|
||||
#include "opencl/extensions/public/cl_ext_private.h"
|
||||
#include "opencl/source/helpers/cl_memory_properties_helpers.h"
|
||||
|
||||
#include "CL/cl_ext_intel.h"
|
||||
#include "CL/cl_ext.h"
|
||||
|
||||
namespace NEO {
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2018-2021 Intel Corporation
|
||||
* Copyright (C) 2018-2022 Intel Corporation
|
||||
*
|
||||
* SPDX-License-Identifier: MIT
|
||||
*
|
||||
@@ -14,7 +14,7 @@
|
||||
#include "CL/cl_d3d11.h"
|
||||
#include "CL/cl_dx9_media_sharing.h"
|
||||
#define CL_DX9_MEDIA_SHARING_INTEL_EXT
|
||||
#include "CL/cl_dx9_media_sharing_intel.h"
|
||||
#include "CL/cl_dx9_media_sharing.h"
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL clGetDeviceIDsFromDX9INTEL(
|
||||
cl_platform_id platform,
|
||||
|
||||
@@ -745,8 +745,8 @@ HWTEST_F(QueueFamiliesTests, whenGettingQueueFamilyCapabilitiesAllThenReturnCorr
|
||||
|
||||
HWTEST_F(QueueFamiliesTests, givenComputeQueueWhenGettingQueueFamilyCapabilitiesThenReturnDefaultCapabilities) {
|
||||
auto device = std::make_unique<MockClDevice>(MockDevice::createWithNewExecutionEnvironment<MockDevice>(defaultHwInfo.get()));
|
||||
EXPECT_EQ(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL, device->getQueueFamilyCapabilities(NEO::EngineGroupType::Compute));
|
||||
EXPECT_EQ(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL, device->getQueueFamilyCapabilities(NEO::EngineGroupType::RenderCompute));
|
||||
EXPECT_EQ(static_cast<uint64_t>(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL), device->getQueueFamilyCapabilities(NEO::EngineGroupType::Compute));
|
||||
EXPECT_EQ(static_cast<uint64_t>(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL), device->getQueueFamilyCapabilities(NEO::EngineGroupType::RenderCompute));
|
||||
}
|
||||
|
||||
HWCMDTEST_F(IGFX_GEN8_CORE, QueueFamiliesTests, givenCopyQueueWhenGettingQueueFamilyCapabilitiesThenDoNotReturnUnsupportedOperations) {
|
||||
|
||||
@@ -733,7 +733,7 @@ HWTEST_F(GetDeviceInfoQueueFamilyTest, givenSingleDeviceWhenInitializingCapsThen
|
||||
EXPECT_EQ(CL_SUCCESS, retVal);
|
||||
EXPECT_EQ(2u, paramRetSize / sizeof(cl_queue_family_properties_intel));
|
||||
|
||||
EXPECT_EQ(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL, families[0].capabilities);
|
||||
EXPECT_EQ(static_cast<uint64_t>(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL), families[0].capabilities);
|
||||
EXPECT_EQ(3u, families[0].count);
|
||||
EXPECT_EQ(clDevice.getDeviceInfo().queueOnHostProperties, families[0].properties);
|
||||
|
||||
@@ -756,7 +756,7 @@ HWTEST_F(GetDeviceInfoQueueFamilyTest, givenSubDeviceWhenInitializingCapsThenRet
|
||||
EXPECT_EQ(CL_SUCCESS, retVal);
|
||||
EXPECT_EQ(2u, paramRetSize / sizeof(cl_queue_family_properties_intel));
|
||||
|
||||
EXPECT_EQ(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL, families[0].capabilities);
|
||||
EXPECT_EQ(static_cast<uint64_t>(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL), families[0].capabilities);
|
||||
EXPECT_EQ(3u, families[0].count);
|
||||
EXPECT_EQ(clDevice.getDeviceInfo().queueOnHostProperties, families[0].properties);
|
||||
|
||||
@@ -791,7 +791,7 @@ HWTEST_F(GetDeviceInfoQueueFamilyTest, givenSubDeviceWithoutSupportedEngineWhenI
|
||||
EXPECT_EQ(CL_SUCCESS, retVal);
|
||||
EXPECT_EQ(2u, paramRetSize / sizeof(cl_queue_family_properties_intel));
|
||||
|
||||
EXPECT_EQ(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL, families[0].capabilities);
|
||||
EXPECT_EQ(static_cast<uint64_t>(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL), families[0].capabilities);
|
||||
EXPECT_EQ(3u, families[0].count);
|
||||
EXPECT_EQ(clDevice0.getDeviceInfo().queueOnHostProperties, families[0].properties);
|
||||
|
||||
@@ -807,7 +807,7 @@ HWTEST_F(GetDeviceInfoQueueFamilyTest, givenSubDeviceWithoutSupportedEngineWhenI
|
||||
EXPECT_EQ(CL_SUCCESS, retVal);
|
||||
EXPECT_EQ(1u, paramRetSize / sizeof(cl_queue_family_properties_intel));
|
||||
|
||||
EXPECT_EQ(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL, families[0].capabilities);
|
||||
EXPECT_EQ(static_cast<uint64_t>(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL), families[0].capabilities);
|
||||
EXPECT_EQ(3u, families[0].count);
|
||||
EXPECT_EQ(clDevice1.getDeviceInfo().queueOnHostProperties, families[0].properties);
|
||||
|
||||
@@ -831,7 +831,7 @@ HWTEST_F(GetDeviceInfoQueueFamilyTest, givenDeviceRootDeviceWhenInitializingCaps
|
||||
EXPECT_EQ(CL_SUCCESS, retVal);
|
||||
EXPECT_EQ(1u, paramRetSize / sizeof(cl_queue_family_properties_intel));
|
||||
|
||||
EXPECT_EQ(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL, families[0].capabilities);
|
||||
EXPECT_EQ(static_cast<uint64_t>(CL_QUEUE_DEFAULT_CAPABILITIES_INTEL), families[0].capabilities);
|
||||
EXPECT_EQ(1u, families[0].count);
|
||||
EXPECT_EQ(clDevice.getDeviceInfo().queueOnHostProperties, families[0].properties);
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
#include "opencl/test/unit_test/mocks/mock_cl_device.h"
|
||||
#include "opencl/test/unit_test/mocks/mock_context.h"
|
||||
|
||||
#include "CL/cl_ext_intel.h"
|
||||
#include "CL/cl_ext.h"
|
||||
#include "gtest/gtest.h"
|
||||
#include "memory_properties_flags.h"
|
||||
|
||||
|
||||
1250
third_party/opencl_headers/CL/cl.h
vendored
1250
third_party/opencl_headers/CL/cl.h
vendored
File diff suppressed because it is too large
Load Diff
87
third_party/opencl_headers/CL/cl_d3d10.h
vendored
87
third_party/opencl_headers/CL/cl_d3d10.h
vendored
@@ -1,37 +1,35 @@
|
||||
/**********************************************************************************
|
||||
* Copyright (c) 2008-2015 The Khronos Group Inc.
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2008-2020 The Khronos Group Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and/or associated documentation files (the
|
||||
* "Materials"), to deal in the Materials without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
* permit persons to whom the Materials are furnished to do so, subject to
|
||||
* the following conditions:
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Materials.
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
|
||||
* KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
|
||||
* SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
|
||||
* https://www.khronos.org/registry/
|
||||
*
|
||||
* THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
**********************************************************************************/
|
||||
|
||||
/* $Revision: 11708 $ on $Date: 2010-06-13 23:36:24 -0700 (Sun, 13 Jun 2010) $ */
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
******************************************************************************/
|
||||
|
||||
#ifndef __OPENCL_CL_D3D10_H
|
||||
#define __OPENCL_CL_D3D10_H
|
||||
|
||||
#if defined(_MSC_VER)
|
||||
#if _MSC_VER >=1500
|
||||
#pragma warning( push )
|
||||
#pragma warning( disable : 4201 )
|
||||
#pragma warning( disable : 5105 )
|
||||
#endif
|
||||
#endif
|
||||
#include <d3d10.h>
|
||||
#if defined(_MSC_VER)
|
||||
#if _MSC_VER >=1500
|
||||
#pragma warning( pop )
|
||||
#endif
|
||||
#endif
|
||||
#include <CL/cl.h>
|
||||
#include <CL/cl_platform.h>
|
||||
|
||||
@@ -78,7 +76,7 @@ typedef cl_uint cl_d3d10_device_set_khr;
|
||||
|
||||
/******************************************************************************/
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clGetDeviceIDsFromD3D10KHR_fn)(
|
||||
typedef cl_int (CL_API_CALL *clGetDeviceIDsFromD3D10KHR_fn)(
|
||||
cl_platform_id platform,
|
||||
cl_d3d10_device_source_khr d3d_device_source,
|
||||
void * d3d_object,
|
||||
@@ -87,27 +85,27 @@ typedef CL_API_ENTRY cl_int (CL_API_CALL *clGetDeviceIDsFromD3D10KHR_fn)(
|
||||
cl_device_id * devices,
|
||||
cl_uint * num_devices) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY cl_mem (CL_API_CALL *clCreateFromD3D10BufferKHR_fn)(
|
||||
typedef cl_mem (CL_API_CALL *clCreateFromD3D10BufferKHR_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
ID3D10Buffer * resource,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY cl_mem (CL_API_CALL *clCreateFromD3D10Texture2DKHR_fn)(
|
||||
typedef cl_mem (CL_API_CALL *clCreateFromD3D10Texture2DKHR_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
ID3D10Texture2D * resource,
|
||||
UINT subresource,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY cl_mem (CL_API_CALL *clCreateFromD3D10Texture3DKHR_fn)(
|
||||
typedef cl_mem (CL_API_CALL *clCreateFromD3D10Texture3DKHR_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
ID3D10Texture3D * resource,
|
||||
UINT subresource,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueAcquireD3D10ObjectsKHR_fn)(
|
||||
typedef cl_int (CL_API_CALL *clEnqueueAcquireD3D10ObjectsKHR_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
@@ -115,7 +113,7 @@ typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueAcquireD3D10ObjectsKHR_fn)(
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueReleaseD3D10ObjectsKHR_fn)(
|
||||
typedef cl_int (CL_API_CALL *clEnqueueReleaseD3D10ObjectsKHR_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
@@ -123,6 +121,31 @@ typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueReleaseD3D10ObjectsKHR_fn)(
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
/***************************************************************
|
||||
* cl_intel_sharing_format_query_d3d10
|
||||
***************************************************************/
|
||||
#define cl_intel_sharing_format_query_d3d10 1
|
||||
|
||||
/* when cl_khr_d3d10_sharing is supported */
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clGetSupportedD3D10TextureFormatsINTEL(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_mem_object_type image_type,
|
||||
cl_uint num_entries,
|
||||
DXGI_FORMAT* d3d10_formats,
|
||||
cl_uint* num_texture_formats) ;
|
||||
|
||||
typedef cl_int (CL_API_CALL *
|
||||
clGetSupportedD3D10TextureFormatsINTEL_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_mem_object_type image_type,
|
||||
cl_uint num_entries,
|
||||
DXGI_FORMAT* d3d10_formats,
|
||||
cl_uint* num_texture_formats) ;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
89
third_party/opencl_headers/CL/cl_d3d11.h
vendored
89
third_party/opencl_headers/CL/cl_d3d11.h
vendored
@@ -1,37 +1,35 @@
|
||||
/**********************************************************************************
|
||||
* Copyright (c) 2008-2015 The Khronos Group Inc.
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2008-2020 The Khronos Group Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and/or associated documentation files (the
|
||||
* "Materials"), to deal in the Materials without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
* permit persons to whom the Materials are furnished to do so, subject to
|
||||
* the following conditions:
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Materials.
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
|
||||
* KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
|
||||
* SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
|
||||
* https://www.khronos.org/registry/
|
||||
*
|
||||
* THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
**********************************************************************************/
|
||||
|
||||
/* $Revision: 11708 $ on $Date: 2010-06-13 23:36:24 -0700 (Sun, 13 Jun 2010) $ */
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
******************************************************************************/
|
||||
|
||||
#ifndef __OPENCL_CL_D3D11_H
|
||||
#define __OPENCL_CL_D3D11_H
|
||||
|
||||
#if defined(_MSC_VER)
|
||||
#if _MSC_VER >=1500
|
||||
#pragma warning( push )
|
||||
#pragma warning( disable : 4201 )
|
||||
#pragma warning( disable : 5105 )
|
||||
#endif
|
||||
#endif
|
||||
#include <d3d11.h>
|
||||
#if defined(_MSC_VER)
|
||||
#if _MSC_VER >=1500
|
||||
#pragma warning( pop )
|
||||
#endif
|
||||
#endif
|
||||
#include <CL/cl.h>
|
||||
#include <CL/cl_platform.h>
|
||||
|
||||
@@ -78,7 +76,7 @@ typedef cl_uint cl_d3d11_device_set_khr;
|
||||
|
||||
/******************************************************************************/
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clGetDeviceIDsFromD3D11KHR_fn)(
|
||||
typedef cl_int (CL_API_CALL *clGetDeviceIDsFromD3D11KHR_fn)(
|
||||
cl_platform_id platform,
|
||||
cl_d3d11_device_source_khr d3d_device_source,
|
||||
void * d3d_object,
|
||||
@@ -87,27 +85,27 @@ typedef CL_API_ENTRY cl_int (CL_API_CALL *clGetDeviceIDsFromD3D11KHR_fn)(
|
||||
cl_device_id * devices,
|
||||
cl_uint * num_devices) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_mem (CL_API_CALL *clCreateFromD3D11BufferKHR_fn)(
|
||||
typedef cl_mem (CL_API_CALL *clCreateFromD3D11BufferKHR_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
ID3D11Buffer * resource,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_mem (CL_API_CALL *clCreateFromD3D11Texture2DKHR_fn)(
|
||||
typedef cl_mem (CL_API_CALL *clCreateFromD3D11Texture2DKHR_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
ID3D11Texture2D * resource,
|
||||
UINT subresource,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_mem (CL_API_CALL *clCreateFromD3D11Texture3DKHR_fn)(
|
||||
typedef cl_mem (CL_API_CALL *clCreateFromD3D11Texture3DKHR_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
ID3D11Texture3D * resource,
|
||||
UINT subresource,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueAcquireD3D11ObjectsKHR_fn)(
|
||||
typedef cl_int (CL_API_CALL *clEnqueueAcquireD3D11ObjectsKHR_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
@@ -115,7 +113,7 @@ typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueAcquireD3D11ObjectsKHR_fn)(
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueReleaseD3D11ObjectsKHR_fn)(
|
||||
typedef cl_int (CL_API_CALL *clEnqueueReleaseD3D11ObjectsKHR_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
@@ -123,6 +121,33 @@ typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueReleaseD3D11ObjectsKHR_fn)(
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
/***************************************************************
|
||||
* cl_intel_sharing_format_query_d3d11
|
||||
***************************************************************/
|
||||
#define cl_intel_sharing_format_query_d3d11 1
|
||||
|
||||
/* when cl_khr_d3d11_sharing is supported */
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clGetSupportedD3D11TextureFormatsINTEL(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_mem_object_type image_type,
|
||||
cl_uint plane,
|
||||
cl_uint num_entries,
|
||||
DXGI_FORMAT* d3d11_formats,
|
||||
cl_uint* num_texture_formats) ;
|
||||
|
||||
typedef cl_int (CL_API_CALL *
|
||||
clGetSupportedD3D11TextureFormatsINTEL_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_mem_object_type image_type,
|
||||
cl_uint plane,
|
||||
cl_uint num_entries,
|
||||
DXGI_FORMAT* d3d11_formats,
|
||||
cl_uint* num_texture_formats) ;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
196
third_party/opencl_headers/CL/cl_dx9_media_sharing.h
vendored
196
third_party/opencl_headers/CL/cl_dx9_media_sharing.h
vendored
@@ -1,32 +1,18 @@
|
||||
/**********************************************************************************
|
||||
* Copyright (c) 2008-2015 The Khronos Group Inc.
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2008-2020 The Khronos Group Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and/or associated documentation files (the
|
||||
* "Materials"), to deal in the Materials without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
* permit persons to whom the Materials are furnished to do so, subject to
|
||||
* the following conditions:
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Materials.
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
|
||||
* KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
|
||||
* SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
|
||||
* https://www.khronos.org/registry/
|
||||
*
|
||||
* THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
**********************************************************************************/
|
||||
|
||||
/* $Revision: 11708 $ on $Date: 2010-06-13 23:36:24 -0700 (Sun, 13 Jun 2010) $ */
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
******************************************************************************/
|
||||
|
||||
#ifndef __OPENCL_CL_DX9_MEDIA_SHARING_H
|
||||
#define __OPENCL_CL_DX9_MEDIA_SHARING_H
|
||||
@@ -46,7 +32,19 @@ typedef cl_uint cl_dx9_media_adapter_type_khr;
|
||||
typedef cl_uint cl_dx9_media_adapter_set_khr;
|
||||
|
||||
#if defined(_WIN32)
|
||||
#if defined(_MSC_VER)
|
||||
#if _MSC_VER >=1500
|
||||
#pragma warning( push )
|
||||
#pragma warning( disable : 4201 )
|
||||
#pragma warning( disable : 5105 )
|
||||
#endif
|
||||
#endif
|
||||
#include <d3d9.h>
|
||||
#if defined(_MSC_VER)
|
||||
#if _MSC_VER >=1500
|
||||
#pragma warning( pop )
|
||||
#endif
|
||||
#endif
|
||||
typedef struct _cl_dx9_surface_info_khr
|
||||
{
|
||||
IDirect3DSurface9 *resource;
|
||||
@@ -90,7 +88,7 @@ typedef struct _cl_dx9_surface_info_khr
|
||||
|
||||
/******************************************************************************/
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clGetDeviceIDsFromDX9MediaAdapterKHR_fn)(
|
||||
typedef cl_int (CL_API_CALL *clGetDeviceIDsFromDX9MediaAdapterKHR_fn)(
|
||||
cl_platform_id platform,
|
||||
cl_uint num_media_adapters,
|
||||
cl_dx9_media_adapter_type_khr * media_adapter_type,
|
||||
@@ -100,7 +98,7 @@ typedef CL_API_ENTRY cl_int (CL_API_CALL *clGetDeviceIDsFromDX9MediaAdapterKHR_f
|
||||
cl_device_id * devices,
|
||||
cl_uint * num_devices) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_mem (CL_API_CALL *clCreateFromDX9MediaSurfaceKHR_fn)(
|
||||
typedef cl_mem (CL_API_CALL *clCreateFromDX9MediaSurfaceKHR_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_dx9_media_adapter_type_khr adapter_type,
|
||||
@@ -108,7 +106,7 @@ typedef CL_API_ENTRY cl_mem (CL_API_CALL *clCreateFromDX9MediaSurfaceKHR_fn)(
|
||||
cl_uint plane,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueAcquireDX9MediaSurfacesKHR_fn)(
|
||||
typedef cl_int (CL_API_CALL *clEnqueueAcquireDX9MediaSurfacesKHR_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
@@ -116,7 +114,7 @@ typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueAcquireDX9MediaSurfacesKHR_fn
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueReleaseDX9MediaSurfacesKHR_fn)(
|
||||
typedef cl_int (CL_API_CALL *clEnqueueReleaseDX9MediaSurfacesKHR_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
@@ -124,6 +122,144 @@ typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueReleaseDX9MediaSurfacesKHR_fn
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
/***************************************
|
||||
* cl_intel_dx9_media_sharing extension *
|
||||
****************************************/
|
||||
|
||||
#define cl_intel_dx9_media_sharing 1
|
||||
|
||||
typedef cl_uint cl_dx9_device_source_intel;
|
||||
typedef cl_uint cl_dx9_device_set_intel;
|
||||
|
||||
/* error codes */
|
||||
#define CL_INVALID_DX9_DEVICE_INTEL -1010
|
||||
#define CL_INVALID_DX9_RESOURCE_INTEL -1011
|
||||
#define CL_DX9_RESOURCE_ALREADY_ACQUIRED_INTEL -1012
|
||||
#define CL_DX9_RESOURCE_NOT_ACQUIRED_INTEL -1013
|
||||
|
||||
/* cl_dx9_device_source_intel */
|
||||
#define CL_D3D9_DEVICE_INTEL 0x4022
|
||||
#define CL_D3D9EX_DEVICE_INTEL 0x4070
|
||||
#define CL_DXVA_DEVICE_INTEL 0x4071
|
||||
|
||||
/* cl_dx9_device_set_intel */
|
||||
#define CL_PREFERRED_DEVICES_FOR_DX9_INTEL 0x4024
|
||||
#define CL_ALL_DEVICES_FOR_DX9_INTEL 0x4025
|
||||
|
||||
/* cl_context_info */
|
||||
#define CL_CONTEXT_D3D9_DEVICE_INTEL 0x4026
|
||||
#define CL_CONTEXT_D3D9EX_DEVICE_INTEL 0x4072
|
||||
#define CL_CONTEXT_DXVA_DEVICE_INTEL 0x4073
|
||||
|
||||
/* cl_mem_info */
|
||||
#define CL_MEM_DX9_RESOURCE_INTEL 0x4027
|
||||
#define CL_MEM_DX9_SHARED_HANDLE_INTEL 0x4074
|
||||
|
||||
/* cl_image_info */
|
||||
#define CL_IMAGE_DX9_PLANE_INTEL 0x4075
|
||||
|
||||
/* cl_command_type */
|
||||
#define CL_COMMAND_ACQUIRE_DX9_OBJECTS_INTEL 0x402A
|
||||
#define CL_COMMAND_RELEASE_DX9_OBJECTS_INTEL 0x402B
|
||||
/******************************************************************************/
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clGetDeviceIDsFromDX9INTEL(
|
||||
cl_platform_id platform,
|
||||
cl_dx9_device_source_intel dx9_device_source,
|
||||
void* dx9_object,
|
||||
cl_dx9_device_set_intel dx9_device_set,
|
||||
cl_uint num_entries,
|
||||
cl_device_id* devices,
|
||||
cl_uint* num_devices) CL_API_SUFFIX__VERSION_1_1;
|
||||
|
||||
typedef cl_int (CL_API_CALL* clGetDeviceIDsFromDX9INTEL_fn)(
|
||||
cl_platform_id platform,
|
||||
cl_dx9_device_source_intel dx9_device_source,
|
||||
void* dx9_object,
|
||||
cl_dx9_device_set_intel dx9_device_set,
|
||||
cl_uint num_entries,
|
||||
cl_device_id* devices,
|
||||
cl_uint* num_devices) CL_API_SUFFIX__VERSION_1_1;
|
||||
|
||||
extern CL_API_ENTRY cl_mem CL_API_CALL
|
||||
clCreateFromDX9MediaSurfaceINTEL(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
IDirect3DSurface9* resource,
|
||||
HANDLE sharedHandle,
|
||||
UINT plane,
|
||||
cl_int* errcode_ret) CL_API_SUFFIX__VERSION_1_1;
|
||||
|
||||
typedef cl_mem (CL_API_CALL *clCreateFromDX9MediaSurfaceINTEL_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
IDirect3DSurface9* resource,
|
||||
HANDLE sharedHandle,
|
||||
UINT plane,
|
||||
cl_int* errcode_ret) CL_API_SUFFIX__VERSION_1_1;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clEnqueueAcquireDX9ObjectsINTEL(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem* mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event* event_wait_list,
|
||||
cl_event* event) CL_API_SUFFIX__VERSION_1_1;
|
||||
|
||||
typedef cl_int (CL_API_CALL *clEnqueueAcquireDX9ObjectsINTEL_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem* mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event* event_wait_list,
|
||||
cl_event* event) CL_API_SUFFIX__VERSION_1_1;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clEnqueueReleaseDX9ObjectsINTEL(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
cl_mem* mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event* event_wait_list,
|
||||
cl_event* event) CL_API_SUFFIX__VERSION_1_1;
|
||||
|
||||
typedef cl_int (CL_API_CALL *clEnqueueReleaseDX9ObjectsINTEL_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
cl_mem* mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event* event_wait_list,
|
||||
cl_event* event) CL_API_SUFFIX__VERSION_1_1;
|
||||
|
||||
/***************************************************************
|
||||
* cl_intel_sharing_format_query_dx9
|
||||
***************************************************************/
|
||||
#define cl_intel_sharing_format_query_dx9 1
|
||||
|
||||
/* when cl_khr_dx9_media_sharing or cl_intel_dx9_media_sharing is supported */
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clGetSupportedDX9MediaSurfaceFormatsINTEL(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_mem_object_type image_type,
|
||||
cl_uint plane,
|
||||
cl_uint num_entries,
|
||||
D3DFORMAT* dx9_formats,
|
||||
cl_uint* num_surface_formats) ;
|
||||
|
||||
typedef cl_int (CL_API_CALL *
|
||||
clGetSupportedDX9MediaSurfaceFormatsINTEL_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_mem_object_type image_type,
|
||||
cl_uint plane,
|
||||
cl_uint num_entries,
|
||||
D3DFORMAT* dx9_formats,
|
||||
cl_uint* num_surface_formats) ;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -1,182 +1,18 @@
|
||||
/**********************************************************************************
|
||||
* Copyright (c) 2008-2016 The Khronos Group Inc.
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2008-2020 The Khronos Group Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and/or associated documentation files (the
|
||||
* "Materials"), to deal in the Materials without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
* permit persons to whom the Materials are furnished to do so, subject to
|
||||
* the following conditions:
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Materials.
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
|
||||
* KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
|
||||
* SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
|
||||
* https://www.khronos.org/registry/
|
||||
*
|
||||
* THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
**********************************************************************************/
|
||||
/*****************************************************************************\
|
||||
|
||||
Copyright (c) 2013-2016 Intel Corporation All Rights Reserved.
|
||||
|
||||
THESE MATERIALS ARE PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL INTEL OR ITS
|
||||
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
||||
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
||||
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
|
||||
OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY OR TORT (INCLUDING
|
||||
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THESE
|
||||
MATERIALS, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
File Name: cl_dx9_media_sharing_intel.h
|
||||
|
||||
Abstract:
|
||||
|
||||
Notes:
|
||||
|
||||
\*****************************************************************************/
|
||||
|
||||
#ifndef __OPENCL_CL_DX9_MEDIA_SHARING_INTEL_H
|
||||
#define __OPENCL_CL_DX9_MEDIA_SHARING_INTEL_H
|
||||
|
||||
#include <CL/cl.h>
|
||||
#include <CL/cl_platform.h>
|
||||
#include <d3d9.h>
|
||||
#include <dxvahd.h>
|
||||
#include <wtypes.h>
|
||||
#include <d3d9types.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/***************************************
|
||||
* cl_intel_dx9_media_sharing extension *
|
||||
****************************************/
|
||||
|
||||
#define cl_intel_dx9_media_sharing 1
|
||||
|
||||
typedef cl_uint cl_dx9_device_source_intel;
|
||||
typedef cl_uint cl_dx9_device_set_intel;
|
||||
|
||||
/* error codes */
|
||||
#define CL_INVALID_DX9_DEVICE_INTEL -1010
|
||||
#define CL_INVALID_DX9_RESOURCE_INTEL -1011
|
||||
#define CL_DX9_RESOURCE_ALREADY_ACQUIRED_INTEL -1012
|
||||
#define CL_DX9_RESOURCE_NOT_ACQUIRED_INTEL -1013
|
||||
|
||||
/* cl_dx9_device_source_intel */
|
||||
#define CL_D3D9_DEVICE_INTEL 0x4022
|
||||
#define CL_D3D9EX_DEVICE_INTEL 0x4070
|
||||
#define CL_DXVA_DEVICE_INTEL 0x4071
|
||||
|
||||
/* cl_dx9_device_set_intel */
|
||||
#define CL_PREFERRED_DEVICES_FOR_DX9_INTEL 0x4024
|
||||
#define CL_ALL_DEVICES_FOR_DX9_INTEL 0x4025
|
||||
|
||||
/* cl_context_info */
|
||||
#define CL_CONTEXT_D3D9_DEVICE_INTEL 0x4026
|
||||
#define CL_CONTEXT_D3D9EX_DEVICE_INTEL 0x4072
|
||||
#define CL_CONTEXT_DXVA_DEVICE_INTEL 0x4073
|
||||
|
||||
/* cl_mem_info */
|
||||
#define CL_MEM_DX9_RESOURCE_INTEL 0x4027
|
||||
#define CL_MEM_DX9_SHARED_HANDLE_INTEL 0x4074
|
||||
|
||||
/* cl_image_info */
|
||||
#define CL_IMAGE_DX9_PLANE_INTEL 0x4075
|
||||
|
||||
/* cl_command_type */
|
||||
#define CL_COMMAND_ACQUIRE_DX9_OBJECTS_INTEL 0x402A
|
||||
#define CL_COMMAND_RELEASE_DX9_OBJECTS_INTEL 0x402B
|
||||
/******************************************************************************/
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clGetDeviceIDsFromDX9INTEL(
|
||||
cl_platform_id /* platform */,
|
||||
cl_dx9_device_source_intel /* dx9_device_source */,
|
||||
void* /* dx9_object */,
|
||||
cl_dx9_device_set_intel /* dx9_device_set */,
|
||||
cl_uint /* num_entries */,
|
||||
cl_device_id* /* devices */,
|
||||
cl_uint* /* num_devices */) CL_EXT_SUFFIX__VERSION_1_1;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL* clGetDeviceIDsFromDX9INTEL_fn)(
|
||||
cl_platform_id /* platform */,
|
||||
cl_dx9_device_source_intel /* dx9_device_source */,
|
||||
void* /* dx9_object */,
|
||||
cl_dx9_device_set_intel /* dx9_device_set */,
|
||||
cl_uint /* num_entries */,
|
||||
cl_device_id* /* devices */,
|
||||
cl_uint* /* num_devices */) CL_EXT_SUFFIX__VERSION_1_1;
|
||||
|
||||
extern CL_API_ENTRY cl_mem CL_API_CALL
|
||||
clCreateFromDX9MediaSurfaceINTEL(
|
||||
cl_context /* context */,
|
||||
cl_mem_flags /* flags */,
|
||||
IDirect3DSurface9* /* resource */,
|
||||
HANDLE /* sharedHandle */,
|
||||
UINT /* plane */,
|
||||
cl_int* /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_1;
|
||||
|
||||
typedef CL_API_ENTRY cl_mem (CL_API_CALL *clCreateFromDX9MediaSurfaceINTEL_fn)(
|
||||
cl_context /* context */,
|
||||
cl_mem_flags /* flags */,
|
||||
IDirect3DSurface9* /* resource */,
|
||||
HANDLE /* sharedHandle */,
|
||||
UINT /* plane */,
|
||||
cl_int* /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_1;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clEnqueueAcquireDX9ObjectsINTEL(
|
||||
cl_command_queue /* command_queue */,
|
||||
cl_uint /* num_objects */,
|
||||
const cl_mem* /* mem_objects */,
|
||||
cl_uint /* num_events_in_wait_list */,
|
||||
const cl_event* /* event_wait_list */,
|
||||
cl_event* /* event */) CL_EXT_SUFFIX__VERSION_1_1;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueAcquireDX9ObjectsINTEL_fn)(
|
||||
cl_command_queue /* command_queue */,
|
||||
cl_uint /* num_objects */,
|
||||
const cl_mem* /* mem_objects */,
|
||||
cl_uint /* num_events_in_wait_list */,
|
||||
const cl_event* /* event_wait_list */,
|
||||
cl_event* /* event */) CL_EXT_SUFFIX__VERSION_1_1;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clEnqueueReleaseDX9ObjectsINTEL(
|
||||
cl_command_queue /* command_queue */,
|
||||
cl_uint /* num_objects */,
|
||||
cl_mem* /* mem_objects */,
|
||||
cl_uint /* num_events_in_wait_list */,
|
||||
const cl_event* /* event_wait_list */,
|
||||
cl_event* /* event */) CL_EXT_SUFFIX__VERSION_1_1;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueReleaseDX9ObjectsINTEL_fn)(
|
||||
cl_command_queue /* command_queue */,
|
||||
cl_uint /* num_objects */,
|
||||
cl_mem* /* mem_objects */,
|
||||
cl_uint /* num_events_in_wait_list */,
|
||||
const cl_event* /* event_wait_list */,
|
||||
cl_event* /* event */) CL_EXT_SUFFIX__VERSION_1_1;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __OPENCL_CL_DX9_MEDIA_SHARING_INTEL_H */
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
******************************************************************************/
|
||||
|
||||
#include <CL/cl_dx9_media_sharing.h>
|
||||
#pragma message("The Intel DX9 media sharing extensions have been moved into cl_dx9_media_sharing.h. Please include cl_dx9_media_sharing.h directly.")
|
||||
|
||||
132
third_party/opencl_headers/CL/cl_egl.h
vendored
132
third_party/opencl_headers/CL/cl_egl.h
vendored
@@ -1,39 +1,23 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2008-2015 The Khronos Group Inc.
|
||||
* Copyright (c) 2008-2020 The Khronos Group Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and/or associated documentation files (the
|
||||
* "Materials"), to deal in the Materials without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
* permit persons to whom the Materials are furnished to do so, subject to
|
||||
* the following conditions:
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Materials.
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
|
||||
* KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
|
||||
* SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
|
||||
* https://www.khronos.org/registry/
|
||||
*
|
||||
* THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
******************************************************************************/
|
||||
|
||||
#ifndef __OPENCL_CL_EGL_H
|
||||
#define __OPENCL_CL_EGL_H
|
||||
|
||||
#ifdef __APPLE__
|
||||
|
||||
#else
|
||||
#include <CL/cl.h>
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
@@ -65,69 +49,69 @@ typedef intptr_t cl_egl_image_properties_khr;
|
||||
#define cl_khr_egl_image 1
|
||||
|
||||
extern CL_API_ENTRY cl_mem CL_API_CALL
|
||||
clCreateFromEGLImageKHR(cl_context /* context */,
|
||||
CLeglDisplayKHR /* egldisplay */,
|
||||
CLeglImageKHR /* eglimage */,
|
||||
cl_mem_flags /* flags */,
|
||||
const cl_egl_image_properties_khr * /* properties */,
|
||||
cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0;
|
||||
clCreateFromEGLImageKHR(cl_context context,
|
||||
CLeglDisplayKHR egldisplay,
|
||||
CLeglImageKHR eglimage,
|
||||
cl_mem_flags flags,
|
||||
const cl_egl_image_properties_khr * properties,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY cl_mem (CL_API_CALL *clCreateFromEGLImageKHR_fn)(
|
||||
cl_context context,
|
||||
CLeglDisplayKHR egldisplay,
|
||||
CLeglImageKHR eglimage,
|
||||
cl_mem_flags flags,
|
||||
const cl_egl_image_properties_khr * properties,
|
||||
cl_int * errcode_ret);
|
||||
typedef cl_mem (CL_API_CALL *clCreateFromEGLImageKHR_fn)(
|
||||
cl_context context,
|
||||
CLeglDisplayKHR egldisplay,
|
||||
CLeglImageKHR eglimage,
|
||||
cl_mem_flags flags,
|
||||
const cl_egl_image_properties_khr * properties,
|
||||
cl_int * errcode_ret);
|
||||
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clEnqueueAcquireEGLObjectsKHR(cl_command_queue /* command_queue */,
|
||||
cl_uint /* num_objects */,
|
||||
const cl_mem * /* mem_objects */,
|
||||
cl_uint /* num_events_in_wait_list */,
|
||||
const cl_event * /* event_wait_list */,
|
||||
cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0;
|
||||
clEnqueueAcquireEGLObjectsKHR(cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueAcquireEGLObjectsKHR_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event);
|
||||
typedef cl_int (CL_API_CALL *clEnqueueAcquireEGLObjectsKHR_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event);
|
||||
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clEnqueueReleaseEGLObjectsKHR(cl_command_queue /* command_queue */,
|
||||
cl_uint /* num_objects */,
|
||||
const cl_mem * /* mem_objects */,
|
||||
cl_uint /* num_events_in_wait_list */,
|
||||
const cl_event * /* event_wait_list */,
|
||||
cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0;
|
||||
clEnqueueReleaseEGLObjectsKHR(cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueReleaseEGLObjectsKHR_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event);
|
||||
typedef cl_int (CL_API_CALL *clEnqueueReleaseEGLObjectsKHR_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event);
|
||||
|
||||
|
||||
#define cl_khr_egl_event 1
|
||||
|
||||
extern CL_API_ENTRY cl_event CL_API_CALL
|
||||
clCreateEventFromEGLSyncKHR(cl_context /* context */,
|
||||
CLeglSyncKHR /* sync */,
|
||||
CLeglDisplayKHR /* display */,
|
||||
cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0;
|
||||
clCreateEventFromEGLSyncKHR(cl_context context,
|
||||
CLeglSyncKHR sync,
|
||||
CLeglDisplayKHR display,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY cl_event (CL_API_CALL *clCreateEventFromEGLSyncKHR_fn)(
|
||||
cl_context context,
|
||||
CLeglSyncKHR sync,
|
||||
CLeglDisplayKHR display,
|
||||
cl_int * errcode_ret);
|
||||
typedef cl_event (CL_API_CALL *clCreateEventFromEGLSyncKHR_fn)(
|
||||
cl_context context,
|
||||
CLeglSyncKHR sync,
|
||||
CLeglDisplayKHR display,
|
||||
cl_int * errcode_ret);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
1757
third_party/opencl_headers/CL/cl_ext.h
vendored
1757
third_party/opencl_headers/CL/cl_ext.h
vendored
File diff suppressed because it is too large
Load Diff
434
third_party/opencl_headers/CL/cl_ext_intel.h
vendored
434
third_party/opencl_headers/CL/cl_ext_intel.h
vendored
@@ -1,429 +1,19 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2008-2017 The Khronos Group Inc.
|
||||
* Copyright (c) 2008-2020 The Khronos Group Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and/or associated documentation files (the
|
||||
* "Materials"), to deal in the Materials without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
* permit persons to whom the Materials are furnished to do so, subject to
|
||||
* the following conditions:
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Materials.
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
|
||||
* KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
|
||||
* SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
|
||||
* https://www.khronos.org/registry/
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*
|
||||
* THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
******************************************************************************/
|
||||
/*****************************************************************************\
|
||||
|
||||
Copyright (c) 2013-2017 Intel Corporation All Rights Reserved.
|
||||
|
||||
THESE MATERIALS ARE PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL INTEL OR ITS
|
||||
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
||||
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
||||
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
|
||||
OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY OR TORT (INCLUDING
|
||||
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THESE
|
||||
MATERIALS, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
File Name: cl_ext_intel.h
|
||||
|
||||
Abstract:
|
||||
|
||||
Notes:
|
||||
|
||||
\*****************************************************************************/
|
||||
|
||||
#ifndef __CL_EXT_INTEL_H
|
||||
#define __CL_EXT_INTEL_H
|
||||
|
||||
#ifdef __APPLE__
|
||||
#include <OpenCL/cl.h>
|
||||
#include <OpenCL/cl_platform.h>
|
||||
#else
|
||||
#include <CL/cl.h>
|
||||
#include <CL/cl_platform.h>
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/***************************************
|
||||
* cl_intel_thread_local_exec extension *
|
||||
****************************************/
|
||||
|
||||
#define cl_intel_thread_local_exec 1
|
||||
|
||||
#define CL_QUEUE_THREAD_LOCAL_EXEC_ENABLE_INTEL (((cl_bitfield)1) << 31)
|
||||
|
||||
/***********************************************
|
||||
* cl_intel_device_partition_by_names extension *
|
||||
************************************************/
|
||||
|
||||
#define cl_intel_device_partition_by_names 1
|
||||
|
||||
#define CL_DEVICE_PARTITION_BY_NAMES_INTEL 0x4052
|
||||
#define CL_PARTITION_BY_NAMES_LIST_END_INTEL -1
|
||||
|
||||
/************************************************
|
||||
* cl_intel_accelerator extension *
|
||||
* cl_intel_motion_estimation extension *
|
||||
* cl_intel_advanced_motion_estimation extension *
|
||||
*************************************************/
|
||||
|
||||
#define cl_intel_accelerator 1
|
||||
#define cl_intel_motion_estimation 1
|
||||
#define cl_intel_advanced_motion_estimation 1
|
||||
|
||||
typedef struct _cl_accelerator_intel* cl_accelerator_intel;
|
||||
typedef cl_uint cl_accelerator_type_intel;
|
||||
typedef cl_uint cl_accelerator_info_intel;
|
||||
|
||||
typedef struct _cl_motion_estimation_desc_intel {
|
||||
cl_uint mb_block_type;
|
||||
cl_uint subpixel_mode;
|
||||
cl_uint sad_adjust_mode;
|
||||
cl_uint search_path_type;
|
||||
} cl_motion_estimation_desc_intel;
|
||||
|
||||
/* error codes */
|
||||
#define CL_INVALID_ACCELERATOR_INTEL -1094
|
||||
#define CL_INVALID_ACCELERATOR_TYPE_INTEL -1095
|
||||
#define CL_INVALID_ACCELERATOR_DESCRIPTOR_INTEL -1096
|
||||
#define CL_ACCELERATOR_TYPE_NOT_SUPPORTED_INTEL -1097
|
||||
|
||||
/* cl_accelerator_type_intel */
|
||||
#define CL_ACCELERATOR_TYPE_MOTION_ESTIMATION_INTEL 0x0
|
||||
|
||||
/* cl_accelerator_info_intel */
|
||||
#define CL_ACCELERATOR_DESCRIPTOR_INTEL 0x4090
|
||||
#define CL_ACCELERATOR_REFERENCE_COUNT_INTEL 0x4091
|
||||
#define CL_ACCELERATOR_CONTEXT_INTEL 0x4092
|
||||
#define CL_ACCELERATOR_TYPE_INTEL 0x4093
|
||||
|
||||
/* cl_motion_detect_desc_intel flags */
|
||||
#define CL_ME_MB_TYPE_16x16_INTEL 0x0
|
||||
#define CL_ME_MB_TYPE_8x8_INTEL 0x1
|
||||
#define CL_ME_MB_TYPE_4x4_INTEL 0x2
|
||||
|
||||
#define CL_ME_SUBPIXEL_MODE_INTEGER_INTEL 0x0
|
||||
#define CL_ME_SUBPIXEL_MODE_HPEL_INTEL 0x1
|
||||
#define CL_ME_SUBPIXEL_MODE_QPEL_INTEL 0x2
|
||||
|
||||
#define CL_ME_SAD_ADJUST_MODE_NONE_INTEL 0x0
|
||||
#define CL_ME_SAD_ADJUST_MODE_HAAR_INTEL 0x1
|
||||
|
||||
#define CL_ME_SEARCH_PATH_RADIUS_2_2_INTEL 0x0
|
||||
#define CL_ME_SEARCH_PATH_RADIUS_4_4_INTEL 0x1
|
||||
#define CL_ME_SEARCH_PATH_RADIUS_16_12_INTEL 0x5
|
||||
|
||||
#define CL_ME_SKIP_BLOCK_TYPE_16x16_INTEL 0x0
|
||||
#define CL_ME_CHROMA_INTRA_PREDICT_ENABLED_INTEL 0x1
|
||||
#define CL_ME_LUMA_INTRA_PREDICT_ENABLED_INTEL 0x2
|
||||
#define CL_ME_SKIP_BLOCK_TYPE_8x8_INTEL 0x4
|
||||
|
||||
#define CL_ME_FORWARD_INPUT_MODE_INTEL 0x1
|
||||
#define CL_ME_BACKWARD_INPUT_MODE_INTEL 0x2
|
||||
#define CL_ME_BIDIRECTION_INPUT_MODE_INTEL 0x3
|
||||
|
||||
#define CL_ME_BIDIR_WEIGHT_QUARTER_INTEL 16
|
||||
#define CL_ME_BIDIR_WEIGHT_THIRD_INTEL 21
|
||||
#define CL_ME_BIDIR_WEIGHT_HALF_INTEL 32
|
||||
#define CL_ME_BIDIR_WEIGHT_TWO_THIRD_INTEL 43
|
||||
#define CL_ME_BIDIR_WEIGHT_THREE_QUARTER_INTEL 48
|
||||
|
||||
#define CL_ME_COST_PENALTY_NONE_INTEL 0x0
|
||||
#define CL_ME_COST_PENALTY_LOW_INTEL 0x1
|
||||
#define CL_ME_COST_PENALTY_NORMAL_INTEL 0x2
|
||||
#define CL_ME_COST_PENALTY_HIGH_INTEL 0x3
|
||||
|
||||
#define CL_ME_COST_PRECISION_QPEL_INTEL 0x0
|
||||
#define CL_ME_COST_PRECISION_HPEL_INTEL 0x1
|
||||
#define CL_ME_COST_PRECISION_PEL_INTEL 0x2
|
||||
#define CL_ME_COST_PRECISION_DPEL_INTEL 0x3
|
||||
|
||||
#define CL_ME_LUMA_PREDICTOR_MODE_VERTICAL_INTEL 0x0
|
||||
#define CL_ME_LUMA_PREDICTOR_MODE_HORIZONTAL_INTEL 0x1
|
||||
#define CL_ME_LUMA_PREDICTOR_MODE_DC_INTEL 0x2
|
||||
#define CL_ME_LUMA_PREDICTOR_MODE_DIAGONAL_DOWN_LEFT_INTEL 0x3
|
||||
|
||||
#define CL_ME_LUMA_PREDICTOR_MODE_DIAGONAL_DOWN_RIGHT_INTEL 0x4
|
||||
#define CL_ME_LUMA_PREDICTOR_MODE_PLANE_INTEL 0x4
|
||||
#define CL_ME_LUMA_PREDICTOR_MODE_VERTICAL_RIGHT_INTEL 0x5
|
||||
#define CL_ME_LUMA_PREDICTOR_MODE_HORIZONTAL_DOWN_INTEL 0x6
|
||||
#define CL_ME_LUMA_PREDICTOR_MODE_VERTICAL_LEFT_INTEL 0x7
|
||||
#define CL_ME_LUMA_PREDICTOR_MODE_HORIZONTAL_UP_INTEL 0x8
|
||||
|
||||
#define CL_ME_CHROMA_PREDICTOR_MODE_DC_INTEL 0x0
|
||||
#define CL_ME_CHROMA_PREDICTOR_MODE_HORIZONTAL_INTEL 0x1
|
||||
#define CL_ME_CHROMA_PREDICTOR_MODE_VERTICAL_INTEL 0x2
|
||||
#define CL_ME_CHROMA_PREDICTOR_MODE_PLANE_INTEL 0x3
|
||||
|
||||
/* cl_device_info */
|
||||
#define CL_DEVICE_ME_VERSION_INTEL 0x407E
|
||||
|
||||
#define CL_ME_VERSION_LEGACY_INTEL 0x0
|
||||
#define CL_ME_VERSION_ADVANCED_VER_1_INTEL 0x1
|
||||
#define CL_ME_VERSION_ADVANCED_VER_2_INTEL 0x2
|
||||
|
||||
extern CL_API_ENTRY cl_accelerator_intel CL_API_CALL
|
||||
clCreateAcceleratorINTEL(
|
||||
cl_context /* context */,
|
||||
cl_accelerator_type_intel /* accelerator_type */,
|
||||
size_t /* descriptor_size */,
|
||||
const void* /* descriptor */,
|
||||
cl_int* /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_accelerator_intel (CL_API_CALL *clCreateAcceleratorINTEL_fn)(
|
||||
cl_context /* context */,
|
||||
cl_accelerator_type_intel /* accelerator_type */,
|
||||
size_t /* descriptor_size */,
|
||||
const void* /* descriptor */,
|
||||
cl_int* /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clGetAcceleratorInfoINTEL(
|
||||
cl_accelerator_intel /* accelerator */,
|
||||
cl_accelerator_info_intel /* param_name */,
|
||||
size_t /* param_value_size */,
|
||||
void* /* param_value */,
|
||||
size_t* /* param_value_size_ret */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clGetAcceleratorInfoINTEL_fn)(
|
||||
cl_accelerator_intel /* accelerator */,
|
||||
cl_accelerator_info_intel /* param_name */,
|
||||
size_t /* param_value_size */,
|
||||
void* /* param_value */,
|
||||
size_t* /* param_value_size_ret */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clRetainAcceleratorINTEL(
|
||||
cl_accelerator_intel /* accelerator */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clRetainAcceleratorINTEL_fn)(
|
||||
cl_accelerator_intel /* accelerator */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clReleaseAcceleratorINTEL(
|
||||
cl_accelerator_intel /* accelerator */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clReleaseAcceleratorINTEL_fn)(
|
||||
cl_accelerator_intel /* accelerator */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
|
||||
/******************************************
|
||||
* cl_intel_simultaneous_sharing extension *
|
||||
*******************************************/
|
||||
|
||||
#define cl_intel_simultaneous_sharing 1
|
||||
|
||||
#define CL_DEVICE_SIMULTANEOUS_INTEROPS_INTEL 0x4104
|
||||
#define CL_DEVICE_NUM_SIMULTANEOUS_INTEROPS_INTEL 0x4105
|
||||
|
||||
/***********************************
|
||||
* cl_intel_egl_image_yuv extension *
|
||||
************************************/
|
||||
|
||||
#define cl_intel_egl_image_yuv 1
|
||||
|
||||
#define CL_EGL_YUV_PLANE_INTEL 0x4107
|
||||
|
||||
/********************************
|
||||
* cl_intel_packed_yuv extension *
|
||||
*********************************/
|
||||
|
||||
#define cl_intel_packed_yuv 1
|
||||
|
||||
#define CL_YUYV_INTEL 0x4076
|
||||
#define CL_UYVY_INTEL 0x4077
|
||||
#define CL_YVYU_INTEL 0x4078
|
||||
#define CL_VYUY_INTEL 0x4079
|
||||
|
||||
/********************************************
|
||||
* cl_intel_required_subgroup_size extension *
|
||||
*********************************************/
|
||||
|
||||
#define cl_intel_required_subgroup_size 1
|
||||
|
||||
#define CL_DEVICE_SUB_GROUP_SIZES_INTEL 0x4108
|
||||
#define CL_KERNEL_SPILL_MEM_SIZE_INTEL 0x4109
|
||||
#define CL_KERNEL_COMPILE_SUB_GROUP_SIZE_INTEL 0x410A
|
||||
|
||||
/****************************************
|
||||
* cl_intel_driver_diagnostics extension *
|
||||
*****************************************/
|
||||
|
||||
#define cl_intel_driver_diagnostics 1
|
||||
|
||||
typedef cl_uint cl_diagnostics_verbose_level;
|
||||
|
||||
#define CL_CONTEXT_SHOW_DIAGNOSTICS_INTEL 0x4106
|
||||
|
||||
#define CL_CONTEXT_DIAGNOSTICS_LEVEL_ALL_INTEL ( 0xff )
|
||||
#define CL_CONTEXT_DIAGNOSTICS_LEVEL_GOOD_INTEL ( 1 )
|
||||
#define CL_CONTEXT_DIAGNOSTICS_LEVEL_BAD_INTEL ( 1 << 1 )
|
||||
#define CL_CONTEXT_DIAGNOSTICS_LEVEL_NEUTRAL_INTEL ( 1 << 2 )
|
||||
|
||||
/********************************
|
||||
* cl_intel_planar_yuv extension *
|
||||
*********************************/
|
||||
|
||||
#define CL_NV12_INTEL 0x410E
|
||||
|
||||
#define CL_MEM_NO_ACCESS_INTEL ( 1 << 24 )
|
||||
#define CL_MEM_ACCESS_FLAGS_UNRESTRICTED_INTEL ( 1 << 25 )
|
||||
|
||||
#define CL_DEVICE_PLANAR_YUV_MAX_WIDTH_INTEL 0x417E
|
||||
#define CL_DEVICE_PLANAR_YUV_MAX_HEIGHT_INTEL 0x417F
|
||||
|
||||
/*******************************************************
|
||||
* cl_intel_device_side_avc_motion_estimation extension *
|
||||
********************************************************/
|
||||
|
||||
#define CL_DEVICE_AVC_ME_VERSION_INTEL 0x410B
|
||||
#define CL_DEVICE_AVC_ME_SUPPORTS_TEXTURE_SAMPLER_USE_INTEL 0x410C
|
||||
#define CL_DEVICE_AVC_ME_SUPPORTS_PREEMPTION_INTEL 0x410D
|
||||
|
||||
#define CL_AVC_ME_VERSION_0_INTEL 0x0; // No support.
|
||||
#define CL_AVC_ME_VERSION_1_INTEL 0x1; // First supported version.
|
||||
|
||||
#define CL_AVC_ME_MAJOR_16x16_INTEL 0x0
|
||||
#define CL_AVC_ME_MAJOR_16x8_INTEL 0x1
|
||||
#define CL_AVC_ME_MAJOR_8x16_INTEL 0x2
|
||||
#define CL_AVC_ME_MAJOR_8x8_INTEL 0x3
|
||||
|
||||
#define CL_AVC_ME_MINOR_8x8_INTEL 0x0
|
||||
#define CL_AVC_ME_MINOR_8x4_INTEL 0x1
|
||||
#define CL_AVC_ME_MINOR_4x8_INTEL 0x2
|
||||
#define CL_AVC_ME_MINOR_4x4_INTEL 0x3
|
||||
|
||||
#define CL_AVC_ME_MAJOR_FORWARD_INTEL 0x0
|
||||
#define CL_AVC_ME_MAJOR_BACKWARD_INTEL 0x1
|
||||
#define CL_AVC_ME_MAJOR_BIDIRECTIONAL_INTEL 0x2
|
||||
|
||||
#define CL_AVC_ME_PARTITION_MASK_ALL_INTEL 0x0
|
||||
#define CL_AVC_ME_PARTITION_MASK_16x16_INTEL 0x7E
|
||||
#define CL_AVC_ME_PARTITION_MASK_16x8_INTEL 0x7D
|
||||
#define CL_AVC_ME_PARTITION_MASK_8x16_INTEL 0x7B
|
||||
#define CL_AVC_ME_PARTITION_MASK_8x8_INTEL 0x77
|
||||
#define CL_AVC_ME_PARTITION_MASK_8x4_INTEL 0x6F
|
||||
#define CL_AVC_ME_PARTITION_MASK_4x8_INTEL 0x5F
|
||||
#define CL_AVC_ME_PARTITION_MASK_4x4_INTEL 0x3F
|
||||
|
||||
#define CL_AVC_ME_SEARCH_WINDOW_EXHAUSTIVE_INTEL 0x0
|
||||
#define CL_AVC_ME_SEARCH_WINDOW_SMALL_INTEL 0x1
|
||||
#define CL_AVC_ME_SEARCH_WINDOW_TINY_INTEL 0x2
|
||||
#define CL_AVC_ME_SEARCH_WINDOW_EXTRA_TINY_INTEL 0x3
|
||||
#define CL_AVC_ME_SEARCH_WINDOW_DIAMOND_INTEL 0x4
|
||||
#define CL_AVC_ME_SEARCH_WINDOW_LARGE_DIAMOND_INTEL 0x5
|
||||
#define CL_AVC_ME_SEARCH_WINDOW_RESERVED0_INTEL 0x6
|
||||
#define CL_AVC_ME_SEARCH_WINDOW_RESERVED1_INTEL 0x7
|
||||
#define CL_AVC_ME_SEARCH_WINDOW_CUSTOM_INTEL 0x8
|
||||
#define CL_AVC_ME_SEARCH_WINDOW_16x12_RADIUS_INTEL 0x9
|
||||
#define CL_AVC_ME_SEARCH_WINDOW_4x4_RADIUS_INTEL 0x2
|
||||
#define CL_AVC_ME_SEARCH_WINDOW_2x2_RADIUS_INTEL 0xa
|
||||
|
||||
#define CL_AVC_ME_SAD_ADJUST_MODE_NONE_INTEL 0x0
|
||||
#define CL_AVC_ME_SAD_ADJUST_MODE_HAAR_INTEL 0x2
|
||||
|
||||
#define CL_AVC_ME_SUBPIXEL_MODE_INTEGER_INTEL 0x0
|
||||
#define CL_AVC_ME_SUBPIXEL_MODE_HPEL_INTEL 0x1
|
||||
#define CL_AVC_ME_SUBPIXEL_MODE_QPEL_INTEL 0x3
|
||||
|
||||
#define CL_AVC_ME_COST_PRECISION_QPEL_INTEL 0x0
|
||||
#define CL_AVC_ME_COST_PRECISION_HPEL_INTEL 0x1
|
||||
#define CL_AVC_ME_COST_PRECISION_PEL_INTEL 0x2
|
||||
#define CL_AVC_ME_COST_PRECISION_DPEL_INTEL 0x3
|
||||
|
||||
#define CL_AVC_ME_BIDIR_WEIGHT_QUARTER_INTEL 0x10
|
||||
#define CL_AVC_ME_BIDIR_WEIGHT_THIRD_INTEL 0x15
|
||||
#define CL_AVC_ME_BIDIR_WEIGHT_HALF_INTEL 0x20
|
||||
#define CL_AVC_ME_BIDIR_WEIGHT_TWO_THIRD_INTEL 0x2B
|
||||
#define CL_AVC_ME_BIDIR_WEIGHT_THREE_QUARTER_INTEL 0x30
|
||||
|
||||
#define CL_AVC_ME_BORDER_REACHED_LEFT_INTEL 0x0
|
||||
#define CL_AVC_ME_BORDER_REACHED_RIGHT_INTEL 0x2
|
||||
#define CL_AVC_ME_BORDER_REACHED_TOP_INTEL 0x4
|
||||
#define CL_AVC_ME_BORDER_REACHED_BOTTOM_INTEL 0x8
|
||||
|
||||
#define CL_AVC_ME_SKIP_BLOCK_PARTITION_16x16_INTEL 0x0
|
||||
#define CL_AVC_ME_SKIP_BLOCK_PARTITION_8x8_INTEL 0x4000
|
||||
|
||||
#define CL_AVC_ME_SKIP_BLOCK_16x16_FORWARD_ENABLE_INTEL ( 0x1 << 24 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_16x16_BACKWARD_ENABLE_INTEL ( 0x2 << 24 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_16x16_DUAL_ENABLE_INTEL ( 0x3 << 24 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_8x8_FORWARD_ENABLE_INTEL ( 0x55 << 24 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_8x8_BACKWARD_ENABLE_INTEL ( 0xAA << 24 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_8x8_DUAL_ENABLE_INTEL ( 0xFF << 24 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_8x8_0_FORWARD_ENABLE_INTEL ( 0x1 << 24 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_8x8_0_BACKWARD_ENABLE_INTEL ( 0x2 << 24 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_8x8_1_FORWARD_ENABLE_INTEL ( 0x1 << 26 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_8x8_1_BACKWARD_ENABLE_INTEL ( 0x2 << 26 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_8x8_2_FORWARD_ENABLE_INTEL ( 0x1 << 28 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_8x8_2_BACKWARD_ENABLE_INTEL ( 0x2 << 28 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_8x8_3_FORWARD_ENABLE_INTEL ( 0x1 << 30 )
|
||||
#define CL_AVC_ME_SKIP_BLOCK_8x8_3_BACKWARD_ENABLE_INTEL ( 0x2 << 30 )
|
||||
|
||||
#define CL_AVC_ME_BLOCK_BASED_SKIP_4x4_INTEL 0x00
|
||||
#define CL_AVC_ME_BLOCK_BASED_SKIP_8x8_INTEL 0x80
|
||||
|
||||
#define CL_AVC_ME_INTRA_16x16_INTEL 0x0
|
||||
#define CL_AVC_ME_INTRA_8x8_INTEL 0x1
|
||||
#define CL_AVC_ME_INTRA_4x4_INTEL 0x2
|
||||
|
||||
#define CL_AVC_ME_INTRA_LUMA_PARTITION_MASK_16x16_INTEL 0x6
|
||||
#define CL_AVC_ME_INTRA_LUMA_PARTITION_MASK_8x8_INTEL 0x5
|
||||
#define CL_AVC_ME_INTRA_LUMA_PARTITION_MASK_4x4_INTEL 0x3
|
||||
|
||||
#define CL_AVC_ME_INTRA_NEIGHBOR_LEFT_MASK_ENABLE_INTEL 0x60
|
||||
#define CL_AVC_ME_INTRA_NEIGHBOR_UPPER_MASK_ENABLE_INTEL 0x10
|
||||
#define CL_AVC_ME_INTRA_NEIGHBOR_UPPER_RIGHT_MASK_ENABLE_INTEL 0x8
|
||||
#define CL_AVC_ME_INTRA_NEIGHBOR_UPPER_LEFT_MASK_ENABLE_INTEL 0x4
|
||||
|
||||
#define CL_AVC_ME_LUMA_PREDICTOR_MODE_VERTICAL_INTEL 0x0
|
||||
#define CL_AVC_ME_LUMA_PREDICTOR_MODE_HORIZONTAL_INTEL 0x1
|
||||
#define CL_AVC_ME_LUMA_PREDICTOR_MODE_DC_INTEL 0x2
|
||||
#define CL_AVC_ME_LUMA_PREDICTOR_MODE_DIAGONAL_DOWN_LEFT_INTEL 0x3
|
||||
#define CL_AVC_ME_LUMA_PREDICTOR_MODE_DIAGONAL_DOWN_RIGHT_INTEL 0x4
|
||||
#define CL_AVC_ME_LUMA_PREDICTOR_MODE_PLANE_INTEL 0x4
|
||||
#define CL_AVC_ME_LUMA_PREDICTOR_MODE_VERTICAL_RIGHT_INTEL 0x5
|
||||
#define CL_AVC_ME_LUMA_PREDICTOR_MODE_HORIZONTAL_DOWN_INTEL 0x6
|
||||
#define CL_AVC_ME_LUMA_PREDICTOR_MODE_VERTICAL_LEFT_INTEL 0x7
|
||||
#define CL_AVC_ME_LUMA_PREDICTOR_MODE_HORIZONTAL_UP_INTEL 0x8
|
||||
#define CL_AVC_ME_CHROMA_PREDICTOR_MODE_DC_INTEL 0x0
|
||||
#define CL_AVC_ME_CHROMA_PREDICTOR_MODE_HORIZONTAL_INTEL 0x1
|
||||
#define CL_AVC_ME_CHROMA_PREDICTOR_MODE_VERTICAL_INTEL 0x2
|
||||
#define CL_AVC_ME_CHROMA_PREDICTOR_MODE_PLANE_INTEL 0x3
|
||||
|
||||
#define CL_AVC_ME_FRAME_FORWARD_INTEL 0x1
|
||||
#define CL_AVC_ME_FRAME_BACKWARD_INTEL 0x2
|
||||
#define CL_AVC_ME_FRAME_DUAL_INTEL 0x3
|
||||
|
||||
#define CL_AVC_ME_SLICE_TYPE_PRED_INTEL 0x0
|
||||
#define CL_AVC_ME_SLICE_TYPE_BPRED_INTEL 0x1
|
||||
#define CL_AVC_ME_SLICE_TYPE_INTRA_INTEL 0x2
|
||||
|
||||
#define CL_AVC_ME_INTERLACED_SCAN_TOP_FIELD_INTEL 0x0
|
||||
#define CL_AVC_ME_INTERLACED_SCAN_BOTTOM_FIELD_INTEL 0x1
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __CL_EXT_INTEL_H */
|
||||
|
||||
#include <CL/cl_ext.h>
|
||||
#pragma message("The Intel extensions have been moved into cl_ext.h. Please include cl_ext.h directly.")
|
||||
|
||||
207
third_party/opencl_headers/CL/cl_gl.h
vendored
207
third_party/opencl_headers/CL/cl_gl.h
vendored
@@ -1,39 +1,23 @@
|
||||
/**********************************************************************************
|
||||
* Copyright (c) 2008-2018 The Khronos Group Inc.
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2008-2021 The Khronos Group Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and/or associated documentation files (the
|
||||
* "Materials"), to deal in the Materials without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
* permit persons to whom the Materials are furnished to do so, subject to
|
||||
* the following conditions:
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Materials.
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
|
||||
* KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
|
||||
* SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
|
||||
* https://www.khronos.org/registry/
|
||||
*
|
||||
* THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
**********************************************************************************/
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
******************************************************************************/
|
||||
|
||||
#ifndef __OPENCL_CL_GL_H
|
||||
#define __OPENCL_CL_GL_H
|
||||
|
||||
#ifdef __APPLE__
|
||||
#include <OpenCL/cl.h>
|
||||
#else
|
||||
#include <CL/cl.h>
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
@@ -65,109 +49,144 @@ typedef struct __GLsync *cl_GLsync;
|
||||
|
||||
|
||||
extern CL_API_ENTRY cl_mem CL_API_CALL
|
||||
clCreateFromGLBuffer(cl_context /* context */,
|
||||
cl_mem_flags /* flags */,
|
||||
cl_GLuint /* bufobj */,
|
||||
int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0;
|
||||
clCreateFromGLBuffer(cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_GLuint bufobj,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
#ifdef CL_VERSION_1_2
|
||||
|
||||
extern CL_API_ENTRY cl_mem CL_API_CALL
|
||||
clCreateFromGLTexture(cl_context /* context */,
|
||||
cl_mem_flags /* flags */,
|
||||
cl_GLenum /* target */,
|
||||
cl_GLint /* miplevel */,
|
||||
cl_GLuint /* texture */,
|
||||
cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
clCreateFromGLTexture(cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_GLenum target,
|
||||
cl_GLint miplevel,
|
||||
cl_GLuint texture,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
#endif
|
||||
|
||||
extern CL_API_ENTRY cl_mem CL_API_CALL
|
||||
clCreateFromGLRenderbuffer(cl_context /* context */,
|
||||
cl_mem_flags /* flags */,
|
||||
cl_GLuint /* renderbuffer */,
|
||||
cl_int * /* errcode_ret */) CL_API_SUFFIX__VERSION_1_0;
|
||||
clCreateFromGLRenderbuffer(cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_GLuint renderbuffer,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clGetGLObjectInfo(cl_mem /* memobj */,
|
||||
cl_gl_object_type * /* gl_object_type */,
|
||||
cl_GLuint * /* gl_object_name */) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clGetGLTextureInfo(cl_mem /* memobj */,
|
||||
cl_gl_texture_info /* param_name */,
|
||||
size_t /* param_value_size */,
|
||||
void * /* param_value */,
|
||||
size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0;
|
||||
clGetGLObjectInfo(cl_mem memobj,
|
||||
cl_gl_object_type * gl_object_type,
|
||||
cl_GLuint * gl_object_name) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clEnqueueAcquireGLObjects(cl_command_queue /* command_queue */,
|
||||
cl_uint /* num_objects */,
|
||||
const cl_mem * /* mem_objects */,
|
||||
cl_uint /* num_events_in_wait_list */,
|
||||
const cl_event * /* event_wait_list */,
|
||||
cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0;
|
||||
clGetGLTextureInfo(cl_mem memobj,
|
||||
cl_gl_texture_info param_name,
|
||||
size_t param_value_size,
|
||||
void * param_value,
|
||||
size_t * param_value_size_ret) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clEnqueueReleaseGLObjects(cl_command_queue /* command_queue */,
|
||||
cl_uint /* num_objects */,
|
||||
const cl_mem * /* mem_objects */,
|
||||
cl_uint /* num_events_in_wait_list */,
|
||||
const cl_event * /* event_wait_list */,
|
||||
cl_event * /* event */) CL_API_SUFFIX__VERSION_1_0;
|
||||
clEnqueueAcquireGLObjects(cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clEnqueueReleaseGLObjects(cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem * mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event * event_wait_list,
|
||||
cl_event * event) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
|
||||
/* Deprecated OpenCL 1.1 APIs */
|
||||
extern CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED cl_mem CL_API_CALL
|
||||
clCreateFromGLTexture2D(cl_context /* context */,
|
||||
cl_mem_flags /* flags */,
|
||||
cl_GLenum /* target */,
|
||||
cl_GLint /* miplevel */,
|
||||
cl_GLuint /* texture */,
|
||||
cl_int * /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
extern CL_API_ENTRY CL_EXT_PREFIX__VERSION_1_1_DEPRECATED cl_mem CL_API_CALL
|
||||
clCreateFromGLTexture3D(cl_context /* context */,
|
||||
cl_mem_flags /* flags */,
|
||||
cl_GLenum /* target */,
|
||||
cl_GLint /* miplevel */,
|
||||
cl_GLuint /* texture */,
|
||||
cl_int * /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
extern CL_API_ENTRY CL_API_PREFIX__VERSION_1_1_DEPRECATED cl_mem CL_API_CALL
|
||||
clCreateFromGLTexture2D(cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_GLenum target,
|
||||
cl_GLint miplevel,
|
||||
cl_GLuint texture,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
extern CL_API_ENTRY CL_API_PREFIX__VERSION_1_1_DEPRECATED cl_mem CL_API_CALL
|
||||
clCreateFromGLTexture3D(cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_GLenum target,
|
||||
cl_GLint miplevel,
|
||||
cl_GLuint texture,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_1_DEPRECATED;
|
||||
|
||||
/* cl_khr_gl_sharing extension */
|
||||
|
||||
|
||||
#define cl_khr_gl_sharing 1
|
||||
|
||||
|
||||
typedef cl_uint cl_gl_context_info;
|
||||
|
||||
|
||||
/* Additional Error Codes */
|
||||
#define CL_INVALID_GL_SHAREGROUP_REFERENCE_KHR -1000
|
||||
|
||||
|
||||
/* cl_gl_context_info */
|
||||
#define CL_CURRENT_DEVICE_FOR_GL_CONTEXT_KHR 0x2006
|
||||
#define CL_DEVICES_FOR_GL_CONTEXT_KHR 0x2007
|
||||
|
||||
|
||||
/* Additional cl_context_properties */
|
||||
#define CL_GL_CONTEXT_KHR 0x2008
|
||||
#define CL_EGL_DISPLAY_KHR 0x2009
|
||||
#define CL_GLX_DISPLAY_KHR 0x200A
|
||||
#define CL_WGL_HDC_KHR 0x200B
|
||||
#define CL_CGL_SHAREGROUP_KHR 0x200C
|
||||
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clGetGLContextInfoKHR(const cl_context_properties * /* properties */,
|
||||
cl_gl_context_info /* param_name */,
|
||||
size_t /* param_value_size */,
|
||||
void * /* param_value */,
|
||||
size_t * /* param_value_size_ret */) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clGetGLContextInfoKHR_fn)(
|
||||
clGetGLContextInfoKHR(const cl_context_properties * properties,
|
||||
cl_gl_context_info param_name,
|
||||
size_t param_value_size,
|
||||
void * param_value,
|
||||
size_t * param_value_size_ret) CL_API_SUFFIX__VERSION_1_0;
|
||||
|
||||
typedef cl_int (CL_API_CALL *clGetGLContextInfoKHR_fn)(
|
||||
const cl_context_properties * properties,
|
||||
cl_gl_context_info param_name,
|
||||
size_t param_value_size,
|
||||
void * param_value,
|
||||
size_t * param_value_size_ret);
|
||||
|
||||
/*
|
||||
* cl_khr_gl_event extension
|
||||
*/
|
||||
#define CL_COMMAND_GL_FENCE_SYNC_OBJECT_KHR 0x200D
|
||||
|
||||
extern CL_API_ENTRY cl_event CL_API_CALL
|
||||
clCreateEventFromGLsyncKHR(cl_context context,
|
||||
cl_GLsync sync,
|
||||
cl_int * errcode_ret) CL_API_SUFFIX__VERSION_1_1;
|
||||
|
||||
/***************************************************************
|
||||
* cl_intel_sharing_format_query_gl
|
||||
***************************************************************/
|
||||
#define cl_intel_sharing_format_query_gl 1
|
||||
|
||||
/* when cl_khr_gl_sharing is supported */
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clGetSupportedGLTextureFormatsINTEL(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_mem_object_type image_type,
|
||||
cl_uint num_entries,
|
||||
cl_GLenum* gl_formats,
|
||||
cl_uint* num_texture_formats) ;
|
||||
|
||||
typedef cl_int (CL_API_CALL *
|
||||
clGetSupportedGLTextureFormatsINTEL_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_mem_object_type image_type,
|
||||
cl_uint num_entries,
|
||||
cl_GLenum* gl_formats,
|
||||
cl_uint* num_texture_formats) ;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
84
third_party/opencl_headers/CL/cl_gl_ext.h
vendored
84
third_party/opencl_headers/CL/cl_gl_ext.h
vendored
@@ -1,74 +1,18 @@
|
||||
/**********************************************************************************
|
||||
* Copyright (c) 2008-2015 The Khronos Group Inc.
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2008-2021 The Khronos Group Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and/or associated documentation files (the
|
||||
* "Materials"), to deal in the Materials without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
* permit persons to whom the Materials are furnished to do so, subject to
|
||||
* the following conditions:
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Materials.
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
|
||||
* KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
|
||||
* SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
|
||||
* https://www.khronos.org/registry/
|
||||
*
|
||||
* THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
**********************************************************************************/
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
******************************************************************************/
|
||||
|
||||
/* $Revision: 11708 $ on $Date: 2010-06-13 23:36:24 -0700 (Sun, 13 Jun 2010) $ */
|
||||
|
||||
/* cl_gl_ext.h contains vendor (non-KHR) OpenCL extensions which have */
|
||||
/* OpenGL dependencies. */
|
||||
|
||||
#ifndef __OPENCL_CL_GL_EXT_H
|
||||
#define __OPENCL_CL_GL_EXT_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef __APPLE__
|
||||
#include <OpenCL/cl_gl.h>
|
||||
#else
|
||||
#include <CL/cl_gl.h>
|
||||
#endif
|
||||
|
||||
/*
|
||||
* For each extension, follow this template
|
||||
* cl_VEN_extname extension */
|
||||
/* #define cl_VEN_extname 1
|
||||
* ... define new types, if any
|
||||
* ... define new tokens, if any
|
||||
* ... define new APIs, if any
|
||||
*
|
||||
* If you need GLtypes here, mirror them with a cl_GLtype, rather than including a GL header
|
||||
* This allows us to avoid having to decide whether to include GL headers or GLES here.
|
||||
*/
|
||||
|
||||
/*
|
||||
* cl_khr_gl_event extension
|
||||
* See section 9.9 in the OpenCL 1.1 spec for more information
|
||||
*/
|
||||
#define CL_COMMAND_GL_FENCE_SYNC_OBJECT_KHR 0x200D
|
||||
|
||||
extern CL_API_ENTRY cl_event CL_API_CALL
|
||||
clCreateEventFromGLsyncKHR(cl_context /* context */,
|
||||
cl_GLsync /* cl_GLsync */,
|
||||
cl_int * /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_1;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __OPENCL_CL_GL_EXT_H */
|
||||
#include <CL/cl_gl.h>
|
||||
#pragma message("All OpenGL-related extensions have been moved into cl_gl.h. Please include cl_gl.h directly.")
|
||||
|
||||
309
third_party/opencl_headers/CL/cl_platform.h
vendored
309
third_party/opencl_headers/CL/cl_platform.h
vendored
@@ -1,55 +1,48 @@
|
||||
/**********************************************************************************
|
||||
* Copyright (c) 2008-2018 The Khronos Group Inc.
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2008-2020 The Khronos Group Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and/or associated documentation files (the
|
||||
* "Materials"), to deal in the Materials without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
* permit persons to whom the Materials are furnished to do so, subject to
|
||||
* the following conditions:
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Materials.
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
|
||||
* KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
|
||||
* SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
|
||||
* https://www.khronos.org/registry/
|
||||
*
|
||||
* THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
**********************************************************************************/
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
******************************************************************************/
|
||||
|
||||
#ifndef __CL_PLATFORM_H
|
||||
#define __CL_PLATFORM_H
|
||||
|
||||
#ifdef __APPLE__
|
||||
#include <OpenCL/cl_version.h>
|
||||
|
||||
/* Contains #defines for AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER below */
|
||||
#include <AvailabilityMacros.h>
|
||||
#else
|
||||
#include <CL/cl_version.h>
|
||||
#endif
|
||||
#include <CL/cl_version.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#if defined(_WIN32)
|
||||
#define CL_API_ENTRY
|
||||
#define CL_API_CALL __stdcall
|
||||
#define CL_CALLBACK __stdcall
|
||||
#if !defined(CL_API_ENTRY)
|
||||
#define CL_API_ENTRY
|
||||
#endif
|
||||
#if !defined(CL_API_CALL)
|
||||
#define CL_API_CALL __stdcall
|
||||
#endif
|
||||
#if !defined(CL_CALLBACK)
|
||||
#define CL_CALLBACK __stdcall
|
||||
#endif
|
||||
#else
|
||||
#define CL_API_ENTRY
|
||||
#define CL_API_CALL
|
||||
#define CL_CALLBACK
|
||||
#if !defined(CL_API_ENTRY)
|
||||
#define CL_API_ENTRY
|
||||
#endif
|
||||
#if !defined(CL_API_CALL)
|
||||
#define CL_API_CALL
|
||||
#endif
|
||||
#if !defined(CL_CALLBACK)
|
||||
#define CL_CALLBACK
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/*
|
||||
@@ -60,107 +53,99 @@ extern "C" {
|
||||
* deprecation but is deprecated in versions later than 1.1.
|
||||
*/
|
||||
|
||||
#ifdef __APPLE__
|
||||
#define CL_EXTENSION_WEAK_LINK __attribute__((weak_import))
|
||||
#define CL_API_SUFFIX__VERSION_1_0 AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER
|
||||
#define CL_EXT_SUFFIX__VERSION_1_0 CL_EXTENSION_WEAK_LINK AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER
|
||||
#define CL_API_SUFFIX__VERSION_1_1 AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER
|
||||
#define GCL_API_SUFFIX__VERSION_1_1 AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER
|
||||
#define CL_EXT_SUFFIX__VERSION_1_1 CL_EXTENSION_WEAK_LINK AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER
|
||||
#define CL_EXT_SUFFIX__VERSION_1_0_DEPRECATED CL_EXTENSION_WEAK_LINK AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7
|
||||
#ifndef CL_API_SUFFIX_USER
|
||||
#define CL_API_SUFFIX_USER
|
||||
#endif
|
||||
|
||||
#ifdef AVAILABLE_MAC_OS_X_VERSION_10_8_AND_LATER
|
||||
#define CL_API_SUFFIX__VERSION_1_2 AVAILABLE_MAC_OS_X_VERSION_10_8_AND_LATER
|
||||
#define GCL_API_SUFFIX__VERSION_1_2 AVAILABLE_MAC_OS_X_VERSION_10_8_AND_LATER
|
||||
#define CL_EXT_SUFFIX__VERSION_1_2 CL_EXTENSION_WEAK_LINK AVAILABLE_MAC_OS_X_VERSION_10_8_AND_LATER
|
||||
#define CL_EXT_PREFIX__VERSION_1_1_DEPRECATED
|
||||
#define CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED CL_EXTENSION_WEAK_LINK AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8
|
||||
#else
|
||||
#warning This path should never happen outside of internal operating system development. AvailabilityMacros do not function correctly here!
|
||||
#define CL_API_SUFFIX__VERSION_1_2 AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER
|
||||
#define GCL_API_SUFFIX__VERSION_1_2 AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER
|
||||
#define CL_EXT_SUFFIX__VERSION_1_2 CL_EXTENSION_WEAK_LINK AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER
|
||||
#define CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED CL_EXTENSION_WEAK_LINK AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER
|
||||
#endif
|
||||
#ifndef CL_API_PREFIX_USER
|
||||
#define CL_API_PREFIX_USER
|
||||
#endif
|
||||
|
||||
#define CL_API_SUFFIX_COMMON CL_API_SUFFIX_USER
|
||||
#define CL_API_PREFIX_COMMON CL_API_PREFIX_USER
|
||||
|
||||
#define CL_API_SUFFIX__VERSION_1_0 CL_API_SUFFIX_COMMON
|
||||
#define CL_API_SUFFIX__VERSION_1_1 CL_API_SUFFIX_COMMON
|
||||
#define CL_API_SUFFIX__VERSION_1_2 CL_API_SUFFIX_COMMON
|
||||
#define CL_API_SUFFIX__VERSION_2_0 CL_API_SUFFIX_COMMON
|
||||
#define CL_API_SUFFIX__VERSION_2_1 CL_API_SUFFIX_COMMON
|
||||
#define CL_API_SUFFIX__VERSION_2_2 CL_API_SUFFIX_COMMON
|
||||
#define CL_API_SUFFIX__VERSION_3_0 CL_API_SUFFIX_COMMON
|
||||
#define CL_API_SUFFIX__EXPERIMENTAL CL_API_SUFFIX_COMMON
|
||||
|
||||
|
||||
#ifdef __GNUC__
|
||||
#define CL_API_SUFFIX_DEPRECATED __attribute__((deprecated))
|
||||
#define CL_API_PREFIX_DEPRECATED
|
||||
#elif defined(_WIN32)
|
||||
#define CL_API_SUFFIX_DEPRECATED
|
||||
#define CL_API_PREFIX_DEPRECATED __declspec(deprecated)
|
||||
#else
|
||||
#define CL_EXTENSION_WEAK_LINK
|
||||
#define CL_API_SUFFIX__VERSION_1_0
|
||||
#define CL_EXT_SUFFIX__VERSION_1_0
|
||||
#define CL_API_SUFFIX__VERSION_1_1
|
||||
#define CL_EXT_SUFFIX__VERSION_1_1
|
||||
#define CL_API_SUFFIX__VERSION_1_2
|
||||
#define CL_EXT_SUFFIX__VERSION_1_2
|
||||
#define CL_API_SUFFIX__VERSION_2_0
|
||||
#define CL_EXT_SUFFIX__VERSION_2_0
|
||||
#define CL_API_SUFFIX__VERSION_2_1
|
||||
#define CL_EXT_SUFFIX__VERSION_2_1
|
||||
#define CL_API_SUFFIX__VERSION_2_2
|
||||
#define CL_EXT_SUFFIX__VERSION_2_2
|
||||
#define CL_API_SUFFIX__VERSION_3_0
|
||||
#define CL_EXT_SUFFIX__VERSION_3_0
|
||||
#define CL_API_SUFFIX_DEPRECATED
|
||||
#define CL_API_PREFIX_DEPRECATED
|
||||
#endif
|
||||
|
||||
#ifdef __GNUC__
|
||||
#define CL_EXT_SUFFIX_DEPRECATED __attribute__((deprecated))
|
||||
#define CL_EXT_PREFIX_DEPRECATED
|
||||
#elif defined(_WIN32)
|
||||
#define CL_EXT_SUFFIX_DEPRECATED
|
||||
#define CL_EXT_PREFIX_DEPRECATED __declspec(deprecated)
|
||||
#else
|
||||
#define CL_EXT_SUFFIX_DEPRECATED
|
||||
#define CL_EXT_PREFIX_DEPRECATED
|
||||
#endif
|
||||
#ifdef CL_USE_DEPRECATED_OPENCL_1_0_APIS
|
||||
#define CL_API_SUFFIX__VERSION_1_0_DEPRECATED CL_API_SUFFIX_COMMON
|
||||
#define CL_API_PREFIX__VERSION_1_0_DEPRECATED CL_API_PREFIX_COMMON
|
||||
#else
|
||||
#define CL_API_SUFFIX__VERSION_1_0_DEPRECATED CL_API_SUFFIX_COMMON CL_API_SUFFIX_DEPRECATED
|
||||
#define CL_API_PREFIX__VERSION_1_0_DEPRECATED CL_API_PREFIX_COMMON CL_API_PREFIX_DEPRECATED
|
||||
#endif
|
||||
|
||||
#ifdef CL_USE_DEPRECATED_OPENCL_1_0_APIS
|
||||
#define CL_EXT_SUFFIX__VERSION_1_0_DEPRECATED
|
||||
#define CL_EXT_PREFIX__VERSION_1_0_DEPRECATED
|
||||
#else
|
||||
#define CL_EXT_SUFFIX__VERSION_1_0_DEPRECATED CL_EXT_SUFFIX_DEPRECATED
|
||||
#define CL_EXT_PREFIX__VERSION_1_0_DEPRECATED CL_EXT_PREFIX_DEPRECATED
|
||||
#endif
|
||||
#ifdef CL_USE_DEPRECATED_OPENCL_1_1_APIS
|
||||
#define CL_API_SUFFIX__VERSION_1_1_DEPRECATED CL_API_SUFFIX_COMMON
|
||||
#define CL_API_PREFIX__VERSION_1_1_DEPRECATED CL_API_PREFIX_COMMON
|
||||
#else
|
||||
#define CL_API_SUFFIX__VERSION_1_1_DEPRECATED CL_API_SUFFIX_COMMON CL_API_SUFFIX_DEPRECATED
|
||||
#define CL_API_PREFIX__VERSION_1_1_DEPRECATED CL_API_PREFIX_COMMON CL_API_PREFIX_DEPRECATED
|
||||
#endif
|
||||
|
||||
#ifdef CL_USE_DEPRECATED_OPENCL_1_1_APIS
|
||||
#define CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED
|
||||
#define CL_EXT_PREFIX__VERSION_1_1_DEPRECATED
|
||||
#else
|
||||
#define CL_EXT_SUFFIX__VERSION_1_1_DEPRECATED CL_EXT_SUFFIX_DEPRECATED
|
||||
#define CL_EXT_PREFIX__VERSION_1_1_DEPRECATED CL_EXT_PREFIX_DEPRECATED
|
||||
#endif
|
||||
#ifdef CL_USE_DEPRECATED_OPENCL_1_2_APIS
|
||||
#define CL_API_SUFFIX__VERSION_1_2_DEPRECATED CL_API_SUFFIX_COMMON
|
||||
#define CL_API_PREFIX__VERSION_1_2_DEPRECATED CL_API_PREFIX_COMMON
|
||||
#else
|
||||
#define CL_API_SUFFIX__VERSION_1_2_DEPRECATED CL_API_SUFFIX_COMMON CL_API_SUFFIX_DEPRECATED
|
||||
#define CL_API_PREFIX__VERSION_1_2_DEPRECATED CL_API_PREFIX_COMMON CL_API_PREFIX_DEPRECATED
|
||||
#endif
|
||||
|
||||
#ifdef CL_USE_DEPRECATED_OPENCL_1_2_APIS
|
||||
#define CL_EXT_SUFFIX__VERSION_1_2_DEPRECATED
|
||||
#define CL_EXT_PREFIX__VERSION_1_2_DEPRECATED
|
||||
#else
|
||||
#define CL_EXT_SUFFIX__VERSION_1_2_DEPRECATED CL_EXT_SUFFIX_DEPRECATED
|
||||
#define CL_EXT_PREFIX__VERSION_1_2_DEPRECATED CL_EXT_PREFIX_DEPRECATED
|
||||
#endif
|
||||
#ifdef CL_USE_DEPRECATED_OPENCL_2_0_APIS
|
||||
#define CL_API_SUFFIX__VERSION_2_0_DEPRECATED CL_API_SUFFIX_COMMON
|
||||
#define CL_API_PREFIX__VERSION_2_0_DEPRECATED CL_API_PREFIX_COMMON
|
||||
#else
|
||||
#define CL_API_SUFFIX__VERSION_2_0_DEPRECATED CL_API_SUFFIX_COMMON CL_API_SUFFIX_DEPRECATED
|
||||
#define CL_API_PREFIX__VERSION_2_0_DEPRECATED CL_API_PREFIX_COMMON CL_API_PREFIX_DEPRECATED
|
||||
#endif
|
||||
|
||||
#ifdef CL_USE_DEPRECATED_OPENCL_2_0_APIS
|
||||
#define CL_EXT_SUFFIX__VERSION_2_0_DEPRECATED
|
||||
#define CL_EXT_PREFIX__VERSION_2_0_DEPRECATED
|
||||
#else
|
||||
#define CL_EXT_SUFFIX__VERSION_2_0_DEPRECATED CL_EXT_SUFFIX_DEPRECATED
|
||||
#define CL_EXT_PREFIX__VERSION_2_0_DEPRECATED CL_EXT_PREFIX_DEPRECATED
|
||||
#endif
|
||||
#ifdef CL_USE_DEPRECATED_OPENCL_2_1_APIS
|
||||
#define CL_API_SUFFIX__VERSION_2_1_DEPRECATED CL_API_SUFFIX_COMMON
|
||||
#define CL_API_PREFIX__VERSION_2_1_DEPRECATED CL_API_PREFIX_COMMON
|
||||
#else
|
||||
#define CL_API_SUFFIX__VERSION_2_1_DEPRECATED CL_API_SUFFIX_COMMON CL_API_SUFFIX_DEPRECATED
|
||||
#define CL_API_PREFIX__VERSION_2_1_DEPRECATED CL_API_PREFIX_COMMON CL_API_PREFIX_DEPRECATED
|
||||
#endif
|
||||
|
||||
#ifdef CL_USE_DEPRECATED_OPENCL_2_1_APIS
|
||||
#define CL_EXT_SUFFIX__VERSION_2_1_DEPRECATED
|
||||
#define CL_EXT_PREFIX__VERSION_2_1_DEPRECATED
|
||||
#else
|
||||
#define CL_EXT_SUFFIX__VERSION_2_1_DEPRECATED CL_EXT_SUFFIX_DEPRECATED
|
||||
#define CL_EXT_PREFIX__VERSION_2_1_DEPRECATED CL_EXT_PREFIX_DEPRECATED
|
||||
#endif
|
||||
|
||||
#ifdef CL_USE_DEPRECATED_OPENCL_2_2_APIS
|
||||
#define CL_EXT_SUFFIX__VERSION_2_2_DEPRECATED
|
||||
#define CL_EXT_PREFIX__VERSION_2_2_DEPRECATED
|
||||
#else
|
||||
#define CL_EXT_SUFFIX__VERSION_2_2_DEPRECATED CL_EXT_SUFFIX_DEPRECATED
|
||||
#define CL_EXT_PREFIX__VERSION_2_2_DEPRECATED CL_EXT_PREFIX_DEPRECATED
|
||||
#endif
|
||||
#ifdef CL_USE_DEPRECATED_OPENCL_2_2_APIS
|
||||
#define CL_API_SUFFIX__VERSION_2_2_DEPRECATED CL_API_SUFFIX_COMMON
|
||||
#define CL_API_PREFIX__VERSION_2_2_DEPRECATED CL_API_PREFIX_COMMON
|
||||
#else
|
||||
#define CL_API_SUFFIX__VERSION_2_2_DEPRECATED CL_API_SUFFIX_COMMON CL_API_SUFFIX_DEPRECATED
|
||||
#define CL_API_PREFIX__VERSION_2_2_DEPRECATED CL_API_PREFIX_COMMON CL_API_PREFIX_DEPRECATED
|
||||
#endif
|
||||
|
||||
#if (defined (_WIN32) && defined(_MSC_VER))
|
||||
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wlanguage-extension-token"
|
||||
#endif
|
||||
|
||||
/* intptr_t is used in cl.h and provided by stddef.h in Visual C++, but not in clang */
|
||||
/* stdint.h was missing before Visual Studio 2010, include it for later versions and for clang */
|
||||
#if defined(__clang__) || _MSC_VER >= 1600
|
||||
#include <stdint.h>
|
||||
#endif
|
||||
|
||||
/* scalar types */
|
||||
typedef signed __int8 cl_char;
|
||||
typedef unsigned __int8 cl_uchar;
|
||||
@@ -175,6 +160,10 @@ typedef unsigned __int16 cl_half;
|
||||
typedef float cl_float;
|
||||
typedef double cl_double;
|
||||
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
|
||||
/* Macro names and corresponding values defined by OpenCL */
|
||||
#define CL_CHAR_BIT 8
|
||||
#define CL_SCHAR_MAX 127
|
||||
@@ -266,16 +255,16 @@ typedef double cl_double;
|
||||
/* scalar types */
|
||||
typedef int8_t cl_char;
|
||||
typedef uint8_t cl_uchar;
|
||||
typedef int16_t cl_short __attribute__((aligned(2)));
|
||||
typedef uint16_t cl_ushort __attribute__((aligned(2)));
|
||||
typedef int32_t cl_int __attribute__((aligned(4)));
|
||||
typedef uint32_t cl_uint __attribute__((aligned(4)));
|
||||
typedef int64_t cl_long __attribute__((aligned(8)));
|
||||
typedef uint64_t cl_ulong __attribute__((aligned(8)));
|
||||
typedef int16_t cl_short;
|
||||
typedef uint16_t cl_ushort;
|
||||
typedef int32_t cl_int;
|
||||
typedef uint32_t cl_uint;
|
||||
typedef int64_t cl_long;
|
||||
typedef uint64_t cl_ulong;
|
||||
|
||||
typedef uint16_t cl_half __attribute__((aligned(2)));
|
||||
typedef float cl_float __attribute__((aligned(4)));
|
||||
typedef double cl_double __attribute__((aligned(8)));
|
||||
typedef uint16_t cl_half;
|
||||
typedef float cl_float;
|
||||
typedef double cl_double;
|
||||
|
||||
/* Macro names and corresponding values defined by OpenCL */
|
||||
#define CL_CHAR_BIT 8
|
||||
@@ -395,14 +384,16 @@ typedef unsigned int cl_GLenum;
|
||||
|
||||
/* Define basic vector types */
|
||||
#if defined( __VEC__ )
|
||||
#include <altivec.h> /* may be omitted depending on compiler. AltiVec spec provides no way to detect whether the header is required. */
|
||||
typedef vector unsigned char __cl_uchar16;
|
||||
typedef vector signed char __cl_char16;
|
||||
typedef vector unsigned short __cl_ushort8;
|
||||
typedef vector signed short __cl_short8;
|
||||
typedef vector unsigned int __cl_uint4;
|
||||
typedef vector signed int __cl_int4;
|
||||
typedef vector float __cl_float4;
|
||||
#if !defined(__clang__)
|
||||
#include <altivec.h> /* may be omitted depending on compiler. AltiVec spec provides no way to detect whether the header is required. */
|
||||
#endif
|
||||
typedef __vector unsigned char __cl_uchar16;
|
||||
typedef __vector signed char __cl_char16;
|
||||
typedef __vector unsigned short __cl_ushort8;
|
||||
typedef __vector signed short __cl_short8;
|
||||
typedef __vector unsigned int __cl_uint4;
|
||||
typedef __vector signed int __cl_int4;
|
||||
typedef __vector float __cl_float4;
|
||||
#define __CL_UCHAR16__ 1
|
||||
#define __CL_CHAR16__ 1
|
||||
#define __CL_USHORT8__ 1
|
||||
@@ -519,27 +510,25 @@ typedef unsigned int cl_GLenum;
|
||||
#if !defined(__cplusplus) && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201112L
|
||||
#define __CL_HAS_ANON_STRUCT__ 1
|
||||
#define __CL_ANON_STRUCT__
|
||||
#elif defined( __GNUC__) && ! defined( __STRICT_ANSI__ )
|
||||
#elif defined(_WIN32) && defined(_MSC_VER) && !defined(__STDC__)
|
||||
#define __CL_HAS_ANON_STRUCT__ 1
|
||||
#define __CL_ANON_STRUCT__
|
||||
#elif defined(__GNUC__) && ! defined(__STRICT_ANSI__)
|
||||
#define __CL_HAS_ANON_STRUCT__ 1
|
||||
#define __CL_ANON_STRUCT__ __extension__
|
||||
#elif defined( _WIN32) && defined(_MSC_VER)
|
||||
#if _MSC_VER >= 1500
|
||||
/* Microsoft Developer Studio 2008 supports anonymous structs, but
|
||||
* complains by default. */
|
||||
#define __CL_HAS_ANON_STRUCT__ 1
|
||||
#define __CL_ANON_STRUCT__
|
||||
/* Disable warning C4201: nonstandard extension used : nameless
|
||||
* struct/union */
|
||||
#pragma warning( push )
|
||||
#pragma warning( disable : 4201 )
|
||||
#endif
|
||||
#else
|
||||
#define __CL_HAS_ANON_STRUCT__ 0
|
||||
#define __CL_ANON_STRUCT__
|
||||
#endif
|
||||
|
||||
#if defined(_WIN32) && defined(_MSC_VER) && __CL_HAS_ANON_STRUCT__
|
||||
/* Disable warning C4201: nonstandard extension used : nameless struct/union */
|
||||
#pragma warning( push )
|
||||
#pragma warning( disable : 4201 )
|
||||
#endif
|
||||
|
||||
/* Define alignment keys */
|
||||
#if defined( __GNUC__ )
|
||||
#if defined( __GNUC__ ) || defined(__INTEGRITY)
|
||||
#define CL_ALIGNED(_x) __attribute__ ((aligned(_x)))
|
||||
#elif defined( _WIN32) && (_MSC_VER)
|
||||
/* Alignment keys neutered on windows because MSVC can't swallow function arguments with alignment requirements */
|
||||
@@ -1413,12 +1402,8 @@ typedef union
|
||||
}
|
||||
#endif
|
||||
|
||||
#undef __CL_HAS_ANON_STRUCT__
|
||||
#undef __CL_ANON_STRUCT__
|
||||
#if defined( _WIN32) && defined(_MSC_VER)
|
||||
#if _MSC_VER >=1500
|
||||
#if defined(_WIN32) && defined(_MSC_VER) && __CL_HAS_ANON_STRUCT__
|
||||
#pragma warning( pop )
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#endif /* __CL_PLATFORM_H */
|
||||
|
||||
@@ -1,54 +1,18 @@
|
||||
/**********************************************************************************
|
||||
* Copyright (c) 2008-2016 The Khronos Group Inc.
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2008-2020 The Khronos Group Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and/or associated documentation files (the
|
||||
* "Materials"), to deal in the Materials without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
* permit persons to whom the Materials are furnished to do so, subject to
|
||||
* the following conditions:
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Materials.
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
|
||||
* KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
|
||||
* SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
|
||||
* https://www.khronos.org/registry/
|
||||
*
|
||||
* THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
**********************************************************************************/
|
||||
/*****************************************************************************\
|
||||
|
||||
Copyright (c) 2013-2016 Intel Corporation All Rights Reserved.
|
||||
|
||||
THESE MATERIALS ARE PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL INTEL OR ITS
|
||||
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
||||
EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
||||
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
||||
PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
|
||||
OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY OR TORT (INCLUDING
|
||||
NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THESE
|
||||
MATERIALS, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
File Name: cl_va_api_media_sharing_intel.h
|
||||
|
||||
Abstract:
|
||||
|
||||
Notes:
|
||||
|
||||
\*****************************************************************************/
|
||||
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
******************************************************************************/
|
||||
|
||||
#ifndef __OPENCL_CL_VA_API_MEDIA_SHARING_INTEL_H
|
||||
#define __OPENCL_CL_VA_API_MEDIA_SHARING_INTEL_H
|
||||
@@ -61,6 +25,33 @@ Notes:
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/***************************************************************
|
||||
* cl_intel_sharing_format_query_va_api
|
||||
***************************************************************/
|
||||
#define cl_intel_sharing_format_query_va_api 1
|
||||
|
||||
/* when cl_intel_va_api_media_sharing is supported */
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clGetSupportedVA_APIMediaSurfaceFormatsINTEL(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_mem_object_type image_type,
|
||||
cl_uint plane,
|
||||
cl_uint num_entries,
|
||||
VAImageFormat* va_api_formats,
|
||||
cl_uint* num_surface_formats) ;
|
||||
|
||||
typedef cl_int (CL_API_CALL *
|
||||
clGetSupportedVA_APIMediaSurfaceFormatsINTEL_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
cl_mem_object_type image_type,
|
||||
cl_uint plane,
|
||||
cl_uint num_entries,
|
||||
VAImageFormat* va_api_formats,
|
||||
cl_uint* num_surface_formats) ;
|
||||
|
||||
/******************************************
|
||||
* cl_intel_va_api_media_sharing extension *
|
||||
*******************************************/
|
||||
@@ -98,71 +89,71 @@ typedef cl_uint cl_va_api_device_set_intel;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clGetDeviceIDsFromVA_APIMediaAdapterINTEL(
|
||||
cl_platform_id /* platform */,
|
||||
cl_va_api_device_source_intel /* media_adapter_type */,
|
||||
void* /* media_adapter */,
|
||||
cl_va_api_device_set_intel /* media_adapter_set */,
|
||||
cl_uint /* num_entries */,
|
||||
cl_device_id* /* devices */,
|
||||
cl_uint* /* num_devices */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
cl_platform_id platform,
|
||||
cl_va_api_device_source_intel media_adapter_type,
|
||||
void* media_adapter,
|
||||
cl_va_api_device_set_intel media_adapter_set,
|
||||
cl_uint num_entries,
|
||||
cl_device_id* devices,
|
||||
cl_uint* num_devices) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL * clGetDeviceIDsFromVA_APIMediaAdapterINTEL_fn)(
|
||||
cl_platform_id /* platform */,
|
||||
cl_va_api_device_source_intel /* media_adapter_type */,
|
||||
void* /* media_adapter */,
|
||||
cl_va_api_device_set_intel /* media_adapter_set */,
|
||||
cl_uint /* num_entries */,
|
||||
cl_device_id* /* devices */,
|
||||
cl_uint* /* num_devices */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
typedef cl_int (CL_API_CALL * clGetDeviceIDsFromVA_APIMediaAdapterINTEL_fn)(
|
||||
cl_platform_id platform,
|
||||
cl_va_api_device_source_intel media_adapter_type,
|
||||
void* media_adapter,
|
||||
cl_va_api_device_set_intel media_adapter_set,
|
||||
cl_uint num_entries,
|
||||
cl_device_id* devices,
|
||||
cl_uint* num_devices) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
extern CL_API_ENTRY cl_mem CL_API_CALL
|
||||
clCreateFromVA_APIMediaSurfaceINTEL(
|
||||
cl_context /* context */,
|
||||
cl_mem_flags /* flags */,
|
||||
VASurfaceID* /* surface */,
|
||||
cl_uint /* plane */,
|
||||
cl_int* /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
VASurfaceID* surface,
|
||||
cl_uint plane,
|
||||
cl_int* errcode_ret) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_mem (CL_API_CALL * clCreateFromVA_APIMediaSurfaceINTEL_fn)(
|
||||
cl_context /* context */,
|
||||
cl_mem_flags /* flags */,
|
||||
VASurfaceID* /* surface */,
|
||||
cl_uint /* plane */,
|
||||
cl_int* /* errcode_ret */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
typedef cl_mem (CL_API_CALL * clCreateFromVA_APIMediaSurfaceINTEL_fn)(
|
||||
cl_context context,
|
||||
cl_mem_flags flags,
|
||||
VASurfaceID* surface,
|
||||
cl_uint plane,
|
||||
cl_int* errcode_ret) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clEnqueueAcquireVA_APIMediaSurfacesINTEL(
|
||||
cl_command_queue /* command_queue */,
|
||||
cl_uint /* num_objects */,
|
||||
const cl_mem* /* mem_objects */,
|
||||
cl_uint /* num_events_in_wait_list */,
|
||||
const cl_event* /* event_wait_list */,
|
||||
cl_event* /* event */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem* mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event* event_wait_list,
|
||||
cl_event* event) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueAcquireVA_APIMediaSurfacesINTEL_fn)(
|
||||
cl_command_queue /* command_queue */,
|
||||
cl_uint /* num_objects */,
|
||||
const cl_mem* /* mem_objects */,
|
||||
cl_uint /* num_events_in_wait_list */,
|
||||
const cl_event* /* event_wait_list */,
|
||||
cl_event* /* event */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
typedef cl_int (CL_API_CALL *clEnqueueAcquireVA_APIMediaSurfacesINTEL_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem* mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event* event_wait_list,
|
||||
cl_event* event) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
extern CL_API_ENTRY cl_int CL_API_CALL
|
||||
clEnqueueReleaseVA_APIMediaSurfacesINTEL(
|
||||
cl_command_queue /* command_queue */,
|
||||
cl_uint /* num_objects */,
|
||||
const cl_mem* /* mem_objects */,
|
||||
cl_uint /* num_events_in_wait_list */,
|
||||
const cl_event* /* event_wait_list */,
|
||||
cl_event* /* event */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef CL_API_ENTRY cl_int (CL_API_CALL *clEnqueueReleaseVA_APIMediaSurfacesINTEL_fn)(
|
||||
cl_command_queue /* command_queue */,
|
||||
cl_uint /* num_objects */,
|
||||
const cl_mem* /* mem_objects */,
|
||||
cl_uint /* num_events_in_wait_list */,
|
||||
const cl_event* /* event_wait_list */,
|
||||
cl_event* /* event */) CL_EXT_SUFFIX__VERSION_1_2;
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem* mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event* event_wait_list,
|
||||
cl_event* event) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
typedef cl_int (CL_API_CALL *clEnqueueReleaseVA_APIMediaSurfacesINTEL_fn)(
|
||||
cl_command_queue command_queue,
|
||||
cl_uint num_objects,
|
||||
const cl_mem* mem_objects,
|
||||
cl_uint num_events_in_wait_list,
|
||||
const cl_event* event_wait_list,
|
||||
cl_event* event) CL_API_SUFFIX__VERSION_1_2;
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
||||
40
third_party/opencl_headers/CL/cl_version.h
vendored
40
third_party/opencl_headers/CL/cl_version.h
vendored
@@ -1,29 +1,17 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2018 The Khronos Group Inc.
|
||||
* Copyright (c) 2018-2020 The Khronos Group Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and/or associated documentation files (the
|
||||
* "Materials"), to deal in the Materials without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
* permit persons to whom the Materials are furnished to do so, subject to
|
||||
* the following conditions:
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Materials.
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
|
||||
* KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
|
||||
* SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
|
||||
* https://www.khronos.org/registry/
|
||||
*
|
||||
* THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
******************************************************************************/
|
||||
|
||||
#ifndef __CL_VERSION_H
|
||||
@@ -31,8 +19,8 @@
|
||||
|
||||
/* Detect which version to target */
|
||||
#if !defined(CL_TARGET_OPENCL_VERSION)
|
||||
#pragma message("cl_version.h: CL_TARGET_OPENCL_VERSION is not defined. Defaulting to 220 (OpenCL 2.2)")
|
||||
#define CL_TARGET_OPENCL_VERSION 220
|
||||
#pragma message("cl_version.h: CL_TARGET_OPENCL_VERSION is not defined. Defaulting to 300 (OpenCL 3.0)")
|
||||
#define CL_TARGET_OPENCL_VERSION 300
|
||||
#endif
|
||||
#if CL_TARGET_OPENCL_VERSION != 100 && \
|
||||
CL_TARGET_OPENCL_VERSION != 110 && \
|
||||
@@ -41,9 +29,9 @@
|
||||
CL_TARGET_OPENCL_VERSION != 210 && \
|
||||
CL_TARGET_OPENCL_VERSION != 220 && \
|
||||
CL_TARGET_OPENCL_VERSION != 300
|
||||
#pragma message("cl_version: CL_TARGET_OPENCL_VERSION is not a valid value (100, 110, 120, 200, 210, 220, 300). Defaulting to 220 (OpenCL 2.2)")
|
||||
#pragma message("cl_version: CL_TARGET_OPENCL_VERSION is not a valid value (100, 110, 120, 200, 210, 220, 300). Defaulting to 300 (OpenCL 3.0)")
|
||||
#undef CL_TARGET_OPENCL_VERSION
|
||||
#define CL_TARGET_OPENCL_VERSION 220
|
||||
#define CL_TARGET_OPENCL_VERSION 300
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
47
third_party/opencl_headers/CL/opencl.h
vendored
47
third_party/opencl_headers/CL/opencl.h
vendored
@@ -1,33 +1,19 @@
|
||||
/*******************************************************************************
|
||||
* Copyright (c) 2008-2015 The Khronos Group Inc.
|
||||
* Copyright (c) 2008-2021 The Khronos Group Inc.
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a
|
||||
* copy of this software and/or associated documentation files (the
|
||||
* "Materials"), to deal in the Materials without restriction, including
|
||||
* without limitation the rights to use, copy, modify, merge, publish,
|
||||
* distribute, sublicense, and/or sell copies of the Materials, and to
|
||||
* permit persons to whom the Materials are furnished to do so, subject to
|
||||
* the following conditions:
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included
|
||||
* in all copies or substantial portions of the Materials.
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS
|
||||
* KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS
|
||||
* SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT
|
||||
* https://www.khronos.org/registry/
|
||||
*
|
||||
* THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
||||
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
|
||||
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
|
||||
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
||||
* MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS.
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
******************************************************************************/
|
||||
|
||||
/* $Revision: 11708 $ on $Date: 2010-06-13 23:36:24 -0700 (Sun, 13 Jun 2010) $ */
|
||||
|
||||
#ifndef __OPENCL_H
|
||||
#define __OPENCL_H
|
||||
|
||||
@@ -35,25 +21,12 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifdef __APPLE__
|
||||
|
||||
#include <OpenCL/cl.h>
|
||||
#include <OpenCL/cl_gl.h>
|
||||
#include <OpenCL/cl_gl_ext.h>
|
||||
#include <OpenCL/cl_ext.h>
|
||||
|
||||
#else
|
||||
|
||||
#include <CL/cl.h>
|
||||
#include <CL/cl_gl.h>
|
||||
#include <CL/cl_gl_ext.h>
|
||||
#include <CL/cl_ext.h>
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* __OPENCL_H */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user