Vulcan #7
Here the pixel value is the distance from the corner.
var a = frac(x);
var b = frac(y);
pixel.value =Math.Sqrt(a*a + b*b);
The following is a continuation of the scripting language from the previous post Vulcan #6.
The scripting is used to modify an image. In these examples, I am simply writing a value to a pixel location. The typical use would assume that something already exists on the canvas and the script is modifying the current state. There is also a "mask" property that limits the modification to different areas of the canvas. I won't go into those details. This point is just setting a value is the simplest operation.
So imagine painting with math as something like this: I have a partially complete image on my (virtual) canvas. I write a script (or better grab an existing one from a toolkit), set a mask, colors and combining rule, And the apply it to the canvas.
That was my goal when I wrote the program. It is not as smooth as the above description suggests, but it is getting there.