MP3 compression settings

A lot of misconceptions exist about audio compression. Bear in mind that the whole idea behind it is to store digital audio but not have it take up too much space on your hard drive. Uncompressed audio is in wav format. You can compress it in 2 ways:

  • Lossless compression: no information is lost, compression is about 50%.
  • Lossy compression: the codec used tries to determine parts of the file you won’t be able to hear anyway and throws them away. The rest is compressed. Compression is determined by either the bitrate you want to give or the quality you want to give. Compression depends upon the bitrate used but can typically be around 80% while staying transparant.

So, no codec (mp3, ogg, aac, …) can ever be said to provide better or worse sound quality. What can be said is that different codecs need a different bitrate (and so, file size) to reach the same quality.

We’ll be compressing lossy. mp3 is an old codec and in theory newer ones such as aac should need a lower bitrate to get the same quality. However…When using the lame mp3 encoder you have an encoder which has excellent tuning. The advantage of using mp3 is that it’s universally supported on all devices. (indeed, most people think about mp3’s when talking about digital audio.) Also note that a song encoded with the same bitrate but by different encoders may have a very diffent quality for different encodings. When encoding to mp3 and if quality is the goal (instead of speed) always use lame! So, MP3 is what we’ll be using here… Continue reading “MP3 compression settings”

Tagging audio files

There are a few ways I can think of for an audio player to show you all relevant information (artist, title, release year, …) about an audio file.

  • derive it on-the-fly from the filename.
    • disadvantages:
      • only a limited amount of fields can be entered before file names become too long
      • changing a field would require you to rename the file, which will make programs no longer find the file.
      • you need to take care when naming your files, changing your filename format afterwards may be difficult.
    • advantages:
      • ummmm…not sure…
  • derive it from metadata added to the file.
    • disadvantages:
      • a lot of fields are standardized, but some are not. (album artist anyone?)
      • file becomes (only slightly) bigger
    • advantages:
      • very flexible: you can add fields whenever you want

Continue reading “Tagging audio files”