Page 1 of 1
PNG resising file size problem
Posted: 2010-04-29T20:02:34-07:00
by gse-media
Hello,
I did search the forum but did not find a solution to this, or overlooked it. I am resisizing some PNG images and getting obscene file sizes for some of the output (smaller resolution) images. The command I'm using is:
convert > [original file] -resize '400' -strip -quality 90 -unsharp 4.5x.5 [output file]
An example of results:
Original file: 582 x 800 : 58.6KB : 1027 colors
Resize 1: 400 x 550 : 304KB : 3161 colors
Resize 2: 73 x 100 : 31KB : 550 colors
Any help would be appreciated. This is killing me!
Re: PNG resising file size problem
Posted: 2010-04-29T20:55:46-07:00
by snibgo
It would help us if you posted the images (put them on the web somewhere and tell us the URLs).
I would expect sharpening to increase the sizes.
Re: PNG resising file size problem
Posted: 2010-04-29T21:03:08-07:00
by gse-media
Sure thing:
Original:
http://www.freestockphotos.biz/download ... /11440.png
Resize 1:
http://www.freestockphotos.biz/pictures ... 40/egg.png (slightly smaller dimensions, much higher file size)
Resize 2:
http://www.freestockphotos.biz/thumbs_0 ... _11440.png (much smaller dimensions, somewhat smaller, but still larger than expected file size)
Re: PNG resising file size problem
Posted: 2010-04-29T21:05:35-07:00
by fmw42
IM does not necessarily make optimized size pngs. Also be sure you are using -quality correctly. see
http://www.imagemagick.org/Usage/formats/#png_quality and
http://www.imagemagick.org/Usage/formats/#png_non-im
Re: PNG resising file size problem
Posted: 2010-04-29T21:12:48-07:00
by gse-media
Thanks fmw42,
I did read up on the -quality for pngs after I originally posted, and did quite a few tests without any significant results. I will look at some of the other optimizer possibilities, but not sure if they'll be available for me to use.
Re: PNG resising file size problem
Posted: 2010-04-29T21:23:01-07:00
by snibgo
What version IM do you use, on what platform? Your commands on IM 6.6.0-8 Q16 Windows 7 gives egg.png as 69785 bytes. Partly because it outputs 8-bit channels, not 16-bit.
Re: PNG resising file size problem
Posted: 2010-04-29T21:31:27-07:00
by fmw42
If on Q16, add -depth 8 to generate 8 bits per channel rather than 16 bits per channel. Also see PNG8: vs PNG32: and PNG24
http://www.imagemagick.org/Usage/formats/#png_formats and png controls at
http://www.imagemagick.org/Usage/formats/#png_write
Re: PNG resising file size problem
Posted: 2010-04-29T21:36:42-07:00
by gse-media
It looks like I am using version: 6.3.9 12/10/08 Q16
I will have to talk to my web host to see about updating the version.
I will try -depth and do the reading up. Thank you for your help so far, I appreciate it!