Create Thumbnails in Linux
Posted on July 3rd, 2008 at 9:25 amWell as if there are not enough how-to’s out there here comes another one folks. I was asked the other day how can I make thumbnails in Linux. Well binky here is the fast way to start. You can change the .png to .jpg or what ever it is that you need and it is that simple, all you need is Imagemagick installed and follow the instructions below and you will be a happy camper.
You need to pass -thumbnail argument to convert command:
convert thumbnail
So to create a thumbnail of the abc.png image with 200px width, you need to type:
$ convert -thumbnail 200 abc.png thumb.abc.png
To create a thumbnail of the abc.png image with 200px height, you need to type:
$ convert -thumbnail x200 abc.png thumb.abc.png
And you can convert the conversion by changing the thumb to tn if you desire and there are a couple of other options that you can toss in if you desire.
But wait you say you have a entire folder full of pictures that you want to turn into thumbnails, and the process above does them one at time. Well spanky just add this little script to your list of must keep handy files and you be in business;
for file in *.jpg
do
convert -resize 200 “$file” thumb_”$file”
done
simple huh? Well have fun and enjoy and don’t forget to teach as you learn and linux will continue to expand it’s user base, Baldy
Leave a Reply
You must be logged in to post a comment.