Skip to content

Instantly share code, notes, and snippets.

@haru067
Created February 13, 2020 07:36
Show Gist options
  • Save haru067/e768cad6996f7467cbdb32a12cb66b0b to your computer and use it in GitHub Desktop.
Save haru067/e768cad6996f7467cbdb32a12cb66b0b to your computer and use it in GitHub Desktop.
gaming
# Usage: ./gaming.sh target.png
filename=$(basename -- "$1")
extension="${filename##*.}"
filename="${filename%.*}"
for i in 0 1 2 3 4; do
convert $1 -modulate 100,100,$(((($i + 3) % 5) * 33)) $filename$i.png
done
convert -delay 3 -loop 0 $filename*.png $filename.gif;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment