pub struct YuvEncoding {
pub color: ColorMetadata,
pub chroma: ChromaLocation,
}Expand description
How rendered RGB is written as 8-bit 4:2:0 YUV: its color coding, and where its chroma samples sit relative to the luma grid.
Fields§
§color: ColorMetadataMatrix, range, and the tags the output carries.
chroma: ChromaLocationWhere each chroma sample sits, so the pack filters for that point.
Implementations§
Source§impl YuvEncoding
impl YuvEncoding
Sourcepub const fn new(color: ColorMetadata, chroma: ChromaLocation) -> Self
pub const fn new(color: ColorMetadata, chroma: ChromaLocation) -> Self
color with chroma sited at chroma.
Sourcepub const fn export(codec: VideoCodec) -> Self
pub const fn export(codec: VideoCodec) -> Self
What an export to codec writes: ColorMetadata::EXPORT, with the
chroma where the codec implies it (crate::VideoCodec::chroma_location).
Trait Implementations§
Source§impl Clone for YuvEncoding
impl Clone for YuvEncoding
impl Copy for YuvEncoding
Source§impl Debug for YuvEncoding
impl Debug for YuvEncoding
impl Eq for YuvEncoding
Source§impl PartialEq for YuvEncoding
impl PartialEq for YuvEncoding
impl StructuralPartialEq for YuvEncoding
Auto Trait Implementations§
impl Freeze for YuvEncoding
impl RefUnwindSafe for YuvEncoding
impl Send for YuvEncoding
impl Sync for YuvEncoding
impl Unpin for YuvEncoding
impl UnsafeUnpin for YuvEncoding
impl UnwindSafe for YuvEncoding
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