pub struct Rgb8Frame { /* private fields */ }Expand description
Raw RGB8 frame payload that can be consumed without f32 conversion.
Implementations§
Source§impl Rgb8Frame
impl Rgb8Frame
pub fn new( index: u64, timestamp_us: u64, width: usize, height: usize, data: Vec<u8>, ) -> Result<Self, VideoError>
pub fn from_bytes( index: u64, timestamp_us: u64, width: usize, height: usize, data: Bytes, ) -> Result<Self, VideoError>
pub fn index(&self) -> u64
pub fn timestamp_us(&self) -> u64
pub fn width(&self) -> usize
pub fn height(&self) -> usize
pub fn data(&self) -> &[u8] ⓘ
pub fn into_data(self) -> Vec<u8> ⓘ
pub fn into_bytes(self) -> Bytes
Trait Implementations§
impl Eq for Rgb8Frame
impl StructuralPartialEq for Rgb8Frame
Auto Trait Implementations§
impl !Freeze for Rgb8Frame
impl RefUnwindSafe for Rgb8Frame
impl Send for Rgb8Frame
impl Sync for Rgb8Frame
impl Unpin for Rgb8Frame
impl UnsafeUnpin for Rgb8Frame
impl UnwindSafe for Rgb8Frame
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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