Type Alias nannou::prelude::Rgba

source ·
pub type Rgba<S = f32> = Alpha<Rgb<Srgb, S>, S>;
Expand description

The same as Rgb, but with an alpha value representing opacity.

This type is an alias for the Srgba type, a type that represents the sRGB color space alongside an alpha value.

If you are looking for more advanced control over the RGB space and component type, please see the palette crate’s generic Rgb type.

Aliased Type§

struct Rgba<S = f32> {
    pub color: Rgb<Srgb, S>,
    pub alpha: S,
}

Fields§

§color: Rgb<Srgb, S>

The color.

§alpha: S

The transparency component. 0.0 is fully transparent and 1.0 is fully opaque.