libjpeg
libjpeg
|
|
---|---|
Basic data
|
|
developer | Independent JPEG Group |
Publishing year | October 7, 1991 |
Current version |
9c ( January 14, 2018 ) |
operating system | platform independent |
programming language | C. |
category | Program library |
License | BSD-like ( Free Software ) |
ijg.org |
libjpeg is a widely used free program library with functions for handling the image data format JPEG . It implements a JPEG codec (encoding and decoding) as well as various auxiliary functions for handling JPEG data. It is written in C and is distributed as free software also in the source code under the terms of its own liberal ( BSD-like ) free software license, which essentially requires attribution .
The original variant is published and maintained by the Independent JPEG Group (IJG). There are now several largely compatible splits with additional properties such as higher coding efficiency.
Utilities
The following utilities are shipped with libjpeg:
- cjpeg and djpeg
- to convert between JPEG and some other common image file formats,
- rdjpgcom and wrjpgcom
- for inserting and reading out text comments in JPEG files and
- jpegtran
- a utility program for transforming existing JPEG files.
jpegtran
The command line program jpegtran offers several functions for reformatting and recoding the representation of the existing DCT coefficients, for transforming the actual image data and for discarding additional data in JPEG files. The transformations related to the representation of the coefficients include
- the optimization of the Huffman trees and
- Conversion between Huffman and arithmetic coding in the entropy coding layer, as well as
- the conversion between sequential and progressive JPEG.
These transformations are completely lossless and reversible. The image data transformations include
- discarding color channels (conversion to grayscale image),
- Rotate and mirror in 90 degree steps,
- Cropping along the image block boundaries (8 × 8 or 16 × 16 pixels) and
- Scaling.
They are lossless and reversible, at least with regard to the image data components ultimately obtained. There is no decompression and recompression of the data, which would result in a further reduction in image quality and thus a generation loss.
There is an associated Windows application called Jpegcrop , which provides a graphical user interface to jpegtran . For Unixoid systems like GNU / Linux there is the free CropGUI with similar functionality.
history
The Independent JPEG Group's (IJG) implementation of JPEG was first published on October 7, 1991, and has since evolved considerably. The development was initially mainly carried out by Tom Lane. The IJG's open source implementation was one of the most important packages of open source software for JPEG and also a key to the standard's success. It has been used by many companies in a wide range of products such as image editing programs and web browsers.
For version 5, published on September 24, 1994, the entire code base was rewritten. With it the auxiliary programs rdjpgcom and wrjpgcom for handling embedded text comments were introduced. Version 6, released on August 2, 1995, came with progressive JPEG support and, for the first time, the jpegtran utility . This has been expanded in version 6b to include the functions for rotating and mirroring as well as for color reduction to grayscale.
Miyasaka Masaru developed the libjpeg / SIMD branch from version 6b of libjpeg from March 27, 1998 , which integrated x86 SIMD optimizations. The TigerVNC and VirtualGL 2009 projects made significant contributions to this. On this basis, the libjpeg-turbo project was created in early 2010.
After a change of leadership after 11 years without publication, the IJG released new libjpeg versions (7 to 9), each of which broke the compatibility of the binary interface (ABI) with previous versions. The further developments promised after the 6-series versions did not materialize. In version 7 support for arithmetic coding was introduced, which had previously been rejected for patent reasons, as well as the trimming function in jpegtran ( -crop
). Versions 8 and 9 were mainly used to introduce controversial incompatible format extensions. These are widely regarded as ineffective and inferior to existing, standardized solutions. Their standardization was rejected after submission to the ITU-T . Original organizer Tom Lane and others speak of a break with the IJG's previous goals.
On March 4, 2014, the first version of the file-size-optimizing spin-off mozjpeg was published. Josh Aas from Mozilla Research reworked the Perl script jpegcrush from x264 main developer Loren Merritt and integrated it into the code base of libjpeg-turbo. On July 10th, Mozilla released version 2.0, which mainly retrofits trellis quantization and can now further optimize baseline JPEGs. Facebook Inc. then donated $ 60,000 to develop the next version, and CloudFlare hired a developer to develop it.
Spin-offs
Well-known spin-offs are the libjpeg-turbo project, which optimizes its product for execution speed, and mozjpeg, which optimizes small file sizes. In addition, there is a libjpeg from ISO , which aims at a complete implementation of all JPEG-1 standards.
libjpeg-turbo
libjpeg-turbo
|
|
---|---|
Basic data
|
|
developer | libjpeg-turbo Project |
Publishing year | 2010 |
Current version | 1.5.1 (September 21, 2016) |
operating system | Platform independence |
programming language | C. |
libjpeg-turbo.org |
libjpeg-turbo is a spin-off of libjpeg, the SIMD - commands uses to accelerate the encoding and decoding baseline JPEG. Many projects now use libjpeg-turbo instead of libjpeg, including popular GNU / Linux distributions (including Debian , Ubuntu , Mageia , Fedora ), Mozilla and Chrome . In addition to the performance advantages, some projects have also opted for libjpeg-turbo to maintain binary interface compatibility with the older version 6b of libjpeg.
libjpeg-turbo can be compiled in such a way that the binary interface is compatible with version 7 or 8 of libjpeg, whereby the full range of functions of more recent IJG publications is not implemented. The project chose not to support the SmartScale format extension, pointing out that it was not an ITU-T standard and citing its own research that casts doubt on the usefulness of the function. Furthermore, the libjpeg-turbo project has decided not to emulate version 9 of libjpeg, as its only new feature only affects the SmartScale format. Therefore, the SmartScale files created with version 8 and later versions of libjpeg are not correctly decompressed by libjpeg-turbo.
mozjpeg
libjpeg
|
|
---|---|
mozcjpeg tries different divisions of the DCT coefficient spectrum |
|
Basic data
|
|
Maintainer | Josh Carrion |
developer | Mozilla Research |
Publishing year | 4th March 2014 |
Current version | 3.1 (May 18, 2015) |
operating system | Platform independence |
programming language | C. |
github.com/mozilla/mozjpeg |
mozjpeg is a spin-off of libjpeg-turbo from Josh Aas and others from Mozilla Research. It is intended to accelerate the loading times of websites by improving the coding efficiency while maintaining the image quality (around 10 percent) and achieving smaller file sizes and thus reduced transmission times. For this purpose, a higher computational effort is to be used for the coding of the files, which is typically one-time here (asymmetry), whereby the format compatibility is maintained and no changes are required on the decoder side. Specifically, this is achieved by optimizing the Huffman trees, using progressive coding with an optimized distribution of the DCT coefficient spectrum on individual runs and using trellis quantization . In addition, the presets are aggressively optimized to minimize file sizes. In addition to libjpeg-turbo, mozjpeg is based on jpegcrush, a Perl script by Loren Merritt.
Web links
- Web presence of the Independent JPEG Group
- JPEGclub - additional functions for libjpeg
- Binaries from libjpeg for Windows (from GnuWin32 on SourceForge.net)
- libjpeg-turbo , an ABI- / API-compatible fork of libjpeg, which uses x86-SIMD commands for a significant speed advantage compared to the reference implementation.
- Web presence of mozjpeg , the spin-off optimized for file size minimization
- Josh Aas, Robert Nyman; August 2014: Using mozjpeg to Create Efficient JPEGs - practical overview of mozjpeg, in English
swell
- ^ Independent JPEG Group . (accessed on March 1, 2019).
- ↑ Libjpeg License - JPEG Reference. In: jpegclub.org. Retrieved September 7, 2016 .
- ↑ Jpegcrop Preferences and Options description
- ↑ Filmic Games >> The greatest failure of our patent system was ... ( Memento of the original from September 1, 2012 in the Internet Archive ) Info: The archive link was inserted automatically and has not yet been checked. Please check the original and archive link according to the instructions and then remove this notice.
- ↑ 680385 - Firefox does not show arithmetic coded jpegs
- ↑ New jpegtran features
- ↑ JPEG homepage
- ↑ http://libjpeg-turbo.virtualgl.org/
- ↑ libjpeg: API changes / compatibility ( Memento of the original from April 16, 2014 in the Internet Archive ) Info: The archive link was inserted automatically and not yet checked. Please check the original and archive link according to the instructions and then remove this notice. . February 9, 2012
- ^ A b Mans Rullgard (Hardwarebug.org), August 4, 2009: IJG is back
- ↑ Tom Lane, January 16, 2013: jpeg-9, API / ABI compatibility, and the future role of this project
- ↑ a b What About libjpeg v9? . libjpeg-turbo team. Retrieved February 8, 2013.
- ^ Mans Rullgard (Hardwarebug.org), February 1, 2010: IJG swings again, and misses
- ↑ a b André Kramer (heise.de-Newsticker), January 14, 2013: Mozilla encoder improves JPEG compression
- ↑ Sebastian Grüner, July 16, 2014: mozjpeg 2.0: Facebook supports JPEG encoders from Mozilla
- ↑ http://www.soeren-hentzschel.at/mozilla/2014/07/30/cloudflare-moechte-zu-mozillas-jpeg-encoder-beitrag/
- ↑ https://github.com/thorfdbg/libjpeg
- ↑ Release 1.5.1
- ↑ a b The libjpeg Open Source Project on Open Hub: Languages Page . In: Open Hub . (accessed on September 26, 2018).
- ^ Software That Uses or Provides libjpeg-turbo . February 9, 2012.
- ↑ Issue 48789 - chromium - Use libjpeg-turbo instead of libjpeg . April 14, 2011.
- ↑ Bug 698519 - Update to libjpeg-turbo 1.2 . February 28, 2012
- ↑ libjpeg for F14 . February 9, 2012.
- ↑ libjpeg-turbo README file ( Memento of the original from August 12, 2014 in the Internet Archive ) Info: The archive link was inserted automatically and has not yet been checked. Please check the original and archive link according to the instructions and then remove this notice.
- ↑ Andreas Donath (golem.de), March 6, 2014: Mozilla wants to compress JPEGs better