summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2016-05-06 19:57:17 +0200
committerwm4 <wm4@nowhere>2016-05-06 19:57:17 +0200
commit55846641eac86d55817be20eab00b8256a7e1c9a (patch)
tree0a5ecaad8fab59f4bbbc8208f65f1b6a6b4b0c55
parent7c5188c27eacf4e13238f3621e015518c87bce10 (diff)
downloadmpv-55846641eac86d55817be20eab00b8256a7e1c9a.tar.bz2
mpv-55846641eac86d55817be20eab00b8256a7e1c9a.tar.xz
x11: add --x11-bypass-compositor=always
Also add missing documentation for fs-only, and correct the default.
-rw-r--r--DOCS/man/options.rst9
-rw-r--r--options/options.c2
-rw-r--r--video/out/x11_common.c1
3 files changed, 9 insertions, 3 deletions
diff --git a/DOCS/man/options.rst b/DOCS/man/options.rst
index 7cd9b8d281..b3ec913dee 100644
--- a/DOCS/man/options.rst
+++ b/DOCS/man/options.rst
@@ -2085,9 +2085,14 @@ Window
This option might be removed in the future.
-``--x11-bypass-compositor=<yes|no>``
+``--x11-bypass-compositor=<yes|no|fs-only|always>``
If set to ``yes``, then ask the compositor to unredirect the mpv window
- (default: no). This uses the ``_NET_WM_BYPASS_COMPOSITOR`` hint.
+ (default: ``fs-only``). This uses the ``_NET_WM_BYPASS_COMPOSITOR`` hint.
+
+ ``fs-only`` asks the window manager to disable the compositor only in
+ fullscreen mode,
+
+ ``always`` asks the window manager to always enable the compositor.
Disc Devices
diff --git a/options/options.c b/options/options.c
index 0487986f8f..b0d6fb7a30 100644
--- a/options/options.c
+++ b/options/options.c
@@ -461,7 +461,7 @@ const m_option_t mp_opts[] = {
OPT_CHOICE("x11-netwm", vo.x11_netwm, 0,
({"auto", 0}, {"no", -1}, {"yes", 1})),
OPT_CHOICE("x11-bypass-compositor", vo.x11_bypass_compositor, 0,
- ({"no", 0}, {"yes", 1}, {"fs-only", 2})),
+ ({"no", 0}, {"yes", 1}, {"fs-only", 2}, {"always", 3})),
#endif
#if HAVE_WIN32
OPT_STRING("vo-mmcss-profile", vo.mmcss_profile, M_OPT_FIXED),
diff --git a/video/out/x11_common.c b/video/out/x11_common.c
index c42e78c97b..009f7e4bf6 100644
--- a/video/out/x11_common.c
+++ b/video/out/x11_common.c
@@ -959,6 +959,7 @@ static void vo_x11_update_composition_hint(struct vo *vo)
case 0: hint = 0; break; // leave default
case 1: hint = 1; break; // always bypass
case 2: hint = x11->fs ? 1 : 0; break; // bypass in FS
+ case 3: hint = 2; break; // always enable
}
XChangeProperty(x11->display, x11->window, XA(x11,_NET_WM_BYPASS_COMPOSITOR),