Jocl structs alpha version

Hello,

I’ve been using the struct library with great success (actually, I’m enjoying it). I noticed that it has no implementation of certain opencl data types like float3. I haven’t looked at the source code yet, but I wanted to know whether they can be added trivially. :slight_smile:

Thank you,
Joe.

Hello

Interesting to hear that you are using it - I hope you noticed the disclaimer, stating that it was only a basic experiment :wink:

The float3 data type could probably be added without much effort. (The library was based on OpenCL 1.0, where cl_float3 did not yet exist). However, the cl_float3 datatype is mainly intended to increase readability, and does not offer a special functionality of other benefits. According to cl_platform.h:


/* cl_float3 is identical in size, alignment and behavior to cl_float4. See section 6.1.5. */
typedef  cl_float4  cl_float3;

However, maybe I’ll add it when I update the library.

And BTW: I’d really be interested in any feedback about this lib.

bye
Marco