Amiga.org

Coffee House => Coffee House Boards => CH / Science and Technology => Topic started by: motorollin on January 31, 2009, 01:53:55 PM

Title: Linux slideshow software
Post by: motorollin on January 31, 2009, 01:53:55 PM
I've got Debian running on my EFIKA and I'm using it as a digital photo frame. I'm using the GLSlideShow screensaver for this, but I'm having a couple of problems. First, the screen sometimes goes black with no image displayed for a few seconds. More importantly though, the slideshow doesn't have flexible options for scaling the images.

So, does anyone know of a good slideshow app for Linux? It should have various options for scaling, support a variety of formats, and be able to scan a directory for images and randomly play them. I also need it to start without user intervention.
Title: Re: Linux slideshow software
Post by: pyrre on February 01, 2009, 01:34:51 AM
I don't know if you have tried.
But a quick google search:
link (http://www.klografx.net/qiv/index2.html)
link (http://www.linux.com/articles/55737)
several links (http://linux.softpedia.com/downloadTag/image+slideshow)

Hope some of them works out...
Title: Re: Linux slideshow software
Post by: bloodline on February 01, 2009, 11:07:05 AM
Probably not what you want to hear... but you could easily write your own! The SDL_gfx library has some good real time scaling functions.
Title: Re: Linux slideshow software
Post by: motorollin on February 01, 2009, 11:12:00 AM
Thanks for the info. Yes, I have spent some time Googling but nothing quite seems to meet my needs. Should have mentioned that to avoid coming across as lazy ;-)

I have looked at qiv already and is almost perfect. The problem with it is that it seems to require a text file containing the names of the images you want it to display (the -F parameter in other words). Do you know if it's possible to use it without that, by telling it to use a directory as the location of the images?

Feh looks promising, though there's not much info on how it handles scaling of images. I'll try to install it and see what happens.

Thanks for the Softpedia link. I have never heard of that site! If the other two apps aren't any good then I'll start trawling through.
Title: Re: Linux slideshow software
Post by: motorollin on February 01, 2009, 11:13:17 AM
Quote
bloodline wrote:
Probably not what you want to hear... but you could easily write your own! The SDL_gfx library has some good real time scaling functions.

I considered it actually. Shouldn't be a massive job to load the image, scale it and display it.

If only RealBasic cross-compiled for PPC Linux :-(
Title: Re: Linux slideshow software
Post by: bloodline on February 01, 2009, 11:27:19 AM
I really really promise you that SDL and C isn't that hard! :-D

http://friedspace.com/SDLTest.c
Title: Re: Linux slideshow software
Post by: motorollin on February 01, 2009, 02:38:08 PM
Quote
bloodline wrote:
I really really promise you that SDL and C isn't that hard! :-D

http://friedspace.com/SDLTest.c

Actually I do quite like SDL. I started writing a GridWars/Geometry Wars clone for the GP2X in C++/SDL and SDL was the only thing about the programming experience which didn't suck! I only gave up on it because the AI was too difficult for me to get my head around and then I started my degree ;-)

So yes, I do like SDL. It's just a shame about all the C malarkey :-P
Title: Re: Linux slideshow software
Post by: bloodline on February 01, 2009, 05:43:07 PM
Quote

motorollin wrote:
Quote
bloodline wrote:
I really really promise you that SDL and C isn't that hard! :-D

http://friedspace.com/SDLTest.c

Actually I do quite like SDL. I started writing a GridWars/Geometry Wars clone for the GP2X in C++/SDL and SDL was the only thing about the programming experience which didn't suck! I only gave up on it because the AI was too difficult for me to get my head around and then I started my degree ;-)

So yes, I do like SDL. It's just a shame about all the C malarkey :-P


Game AI is a headf**k... I have found it much easier though, if you run it in a separate thread... then you can just treat it as a program in its own right, and give it the same access to the game engine as the human gets.
Title: Re: Linux slideshow software
Post by: motorollin on February 01, 2009, 05:56:39 PM
Quote
bloodline wrote:
Game AI is a headf**k... I have found it much easier though, if you run it in a separate thread... then you can just treat it as a program in its own right, and give it the same access to the game engine as the human gets.

IIRC each enemy object had its own thread. The problem came when I needed to code the green square enemies. In Geometry Wars they move towards the player but avoid bullets. They move smoothly all the time, so change course to avoid the bullet but still move vaguely towards the player. I couldn't get the equations right to make them move away from the bullet without them either jumping or making sudden, drastic course adjustments away from the player.

I did have a look at the BlitzMax code for GridWars and converted the equations for the enemy movements to C, but it still didn't work properly :-(
Title: Re: Linux slideshow software
Post by: bloodline on February 01, 2009, 06:18:36 PM
Grid Wars: http://www.youtube.com/watch?v=EKBuz6oWGzg


Probably a problem with your detection algorithm...
Title: Re: Linux slideshow software
Post by: motorollin on February 01, 2009, 06:42:41 PM
I played GridWars a lot before starting on my GP2X remake. The problem was probably a combination between the detection algorithm and the movement code.

I think the way I did it was for the bullets to tell the green squares to move. So when the bullet moved, it checked the position of all the green squares. If any of them were in its path it triggered a method in them to get out of the way. Probably not the most efficient way, but it's the only way I could find which remotely worked.

Shortly after I gave up, Geometry Wars Was released for the Nintendo DS, so I didn't need to remake it any more ;-)
Title: Re: Linux slideshow software
Post by: Oliver on February 03, 2009, 05:49:39 PM
Quote
motorollin wrote:
I have looked at qiv already and is almost perfect. The problem with it is that it seems to require a text file containing the names of the images you want it to display (the -F parameter in other words). Do you know if it's possible to use it without that, by telling it to use a directory as the location of the images?


How about automating the generation of a directory list as a text file for qiv to use at startup? Perhaps it would be possible to periodically send a signal to qiv to update its list? I haven't used qiv before, and not sure if it can be caused to update on the fly (i'm thinking in terms of a daemon which can be caused to re-read its environment variables, and settings, etc.).
Title: Re: Linux slideshow software
Post by: motorollin on February 03, 2009, 07:47:46 PM
Hmm, good idea! A shell script to create the file and then launch qiv should be just the thing. Thanks!
Title: Re: Linux slideshow software
Post by: Oliver on February 04, 2009, 12:27:17 AM
Quote
motorollin wrote:
Hmm, good idea! A shell script to create the file and then launch qiv should be just the thing. Thanks!


 :-)
Title: Re: Linux slideshow software
Post by: motorollin on February 04, 2009, 05:01:57 PM
Well it turns out the --file parameter is optional. If you omit it, then qiv expects the filename to be passed as the last argument. So you can just do "qiv [options] ~/Pictures/*"

Unfortunately, qiv can't scale images in such a way that you don't get a letterbox effect, so I'll have to keep looking :-(