summaryrefslogtreecommitdiffstats
path: root/video/out/vo_opengl.c
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2015-11-01 20:43:46 +0100
committerwm4 <wm4@nowhere>2015-11-01 20:47:57 +0100
commit30a61064773e4fcb4c20a90787af95bc7d0e6d12 (patch)
tree8ae343f6dcfe428a54e3db5dd523870ad8b78f20 /video/out/vo_opengl.c
parentf1e767b6a2539b9c4760cc63f2e8d96308153ebc (diff)
downloadmpv-30a61064773e4fcb4c20a90787af95bc7d0e6d12.tar.bz2
mpv-30a61064773e4fcb4c20a90787af95bc7d0e6d12.tar.xz
vo_opengl: win32: try to enable DwmFlush by default
Enable it by default, but not unconditionally. Add an "auto" mode, which disable DwmFlush if the compositor is (probably) inactive. Let's see how this goes. Since I accidentally enabled DwmFlush always by default (more or less) in a previous commit touching this code, this is probably mostly just cargo-culting, and it's uncertain whether it does anything. Note that I still got bad vsync behavior when fullscreening mpv, and making another window visible on the same screen. This happens even if forcing DWM.
Diffstat (limited to 'video/out/vo_opengl.c')
-rw-r--r--video/out/vo_opengl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/video/out/vo_opengl.c b/video/out/vo_opengl.c
index f5a3cdcf73..66ab7f11a7 100644
--- a/video/out/vo_opengl.c
+++ b/video/out/vo_opengl.c
@@ -460,7 +460,7 @@ static const struct m_option options[] = {
OPT_FLAG("waitvsync", waitvsync, 0),
OPT_INT("swapinterval", swap_interval, 0, OPTDEF_INT(1)),
OPT_CHOICE("dwmflush", dwm_flush, 0,
- ({"no", 0}, {"windowed", 1}, {"yes", 2})),
+ ({"no", -1}, {"auto", 0}, {"windowed", 1}, {"yes", 2})),
OPT_FLAG("debug", use_gl_debug, 0),
OPT_STRING_VALIDATE("backend", backend, 0, mpgl_validate_backend_opt),
OPT_FLAG("sw", allow_sw, 0),