Enum ggez::graphics::BlendMode [] [src]

pub enum BlendMode {
    Add,
    Subtract,
    Alpha,
    Invert,
    Multiply,
    Replace,
    Lighten,
    Darken,
}

An enum for specifying default and custom blend modes

Variants

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

When combining two fragments, subtract the source value from the destination value

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.

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.

When combining two fragments, multiply their values together.

When combining two fragments, choose the source value

When combining two fragments, choose the lighter value

When combining two fragments, choose the darker value

Trait Implementations

impl Clone for BlendMode
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl Copy for BlendMode
[src]

impl Debug for BlendMode
[src]

[src]

Formats the value using the given formatter.

impl PartialEq for BlendMode
[src]

[src]

This method tests for self and other values to be equal, and is used by ==. Read more

1.0.0
[src]

This method tests for !=.

impl Eq for BlendMode
[src]

impl Hash for BlendMode
[src]

[src]

Feeds this value into the given [Hasher]. Read more

1.3.0
[src]

Feeds a slice of this type into the given [Hasher]. Read more