Difference between revisions of "Photo Screen Saver - Disable pan/zoom"
Line 66: | Line 66: | ||
Then in a terminal session from ~/LinuxMCE-0710/src/Photo_Screen_Saver (running as root): | Then in a terminal session from ~/LinuxMCE-0710/src/Photo_Screen_Saver (running as root): | ||
− | make bin | + | make bin (Creating the new executable Photo_Screen_Saver) |
− | cp Photo_Screen_Saver /usr/pluto/bin | + | cp /usr/pluto/bin/Photo_Screen_Saver ~/ (Making a backup of the original executable) |
+ | cp Photo_Screen_Saver /usr/pluto/bin (Copying the new executable over the original) | ||
You have now changed, compiled and replaced the Photo_Screen_Saver executable. Do a quick reload of your router and the images on your screen saver will not be zoomed in, the entire image will be visible on your screen. | You have now changed, compiled and replaced the Photo_Screen_Saver executable. Do a quick reload of your router and the images on your screen saver will not be zoomed in, the entire image will be visible on your screen. |
Revision as of 17:49, 30 January 2009
Contents
Introduction
The photo screen saver is doing three things with your photos.
- Panning (Image moves across the screen randomly)
- Fading (The transition effect when changing from one image to another)
- Zooming (Image is randomly zoomed in on, displaying only a portion of the total image)
The first two are simply settings in webadmin, zooming had to be handled programatically.
Panning
In WebAdmin go to ADVANCED > CONFIGURATION > DEVICES on the top menu. Once you click 'DEVICES' the left menu will change.
On the left menu click the Core/MD you wish to change then click 'OnScreen Orbiter' then 'Photo Screen Saver' below that.
You are now looking at the configuration of the screen saver for that media director. In the 'Device Data' section you will see 'Zoom Time' which is defaulted to 10000 (this is milliseconds so 10000 = 10 seconds). The title 'Zoom Time' is a bit misleading as it actually controls panning and zooming. If you set this setting to 0 your screensaver will still randomly zoom in on images and fade between images however it will not pan across the screen and the zoom will not be animated. The image will simply fade in at a random zoom level and stay that way until another image fades in to replace it.
Fading
In WebAdmin go to ADVANCED > CONFIGURATION > DEVICES on the top menu. Once you click 'DEVICES' the left menu will change.
On the left menu click the Core/MD you wish to change then click 'OnScreen Orbiter' then 'Photo Screen Saver' below that.
You are now looking at the configuration of the screen saver for that media director. In the 'Device Data' section you will see 'Fade Time' which is defaulted to 3500 (3.5 seconds). This is the time it takes to fade an image in to replace the current image. Setting this to 0 will cause the images to simply change instantly. Obviously, setting it to a greater duration causes the image to fade in more slowly.
Zooming
There is no setting in WebAdmin to disable zooming in on images all together. This had to be done by modifying the source code of the Photo_Screen_Saver.
First you must build a development environment as per these posts:
http://wiki.linuxmce.org/index.php/Setting_Up_A_Development_Environment http://wiki.linuxmce.org/index.php/Building_From_Source
As of the time of this article neither of these can be followed step by step as they both seem to be dated and/or incomplete. Here are the commands I used taken from both of the above articles.
sudo apt-get install subversion build-essential ccache cd ~/ svn co http://svn.linuxmce.org/svn/branches/LinuxMCE-0710/ cd LinuxMCE-0710 cp /usr/pluto/lib/* src/lib find . -iname Makefile -exec sed -e 's/<-mkr_t_compile_defines->/-DKDE_LMCE -DDEBUG -DTHREAD_LOG -DLOG_ALL_QUERIES -I\/opt\/libxine1-pluto\/include -I\/opt\/libsdl1.2-1.2.7+1.2.8cvs20041007\/include -I\/opt\/libsdl1.2-1.2.7+1.2.8cvs20041007\/include\/SD/' -i '{}' \; find . -iname Makefile -exec sed -e 's/<-mkr_t_compile_libs->/-L\/opt\/libxine1-pluto\/lib -L\/opt\/libsdl1.2-1.2.7+1.2.8cvs20041007\/lib/' -i '{}' \;
Now we are ready to edit the Photo_Screen_Saver
I actually use a combination of the GUI and a root terminal session, use whatever methods you're comfortable with.
Go to ~/LinuxMCE-0710/src/Photo_Screen_Saver and edit ZoomSimple.cpp You will see these two lines:
ZoomAmount1 = RandomInInterval(500, 1000)/1000.0f; and ZoomAmount2 = RandomInInterval(500, 1000)/1000.0f;
Change both of these lines to:
ZoomAmount1 = RandomInInterval(1, 2)/1.0f; and ZoomAmount2 = RandomInInterval(1, 2)/1.0f;
Save the file. Then in a terminal session from ~/LinuxMCE-0710/src/Photo_Screen_Saver (running as root):
make bin (Creating the new executable Photo_Screen_Saver) cp /usr/pluto/bin/Photo_Screen_Saver ~/ (Making a backup of the original executable) cp Photo_Screen_Saver /usr/pluto/bin (Copying the new executable over the original)
You have now changed, compiled and replaced the Photo_Screen_Saver executable. Do a quick reload of your router and the images on your screen saver will not be zoomed in, the entire image will be visible on your screen.
IMPORTANT NOTE: If you are running both i386 and amd64 architectures in your installation this process has to be done on each to generate the correct executable for the corresponding platform.