mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-12 11:50:21 +00:00
memoryformat: Add a debug helper
I need this often enough that I'll just put it here.
This commit is contained in:
parent
f2ccba0988
commit
fd78bd3eaf
@ -1524,6 +1524,14 @@ gdk_memory_format_get_depth (GdkMemoryFormat format,
|
||||
return depth;
|
||||
}
|
||||
|
||||
const char *
|
||||
gdk_memory_depth_get_name (GdkMemoryDepth depth)
|
||||
{
|
||||
const char *names[] = { "none", "u8", "u8-srgb", "u16", "f16", "f32" };
|
||||
|
||||
return names[depth];
|
||||
}
|
||||
|
||||
/*<private>
|
||||
* gdk_memory_depth_merge:
|
||||
* @depth1: the first depth
|
||||
|
@ -66,6 +66,7 @@ GdkMemoryDepth gdk_memory_depth_merge (GdkMemoryDepth
|
||||
GdkMemoryDepth depth2) G_GNUC_CONST;
|
||||
GdkMemoryFormat gdk_memory_depth_get_format (GdkMemoryDepth depth) G_GNUC_CONST;
|
||||
GdkMemoryFormat gdk_memory_depth_get_alpha_format (GdkMemoryDepth depth) G_GNUC_CONST;
|
||||
const char * gdk_memory_depth_get_name (GdkMemoryDepth depth);
|
||||
void gdk_memory_format_gl_format (GdkMemoryFormat format,
|
||||
gboolean gles,
|
||||
GLint *out_internal_format,
|
||||
|
Loading…
Reference in New Issue
Block a user