diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2013-08-18 21:10:26 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2013-08-18 21:10:26 +0100 |
commit | 34e4780c8e9c429a835c8be9c512cfe239241298 (patch) | |
tree | 07b548c700173cdcd0e90d0659c09a6f3d86c4ae /overlay/overlay.c | |
parent | 1c1a2798063df03633dc7dfbd215a37b71dbecd6 (diff) |
overlay: Add a X11 window backend
Useful for remote hosts.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'overlay/overlay.c')
-rw-r--r-- | overlay/overlay.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/overlay/overlay.c b/overlay/overlay.c index 519bf200..b9247b84 100644 --- a/overlay/overlay.c +++ b/overlay/overlay.c @@ -23,6 +23,8 @@ static void overlay_show(cairo_surface_t *surface) { struct overlay *overlay; + cairo_surface_flush(surface); + overlay = cairo_surface_get_user_data(surface, &overlay_key); if (overlay == NULL) return; @@ -511,6 +513,8 @@ int main(int argc, char **argv) ctx.height = 236; ctx.surface = x11_overlay_create(POS_TOP_RIGHT, &ctx.width, &ctx.height); if (ctx.surface == NULL) + ctx.surface = x11_window_create(POS_TOP_RIGHT, &ctx.width, &ctx.height); + if (ctx.surface == NULL) return ENOMEM; init_gpu_top(&ctx, &ctx.gpu_top); |