[gtk/wip/baedert/for-master] gdkgl: Remove flipping in draw_from_gl()



commit 7c704f09fb92bc5a3d81267d6d29fe0b0f1bceea
Author: Timm Bäder <mail baedert org>
Date:   Tue Sep 29 19:31:01 2020 +0200

    gdkgl: Remove flipping in draw_from_gl()

 gdk/gdkgl.c        | 4 ----
 gdk/gdkgltexture.c | 2 --
 2 files changed, 6 deletions(-)
---
diff --git a/gdk/gdkgl.c b/gdk/gdkgl.c
index 7ac9f2b320..5d91a3cecd 100644
--- a/gdk/gdkgl.c
+++ b/gdk/gdkgl.c
@@ -421,10 +421,6 @@ gdk_cairo_draw_from_gl (cairo_t              *cr,
 
   cairo_surface_mark_dirty (image);
 
-  /* Invert due to opengl having different origin */
-  cairo_scale (cr, 1, -1);
-  cairo_translate (cr, 0, -height / buffer_scale);
-
   cairo_set_source_surface (cr, image, 0, 0);
   cairo_set_operator (cr, CAIRO_OPERATOR_OVER);
   cairo_paint (cr);
diff --git a/gdk/gdkgltexture.c b/gdk/gdkgltexture.c
index bd1426e119..8161bc06fa 100644
--- a/gdk/gdkgltexture.c
+++ b/gdk/gdkgltexture.c
@@ -95,8 +95,6 @@ gdk_gl_texture_download (GdkTexture         *texture,
 
       gl_surface = gdk_gl_context_get_surface (self->context);
 
-      cairo_scale (cr, 1, -1);
-      cairo_translate (cr, 0, - area->height);
       gdk_cairo_draw_from_gl (cr, gl_surface, self->id, GL_TEXTURE, 1,
                               area->x, area->y,
                               area->width, area->height);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]