From eada87853eddca71c7d5c7ca4d7c842e10f312ea Mon Sep 17 00:00:00 2001 From: wm4 Date: Wed, 7 May 2014 21:39:17 +0200 Subject: player: handle video reconfig slightly different again Now we avoid calling update_video() twice on reconfig (once to check whether there are still new frames, and again to actually do the reconfig). Instead, we check whether there's still something going on before calling update_video() at all, and depending on that update_video() will be allowed to reconfig or not. This will simplify some things later. --- player/video.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'player/video.c') diff --git a/player/video.c b/player/video.c index d2c605bbe9..35ad3e7b39 100644 --- a/player/video.c +++ b/player/video.c @@ -469,6 +469,9 @@ static int video_output_image(struct MPContext *mpctx, bool reconfig_ok) return -1; } init_vo(mpctx); + // Display the frame queued after this immediately. + // (Neutralizes frame time calculation in update_video.) + mpctx->video_next_pts = MP_NOPTS_VALUE; } // Queue new frame, if there's one. -- cgit v1.2.3