player: never show "DS: (unavailable)"

Kind of annoying.
This commit is contained in:
wm4 2016-01-20 16:52:32 +01:00
parent f352669157
commit ff43215960
1 changed files with 6 additions and 3 deletions

View File

@ -237,9 +237,12 @@ static void print_status(struct MPContext *mpctx)
// VO stats
if (mpctx->vo_chain) {
if (mpctx->display_sync_active) {
char *r = mp_property_expand_string(mpctx, "${vsync-ratio}");
saddf(&line, " DS: %s/%"PRId64, r,
vo_get_delayed_count(mpctx->video_out));
char *r = mp_property_expand_string(mpctx,
"${?vsync-ratio:${vsync-ratio}}");
if (r[0]) {
saddf(&line, " DS: %s/%"PRId64, r,
vo_get_delayed_count(mpctx->video_out));
}
talloc_free(r);
}
int64_t c = vo_get_drop_count(mpctx->video_out);