1
0
Fork 0
mutter-performance-source/src
Jonas Ådahl 8beef8ccd0 shaped-texture: Fix use-nearest check when viewports are scaled
We checked that the content size was appropriately painted in the stage,
but didn't take into account that the size of the sampled texture
region, meaning that when stage views were scaled, we'd think that we
would draw a texture scaled, as e.g. a 200x200 sized texture with buffer
scale 2 would have the size 100x100. When stage views were not scaled,
we'd apply a geometry scale meaning it'd end up as 200x200 anyway, thus
pass the check, but when stage views are scaled, it'd still be painted
as a 100x100 shaped texture on the stage, thus failing the
are-we-unscaled test.

Fix this by comparing the transformed paint size with the sampled size,
instead of the paint size again, when checking whether we are being
painted scaled or not. For example, when stage views are scaled, our
200x200 buffer with buffer scale 2, thus content size 100x100 will
transform to a 200x200 paint command, thus passing the test. For
non-scaled stage views, our 200x200 buffer with buffer scale 2 thus
content size 100x100 will also transform into a 200x200 paint command,
and will also pass the check, as the texture sample region is still
200x200.

Fixes: https://gitlab.gnome.org/GNOME/mutter/issues/804

https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1124
2020-03-26 08:32:46 +00:00
..
backends crtc-xrandr: Respect configured RANDR panning 2020-03-26 09:24:25 +01:00
compositor shaped-texture: Fix use-nearest check when viewports are scaled 2020-03-26 08:32:46 +00:00
core cogl: Install cogl-trace.h and include from cogl.h 2020-03-26 09:05:38 +01:00
meta Add MetaGravity and replace X11 equivalent with it 2020-02-29 21:01:50 +00:00
tests monitor-manager: Remove 'mirror' capability 2020-03-18 00:46:20 +00:00
ui frame: Pass the frame area for get_mask() 2020-01-29 10:44:50 +00:00
wayland cogl: Install cogl-trace.h and include from cogl.h 2020-03-26 09:05:38 +01:00
x11 cogl: Install cogl-trace.h and include from cogl.h 2020-03-26 09:05:38 +01:00
libmutter.pc.in build: Fix libs and cflags in autotools .pc file 2018-11-10 16:20:46 +00:00
meson.build backends: Add MetaInputDevice derivable class 2020-03-24 18:07:31 +00:00
meta-marshal.list cursor-tracker: Use our own marshal for cursor-moved 2019-07-31 09:34:17 +00:00
org.freedesktop.login1.xml MetaLauncher: Don't g_error() on failure 2015-11-06 17:03:59 -05:00
org.gnome.Mutter.DisplayConfig.xml fixed typo 2018-07-24 13:16:36 +00:00
org.gnome.Mutter.IdleMonitor.xml idle-monitor: Add ResetIdletime API, for testing purposes 2018-04-16 13:28:03 +02:00
org.gnome.Mutter.RemoteDesktop.xml Fix typo in RemoteDesktop dbus api 2019-05-22 16:21:57 +02:00
org.gnome.Mutter.ScreenCast.xml screen-cast-session: Add 'disable-animations' property 2020-02-20 10:40:42 +00:00