Trait softrender::pixel::Pixel [] [src]

pub trait Pixel: Clone + Copy + Send + Sync {
    fn empty() -> Self;
    fn with_alpha(self, alpha: f32) -> Self;
    fn mul_alpha(self, alpha: f32) -> Self;
}

Trait required to distinguish pixel type for use in the framebuffer and fragment shader

Required Methods

An empty pixel in which values can be accumulated into

Copy the pixel, but with the given alpha channel value

Copy the pixel, but multiply the alpha channel with the given value

Implementors