Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mpc-hc/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJustin Ruggles <justin.ruggles@gmail.com>2012-04-26 20:51:14 +0400
committerHendrik Leppkes <h.leppkes@gmail.com>2012-04-26 20:51:14 +0400
commitfa6b37c1cec4fabead0bd76168d9282d060b415c (patch)
tree51cdfefb4b5ffc05403e5585e2152f190cb0b9ff
parent4a7217d8b9dc9e6c0364358bc53fec68b20497bc (diff)
avformat: remove a workaround for broken timestampslav0.50.2
This modifies pts in situations other than what was intended, leading to invalid timestamps. Reverts commit 90bb394dccacd10607153833a0aeba0d970dc8db
-rw-r--r--libavformat/utils.c12
1 files changed, 0 insertions, 12 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c
index 0f3b6c3333..fc02a61d12 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -1067,18 +1067,6 @@ static void compute_pkt_fields(AVFormatContext *s, AVStream *st,
pkt->duration ) {
int duration = pkt->duration;
- if(pkt->pts != AV_NOPTS_VALUE && duration){
- int64_t old_diff= FFABS(st->cur_dts - duration - pkt->pts);
- int64_t new_diff= FFABS(st->cur_dts - pkt->pts);
- if( old_diff < new_diff && old_diff < (duration>>3)
- && (!strcmp(s->iformat->name, "mpeg") ||
- !strcmp(s->iformat->name, "mpegts"))){
- pkt->pts += duration;
- av_log(s, AV_LOG_WARNING, "Adjusting PTS forward\n");
- // av_log(NULL, AV_LOG_DEBUG, "id:%d old:%"PRId64" new:%"PRId64" dur:%d cur:%"PRId64" size:%d\n", pkt->stream_index, old_diff, new_diff, pkt->duration, st->cur_dts, pkt->size);
- }
- }
-
/* presentation is not delayed : PTS and DTS are the same */
if(pkt->pts == AV_NOPTS_VALUE)
pkt->pts = pkt->dts;