1
Fork 0
This repository has been archived on 2025-04-09. You can view files and clone it, but cannot push or open issues or pull requests.
opencl-experiment/Kernel.cl

8 lines
313 B
Common Lisp

kernel void square(global float* input, size_t width, global float* output){
size_t x = get_global_id(0);
size_t y = get_global_id(1);
float i = 2.0 * (input[x + width*y] - 0.5);
output[x + width*y] = 0.5 + 0.5*sin((1.0 - i) * sin(i*i + 6.2*float(x)/width) + cos(1.0/i + 6.2*float(y)/width));
}