lavf: don't select an attached picture as default stream for seeking.

This commit is contained in:
Anton Khirnov 2012-03-15 09:04:41 +01:00
parent 251422982b
commit cd9a3c3512
1 changed files with 2 additions and 1 deletions

View File

@ -1307,7 +1307,8 @@ int av_find_default_stream_index(AVFormatContext *s)
return -1;
for(i = 0; i < s->nb_streams; i++) {
st = s->streams[i];
if (st->codec->codec_type == AVMEDIA_TYPE_VIDEO) {
if (st->codec->codec_type == AVMEDIA_TYPE_VIDEO &&
!(st->disposition & AV_DISPOSITION_ATTACHED_PIC)) {
return i;
}
if (first_audio_index < 0 && st->codec->codec_type == AVMEDIA_TYPE_AUDIO)