[Beignet] [PATCH] runtime: The depth should be 1 for CL_MEM_OBJECT_IMAGE2D in beignet's implementation.

Chuanbo Weng chuanbo.weng at intel.com
Tue Jun 7 03:03:43 UTC 2016


Reported by Feng Yuan.

Signed-off-by: Chuanbo Weng <chuanbo.weng at intel.com>
---
 src/cl_mem.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/cl_mem.c b/src/cl_mem.c
index 229bc0a..79cd41d 100644
--- a/src/cl_mem.c
+++ b/src/cl_mem.c
@@ -2194,7 +2194,7 @@ LOCAL cl_mem cl_mem_new_libva_image(cl_context ctx,
   image->w = width;
   image->h = height;
   image->image_type = CL_MEM_OBJECT_IMAGE2D;
-  image->depth = 2;
+  image->depth = 1;
   image->fmt = fmt;
   image->intel_fmt = intel_fmt;
   image->bpp = bpp;
@@ -2292,7 +2292,7 @@ LOCAL cl_mem cl_mem_new_image_from_fd(cl_context ctx,
   image->w = width;
   image->h = height;
   image->image_type = CL_MEM_OBJECT_IMAGE2D;
-  image->depth = 0;
+  image->depth = 1;
   image->fmt = fmt;
   image->intel_fmt = intel_fmt;
   image->bpp = bpp;
-- 
1.9.1



More information about the Beignet mailing list