WillPower3309 / swayfx

SwayFX: Sway, but with eye candy!
MIT License
1.29k stars 48 forks source link

Artifacts when a floating window goes over a layer with effects enabled #165

Closed WillPower3309 closed 1 year ago

WillPower3309 commented 1 year ago

If you make a window float, then drag it onto waybar, you can see the artifacts in the first image. if you deselect the window (click on wallpaper for example), the artifacts disappear.

2023-05-23_21-05-1684893397

2023-05-23_21-05-1684893408

ErikReider commented 1 year ago

https://github.com/WillPower3309/swayfx/blob/6402611e5a472e08e2212fecc286020f991de4da/sway/config.c#L1097-L1099

Is the cause. It underestimates the blur size.

Wayfire uses this but it is a bit overkill:

pow(2, config->blur_params.num_passes + 1) * config->blur_params.radius
ErikReider commented 1 year ago

Nvm, found the bug. We destroy the main buffer on render end which gives the blur less data to work with (everything outside of the damage is black).

I'll post a PR soon ish