aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-02-12 06:32:51 +0100
committerCarl Eugen Hoyos <cehoyos@ag.or.at>2014-03-24 23:39:37 +0100
commitbe66ae3b015115aa72bd1bf56946e7c6309f1f14 (patch)
treec6c8a5f91c7a455e14ebd50329ec7a6567053fe9
parent519675c49c28eafa592274abea7170c16e8c45fc (diff)
downloadffmpeg-be66ae3b015115aa72bd1bf56946e7c6309f1f14.tar.gz
avformat/mov: fix keyframe flags for sample from chromium Issue 340865
Fixes ticket #3362. Signed-off-by: Michael Niedermayer <michaelni@gmx.at> (cherry picked from commit a0911b059763b8f13c70adcbbe71e10382855104)
-rw-r--r--libavformat/mov.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/libavformat/mov.c b/libavformat/mov.c
index 0959b22a89..7d3c85b073 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -2007,6 +2007,11 @@ static void mov_build_index(MOVContext *mov, AVStream *st)
rap_group_index++;
}
}
+ if (sc->keyframe_absent
+ && !sc->stps_count
+ && !rap_group_present
+ && st->codec->codec_type == AVMEDIA_TYPE_AUDIO)
+ keyframe = 1;
if (keyframe)
distance = 0;
sample_size = sc->alt_sample_size > 0 ? sc->alt_sample_size : sc->sample_sizes[current_sample];