noise
Returns a pixmap with pixels randomly set to a given colour.
Syntax
-
noise(pm[, p[, c]])
-
pm
is a pixmap -
p
is a real number in [0, 1] -
c
is a colour
-
Description
noise(pm, p, c)
returns pm
with each pixel set to colour c
with probability p
. If omitted, p
defaults to .5
and c
to white.
Examples
noise(ExampleData("harvestman"), .2, "green")