1.2.5 Compression Flashcards
What is compression?
To compress a file means to make its size smaller
Why would we need to compress a file?
- Files take up less storage space
- Smaller files can be transferred quicker
- Files are read from or written quicker
What are the 2 types of compression?
1) Lossy
2) Lossless
What is lossy compression?
Lossy compression uses an algorithm to analyse a file and remove data that cannot be seen or heard by humans.
Example - a lossy compression on a sound file would remove frequencies that humans can’t hear
Further lossy compression will remove data that humans can see/hear causing a change to the file
Example - an image losing its quality
Lossy compression removes data permanently so they file can never return to its original form
What is lossless compression?
Lossless compression will reduce the size of a file without permanently removing any data. This means the file is returned to its original form when decompressed and no quality is lost
Lossless compression is used on files that would not work if any data was removed
Example - Executable files (programs and games)
- Word documents
- Spreadsheets