Skip to content

Instantly share code, notes, and snippets.



Last active Jan 27, 2019
What would you like to do?
Shell script to split two-spread image into two different images. Uses ImageMagick.
# Split two-spread image into two different images (leaving some overlap for safety)
# Usage: splitimage filename.jpg
# ----------------------------------------------------------------------------------
convert $1 -crop 56x100%+0+0 +repage output/`basename $1 .jpg`a.jpg
convert $1 -flop -crop 60x100%+0+0 -flop +repage output/`basename $1 .jpg`b.jpg
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment