Using ImageMagick’s convert to resize all jpg’s in a directory

Written by James McDonald

October 25, 2007

Using cygwin with ImageMagick installed you can resize entire directories of jpegs using the convert utility

for i in `ls *.jpg`; do convert -resize 30% -quality 80 $i conv_$i; done

The 30% made images with a resolution of 3072 x 2304 pixels (approx 1.6 to 2.1MB each) into 922 x 691 (approx 80KB to 140KB each)

Experiment with different percentages to get your desired size.

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

You May Also Like…

How to Research a CPU Upgrade

How to Research a CPU Upgrade

Upgrade Time! Doing a lot of VMWare Workstation virtualization to create labs for self-study and training. Finding...