aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNicolas George <nicolas.george@normalesup.org>2013-09-03 22:13:49 +0200
committerNicolas George <george@nsup.org>2013-11-03 10:30:16 +0100
commitd300f5f6f570659e4b58567b35c9e8600c9f2956 (patch)
tree58b66a3112ee01dfea1a30ce0a33a8dd8cd16e9e
parentf775eb3fb4c7b716107355e428e40cb63f71ee7a (diff)
downloadffmpeg-d300f5f6f570659e4b58567b35c9e8600c9f2956.tar.gz
lavfi/avfiltergraph: do not reduce incompatible lists.
A list of "all channel layouts" but not "all channel counts" can not be reduced to a single unknown channel count.
-rw-r--r--libavfilter/avfiltergraph.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavfilter/avfiltergraph.c b/libavfilter/avfiltergraph.c
index bcdcde06ce..1fb83c4877 100644
--- a/libavfilter/avfiltergraph.c
+++ b/libavfilter/avfiltergraph.c
@@ -741,7 +741,8 @@ static int reduce_formats_on_filter(AVFilterContext *filter)
if (inlink->type != outlink->type || fmts->nb_channel_layouts == 1)
continue;
- if (fmts->all_layouts) {
+ if (fmts->all_layouts &&
+ (!FF_LAYOUT2COUNT(fmt) || fmts->all_counts)) {
/* Turn the infinite list into a singleton */
fmts->all_layouts = fmts->all_counts = 0;
ff_add_channel_layout(&outlink->in_channel_layouts, fmt);