mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-15 05:00:09 +00:00
f1d44635bd
This fixes two issues with the offscreen rendering code for nodes with bounds not aligned with the pixel grid: 1.) When drawing to an offscreen buffer the size of the offscreen buffer was rounded up, but then later when used as texture the vertices correspond to the original bounds with the unrounded size. This could then result in the offscreen texture being drawn onscreen at a slightly smaller size, which then lead to it being visually shifted and blurry. This is fixed by adjusting the u/v coordinates to ignore the padding region in the offscreen texture that got added by the size increase from rounding. 2.) The viewport used when rendering to the offscreen buffer was not aligned with the pixel grid for nodes at coordinates not aligned with the pixel grid. Then because the content of the offscreen buffer is not aligned with the pixel grid and later when used as textures sampling from it will result in interpolated values for an onscreen pixel. This could also result in shifting and blurriness, especially for nested offscreen rendering at different offsets. This is fixed by adding similar padding at the beginning of the texture and also adjusting the u/v coordinates to ignore this region. Fixes: https://gitlab.gnome.org/GNOME/gtk/-/issues/3833 |
||
---|---|---|
.. | ||
broadway | ||
gl | ||
vulkan | ||
gen-gsk-gresources-xml.py | ||
gsk-autocleanup.h | ||
gsk.h | ||
gskcairoblur.c | ||
gskcairoblurprivate.h | ||
gskcairorenderer.c | ||
gskcairorenderer.h | ||
gskdebug.c | ||
gskdebugprivate.h | ||
gskdiff.c | ||
gskdiffprivate.h | ||
gskenums.h | ||
gskenumtypes.c.template | ||
gskenumtypes.h.template | ||
gskglshader.c | ||
gskglshader.h | ||
gskglshaderprivate.h | ||
gskprivate.c | ||
gskprivate.h | ||
gskprofiler.c | ||
gskprofilerprivate.h | ||
gskrenderer.c | ||
gskrenderer.h | ||
gskrendererprivate.h | ||
gskrendernode.c | ||
gskrendernode.h | ||
gskrendernodeimpl.c | ||
gskrendernodeparser.c | ||
gskrendernodeparserprivate.h | ||
gskrendernodeprivate.h | ||
gskroundedrect.c | ||
gskroundedrect.h | ||
gskroundedrectprivate.h | ||
gsktransform.c | ||
gsktransform.h | ||
gsktransformprivate.h | ||
gsktypes.h | ||
meson.build |