aboutsummaryrefslogtreecommitdiffstats
path: root/avconv_opt.c
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2015-07-15 17:17:54 +0200
committerAnton Khirnov <anton@khirnov.net>2015-07-19 09:38:44 +0200
commitbe101bc1e357c50fcb740bc4870b3bacc93a5727 (patch)
tree66cf36e11f214ac032073322a5ae9d8d19647ed7 /avconv_opt.c
parent1959351aecf09fc3e90208ff775f4849801dc13f (diff)
downloadffmpeg-be101bc1e357c50fcb740bc4870b3bacc93a5727.tar.gz
avconv: create the complex filtergraphs earlier
Since global options are processed before all the other options now, we do not have to try creating the complex filtergraphs several times anymore, it is enough to do it once after the input files are opened.
Diffstat (limited to 'avconv_opt.c')
-rw-r--r--avconv_opt.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/avconv_opt.c b/avconv_opt.c
index 1ec165db01..4505a8e6a9 100644
--- a/avconv_opt.c
+++ b/avconv_opt.c
@@ -1418,11 +1418,6 @@ static int open_output_file(OptionsContext *o, const char *filename)
AVDictionary *unused_opts = NULL;
AVDictionaryEntry *e = NULL;
- if (configure_complex_filters() < 0) {
- av_log(NULL, AV_LOG_FATAL, "Error configuring filters.\n");
- exit_program(1);
- }
-
GROW_ARRAY(output_files, nb_output_files);
of = av_mallocz(sizeof(*of));
if (!of)
@@ -2232,6 +2227,13 @@ int avconv_parse_options(int argc, char **argv)
goto fail;
}
+ /* create the complex filtergraphs */
+ ret = configure_complex_filters();
+ if (ret < 0) {
+ av_log(NULL, AV_LOG_FATAL, "Error configuring filters.\n");
+ goto fail;
+ }
+
/* open output files */
ret = open_files(&octx.groups[GROUP_OUTFILE], "output", open_output_file);
if (ret < 0) {