Re: mp3AIFF



zoara <me3@xxxxxxxxxxx> wrote:



A quick lesson in lossy compression...

If I want to send you the following text:

---------+---------+---------+---------+---------+---------+---------+
AAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAABBBBBBBBBCCCCCCCAABBBBBBBBBBBBBB

then I could 'compress' it into fewer characters by using a code we both
agreed on. Let's say a number means 'repeat the last character that
number of times', so I could send you:

A21B1A16B9C7A2B14

Now the same information takes up 17 characters, instead of 70. You
could store it as 17 characters, but you could turn it back into the 70
characters if you wanted - it would then take up more space.

That's lossless compression; you still have all the information. You can
compress complicated stuff further by using lossy compression (liek MP3)
by discarding the stuff you don't think is important. Let's say you
weren't interested in bunches of characters that were less than five
repeats; you could then represent the above as:

A38B9C9B14

That's now 10 characters, only a seventh the size of what we started
with. You could go further by ignoring any bunches of characters with
less than ten repeats - this is like changing the bit rate of the MP3 to
something lower - and you'd end up with:

A38B32

Now a mere 6 characters long, a tenth the original size.

The problem with lossy compression is that you lose some information. If
you now expanded that to full text, you'd get:

AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB

It's still the same size (70 characters) as the original, but it's just
lost some of the detail.

If you expanded the previous one (A38B9C9B14) to full text, you'd get
some of the detail but not all, ie

AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABBBBBBBBBCCCCCCCCCBBBBBBBBBBBBBB

So you have to decide how small you want the resulting compression, and
how much detail you are willing to lose. Some people might be happy with
A38B32, others would want the extra detail of A38B9C9B14, and a few
would complain if you used any less than A21B1A16B9C7A2B14.

Lossy compression is used where there are complex patterns that can
possibly be simplified without too much damage to the information. So
that's mainly music (MP3, AAC) and pictures (JPEG), both of which end up
a bit less detailed after lossy compression. Some people prefer not to
lose the data and so use lossless compression (TIFF, AIFF).

Hope this helps,

-zoara-
It does, and also explains why there are so many compresion formats,
thanks
Richard
.



Relevant Pages

  • Re: Reduce numbers to one number
    ... jpg is lossy in that the uncompressed image doesn't equal the original. ... more to compression. ... could jump up to 16 bit "characters" e.g. unicode. ...
    (sci.math)
  • Re: Some questions
    ... Briefly some methods uses 2 or even 4 byte per characters, ... compressible you can achieve compression on most files." ... The very problem is that on a pure etropic file you cast prediction on ... sort (or otherwise give an alternative representation) of such a file ...
    (comp.compression)
  • Re: compression API available in Java & C++?
    ... > "Monique Y. Mudama" wrote... ... >>> compression scheme that asume them. ... >> ASCII characters, and of those only the common ones that show up on ... > schema for mapping each character to 6 bits instead of 8. ...
    (comp.lang.java.programmer)
  • Re: Need specific BootCamp/Vista advice please
    ... Hex garbage characters might work! ... Not for the purpose of tight compression of a file, ... Duplicate the garbage file about 4 times, stuff dups in a folder. ...
    (comp.sys.mac.system)
  • Re: Are CODECs used by Blu-ray and HD-DVD owned by Microsoft?
    ... general and DCT based compression in particular. ... Yes - all video codecs are lossy when using Blu-ray, ... And Blu-Ray is not full AVC like HD-DVD, it's only a cut back version. ... all day long always ending back with the original file you started ...
    (alt.tv.tech.hdtv)