From 4d07a1c213d5b3396b9e140c139e9a6423400947 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Kristian=20H=C3=B8gsberg?= Date: Fri, 6 May 2011 14:03:12 -0400 Subject: [PATCH] compositor: Scanout client buffers even if they're not map_fullscreen --- compositor/compositor-drm.c | 4 +++- compositor/compositor.c | 22 +++++++++++----------- 2 files changed, 14 insertions(+), 12 deletions(-) diff --git a/compositor/compositor-drm.c b/compositor/compositor-drm.c index 2902168..eb452ab 100644 --- a/compositor/compositor-drm.c +++ b/compositor/compositor-drm.c @@ -144,7 +144,9 @@ drm_output_prepare_scanout_surface(struct wlsc_output *output_base, int ret; uint32_t fb_id = 0; - if (es->width != output->base.width || + if (es->x != output->base.x || + es->y != output->base.y || + es->width != output->base.width || es->height != output->base.height || es->image == EGL_NO_IMAGE_KHR) return -1; diff --git a/compositor/compositor.c b/compositor/compositor.c index 15dc600..22bb9a8 100644 --- a/compositor/compositor.c +++ b/compositor/compositor.c @@ -703,19 +703,19 @@ wlsc_output_repaint(struct wlsc_output *output) using_hardware_cursor = 0; es = container_of(ec->surface_list.next, struct wlsc_surface, link); - if (es->fullscreen_output == output) { - if (es->visual == &ec->compositor.rgb_visual && - using_hardware_cursor) { - if (output->prepare_scanout_surface(output, es) == 0) { - /* We're drawing nothing now, - * draw the damaged regions later. */ - pixman_region32_union(&ec->damage_region, - &ec->damage_region, - &total_damage); - return; - } + + if (es->visual == &ec->compositor.rgb_visual && using_hardware_cursor) { + if (output->prepare_scanout_surface(output, es) == 0) { + /* We're drawing nothing now, + * draw the damaged regions later. */ + pixman_region32_union(&ec->damage_region, + &ec->damage_region, + &total_damage); + return; } + } + if (es->fullscreen_output == output) { if (es->width < output->width || es->height < output->height) glClear(GL_COLOR_BUFFER_BIT); -- 2.7.4