diff options
-rw-r--r-- | player/audio.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/player/audio.c b/player/audio.c index 8274399f67..75989bfe20 100644 --- a/player/audio.c +++ b/player/audio.c @@ -429,7 +429,7 @@ static bool get_sync_samples(struct MPContext *mpctx, int *skip) return true; } -void fill_audio_out_buffers(struct MPContext *mpctx, double endpts) +static void do_fill_audio_out_buffers(struct MPContext *mpctx, double endpts) { struct MPOpts *opts = mpctx->opts; struct dec_audio *d_audio = mpctx->d_audio; @@ -589,6 +589,15 @@ void fill_audio_out_buffers(struct MPContext *mpctx, double endpts) } } +void fill_audio_out_buffers(struct MPContext *mpctx, double endpts) +{ + do_fill_audio_out_buffers(mpctx, endpts); + // Run audio playback state machine again to display the actual audio PTS + // as current time on OSD in audio-only mode in most situations. + if (mpctx->audio_status == STATUS_SYNCING) + do_fill_audio_out_buffers(mpctx, endpts); +} + // Drop data queued for output, or which the AO is currently outputting. void clear_audio_output_buffers(struct MPContext *mpctx) { |