Struct rsmpeg::avformat::AVFormatContextInput[][src]

pub struct AVFormatContextInput { /* fields omitted */ }

Implementations

impl AVFormatContextInput[src]

pub fn as_ptr(&self) -> *const AVFormatContext[src]

pub fn as_mut_ptr(&mut self) -> *mut AVFormatContext[src]

pub unsafe fn set_ptr(&mut self, ptr: NonNull<AVFormatContext>)[src]

Safety

This function should only be called when the pointer is valid and the data it’s pointing to can be dropped.

pub unsafe fn from_raw(raw: NonNull<AVFormatContext>) -> Self[src]

Safety

This function should only be called when the pointer is valid and the data it’s pointing to can be dropped.

pub fn into_raw(self) -> NonNull<AVFormatContext>[src]

impl AVFormatContextInput[src]

pub fn open(filename: &CStr) -> Result<Self>[src]

Create a AVFormatContextInput instance of a file.

pub fn dump(&mut self, index: usize, filename: &CStr) -> Result<()>[src]

Dump ffi::AVFormatContext’s info in the “FFmpeg” way.

The filename here is just for info printing, it really doesn’t matter.

pub fn read_packet(&mut self) -> Result<Option<AVPacket>>[src]

Return the next packet of a stream. This function returns what is stored in the file, and does not validate that what is there are valid packets for the decoder. It will split what is stored in the file into packets and return one for each call. It will not omit invalid data between valid packets so as to give the decoder the maximum information possible for decoding.

pub fn find_best_stream(
    &self,
    media_type: AVMediaType
) -> Result<Option<(usize, AVCodecRef<'static>)>>
[src]

Return the stream index and stream decoder if there is any “best” stream. “best” means the most likely what the user wants.

impl<'stream> AVFormatContextInput[src]

pub fn streams(&'stream self) -> AVStreamRefs<'stream>[src]

Get Iterator of all AVStreams in the ffi::AVFormatContext.

pub fn iformat(&'stream self) -> AVInputFormatRef<'stream>[src]

Get Iterator of all AVInputFormats in the ffi::AVFormatContext.

pub fn metadata(&'stream self) -> AVDictionaryRef<'stream>[src]

Get metadata of the ffi::AVFormatContext in crate::avutil::AVDictionary. demuxing: set by libavformat in avformat_open_input() muxing: may be set by the caller before avformat_write_header()

Trait Implementations

impl Deref for AVFormatContextInput[src]

type Target = AVFormatContext

The resulting type after dereferencing.

fn deref(&self) -> &Self::Target[src]

Dereferences the value.

impl Drop for AVFormatContextInput[src]

fn drop(&mut self)[src]

Executes the destructor for this type. Read more

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

impl<T> From<T> for T[src]

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

pub fn into(self) -> U[src]

Performs the conversion.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

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

Performs the conversion.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

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

Performs the conversion.