convert jpg to png creates very large file

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: convert jpg to png creates very large file

Post by anthony »

You can not keep the same file size in PNG as you can in JPG. Jpeg is a very highly compressed (loosy compressed) image file format. PNG is an exact compression image format that will not loose information to make it compress better. As such a PNG image is always a lot bigger than a JPG image.

You can improve the compression of PNg by setting a specific quality level
-quality 92 is good for general cartton like images or diagrams, while 95 is good for photos. the 9 is the compression level, the second number is the data storage filter style.

See IM examples PNG format
http://www.imagemagick.org/Usage/formats/#png
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
Post Reply