Enum ColorMatrix
#[repr(u8)]pub enum ColorMatrix {
Show 13 variants
Identity = 0,
Bt709 = 1,
Bt470M = 2,
Bt470Bg = 3,
Smpte170M = 4,
Smpte240M = 5,
Ycgco = 6,
Bt2020Ncl = 7,
Bt2020Cl = 8,
Smpte2085 = 9,
ChromaticityDerivedNcl = 10,
ChromaticityDerivedCl = 11,
Ictcp = 12,
}Expand description
Official matrix coefficient metadata values.
Variants§
Identity = 0
Identity matrix coefficients.
Bt709 = 1
ITU-R BT.709 matrix coefficients.
Bt470M = 2
ITU-R BT.470 System M matrix coefficients.
Bt470Bg = 3
ITU-R BT.470 System B/G matrix coefficients.
Smpte170M = 4
SMPTE 170M matrix coefficients.
Smpte240M = 5
SMPTE 240M matrix coefficients.
Ycgco = 6
YCgCo matrix coefficients.
Bt2020Ncl = 7
ITU-R BT.2020 non-constant-luminance matrix coefficients.
Bt2020Cl = 8
ITU-R BT.2020 constant-luminance matrix coefficients.
Smpte2085 = 9
SMPTE ST 2085 matrix coefficients.
ChromaticityDerivedNcl = 10
Chromaticity-derived non-constant-luminance matrix coefficients.
ChromaticityDerivedCl = 11
Chromaticity-derived constant-luminance matrix coefficients.
Ictcp = 12
ICtCp matrix coefficients.
Implementations§
§impl ColorMatrix
impl ColorMatrix
pub fn parse(value: &str) -> Result<ColorMatrix, PixelFlowError>
pub fn parse(value: &str) -> Result<ColorMatrix, PixelFlowError>
Parses canonical matrix metadata string.
pub const fn luma_coefficients(self) -> (f32, f32, f32)
pub const fn luma_coefficients(self) -> (f32, f32, f32)
Returns (Kr, Kg, Kb) luma coefficients for matrix families.
Trait Implementations§
§impl Clone for ColorMatrix
impl Clone for ColorMatrix
§fn clone(&self) -> ColorMatrix
fn clone(&self) -> ColorMatrix
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read more§impl Debug for ColorMatrix
impl Debug for ColorMatrix
§impl PartialEq for ColorMatrix
impl PartialEq for ColorMatrix
impl Copy for ColorMatrix
impl Eq for ColorMatrix
impl StructuralPartialEq for ColorMatrix
Auto Trait Implementations§
impl Freeze for ColorMatrix
impl RefUnwindSafe for ColorMatrix
impl Send for ColorMatrix
impl Sync for ColorMatrix
impl Unpin for ColorMatrix
impl UnsafeUnpin for ColorMatrix
impl UnwindSafe for ColorMatrix
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