Expand description
A RGBA colour represented as a float between 0 and 1
Fields
r: f32
Red
g: f32
Green
b: f32
Blue
a: f32
Alpha
Implementations
sourceimpl Rgba
impl Rgba
pub const TRANSPARENT: Rgba = Self::new(0.0, 0.0, 0.0, 0.0)
pub const BLUE: Rgba = Self::new(0.0, 0.0, 1.0, 1.0)
pub const GREEN: Rgba = Self::new(0.0, 1.0, 0.0, 1.0)
pub const RED: Rgba = Self::new(1.0, 0.0, 0.0, 1.0)
pub const WHITE: Rgba = Self::new(1.0, 1.0, 1.0, 1.0)
pub const BLACK: Rgba = Self::new(0.0, 0.0, 0.0, 1.0)
Trait Implementations
impl Copy for Rgba
impl StructuralPartialEq for Rgba
Auto Trait Implementations
impl RefUnwindSafe for Rgba
impl Send for Rgba
impl Sync for Rgba
impl Unpin for Rgba
impl UnwindSafe for Rgba
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more