Avoid brittle and obfuscating reference to a global.
Signed-off-by: Anton Khirnov <anton@khirnov.net>
return ret;
}
-AVDictionary **setup_find_stream_info_opts(AVFormatContext *s)
+AVDictionary **setup_find_stream_info_opts(AVFormatContext *s, AVDictionary *codec_opts)
{
int i;
AVDictionary **opts;
* @return pointer to the created array of dictionaries, NULL if it
* cannot be created
*/
-AVDictionary **setup_find_stream_info_opts(AVFormatContext *s);
+AVDictionary **setup_find_stream_info_opts(AVFormatContext *s, AVDictionary *codec_opts);
/**
* Print an error message to stderr, indicating filename and a human
}
/* Set AVCodecContext options for avformat_find_stream_info */
- opts = setup_find_stream_info_opts(ic);
+ opts = setup_find_stream_info_opts(ic, codec_opts);
orig_nb_streams = ic->nb_streams;
/* If not enough info to get the stream parameters, we decode the
if(genpts)
ic->flags |= AVFMT_FLAG_GENPTS;
- opts = setup_find_stream_info_opts(ic);
+ opts = setup_find_stream_info_opts(ic, codec_opts);
orig_nb_streams = ic->nb_streams;
err = avformat_find_stream_info(ic, opts);