Hi again,
there is also a problem with write_imagef() function itself.
previously I posted a problem related to its compilation.
even if you get the code to compile, a run-time error occurs.
my aim is to write to an output texture and draw this as a full-screen quad in opengl.
if there is an early exit branch from the kernel
the write_imagef function does not work:
in fact nothing works and no output image is produced.
if( dataPos < 0 )
return;
write_imagef( OutputImage, (int2)(x,y), color );
just after lauching the code
I notice a very quick flicker and I get a blank image as output picture for every invocation of the kernel.
when I remove the early exit check, it seems to work fine:
what I cannot understand is, no such thing happens with the corresponding GLSL shader code.
what I first though of was the problem with threads having to follow the same execution path on the same core.
but then I think of the GLSL code which does not have this problem, although they work on the same hardware
is this an inherent limitation of opencl or a bug?
by the way:
I am using an nvidia GTX-295 (multi-gpu mode enabled)