aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2015-04-06 04:20:51 +0200
committerMichael Niedermayer <michaelni@gmx.at>2015-04-17 15:20:29 +0200
commit8968de6c61935da8942f1d9a152412a7c2d0ddc5 (patch)
tree504deaaad160faf4a9344efdd861bebd578de8a5
parent043cb40becb230cc53fc038cca26b4bb4b6ca7d7 (diff)
downloadffmpeg-8968de6c61935da8942f1d9a152412a7c2d0ddc5.tar.gz
avformat/utils: avoid discarded streams in av_find_default_stream_index()
Fixes Ticket2010 Signed-off-by: Michael Niedermayer <michaelni@gmx.at> (cherry picked from commit ff6841c6bb2d35f8d461419e45d59be7542d03fe) Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavformat/utils.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c
index 78653d1f1c..1ab8bb646b 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -1583,6 +1583,9 @@ int av_find_default_stream_index(AVFormatContext *s)
score += 50;
}
+ if (st->discard != AVDISCARD_ALL)
+ score += 200;
+
if (score > best_score) {
best_score = score;
best_stream = i;