Fields
r: T
g: T
b: T
Implementations
sourceimpl<T: Channel, S: TransferFunction> Rgb<T, S>
impl<T: Channel, S: TransferFunction> Rgb<T, S>
pub fn from_hex(hex: u32) -> Rgb<T, S>
pub fn rg(&self) -> Rg<T, S>
pub fn rb(&self) -> Rg<T, S>
pub fn gr(&self) -> Rg<T, S>
pub fn gb(&self) -> Rg<T, S>
pub fn br(&self) -> Rg<T, S>
pub fn bg(&self) -> Rg<T, S>
pub fn rgb(&self) -> Rgb<T, S>
pub fn rbg(&self) -> Rgb<T, S>
pub fn bgr(&self) -> Rgb<T, S>
pub fn brg(&self) -> Rgb<T, S>
pub fn grb(&self) -> Rgb<T, S>
pub fn gbr(&self) -> Rgb<T, S>
sourceimpl<T: Channel, S: TransferFunction> Rgb<T, S>
impl<T: Channel, S: TransferFunction> Rgb<T, S>
pub fn to_standard<S2: TransferFunction>(&self) -> Rgb<T, S2>
pub fn to_linear(&self) -> Rgb<T, LinearRgb>
sourceimpl Rgb<f32>
impl Rgb<f32>
pub fn gamut_clip_preserve_chroma(&self) -> Rgb<f32>
pub fn gamut_clip_project_to_0_5(&self) -> Rgb<f32>
pub fn gamut_clip_project_to_l_cusp(&self) -> Rgb<f32>
pub fn gamut_clip_adaptive_l0_0_5(&self) -> Rgb<f32>
pub fn gamut_clip_adaptive_l0_0_5_alpha(&self, alpha: f32) -> Rgb<f32>
pub fn gamut_clip_adaptive_l0_l_cusp(&self) -> Rgb<f32>
pub fn gamut_clip_adaptive_l0_l_cusp_alpha(&self, alpha: f32) -> Rgb<f32>
Trait Implementations
sourceimpl<T, S> BorrowMut<[T; 3]> for Rgb<T, S>
impl<T, S> BorrowMut<[T; 3]> for Rgb<T, S>
sourcefn borrow_mut(&mut self) -> &mut [T; 3]
fn borrow_mut(&mut self) -> &mut [T; 3]
Mutably borrows from an owned value. Read more
sourceimpl<T: Channel, S> Color<T> for Rgb<T, S>
impl<T: Channel, S> Color<T> for Rgb<T, S>
sourceimpl<'de, T, S> Deserialize<'de> for Rgb<T, S> where
T: Deserialize<'de>,
impl<'de, T, S> Deserialize<'de> for Rgb<T, S> where
T: Deserialize<'de>,
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl<T: FloatChannel, S> FloatColor<T> for Rgb<T, S>
impl<T: FloatChannel, S> FloatColor<T> for Rgb<T, S>
sourceimpl<T: Channel + Saturating, S> Saturating for Rgb<T, S>
impl<T: Channel + Saturating, S> Saturating for Rgb<T, S>
sourcefn saturating_add(self, v: Rgb<T, S>) -> Rgb<T, S>
fn saturating_add(self, v: Rgb<T, S>) -> Rgb<T, S>
Saturating addition operator. Returns a+b, saturating at the numeric bounds instead of overflowing. Read more
sourcefn saturating_sub(self, v: Rgb<T, S>) -> Rgb<T, S>
fn saturating_sub(self, v: Rgb<T, S>) -> Rgb<T, S>
Saturating subtraction operator. Returns a-b, saturating at the numeric bounds instead of overflowing. Read more
sourceimpl<T: Channel, S: TransferFunction> ToHsv for Rgb<T, S>
impl<T: Channel, S: TransferFunction> ToHsv for Rgb<T, S>
sourceimpl<T: Channel, S: TransferFunction> ToLuma for Rgb<T, S>
impl<T: Channel, S: TransferFunction> ToLuma for Rgb<T, S>
sourceimpl<T: Channel + Float + NumCast, S: MatrixColorSpace + TransferFunction> ToOkLab for Rgb<T, S>
impl<T: Channel + Float + NumCast, S: MatrixColorSpace + TransferFunction> ToOkLab for Rgb<T, S>
sourceimpl<T: Channel, S: TransferFunction> ToRgb for Rgb<T, S>
impl<T: Channel, S: TransferFunction> ToRgb for Rgb<T, S>
sourceimpl<T: Channel, S: TransferFunction> ToRgba for Rgb<T, S>
impl<T: Channel, S: TransferFunction> ToRgba for Rgb<T, S>
sourceimpl<T: Channel, S: MatrixColorSpace + TransferFunction> ToXyz for Rgb<T, S>
impl<T: Channel, S: MatrixColorSpace + TransferFunction> ToXyz for Rgb<T, S>
impl<T: Copy, S> Copy for Rgb<T, S>
impl<N: Clone + PartialEq + Eq + Num + NumCast, S> Eq for Rgb<N, S>
Auto Trait Implementations
impl<T, S> RefUnwindSafe for Rgb<T, S> where
S: RefUnwindSafe,
T: RefUnwindSafe,
impl<T, S> Send for Rgb<T, S> where
S: Send,
T: Send,
impl<T, S> Sync for Rgb<T, S> where
S: Sync,
T: Sync,
impl<T, S> Unpin for Rgb<T, S> where
S: Unpin,
T: Unpin,
impl<T, S> UnwindSafe for Rgb<T, S> where
S: UnwindSafe,
T: UnwindSafe,
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
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more