From cdd6eb0994bc6aeb8aeb0326e5d8c61c06eb38eb Mon Sep 17 00:00:00 2001 From: Dudemanguy Date: Sun, 15 Mar 2020 12:42:33 -0500 Subject: wayland: notify vo if an output changes Previously, the vo wasn't always informed if something about the output changed during playback. For instance, changing a display's refresh rate during playback would not update mpv's display fps. Fix this by simply using VO_EVENT_WIN_STATE in output_handle_done which executes whenever something about the output is changed. --- video/out/wayland_common.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/video/out/wayland_common.c b/video/out/wayland_common.c index fe9a876bed..20a25f8652 100644 --- a/video/out/wayland_common.c +++ b/video/out/wayland_common.c @@ -631,6 +631,8 @@ static void output_handle_done(void* data, struct wl_output *wl_output) "\tHz: %f\n", o->make, o->model, o->id, o->geometry.x0, o->geometry.y0, mp_rect_w(o->geometry), o->phys_width, mp_rect_h(o->geometry), o->phys_height, o->scale, o->refresh_rate); + + o->wl->pending_vo_events |= VO_EVENT_WIN_STATE; } static void output_handle_scale(void* data, struct wl_output *wl_output, -- cgit v1.2.3