HobbyBlobby / PlasmaWallpaper_CityGrow

Plasma Wallpaper Plugin (also Screen Lock) with growing city animation
MIT License
10 stars 0 forks source link

Support KDE 6 #2

Closed Bodanor closed 8 months ago

Bodanor commented 8 months ago

Right now, this wallpaper only works on KDE 5 and not anymore on KDE 6. Are you planning on supporting the latest KDE version ?

HobbyBlobby commented 8 months ago

Hi @Bodanor

I am working on it. Almost done (at least on my Plasma6 it is already rendering something). ^^

Bodanor commented 8 months ago

@HobbyBlobby Take your time, I juste wanted to know if it was on your todo list :) That's some great news, and of course I appreciate your effort porting this wallpaper to KDE 6. Nevertheless, if you need some help I would be happy to help (even tho I'll have to start learning writing widgets from scratch :/)

Do I keep this issue open till the new update or should I close it ?

HobbyBlobby commented 8 months ago

Actually, I just pushed a version which should run under Plasma6. Still some cleanup needed, but you can test. It is not uploaded into the KDE store, but you can check out this repo and do the "cmake + make install" steps to try.

Bodanor commented 8 months ago

Actually, I just pushed a version which should run under Plasma6. Still some cleanup needed, but you can test. It is not uploaded into the KDE store, but you can check out this repo and do the "cmake + make install" steps to try.

Sure, I'll test it out and report to you if something is wrong. I'll just go to bed cause I'm tired but I'll test it tomorrow and report to you ASAP.

Bodanor commented 8 months ago

Hi again, I couldn't sleep so I git cloned and build the wallpaper. I have it running at the moment and everything seems to work at the beginning, but for some reason the paths are going out of my screen (see the screenshot) )and it doesn't seem to reset at all as it did previously. Not sure what the issue could be :/

I imagine that you only got it to show something (which is good btw) and not actually finished the whole thing up right ? Screenshot_20240316_005441

HobbyBlobby commented 8 months ago

Hi,

thanks for testing. I fixed the restart issue. It should now reset when the last branch stopped (after a 5 seconds break). But currently I am not able to reproduce the issue with the lines going out of screen. It seems to be off by 1 grid point. I am not sure, I will test this with an external monitor. Maybe this is connected to the screen resolution (rounding error)?

Bodanor commented 8 months ago

Hi,

I'm not sure either, urghh I was I could help you on that one. On a side note, I also discovered another bug. Basically on my laptop Thinkpad (1920X1080) on Arch with the latest KDE Plasma version it does what I described earlier (that is not resetting by itself). But on my other main computer (again, Arch, latest KDE Plasma version with 2 display attached), nothing renders. Tried on the main monitor as well as the second monitor but nothing shows up (black screen). Not sure why it would work on my laptop and not on my main computer with 2 monitors attached :/

Now that I'm writing this, I'll try again but this time with only the main monitor attached and nothing else. Maybe 2 monitors confuses the engine ??

Bodanor commented 8 months ago

Hi again,

I just tried with only one monitor and I still get a black screen. Now, my theory is that this issue comes from the Nvidia driver. My laptop is based on AMD but my main computer runs on a GTX 1070TI from Nvidia, so that's the only explanation I can think of at the moment. My next step is to try with the Nouveau driver and see if I get a different result. However, if I get the same result then I'm afraid but I really don't know what I can do to report this issue. I know that it worked previously on the same machine with KDE Plasma version 5 but the Nvidia drivers also got updated with the new version. So is it your wallpaper that is at fault or the Nvidia driver ? We don't know yet, so I'll have to do more tests and see what could cause it.

So in summary they are 2 main bugs, one is the out of the screen bug where the wallpaper just gets stuck (but you are on it and I'll try everytime this repo gets updated as I create a PKGBUILD that works with the AUR so I don't have to manually check every commit. BTW, Tell me if you are interested to get it published on the AUR). And the other one which I suspect has something to do with the Nvidia driver, but don't worry I'll keep you up to date if I find additional results and discoveries. For the later BUG do you want me to open another issue so that we keep this thread organized ?

HobbyBlobby commented 8 months ago

Okay, so much information at once....

  1. Regarding NVIDIA: I doubt I can do anything about it. I use just a Qt Canvas (https://doc.qt.io/qt-6/qml-qtquick-canvas.html) with a 2d context rendering lines. Nothing fancy, just lines on a plain. If this is not rendering, this is going to Qt or KDE???
  2. Regarding multiple monitors: You can set up a wallpaper plugin per monitor. Basically, every monitor has its own wallpaper running, independent of each other. This means, there are simply running two instances of that plugin, each with its own "normal" rectangular geometry. This shouldn't be an issue, theoretically.
  3. Regarding the out-of-bounds lines: I will check this again. On my screen, I have the (non-transparent) toolbar on the left, so actually I do not see the left-most part. But I am running this plugin as screen saver (where it was originally designed for), and there the boundaries look perfectly normal. Hint: it is easier to test with screen saver, because every time the screen lock is started, the plugin is loaded. In contrast, for wallpaper mode, the plugin is loaded only when logout and login again.
  4. Regarding AUR: this is appreciated, but I think the "proper" way is to publish the plugin via the KDE store page, so you can find it in the standard "Download new plugin" dialog. But I want to work on the bugs before uploading it again to the store.
  5. Lastly, can you please test to use the plugin as screen saver (screen lock system settings) and check, if the out-of-bounds bug is still existing there? Maybe also try to start it on the NVIDIA machine as screen save. I want to check, if this is a problem when the plugin as actually user as wallpaper (in my case, everything works fine here).

I am not sure if you want to open a new issue regarding the NVIDIA machine. As I said, I doubt I can help here. Maybe if I can get my hands on a NVIDIA computer, I can make a minimal test example and report a bug....

And again, your help is very welcome.

HobbyBlobby commented 8 months ago

I now tested with an external monitor (different resolution than my laptop screen), but the "city" seems to fill the space correct. Screenshot_20240318_095123

Are you sure you logoff and login after the last "make install"? It seems, plasma loads the plugins once during login and changes are not applied in a running session.

Bodanor commented 8 months ago
  1. Regarding NVIDIA: I doubt I can do anything about it. I use just a Qt Canvas (https://doc.qt.io/qt-6/qml-qtquick-canvas.html) with a 2d context rendering lines. Nothing fancy, just lines on a plain. If this is not rendering, this is going to Qt or KDE???

Yes that's why I thought it was a little weird. I just tried on the nouveau driver, rebooted and everything but I still get the same black wallpaper. Additionally, I tried wayland and X11 session but no success. Unfortunately, I don't know what else to try here. It seems that it only works on AMD based machines (if the problem is really related to nvidia)...

  1. Regarding the out-of-bounds lines: I will check this again. On my screen, I have the (non-transparent) toolbar on the left, so actually I do not see the left-most part. But I am running this plugin as screen saver (where it was originally designed for), and there the boundaries look perfectly normal. Hint: it is easier to test with screen saver, because every time the screen lock is started, the plugin is loaded. In contrast, for wallpaper mode, the plugin is loaded only when logout and login again.

Are you sure about that hint ? Because I'm using multiple desktop widgets, and I never had to logout to get them running. Additionally, when I compiled this wallpaper on my laptop, I never logged out to get it to run. Maybe things have changed in plasma 6 ?

  1. Regarding AUR: this is appreciated, but I think the "proper" way is to publish the plugin via the KDE store page, so you can find it in the standard "Download new plugin" dialog. But I want to work on the bugs before uploading it again to the store.

That make sense. I create this PKGBUILD only for me to compile and test this wallpaper easily. But yes I think the proper way is to publish it to the store for sure.

  1. Lastly, can you please test to use the plugin as screen saver (screen lock system settings) and check, if the out-of-bounds bug is still existing there? Maybe also try to start it on the NVIDIA machine as screen save. I want to check, if this is a problem when the plugin as actually user as wallpaper (in my case, everything works fine here).

I just tried to set it to use as a screen saver and I'm afraid but I still get this silly black screen. I really thing you are not a fault here and something is not working on the lower level with KDE. But one that doesn't add up is the fact that other plugins like active blur on the store are working perfectly fine on my Nvidia based machine. So who knows where the culprit could be.

I am not sure if you want to open a new issue regarding the NVIDIA machine. As I said, I doubt I can help here. Maybe if I can get my hands on a NVIDIA computer, I can make a minimal test example and report a bug....

Well, you don't really need to, I could be your Nvidia tester. After all I'm here to test and report things

And again, your help is very welcome.

My pleasure :)

HobbyBlobby commented 8 months ago

Still no update on the NVIDIA problem.

But I think I've got something on the out-of-bounds issue: I moved the whole image by the line width of the branches. It seems to fit much better into the screen now. Hope this is working better now.

Bodanor commented 8 months ago

I just compiled it and tested, however it still doesn't reset correctly. I'm still stuck here and it's been 2 minutes or so Screenshot_20240318_150305

Is it resetting on your end ?

Bodanor commented 8 months ago

Here is an update. I just tried to set it to work as a screen saver and it correctly resets by itself but not when I set it as a desktop wallpaper. So I guess something is going on with panels or so I don't know :/

So lock screen looks good everything works perfectly but not on the desktop wallpaper end. But as you said, you created this wallpaper to work when used as a screen saver, so I guess the issue is fixed ? Not sure if you plan to make it work as a desktop wallpaper though

HobbyBlobby commented 8 months ago

Hi,

I further tested, also in wallpaper mode. Currently, I am not able to reproduce the issue with failing reset. I am not sure, why you still get this error.

One thing to try is to clean up the sources and re-install.

  1. Remove everything from the install folder "rm -rf /usr/share/plasma/wallpapers/org.kde.plasma.citygrow"
  2. Then do the cmake and make install steps (maybe also start with a clean "build" folder)
  3. Logout and login again

If this is not helping, I honestly have no idea.

PS: there is a new option to pause the plugin when a full screen or maximized window is detected. This helps to save CPU resources (when the wallpaper is hidden behind windows). This is still in testing mode, and makes sense only in wallpaper mode... Just in case you are wondering.

One last thing: when you test (e.g. with the NVIDIA black screen), can you let the comand " journalctl --user -f " runnig during the screen save test? Then you can look out for any "citygrow" related errors.

HobbyBlobby commented 8 months ago

Hi,

since you used the git version (with "make install") and there is a KDE store version now too, please remove all content from your computer: "rm -rf /usr/share/plasma/wallpapers/org.kde.plasma.citygrow" and also "rm /usr/share/metainfo/org.kde.plasma.citygrow.appdata.xml"

Then you can clean up your "build" directory and do the "cmake + make install" command (PKG build). This will install a "City Grow - Debug" version, which helps to differentiate between the git -repo version and the one from store.kde.org. .

Now you can have the official version by just downloading the plugin via the systemsettings dialog.

Best regards

Bodanor commented 8 months ago

Hi again,

I'm sorry I was kind of busy lately but I came here with some great news. First, I would like to thank you for your effort porting this wallpaper/screen saver to Plasma 6. I hope you at least had some fun porting it. Additionally, I just tried downloading it through the store, and by curiosity I also tried it on my Nvidia based machine, and it immediately worked flawlessly. I don't really know what changed but it works ! Again, thank you for your effort I really appreciate it

I think we can now close this issue, as the initial one is now fixed + the reset and the Nvidia one is also fixed.

PS : Your idea to pause the wallpaper is a welcomed feature and a brilliant idea. But how did you make sure that it really pause when not visible ? Best regards

HobbyBlobby commented 8 months ago

Hi @Bodanor, this is indeed great news. I hoped that a clean "install" via the KDE store would help. Maybe during the multiple tries, something got stuck... Your testing work was a big help, not all work is done be developers.

Answering your question regarding the pause function. Basically, the plugin is asking the task manager to return a list of maximized or full screen application on the matching screen/monitor. The rendering is paused, whenever an application is on the same screen in full screen or maximized mode. This of course has limits: One example is the "peek at desktop" feature (usually trigger by the key combination Meta+D). This feature shows the wallpaper, but the applications are technically still there, so the plugin is paused during the "peek". Also, if you activate the checkbox in the screen saver settings, the plugin is paused even as screen saver if there is a maximized application.

I close this issue now, thanks again!

Bodanor commented 8 months ago

I just feel a little bit guilty, because maybe I've done something wrong during my testing and because of that I may have wasted your time on an issue that never existed and I wanted to apologize if it was the case

Your testing work was a big help, not all work is done be developers.

That's absolutely true and to my eyes, the most important thing is to contribute no matter how, and to see that it took less than a week to resolve the issue (porting is never easy, and we may something encounter obstacles int the way) is amazing. Again thank you for your work and time.

This of course has limits: One example is the "peek at desktop" feature (usually trigger by the key combination Meta+D). This feature shows the wallpaper, but the applications are technically still there, so the plugin is paused during the "peek". Also, if you activate the checkbox in the screen saver settings, the plugin is paused even as screen saver if there is a maximized application.

I now see of it works behind the scenes. I was trying to find a way to prove that it indeed worked but never thought about the "peek at desktop" feature, mostly because I thought that peeking at desktop would make think to your wallpaper that all windows were "gone"