User Guide

GNU Image Manipulation Program
113 / 653
Figure 8.20: Example for layer mode ‘Difference’
(a) Mask 1 is used as upper layer with 100% opac-
ity.
(b) Mask 2 is used as upper layer with 100% opac-
ity.
Difference mode subtracts the pixel value of the upper layer from that of the lower layer and then takes the absolute value
of the result. No matter what the original two layers look like, the result looks rather odd. You can use it to invert elements
of an image.
The equation is:
E = |I M|
EQUATION 8.15: Equation for layer mode Difference
The mode is commutative; the order of the two layers doesn’t matter.
Addition
Figure 8.21: Example for layer mode ‘Addition’
(a) Mask 1 is used as upper layer with 100% opac-
ity.
(b) Mask 2 is used as upper layer with 100% opac-
ity.
Addition mode is very simple. The pixel values of the upper and lower layers are added to each other. The resulting image
is usually lighter. The equation can result in color values greater than 255, so some of the light colors may be set to the
maximum value of 255.