Reputation: 1344
I've just started learning OpenCL with the following tutorial: http://simpleopencl.blogspot.hu/2013/06/tutorial-simple-start-with-opencl-and-c.html
I have a problem with the following code:
cl::Device defaultDevice = allDevices[0];
cl::Context context({defaultDevice});
The compiler says:
I think the compiler cannot choose between the 2nd and 3rd candidate, but I don't know how to force the compiler to choose the 2nd one.
I use Qt Creator on Windows 7 and AMD SDK.
Upvotes: 2
Views: 348
Reputation: 8036
Don't use the braces. Just:
cl::Device defaultDevice = allDevices[0];
cl::Context context(defaultDevice);
Upvotes: 2