Search code examples
c++clibjpeglibpng

Which is slower, jpeg or png?


I was wondering if there is a significant difference in the decompression process of these two types of image: Which is slower, JPEG or PNG?


Solution

  • The many commenters here who say "it depends" are wrong. PNG decompression is always slower than JPG decompression, in every study that has been reported. Plus I personally have verified this in several different projects.

    There is no such thing as an uncompressed PNG, despite greg's assertion to the contrary. All PNGs are compressed, and the compression of all PNGs is lossless. And decompressing all PNGs is sorta slow, compared to comparable JPGs.

    All JPGs are compressed too, but JPG compression is always lossy. In particular, JPEG at 100 quality is NOT uncompressed. Quality 100 still has lossy compression, despite Ed S.'s assertion to the contrary. Please stop upvoting his comment.