Bug 243693 - Kwin blur plugin does not transform the blur mask of a window along with the window
Summary: Kwin blur plugin does not transform the blur mask of a window along with the ...
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: general (show other bugs)
Version: unspecified
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-05 21:48 UTC by Ryan Thompson
Modified: 2010-11-02 21:49 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 4.5.2


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ryan Thompson 2010-07-05 21:48:01 UTC
Version:           unspecified (using Devel) 
OS:                Linux

When I use (for example) the Magic Lamp plugin, it deforms a window as it minimizes. However, the blur mask of that window's decoration remains behind exactly where the window was originally for the duration of the animation. This looks silly. It could be fixed by simply disabling blur for the duration of any window-deforming animation. (Incidentally, IIRC this is the approach that Windows uses.) This solution would have the added benefit 

Reproducible: Always

Steps to Reproduce:
1. Enable Desktop Effects.
2. Enable Blur plugin.
3. Enable Magic Lamp plugin.
4. For convenience, set the magic lamp's animation duration to something very large, like 3000 ms.
5. Minimize a window.
6. Watch where the window borders used to be.

Actual Results:  
The areas that used to be covered by the window border will be blurred as if the window had not moved. But the window will not be covereing them, so they will look like ugly artifacts. The blur disappears when the magic lamp animation completes.

Expected Results:  
The blur either disappears or follows the deformation of the window as it minimizes.
Comment 1 Ryan Thompson 2010-07-09 03:42:25 UTC
Actually, this is a little more complicated. It seems that the standard minimize animation does the right thing and disables blur during the animation. You can see this most easily by setting animation speed to "Extremely Slow." (I assume this is the purpose of that setting.) So maybe this is an issue specifically with the magic lamp plugin. Although I seem to recall that the Compiz blur plugin had an option to disable blur during *all* animations. Also, for what it's worth, I believe Windows Vista/7 disable blur during animations.
Comment 2 Martin Flöser 2010-08-28 16:30:16 UTC
SVN commit 1169158 by graesslin:

Exclude all transformed windows from blur effect.

Currently only scaled or translated windows were excluded,
but it is possible to also have windows with just changed
window quads (e.g. magic lamp).
BUG: 243693
FIXED-IN: 4.5.2



 M  +1 -1      blur.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1169158
Comment 3 Martin Flöser 2010-08-28 16:31:54 UTC
SVN commit 1169160 by graesslin:

Forward port rev 1169158: Exclude all transformed windows from blur effect.

Currently only scaled or translated windows were excluded,
but it is possible to also have windows with just changed
window quads (e.g. magic lamp).
CCBUG: 243693

 M  +1 -1      blur.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1169160
Comment 4 Ryan Thompson 2010-08-28 23:47:18 UTC
I just noticed that I forgot to finish my original description. I guess I got distracted in the middle of
Comment 5 railmaniac 2010-10-07 00:17:02 UTC
The blur effect doesn't work with transparent windows if the "glide" effect is also enabled. Continues to work with plasma panel and notifications.

If I disable glide effect, blur works as expected for transparent windows.

This behaviour emerged on the upgrade to KDE 4.5.2. In 4.5.1 I had both blur and glide working properly.

Relevant post in archlinux forum (because I posted there first): https://bbs.archlinux.org/viewtopic.php?pid=836928

Please let me know if additional information is required.
Comment 6 Thomas Lübking 2010-10-07 03:05:17 UTC
@railmaniac
this is an unrelated bug in the glide effect design which keeps all windows permanently in "transformed" mode what prevents the blurring since such windows are ignored for performance and visual glitches (unpredictable geometry)

i'll post a fix for the glide effect tomorow (it has actually more issues...)
Comment 7 Thomas Lübking 2010-11-02 21:49:44 UTC
r1192387

* replace qhash by qmap and avoid side-effect prone QHash::operator[]
* use TimeLine data memeber instead pointer to prevent leaking
* only setTransformed() if there's really a current animation, not if "a window we know is mapped"
* therefore use a poperty to know whether the effect manages a deleted window
* set the TRANSFORMED flag in prePaintWindow as it should be