Compression techniques

Why are compression techniques necessary?

Previously, we talked about the representations of number, text, image, sound, video in binary form (Chapter 1). The file size of data is always a major concern when the data need to be stored and transmitted because our computers have limited memory & disk size and we want to store as more data as possible. When transmitted over internet, big file takes more time and we want fast speed of data transferring.

Compression techniques provide ways to reduce memory & disk storage requirements and to increase the file transmission rate.

The categories of compression techniques?

There are 2 categories of compression techniques:

Lossless compression

Lossless compression is a coding technique that allows subsequent decoding to create exactly the original file. As its name implies, not data is lost. After decoding, we can get the same data as the original.

Lossy compression

Lossy compression is a coding technique that cause some data to be lost and original file cannot be recovered in sub sequential decoding.as its name implies, some data is lost. After decoding, we can not get the same data as the original.

You may wonder why we need lossy compression since data could be lost. in some cases, the lost data is so minor that you can not even notice it. Lossy compression is more appropriate in these cases because it can reduce the size of data dramatically. For example, an image of 24 bits might looks the same as a 32 bits image because human eyes cannot detect the differences. Another sample, a 16 bits audio might sounds the same as a 24 bits audio because human ears cannot detect the differences.

The benefits and drawbacks.

The benefits of lossless compression:

  • The original data can be recovered exactly.

The benefits of lossy compression:

  • The size of data can be reduces dramatically

File format and compression techniques

bitmap

Lossy or uncompressed

JPG(JPEG)

Lossy

PNG

lossless

Mp3/Mp4

lossy

avi

lossless

wav

lossless

ALAC

lossless

FLAC

lossless

 

发布了22 篇原创文章 · 获赞 6 · 访问量 35万+

猜你喜欢

转载自blog.csdn.net/zhangxingping/article/details/104068766