stage: Paint the untransformed swap region
Painting the swap region with CLUTTER_DEBUG_PAINT_DAMAGE_REGION happens on the view framebuffer, so don't transform the region we paint to the onscreen. Fixes the swap region painting on rotated monitors. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2590>
This commit is contained in:
parent
c89bae8594
commit
73695995a7
@ -633,17 +633,6 @@ meta_stage_impl_redraw_view_primary (MetaStageImpl *stage_impl,
|
|||||||
COGL_TRACE_BEGIN_SCOPED (MetaStageImplRedrawViewSwapFramebuffer,
|
COGL_TRACE_BEGIN_SCOPED (MetaStageImplRedrawViewSwapFramebuffer,
|
||||||
"Paint (swap framebuffer)");
|
"Paint (swap framebuffer)");
|
||||||
|
|
||||||
if (clutter_stage_view_get_onscreen (stage_view) !=
|
|
||||||
clutter_stage_view_get_framebuffer (stage_view))
|
|
||||||
{
|
|
||||||
cairo_region_t *transformed_swap_region;
|
|
||||||
|
|
||||||
transformed_swap_region =
|
|
||||||
transform_swap_region_to_onscreen (stage_view, swap_region);
|
|
||||||
cairo_region_destroy (swap_region);
|
|
||||||
swap_region = transformed_swap_region;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (queued_redraw_clip)
|
if (queued_redraw_clip)
|
||||||
{
|
{
|
||||||
cairo_region_t *swap_region_in_stage_space;
|
cairo_region_t *swap_region_in_stage_space;
|
||||||
@ -663,6 +652,17 @@ meta_stage_impl_redraw_view_primary (MetaStageImpl *stage_impl,
|
|||||||
cairo_region_destroy (swap_region_in_stage_space);
|
cairo_region_destroy (swap_region_in_stage_space);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (clutter_stage_view_get_onscreen (stage_view) !=
|
||||||
|
clutter_stage_view_get_framebuffer (stage_view))
|
||||||
|
{
|
||||||
|
cairo_region_t *transformed_swap_region;
|
||||||
|
|
||||||
|
transformed_swap_region =
|
||||||
|
transform_swap_region_to_onscreen (stage_view, swap_region);
|
||||||
|
cairo_region_destroy (swap_region);
|
||||||
|
swap_region = transformed_swap_region;
|
||||||
|
}
|
||||||
|
|
||||||
swap_framebuffer (stage_window,
|
swap_framebuffer (stage_window,
|
||||||
stage_view,
|
stage_view,
|
||||||
swap_region,
|
swap_region,
|
||||||
|
Loading…
Reference in New Issue
Block a user