=====av_open_input_file=====
====Overview====
Defined in ''avformat.h''\\
Open a media file as input. The codecs are not opened. Only the file header (if present) is read.\\
NOTE: If no output is desired, used [[ffmpeg:av_alloc_format_context]] instead.
int av_open_input_file(AVFormatContext **ic_ptr,
const char *filename,
AVInputFormat *fmt,
int buf_size,
AVFormatParameters *ap);
====Parameters====
===ic_ptr===
AVFormatContext **ic_ptr
A pointer to an [[ffmpeg:AVFormatContext]] pointer. The opened media file handle is put here.
===filename===
const char *filename
Filename to open.
===fmt===
AVInputFormat *fmt
An [[ffmpeg:AVInputFormat]] pointer. If non NULL, force the file format to use.
===buf_size===
int buf_size
Optional buffer size (zero if default is OK).
===ap===
AVFormatParameters *ap
An [[ffmpeg:AVFormatParameters]] pointer containing additional parameters needed when opening the file (NULL if default).
====Return value====
0 if OK. [[ffmpeg:AVERROR]] otherwise.
----
Back to [[ffmpeg:ffmpeg]]