[gtk/wip/chergert/glproto: 797/920] add helper to lookup texture by id
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/chergert/glproto: 797/920] add helper to lookup texture by id
- Date: Mon, 8 Feb 2021 19:15:42 +0000 (UTC)
commit ebbbbc0db92d92b3f8c692cc811c028cb1b8ed56
Author: Christian Hergert <chergert redhat com>
Date: Thu Jan 28 16:18:17 2021 -0800
add helper to lookup texture by id
gsk/next/gskgldriverprivate.h | 7 +++++++
1 file changed, 7 insertions(+)
---
diff --git a/gsk/next/gskgldriverprivate.h b/gsk/next/gskgldriverprivate.h
index c133ac1056..824deae58a 100644
--- a/gsk/next/gskgldriverprivate.h
+++ b/gsk/next/gskgldriverprivate.h
@@ -171,6 +171,13 @@ GskGLTextureAtlas *gsk_next_driver_create_atlas (GskNextDriver *
void gsk_next_driver_save_atlases_to_png (GskNextDriver *self,
const char *directory);
+static inline GskGLTexture *
+gsk_next_driver_get_texture_by_id (GskNextDriver *self,
+ guint texture_id)
+{
+ return g_hash_table_lookup (self->textures, GUINT_TO_POINTER (texture_id));
+}
+
G_END_DECLS
#endif /* __GSK_GL_DRIVER_PRIVATE_H__ */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]