[gtk/wip/chergert/glproto: 275/526] fix rouneded rect transform
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/chergert/glproto: 275/526] fix rouneded rect transform
- Date: Tue, 16 Feb 2021 01:14:31 +0000 (UTC)
commit 2cfca8bcf54055eec488f5ff1bdd203ca1cf44f7
Author: Christian Hergert <chergert redhat com>
Date: Wed Jan 20 10:55:48 2021 -0800
fix rouneded rect transform
gsk/next/gskglrenderjob.c | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
---
diff --git a/gsk/next/gskglrenderjob.c b/gsk/next/gskglrenderjob.c
index 1997e3a774..fbc3677009 100644
--- a/gsk/next/gskglrenderjob.c
+++ b/gsk/next/gskglrenderjob.c
@@ -630,8 +630,14 @@ gsk_gl_render_job_transform_rounded_rect (GskGLRenderJob *job,
const GskRoundedRect *rect,
GskRoundedRect *out_rect)
{
- gsk_gl_render_job_transform_bounds (job, &rect->bounds, &out_rect->bounds);
- memcpy (out_rect->corner, rect->corner, sizeof out_rect->corner);
+ out_rect->bounds.origin.x = job->offset_x + rect->bounds.origin.x;
+ out_rect->bounds.origin.y = job->offset_y + rect->bounds.origin.y;
+ out_rect->bounds.size.width = rect->bounds.size.width;
+ out_rect->bounds.size.height = rect->bounds.size.height;
+ out_rect->corner[0] = rect->corner[0];
+ out_rect->corner[1] = rect->corner[1];
+ out_rect->corner[2] = rect->corner[2];
+ out_rect->corner[3] = rect->corner[3];
}
static inline gboolean
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]