pub struct FrameRef<'a> {
pub data: Cow<'a, [u8]>,
pub alpha_data: Option<Cow<'a, [u8]>>,
pub duration_ms: u32,
}Expand description
A single frame from an animated AVIF, with zero-copy when possible.
The data field is Cow::Borrowed when the frame lives in a single
contiguous mdat extent, and Cow::Owned when extents must be concatenated.
Fields§
§data: Cow<'a, [u8]>§alpha_data: Option<Cow<'a, [u8]>>Alpha channel data for this frame, if the animation has a separate alpha track.
duration_ms: u32Auto Trait Implementations§
impl<'a> Freeze for FrameRef<'a>
impl<'a> RefUnwindSafe for FrameRef<'a>
impl<'a> Send for FrameRef<'a>
impl<'a> Sync for FrameRef<'a>
impl<'a> Unpin for FrameRef<'a>
impl<'a> UnwindSafe for FrameRef<'a>
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