Struct convert_image::Y4MFrame
source · pub struct Y4MFrame {
pub data: Vec<u8>,
pub width: i32,
pub height: i32,
pub y_stride: i32,
/* private fields */
}Expand description
YUV420 planar data
Fields§
§data: Vec<u8>§width: i32§height: i32§y_stride: i32Implementations§
source§impl Y4MFrame
impl Y4MFrame
pub fn convert<DEST>(&self) -> Result<impl ImageStride<DEST>, Error>where
DEST: PixelFormat,
pub fn forced_block_size(&self) -> Option<u32>
pub fn new_mono8(data: Vec<u8>, width: u32, height: u32) -> Result<Self, Error>
pub fn is_known_mono_only(&self) -> bool
pub fn data(&self) -> &[u8] ⓘ
pub fn into_data(self) -> Vec<u8>
pub fn y_plane_data(&self) -> &[u8] ⓘ
pub fn u_plane_data(&self) -> &[u8] ⓘ
pub fn v_plane_data(&self) -> &[u8] ⓘ
pub fn width(&self) -> u32
pub fn height(&self) -> u32
pub fn y_stride(&self) -> usize
pub fn u_stride(&self) -> usize
pub fn v_stride(&self) -> usize
pub fn colorspace(&self) -> Y4MColorspace
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Y4MFrame
impl RefUnwindSafe for Y4MFrame
impl Send for Y4MFrame
impl Sync for Y4MFrame
impl Unpin for Y4MFrame
impl UnwindSafe for Y4MFrame
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
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more