Image editing using ImageMagick

To install the package:

sudo apt-get install imagemagick

To resize pictures:

convert source.jpg -scale 200x200 destination.jpg

Another option can be:

convert source.jpg -scale 200 destination.jpg

(This will scale the image to 200 width keeping the aspect ratio)

To know the file details, any of the following commands will work:

file source.jpg
identify source.jpg
identify -verbose source.jpg
convert source.jpg -print "Size: %wx%h" /dev/null
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s