From: Benjamin Otte Date: Mon, 13 Feb 2023 00:23:28 +0000 (+0100) Subject: rendernode: Don't do unnecessary stuff X-Git-Tag: archive/raspbian/4.12.3+ds-1+rpi1~1^2^2^2~22^2~6^2~2^2~5 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=88dd64551cbb82983f780c3e8c9b6b6ebcb1ae7d;p=gtk4.git rendernode: Don't do unnecessary stuff Cairo surfaces are created transparent. And even if they weren't, overdrawing with transparency wouldn't erase what's in the surface because it's a no-op. It would require CAIRO_OPERATOR_CLEAR or CAIRO_OPERATOR_SOURCE. --- diff --git a/gsk/gskrendernodeimpl.c b/gsk/gskrendernodeimpl.c index 089b2e9ead..a84085c9c6 100644 --- a/gsk/gskrendernodeimpl.c +++ b/gsk/gskrendernodeimpl.c @@ -1631,9 +1631,6 @@ gsk_texture_scale_node_draw (GskRenderNode *node, (int) ceilf (node->bounds.size.height)); cr2 = cairo_create (surface2); - cairo_set_source_rgba (cr2, 0, 0, 0, 0); - cairo_paint (cr2); - surface = gdk_texture_download_surface (self->texture); pattern = cairo_pattern_create_for_surface (surface); cairo_pattern_set_extend (pattern, CAIRO_EXTEND_PAD);