How To Install Mozjpeg 2.0, Improved JPEG Encoding Library.

Recently Mozilla announced its JPEG encoding library with following improvements as quoted from Mozilla blog itself
The major feature in this release is trellis quantization, which improves compression for both baseline and progressive JPEGs without sacrificing anything in terms of compatibility. Previous versions of mozjpeg only improved compression for progressive JPEGs.

Other improvements include:

  • The cjpeg utility now supports JPEG input in order to simplify re-compression workflows.
  • We’ve added options to specifically tune for PSNR, PSNR-HVS-M, SSIM, and MS-SSIM metrics.
  • We now generate a single DC scan by default in order to be compatible with decoders that can’t handle arbitrary DC scans.
For more detail, read : #-Link-Snipped-#

How To Install ?

- Download source code from Release mozjpeg v2.0 · mozilla/mozjpeg · GitHub
- Extract it
- Install required libs i.e autoconf, automake, make, nasm & libtool


Now let's build :
- cd mozjpeg-2.0
- autoreconf -fiv
- mkdir build
- cd build
- sh ../configure
- sudo make install

snapshot12 snapshot13

snapshot14

- Once completed, the libraries will be installed in /opt/libmozjpeg

snapshot17 snapshot15

For usage read MAN pages from : /opt/libmozjpeg/man

You can use jpegtran located under /opt/libmozjpeg/bin to compress the image.

snapshot18
This is for Linux users, for OS X & Windows users you can compile from source on your own & post the steps in the comment below.

Replies

  • Abhishek Rawal
    Abhishek Rawal
    Here's result of my test :

    snapshot19 snapshot23 snapshot22 snapshot21
  • Kaustubh Katdare
    Kaustubh Katdare
    That's good and would definitely help companies like Facebook who can save TBs of data through that optimisation; but I'd want something that brings a reduction of about 30-50%! That'd be killer!

You are reading an archived discussion.

Related Posts

Manual or automation testing? Which is good?
hello,sir, Can you give me some creative idea for railway project..?
Name:Ashish S. Kshirsagar Engineering Trade:Computer Science and Engineering Location: Buldhana, Maharashtra Occupation: Fresher(Jobseeker) Hobbies & Interests: Internet surfing Aim in life: To achieve my destination! I joined CrazyEngineers because: Reference:-Google
The next free CEC course on "Design Products With Bluetooth Low Energy" runs for five days from July 21 through July 25. Registered users get free IEEE credits for courses....