Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Thu 21 Sep 2017, 22:52
All times are UTC - 4
 Forum index » Advanced Topics » Puppy Projects
Animated Gif wallpaper
Moderators: Flash, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 2 of 2 [24 Posts]   Goto page: Previous 1, 2
Author Message
greengeek


Joined: 20 Jul 2010
Posts: 4639
Location: Republic of Novo Zelande

PostPosted: Fri 20 May 2016, 02:06    Post subject:  

puppyluvr wrote:
As for the wallpaper request I found it is possible.
Using xwinwrap from here:
http://tech.shantanugoel.com/resources/downloads/shantz-xwinwrap.zip.
I havent had any success with this yet. Anyone else getting this going ok yet? Will keep trying.
Back to top
View user's profile Send private message 
goingnuts

Joined: 07 Dec 2008
Posts: 891

PostPosted: Sun 22 May 2016, 14:50    Post subject:  

I got xwinwrap working - sort of. Below script runs OK but I need to give focus to ROX background for the image to turn up (click on the background)...Thats a ROX-thing - running without ROX shows image immediately on the root-background

Code:
#!/bin/sh
# Uses xwinwrap to display given animated .gif in the center of the screen
#original from https://sathisharthars.wordpress.com/tag/xwinwrap/
if [ $# -ne 1 ]; then
echo 1>&2 Usage: $0 image.gif
exit 1
fi

#get screen resolution
SCRH=$(xrandr | awk '/current/ { print $8 }')
SCRW=$(xrandr | awk '/current/ { print $10 }')
SCRW=${SCRW%\,}

#get gif resolution
IMGHW=$(gifsicle -I $1 | grep logical | cut -d " " -f5)
IMGH=${IMGHW%x*}
IMGW=${IMGHW#*x}

#calculate position
POSH=$((($SCRH/2)-($IMGH/2)))
POSW=$((($SCRW/2)-($IMGW/2)))

xwinwrap -g ${IMGHW}+${POSH}+${POSW} -ov -ni -s -nf -- gifview -w WID $1 -a

exit
Back to top
View user's profile Send private message Visit poster's website 
puppyluvr


Joined: 06 Jan 2008
Posts: 3447
Location: Chickasha Oklahoma

PostPosted: Sun 22 May 2016, 22:28    Post subject:  

Very Happy Helli,
Its amazing what a single question can produce here!!!
Cool

_________________
Close the Windows, and open your eyes, to a whole new world
I am the Admin of the
Puppy Linux Users Group on Facebook
Join us!

Puppy since 2.15CE...
Back to top
View user's profile Send private message Visit poster's website 
ETP


Joined: 19 Oct 2010
Posts: 995
Location: UK

PostPosted: Mon 10 Jul 2017, 09:21    Post subject:
Subject description: An alternative when a gif is not available.
 

Even later to the party Smile I stumbled accross this site this morning and took a fancy to the rotating globe:

http://eventregistry.org/

Incorrectly assuming at first that it was an animated gif I googled "Puppy Linux animated desktop" which
brought me to this thread. Upon returning to the above site it transpired that it uses I think, a series
of png files. A different approach was therefore needed which for the record I am including here.

That involved capturing a 47 second 30fps mkv video using SSR and then using mpv to play a looped video of the recording.
The wallpaper was set to match the background of the video.
mpv has about 470 cli commands including --geometry so it is possible to play such a video anywhere on screen and
to resize it. CPU usage is only 1%.

As I wanted it center screen I however called another script to do that.

A one minute 1080p unlisted YT video of the result follows together with copies of the scripts:

https://youtu.be/7FThgscLkTI

Code:
#!/bin/sh
#
# This is mpv_test_globe.sh      ETP 10th July 2017.
#
#sleep 20 # Uncomment & adjust period as required if this script is placed in /root/Startup
#
/usr/bin/mpv --no-border --loop /root/Downloads/globe.mkv &
#
# Extra script called to ensure any window is always centered on screen. ETP JUly 2017
#
sleep 1.5
bash /root/noob/center_active_window.sh


Code:
#!/bin/sh
# This is /root/noob/center_active_window.sh  ETP 2nd May 2017.
# Call it from the end of any other launch script using the bash command to center app window on any screen.
# Bash is used in order to allow command substitution. Add a sleep of 2 or 3 seconds to allow app such as
# vlc to launch before calling it. (See example in /root/noob/BBC_News_Live_720p
#
#
IFS='x' read screenWidth screenHeight < <(xdpyinfo | grep dimensions | grep -o '[0-9x]*' | head -n1)

width=$(xdotool getactivewindow getwindowgeometry --sh | head -4 | tail -1 | sed 's/[^0-9]*//')
height=$(xdotool getactivewindow getwindowgeometry --sh | head -5 | tail -1 | sed 's/[^0-9]*//')

newPosX=$((screenWidth/2-width/2))
newPosY=$((screenHeight/2-height/2))

xdotool getactivewindow windowmove "$newPosX" "$newPosY"

_________________
Regards ETP



Kennels
Back to top
View user's profile Send private message 
rufwoof

Joined: 24 Feb 2014
Posts: 2095

PostPosted: Mon 10 Jul 2017, 16:37    Post subject:  

Thanks for sharing that ETP.

I had to add a inf (for infinite loops) parameter to the loop option. I used openshot to create a 3D title (rotate), but that had a grey background. I edited the rotate.py script as per this posting hoping for a transparent background, but it was black.

I've also been playing around with Mike's type desktop theming/layout. What with that animation and gkrellm presenting system monitoring updates ... quite a busy desktop

Fun stuff to whileaway some humid time in front of the ac. Thanks.
s.jpg
 Description   
 Filesize   40.38 KB
 Viewed   280 Time(s)

s.jpg

Back to top
View user's profile Send private message 
rufwoof

Joined: 24 Feb 2014
Posts: 2095

PostPosted: Mon 10 Jul 2017, 17:47    Post subject: Re: Animated Gif wallpaper
Subject description: Is it possible???
 

greengeek wrote:
I would like my Puppy to have an animated gif as it's desktop wallpaper. Is this possible? If not can anyone suggest a way it could be attempted?

ps: If it isn't possible to have the whole wallpaper as an animated gif I would probably settle for having a portion of the desktop displaying an animated gif if it could be displayed without borders or title bar - eg: I could have a black desktop with an animated gif in the centre.
(Probably the gif portion would be incapable of supporting icons - but I could live with that if theres no other way).

This works ...
Code:
mplayer -loop 0 -rootwin some-animated.gif

But eats resources, and you have to have the desktop (rox) off ... so no desktop icons (I use pcmanfm --desktop for desktop icon management and ran killall pcmanfm).

Attached image shows giffy.gif (a largish animated gif I downloaded) with that mplayer command running and with pcmanfm --desktop (i.e. rox pin) off.
s.jpg
 Description   
 Filesize   29.41 KB
 Viewed   261 Time(s)

s.jpg

Back to top
View user's profile Send private message 
rufwoof

Joined: 24 Feb 2014
Posts: 2095

PostPosted: Mon 10 Jul 2017, 18:39    Post subject:  

Needs mplayer and rtmpdump and desktop turned off (just xorg and jwm, no rox pinboard or other desktop)
Code:
mplayer -vf scale -zoom -xy 1280 -loop 0 -rootwin mms://media4.abc.net.au/broadbandkids/20070521_1500/story1hi.wmv


Back to top
View user's profile Send private message 
rufwoof

Joined: 24 Feb 2014
Posts: 2095

PostPosted: Mon 10 Jul 2017, 21:58    Post subject:  

I use .jwmrc as the single control file (settings and startup), messy at present, but I've swapped out the desktop icons manager (pcmanfm --desktop) and instead call a script (that I've called wallpaper)

Code:
   <StartupCommand>setxkbmap -option terminate:ctrl_alt_bksp</StartupCommand>

<!--   <StartupCommand>sleep 8s &amp;&amp; pcmanfm --desktop</StartupCommand>  -->
   <StartupCommand>sleep 8s &amp;&amp;exec /home/user/Desktop/Docs/scripts/wallpaper</StartupCommand>
 
   <StartupCommand>numlockx</StartupCommand>
   <StartupCommand>sleep 8s &amp;&amp; osmo</StartupCommand>
   <StartupCommand>sleep 4s &amp;&amp; xrandr --output DVI-I-2 --mode 1280x768 --output DVI-I-1 --off;sleep 2s &amp;&amp;xrandr --output DVI-I-2 --mode 1280x720_60.00 --output DVI-I-1 --off</StartupCommand>
   <StartupCommand>sleep 8s &amp;&amp; radiotray</StartupCommand>
   <StartupCommand>sleep 4s &amp;&amp; libreoffice --quickstart</StartupCommand>
   <StartupCommand>sleep 4s &amp;&amp; wicd-client --tray</StartupCommand>
   <StartupCommand>sleep 4s &amp;&amp; volumeicon</StartupCommand>


that wallpaper script contains

Code:
#!/bin/bash

cd /home/user/Desktop/Docs/scripts
echo lady-gaga-poker-face.mp4 >playlist
echo lady-gaga-judas1.mp4 >>playlist
echo lady-gaga-bad-romance.mp4 >>playlist
echo gossip-heavy-cross.mp4 >>playlist
mplayer -vf scale -zoom -xy 1280 -loop 0 -rootwin -playlist playlist

which just loops through the playlist indefinitely (loop 0) using the root window as the display (I scaled it to my screen resolution level of 1280x720 (720p)).

i.e. the wallpaper is animated in the sense that its a mplayer playlist of vids.

A neat thing is you can just add the desktop icons back in, in my case by running pcmanfm --desktop and the normal icon type desktop appears (and the vids still keep playing, but are sound only). Then stop the desktop ... and the vids appear again. i.e. toggle the desktop (icons) on and off as desired.

I think in rox you could do similar by setting
Code:
rox --pinboard=xxxx
and unsetting (assign a empty value
Code:
rox --pinboard=


Pulseaudio and pavucontrol is quite handy as a single frame shows all of the different channels that are playing and you can dial-up/down the individual channels (maybe turn down the 'wallpaper' to turn up the radio ... or a currently playing youtube ...etc.).
Back to top
View user's profile Send private message 
rufwoof

Joined: 24 Feb 2014
Posts: 2095

PostPosted: Wed 12 Jul 2017, 08:44    Post subject:  

For ROX (tested under tahr 6.0.6 32 bit pae built from WoofCE with mplayer added in)

Turn the pinboard off with
Code:
rox --pinboard=

And back on again with
Code:
rox -p=$HOME/Choices/ROX-Filer/PuppyPin


So if you've set a animation or video to play on the 'desktop', such as

echo $HOME/LadyGagaJudas.mp4 >$HOME/playlist
mplayer -vf scale -zoom -xy 1280 -loop 0 -rootwin -playlist $HOME/playlist

You can toggle between seeing the normal (rox pin) desktop icons, or the video/animation that's playing

Could be useful for a Puppy News type setup, perhaps where a weekly/monthly/whatever news video is downloaded and set to loop play on the normally hidden desktop, but where a toggle button/icon displays/hides that.
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 2 of 2 [24 Posts]   Goto page: Previous 1, 2
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Puppy Projects
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0512s ][ Queries: 13 (0.0065s) ][ GZIP on ]