[]Struct geng::prelude::Color

#[repr(C)]pub struct Color<T> {
    pub r: T,
    pub g: T,
    pub b: T,
    pub a: T,
}

Fields

r: Tg: Tb: Ta: T

Implementations

impl<T> Color<T> where
    T: ColorComponent

pub const WHITE: Color<T>

pub const BLACK: Color<T>

pub const GRAY: Color<T>

pub const TRANSPARENT_WHITE: Color<T>

pub const TRANSPARENT_BLACK: Color<T>

pub const RED: Color<T>

pub const GREEN: Color<T>

pub const BLUE: Color<T>

pub const CYAN: Color<T>

pub const MAGENTA: Color<T>

pub const YELLOW: Color<T>

impl<T> Color<T> where
    T: ColorComponent

pub fn rgb(r: T, g: T, b: T) -> Color<T>

pub fn rgba(r: T, g: T, b: T, a: T) -> Color<T>

pub fn convert<U>(self) -> Color<U> where
    U: ColorComponent

Trait Implementations

impl<T> ApproxEq for Color<T> where
    T: ApproxEq + ColorComponent

impl AsUniform for Color<f32>

type Uniform = [f32; 4]

impl<T> Clone for Color<T> where
    T: Clone

impl<T> Copy for Color<T> where
    T: Copy

impl<T> Debug for Color<T> where
    T: Debug

impl<T> Deref for Color<T> where
    T: ColorComponent

type Target = [T; 4]

The resulting type after dereferencing.

impl<T> DerefMut for Color<T> where
    T: ColorComponent

impl<'de, T> Deserialize<'de> for Color<T> where
    T: Deserialize<'de>, 

impl<T> Display for Color<T> where
    T: ColorComponent

impl<T> Eq for Color<T> where
    T: ColorComponent + Eq

impl<T> PartialEq<Color<T>> for Color<T> where
    T: ColorComponent + Eq

impl RenderbufferPixel for Color<f32>

impl<T> Schematic for Color<T> where
    T: Schematic + 'static, 

impl<T> Serialize for Color<T> where
    T: Serialize

impl TexturePixel for Color<f32>

impl<T> Trans for Color<T> where
    T: Trans

impl VertexAttribute for Color<f32>

Auto Trait Implementations

impl<T> RefUnwindSafe for Color<T> where
    T: RefUnwindSafe

impl<T> Send for Color<T> where
    T: Send

impl<T> Sync for Color<T> where
    T: Sync

impl<T> Unpin for Color<T> where
    T: Unpin

impl<T> UnwindSafe for Color<T> where
    T: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> ApproxEq for T where
    T: Float

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Configurable for T where
    T: Clone + ToString
[src]

type Config = ShowValue<T>

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> Diff for T where
    T: 'static + PartialEq<T> + Send + Copy + Sync + for<'de> Deserialize<'de> + Serialize + Trans

type Delta = T

impl<T> DynClone for T where
    T: Clone
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Message for T where
    T: 'static + Send + Debug + for<'de> Deserialize<'de> + Serialize
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> SetParameter for T

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Uniform for T where
    T: AsUniform

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,