OSDN Git Service
(root)
/
android-x86
/
external-ffmpeg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
394b0c8
)
mpegts: do not set pts for missing dts in video streams
author
Rainer Hochecker
<fernetmenta@online.de>
Tue, 3 Dec 2013 09:03:04 +0000
(10:03 +0100)
committer
Michael Niedermayer
<michaelni@gmx.at>
Wed, 4 Dec 2013 01:18:04 +0000
(
02:18
+0100)
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
libavformat/mpegts.c
patch
|
blob
|
history
diff --git
a/libavformat/mpegts.c
b/libavformat/mpegts.c
index
59b0058
..
d67c63a
100644
(file)
--- a/
libavformat/mpegts.c
+++ b/
libavformat/mpegts.c
@@
-972,7
+972,10
@@
static int mpegts_push_data(MpegTSFilter *filter,
pes->pts = AV_NOPTS_VALUE;
pes->dts = AV_NOPTS_VALUE;
if ((flags & 0xc0) == 0x80) {
- pes->dts = pes->pts = ff_parse_pes_pts(r);
+ pes->pts = ff_parse_pes_pts(r);
+ /* video pts is not monotonic, can't be used for dts */
+ if (pes->st->codec->codec_type != AVMEDIA_TYPE_VIDEO)
+ pes->dts = pes->pts;
r += 5;
} else if ((flags & 0xc0) == 0xc0) {
pes->pts = ff_parse_pes_pts(r);