picom icon indicating copy to clipboard operation
picom copied to clipboard

[Feature Request] Need help testing animations

Open FT-Labs opened this issue 1 year ago • 47 comments

Hello guys,

I did not want to open up a pull request since it might have some way to go for it.

I've tried to implement a general animation fork, with minor code added. It is on a different branch, I will post the link below.

I would appreciate it if someone can try with different window managers, I've only tested this on pdwm only.

Thanks for everyone who wants to help.

https://github.com/FT-Labs/picom/tree/generalanimation

FT-Labs avatar Apr 22 '23 11:04 FT-Labs

Hi there,

As far as i can tell, This branch is working flawlessly on a stock dwm - guess that was to be expected. i3 is more laggy, seems to struggle a lot when opening/closing/resizing the master window. awesomeWM seems to work fine, no particular issue.

The quality of the animations are pretty neat, great job on that. Would appreciate a way to exclude some windows, can get a bit dizzy when dealing with sub-menus.

Overall this is probably the best looking animation fork of picom i ever tried. Thank you for your work.

I will spin a few more wm and report back if i ever find something off.

Edit : resizing windows seems to massively wobble the inner content and create lots of visual artifacts.

Here's the config used :

#  Animations   #

# fly-in: Windows fly in from random directions to the screen
# maximize: Windows pop from center of the screen to their respective positions
# minimize: Windows minimize from their position to the center of the screen
# slide-in-center: Windows move from upper-center of the screen to their respective positions
# slide-out-center: Windows move to the upper-center of the screen
# slide-left: Windows are created from the right-most window position and slide leftwards
# slide right: Windows are created from the left-most window position and slide rightwards
# slide-down: Windows are moved from the top of the screen and slide downward
# slide-up: Windows are moved from their position to top of the screen
# squeeze: Windows are either closed or created to/from their center y-position (similar to a blinking eye)
# squeeze-bottom: Similar to squeeze, but the animation starts from bottom-most y-position
# zoom: Windows are either created or destroyed from/to their center (not the screen center)

#enable or disable animations
animations = true;

#change animation speed of windows in current tag e.g open window in current tag
animation-stiffness-in-tag = 125;

#change animation speed of windows when tag changes
animation-stiffness-tag-change = 90.0;

animation-window-mass = 0.4;
animation-dampening = 15;
animation-clamping = true;

#open windows
animation-for-open-window = "zoom";

#minimize or close windows
animation-for-unmap-window = "squeeze";

#popup windows
animation-for-transient-window = "slide-down"; 

#set animation for windows being transitioned out while changing tags
animation-for-prev-tag = "slide-left";

#enables fading for windows being transitioned out while changing tags
enable-fading-prev-tag = true;

#set animation for windows being transitioned in while changing tags
animation-for-next-tag = "slide-right";

#enables fading for windows being transitioned in while changing tags
enable-fading-next-tag = true;

Amoebawp avatar Apr 22 '23 19:04 Amoebawp

Hello. I tried it on bspwm, and it worked pretty well. It didn't differentiate between prev-tag and next-tag for me. It just applied the animation for next-tag almost all the time (except for that one time when it actually applied the prev-tag animation, but I only saw it working once).

The animation quality is fairly good. But it can give you a headache for some reason. I think it would be right to exclude popups from animation by default, as @Amoebawp said. Even the right-click popups on browsers fly across the screen for me. Also, thanks to @Amoebawp for the config. I would've struggled a lot searching for it otherwise.

shasherazi avatar Apr 22 '23 21:04 shasherazi

I tried with Xfce, it worked. I used the configs for animations by @Amoebawp. Tomorrow I will give another look at options. I didn't see animation when window close.

servimo avatar Apr 22 '23 22:04 servimo

@FT-Labs

I tested it, so far I can't use it because too many crashes.

  1. When I close a window or maximize/focus on an already opened window, I get an assert crash.
picom: ../src/win.c:1558: win_on_win_size_change: Assertion `w->state != WSTATE_UNMAPPED && w->state != WSTATE_DESTROYING && w->state != WSTATE_UNMAPPING' failed.

or

picom: ../src/win.c:355: win_bind_mask: Assertion «!w->mask_image» failed.
  1. The Xfce4 panel collapse animation is totally crazy.
  2. I don't like the opening popups, because the text in them too deformed as if the rendering of a scaled framebuffer isn't enough anti-aliased (Did you apply GL_LINEAR_MIPMAP_LINEAR or something?).
  3. I also have GLX error at line 706: GL_INVALID_FRAMEBUFFER_OPERATION errors in the console.

Here's a testing video (sorry for the quality, I was on my shitty laptop)

2023-04-23 02-56-30.mkv.zip

P.S.

I can also test on my NVidia GPU.

P.P.S.

I used configuration provided by @Amoebawp

Monsterovich avatar Apr 23 '23 01:04 Monsterovich

I didn't see any crash. I use the backend "egl" and start picom with -b (daemonize).

servimo avatar Apr 23 '23 15:04 servimo

Hey everyone,

Appreciate your time for trying to test it. I've made a new commit, could you please try the latest one? I hope this will work now.

https://github.com/FT-Labs/picom/commit/e9834a5e350415d9e036d48304405bdb2d8a1567

@Monsterovich that is another issue I think, for fading to work on animations I needed to add unmapping statement there. After this issue is resolved, I will fix the ability to stop animations for selected windows as well. Thanks guys!

FT-Labs avatar Apr 25 '23 00:04 FT-Labs

I hope im not thinking correctly because this will work with window managers or DE but not both

FT-Labs avatar Apr 25 '23 02:04 FT-Labs

Hi, tried with commit e9834a5. Next-tag and prev-tag animation doesn't work(tried different configs, for example: @Amoebawp). Other animations works fine.

    OS: ArcoLinux
    Kernel: 6.2.10-zen1-1-zen
    Resolution: 1920x1080
    WM: awesome
    CPU: Intel i5-1035G1 (8) @ 3.600GHz
    GPU: Intel Iris Plus Graphics G1
    GPU: NVIDIA GeForce MX330
    GPU Driver: i915

EpsilonKu avatar Apr 29 '23 19:04 EpsilonKu

Tried the latest commit on dwm, i3, bspwm, leftwm and awesome.

All were working as expected really, some minor visual bugs - when opening several windows, some may glitch a bit and fail to render any animation. It's not particulary annoying. All animations were working correctly, resizing aswell, prev/next tab also. I can't say i'm having particular issue... everything's quite smooth really

Here's a quick capture on DWM, but all where behaving like this on my end https://youtu.be/24n2JiQIogM

If i had to mention two annoying things : visual glitch when resizing window + animations on right click/context menu (Xmenu) that would need to be excluded.

@FT-Labs do you need us to test something a bit more specific ?

Here's an updated config after some adjustments to my liking ( with Fading )

#################################
#           Animations          #
#################################

# fly-in: Windows fly in from random directions to the screen
# maximize: Windows pop from center of the screen to their respective positions
# minimize: Windows minimize from their position to the center of the screen
# slide-in-center: Windows move from upper-center of the screen to their respective positions
# slide-out-center: Windows move to the upper-center of the screen
# slide-left: Windows are created from the right-most window position and slide leftwards
# slide right: Windows are created from the left-most window position and slide rightwards
# slide-down: Windows are moved from the top of the screen and slide downward
# slide-up: Windows are moved from their position to top of the screen
# squeeze: Windows are either closed or created to/from their center y-position (similar to a blinking eye)
# squeeze-bottom: Similar to squeeze, but the animation starts from bottom-most y-position
# zoom: Windows are either created or destroyed from/to their center (not the screen center)

#################################

#enable or disable animations
animations = true;

#change animation speed of windows in current tag e.g open window in current tag
animation-stiffness-in-tag = 52;

#change animation speed of windows when tag changes
animation-stiffness-tag-change = 25.0;

animation-window-mass = 0.2;
animation-dampening = 7;
animation-clamping = true;

#open windows
animation-for-open-window = "zoom";

#minimize or close windows
animation-for-unmap-window = "zoom";

#popup windows
animation-for-transient-window = "slide-down"; 

#set animation for windows being transitioned out while changing tags
animation-for-prev-tag = "slide-left";

#enables fading for windows being transitioned out while changing tags
enable-fading-prev-tag = true;

#set animation for windows being transitioned in while changing tags
animation-for-next-tag = "slide-right";

#enables fading for windows being transitioned in while changing tags
enable-fading-next-tag = true;

#################################
#           Fading              #
#################################


# Fade windows in/out when opening/closing and when opacity changes,
#  unless no-fading-openclose is used.
fading = true

# Opacity change between steps while fading in. (0.01 - 1.0, defaults to 0.028)
fade-in-step = 0.04;

# Opacity change between steps while fading out. (0.01 - 1.0, defaults to 0.03)
fade-out-step = 0.06;

# The time between steps in fade step, in milliseconds. (> 0, defaults to 10)
fade-delta = 10

Amoebawp avatar Apr 30 '23 12:04 Amoebawp

bspwm user here searching for fork with animations, rounded corners and blur, haha. for me, all works cool except animation-for-prev-tag, it only executes once. Thats it, everything else is flawless.

edit: actually, https://github.com/fdev31/picom works flawlessly. Only thing is i'd like workspace switch animations.

BANanaD3V avatar May 04 '23 14:05 BANanaD3V

Tag change animations don't work in awesome, it looks like it doesn't recognize it as a tag change? Also when minimizing a client the animation for it doesn't play at all.

Crylia avatar May 04 '23 18:05 Crylia

edit: actually, https://github.com/fdev31/picom works flawlessly. Only thing is i'd like workspace switch animations.

actually, it doesnt now. strange one, prev-tag executes only once as in ft-labs. needs testing

BANanaD3V avatar May 06 '23 19:05 BANanaD3V

@BANanaD3V It's not next-tag or prev-tag animation. It's window creation animation. It execute once because picom think that it's newly created window.

EpsilonKu avatar May 08 '23 17:05 EpsilonKu

Tag switch will be fixed soon. The other issue that is scratching my mind is properly handling xunmapwindow and xdestroywindow events.

Some simpler window managers like dwm do not use minimize or destroy windows. It only unmaps the window and free the window because there is no iconization or minimization in dwm.

After I got the fix for this issue, hopefully the last issue is going to be fixing glitches while shadows are enabled on low performance computers.

FT-Labs avatar May 11 '23 01:05 FT-Labs

It crashes when I close a window on qtile with the following error : "picom: ../picom-9999/src/win.c:1550: win_on_win_size_change: a asserção "w->state != WSTATE_UNMAPPED && w->state != WSTATE_DESTROYING && w->state != WSTATE_UNMAPPING" falhou"

CarDGee avatar May 19 '23 02:05 CarDGee

My 2 cents on i3 :

It works, it's usable but not optimal and still sometimes feels glitchy, it's an overall feeling, I don't know how to express it clearly but for example when refreshing my config polybar may not appear and I would need to refresh again, not a real world case but just for reference if I spam super + enter and open bunch of terminals the desktop will quickly become ultra zoomed without any possibility to take control other than going to a tty and kill picom, with main picom I feel like I could open the double amount of terminals easily without much problems.

StitiFatah avatar May 25 '23 10:05 StitiFatah

Every animation is extremely buggy (not usable) with the following error : GLX error at line X: GL_INVALID_VALUE with x being a number of course.

Aaazd avatar May 28 '23 21:05 Aaazd

Tested on Openbox. Visual glitches with the title bar when minimizing regardless of effect (but like 10% of the time it works fine?) and some windows like Discord and Firefox will animate the first time they're minimized and opened but not again. Other than that, it works great.

My config:

animations = true;

animation-stiffness = 300;
animation-window-mass = 0.4;
animation-dampening = 12;
animation-clamping = true;

animation-for-open-window = "zoom"; #open window
animation-for-unmap-window = "none"; #minimize window
animation-for-transient-window = "slide-down"; #popup windows

BowDown097 avatar May 31 '23 13:05 BowDown097

Working amazingly on BerryWM. Only problem is the occasional lag. Here's a video:

https://github.com/yshui/picom/assets/93940240/29766df3-412b-49c7-abd2-a8592b64a429

rice7th avatar Jun 17 '23 14:06 rice7th

Can we have an update with latest patches on this fork of picom, I am using it and it has a lot since I installed it, related to the yshui/picom.

servimo avatar Jul 03 '23 16:07 servimo

Qtile user here! I tried your fork and it works really well EXCEPT the tag animation I'm using @Amoebawp config

https://github.com/yshui/picom/assets/141400306/ee2f866f-16b9-47ec-86ac-1e8d15ae96f3

Thats my only problem. I also saw other comments that says basically the same issue so yeah

ghost avatar Aug 08 '23 09:08 ghost

Will update this soon! Thanks for the response guys

FT-Labs avatar Aug 08 '23 19:08 FT-Labs

Also using Qtile but my issue might not be related to the desktop used. It doesn't seem like animation set for transient windows (Dunst notifications in my case) is respected

Is it missing something on my end?

$ notify-send "Test"
$ xprop
_NET_WM_WINDOW_OPACITY(CARDINAL) = 4294967200
_NET_WM_STATE(ATOM) = _NET_WM_STATE_ABOVE
_NET_WM_WINDOW_TYPE(ATOM) = _NET_WM_WINDOW_TYPE_NOTIFICATION, _NET_WM_WINDOW_TYPE_UTILITY
WM_CLASS(STRING) = "Dunst", "Dunst"
_NET_WM_NAME(UTF8_STRING) = "Dunst"
WM_NAME(STRING) = "Dunst"

The notification is using the animation from animation-for-open-window rather than animation-for-transient-window

angrybacon avatar Aug 24 '23 11:08 angrybacon

@angrybacon in mean time try

wintypes:
{
  notification = { animation = "slide-down"; };
}

Darukutsu avatar Aug 24 '23 11:08 Darukutsu

Thanks for the workaround. I notice something else just now, the slide-* animations behave like squeeze in that the window grows where I expected them to move into view without being deformed

Is it expected? If so, are there plans for fly-left and fly-right animations?

angrybacon avatar Aug 24 '23 11:08 angrybacon

Animations for prev tag and next tag still don't work on awesomewm right?

Vermoot avatar Sep 25 '23 12:09 Vermoot

Animations for prev tag and next tag still don't work on awesomewm right?

Nope

Crylia avatar Sep 28 '23 06:09 Crylia

Working on it rn

FT-Labs avatar Sep 29 '23 22:09 FT-Labs

Configure Animations Specifically for Window Maximization

I've noticed that the current animation settings are not restricted solely to window maximization; they're also being applied to standard window operations. This isn't the desired behavior. When performing routine tasks such as moving, resizing, or simply focusing on a window, these animations are triggered. This not only results in a visual distraction but also slows down the overall user experience, especially when working with multiple windows simultaneously.

Ideally, I'd like the option to configure animations to be exclusive to certain actions, like window maximization. This would help users like myself who appreciate some animations (like maximizing) but find them cumbersome when applied universally across all window actions.

raven2cz avatar Sep 30 '23 06:09 raven2cz

I'm inclined to agree with @raven2cz, some things being animated doesn't make much sense. Resizing and moving windows (manually, at least) is made somewhat sluggish by animations being applied.

Additionally, one weird thing I encountered using your fork is this:

https://github.com/yshui/picom/assets/23317434/c6a657fd-5a56-4445-9676-4c141c1fafad

Context menus seem to be the "same" window when closing and re-opening them, resulting in an animation of their position when re-opening them. The same applies to tooltips.

Vermoot avatar Sep 30 '23 09:09 Vermoot