Welcome, Guest. Please login or register.
Did you miss your activation email?

Author Topic: [EN] (workaround found) slideshow in KDE 5 desktop and live_wallpaper  (Read 16240 times)

Offline ayla

  • User
  • Posts: 1.745
[EN] Re: slideshow in KDE 5 desktop
« Reply #15 on: 2015/07/15, 23:21:23 »
Not tried the autostart so far.

But I see it's eaten up RAM. It seems to dont free it after reserving/using it.

EDIT: Have to watch this tomorow after setting up all clean, it could be possible something else is responsible for the increasing usage of RAM here.
« Last Edit: 2015/07/15, 23:50:14 by ayla »

Offline ayla

  • User
  • Posts: 1.745
Re: slideshow in KDE 5 desktop
« Reply #16 on: 2015/07/16, 11:33:21 »
After setting up the desktop files and autostart it works so far, but...

My CPU usage is not the problem, it's going up to use all cores for about two seconds at about 15% (see system below).

But, nothing running then the services startet by systemd, kmix and  kmail, the usage of RAM increases on every run of plasmashell at about 150MB.

Starting the script from console gives a lot of messages indicating heavy activity:

  http://paste.siduction.org/20150716091217

So I think I'm back to my first Question. Where can I find the -hopefully well documented or I'm lost in deep space- script/code which is running the slideshow? The slideshow works so far, and I guess I ..."simply :) "... have to tell it, insteed of using an at startup somewhere stored image -what's, my wild guess, it does-, to read the file to display anew every time and all works as it should.
I' ll search the ...rc files you've pointing me to, when I get the time, again and hope to get a hint there...


 

Offline ayla

  • User
  • Posts: 1.745
Re: slideshow in KDE 5 desktop
« Reply #17 on: 2015/07/17, 18:12:50 »
Hi,

I don't know why, but now my slideshow uses new files, even if they are insertet into the folder after slideshow had startet, as long  there is not only a single image file in the folder which uses the same name as the one before.

Im pretty sure I've tried this several times before to solve the mentioned issue and it didn't...

I have done nothing!!  ::)

So I changed my script and store now for every camera with an index, eg current1.jpg, current2.jpg, current3.jpg.
I have at the moment three different images in the folder where every image changes every two minutes and the cycle of the slideshow is two minutes, too. -OK, 2 min and 1 sec, because in slideshow it's not possible to set the seconds to zero.

This works so far, but the order the images show up are random, which means some Images are played double, some get lost.

I will try now what happens if I delete the other images, the moment a new one comes in, and don't keep the name.

greets
ayla

Offline ayla

  • User
  • Posts: 1.745
Re: slideshow in KDE 5 desktop
« Reply #18 on: 2015/07/17, 19:56:45 »
hrmpf  :-\

If I have 3 images in the folder where my slideshow is pointet to when it starts, with this script it works (after first cycle is finished):

  http://paste.siduction.org/20150717173927
 
If I have just two images in the folder at the start it just changes between the to imagenames which were present at startup...

So it seems I have to store three images when I leave the session to get it startet with three cams next time...  :(

diggin...

EDIT: or I have to store 3 similar named images in the folder before plasma starts, or restart plasma once.
« Last Edit: 2015/07/17, 20:39:17 by ayla »

Offline dibl

  • siduction community member
  • Global Moderator
  • User
  • *****
  • Posts: 2.395
    • Land of the Buckeye
Re: slideshow in KDE 5 desktop
« Reply #19 on: 2015/07/17, 21:44:03 »
Thanks for all the work! I'm going to give it another shot on the weekend.


Semi OT -- I was googling for more plasma 5 development issues and I was disappointed to find that the ability to put different wallpapers on different virtual desktops is not in the plan for plasma 5. For KDE 4 I found that a useful way to organize multiple activities.  Too bad.   :-[
System76 Oryx Pro, Intel Core i7-11800H, SSD 970 EVO Plus;  Asus ROG STRIX X299-E, Core i7-7740X, Nvidia GTX-1060, dual monitors, SSD 860 EVO

Offline ayla

  • User
  • Posts: 1.745
Re: slideshow in KDE 5 desktop
« Reply #20 on: 2015/07/17, 23:00:17 »
Hi,

never worked with the activities or virtual desktops, will have a look at the possibilities it serves when I have more time :)

This slideshow is making me complete crazy. Now it works as it should when I give it the 3 images even after it startet and let the script delete/replace them in the cycle untill there is just one changing (content and name) left. Again I did nothing other then before.  I encounterd it when preparing the folder for a next session. What the... , did they erroneously build an AI and it learns? ;D

Think I'm givin up for today and give it another try tomorrow. Thinking about a testseries to learn what rules this ....thing follows, -if any.

Offline dibl

  • siduction community member
  • Global Moderator
  • User
  • *****
  • Posts: 2.395
    • Land of the Buckeye
Re: slideshow in KDE 5 desktop
« Reply #21 on: 2015/07/17, 23:22:10 »
@ayla your method is working!  I have set 4 cameras, each gets a new image every 2 minutes.  So that means the script takes 8 minutes to completely refresh all four images.  Using the slideshow background, the images appear to be shown in random sequence, so it sometimes happens that the same image appears twice because the script has not run the full 8 minute cycle.  But eventually there are new images for each one.  And very low CPU and memory usage, by the way.  Nice! Thanks for your work on it.
System76 Oryx Pro, Intel Core i7-11800H, SSD 970 EVO Plus;  Asus ROG STRIX X299-E, Core i7-7740X, Nvidia GTX-1060, dual monitors, SSD 860 EVO

Offline ayla

  • User
  • Posts: 1.745
Re: slideshow in KDE 5 desktop
« Reply #22 on: 2015/07/17, 23:35:30 »
With how much images in the folder did you start the slideshow? Do you use the script which is leaving just one image after the first cycle is completed?

Offline dibl

  • siduction community member
  • Global Moderator
  • User
  • *****
  • Posts: 2.395
    • Land of the Buckeye
Re: slideshow in KDE 5 desktop
« Reply #23 on: 2015/07/18, 00:59:50 »
I am writing 4 images in the target directory.  Each image is updated every 120 seconds. I set the slideshow also to change every 120 seconds.
System76 Oryx Pro, Intel Core i7-11800H, SSD 970 EVO Plus;  Asus ROG STRIX X299-E, Core i7-7740X, Nvidia GTX-1060, dual monitors, SSD 860 EVO

Offline ayla

  • User
  • Posts: 1.745
Re: slideshow in KDE 5 desktop
« Reply #24 on: 2015/07/18, 11:23:38 »
Hi,

seems it runs now. I have to start with three images to get the slideshow cycle thru all images of the three cams. I do this by copying three images to the folder the slideshow uses on start of the script, named as the images the script provides later and let all but the current one delete during the cycle to prevent it from randomized displaying.

My script in use:
  http://paste.siduction.org/20150718085816
 
For my main screen I have a second script running, which stores it's images in a second folder. This gets a picture of the earth with the day and night zone changing over the day.
http://www.opentopia.com/images/cams/world_sunlight_map_rectangular.jpg
As the slideshow refuses to load new images when only one periodicly changing image is in it's folder in use, I simply added a second cycle and did the naming and the initial and deleting sequence as shown in the script above. Now this one also runs as it should.

greets and thanks for help and not let muddling me alone  :)
ayla
« Last Edit: 2015/07/18, 11:31:31 by ayla »

Offline dibl

  • siduction community member
  • Global Moderator
  • User
  • *****
  • Posts: 2.395
    • Land of the Buckeye
I posted my ~/.config/autostart/live-wallpaper.desktop file above. There's a 3-line shell script to start the getpic.py script in my home folder. I did very little editing to the getpic.py script, just enough to repeat the capture for four cameras.  Here it is:
 
http://paste.siduction.org/20150718140327


The script overwrites the four image files, so no need to delete anything. Just  point the KDE slideshow to the folder with the images, set the timing for 2 minutes, and then log out and log back in and it starts.  Note that it takes a full 8 minutes for the script to finish a new cycle of image captures.
« Last Edit: 2015/07/18, 16:14:42 by dibl »
System76 Oryx Pro, Intel Core i7-11800H, SSD 970 EVO Plus;  Asus ROG STRIX X299-E, Core i7-7740X, Nvidia GTX-1060, dual monitors, SSD 860 EVO

Offline ayla

  • User
  • Posts: 1.745
Quote
The script overwrites the four image files, so no need to delete anything.


Hi,

so of course, doing it that way, there is no need for initializing, because there are allways 4 images present and if  random order of displaying is acceptable there is no need for deleting too.

I wonder whether it would be possible to get an sequential order of displaying other then the way I did. And a pity that it is not possible to insert complete new images into the slideshow after it is startet.

A sequential order with defined starting point would also be a good thing for e.g. displaying a pictorial history or a comic strip. But ok, one may create a video for that and display it the way HendrikL has pointet to, with use of more ressources of course..

greets
ayla

GoldNugget

  • Guest
Hello.
 I am the author of this program. It sounds like you got it working using a script and I'm glad it's working for you now. If you haven't tried it already, I would like to suggest a simpler solution:
You can launch several instances of PortalView a few minutes apart. For example, you could start five different instances of PortalView, pointing to five different locations. Set each one to update every ten minutes and launch them two minutes apart. The result should be what you were looking for...live images from a variety of webcams around the world rotating every two minutes. No extra script necessary. Remember all the images need to be the same format, that is all jpgs or gifs for example.

Good luck and feel free to email me if you have any questions.

Michelle

michelle@goldnuggetwebs.com
« Last Edit: 2015/08/12, 01:26:26 by GoldNugget »

Offline ayla

  • User
  • Posts: 1.745
Hi GoldNugget,

welcome to siduction forum and many thanks for your work on PortalView.
I use it for over an year with two instances and two folders for two displays and PortalView itself was and is working just fine.
 
I just added some "try" and "pass"  to prevent the script from stopping in case of errors caused by network failures or broken images, after the first few weeks of using it. With help from this forum of course because I know nearly nothing about python script language or other programming languages.

What has changed now was the behavior of KDE's slideshow when switching from KDE4 to KDE5.
Before I installed KDE 5 I had simply 3 cams which changed every two minutes and stored an image which was named "current" in one and the same folder. So the image got overwritten every two minutes from a new one. Parallel slideshow used a two minute cycle and displayed this new picture.
Now, with KDE 5, slideshow does not change the displayed picture any more if there is only one image in the folder and the image changes but it didn't change it's name. It shows the first one continiously.
If there are more than one images in the folder it shows them in a random order, which I don't like. So I let the script name the images with an index and  on every new image delete the one before.
That worked one time when I startet slideshow, but another time I had the same image played continiusly...
After a lot of tries I had it stable working as I like it when slideshow found  3 images when it starts, named the same as the images I liked to display during the cycles, which then get deletet on the first cycle. Easiest way to do so was adding this to the PortalView script.

I will test your suggestion using different folders for the different cams, as one can give slideshow more than one folder to get its pictures from, but my suspicion is that I get them displayed in random order again. Will report back, but may take a few days.

Thanks again
ayla

Offline dibl

  • siduction community member
  • Global Moderator
  • User
  • *****
  • Posts: 2.395
    • Land of the Buckeye
Hello.
 I am the author of this program.



Thanks for your work Michelle!  I presently have 9 cameras/images that randomly display every 2 minutes, and this a very satisfactory wallpaper solution.
System76 Oryx Pro, Intel Core i7-11800H, SSD 970 EVO Plus;  Asus ROG STRIX X299-E, Core i7-7740X, Nvidia GTX-1060, dual monitors, SSD 860 EVO