Struct ffmpeg::avcodec::EncoderContextBuilder
source · pub struct EncoderContextBuilder {
codec: *const AVCodec,
context: AvCodecContext,
}
Expand description
A builder to create a AvCodecContext
suitable for encoding.
Fields§
§codec: *const AVCodec
§context: AvCodecContext
Implementations§
source§impl EncoderContextBuilder
impl EncoderContextBuilder
sourcepub fn set_dimensions(&mut self, dimensions: Dimensions)
pub fn set_dimensions(&mut self, dimensions: Dimensions)
Set the width of input frames for this encoding context.
sourcepub fn set_time_base(&mut self, time_base: AVRational)
pub fn set_time_base(&mut self, time_base: AVRational)
Set the time base for this encoding context.
sourcepub fn set_pix_fmt(&mut self, fmt: AvPixelFormat)
pub fn set_pix_fmt(&mut self, fmt: AvPixelFormat)
Set the input pixel format for this encoding context.
sourcepub fn build(self) -> Result<AvCodecContext, AvCodecOpenError>
pub fn build(self) -> Result<AvCodecContext, AvCodecOpenError>
Build a encoder AvCodecContext from the configured options.
Auto Trait Implementations§
impl RefUnwindSafe for EncoderContextBuilder
impl !Send for EncoderContextBuilder
impl !Sync for EncoderContextBuilder
impl Unpin for EncoderContextBuilder
impl UnwindSafe for EncoderContextBuilder
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