Templates support

Hello,
I am a CUDA/C++ developer and I miss templates support in OpenCL badly, especially the thrust library. If there were a similar library in OpenCL, I would certainly switch to OpenCL in my projects.

Hi,

Do you happen to work with Visual Studio environment? There’s a way to template things in generic way in that environment; for any language that is, including OpenCL.

Kalle

Please post a sample!

Sorry to dig up an old thread but I just stumbled upon it via google.

I’ve been working on a C++ STL-like library for OpenCL called Boost.Compute. It provides some standard containers (vector<T>, array<T, N>) along with standard algorithms (sort(), transform(), accumulate()).

Source Code: https://github.com/kylelutz/compute
Documentation: http://kylelutz.github.io/compute

Hopefully you (or others) will find this useful.

Cheers,
Kyle

Posting to an old thread will most likely not get much notice. Please post a new thread with your information. Thanks.