#[repr(C)]pub struct LCh {
pub l: f32,
pub c: f32,
pub h: f32,
}
Expand description
Representing a color in cylindrical CIE LCh(uv) color space
Fields§
§l: f32
The L* value (achromatic luminance) of the colour in 0–100 range.
This is the same value as in the Luv
object.
c: f32
The C*_uv value (chroma) of the colour.
Together with h_uv, it defines chromaticity of the colour. The typical values of the coordinate go from zero up to around 150 (but exact range for ‘valid’ colours depends on luminance and hue). Zero represents shade of grey.
h: f32
The h_uv value (hue) of the colour measured in radians.
Together with C*_uv, it defines chromaticity of the colour. The value represents an angle thus it wraps around τ. Typically, the value will be in the -π–π range. The value is undefined if C*_uv is zero.
Implementations§
Trait Implementations§
Source§impl AddAssign<f32> for LCh
impl AddAssign<f32> for LCh
Source§fn add_assign(&mut self, rhs: f32)
fn add_assign(&mut self, rhs: f32)
Performs the
+=
operation. Read moreSource§impl AddAssign for LCh
impl AddAssign for LCh
Source§fn add_assign(&mut self, rhs: LCh)
fn add_assign(&mut self, rhs: LCh)
Performs the
+=
operation. Read moreSource§impl DivAssign<f32> for LCh
impl DivAssign<f32> for LCh
Source§fn div_assign(&mut self, rhs: f32)
fn div_assign(&mut self, rhs: f32)
Performs the
/=
operation. Read moreSource§impl DivAssign for LCh
impl DivAssign for LCh
Source§fn div_assign(&mut self, rhs: LCh)
fn div_assign(&mut self, rhs: LCh)
Performs the
/=
operation. Read moreSource§impl MulAssign<f32> for LCh
impl MulAssign<f32> for LCh
Source§fn mul_assign(&mut self, rhs: f32)
fn mul_assign(&mut self, rhs: f32)
Performs the
*=
operation. Read moreSource§impl MulAssign for LCh
impl MulAssign for LCh
Source§fn mul_assign(&mut self, rhs: LCh)
fn mul_assign(&mut self, rhs: LCh)
Performs the
*=
operation. Read moreSource§impl PartialEq for LCh
impl PartialEq for LCh
Source§impl PartialOrd for LCh
impl PartialOrd for LCh
Source§impl SubAssign<f32> for LCh
impl SubAssign<f32> for LCh
Source§fn sub_assign(&mut self, rhs: f32)
fn sub_assign(&mut self, rhs: f32)
Performs the
-=
operation. Read moreSource§impl SubAssign for LCh
impl SubAssign for LCh
Source§fn sub_assign(&mut self, rhs: LCh)
fn sub_assign(&mut self, rhs: LCh)
Performs the
-=
operation. Read moreimpl Copy for LCh
Auto Trait Implementations§
impl Freeze for LCh
impl RefUnwindSafe for LCh
impl Send for LCh
impl Sync for LCh
impl Unpin for LCh
impl UnwindSafe for LCh
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