gl: Handle GDK_MEMORY_NONE depth

In rare circumstances a rendernode can be MEMORY_NONE and we don't want
to render it as a float texture then.
This commit is contained in:
Benjamin Otte 2024-09-02 00:20:35 +02:00
parent 6a1cd87480
commit e29701a203

View File

@ -407,7 +407,8 @@ gsk_gl_renderer_render_texture (GskRenderer *renderer,
/* Don't use float textures for SRGB or node-editor turns on high
* depth unconditionally. */
if (gsk_render_node_get_preferred_depth (root) != GDK_MEMORY_U8 &&
if (gsk_render_node_get_preferred_depth (root) != GDK_MEMORY_NONE &&
gsk_render_node_get_preferred_depth (root) != GDK_MEMORY_U8 &&
gsk_render_node_get_preferred_depth (root) != GDK_MEMORY_U8_SRGB &&
gdk_gl_context_check_version (self->context, "3.0", "3.0"))
{