From f9041230c65e15e6bb1260445ba06456d855dd48 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Sat, 23 Feb 2019 04:50:25 +0100 Subject: [PATCH] gl renderer: Round size up when rendering to a texture Both the clip we use and the viewport we set should contain the entire texture size and not potentially clip the last pixel. --- gsk/gl/gskglrenderer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gsk/gl/gskglrenderer.c b/gsk/gl/gskglrenderer.c index 27df97fc9e..24f5452491 100644 --- a/gsk/gl/gskglrenderer.c +++ b/gsk/gl/gskglrenderer.c @@ -2458,8 +2458,8 @@ add_offscreen_ops (GskGLRenderer *self, guint flags) { const float scale = ops_get_scale (builder); - const float width = bounds->size.width * scale; - const float height = bounds->size.height * scale; + const float width = ceilf (bounds->size.width * scale); + const float height = ceilf (bounds->size.height * scale); const float dx = builder->dx; const float dy = builder->dy; int render_target;