diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2009-02-26 13:15:22 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2009-02-26 13:15:22 +0000 |
commit | 34583e1bbe3fd233a32e4a17421358e8c1853702 (patch) | |
tree | 8b781eacb33773bb0182ec43bdd38fc21b8942de | |
parent | d9fc9ff31bcc94f52cccd4b5a3d763d36bc70a8f (diff) | |
download | ffmpeg-34583e1bbe3fd233a32e4a17421358e8c1853702.tar.gz |
Fix next_pts computation to consider repeat_pict.
Originally committed as revision 17613 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | ffmpeg.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -1261,8 +1261,9 @@ static int output_packet(AVInputStream *ist, int ist_index, goto discard_packet; } if (ist->st->codec->time_base.num != 0) { + int ticks= ist->st->parser ? ist->st->parser->repeat_pict+1 : 1; ist->next_pts += ((int64_t)AV_TIME_BASE * - ist->st->codec->time_base.num) / + ist->st->codec->time_base.num * ticks) / ist->st->codec->time_base.den; } len = 0; @@ -1289,8 +1290,9 @@ static int output_packet(AVInputStream *ist, int ist_index, break; case CODEC_TYPE_VIDEO: if (ist->st->codec->time_base.num != 0) { + int ticks= ist->st->parser ? ist->st->parser->repeat_pict+1 : 1; ist->next_pts += ((int64_t)AV_TIME_BASE * - ist->st->codec->time_base.num) / + ist->st->codec->time_base.num * ticks) / ist->st->codec->time_base.den; } break; |