#[non_exhaustive]#[repr(u8)]pub enum YuvMatrix {
Identity = 0,
Bt601 = 1,
Bt709 = 2,
Bt2020 = 3,
}Expand description
YCbCr matrix coefficients for luma/chroma conversion.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Identity = 0
Identity / not applicable (RGB, Gray, Oklab, etc.).
Bt601 = 1
BT.601: Y = 0.299R + 0.587G + 0.114B (JPEG, WebP, SD video).
Bt709 = 2
BT.709: Y = 0.2126R + 0.7152G + 0.0722B (AVIF, HEIC, HD video).
Bt2020 = 3
BT.2020: Y = 0.2627R + 0.6780G + 0.0593B (4K/8K HDR).
Implementations§
Trait Implementations§
impl Copy for YuvMatrix
impl Eq for YuvMatrix
impl StructuralPartialEq for YuvMatrix
Auto Trait Implementations§
impl Freeze for YuvMatrix
impl RefUnwindSafe for YuvMatrix
impl Send for YuvMatrix
impl Sync for YuvMatrix
impl Unpin for YuvMatrix
impl UnsafeUnpin for YuvMatrix
impl UnwindSafe for YuvMatrix
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