pub struct StatefulEncoder<Handle, Backend>where
Backend: StatefulVideoEncoderBackend<Handle>,{ /* private fields */ }
Implementations§
Source§impl<Handle, Backend> StatefulEncoder<Handle, Backend>where
Backend: StatefulVideoEncoderBackend<Handle>,
impl<Handle, Backend> StatefulEncoder<Handle, Backend>where
Backend: StatefulVideoEncoderBackend<Handle>,
Sourcepub fn backend(&mut self) -> &Backend
pub fn backend(&mut self) -> &Backend
StatefulVideoEncoderBackend
’s instance
Trait Implementations§
Source§impl<Handle, Backend> VideoEncoder<Handle> for StatefulEncoder<Handle, Backend>where
Backend: StatefulVideoEncoderBackend<Handle>,
impl<Handle, Backend> VideoEncoder<Handle> for StatefulEncoder<Handle, Backend>where
Backend: StatefulVideoEncoderBackend<Handle>,
Source§fn encode(
&mut self,
meta: FrameMetadata,
handle: Handle,
) -> Result<(), EncodeError>
fn encode( &mut self, meta: FrameMetadata, handle: Handle, ) -> Result<(), EncodeError>
Enqueues the frame for encoding. The implementation will drop the handle after it is no
longer be needed. The encoder is not required to immediately start processing the frame
and yield output bitstream. It is allowed to hold frames until certain conditions are met
eg. for specified prediction structures or referencing in order to further optimize
the compression rate of the bitstream.
Source§fn poll(&mut self) -> EncodeResult<Option<CodedBitstreamBuffer>>
fn poll(&mut self) -> EncodeResult<Option<CodedBitstreamBuffer>>
Polls on the encoder for the available output bitstream with compressed frames that where
submitted with
Self::encode
. Read moreSource§fn drain(&mut self) -> EncodeResult<()>
fn drain(&mut self) -> EncodeResult<()>
Drains the encoder. This means that encoder is required to finish processing of all the
frames in the internal queue and yield output bitstream by the end of the call. The output
bitstream then can be polled using
Self::poll
function. Read moreAuto Trait Implementations§
impl<Handle, Backend> Freeze for StatefulEncoder<Handle, Backend>where
Backend: Freeze,
impl<Handle, Backend> RefUnwindSafe for StatefulEncoder<Handle, Backend>where
Backend: RefUnwindSafe,
Handle: RefUnwindSafe,
impl<Handle, Backend> Send for StatefulEncoder<Handle, Backend>
impl<Handle, Backend> Sync for StatefulEncoder<Handle, Backend>
impl<Handle, Backend> Unpin for StatefulEncoder<Handle, Backend>
impl<Handle, Backend> UnwindSafe for StatefulEncoder<Handle, Backend>where
Backend: UnwindSafe,
Handle: UnwindSafe,
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