diff options
author | Marton Balint <cus@passwd.hu> | 2013-02-02 12:37:29 +0100 |
---|---|---|
committer | Marton Balint <cus@passwd.hu> | 2013-06-01 12:50:46 +0200 |
commit | 97e42551e468cdce53a667f33c9e9002b21db3c8 (patch) | |
tree | 3ad8f6dd3521bdec27c6850d2a592576b7719ad4 /ffplay.c | |
parent | 35b2f30fd119c404e37b4b48cfb89f63a648a4ed (diff) | |
download | ffmpeg-97e42551e468cdce53a667f33c9e9002b21db3c8.tar.gz |
ffplay: use more sane frame timer resetting logic
Signed-off-by: Marton Balint <cus@passwd.hu>
Diffstat (limited to 'ffplay.c')
-rw-r--r-- | ffplay.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -1378,8 +1378,9 @@ retry: return; } - if (delay > 0) - is->frame_timer += delay * FFMAX(1, floor((time-is->frame_timer) / delay)); + is->frame_timer += delay; + if (delay > 0 && time - is->frame_timer > AV_SYNC_THRESHOLD_MAX) + is->frame_timer = time; SDL_LockMutex(is->pictq_mutex); if (!redisplay && !isnan(vp->pts)) |