Created
June 6, 2018 21:05
-
-
Save nemanjan00/22d53dc5206117a5fe54a32cc8f39bd4 to your computer and use it in GitHub Desktop.
Video wallpaper
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# credits: https://www.reddit.com/r/unixporn/comments/8p2u34/animated_backgrounds/e08a650/ | |
_screen() { | |
xwinwrap -ov -g $1 -- mpv --fullscreen\ | |
--on-all-workspaces \ | |
--no-stop-screensaver \ | |
--loop-file --no-audio --no-osc --no-osd-bar -wid WID --quiet \ | |
"$2" --background="$3" --video-zoom="$4" & | |
} | |
killall xwinwrap | |
sleep 0.5 | |
for i in $( xrandr -q | grep ' connected' | grep -oP '\d+x\d+\+\d+\+\d+') | |
do | |
_screen $i "$1" "${2:-#000000}" "${3:-0}" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment