yilozt / rounded-window-corners

A gnome-shell extensions that try to add rounded corners for all windows
GNU General Public License v3.0
464 stars 47 forks source link

No blur effect? #77

Open Kyanoxia opened 2 years ago

Kyanoxia commented 2 years ago

In the mutter-rounded repo, there was a blur effect that you could turn for with some windows. Could you add it to the extension? I know about Blur My Shell, but there are artifacts even on the "no artifacts" hack mode (a vertical line on gnome-terminal-transparency).

yilozt commented 2 years ago

Actually, I have try to add blur effect to this extensions in early stage, most of code from mutter-rounded can be move into this extensions, except the core thing: the blur effect.

The blur effect that mutter-rounded using is a patched version of shell-blur-effect.c from Gnome Shell project, it just replace original shader with a rounded corners shader:

https://github.com/yilozt/mutter-rounded/blob/0b444bf17323bae193fc6ce09ee8596ffff10e67/patches/shell_blur_effect.patch#L57-L64

The patched blur effect can't rewrite with JavaScript, it's means that there is no way to add rounded corners to blur effect to gnome-shell extensions in normal way.

But it's still possible to add blur effect with rounded corners to this extensions, but this features is not out of box, we still need to compile one C files into an dynamic library the let gnome-shell extensions to load it. (btw, a least we needn't compile whole mutter project.)

I have add it in early commit of this project, it can load compiled blur effect and works. But I remove it before v1 released because I can't ship C code in a gnome-extensions (the extensions that publish to extensions.gnome.org can only be writing in JavaScript), another reason is this project are not completed yet in that time:

https://extensions.gnome.org/review/33389

so I remove it in commit d3bc70, but also leave a backup copy in branch blur-effect-with-rounded-corners.

Now we can add it back, but the C language part (the blur effect) will not be included into released extensions pack (the released zip file). If you want to add blur effect, you have to clone this project, compile, then let extensions load it, also we can write an setup wiki page, or build script (like mutter-rounded did)to help user use it.

My idea is compile the blur effect as dynamic library into ~/.local/share/rounded-window-corners, then let extensions load dynamic library from this position. If users want to uninstall blur effect, just remove this directory.

yilozt commented 2 years ago

Btw because now we can using blur effect in gnome-shell, so we can keep blur effect in overview and in the animation of switching workspace for windows, the blur effect even can works with Desktop-Cube

hrqmonteiro commented 2 years ago

Actually, I have try to add blur effect to this extensions in early stage, most of code from mutter-rounded can be move into this extensions, except the core thing: the blur effect.

The blur effect that mutter-rounded using is a patched version of shell-blur-effect.c from Gnome Shell project, it just replace original shader with a rounded corners shader:

https://github.com/yilozt/mutter-rounded/blob/0b444bf17323bae193fc6ce09ee8596ffff10e67/patches/shell_blur_effect.patch#L57-L64

The patched blur effect can't rewrite with JavaScript, it's means that there is no way to add rounded corners to blur effect to gnome-shell extensions in normal way.

But it's still possible to add blur effect with rounded corners to this extensions, but this features is not out of box, we still need to compile one C files into an dynamic library the let gnome-shell extensions to load it. (btw, a least we needn't compile whole mutter project.)

I have add it in early commit of this project, it can load compiled blur effect and works. But I remove it before v1 released because I can't ship C code in a gnome-extensions (the extensions that publish to extensions.gnome.org can only be writing in JavaScript), another reason is this project are not completed yet in that time:

https://extensions.gnome.org/review/33389

so I remove it in commit d3bc70, but also leave a backup copy in branch blur-effect-with-rounded-corners.

Now we can add it back, but the C language part (the blur effect) will not be included into released extensions pack (the released zip file). If you want to add blur effect, you have to clone this project, compile, then let extensions load it, also we can write an setup wiki page, or build script (like mutter-rounded did)to help user use it.

My idea is compile the blur effect as dynamic library into ~/.local/share/rounded-window-corners, then let extensions load dynamic library from this position. If users want to uninstall blur effect, just remove this directory.

How exactly would one do that? I installed the extensions through this branch you mentioned and nothing changed, i still don't have the blur effect option.

Could you please provide a more thoroughly guide, please?

yilozt commented 2 years ago

Very sorry that I have rebase the branch blur-effect-with-rounded-corners, because I am trying to add blur effect back to main branch.

If you want to taste blur effect, there is still the old version of this extensions in Github Action: https://github.com/yilozt/rounded-window-corners/actions/runs/2752319666

Then you can see the setup guide in Experimental area after open preference page:

截图 2022-07-25 23-27-27

Notice that this is very old version, it may can't work. I will open a PR when I move all old code to new version.

hrqmonteiro commented 2 years ago

Yeah, unfortunately you are right.

I installed it and ran through all of the setup guide, and no errors showed up, but when i try to set the blur it doesn't make any difference.

Screenshot from 2022-10-13 11-49-25 Screenshot from 2022-10-13 11-50-23

But thank you for your effort, this would be amazing, i will wait for the code to arrive and i will be the first one to try. I was using the blur with mutter-rounded and i simply love it!

kaykhan commented 1 year ago

This extension does not seem to work with "blur My Shell" it seems to break the blurring effect.

CorvetteCole commented 1 year ago

Developer from Blur My Shell here, would love help figuring out if we can use some of what you've worked on to round our blur actors. Have not figured out a way to do that yet, big issue for us: https://github.com/aunetx/blur-my-shell/issues/8

itsmenewbie03 commented 11 months ago

Recently switched to this extension after using mutter-rounded for quite some time. I liked the blur feature before, is there no updates with this?