[magick-users] Vertical split

Anthony Thyssen A.Thyssen at griffith.edu.au
Mon Jun 8 21:06:55 PDT 2009


On Mon, 8 Jun 2009 18:04:47 +0200
Guido Milanese <guido.milanese at gmail.com> wrote:

| I am sorry for asking a trivial question, but I normally use 
| Imagemagick at a very basic level
| I would like to split a collection of images (scanning from a book) 
| in 2 equal vertical images:
| 
| |----------|
| |          |
| |          |	file01.jpg
| |----------|
| 
| |-----|-----|
| |     |     |	file01a.jpg file01b.jpg
| |     |     |
| |-----|-----|
| 
| i.e. the even and odd page. I could obtain this with gimp or 
| similar, but since I have about 50 files I would like to do via 
| command line with a script. I tried with crop but I was lost in page 
| geometry!
| 
mogrify -crop 50%x100% +repage  +adjoin  images...

the images will be resaved with a -0 or -1 addition to their filename.

EG:
  convert rose: rose_1.png
  mogrify -crop 50%x100% +repage +adjoin rose_1.png

will create the images rose_1-0.png rose_1-1.png


  Anthony Thyssen ( System Programmer )    <A.Thyssen at griffith.edu.au>
 -----------------------------------------------------------------------------
    Instead of wasting my energy bemoaning what I didn't know,
    I should be using what I DID know to expand my own horizons.
                        -- Robert Asprin  "Myth-nomers and Im-pervections"
 -----------------------------------------------------------------------------
     Anthony's Home is his Castle     http://www.cit.gu.edu.au/~anthony/


More information about the Magick-users mailing list