diff options
author | Lu Guanqun <guanqun.lu@intel.com> | 2013-10-17 13:11:05 +0800 |
---|---|---|
committer | Zhigang Gong <zhigang.gong@intel.com> | 2013-10-18 12:17:56 +0800 |
commit | b810dff34f4ddd87e41172a71148eb82f1fc2e6c (patch) | |
tree | 38b9f78ff83c85c5327a37bda1626f6150c9b20f /include/CL | |
parent | b65be48cbd96334c097ddf4afeee70539e7c5e6b (diff) | |
download | beignet-b810dff34f4ddd87e41172a71148eb82f1fc2e6c.tar.gz |
add clCreateImageFromLibvaIntel() api
We can pass in libva's buffer object with other info and then create an image
in our CL code.
Signed-off-by: Lu Guanqun <guanqun.lu@intel.com>
Reviewed-by: Zhigang Gong <zhigang.gong@linux.intel.com>
Diffstat (limited to 'include/CL')
-rw-r--r-- | include/CL/cl_intel.h | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/include/CL/cl_intel.h b/include/CL/cl_intel.h index d0cb492e..3fd73da7 100644 --- a/include/CL/cl_intel.h +++ b/include/CL/cl_intel.h @@ -101,6 +101,27 @@ typedef CL_API_ENTRY cl_mem (CL_API_CALL *clCreateBufferFromLibvaIntel_fn)( unsigned int /* bo_name */, cl_int * /* errcode_ret */); +/* Create image from libva's buffer object */ +typedef struct _cl_libva_image { + unsigned int bo_name; + uint32_t offset; + uint32_t width; + uint32_t height; + cl_image_format fmt; + uint32_t row_pitch; + uint32_t reserved[8]; +} cl_libva_image; + +extern CL_API_ENTRY cl_mem CL_API_CALL +clCreateImageFromLibvaIntel(cl_context /* context */, + const cl_libva_image * /* info */, + cl_int * /* errcode_ret */); + +typedef CL_API_ENTRY cl_mem (CL_API_CALL *clCreateImageFromLibvaIntel_fn)( + cl_context /* context */, + const cl_libva_image * /* info */, + cl_int * /* errcode_ret */); + #ifdef __cplusplus } #endif |