quote: Original post by Pythius
Actually, JPEG and MP3 *DO* compress the data, but you are right that they rely on the fact that humans can''t notice the difference to a certain degree. Each requires this, because it limits how much they actually need to compress (meaning fewer bits per symbol). JPEG first breaks the RGB into Chrominance/Luminance. Since we don''t notice the difference in luminance as much, they first of all take this down to 1/4 the size of the actual image and stretch it at a loss of quality. Then it uses a DCT (discrete cosine transform) to get the symbols in a proper order in blocks of 8x8. This is compiled in a table, which is then passed into an RLE compressor, since that is optimal on these tables.
This isn''t quite correct - first humans eyes are less sensitive to chrominance information then luminance information, so in the JPEG algorithm the chrominance information gets downsampled, and the luminance information is left untouched.
Secondly each channel of the image (one luminance, two chrominance) is compressed seperately. Each channel is cut into a grid of 8x8 blocks. Each block is then processed with a DCT transform which transforms the data from the spatial domain into the frequency domain. Then the frequency data is quantized: low frequencies finely, higher frequencies more coarsely. In addition JPEG uses different quantisation factors (called quantum) depending on the channel being quantised. It is this quantisation process which is the main loss of quality in the image.
Once the quantization process is complete the block is encoded into a bitstream using a static frequency table (generated using statistical averaging of the symbol frequencies from thousands of tests).
On a side note - throughout the DCT and quantisation process the data is always in an 8x8 block. However when it is converted into a bitstream it is readout in a zig-zag fasion starting at the lowest frequency and ending on the highest frequency. The idea is after quantisation most of the high frequencies will be zero and the bitstream for this block can be terminated early with a special code.
I am very sceptical about this CAR compression - this kind of thing comes around about once every two years. From what the original poster has said, that the CAR compression simple massages the data so that it can be compressed better then it sounds very much like the Burrows Wheeler Transform. The BWT shift symbols redundancies from high frequencies into lower frequencies making it easier to compress the data.
Chris
Chris Killpack : ckillpack@eaeurope.com
Technology Group : Bullfrog Productions Ltd