summaryrefslogtreecommitdiffstats
path: root/mp_core.h
diff options
context:
space:
mode:
authorwm4 <wm4@mplayer2.org>2012-01-06 19:48:50 +0100
committerwm4 <wm4@mplayer2.org>2012-01-18 04:33:30 +0100
commitfee4d3b473deeb7b77d868ad2d78fc61446fe364 (patch)
tree2d5c737af2a2892613d08b00d89413e4adc69d47 /mp_core.h
parent6340b54d5c39d1ef5647c79a98d219cc5d8228d2 (diff)
downloadmpv-fee4d3b473deeb7b77d868ad2d78fc61446fe364.tar.bz2
mpv-fee4d3b473deeb7b77d868ad2d78fc61446fe364.tar.xz
osd: add setting to display OSD always on terminal
Now the option --term-osd=force will cause mplayer to display all OSD messages on the terminal, even if there is video. Possible values for --term-osd: - auto: use video OSD, or of there's no video, the terminal (default) - off: always use video for OSD - force: always use terminal for OSD -term-osd and --term-osd are equivalent to --term-osd=force. This changes the meaning of the option, since -term-osd used to enable the OSD default behavior, i.e. --term-osd=auto. -noterm-osd has the same effect as --term-osd=off, and is kept for compatibility. Implementation note: The location for the OSD text was shared between the two code paths (it was in osd_state.osd_text). We can't rely on the fact that the video-OSD update code normally isn't run when --term-osd is called. When e.g. panscan is updated, the video OSD code will draw the OSD anyway. This would sometimes show unwanted OSD text on the video. Deal with this by putting the current terminal-OSD text in a different place (in MPContext.terminal_osd_text) to deal with this.
Diffstat (limited to 'mp_core.h')
-rw-r--r--mp_core.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/mp_core.h b/mp_core.h
index fbcd03b8ba..26ba1b764f 100644
--- a/mp_core.h
+++ b/mp_core.h
@@ -90,6 +90,7 @@ typedef struct MPContext {
struct mp_fifo *key_fifo;
struct input_ctx *input;
struct osd_state *osd;
+ char *terminal_osd_text;
struct sub_data *subdata; // current sub_data style subtitles if any
// last sub_data style sub line if any, used by log_sub() only
struct subtitle *vo_sub_last;