Page 1 of 1

creating smallest filesize

Posted: 2010-09-03T05:18:03-07:00
by jenik
Hi Guys,

I have trouble with resizing small thumbnail of bibberst images for my web:

exammple: http://fototest.mracek.org/list.php?addr=Screensawer

The thumbnail have approximately 20-30KB !! Is very big !
Photoshop make 6KB pictore. This is very good.
Can you help me, what I make bad ??

You can downalod this image : http://fototest.mracek.org/Screensawer/ ... G_0024.jpg
Image
23KB and compres using imagemagic.

My command line is:
convert -verbose -quality 75 -density 72 -depth 8 -resize 159x159 -gravity Center -crop 106x106+0+0 {} small/{} | echo {}
for example.

Thank you for any idea !

Jan

Re: creating smallest filesize

Posted: 2010-09-03T14:42:18-07:00
by fmw42
IM 6.6.3.10 Q16 (HDRI) Mac OSX tiger


convert IMG_0024.jpg -thumbnail 159x159 \
> -gravity Center -crop 106x106+0+0 +repage \
> -density 72 -quality 75 -depth 8 IMG_0024_thumb.jpg

identify IMG_0024_thumb.jpg
IMG_0024_thumb.jpg JPEG 106x106 106x106+0+0 8-bit DirectClass 2.88KB 0.000u 0:00.019

2KB file size

see correct syntax at http://www.imagemagick.org/Usage/basics/#cmdline

Re: creating smallest filesize

Posted: 2010-09-06T02:18:49-07:00
by jenik
dear fmw42,

wow, your tip help me a lot !
I looked to many pages at last 2 days and this option I never found.
Thank you very much.
regards, Jan

Re: creating smallest filesize

Posted: 2010-09-06T10:16:06-07:00
by fmw42
Part of your problem may have been syntax order. Part was not getting rid of the headers and profiles (which you could do with -strip -resize rather than -thumbnail) and part was not adding +repage to remove the virtual canvas.

see

http://www.imagemagick.org/Usage/basics/#cmdline
http://www.imagemagick.org/Usage/crop/#crop_repage
http://www.imagemagick.org/script/comma ... #thumbnail