From 98b8e60b14921cf94eadb0adea5e9d7461091e96 Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Wed, 2 May 2018 12:34:43 -0700 Subject: player: add more logging around buffering state --- player/playloop.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/player/playloop.c b/player/playloop.c index a7771b8be3..8845b58cef 100644 --- a/player/playloop.c +++ b/player/playloop.c @@ -674,11 +674,16 @@ static void handle_pause_on_low_cache(struct MPContext *mpctx) if (mpctx->cache_buffer != cache_buffer) { if ((mpctx->cache_buffer == 100) != (cache_buffer == 100)) { if (cache_buffer < 100) { - MP_VERBOSE(mpctx, "Enter buffering.\n"); + MP_VERBOSE(mpctx, "Enter buffering (buffer went from %d%% -> %d%%) [%fs].\n", + mpctx->cache_buffer, cache_buffer, s.ts_duration); } else { double t = now - mpctx->cache_stop_time; - MP_VERBOSE(mpctx, "End buffering (waited %f secs).\n", t); + MP_VERBOSE(mpctx, "End buffering (waited %f secs) [%fs].\n", + t, s.ts_duration); } + } else { + MP_VERBOSE(mpctx, "Still buffering (buffer went from %d%% -> %d%%) [%fs].\n", + mpctx->cache_buffer, cache_buffer, s.ts_duration); } mpctx->cache_buffer = cache_buffer; force_update = true; -- cgit v1.2.3