InvertColor
Returns a colour or pixmap inverted.
Syntax
-
InvertColor(c)
-
c
is a colour
-
-
InvertColor(pm)
-
pm
is a pixmap
-
Description
If c
is a colour, then InvertColor(c)
returns the inverted colour of c
. This is obtained by taking the complement of each RGB channel, that is,
InvertColor(rgb(r, g, b)) = rgb(1 − r, 1 − g, 1 − b).
If pm
is a pixmap, then InvertColor(pm)
returns pm
with every pixel inverted as described above.
Examples
InvertColor(ExampleData("Sally"))