From: Matthias Clasen Date: Fri, 10 Mar 2023 23:50:40 +0000 (+0100) Subject: Fix gtk_snapshot_append_scaled_texture X-Git-Tag: archive/raspbian/4.12.3+ds-1+rpi1~1^2^2^2~22^2~5^2~6^2~1 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=118361a085a6be212828fafe1d5f5d63f9caf647;p=gtk4.git Fix gtk_snapshot_append_scaled_texture This was doing the wrong thing with transforms. --- diff --git a/gtk/gtksnapshot.c b/gtk/gtksnapshot.c index bca57eaab2..76005769d8 100644 --- a/gtk/gtksnapshot.c +++ b/gtk/gtksnapshot.c @@ -2054,16 +2054,13 @@ gtk_snapshot_append_scaled_texture (GtkSnapshot *snapshot, const graphene_rect_t *bounds) { GskRenderNode *node; - graphene_rect_t real_bounds; - float scale_x, scale_y, dx, dy; g_return_if_fail (snapshot != NULL); g_return_if_fail (GDK_IS_TEXTURE (texture)); g_return_if_fail (bounds != NULL); - gtk_snapshot_ensure_affine (snapshot, &scale_x, &scale_y, &dx, &dy); - gtk_graphene_rect_scale_affine (bounds, scale_x, scale_y, dx, dy, &real_bounds); - node = gsk_texture_scale_node_new (texture, &real_bounds, filter); + gtk_snapshot_ensure_identity (snapshot); + node = gsk_texture_scale_node_new (texture, bounds, filter); gtk_snapshot_append_node_internal (snapshot, node); }