diff options
author | David Phillips <david@sighup.nz> | 2017-02-12 20:31:13 +1300 |
---|---|---|
committer | David Phillips <david@sighup.nz> | 2017-02-12 20:31:13 +1300 |
commit | c19cffcae57ff68d99eaa38f6d0547942dce5eca (patch) | |
tree | d549d1bc78a6b1481ff3ce9ee6c8e2a97c785f21 /test.cl | |
parent | c8dc778d855b05a057e8d340b06900ba738811df (diff) | |
download | fractal-gen-opencl-c19cffcae57ff68d99eaa38f6d0547942dce5eca.tar.xz |
Remove more hardcoded crap
Diffstat (limited to 'test.cl')
-rw-r--r-- | test.cl | 5 |
1 files changed, 2 insertions, 3 deletions
@@ -11,8 +11,7 @@ __kernel void fractal_gen( float b = -1.75+(((float)y)/(float)size)*3.5; float2 z = (0.0, 0.0); - - + for (i = 0; i < iterations; i++) { // if abs(z) > 2 if (z.x*z.x + z.y*z.y > 4) @@ -22,5 +21,5 @@ __kernel void fractal_gen( z.x = z.x*z.x - z.y*z.y + a; z.y = 2*oldx*z.y + b; } - buffer[x+size*y] = (i*255)/iterations; + buffer[(size*y)+x] = (i*255)/iterations; } |