diff options
author | Dudemanguy <random342@airmail.cc> | 2023-01-22 17:06:15 -0600 |
---|---|---|
committer | Dudemanguy <random342@airmail.cc> | 2023-01-24 00:04:39 +0000 |
commit | 006ec9ce4357cd198955bc2e56caec34943db52d (patch) | |
tree | 427e571e77d9305b5afa12d2e4e0018d5b2b8433 /video/out/vo_wlshm.c | |
parent | 9b59d39a3ab64da0e9489ee4ce2062d4503e7cc5 (diff) | |
download | mpv-006ec9ce4357cd198955bc2e56caec34943db52d.tar.bz2 mpv-006ec9ce4357cd198955bc2e56caec34943db52d.tar.xz |
wayland: rewrite geometry and scaling handling
This is in preparation for fractional scaling support. Basically, redo
all the coordinates in wayland so that wl->geometry is equal exactly to
what is being put out to the screen (no extra wl->scaling multiplication
required). The wl->vdparams variable is also eliminated for simplicity.
This changes mpv's behavior on wayland with hidpi scaling but that will
be addressed in more detail with the next commit.
Diffstat (limited to 'video/out/vo_wlshm.c')
-rw-r--r-- | video/out/vo_wlshm.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/video/out/vo_wlshm.c b/video/out/vo_wlshm.c index 9b35364c6d..6f70767b29 100644 --- a/video/out/vo_wlshm.c +++ b/video/out/vo_wlshm.c @@ -182,8 +182,8 @@ static int resize(struct vo *vo) { struct priv *p = vo->priv; struct vo_wayland_state *wl = vo->wl; - const int32_t width = wl->scaling * mp_rect_w(wl->geometry); - const int32_t height = wl->scaling * mp_rect_h(wl->geometry); + const int32_t width = mp_rect_w(wl->geometry); + const int32_t height = mp_rect_h(wl->geometry); struct buffer *buf; vo_wayland_set_opaque_region(wl, 0); |