background: add support for video wallpapers#908
background: add support for video wallpapers#908AteebXYZ wants to merge 39 commits intocaelestia-dots:mainfrom
Conversation
Bug: First wallpaper change on shell launch has no transition
|
I just realised that gifs can also be played in MediaOutput, I really dont know the side effects of doing this and if there are any problems, but for now it solves some part of this pr #889 |
|
Transitions arent FULLY fixed, cant seem to figure out why MediaPlayer emits the media loaded signal even though some frames of black are being displayed in the beginning, also there is a noticeable lag when switching between video to image vice versa |
… on start bug, removed debug logs
98476c6 to
33ca3fa
Compare
|
Just discovered that because i use MediaPlayer and VideoOutput for displaying the thumbnails of the videos in the wallpaper selector, gpu memory takes a huge hit, ill have to implement a way to cache the first frame of the video |
|
This looks great! It does have a few issues which you pointed out though, so I'll keep off merging it until you're done fixing those. |
|
Okay i managed to fix the GPU memory spike but now the wallpaper menu is VERY unstable, things like opening the bottom right menu repeatedly (causes wallpaper selector to resize) crashes the shell. I have no idea whats causing this, my best guess is my c++ code not being optimal. |
|
There is a compiler warning, please fix it. Also, I ran into a few issues with certain wallpapers not having an animation when transitioning to/from them. Idk if it's dependent on the wallpaper, or an issue with something in the code (probably the latter cause without this pr they are fine). Also, when scrolling through the list quickly, the wallpapers are extremely slow to change, and at a certain speed do not change at all. |
Hmm i didn't get this warning when compiling, but i fixed it regardless, could you provide me the correct cmake build command? And about the slow wallpaper switching, I probably have to come up with a way to load the videos in real time without blocking the GUI thread. Thanks for the input though, ill tell you when things are fixed. |
|
Now im considering to switch to mpvpaper to display videos instead of the Qt mediaplayer, ill probably have a c++ backend that will allow me to communicate with mpvpaper with IPC calls |
You probably aren't using |
Ehhhhhh, I don't really like the idea of using an external wallpaper display... Also I've heard that mpvpaper had some problems with memory leaks? |
yeah an external tool feels unintuitive, but i had another idea, what if the wallpaper selector had 2 tabs, one for image wallpapers and the other for video wallpapers, that solves like 90% of the issues that are present |
|
The thing is, it's much more intuitive to only have one unified display for both video and image wallpapers. We could also do filtering, but that's a separate feature. I'll take a look at it and see what I can do in a bit. |
Changes
Wallpaper.qml is now modularized into ImageWallpaper.qml and VideoWallpaper.qml, Wallpaper.qml handles the double-buffered switching between these 2 depending on filetype.
Added config options so that the user can chose to have audio playback with the video wallpaper or not.
filesystemmodel.cpp in Caelestia.Models has been edited to create 2 new filters called "ImagesAndVideos" and "Videos", services/Wallpapers.qml now uses the new "ImagesAndVideos" filter.
Added a C++ VideoThumbnailer backend used for caching video thumbnails to videothumbcache in the caelestia cache dir.
Dynamic colours for the shell are compatible with video files if paired with this pr in the caelestia cli: background: add support for video wallpapers cli#69
Video wallpapers are paused when the lock screen is active, and are completely unloaded and replaced with a placeholder when game mode is active
Side Effects