0% found this document useful (0 votes)
16 views6 pages

INFO1

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
16 views6 pages

INFO1

Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 6

JPEG is a standard for image compression, and significant amount of data with minimal visible

it's also the name of the most common file impact.


format that uses this compression, typically
with the .jpg or .jpeg file extension. The name is 3. Dividing into Blocks
an acronym for the Joint Photographic Experts The image is then divided into small, 8x8 pixel
Group, the committee that created the blocks. Each of these blocks is processed
standard in 1992. JPEG's key feature is its use of independently, which makes the compression
lossy compression, a process that intelligently algorithm highly efficient.
discards some image data to achieve a
significantly smaller file size. 4. Discrete Cosine Transform (DCT)

How JPEG Compression Works Next, a mathematical operation called the


Discrete Cosine Transform (DCT) is applied to
JPEG compression is a multi-step process each 8x8 block of data. The DCT converts the
designed to remove data that the human eye is pixel data from the "spatial domain" (the raw
less likely to notice. This is why it works best for pixel values) to the "frequency domain." This
photographs with smooth color gradients and new representation shows the image in terms
subtle details, but not as well for sharp-edged of different frequencies:
graphics, text, or illustrations.
Low-frequency coefficients represent the
1. Color Space Conversion overall, broad color and brightness patterns in
The process begins by converting the image's the block.
color data from the common RGB (Red, Green, High-frequency coefficients represent fine
Blue) format, which is used by monitors and details, sharp edges, and rapid changes.
cameras, to the YCbCr color space. In YCbCr, "Y"
represents the luminance (brightness) of a pixel, The most important information, the low-
while "Cb" and "Cr" represent the chrominance frequency data, is concentrated in the top-left
(color). This separation is crucial because the corner of the resulting 8x8 matrix, while the less
human eye is far more sensitive to changes in important high-frequency data is in the bottom-
brightness than in color. right.

2. Chrominance Subsampling 5. Quantization

Since our eyes can't detect fine color details as This is the heart of the lossy compression. The
well as they can see brightness changes, the DCT coefficients are divided by a quantization
JPEG algorithm reduces the resolution of the Cb table, which is a pre-defined 8x8 matrix. Each
and Cr channels. This is called chrominance value in the quantization table determines how
subsampling. For example, in a common 4:2:0 much a corresponding coefficient is reduced or
subsampling scheme, the color information is rounded. The values in the table are
averaged over a 2x2 block of pixels, effectively intentionally higher for the high-frequency
reducing the amount of color data to one- coefficients, causing them to be rounded to
quarter of its original size while the luminance zero more often. This effectively throws away
data remains unchanged. This step discards a the fine details that the human eye is poor at
perceiving, resulting in a much smaller data set. High-Frequency Details (Quantization): After the
The degree of compression (and thus image image data is converted into frequency
quality) is determined by a "quality setting" that coefficients, the quantization step discards the
scales this quantization table—a higher quality "high-frequency" information. These high
setting uses a table with smaller numbers, frequencies represent the very fine, sharp
leading to less rounding and less data loss. details and rapid color changes in an image. The
algorithm rounds these values to zero or very
6. Entropy Encoding small numbers, which significantly reduces the
Finally, the remaining, quantized coefficients total data. The loss of these high-frequency
are compressed using a lossless method like details is what causes the "blocky" artifacts
Huffman coding. The data is scanned in a "zig- often seen in heavily compressed JPEGs, as the
zag" pattern to group similar values (especially broader, low-frequency information is all that
the zeros) together. This makes it easier to remains.
compress the data without any further loss of Redundant Information: The final step, entropy
information. The compressed data, along with encoding, performs a lossless compression by
the quantization tables and other metadata, is identifying and removing statistical redundancy
then saved as the final JPEG file. in the remaining data. While this step doesn't
lose any additional image information, it
effectively removes the redundant parts of the
What are these data that are being removed? already-reduced data stream, making the final
file even smaller.
JPEG compression works by intelligently
removing data that the human eye is less How does it relates in data and digital
sensitive to, a process called lossy compression. communication?
It's not a random deletion; the algorithm targets
specific types of information to achieve a JPEG is fundamentally a technology of data
smaller file size with minimal perceived quality compression, which is one of the most critical
loss. subjects in both data and digital
communication. Its relationship is direct and
Here are the primary types of data that are profound: JPEG was designed to solve the
removed: problem of efficiently storing and transmitting
images in a digital world.
Fine Color Details (Chrominance Subsampling):
The human eye is more sensitive to changes in Data Reduction for Storage
brightness (luminance) than to fine variations in
color (chrominance). JPEG takes advantage of Before JPEG, digital images were often stored in
this by drastically reducing the amount of color uncompressed formats like BMP, which could
data in the image. For example, a common result in massive file sizes. A single high-
method called 4:2:0 subsampling averages the resolution image could be several megabytes,
color information across a 2x2 block of pixels, making it impractical for both storage and
effectively reducing the color data to one- sharing. JPEG's lossy compression algorithm
quarter of its original size. reduces a file's size by a factor of 10 or more by
removing data that is not essential to human This ability to optimize data for a specific
perception. This means that a memory card in a communication channel is why JPEG remains
digital camera can store hundreds of images the standard for photographic images today.
instead of just a handful, and a hard drive can
archive a vast photo library.

Efficiency in Digital Communication PNG

The impact of JPEG on digital communication is PNG, which stands for Portable Network
what truly made it a ubiquitous standard. When Graphics, is a raster graphics file format that's
a digital image is sent over a network, such as known for its ability to handle lossless
the internet, it consumes a certain amount of compression and transparency. It was created
bandwidth. A larger file requires more in the mid-1990s as a successor to the GIF
bandwidth and more time to transmit. JPEG's format, primarily to avoid the legal issues
ability to create small, manageable image files associated with GIF's patent on its compression
was a game-changer for the early internet. It algorithm.
allowed for the development of image-rich Key Features of PNG
websites and the widespread sharing of photos
via email and social media, even on slower Lossless Compression: This is a core feature of
connections. Without JPEG's efficiency, the PNG. Unlike a lossy format like JPEG, which
visual content that defines today's internet discards some image data to achieve a smaller
would have been impossible to achieve at scale. file size, PNG compresses the image without
losing any information. This makes it ideal for
The Trade-off: Quality vs. Bandwidth images where quality is critical, like logos, icons,
The core relationship between JPEG and digital and diagrams.
communication is the trade-off between image Transparency: PNG supports an alpha channel,
quality and bandwidth. JPEG allows users to which allows for varying levels of transparency.
choose the compression level, from a low- This means that parts of an image can be
quality, highly compressed file to a higher- completely transparent, partially transparent
quality, larger one. This flexibility is essential in (semitransparent), or completely opaque. This
digital communication where the application is a significant advantage over formats like
dictates the need: JPEG, which don't support transparency at all.
A low-quality JPEG might be perfect for a This feature is crucial for web design, as it
thumbnail on a mobile device where speed is allows images to blend seamlessly with
more important than detail. different background colors or patterns.

A high-quality JPEG is more suitable for a Color Depth: PNG can handle a wide range of
professional photographer's portfolio where color depths, from 1-bit (black and white) to 48-
image integrity is paramount. bit (true color). This allows it to store images
with millions of colors, making it suitable for
high-quality photographs and other complex
images.
No Animation: A notable limitation of the on Microsoft Windows. It's known for its
standard PNG format is that it does not support simplicity and the fact that it is generally an
animation. The Animated Portable Network uncompressed format, meaning it stores a
Graphics (APNG) format was created as an direct, pixel-by-pixel representation of the
extension to PNG to add animation capabilities, image.
but it's not as universally supported as standard
PNG. This uncompressed nature makes BMP files
great for high-quality images and for editing, as
How PNG Works there's no loss of data. However, it also results
in very large file sizes compared to compressed
PNG uses a two-stage compression process. formats like JPEG or PNG.
First, it applies a filter to the image data to
make it more compressible. There are five 🧱 Structure of a BMP File
different filter types, and the best one is chosen
based on the image's characteristics. Then, it A standard BMP file consists of four main parts:
uses the Deflate algorithm (the same algorithm File Header: A 14-byte block that contains basic
used in ZIP compression) to compress the metadata about the file, like its type ('BM') and
filtered data. This two-step process allows for overall file size.
efficient lossless compression.
**DIB (Device-Independent Bitmap) Header:
Use Cases for PNG This is a more detailed header that provides
Due to its features, PNG is the go-to format for information needed to render the image. It
specific types of images: includes key specifications like the image width
and height, the number of color planes, and the
Web Graphics: Logos, icons, banners, and other bits per pixel (color depth).
web elements with sharp lines and text are
often saved as PNGs, especially when Color Palette: An optional section present for
transparency is needed. images with a color depth of less than 24 bits
per pixel. This table maps pixel values to specific
Diagrams and Illustrations: Since PNG is lossless, colors. For example, in an 8-bit image, a pixel
it's perfect for saving technical drawings, charts, value of 15 would correspond to the 16th entry
and diagrams where every pixel matters. in the color palette.

Graphics with Text: When an image contains Pixel Data: This is the core of the file, containing
text, PNG ensures that the text remains crisp the actual color data for each pixel in the image.
and clear, without the artifacts that can appear The data is typically stored from the bottom
in lossy formats. row of the image to the top row. Each row of
pixel data is also padded with zeros to ensure
it's a multiple of 4 bytes, which can further
BMP increase the file size.

BMP (Bitmap) is a raster graphics image file Color Depth (Bits Per Pixel)
format that stores digital images, primarily used
Color depth, measured in bits per pixel (bpp), How does it relates in data and digital
determines the number of colors that a BMP communication?
image can display. It's a key part of the DIB
header and directly impacts the file size and BMP is fundamentally a straightforward data
image quality. The higher the bpp, the more structure, which makes its relation to data and
color information each pixel can hold, leading to digital communication both direct and
a greater range of colors. problematic.

Here are some common color depths for BMP Data Representation
files: A BMP file is an excellent example of raw,
1-bit (Monochrome): Each pixel is represented uncompressed data. The pixel data section is
by a single bit. This allows for only 2 colors essentially a grid of color values, ordered
(2^1), typically black and white. sequentially. For a 24-bit image, every three
bytes of data directly correspond to the red,
4-bit: Each pixel uses 4 bits, allowing for 16 green, and blue color channels of a single pixel.
colors (2^4). These are usually palette-indexed This simplicity means the data can be read and
colors. interpreted with minimal processing. There's no
complex decoding algorithm required, unlike
8-bit: Each pixel uses 8 bits, allowing for 256 with compressed formats. This is why BMP is
colors (2^8), which are also typically palette- often used in basic image processing
indexed. This is useful for saving space while applications and for storing high-quality,
still allowing for a reasonable number of colors. unedited images.
16-bit: Each pixel uses 16 bits, allowing for Digital Communication Issues
65,536 colors (2^{16}). In a 16-bit format, the
color data is often stored directly without a Because it's uncompressed, BMP is generally a
color palette. For example, it might use 5 bits poor choice for digital communication over
for red, 6 for green, and 5 for blue (5-6-5 networks like the internet.
format), as the human eye is more sensitive to
green. Large File Size: The lack of compression means
BMP files are enormous compared to formats
24-bit (Truecolor): Each pixel uses 24 bits, with like JPEG or PNG. This translates to longer
8 bits each for the red, green, and blue (RGB) download times and requires more bandwidth,
color channels. This provides over 16.7 million making it inefficient for web pages or for
colors (2^{24}), which is often considered the sending via email. For example, a high-
full range of colors visible to the human eye. resolution, 24-bit BMP image can be many
This format doesn't require a color palette. times the size of its JPEG equivalent.

32-bit: This is an extension of the 24-bit format, Inefficient for Transmission: The large file size
adding an extra 8 bits for an alpha channel. The also makes BMP unsuitable for real-time digital
alpha channel stores transparency information, communication, such as video streaming or live
allowing for semi-transparent or translucent image feeds, where data efficiency is critical.
pixels. Modern communication protocols are designed
to handle compressed, smaller data packets to
ensure smooth and fast transmission.

Compatibility: While BMP is widely supported


on Windows, its large size and lack of advanced
features (like transparency in older versions)
have led to the dominance of more efficient
formats. For broad digital communication,
developers and users prefer formats that are
optimized for file size and offer better features.

You might also like