summaryrefslogtreecommitdiff
path: root/avconv.c
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2016-05-22 19:57:36 +0200
committerAnton Khirnov <anton@khirnov.net>2016-06-21 12:39:02 +0200
commit73c6ec6d659bab11ac424a4ba6ce3a56246295ee (patch)
tree79300ca1198423c428a4aad9b69f2e2bfb1fdd87 /avconv.c
parent49670e4218d34899a1c37abb7a11615efc16f757 (diff)
avconv: create simple filtergraphs earlier
We already have all the necessary information in open_output_file(). This makes the information about the stream/filtergraph mappings available earlier.
Diffstat (limited to 'avconv.c')
-rw-r--r--avconv.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/avconv.c b/avconv.c
index 8cb8d142e8..e5a76b1746 100644
--- a/avconv.c
+++ b/avconv.c
@@ -2008,11 +2008,10 @@ static int transcode_init(void)
exit_program(1);
#endif
- if (!ost->filter &&
- (enc_ctx->codec_type == AVMEDIA_TYPE_VIDEO ||
- enc_ctx->codec_type == AVMEDIA_TYPE_AUDIO)) {
- FilterGraph *fg;
- fg = init_simple_filtergraph(ist, ost);
+ if ((enc_ctx->codec_type == AVMEDIA_TYPE_VIDEO ||
+ enc_ctx->codec_type == AVMEDIA_TYPE_AUDIO) &&
+ filtergraph_is_simple(ost->filter->graph)) {
+ FilterGraph *fg = ost->filter->graph;
if (configure_filtergraph(fg)) {
av_log(NULL, AV_LOG_FATAL, "Error opening filters!\n");
exit_program(1);