pub type Rgba<S = Srgb, T = f32> = Alpha<Rgb<S, T>, T>;Expand description
Generic RGB with an alpha component. See the Rgba implementation in
Alpha.
Aliased Type§
#[repr(C)]pub struct Rgba<S = Srgb, T = f32> {
pub color: Rgb<S, T>,
pub alpha: T,
}Fields§
§color: Rgb<S, T>The color.
alpha: TThe transparency component. 0.0 (or 0u8) is fully transparent and 1.0 (or 255u8) is fully opaque.
Trait Implementations§
Source§impl ColorExt for Rgba
impl ColorExt for Rgba
Source§impl Interpolate for Rgba
impl Interpolate for Rgba
Source§fn interpolate(from: Self, to: Self, phase: f32) -> Self
fn interpolate(from: Self, to: Self, phase: f32) -> Self
Source§impl RasterColorExt for Rgba
impl RasterColorExt for Rgba
Source§fn quantize_raster_color(self) -> Rgba8
fn quantize_raster_color(self) -> Rgba8
Clamps and rounds each channel to the nearest byte.