diff options
author | Martin Storsjö <martin@martin.st> | 2010-04-20 07:38:52 +0000 |
---|---|---|
committer | Martin Storsjö <martin@martin.st> | 2010-04-20 07:38:52 +0000 |
commit | 5948f8222706d63f603167bf1a17c20bdee0b321 (patch) | |
tree | 3e2a4b1010f72d96e0f46f49eb0a3b99d2c8ee2f /libavformat/rtpdec.c | |
parent | 2cab6b48ad9595abe24615c3262f22b76c9b921d (diff) | |
download | ffmpeg-5948f8222706d63f603167bf1a17c20bdee0b321.tar.gz |
Reset RTCP timestamps after seeking, add range start offset to the packets timestamps
If these aren't reset, the timestamps make a huge jump when the next RTCP
is received.
Originally committed as revision 22918 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/rtpdec.c')
-rw-r--r-- | libavformat/rtpdec.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/rtpdec.c b/libavformat/rtpdec.c index bd3566e9f8..0d2df59a75 100644 --- a/libavformat/rtpdec.c +++ b/libavformat/rtpdec.c @@ -437,7 +437,7 @@ static void finalize_packet(RTPDemuxContext *s, AVPacket *pkt, uint32_t timestam delta_timestamp = timestamp - s->last_rtcp_timestamp; /* convert to the PTS timebase */ addend = av_rescale(s->last_rtcp_ntp_time - s->first_rtcp_ntp_time, s->st->time_base.den, (uint64_t)s->st->time_base.num << 32); - pkt->pts = addend + delta_timestamp; + pkt->pts = s->range_start_offset + addend + delta_timestamp; } } |