pub struct RGB<T>where
T: Channel,{
pub red: T,
pub green: T,
pub blue: T,
}Expand description
Represents a color as red, green and blue channels with no transparency
Fields§
§red: T§green: T§blue: TImplementations§
Source§impl<T> RGB<T>where
T: Channel,
impl<T> RGB<T>where
T: Channel,
Trait Implementations§
Source§impl<T> From<PrimaryColor> for RGB<T>where
T: Channel,
impl<T> From<PrimaryColor> for RGB<T>where
T: Channel,
Source§fn from(color: PrimaryColor) -> RGB<T>
fn from(color: PrimaryColor) -> RGB<T>
Converts to this type from the input type.
impl<T> Copy for RGB<T>where
T: Copy + Channel,
impl<T> Eq for RGB<T>where
T: Eq + Channel,
impl<T> StructuralPartialEq for RGB<T>where
T: Channel,
Auto Trait Implementations§
impl<T> Freeze for RGB<T>where
T: Freeze,
impl<T> RefUnwindSafe for RGB<T>where
T: RefUnwindSafe,
impl<T> Send for RGB<T>where
T: Send,
impl<T> Sync for RGB<T>where
T: Sync,
impl<T> Unpin for RGB<T>where
T: Unpin,
impl<T> UnwindSafe for RGB<T>where
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more