Skip to main content

CodecContext

Struct CodecContext 

Source
pub struct CodecContext { /* private fields */ }

Implementations§

Source§

impl CodecContext

Source

pub fn new(_codec: Option<Codec>) -> Result<Self, AvError>

§Errors

Stub; never executed on docs.rs.

Source

pub fn set_thread_count(&mut self, _thread_count: c_int)

Source

pub fn set_width(&mut self, _width: c_int)

Source

pub fn set_height(&mut self, _height: c_int)

Source

pub fn set_pix_fmt(&mut self, _pix_fmt: AVPixelFormat)

Source

pub fn set_time_base(&mut self, _time_base: AVRational)

Source

pub fn pix_fmt(&self) -> AVPixelFormat

Source

pub fn sample_fmt(&self) -> AVSampleFormat

Source

pub fn width(&self) -> c_int

Source

pub fn height(&self) -> c_int

Source

pub fn set_codec_id(&mut self, _codec_id: AVCodecID)

Source

pub fn set_framerate(&mut self, _framerate: AVRational)

Source

pub fn set_bit_rate(&mut self, _bit_rate: i64)

Source

pub fn bit_rate(&self) -> i64

Source

pub fn set_rc_max_rate(&mut self, _rc_max_rate: i64)

Source

pub fn set_rc_buffer_size(&mut self, _rc_buffer_size: c_int)

Source

pub fn set_color_primaries(&mut self, _color_primaries: AVColorPrimaries)

Source

pub fn set_color_trc(&mut self, _color_trc: AVColorTransferCharacteristic)

Source

pub fn set_colorspace(&mut self, _colorspace: AVColorSpace)

Source

pub fn set_color_range(&mut self, _color_range: AVColorRange)

Source

pub fn set_sample_rate(&mut self, _sample_rate: c_int)

Source

pub fn set_sample_fmt(&mut self, _sample_fmt: AVSampleFormat)

Source

pub fn set_max_b_frames(&mut self, _max_b_frames: c_int)

Source

pub fn set_gop_size(&mut self, _gop_size: c_int)

Source

pub fn set_refs(&mut self, _refs: c_int)

Source

pub fn set_qmin(&mut self, _qmin: c_int)

Source

pub fn set_qmax(&mut self, _qmax: c_int)

Source

pub fn set_ch_layout_default(&mut self, _nb_channels: c_int)

Source

pub fn set_flags(&mut self, _flags: c_int)

Source

pub fn flags(&self) -> c_int

Source

pub fn time_base(&self) -> AVRational

Source

pub fn codec_id(&self) -> AVCodecID

Source

pub fn frame_size(&self) -> c_int

Source

pub fn sample_rate(&self) -> c_int

Source

pub fn channels(&self) -> c_int

Source

pub fn ch_layout(&self) -> &AVChannelLayout

Source

pub fn set_opt(&mut self, _key: &str, _value: &str) -> Result<(), AvError>

§Errors

Stub; never executed on docs.rs.

Source

pub fn set_opt_cstr(&mut self, _key: &str, _value: &CStr) -> Result<(), AvError>

§Errors

Stub; never executed on docs.rs.

Source

pub fn set_opt_search_children( &mut self, _key: &str, _value: &str, ) -> Result<(), AvError>

§Errors

Stub; never executed on docs.rs.

Source

pub fn set_stats_in(&mut self, _stats: &CStr)

Source

pub fn clear_stats_in(&mut self)

Source

pub fn stats_out(&self) -> Option<CString>

Source

pub fn apply_parameters( &mut self, _params: &CodecParameters<'_>, ) -> Result<(), AvError>

§Errors

Stub; never executed on docs.rs.

Source

pub fn open_codec(&mut self, _codec: Codec) -> Result<(), AvError>

§Errors

Stub; never executed on docs.rs.

Source

pub fn send_packet(&mut self, _pkt: &Packet) -> Result<(), AvError>

§Errors

Stub; never executed on docs.rs.

Source

pub unsafe fn send_eof(&mut self) -> Result<(), AvError>

§Safety

Stub; never executed on docs.rs.

Source

pub fn receive_frame( &mut self, _frame: &mut Frame, ) -> Result<ReceiveOutcome, AvError>

§Errors

Stub; never executed on docs.rs.

Source

pub unsafe fn flush_buffers(&mut self)

§Safety

Stub; never executed on docs.rs.

Source

pub fn send_frame(&mut self, _frame: Option<&Frame>) -> Result<(), AvError>

§Errors

Stub; never executed on docs.rs.

Source

pub fn set_hw_device_ctx( &mut self, _device: &HwDeviceContext, ) -> Result<(), AvError>

§Errors

Stub; never executed on docs.rs.

Source

pub fn receive_packet( &mut self, _pkt: &mut Packet, ) -> Result<ReceiveOutcome, AvError>

§Errors

Stub; never executed on docs.rs.

Trait Implementations§

Source§

impl Debug for CodecContext

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Drop for CodecContext

Source§

fn drop(&mut self)

Executes the destructor for this type. Read more
Source§

fn pin_drop(self: Pin<&mut Self>)

🔬This is a nightly-only experimental API. (pin_ergonomics)
Execute the destructor for this type, but different to Drop::drop, it requires self to be pinned. Read more
Source§

impl Send for CodecContext

Auto Trait Implementations§

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

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

fn try_from(value: U) -> Result<T, !>

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.