Struct StatefulEncoder

Source
pub struct StatefulEncoder<Handle, Backend>
where Backend: StatefulVideoEncoderBackend<Handle>,
{ /* private fields */ }

Implementations§

Source§

impl<Handle, Backend> StatefulEncoder<Handle, Backend>
where Backend: StatefulVideoEncoderBackend<Handle>,

Source

pub fn backend(&mut self) -> &Backend

Trait Implementations§

Source§

impl<Handle, Backend> VideoEncoder<Handle> for StatefulEncoder<Handle, Backend>
where Backend: StatefulVideoEncoderBackend<Handle>,

Source§

fn tune(&mut self, tunings: Tunings) -> EncodeResult<()>

Changes dynamic parameters (aka Tunings) of the encoded stream. The change may not be effective right away. Depending on the used prediction structure, the Predictor may choose to delay the change until entire or a some part of the structure had been encoded. Read more
Source§

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>>

Polls on the encoder for the available output bitstream with compressed frames that where submitted with Self::encode. Read more
Source§

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 more

Auto 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>
where Backend: Send, Handle: Send,

§

impl<Handle, Backend> Sync for StatefulEncoder<Handle, Backend>
where Backend: Sync, Handle: Sync,

§

impl<Handle, Backend> Unpin for StatefulEncoder<Handle, Backend>
where Backend: Unpin, Handle: Unpin,

§

impl<Handle, Backend> UnwindSafe for StatefulEncoder<Handle, Backend>
where Backend: UnwindSafe, Handle: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.