Color

Trait Color 

Source
pub trait Color {
    // Required methods
    fn rgb(&self) -> (u8, u8, u8);
    fn alpha(&self) -> f64;
}
Expand description

Any color representation

Required Methods§

Source

fn rgb(&self) -> (u8, u8, u8)

Convert the RGB representation to the standard RGB tuple

Source

fn alpha(&self) -> f64

Get the alpha channel of the color

Trait Implementations§

Source§

impl Color for Box<&dyn Color>

Source§

fn rgb(&self) -> (u8, u8, u8)

Convert the RGB representation to the standard RGB tuple
Source§

fn alpha(&self) -> f64

Get the alpha channel of the color

Implementations on Foreign Types§

Source§

impl Color for Box<&dyn Color>

Source§

fn rgb(&self) -> (u8, u8, u8)

Source§

fn alpha(&self) -> f64

Implementors§