#[repr(C)]
pub struct DisplayP3<ComponentTy> {
pub r: ComponentTy,
pub g: ComponentTy,
pub b: ComponentTy,
}
Expand description
A color in the Display P3 (aka P3 D65) color space.
This color space uses the P3 primaries and D65 white point
and sRGB transfer functions. This version is linear,
without the sRGB OETF applied.
fn as_ref(&self) -> &[ComponentTy; 3]
Performs copy-assignment from source
. Read more
Formats the value using the given formatter. Read more
impl<ComponentTy> From<[ComponentTy; 3]> for DisplayP3<ComponentTy>
impl<ComponentTy> Into<[ComponentTy; 3]> for DisplayP3<ComponentTy>
fn into(self) -> [ComponentTy; 3]
fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
fn clamp(self, min: Self, max: Self) -> Self
Restrict a value to a certain interval. Read more
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl<T> Any for T where
T: 'static + ?Sized,
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
impl<T, U> Into<U> for T where
U: From<T>,
The type returned in the event of a conversion error.
The type returned in the event of a conversion error.