May 21, 2009

Batch processing: modify images with mogrify

Did you ever think about resizing many images or cutting an area out of many images?
Yes you can open every single image with gimp and click through all the menus (image -> scale image -> new values -> ok). For selecting an area you can use your mouse and just do crtl-c (copy), crtl-shft-v (paste into new) and then crtl-shft-s (save as).
But there is a small command, which can do all this work for you:


mogrify (from ImageMagick)



With this tool you can resize your image just with this command:
mogrify -resize 640x480 *.jpg
or using a percentage:
mogrify -resize 50% *.jpg
Or cutting an area out of image serie:
mogrify -extract 370x295+124+102 *.jpg
There are much more options you can use...

No comments:

Post a Comment