gdk: Add gdk_surface_get_gl_is_srgb()

This is a way to query whether the framebuffer we use is using GL_SRGB
or equivalent. Currently, it just returns FALSE.
This commit is contained in:
Matthias Clasen 2024-06-18 14:31:30 -04:00 committed by Benjamin Otte
parent de76045939
commit dfd181d7d5
2 changed files with 9 additions and 0 deletions

View File

@ -1168,6 +1168,12 @@ gdk_surface_ensure_egl_surface (GdkSurface *self,
#endif
}
gboolean
gdk_surface_get_gl_is_srgb (GdkSurface *self)
{
return self->is_srgb;
}
GdkGLContext *
gdk_surface_get_paint_gl_context (GdkSurface *surface,
GError **error)

View File

@ -71,6 +71,7 @@ struct _GdkSurface
guint shortcuts_inhibited : 1;
guint request_motion : 1;
guint has_pointer : 1;
guint is_srgb : 1;
guint request_motion_id;
@ -303,6 +304,8 @@ void gdk_surface_ensure_egl_surface (GdkSurface
GdkMemoryDepth depth);
gpointer /*EGLSurface*/ gdk_surface_get_egl_surface (GdkSurface *self);
gboolean gdk_surface_get_gl_is_srgb (GdkSurface *self);
void gdk_surface_set_widget (GdkSurface *self,
gpointer widget);
gpointer gdk_surface_get_widget (GdkSurface *self);