Docstoc

JPEG -an introduction

Document Sample
JPEG -an introduction Powered By Docstoc
					                                                JPEG
                                             RAVI BHADKA
                                                 08BEC004
                            Department of Electronics & Communication Engineering
                                            Institute of Technology
                                               Nirma University
                                             Ahmedabad - 382 481
                                                 Gujarat, India
                                    Email: 08bec004@nirmauni.ac.in


                 ABSTARCT:
In this paper, we are introducing JPEG as a         A useful property of JPEG is that the degree of
standard compression method for image               lossiness can be varied by adjusting compression
compression and image processing with loss.         parameters. This means that the image maker can
Using JPEG standard compression, original           trade off file size against output image quality. You
image and data can be compressed by ratio of        can make extremely small files if you don't mind
20:1. JPEG is one of the most extensively used      poor quality; this is useful for applications such as
image formats. In this paper, we have talked        indexing image archives. Conversely, if you aren't
about history, current trends of JPEG, basic        happy with the output quality at the default
technology used in JPEG, advantages and             compression setting, you can jack up the quality
disadvantages of JPEG, application and              until you are satisfied, and accept lesser
limitation of JPEG and last future scopes of        compression. Another important aspect of JPEG is
JPEG.                                               that decoders can trade off decoding speed against
                                                    image quality, by using fast but inaccurate
                I.    INTRODUCTION                  approximations to the required calculations. Some
                                                    viewers obtain remarkable speedups in this way.
JPEG (pronounced "jay-peg") is a standardized (Encoders can also trade accuracy for speed, but
image compression mechanism.JPEG stands for there's usually less reason to make such a sacrifice
Joint Photographic Experts Group, the original when writing a file.)
name of the committee that wrote the standard.
JPEG is designed for compressing either full-                         WHY JPEG IS USED?
colour or gray-scale images of natural, real-world There are two good reasons: to make your image
scenes. It works well on photographs, naturalistic files smaller, and to store 24-bit-per-pixel colour
artwork, and similar material; not so well on data instead of 8-bit-per-pixel data. Making image
lettering, simple cartoons, or line drawings. JPEG files smaller is a win for transmitting files across
handles only still images, but there is a related networks and for archiving libraries of images.
standard called MPEG for motion pictures.           Being able to compress a 2 Mbyte full-colour file
JPEG is "lossy," meaning that the decompressed down to, say, 100 Kbytes makes a big difference in
image isn't quite the same as the one you started disk space and transmission time! And JPEG can
with. (There are lossless image compression easily provide 20:1 compression of full-colour data.
algorithms, but JPEG achieves much greater If you are comparing GIF and JPEG, the size ratio
compression than is possible with lossless is usually more like 4:1. Now, it takes longer to
methods.) JPEG is designed to exploit known decode and view a JPEG image than to view an
limitations of the human eye, notably the fact that image of a simpler format such as GIF. Thus using
small colour changes are perceived less accurately JPEG is essentially a time/space trade off: you give
than small changes in brightness. Thus, JPEG is up some time in order to store or transmit an image
intended for compressing images that will be more cheaply. But it's worth noting that when
looked at by humans. If you plan to machine- network transmission is involved, the time savings
analyze your images, the small errors introduced by from transferring a shorter file can be greater than
JPEG may be a problem for you, even if they are the time needed to decompress the file. The second
invisible to the eye.                               fundamental advantage of JPEG is that it stores full
colour information: 24 bits/pixel (16 million             within one second down a 64 Kbits/sec ISDN
colours). GIF, the other image format widely used         line. Eventually, the format would be able to send
on the net, can only store 8 bits/pixel (256 or fewer     loss-less images. The standard was intended for
colours). GIF is reasonably well matched to               natural, real world scenes. It was designed to
inexpensive computer displays --- most run-of-the-        compress natural pictures that are smooth and
mill PCs can't display more than 256 distinct             curved and have no jagged edges. The project
colours at once. But full-colour hardware is getting      began under ISO as Working Group 8 but later
cheaper all the time and JPEG photos look much            merged with CCITT. The Joint Photographic
better than GIFs on such hardware. Within a               Experts Group, actually a subcommittee of ISO,
couple of years, GIF will probably seem as obsolete       was then formed in 1986 in order to avoid
as black-and-white Mac Paint format does today.           competing standards among the three standards
Furthermore, JPEG is far more useful than GIF for         organizations. After testing of numerous schemes,
exchanging images among people with widely                the Adaptive Discrete Cosine Transform (DCT)
varying display hardware, because it avoids               was chosen to be the core of the JPEG
prejudging how many colours to use. Hence JPEG            format. Three years later, the merged ISO/IEC
is considerably more appropriate than GIF for use         committee gave their approval to make the JPEG
as a Usenet and World Wide Web standard photo             the standard. It was drafted as the ISO Committee
format.                                                   Draft 10918 or Digital Compression and Coding of
A lot of people are scared off by the term "lossy         Continuous-Tone Still Images. It was officially
compression". But when it comes to representing           standardized as the International Standard ISO
real-world scenes, no digital image format can            10918-1.
retain all the information that impinges on your          JPEG has been in existence for nearly a
eyeball. By comparison with the real-world scene,         decade. Revisions updating JPEG to make use
JPEG loses far less information than GIF. The real        of our current text-based technologies are in
disadvantage of lossy compression is that if you          progress. This project has been in progress since
repeatedly compress and decompress an image, you          August 1998. The project team is developing a
lose a little more quality each time. This is a serious   JPEG format that provides more compression
objection for some applications but matters not at        options and better images which take up the same
all for many others.                                      amount of space. It is said that the core of
                                                          JPEG 2000 is Wavelet technology. The release date
              II.   HISTORY OF JPEG
                                                          has been set for January 2000, but implementation
                                                          will probably take some time.
The JPEG compression format was standardized by
                                                                    DISCRET COSINE TRANSFORM
ISO in August 1990 and commercial applications
using it began to show up in 1991. The widely used
                                                          Lossless compression, the coefficients must not
IJG implementation was first publicly released in
                                                          allow for the loss of any information. Out of the
October 1991 and has been considerably developed
                                                          image compression techniques available, transform
since that time. JPEG JFIF images are widely used
                                                          coding is the preferred method. Since energy
on the Web. The amount of compression can be
                                                          distribution varies with each image, compression in
adjusted to achieve the desired trade-off between
                                                          the spatial domain is not an easy task. Images do
file size and visual quality. The DCT is the
                                                          however tend to compact their energy in the
transform used in JPEG compression.          "Joint
                                                          frequency domain making compression in the
Photographic Experts Group" is the original name
                                                          frequency domain much more effective. Transform
of the committee that created the JPEG format. The
                                                          coding is simply the compression of the images in
standard was a joint effort by three of the world's
                                                          the frequency domain. Transform coefficients are
largest standards organizations: The International
                                                          used to maximize compression. For The Discrete
Organization for Standardization (ISO), the
                                                          Cosine Transform (DCT) is an example of
International Telegraph and Telephone Consultative
                                                          transform coding. The current JPEG standard uses
Committee (CCITT), and the International Electro
                                                          the DCT as its basis. The DC relocates the highest
technical Commission (IEC). The JPEG project
                                                          energies to the upper left corner of the image. The
began back in 1982. The goal was to create a data
                                                          lesser energy or information is relocated into other
compression standard that would display an image
                                                          areas. The DCT is fast. It can be quickly calculated
and is best for images with smooth edges like            superior to GIF for storing full-colour or gray-scale
photos with human subjects. The DCT coefficients         images of "realistic" scenes; that means scanned
are all real numbers unlike the Fourier                  photographs, continuous-tone artwork, and similar
Transform. The Inverse Discrete Cosine Transform         material. Any smooth variation in colour, such as
(IDCT) can be used to retrieve the image from its        occurs in highlighted or shaded areas, will be
transform representation.                                represented more faithfully and in less space by
                                                         JPEG than by GIF. GIF does significantly better on
                                                         images with only a few distinct colours, such as line
                                                         drawings and simple cartoons. Not only is GIF
DCT:                                                     lossless for such images, but it often compresses
                                                         them more than JPEG can. For example, large
                                                         areas of pixels that are all exactly the same colour
                                                         are compressed very efficiently indeed by GIF.
                                                         JPEG can't squeeze such data as much as GIF does
                                                         without introducing visible defects. Computer-
IDCT:                                                    drawn images, such as ray-traced scenes, usually
                                                         fall between photographs and cartoons in terms of
                                                         complexity.       The more complex and subtly
                                                         rendered the image, the more likely that JPEG will
                                                         do well on it. The same goes for semi-realistic
           III.   APPLICATION OF JPEG                    artwork. But icons that use only a few colours are
                                                         handled better by GIF. JPEG has a hard time with
The JPEG compression algorithm is at its best on         very sharp edges: a row of pure-black pixels
photographs and paintings of realistic scenes with       adjacent to a row of pure-white pixels, for example.
smooth variations of tone and colour. For web            Sharp edges tend to come out blurred unless you
usage, where the amount of data used for an image        use a very high quality setting. Edges this sharp are
is important, JPEG is very popular. JPEG/Exif is         rare in scanned photographs, but are fairly common
also the most common format saved by digital             in GIF files: consider borders, overlaid text, etc.
cameras. On the other hand, JPEG may not be as           The blurriness is particularly objectionable with
well suited for line drawings and other textual or       text that's only a few pixels high. If you have a GIF
iconic graphics, where the sharp contrasts between       with a lot of small-size overlaid text, don't JPEG it.
adjacent pixels can cause noticeable artifacts. Such     Plain black-and-white (two level) images should
images may be better saved in a lossless graphics        never be converted to JPEG; they violate all of the
format such as TIFF, GIF, PNG, or a raw image            conditions given above. You need at least about 16
format. The JPEG standard actually includes a            gray levels before JPEG is useful for gray-scale
lossless coding mode, but that mode is not               images. It should also be noted that GIF is lossless
supported in most products. As the typical use of        for gray-scale images of up to 256 levels, while
JPEG is a lossy compression method, which                JPEG is not.
somewhat reduces the image fidelity, it should not
be used in scenarios where the exact reproduction                      IV.JPEG COMPRESSION
of the data is required (such as some scientific and
medical imaging applications and certain technical       The compression method is usually lossy, meaning
image processing work). JPEG is also not well            that some original image information is lost and
suited to files that will undergo multiple edits, as     cannot be restored, possibly affecting image
some image quality will usually be lost each time        quality. There is an optional lossless mode defined
the image is decompressed and recompressed,              in the JPEG standard; however, that mode is not
particularly if the image is cropped or shifted, or if   widely supported in products. There is also an
encoding parameters are changed. To avoid this, an       interlaced "Progressive JPEG" format, in which
image that is being modified or may be modified in       data is compressed in multiple passes of
the future can be saved in a lossless format, with a     progressively higher detail. This is ideal for large
copy exported as JPEG for distribution. One of the       images that will be displayed while downloading
first things to learn about JPEG is which kinds of       over a slow connection, allowing a reasonable
images to apply it to. Generally speaking, JPEG is
preview after receiving only a portion of the data.      Several additional standards have evolved to
However, progressive JPEGs are not as widely             address these issues. The first of these, released in
supported, and even some software which does             1992, was JPEG File Interchange Format (or JFIF),
support them (such as some versions of Internet          followed in recent years by Exchangeable image
Explorer) only displays the image once it has been       file format (Exif) and ICC colour profiles. Both of
completely downloaded. There are also many               these formats use the actual JIF byte layout,
medical imaging and traffic systems that create and      consisting of different markers, but in addition
process 12-bit JPEG images, normally grayscale           employ one of the JIF standard's extension points,
images. The 12-bit JPEG format has been part of          namely the application markers: JFIF use APP0,
the JPEG specification for some time, but again,         while Exif use APP1. Within these segments of the
this format is not as widely supported.                  file, that were left for future use in the JIF standard
                                                         and aren't read by it, these standards add specific
                     LOSSLESS EDITING                    metadata.

A number of alterations to a JPEG image can be           Thus, in some ways JFIF is a cutdown version of
performed losslessly (that is, without recompression     the JIF standard in that it specifies certain
and the associated quality loss) as long as the image    constraints (such as not allowing all the different
size is a multiple 1 MCU block (Minimum Coded            encoding modes), while in other ways it is an
Unit) (usually 16 pixels in both directions, for 4:2:0   extension of JIF due to the added metadata. The
chrome sub sampling). Blocks can be rotated in 90        documentation for the original JFIF standard states:
degree increments, flipped in the horizontal,
vertical and diagonal axes and moved about in the        JPEG File Interchange Format is a minimal file
image. Not all blocks from the original image need       format which enables JPEG bit streams to be
to be used in the modified one. The top and left of a    exchanged between a wide variety of platforms and
JPEG image must lie on a block boundary, but the         applications. This minimal format does not include
bottom and right need not do so. This limits the         any of the advanced features found in the TIFF
possible lossless crop operations, and also what         JPEG specification or any application specific file
flips and rotates can be performed on an image           format. Nor should it, for the only purpose of this
whose edges do not lie on a block boundary for all       simplified format is to allow the exchange of JPEG
channels. When using lossless cropping, if the           compressed images.
bottom or right side of the crop region is not on a
block boundary then the rest of the data from the    Image files that employ JPEG compression are
partially used blocks will still be present in the   commonly called "JPEG files", and are stored in
cropped file and can be recovered. It is also        variants of the JIF image format. Most image
possible to transform between baseline and           capture devices (such as digital cameras) that output
progressive formats without any loss of quality,     JPEG are actually creating files in the Exif format,
since the only difference is the order in which the  the format that the camera industry has standardized
coefficients are placed in the file.                 on for metadata interchange. On the other hand,
                                                     since the Exif standard does not allow colour
                    JPEG FILES                       profiles, most image editing software stores JPEG
                                                     in JFIF format, and also include the APP1 segment
The file format known as "JPEG Interchange from the Exif file to include the metadata in an
Format" (JIF) is specified in Annex B of the almost-compliant way; the JFIF standard is
standard. However, this "pure" file format is rarely interpreted somewhat flexibly. Strictly speaking,
used, primarily because of the difficulty of the JFIF and Exif standards are incompatible
programming encoders and decoders that fully because they each specify that their marker segment
implement all aspects of the standard and because (APP0 or APP1, respectively) appears first. In
of certain shortcomings of the standard:             practice, most JPEG files contain a JFIF marker
                                                     segment that precedes the Exif header. This allows
     Colour space definition                        older readers to correctly handle the older format
     Component sub-sampling registration            JFIF segment, while newer readers also decode the
     Pixel aspect ratio definition.
following Exif segment, being less strict about        The exact threshold at which errors become visible
requiring it to appear first.                          depends on your viewing conditions. The smaller
                                                       an individual pixel, the harder it is to see an error;
             GOOD QUALITIES OF JPEG                    so errors are more visible on a computer screen (at
                                                       70 or so dots/inch) than on a high-quality colour
Very well indeed, when working with its intended printout (300 or more dots/inch). Thus a higher-
type of image (photographs and suchlike). For full- resolution image can tolerate more compression ...
colour images, the uncompressed data is normally which is fortunate considering it's much bigger to
24 bits/pixel. The best known lossless compression start with. The compression ratios quoted above are
methods can compress such data about 2:1 on typical for screen viewing. Also note that the
average. JPEG can typically achieve 10:1 to 20:1 threshold of visible error varies considerably across
compression without visible loss, bringing the images.
effective storage requirement down to 1 to 2                    MODES OF OPERATION FOR JPEG
bits/pixel. 30:1 to 50:1 compression is possible There are four distinct modes of operation under
with small to moderate defects, while for very-low- which the various coding processes are defined:
quality purposes such as previews or archive sequential DCT-based, progressive DCT-based,
indexes, 100:1 compression is quite feasible. An lossless, and hierarchical. The other modes of
image compressed 100:1 with JPEG takes up the operation are compared as follows.
same space as a full-colour one-tenth-scale For the sequential DCT-based mode, 8 ´ 8 sample
thumbnail image, yet it retains much more detail blocks are typically input block by block from left
than such a thumbnail.                                 to right, and block row by block-row from top to
For comparison, a GIF version of the same image bottom. After a block has been transformed by the
would start out by sacrificing most of the colour forward DCT, quantized and prepared for entropy
information to reduce the image to 256 colours (8 encoding, all 64 of its quantized DCT coefficients
bits/pixel). This provides 3:1 compression. GIF can be immediately entropy encoded and output as
has additional "LZW" compression built in, but part of the compressed image data, thereby
LZW doesn't work very well on typical minimizing coefficient storage requirements. For
photographic data; at most you may get 5:1 the progressive DCT-based mode, 8 ´ 8 blocks are
compression overall, and it's not at all uncommon also typically encoded in the same order, but in
for LZW to be a net loss (i.e., less than 3:1 overall multiple scans through the image. This is
compression). LZW does work well on simpler accomplished by adding an image-sized coefficient
images such as line drawings, which is why GIF memory buffer between the quantizer and the
handles that sort of image so well. When a JPEG entropy encoder. As each block is transformed by
file is made from full-colour photographic data, the forward DCT and quantized, its coefficients are
using a quality setting just high enough to prevent stored in the buffer. The DCT coefficients in the
visible loss, the JPEG will typically be a factor of buffer are then partially encoded in each of multiple
four or five smaller than a GIF file made from the scans. The typical sequence of image presentation
same data.                                             at the output of the decoder for sequential versus
Gray-scale images do not compress by such large progressive modes of operation is shown in Figure
factors. Because the human eye is much more below. There are two procedures by which the
sensitive to brightness variations than to hue quantized coefficients in the buffer may be partially
variations, JPEG can compress hue data more encoded within a scan. First, only a specified band
heavily than brightness (gray-scale) data.             of coefficients from the zigzag sequence need be
A gray-scale JPEG file is generally only about encoded. This procedure is called spectral selection,
10%-25% smaller than a full-colour JPEG file of because each band typically contains coefficients
similar visual quality. But the uncompressed gray- which occupy a lower or higher part of the
scale data is only 8 bits/pixel, or one-third the size frequency spectrum for that 8 * 8 block. Secondly,
of the colour data, so the calculated compression the coefficients within the current band need not be
ratio is much lower. The threshold of visible loss is encoded to their full (quantized) accuracy within
often around 5:1 compression for gray-scale each scan. Upon a coefficient’s first encoding, a
images.                                                specified number of most significant bits is encoded
                                                       first.
In subsequent scans, the less significant bits are does NOT mean "keep 95% of the information", as
then encoded. This procedure is called successive  some have claimed. The quality scale is purely
approximation. Either procedure may be used        arbitrary; it's not a percentage of anything.
separately, or they may be mixed in flexible       In fact, quality scales aren't even standardized
combinations.                                      across JPEG programs. The quality settings
In hierarchical mode, an image is encoded as a     discussed in this article apply to the free IJG JPEG
sequence of frames. These frames provide reference software, and too many programs based on it.
reconstructed components which are usually needed  Some other JPEG implementations use completely
for prediction in subsequent frames. Except for thedifferent quality scales.
first frame for a given component, differential    For example:
frames encode the difference between source            1) Apple used to use a scale running from 0
components       and      reference   reconstructed        to 4, not 0 to 100.
components. The coding of the differences may be       2) Recent Apple software uses an 0-100
done using only DCT-based processes, only lossless         scale that has nothing to do with the IJG
processes, or DCT-based processes with a final             scale (their Q 50 is about the same as Q 80
lossless process for each component. Down                  on the IJG scale).
sampling and up sampling filters may be used to        3) Paint Shop Pro's scale is the exact
provide a pyramid of spatial resolutions.                  opposite of the IJG scale, PSP setting N =
Alternatively, the hierarchical mode can be used to        IJG 100-N; thus lower numbers are higher
improve the quality of the reconstructed                   quality in PSP.
components at a given spatial resolution.              4) Adobe Photoshop doesn't use a numeric
Hierarchical mode offers a progressive presentation        scale at all, it just gives you
similar to the progressive DCT-based mode but is           "high"/"medium"/"low" choices.
useful in environments which have multi-resolution Fortunately, this confusion doesn't prevent different
requirements. Hierarchical mode also offers the    implementations from exchanging JPEG files. But
                                                   you do need to keep in mind that quality scales vary
capability of progressive coding to a final lossless
stage.                                             considerably from one JPEG-creating program to
                                                   another, and that just saying "I saved this at Q 75"
                                                   doesn't mean a thing if you don't say which
                                                   program you used. In most cases the user's goal is
                                                   to pick the lowest quality setting, or smallest file
                                                   size, that decompresses into an image
                                                   indistinguishable from the original. This setting
                                                   will vary from one image to another and from one
                                                   observer to another, but here are some rules of
                                                   thumb. For good-quality, full-color source images,
                  Progressive                      the default IJG quality setting
                                                   (Q 75) is very often the best choice. This setting is
                                                   about the lowest you can go without expecting to
                                                   see defects in a typical image. Try Q 75 first; if you
                                                   see defects, then go up. If the image was less than
                                                   perfect quality to begin with, you might be able to
                                                   drop down to Q 50 without objectionable
                                                   degradation. On the other hand, you might need to
                                                   go to a higher quality setting to avoid further loss.
                                                   This is often necessary if the image contains
                   Sequential                      dithering or moiré patterns Except for experimental
                                                   purposes, never go above about Q 95; using Q 100
          IV.   ADVANTAGES OF JPEG
                                                   will produce a file two or three times as large as Q
Most JPEG compressors let you pick a file size vs. 95, but of hardly any better quality. Q 100 is a
image quality trade off by selecting a quality mathematical limit rather than a useful setting.
setting. There seems to be widespread confusion If you see a file made with Q 100, it's a pretty sure
about the meaning of these settings. "Quality 95" sign that the maker didn't know what he/she was
doing. If you want a very small file (say for preview    possible to do 90-degree rotations and flips
or indexing purposes) and are prepared to tolerate       losslessly, if the image dimensions are a multiple of
large defects, a Q setting in the range of 5 to 10 is    the file's block size (typically 16x16, 16x8, or 8x8
about right. Q 2 or so may be amusing as "op art".       pixels for colour JPEGs). This fact used to be just
 If your image contains sharp coloured edges, you        an academic curiosity, but it has assumed practical
may notice slight fuzziness or jugginses around          importance recently because many users of digital
such edges no matter how high you make the               cameras would like to be able to rotate their images
quality setting. This can be suppressed, at a price in   from landscape to portrait format without incurring
file size, by turning off chrome down sampling in        loss --- and practically all dig cams that produce
the compressor. The IJG encoder regards down             JPEG files produce images of the right dimensions
sampling as a separate option which you can turn         for these operations to work. So software that can
on or off independently of the Q setting. With the       do lossless JPEG transforms has started to pop up.
cjpeg program, the command line switch "-sample          But you do need special software; rotating the
1x1" turns off down sampling; other programs             image in a regular image editor won't be lossless.
based on the IJG library may have checkboxes or
other controls for down sampling. Other JPEG
implementations may or may not provide user                         V.    LIMITATIONS OF JPEG
control of down sampling. Adobe Photoshop, for
example, automatically switches off down sampling        JPEG does not support transparency and is not
at its higher quality settings. On most photographic     likely to do so any time soon. It turns out that
images, we recommend leaving down sampling on,           adding transparency to JPEG would not be a simple
because it saves a significant amount of space at        task; read on if you want the gory details. The
little or no visual penalty. For images being used on    traditional approach to transparency, as found in
the World Wide Web, it's often a good idea to give       GIF and some other file formats, is to choose one
up a small amount of image quality in order to           otherwise-unused colour value to denote a
reduce download time.                                    transparent pixel. That can't work in JPEG because
Quality settings around 50 are often perfectly           JPEG is lossy: a pixel won't necessarily come out
acceptable on the Web. In fact, a user viewing such      exactly the same colour that it started as. Normally,
an image on a browser with a 256-color display is        a small error in a pixel value is OK because it
unlikely to be able to see any difference from a         affects the image only slightly. But if it changes the
higher quality setting, because the browser's color      pixel from transparent to normal or vice versa, the
quantization artefacts will swamp any imperfections      error would be highly visible and annoying,
in the JPEG image itself. It's also worth knowing        especially if the actual background were quite
that current progressive-JPEG-making programs            different from the transparent colour. A more
use default progression sequences that are tuned for     reasonable approach is to store an alpha channel
quality settings around 50-75: much below 50, the        (transparency percentage) as a separate colour
early scans will look really bad, while much above       component in a JPEG image. That could work
75, the later scans won't contribute anything            since a small error in alpha makes only a small
noticeable to the picture.                               difference in the result. The problem is that a
It would be nice if, having compressed an image          typical alpha channel is exactly the sort of image
with JPEG, you could decompress it, manipulate it        that JPEG does very badly on: lots of large flat
(crop off a border, say), and recompress it without      areas and sudden jumps. You'd have to use a very
any further image degradation beyond what you lost       high quality setting for the alpha channel. It could
initially. Unfortunately THIS IS NOT THE CASE.           be done, but the penalty in file size is large. A
In general, recompressing an altered image loses         transparent JPEG done this way could easily be
more information. Hence it's important to minimize       double the size of a non-transparent JPEG.
the number of generations of JPEG compression            That's too high a price to pay for most uses of
between initial and final versions of an image.          transparency. The only real solution is to combine
There are a few specialized operations that can be       lossy JPEG storage of the image with lossless
done on a JPEG file without decompressing it, and        storage of a transparency mask using some other
thus without incurring the generational loss that        algorithm.     Developing,      standardizing,    and
you'd normally get from loading and re-saving the        popularizing a file format capable of doing that is
image in a regular image editor. In particular it is
not a small task. As far as I know, no serious work
is being done on it; transparency doesn't seem
worth that much effort.

                  VI.   JPEG 2000
JPEG 2000 offers numerous advantages over the
old JPEG standard, and several of these advantages
will be discussed. One main advantage is that JPEG
2000 offers both lossy and lossless compression in
the same file stream, while JPEG usually only
utilizes lossy compression4. JPEG does have a
lossless compression engine, but it is separate from     A second advantage of JPEG 2000 over JPEG is
the lossy engine, and is not used very often. Thus,      that JPEG 2000 is able to offer higher compression
when high quality is a concern, JPEG 2000 proves         ratios for lossy compression.           For lossy
to be a much better compression tool. Because of         compression, data has shown that JPEG 2000 can
the way the compression engine works, JPEG 2000          typically compress images from 20%-200% more
promises a higher quality final image, even when         than JPEG. Compression efficiency for lossy
using lossy compression. Since the JPEG 2000             compression is typically measured using the peak
format includes much richer content than existing        signal to noise ratio, or PSNR, and the root mean
JPEG files, the bottom line effect is the ability to     square error (RMSE). This method seeks to take
deliver much smaller files that still contain the same   into account the visual quality retained by the
level of detail as the larger original JPEG files. The   compression method, as well as how much the
JPEG 2000 files can also handle up to 256 channels       image was compressed.
of information as compared to the current JPEG           Another advantage of JPEG 2000 is its ability to
standard, which, by reason of common                     display images at different resolutions and sizes
implementation, is limited to only RGB (red, green,      from the same image file.
and blue) data. Figure shows two images that were
first compressed with the old JPEG compression
engine, and then compressed using the JPEG 2000
method. The images that were compressed using
JPEG 2000 are seen from Figure to retain a much
higher quality.




                                                         With JPEG, an image file was only able to be
                                                         displayed a single way, with a certain
                                                         resolution. Because JPEG 2000 is based on
wavelets, the wavelet stream can be only partially                    X. REFERENCES
decompressed if the user only wants a low-
resolution image, while the full resolution image 1) ISO/IEC JTC 1/SC 29 (2009-05-07). "ISO/IEC
                                                 JTC 1/SC 29/WG 1 – Coding of Still Pictures (SC
can be viewed if this is desired. There are numerous
                                                 29/WG
benefits to viewing the same image file at different                     1                 Structure)".
                                                 http://www.itscj.ipsj.or.jp/sc29/29w12901.htm.
resolutions. For example, if an image was available
for download on the Internet, someone with a fastRetrieved 2009-11-11.
Internet connection could download the full      2) ISO/IEC JTC 1/SC 29. "Programme of Work,
resolution image, while someone with a slower    (Allocated       to        SC       29/WG          1)".
connection could choose to save time by          http://www.itscj.ipsj.or.jp/sc29/29w42901.htm.
downloading a lower-resolution image. The abilityRetrieved 2009-11-07.
                                                 3)ISO. "JTC 1/SC 29 – Coding of audio, picture,
to display a single file with different resolutions
also promises to be helpful in many industry     multimedia      and     hypermedia      information".
applications where a certain image may need be   http://www.iso.org/iso/standards_development/tech
                                                 nical_committees/list_of_iso_technical_committees
displayed with only a low resolution at times, while
in other processes a clearer picture may be      /iso_technical_committee.htm?commid=45316.
                                                 Retrieved 2009-11-11.
needed. Using JPEG, a different file would need to
be generated for each picture. Using JPEG 2000,  4) JPEG. "Joint Photographic Experts Group, JPEG
the same image file could be used, and the user  Homepage". http://www.jpeg.org/jpeg/index.html.
could choose at what resolution to display the   Retrieved 2009-11-08.
                                                 5) http://www.itu.int/rec/T-REC-T.81. Retrieved
image. Yet another benefit of JPEG 2000 is its ROI
capability, or Region of Interest. The use of    2009-11-07.
                                                 6) William B. Pennebaker and Joan L. Mitchell
wavelets allows one to be able to select a certain
area of an image to view at a high quality, while(1993). JPEG still image data compression
leaving the rest of the image at a lower         standard      (3rd     ed.).     Springer.     p. 291.
quality. This allows the user to only view a     ISBN 9780442012724.
                                                 http://books.google.com/books?id=AepB_PZ_WM
necessary portion of the image instead of the entire
image. This significantly reduces the amount of  kC&pg=PA291&dq=JPEG+%22did+not+specify+a
memory the image requires, and the amount of time+file+format%22&lr=&num=20&as_brr=0&ei=VH
required to access the image.                    XySui8JYqukASSssWzAw#v=onepage&q=JPEG
                                                 %20%22did%20not%20specify%20a%20file%20fo
               VII. FUTURE SCOPES                rmat%22&f=false.
Now days, different compression standards are 7)ISO. "JTC 1/SC 29 – Coding of audio, picture,
available in place of JPEG with more clarity and multimedia      and     hypermedia      information".
advantages. Most popular standards are JIF, PIG, http://www.iso.org/iso/iso_catalogue/catalogue_tc/c
JPEG 2000 used in place of JPEG.                 atalogue_tc_browse.htm?commid=45316.
                  X. STANDARDS                   Retrieved 2009-11-07.
                                                 8) JPEG (2009-04-24). "Press Release – 48th WG1
 JPEG (lossy and lossless): ITU-T T.81, meeting, Maui, USA – JPEG XR enters FDIS status,
   ISO/IEC IS 10918-1                            JPEG File Interchange Format (JFIF) to be
 JPEG extensions: ITU-T T.84                    standardized       as        JPEG       Part        5".
 JPEG-LS (lossless, improved): ITU-T T.87, http://www.jpeg.org/newsrel25.html.              Retrieved
   ISO/IEC IS 14495-1                            2009-11-09.
 JBIG (black and white pictures): ITU-T T.82, 9)      "JFIF File Format as PDF" (PDF).
   ISO/IEC IS 11544-1                            http://www.w3.org/Graphics/JPEG/jfif3.pdf.
 JPEG 2000 : ITU-T T.800, ISO/IEC IS 15444-1
 JPEG 2000 extensions: ITU-T T.801
 JPEG XR (formerly called HD Photo prior to
   standardization) : ITU-T T.832, ISO/IEC
   29199-2

				
DOCUMENT INFO
Shared By:
Categories:
Tags:
Stats:
views:125
posted:4/7/2011
language:English
pages:9