! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
Zooming doesn't switch to nearest filtering at high zoom levels
Status:
RESOLVED: FIXED

Comments

Description Alistair Buxton 2019-05-12 17:04:45 CEST
In compositor.c recenter_zoomed_area() there is this branch: https://git.xfce.org/xfce/xfwm4/tree/src/compositor.c?id=944769cfeaa459de3e31145e798822e2c63d2b4c#n3272

The intent of this is that at very high zoom levels, the filtering should switch to nearest, ie sharp pixels. The reasoning is that if you zoom in to the point where only 20x20 area is visible, you probably are doing it because you are working on some graphics and need to see the individual pixels are right.

However, in git master this no longer seems to work. You always get linear filtering, ie blurry pixels. I am not sure why. I have traced the code and it is selecting the correct branch.

If the code can't be made to work then the GL_NEAREST branch may as well be removed.
Comment 1 Olivier Fourdan editbugs 2019-05-12 17:46:34 CEST
The default vblank backend is using GLX and that code is not used with GLX, as GL is used for zooming, instead of Xrender.

For GL, GL_LINEAR/GL_NEAREST are used instead of FilterBilinear/FilterNearest.

Try with XPresent (--vblank=xpresent) or even disabling vblank (--vblank=off) to see if that makes a difference.
Comment 2 Olivier Fourdan editbugs 2019-05-12 17:48:47 CEST
Yeah, this is it, GL_NEAREST doesn't give as sharp results as FilterNearest...
Comment 3 Git Bot editbugs 2019-05-12 17:56:57 CEST
Olivier Fourdan referenced this bugreport in commit 14cd399a6e518a52e0d9944711f97e8e1741e2a4

compositor: Apply texture filter for zooming

https://git.xfce.org/xfce/xfwm4/commit?id=14cd399a6e518a52e0d9944711f97e8e1741e2a4
Comment 4 Olivier Fourdan editbugs 2019-05-12 17:57:25 CEST
My bad, that should be fixed now.
Comment 5 Alistair Buxton 2019-05-12 20:00:41 CEST
Works for me now, thanks.

Bug #15392

Reported by:
Alistair Buxton
Reported on: 2019-05-12
Last modified on: 2019-05-12

People

Assignee:
Olivier Fourdan
CC List:
0 users

Version

Version:
unspecified

Attachments

Additional information