PDF image JBIG2 compression and decompression with JBIG2 encoding and decoding SDK library

JBIG2 is an image compression standard for bi-level images developed by the Joint bi-level Image Expert Group. It is suitable for lossless compression and lossy compression. According to the group's press release, in its lossless mode, JBIG2 usually generates files that are one-third to one-fifth the size of the fax group 4 and twice the size of JBIG, which was previously released by the group. The double-layer compression standard. JBIG2 was released as an international standard ITU in 2000.


JBIG2 compression
JBIG2 is an international standard for bi-level image compression. By segmenting the image into overlapping and/or non-overlapping areas of text, halftones and general content, compression techniques optimized for each content type are used:

*Text area:
The text area is composed of characters that are well suited for symbol-based encoding methods. Usually, each symbol will correspond to a character bitmap, and a sub-image represents a character or text. For each uppercase and lowercase character used on the front face, there is usually only one character bitmap (or sub-image) in the symbol dictionary.

For example, the dictionary will have an "a" bitmap, an "A" bitmap, a "b" bitmap, and so on.

*Halftone area:
Halftone areas are similar to text areas because they consist of patterns arranged in a regular grid. The symbols stored in the dictionary are not character bitmaps, but periodic patterns representing the intensity of the dithering (such as photos) to produce a double-layer printed image.

*General area:
The general area contains non-text, non-halftone information (such as lines and noise) and is compressed using arithmetic or MMR coding.


Lossy JBIG2 compression:
In lossy JBIG2 compression (often called perceptually lossless or visually lossless), we ignore the difference between the dictionary bitmap (ie, the reference character bitmap or character template) and the specific instance of the corresponding character in the image. In lossless compression, the difference is stored and used in combination with triples (each character is encoded by a decoder) to generate the actual image bitmap.

Sometimes, when acceptable or necessary, it may be interesting to recompress images already contained in an existing PDF file to reduce the file size.

The PDF specification provides seven compression schemes for this purpose. All of these can be used to compress images.

JBIG2 is an image compression standard for black and white images. It is suitable for lossless compression and lossy compression. Compared with CCITT fax group 4 compression, JBIG2 compression can compress black and white images 2-5 times more effectively.

Now, JBIG2 compression is very popular in PDF documents: most scanners generate PDF documents with JBIG2 images, many PDF editors use JBIG2 compression decoders and encoders, and all PDF compressors use JBIG2 compression viewers and encodings. Device.

VeryUtils has a JBIG2 encoding and decoding SDK library that allows decoding and encoding of JBIG2 images in C++ and .NET environments. You can download the trial version of the JBIG2 encoding and decoding SDK library from this webpage to try,


If you have any questions about this JBIG2 encoding and decoding SDK library, please feel free to let us know, we are happy to help you as soon as possible.

No votes yet.
Please wait...

Related Posts

Leave a Reply

Your email address will not be published.