Create a new Frame (crate-internal constructor). 创建新的 Frame(crate 内部构造函数)。
(
data: &'a [u8],
width: u32,
height: u32,
pixel_format: PixelFormat,
sequence: u64,
timestamp_us: u64,
)
| 86 | /// Create a new Frame (crate-internal constructor). |
| 87 | /// 创建新的 Frame(crate 内部构造函数)。 |
| 88 | pub(crate) fn new( |
| 89 | data: &'a [u8], |
| 90 | width: u32, |
| 91 | height: u32, |
| 92 | pixel_format: PixelFormat, |
| 93 | sequence: u64, |
| 94 | timestamp_us: u64, |
| 95 | ) -> Self { |
| 96 | Self { |
| 97 | data, |
| 98 | width, |
| 99 | height, |
| 100 | pixel_format, |
| 101 | sequence, |
| 102 | timestamp_us, |
| 103 | _marker: PhantomData, |
| 104 | } |
| 105 | } |
| 106 | |
| 107 | /// Access the raw pixel data (zero-copy). |
| 108 | /// 访问原始像素数据(零拷贝)。 |
nothing calls this directly
no outgoing calls
no test coverage detected