This looks cool. I can't understand some of the code, though. It seems very confused.
x = (grid_size-(abs(grid_w-2*ix))*grid_size/grid_w);
y = (grid_size-(abs(grid_h-2*iy))*grid_size/grid_h);
float sc =map((x+y), 0, 2*grid_size, 0.1, 1);
scale(sc*2);
elementMalen(x, y);
It looks overly complicated, which usually means it is! If the width is, say, 900 pixels, then the x values go (approximately) from 0 to 45 and back to 0. In elementMalen(), the w and h values are actually used for the stroke colour, not positioning, and the idea is (or seems to be) to reduce the red/green values away from the centre.
Consider:
a = 1 - abs( map(ix, 0, grid_w, -1, 1) ); // values 0 to 1 to 0 again
b = 1 - abs( map(iy, 0, grid_h, -1, 1) ); // values 0 to 1 to 0 again
scale(a + b);
x = (grid_size-(abs(grid_w-2*ix))*grid_size/grid_w);
y = (grid_size-(abs(grid_h-2*iy))*grid_size/grid_h);
float sc =map((x+y), 0, 2*grid_size, 0.1, 1);
scale(sc*2);
elementMalen(x, y);
It looks overly complicated, which usually means it is! If the width is, say, 900 pixels, then the x values go (approximately) from 0 to 45 and back to 0. In elementMalen(), the w and h values are actually used for the stroke colour, not positioning, and the idea is (or seems to be) to reduce the red/green values away from the centre.
Consider:
a = 1 - abs( map(ix, 0, grid_w, -1, 1) ); // values 0 to 1 to 0 again
b = 1 - abs( map(iy, 0, grid_h, -1, 1) ); // values 0 to 1 to 0 again
scale(a + b);
fullscreen
