offload: Add more debug spew
Print what transform we are passing to the compositor. Helps for debugging transforms.
This commit is contained in:
committed by
Benjamin Otte
parent
4f2b639a24
commit
e68f58940c
@@ -247,6 +247,14 @@ gdk_texture_transform_to_wl (GdkDihedral transform)
|
|||||||
return (enum wl_output_transform) transform;
|
return (enum wl_output_transform) transform;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static inline const char *
|
||||||
|
transform_name (GdkDihedral transform)
|
||||||
|
{
|
||||||
|
const char *name[] = { "normal", "90", "180", "270", "flipped", "flipped 90", "flipped 180", "flipped 270" };
|
||||||
|
|
||||||
|
return name[transform];
|
||||||
|
}
|
||||||
|
|
||||||
static inline GdkDihedral
|
static inline GdkDihedral
|
||||||
wl_output_transform_to_gdk (enum wl_output_transform transform)
|
wl_output_transform_to_gdk (enum wl_output_transform transform)
|
||||||
{
|
{
|
||||||
@@ -503,7 +511,7 @@ gdk_wayland_subsurface_attach (GdkSubsurface *sub,
|
|||||||
}
|
}
|
||||||
|
|
||||||
GDK_DISPLAY_DEBUG (gdk_surface_get_display (sub->parent), OFFLOAD,
|
GDK_DISPLAY_DEBUG (gdk_surface_get_display (sub->parent), OFFLOAD,
|
||||||
"[%p] %s Attaching texture (%dx%d) at %d %d %d %d",
|
"[%p] %s Attaching texture (%dx%d) at %d %d %d %d%s%s%s",
|
||||||
self,
|
self,
|
||||||
will_be_above
|
will_be_above
|
||||||
? (has_background ? "▲" : "△")
|
? (has_background ? "▲" : "△")
|
||||||
@@ -511,7 +519,11 @@ gdk_wayland_subsurface_attach (GdkSubsurface *sub,
|
|||||||
gdk_texture_get_width (texture),
|
gdk_texture_get_width (texture),
|
||||||
gdk_texture_get_height (texture),
|
gdk_texture_get_height (texture),
|
||||||
self->dest.x, self->dest.y,
|
self->dest.x, self->dest.y,
|
||||||
self->dest.width, self->dest.height);
|
self->dest.width, self->dest.height,
|
||||||
|
transform != GDK_DIHEDRAL_NORMAL ? " (" : "",
|
||||||
|
transform != GDK_DIHEDRAL_NORMAL ? transform_name (transform): "",
|
||||||
|
transform != GDK_DIHEDRAL_NORMAL ? " )" : ""
|
||||||
|
);
|
||||||
result = TRUE;
|
result = TRUE;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user