pub struct Dlch {
pub l: f64,
pub c: f64,
pub h: f64,
pub alpha: Option<f64>,
}Expand description
DIN99o LCh. l is in 0..100, c is non-negative, h is in degrees.
Fields§
§l: f64Lightness in 0..100.
c: f64Chroma.
h: f64Hue in degrees.
alpha: Option<f64>Optional alpha in 0..1.
Trait Implementations§
Source§impl ColorSpace for Dlch
impl ColorSpace for Dlch
Source§const MODE: &'static str = "dlch"
const MODE: &'static str = "dlch"
Stable identifier for this space (matches culori’s
mode string).Source§const CHANNELS: &'static [&'static str]
const CHANNELS: &'static [&'static str]
The space’s natural channels in canonical order. Alpha is excluded:
it is a universal meta-channel accessed via
alpha
rather than a channel of any particular space.Source§fn with_alpha(self, alpha: Option<f64>) -> Self
fn with_alpha(self, alpha: Option<f64>) -> Self
Returns a copy of
self with the given alpha.Source§fn from_xyz65(xyz: Xyz65) -> Self
fn from_xyz65(xyz: Xyz65) -> Self
Construct a color of this space from the XYZ D65 hub space.
Source§impl From<Rgb> for Dlch
Direct Rgb → Dlch matching culori’s achromatic-RGB snap. See the
From<Rgb> for Dlab doc for why the snap is necessary.
impl From<Rgb> for Dlch
Direct Rgb → Dlch matching culori’s achromatic-RGB snap. See the
From<Rgb> for Dlab doc for why the snap is necessary.
impl Copy for Dlch
impl StructuralPartialEq for Dlch
Auto Trait Implementations§
impl Freeze for Dlch
impl RefUnwindSafe for Dlch
impl Send for Dlch
impl Sync for Dlch
impl Unpin for Dlch
impl UnsafeUnpin for Dlch
impl UnwindSafe for Dlch
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