Created
July 27, 2016 23:19
-
-
Save antonioalmeida/5cc29000c6958614f41ccd35a159fa2e to your computer and use it in GitHub Desktop.
Squares all images in a directory (Requires ImageMagick)
This file contains hidden or 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
for f in *.png | |
do | |
convert $f \ | |
\( +clone -rotate 90 +clone -mosaic +level-colors white \) \ | |
+swap -gravity center -composite "square $f" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment