a-parhom / RoundedSBE

A fork of SierraBreezeEnhanced with integrated corner rounding effect CornersShader (reworked version of what used to be called LightlyShaders) and shared configuration
GNU General Public License v3.0
67 stars 3 forks source link

Window blurriness every other pixel when using Fractional Scaling on Wayland with rounding shaders #18

Open jkcdarunday opened 1 year ago

jkcdarunday commented 1 year ago

Enabling shaders on Wayland desktops that use fractional scaling (150%) causes visible blurriness every time windows are moved one pixel sidewards (then becomes clear again every other pixel).

Here are some screenshots but it might not be too obvious due to github resizing / browser scaling but much more obvious irl since it seems to affect subpixel rendering.

How it looks without the shaders enabled in Desktop Effects / normally:

How it looks with shaders / every odd pixels sidewards:

The ff. zip contains the lossless png images of the screenshots. Viewing with feh seems to be work well in showing the differences. rounded-fractional-blur-bug.zip

Here are my versions: Operating System: Arch Linux KDE Plasma Version: 5.27.7 KDE Frameworks Version: 5.108.0 Qt Version: 5.15.10 Kernel Version: 6.4.9-arch1-1 (64-bit) Graphics Platform: Wayland Processors: 32 × AMD Ryzen 9 7950X 16-Core Processor Memory: 58.5 GiB of RAM Graphics Processor: AMD Radeon Graphics RoundedSBE-git version: 5.27.4.r233.4f71ab0-1 (from AUR)

jkcdarunday commented 1 year ago

Not sure if directly related but I remember having a similar issue a few Plasma versions ago and reading discussions about off-by-one issues caused by non-standardized integer rounding. I've only been trying out Wayland back then but it eventually got fixed.

So it's possible that a similar integer rounding issue happens in the shader code as it deals with fractional scaling.