diff options
author | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2008-11-27 21:24:25 +0000 |
---|---|---|
committer | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2008-11-27 21:24:25 +0000 |
commit | cb103a194beb766d230b715671f2bee40af1cacc (patch) | |
tree | 03b0e01a0f65c4420828455e4d0b9ea7df41ead2 | |
parent | f653095bdd5f6c25960f75b81b138dd78f73ca37 (diff) | |
download | ffmpeg-cb103a194beb766d230b715671f2bee40af1cacc.tar.gz |
Make the input realtime framerate emulation code use ist->pts for
computing the time of the next frame to send to output.
See the thread: fix ffmpeg -re behaviour.
Originally committed as revision 15944 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | ffmpeg.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -1306,7 +1306,7 @@ static int output_packet(AVInputStream *ist, int ist_index, /* frame rate emulation */ if (ist->st->codec->rate_emu) { - int64_t pts = av_rescale((int64_t) ist->frame * ist->st->codec->time_base.num, 1000000, ist->st->codec->time_base.den); + int64_t pts = av_rescale(ist->pts, 1000000, AV_TIME_BASE); int64_t now = av_gettime() - ist->start; if (pts > now) usleep(pts - now); |