pub struct RefFrameMvs { /* private fields */ }Expand description
Reference frame motion vector storage.
Stores MVs for decoded reference frames to enable temporal prediction.
Implementations§
Source§impl RefFrameMvs
impl RefFrameMvs
Sourcepub fn with_max_refs(self, max: usize) -> Self
pub fn with_max_refs(self, max: usize) -> Self
Sets the maximum number of references.
Sourcepub fn allocate(&mut self, width: usize, height: usize, num_refs: usize)
pub fn allocate(&mut self, width: usize, height: usize, num_refs: usize)
Allocates storage for reference frames.
Sourcepub fn get_frame(&self, frame_idx: usize) -> Option<&MvCache>
pub fn get_frame(&self, frame_idx: usize) -> Option<&MvCache>
Gets the MV cache for a reference frame.
Sourcepub fn get_frame_mut(&mut self, frame_idx: usize) -> Option<&mut MvCache>
pub fn get_frame_mut(&mut self, frame_idx: usize) -> Option<&mut MvCache>
Gets mutable MV cache for a reference frame.
Sourcepub fn store_frame(&mut self, frame_idx: usize, source: &MvCache)
pub fn store_frame(&mut self, frame_idx: usize, source: &MvCache)
Stores MVs from current frame as reference.
Sourcepub fn get_co_located(
&self,
frame_idx: usize,
mi_row: usize,
mi_col: usize,
) -> Option<MvCacheEntry>
pub fn get_co_located( &self, frame_idx: usize, mi_row: usize, mi_col: usize, ) -> Option<MvCacheEntry>
Gets co-located MV from reference frame.
Sourcepub fn shift_frames(&mut self)
pub fn shift_frames(&mut self)
Shifts reference frames (for new frame insertion).
Trait Implementations§
Source§impl Clone for RefFrameMvs
impl Clone for RefFrameMvs
Source§fn clone(&self) -> RefFrameMvs
fn clone(&self) -> RefFrameMvs
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RefFrameMvs
impl Debug for RefFrameMvs
Auto Trait Implementations§
impl Freeze for RefFrameMvs
impl RefUnwindSafe for RefFrameMvs
impl Send for RefFrameMvs
impl Sync for RefFrameMvs
impl Unpin for RefFrameMvs
impl UnsafeUnpin for RefFrameMvs
impl UnwindSafe for RefFrameMvs
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