Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blur opacity #333

Open
MRSS02 opened this issue Jul 21, 2024 · 5 comments
Open

Blur opacity #333

MRSS02 opened this issue Jul 21, 2024 · 5 comments
Labels
enhancement New feature or request

Comments

@MRSS02
Copy link

MRSS02 commented Jul 21, 2024

Please fill out the following:

  • Description:
    I've found out that blur in swayfx automatically reduces the opacity of the windows i have, which is a little bit annoying, because i have windows that aren't fully transparent, and they become too dark (especially when stacked). Is there a way to offer a workaround for this by allowing to change blur opacity?
@MRSS02 MRSS02 added the enhancement New feature or request label Jul 21, 2024
@ozwaldorf
Copy link
Contributor

ozwaldorf commented Jul 21, 2024

Even if you set contrast saturation and brightness all to 1.0, and noise to 0.0 (no effect) for blur?

@MRSS02
Copy link
Author

MRSS02 commented Jul 21, 2024

Even if you set contrast saturation and brightness all to 1.0, and noise to 0.0 (no effect) for blur?

I mean all of those options do work, and seem to work exactly as intended, but none of them affect opacity (and as far as i know they really shouldn't), but i'd want to control blur opacity. In fact in other DEs like kde plasma, for example, I used to use blur with high opacity but with dark gray windows with a relatively low alpha value, so this way what is behind than the window is dark gray tinted but i can still see what is behind, and stacked windows don't get too opaque nor dark.

But now with swayFX, it gets pretty hard to see what is behind when it's already a dark floating window or layer being blurred on top of another; as it seems the blur reduces the transparency of whatever window it is applied by quite a bit.

image

image

So, thus far my workaround for this has been to reduce the opacity (alpha value) of the window backgrounds in the themes i use, so the windows get less dark when blurred as a result, but it is not quite what i really want, since this way the actual window color gets lost even further to the blur color controlled by the brightness setting in the blur (which is linear rather than an RGB value), and floating windows and popups still become actually darker (and way more opaque) than i really want.

Hope i explained well, and thanks for the support.

@MRSS02
Copy link
Author

MRSS02 commented Jul 21, 2024

swayFX

kde

Just so you can see the difference in blur opacity i was talking about... in swayFX i am even testing with a higher blur brightness, but it does not compensate for the higher opacity... stacked windows are still noticeably harder to see behind in swayFX (and even non-stacked windows are more opaque)

In kvantummanager, "intensity" means the same as "brightness"

Also, from my testing, the contrast option is inverted in kvantum compared to swayFX - higher values mean less contrast.

@ozwaldorf
Copy link
Contributor

ozwaldorf commented Jul 21, 2024

The blur should be additive to the window backgrounds opacity value, I prefer to just tweak the apps background opacity directly, like you said you were able to do, as it keeps the rest of ui elements fully opaque. But there is a window opacity window rule that I think does the same thing as kvantum's transparency in the hacks section

set $opacity 0.9
for_window [class=".*"] opacity $opacity
for_window [app_id=".*"] opacity $opacity

You can find more info on the selectors in man 5 sway

@MRSS02
Copy link
Author

MRSS02 commented Jul 21, 2024

I mean i think I didn't explain myself well, i guess, i used kvantum as an example. Kvantum does reduce the kde apps' opacity value, however i didn't mean to say i don't want the swayFX blur to be additive.

I still want to have additive blur, but what I mean to say is that I'd want to control how opaque the blur is, so it doesn't end up making windows that already aren't fully transparent become too opaque.

What kvantum does is indeed to reduce the opacity of certain window backgrounds (however only of ones that are kvantum themed, and it does not affect the ui), and this reduced opacity actually still applies in swayFX for the kvantum themed windows (but the kvantum's blur doesn't apply, of course, since it is controlled by the kwin compositor in plasma).

The difference i was trying to show is that kde's blur doesn't seem to add too much extra opacity to what it does blur, if at all (which is what i intend to achieve in swayFX); while the swayFX's one does seem to do add that extra opacity.

Nonetheless, sadly this suggestion you gave sadly does not really help me achieve my goal, since it seems to mess up with the blur effect itself, affects the ui opacity and also applies to all windows matching a certain set class name pattern, even if the window was fully opaque. See here:
image

In short, what i want is not to reduce window opacity, but rather to reduce how much opacity the blur gives to the window.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants