mirror of
https://github.com/Droid-Deck/DroidDeck.git
synced 2026-12-05 12:35:42 +00:00
fix(compositor): clear stale viewport destination on buffer resize
This commit is contained in:
1 parent
d7898360e3
commit
3975feb198
1 file changed
+10
@@ -1000,6 +1000,11 @@ static void take_shm(struct surface *s, struct wl_shm_buffer *shm, struct wl_res
|
||||
s->buf_alpha = wl_shm_buffer_get_format(shm) == WL_SHM_FORMAT_ARGB8888;
|
||||
s->black_fill = 0;
|
||||
s->has_content = s->shm_img != NULL;
|
||||
if (s->dst_set && !s->src_set && (s->dst[0] != w || s->dst[1] != h)) {
|
||||
s->dst_set = 0;
|
||||
s->dst[0] = -1;
|
||||
s->dst[1] = -1;
|
||||
}
|
||||
g_stat_shm++;
|
||||
struct client_info *ci = client_info_of(wl_resource_get_client(s->resource));
|
||||
if (ci && ci->asked_feedback) ci->shm_frames++;
|
||||
@@ -1083,6 +1088,11 @@ static void take_dmabuf(struct surface *s, struct dmabuf_buffer *b, struct wl_re
|
||||
s->buf_h = b->height;
|
||||
s->buf_alpha = (b->format & 0xff) == 'A';
|
||||
s->has_content = b->img != NULL;
|
||||
if (s->dst_set && !s->src_set && (s->dst[0] != b->width || s->dst[1] != b->height)) {
|
||||
s->dst_set = 0;
|
||||
s->dst[0] = -1;
|
||||
s->dst[1] = -1;
|
||||
}
|
||||
if (!repeat) g_stat_dmabuf++;
|
||||
const int announced_now = !s->announced_vulkan;
|
||||
if (!s->announced_vulkan) {
|
||||
|
||||
Reference in new issue
Block a user