Is there a way to program I OpenCL without 3rd party plugins? C#

Viewed 82

I realise the question of how to run C# on the GPU is a common question but my question is a bit different. Is there a way to do it without 3rd party frameworks (such as Cudafy). I don't want to use plugins because I'm making a program which I intend to be 100% my own code (personal ambition) and in feel I won't learn as much if I do.

Would I simply need to create a kernel and compile it and call it from c# (process.start()) or is there a better way of doing it.

How do I go about making a kernel? I am beginner with GPGPU so sorry for my ignorance. However, I am a very advanced c# programmer.

1 Answers

After a long time, I have finally come up with a solution to my issue. I created bindings to the (unmanaged) OpenCL.dll. It then uses some tricks to be able to run the code on the GPU by using an attribute. The best way I can describe it is like Cudafy, but it is quite different.

Thanks to those who replied to my question.

Related