I am resizing images using ImageMagick. If I pass a -resize WxH option it behaves as expected. But if I pass -resize WxH! (to ignore aspect ratio during resize), some images, especially PNGs, are actually increasing in size. A 200k image becomes 450k, a 170k image becomes 360k and so on.
Any ideas why this is hapenning and how to fix it?
Thanks
To resize an image to specific dimensions, use the convert command with an input file, the -resize parameter, your preferred dimensions, and an output filename: convert original. png -resize 100x100 new. png.
If you're not sure what ImageMagick is, it's one of the greatest tools you could have on your computer, to manipulate images and a few other types of files.
After researching, I upgraded my ImageMagick version from 6.3.7 to 6.5.6, and now it is working great. Resizing images is generating smaller images and everything is OK.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With