SlideShow (GL)

Screensavers

Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on opencode.net

0
5.0
Description:

This is a KDE slide show screensaver which uses OpenGL for smooth zooming and crossfades. It has a simular feel to that of the MacOS X slideshow screensaver. Note that since this uses OpenGL textures for the images, you will need significant amounts of texture memory on your card for this to work well (especially for large images).

I would appreciate any _constructive_ input. I changed some of the features of the screensaver: The images used to have a vignette effect, and you could select the size of the image; now the image is always sized so that it fills the screen. Which is preferable? Should it be an option? Does the incremental jpeg loader work? Does it eliminate the lag between images?
Last changelog:

17 years ago

- Added support for png images. They are loaded incrementally just like the jpegs, so skipping shouldn't be a problem. please report any problems.

- Stability improvements. Works on both greyscale and color jpeg's now (before it would crash on greyscale jpegs). Gracefully handles unmounting of drives which images are stored on (i.e. it doesn't crash when it can't read an image). Added an option to display the image name in the lower left hand corner. Also, the screensaver no longer always zooms towards the center of an image. It can zoom to any portion of the image, but gives preference to the top half for portrait oriented images (since that is where the center of focus normally resides in portraits). Didn't update the preview cause I'm too lazy.

- Added line to link to libjpeg. For some reason it worked on my machine without it.

- Image directory selection will now traverse into any subdirectories up to depth 1. This means you can effectively use multiple directories for source images by creating a directory with symlinks to your image directories.

- Much faster load up time, much smaller memory footprint, and uses much less CPU time than before.

- Implemented a incremental jpeg loader that (hopefully) prevents jerkiness between images. Movement should be smooth, unless of course, you set the delay time to something very small and your machine cannot finish loading the next image before it is due for display.

djwilly

17 years ago

Well, the indexing problem is not the randomize feature... you didn't understand me:

The desired behaviour:
-Show A
-Start transition from A to B
-End transition from A to B
-Show B
[...]

The real behaviour on my computer:
-Show A
-Start transition from [any image] to [other image]
-End that transition
-Show B

Understand now? Sorry, i can't speak better the english :)

Well, it's possible that the split screen issue come from my card. It's a 32Mb TNT2... If it was the problem, I think those requirements are unacceptable for a slide show program... even quake3 or gta3 require less amount of memory :) What about scaling the image to the screen resolution before displaying it? It would require much much less memory... can it be possible without an huge performance loss? It's only an idea :)

byee

Report

C

wjarosz

17 years ago

I don't know if i understand what you are saying about the transition. Do you mean that image A transitions to image B, and then suddenly the image changes to an image C without any transition?

The reason that quake3 can work is because it's not loading 4096x4096 images as textures. this should not be a problem if you are running the screensaver on normal sized images (1280x1024, 1600x1200), however if you do load images larger than 2048x2048, you will run out of texture memory. It is possible to scale the image before hand, but in order to do that without causing any skips I would have to implement an incremental image scaler. I could then do a little bit of scaling at each frame, instead of scaling the whole image at once and lagging the animation. Even then, if the machine isn't fast enough, lagging will most likely occure. It's alot of coding for something that could be easily avoided by not using insane image sizes if you are running on an older graphics card.

Right now the CPU time is very low, by having to scale all the images beforehand it would raise the CPU time significantly (not something that is desired from a screensaver either). Are you using images that are THAT big? I'm not convinced that this is the cause of your problem.

Report

djwilly

17 years ago

I don't know if i understand what you are saying about the transition. Do you mean that image A transitions to image B, and then suddenly the image changes to an image C without any transition?

More or less... what you have said happens, but not only that. Sometimes it's worse: I'm seeing A; If the next image is B, there should be a smooth transition from A to B. Well, sometimes, instead of A, another image (like if it is randomly chosen) do the transition with B. It's hard to explain :)

Are you using images that are THAT big? I'm not convinced that this is the cause of your problem.

Errr... well, no. They are 1280x960x24 (as my digital camera do them :)) 4mb should be enough, it seems...

Well, if you want, contact me by email and we'll talk further (djwilly@jazzfree.com).

Bye

Report

KhanReaper

17 years ago

In the screenshot provided for this project, I see a widget set of which I have little familiarity in terms of KDE styles.

From what I can ascertain, it appears similar to the GTK-2 widget set entitled "Wonderland" as seen here:

http://art.gnome.org/show_theme.php?themeID=274&category=gtk2

Since my question predicates itself upon the assumption that this screensaver utilize KDE's architecture, I assume that KDE provides these widgets for the screensaver.

If I may inquire, what KDE style did the author use to achieve this Wonderland-esque facade?

Thank you.

Report

C

wjarosz

17 years ago

That is the Bluecurve theme which is the default theme for both Gnome and KDE in Redhat 8.0/9. I'm pretty sure you can get repackaged version for other distros somewhere on this site, or you could look into freecurve or qtcurve.

Report

gooffy22

17 years ago

using mandrake 9.1, getting following error at "make install" stage. thanks for help

In file included from main.cpp:24:
/usr/lib/qt3/include/qgl.h:78:21: GL/glu.h: No such file or directory
make[2]: *** [main.o] Error 1
make[2]: Leaving directory `/home/sheldon/kslidesavergl-0.65/kslidesavergl'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/home/sheldon/kslidesavergl-0.65/kslidesavergl'
make: *** [install-recursive] Error 1

Report

tportenier

17 years ago

you have to install the following package:

"libMesaGLU1-devel"

for problems like this, try:

$ urpmf glu.h

the result is something like this:

libMesaGLU1-devel:/usr/X11R6/include/GL/glu.h

(urpmf is comfortable to find out, from which package a file comes from)

greetings... tizz

Report

gooffy22

17 years ago

ignore
found rpm file

Report

C

wjarosz

17 years ago

Do you have libGLU installed? They will either be provided by Mesa or whatever GL driver you may be using. Note that the rpm that is currently available on kde-look is not up to date with the newest version of the screensaver that I uploaded today. (AFAICT).

Report

illogic-al

17 years ago

oopsies. haven't been here in a while. i'll try to update soon.

Report

samppa

18 years ago

Very nice work. Has anyone experienced the following problem with this screensaver. When clicking on the test button to test the screensaver and then quiting it (clicking on mouse button etc), the kslideshow.kss process still stays running. Clicking test several times always leaves a new process running and if you press cancel on screensaver configuration dialog, they still keep on running, until I manually kill them.

Report

probono

18 years ago

Please make debian .debs available, this way it could be included in Knoppix (www.knoppix.net)

Report

C

wjarosz

18 years ago

I unfortunately don't have any experience in that and don't have time to teach myself at the momement. But anyone is of course welcome to make a .deb out of this and release it under the GPL.

Report

manor

18 years ago

I made screenshots of my problem.

Please have a look at
ftp://guest:guest@heiko.kicks-ass.net/

For a description of my problem check your email at hotmail.


Thanks in advance.

Report

illogic-al

18 years ago

This thing is awesome! after finally getting it to compile it took a bit of work to get it to work in mdk. I'd make an rpm but i'm sure tex'll find his way over and package it in time. but in the few hours it will take for this to happen here's what i did to get it to work on mdk 9.1:
1) i passed --prefix=/usr to the configure script with this command
./configure --prefix=/usr
and then did make both as a normal user
2) then for make install i did this
su -c "make install"
3) After the make install step i entered this command
su -c "ln -s /usr/share/apps/kscreensaver/ScreenSavers/kslidesavergl.desktop /usr/share/applnk/System/ScreenSavers/kslidesavergl.desktop"
then you just enter your root password so that the command works. Then go into the KDE control center and Voila!
Great work wjarosz, keep it up.

Report

illogic-al

18 years ago

i actually did make an rpm because of problems with it disappearing when i installed rpms in mdk

Report

probono

18 years ago

great! great! great! I *love* that Mac OS screensaver effect. I've always been looking for this on the PC. Thanks :-) I didn't try to install this yet, but this definitely should make it into standard KDE and Knoppix (bootable CD Linux that you can take with you and present your images everywhere).

This makes not only a great screensaver, but it's also great for photo presentations on a projector. For this purpose, I would like to be able to determine the sequence of the photos by name.

Also, there should be a possibility to include mp3 sound. For example, when 0001.jpg would be displayed, 0001.mp3 should start to play and continue playing until another mp3 with a "matching" name is found. mp3s should be crossfaded.

There should also be a way to "pack" presentations to burn them on CD and give them to people, including sound and picutres.

Report

brendanorr

18 years ago

When I see the preview in the setup dialog, it looks nice and normal. When I run it, however, the first image just fades to black with no other images fading in.

Report

C

wjarosz

18 years ago

Hmm, thats strange. This would mean that the first image loads fine, but all images after that either don't load correctly off of disk, or don't get uploaded to the graphics card correctly. This could possibly happen if you don't have much texture memory, or the size limit for GL textures on your card is smaller than the size of the images being loaded. It might work in the setup window because the size of the GL window is smaller, and therefore uses less video memory (therefore leaving more for the textures). Can you try it with smaller images to see if that fixes it?

Report

brendanorr

18 years ago

Yeah, using smaller pictures fixes the problem, but its not because of my graphics card not having enough memory. Its a GeForce4 w/128 megs-o-ram

Report

C

wjarosz

18 years ago

Thats strange, since I have the same card. It could be a driver or XFree issue. Are you using the NVidia drivers? Other than that I don't really know how to help, I'm by no means an expert at this. I am pretty sure that there is an OpenGL texture size limit, which is card dependent. But since I have the same card, that doesn't make sense.

At some time in the future I was considering implementing tiling so that large images are split up into multiple 64x64 texture tiles. This would ensure that they show up (I think), since in order to claim OpenGL support, a card needs to support at least a certain size texture (64x64 or something like that). That would require significant additions to the code however, and currently I have exams to worry about.

If you are comfortable enough with coding you could try playing around with the code, and I would love knowing what the problem is if you find it.

Good luck.

Report

brendanorr

18 years ago

I'm using the 4349 drivers ATM, I'll try downgrading tomorrow to see if that works, otherwise I'll try to poke around in the source a little. Thanks anyway :)

Report

manor

18 years ago

Hi !

Would someone help me please ?

I have trouble to compile SlideShow.

I have qt-3.1.1 (threaded)
kde3.1.1 (SuSE)
gcc3.2

-D_XOPEN_SOURCE=500 -D_BSD_SOURCE -Wcast-align -Wconversion -O2 -fno-exceptions -fno-check-new -o kslidesavergl -L/usr/X11R6/lib -L/usr/lib/qt3/lib -L/opt/kde3/lib -R /opt/kde3/lib -R /usr/lib/qt3/lib -R /usr/X11R6/lib main.o kslidesaverkss.o kslidesaver.o kslidesaversetup.o kslidesaver.moc.o ./math/libmath.a -lkscreensaver -lGLU -lGL -lkdeui -lkdecore -lqt-mt -lpng -lz -lm -lXext -lX11 -lresolv -lSM -lICE -lpthread -lresolv
./math/libmath.a(jpegloader.o): In function `jpegLoader::read_jpeg_image(char const*)':
jpegloader.o(.text+0x14b): undefined reference to `jpeg_std_error'
jpegloader.o(.text+0x161): undefined reference to `jpeg_CreateDecompress'
jpegloader.o(.text+0x16c): undefined reference to `jpeg_stdio_src'
jpegloader.o(.text+0x176): undefined reference to `jpeg_read_header'
jpegloader.o(.text+0x17e): undefined reference to `jpeg_start_decompress'
jpegloader.o(.text+0x216): undefined reference to `jpeg_read_scanlines'
jpegloader.o(.text+0x236): undefined reference to `jpeg_finish_decompress'
jpegloader.o(.text+0x23e): undefined reference to `jpeg_destroy_decompress'
./math/libmath.a(jpegloader.o): In function `jpegLoader::start_incremental_jpeg_read(char const*)':
jpegloader.o(.text+0x2c1): undefined reference to `jpeg_std_error'
jpegloader.o(.text+0x2d7): undefined reference to `jpeg_CreateDecompress'
jpegloader.o(.text+0x2e2): undefined reference to `jpeg_stdio_src'
jpegloader.o(.text+0x2ec): undefined reference to `jpeg_read_header'
jpegloader.o(.text+0x2f4): undefined reference to `jpeg_start_decompress'
./math/libmath.a(jpegloader.o): In function `jpegLoader::incremental_jpeg_read(int const&)':
jpegloader.o(.text+0x399): undefined reference to `jpeg_read_scanlines'
./math/libmath.a(jpegloader.o): In function `jpegLoader::finish_incremental_jpeg_read()':
jpegloader.o(.text+0x3f6): undefined reference to `jpeg_read_scanlines'
jpegloader.o(.text+0x419): undefined reference to `jpeg_finish_decompress'
jpegloader.o(.text+0x421): undefined reference to `jpeg_destroy_decompress'
collect2: ld returned 1 exit status
make[3]: *** [kslidesavergl] Fehler 1
make[3]: Verlassen des Verzeichnisses

Report

C

wjarosz

18 years ago

Check to make sure that you have libjpeg and libjpeg-devel installed. I think that should fix your problem. I will try to add a check for that into the configure script so that this gets caught earlier.

Report

manor

18 years ago

Thanks for SlideShow and your help :)

I will check either i have installed jpeg-devel or not.

Report

17 years ago

- Added support for png images. They are loaded incrementally just like the jpegs, so skipping shouldn't be a problem. please report any problems.

- Stability improvements. Works on both greyscale and color jpeg's now (before it would crash on greyscale jpegs). Gracefully handles unmounting of drives which images are stored on (i.e. it doesn't crash when it can't read an image). Added an option to display the image name in the lower left hand corner. Also, the screensaver no longer always zooms towards the center of an image. It can zoom to any portion of the image, but gives preference to the top half for portrait oriented images (since that is where the center of focus normally resides in portraits). Didn't update the preview cause I'm too lazy.

- Added line to link to libjpeg. For some reason it worked on my machine without it.

- Image directory selection will now traverse into any subdirectories up to depth 1. This means you can effectively use multiple directories for source images by creating a directory with symlinks to your image directories.

- Much faster load up time, much smaller memory footprint, and uses much less CPU time than before.

- Implemented a incremental jpeg loader that (hopefully) prevents jerkiness between images. Movement should be smooth, unless of course, you set the delay time to something very small and your machine cannot finish loading the next image before it is due for display.

12345678910
Be the first to comment
File (click to download) Version Description Downloads Date Filesize DL OCS-Install MD5SUM
*Needs pling-store or ocs-url to install things
Pling
0 Affiliates
Details
license
version
0.7
updated May 06 2003
added Apr 02 2003
downloads 24h
0
mediaviews 24h 0
pageviews 24h 0