Documente Academic
Documente Profesional
Documente Cultură
Data Compression
Instructor Introduction
Instructor: Eyas El-Qawasmeh
Email :eyas@just.edu.jo
Office hours : 10-12. Wen and Monday.
Office location : D1 Level 0: One floor up
from the chemistry department.
7A Objectives
A: 00000
B: 00001
C: 00010
:
:
Y: 11000
Z: 11001
The number of colors that GIF works with is only 256 (28 in contrast to 224 for
JPEG
Stores up to 256 colors in a table and attempt to cover the range of colors in an
image as closely as possible
The resulting bit values are subjected to some form of Lempel-Ziv compression
Lossy if the number of colors in an image is more than 256; lossless otherwise
Best suited for graphics that contain relatively few colors and sharply defined
boundaries between the colors, such as cartoons, charts, …etc.
Not that suitable for images with lots of variations between colors, such as full-
color photographic-quality images
GIF format
• By default, converting to a GIF format, reduces
the number of colors to 256 or 8 bits per pixel
• and "runs" of same-color pixels are encoded in a
color+numberOfPixels format.
– For example, if there are 100 pixels on a line with the
color 41, the image file stores the color (41) and the
length of the run (100).
– This makes a GIF file great for storing drawings that
have lots of same-color pixels
The idea is to linearize the content of the Q array and compress it for
transmission
Since many 2-D must be transmitted for the image, and many of them
may not have much differences, Differential encoding can also be applied
In general, JPEG compression ration is about 20:1; that is, the resulted
file is 5% of the original
Better ratios are possible but loss of quality may become noticeable
Auditory Masking:
• If two sounds have similar frequencies, but one is weak and the
other is high, it is possible that a human cannot hear the weak
sound
Auditory Masking:
• If two sounds have similar frequencies, but one is weak and the
other is high, it is possible that a human cannot hear the weak
sound