Adds random noise to an image.
theImage - image object
colorize - true or false. Either creates gray or colour noise
theBlend - the level of blending to do. Value between 0-255
theInk - can apply an ink to the overlaying of the noise.
on Noise (theImage, colorize, theBlend, theInk)
theWidth = theImage.width - 1
theHeight = theImage.height - 1
anImage = theImage.duplicate()
if colorize then
newImage = image(anImage.width, anImage.height, 8)
newImage = image(anImage.width, anImage.height, 8, #grayscale)
repeat with y1 = 0 to theHeight
repeat with x1 = 0 to theWidth
rnd = random(255)