[gtk/big-glyphs: 5/6] Add code to dump out the glyph caches



commit 5cf90261a373a0b4bcc646cf90de01de3f5fdf9e
Author: Matthias Clasen <mclasen redhat com>
Date:   Sun Jun 2 22:22:17 2019 +0000

    Add code to dump out the glyph caches

 gsk/gl/gskglglyphcache.c | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)
---
diff --git a/gsk/gl/gskglglyphcache.c b/gsk/gl/gskglglyphcache.c
index 6e81b1b793..8f80ac6552 100644
--- a/gsk/gl/gskglglyphcache.c
+++ b/gsk/gl/gskglglyphcache.c
@@ -446,4 +446,20 @@ gsk_gl_glyph_cache_begin_frame (GskGLGlyphCache *self)
     }
 
   g_hash_table_unref (removed);
+
+#if 0
+  for (i = 0; i < self->atlases->len; i++)
+    {
+      GskGLGlyphAtlas *atlas = g_ptr_array_index (self->atlases, i);
+
+      if (atlas->image)
+        {
+          char *filename;
+
+          filename = g_strdup_printf ("glyphatlas%d-%ld.png", i, self->timestamp);
+          gsk_gl_image_write_to_png (atlas->image, self->gl_driver, filename);
+          g_free (filename);
+        }
+    }
+#endif
 }


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