Intel® oneAPI Data Parallel C++
Support for Intel® oneAPI DPC++ Compiler, Intel® oneAPI DPC++ Library, Intel® DPC++ Compatibility Tool, and GDB*
415 Discussions

Why can't use image accessor to read value of other types

shenuo
Employee
311 Views

 

I see the accessor.hpp (line 417)

static_assert(std::is_same<DataT, cl_int4>::value ||
std::is_same<DataT, cl_uint4>::value ||
std::is_same<DataT, cl_float4>::value ||
std::is_same<DataT, cl_half4>::value,
"The data type of an image accessor must be only cl_int4, "
"cl_uint4, cl_float4 or cl_half4 from SYCL namespace");

is that mean the data can only be these types?  if I want read a 1 channel image with pixel of 8 bit by using image accessor  ,

what should I do? 

Labels (1)
0 Kudos
2 Replies
NoorjahanSk_Intel
Moderator
258 Views

Hi,


Thanks for reaching out to us.


>>is that mean the data can only be these types?

As of now the supported data type for image accessors are 

int4 

uint4 

float4 

half4


>> if I want read a 1 channel image with pixel of 8 bit by using image accessor 

We will check with the concerned team and get back to you with an update.


Thanks & Regards,

Noorjahan.


NoorjahanSk_Intel
Moderator
234 Views

Hi,


We have reported this issue to the development team, they are looking into this issue


Thanks & Regards,

Noorjahan.


Reply