What are compressed and uncompressed files, how does it all work and why compressed files take less storage?

2.00K views

What are compressed and uncompressed files, how does it all work and why compressed files take less storage?

In: Technology

27 Answers

Anonymous 0 Comments

Imagine you have a graph of 100 points. To know the position of each point in X& y you’d need 2 bytes each or 200 bytes. However you could come up with a mathematical formula that when run could make a line that nearly matches all the points, it’ll be a little off, but now instead of 200 bytes you only need 20 to store the formula that at intervals of the X axis outputs the required y axis for the points.

Compressing images is even simpler. A raw image uses 8 bits (or a byte) per colour Chanel per pixel to define the brightness and colour of the pixke as a whole, the subpixle is set from 0 (off) to 256 (on) with in-between being increasing brightness. This is an 8 bit colour (2x2x2x2x2x2x2x2 = 256) there are several options for compressing, for starters you could reduce the number of bits per subpixle. Or reduce the resolution by merging nearby pixles together. You could throw away every other pixle and then interpolate that colour during unpacking based off it’s neighbours

You are viewing 1 out of 27 answers, click here to view all answers.