Skip to main content

mediaframe/source/
yuv440p12.rs

1//! YUV 4:4:0 planar 12‑bit (`AV_PIX_FMT_YUV440P12LE`).
2//!
3//! Full-width × half-height chroma at 12 bits per sample. Reuses
4//! the const-generic `yuv_444p_n_to_rgb_*<12>` kernel family.
5
6use crate::frame::Yuv440pFrame16;
7
8walker! {
9  planar3_be {
10    /// Zero‑sized marker for the YUV 4:4:0 **12‑bit** source format.
11    #[derive(Debug, Clone, Copy, Default, PartialEq, Eq, Hash)]
12    marker: Yuv440p12,
13    frame: Yuv440pFrame16<'_, 12, BE>,
14    frame_le: Yuv440pFrame16<'_, 12, false>,
15    row: Yuv440p12Row,
16    sink: Yuv440p12Sink,
17    walker: yuv440p12_to,
18    walker_endian: yuv440p12_to_endian,
19    elem_type: u16,
20    chroma_h: full,
21    chroma_v: half,
22    row_doc: "One output row of a [`Yuv440p12`] source.",
23    walker_doc: "Walks a [`Yuv440p12Frame`](crate::frame::Yuv440p12Frame) row by row into the sink. Y row `r`\n\
24                 reads chroma row `r / 2` (half-height vertical subsampling).",
25  }
26}