vulkan: Add visible fallback rendering

Hook up the "Show fallback rendering" switch for Vulkan.

This brings home the sobering truth that the Vulkan renderer
is doing *all* fallback, since we switched from offset nodes
to transform nodes.
This commit is contained in:
Matthias Clasen
2021-03-05 18:39:22 -05:00
parent 3aa89efcf4
commit dbb264dfc9

View File

@@ -859,6 +859,25 @@ gsk_vulkan_render_pass_upload_fallback (GskVulkanRenderPass *self,
gsk_render_node_draw (node, cr);
#ifdef G_ENABLE_DEBUG
if (GSK_RENDERER_DEBUG_CHECK (gsk_vulkan_render_get_renderer (render), FALLBACK))
{
cairo_rectangle (cr,
op->clip.bounds.origin.x, op->clip.bounds.origin.y,
op->clip.bounds.size.width, op->clip.bounds.size.height);
if (gsk_render_node_get_node_type (node) == GSK_CAIRO_NODE)
cairo_set_source_rgba (cr, 0.3, 0, 1, 0.25);
else
cairo_set_source_rgba (cr, 1, 0, 0, 0.25);
cairo_fill_preserve (cr);
if (gsk_render_node_get_node_type (node) == GSK_CAIRO_NODE)
cairo_set_source_rgba (cr, 0.3, 0, 1, 1);
else
cairo_set_source_rgba (cr, 1, 0, 0, 1);
cairo_stroke (cr);
}
#endif
cairo_destroy (cr);
op->source = gsk_vulkan_image_new_from_data (uploader,