diff options
author | wm4 <wm4@nowhere> | 2014-09-25 20:25:24 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2014-09-25 21:32:56 +0200 |
commit | d23ffd243f33ce5d6a5649c7909664b0ae1e858e (patch) | |
tree | d237b384b4967682ead44f08d9fd0b7d78632776 /player/core.h | |
parent | 9537e33057d99db65bb12d902d660e3b8c47c5ea (diff) | |
download | mpv-d23ffd243f33ce5d6a5649c7909664b0ae1e858e.tar.bz2 mpv-d23ffd243f33ce5d6a5649c7909664b0ae1e858e.tar.xz |
player: rate-limit OSD text update
There's no need to update OSD messages and the terminal status if nobody
is going to see it. Since the player doesn't block on video display
anymore, this update happens to often and probably burns slightly more
CPU than necessary. (OSD redrawing is handled separately, so it's just
mostly useless text processing and such.)
Change it so that it's updated only on every video frame or all 50ms
(whatever comes first).
For VO OSD, we could in theory try to lock to the OSD redraw heuristic
or the display refresh rate, but that's more complicated and doesn't
work for the terminal status.
Diffstat (limited to 'player/core.h')
-rw-r--r-- | player/core.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/player/core.h b/player/core.h index 11421ce485..a60e13a3e7 100644 --- a/player/core.h +++ b/player/core.h @@ -184,6 +184,7 @@ typedef struct MPContext { int osd_function; double osd_function_visible; double osd_last_update; + bool osd_force_update; struct osd_progbar_state osd_progbar; struct playlist *playlist; |