A Complete Guide to Web Design

(やまだぃちぅ) #1
Nonstreaming (Static) Audio 337

Audio

Nonstreaming (Static) Audio

Web Design in a Nutshell, eMatter Edition

one of the many available MPEG players, such as maplay or WinAMP
(Windows) or SoundApp or MPEG Audio Player (Mac).
To learn more about MPEG, visit the MPEG Web Site (http://www.mpeg.org/).

MIDI (.mid)
MIDI (which stands for Musical Instrument Digital Interface) is a different
breed of audio file format. It was originally developed as a standard way for
electronic musical instruments to communicate with each other.
A MIDI file contains no actual audio information (the digital representation of
analog sound), but rather a set of mathematical commands that describe a
series of notes. These notes are played by a MIDI player using the available
“instrument” sounds on a computer’s sound card. MIDIs are to other audio
formats what vector graphics are to bitmaps—just mathematical formulas for
creating the final product on the other end.
As a result, MIDI files are incredibly compact. They are capable of packing a
minute of music into just 10K, which is 1,000 times smaller than a one-minute
WAVE file (approximately 10.MB).
The drawback to MIDI files is that they can only contain notes, not real
sounds, so they are only useful for synthesizer-sounding music. You cannot
reproduce the sound of a human voice or any organic sounds using MIDI.
Despite this limitation, MIDIs are an extremely attractive alternative for adding
instrumental music to your web site with very little download time.


Optimizing Audio Files for Download


There are ways to reduce the size of an audio file so it is appropriate for down-
loading via a web page. Not surprisingly, this usually requires sacrificing quality.
Reducing file size (and quality) is not such an issue if you are using one of the
streaming audio technologies. The aspects of the audio file you can control are:


Length of the audio clip
It might seem obvious, but you should keep the audio sample as short as
possible. For example, consider providing just part of a song rather than the
whole thing. If you are recording a greeting, make it short and sweet.


Number of channels
A mono audio file requires half the disk space of a stereo file and is recom-
mended for web audio.


Bit depth
Audio files for the Web are most often saved at 8 bits, which will result in a
file that is half the size of a 16-bit file.


Sampling rate
Cutting the sampling rate in half will cut the file size in half (e.g., a sampling
rate of 22.05 KHz requires half the data than one of 44.1 KHz). As a general
guideline, audio files that are voice-only can be reduced down to 8 KHz.
Sound effects will work at 8 Khz or 11.025 KHz. Music will sound acceptable
at 22 Khz.

Free download pdf