[gtk+] gsk: Handle GL textures



commit 31fcf5b3a72ac6a7013f517fe501348c002429cd
Author: Matthias Clasen <mclasen redhat com>
Date:   Wed Jan 17 00:52:15 2018 -0500

    gsk: Handle GL textures
    
    These textures already have a GL texture in them,
    no need to create a new one.

 gsk/gl/gskgldriver.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
---
diff --git a/gsk/gl/gskgldriver.c b/gsk/gl/gskgldriver.c
index 3d858e7..6d1c417 100644
--- a/gsk/gl/gskgldriver.c
+++ b/gsk/gl/gskgldriver.c
@@ -370,6 +370,9 @@ gsk_gl_driver_get_texture_for_texture (GskGLDriver *driver,
   Texture *t;
   cairo_surface_t *surface;
 
+  if (GDK_IS_GL_TEXTURE (texture))
+    return gdk_gl_texture_get_id (GDK_GL_TEXTURE (texture));
+
   t = gdk_texture_get_render_data (texture, driver);
 
   if (t)


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