From c591e60ebdcc387360856d2732115a1b9444a674 Mon Sep 17 00:00:00 2001 From: Martijn Braam Date: Sat, 28 Nov 2020 16:21:32 +0100 Subject: [PATCH] Add black background behind preview --- main.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/main.c b/main.c index 4ea876d..8dfe283 100644 --- a/main.c +++ b/main.c @@ -297,10 +297,15 @@ preview_draw(GtkWidget *widget, cairo_t *cr, gpointer data) return FALSE; } + // Clear preview area with black + cairo_paint(cr); + + // Draw camera preview if (surface) { draw_surface_scaled_centered(cr, preview_width, preview_height, surface); } + // Draw control overlay cairo_set_source_surface(cr, status_surface, 0, 0); cairo_paint(cr); return FALSE;