Mozilla Introduces New JPEG Encoding Library

Written by Michael Larabel in Mozilla on 6 March 2014 at 09:41 AM EST. 14 Comments
MOZILLA
Mozilla has introduced a new open-source JPEG encoding library that it claims can measurably reduce the file-size of encoded images.

Mozilla this week announced "mozjpeg" as one of their latest open-source projects and this library is yielding file-sizes smaller than other JPEG libraries while at comparable image quality levels. Mozilla says with mozjpeg is about a 10% reduction in file-size over alternatives.

For achieving the smaller file-sizes, mozjpeg is incorporating different algorithms into its JPEG encoder. Particularly, the Mozilla work is based upon libjpeg-turbo but with jpgcrush code added in. Josh Aas of Mozilla wrote in a blog post on Wednesday when announcing version 1.0, "We noticed that people have been reducing JPEG file sizes using a perl script written by Loren Merritt called ‘jpgcrush’, references to which can be found on various forums around the Web. It losslessly reduces file sizes, typically by 2-6% for PNGs encoded to JPEG by IJG libjpeg, and 10% on average for a sample of 1500 JPEG files from Wikimedia. It does this by figuring out which progressive coding configuration uses the fewest bits. So far as we know, no production encoder has this functionality built in, so we added it as the first feature in ‘mozjpeg’."

Mozilla also has further plans to improve encoding by utilizing trellis quantization.

The code to this new JPEG library can be found as mozjpeg on GitHub. The code is under a BSD-style license.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week