Module gfx::preset::blend[][src]

Blending preset modes.

Constants

ADD

When combining two fragments, add their values together, saturating at 1.0

ALPHA

When combining two fragments, add the value of the source times its alpha channel with the value of the destination multiplied by the inverse of the source alpha channel. Has the usual transparency effect: mixes the two colors using a fraction of each one specified by the alpha of the source.

INVERT

When combining two fragments, subtract the destination color from a constant color using the source color as weight. Has an invert effect with the constant color as base and source color controlling displacement from the base color. A white source color and a white value results in plain invert. The output alpha is same as destination alpha.

MULTIPLY

When combining two fragments, multiply their values together.

REPLACE

When combining two fragments, choose the source value