Browse DevX
Sign up for e-mail newsletters from DevX


Audio Basics : Page 4

This section provides some basic background information for adding sound to your site.




Building the Right Environment to Support AI, Machine Learning and Deep Learning

Audio Formats and Quality Levels
As discussed in the Quick Start, many different formats, or ways to record sound exist. Formats fall into two categories: described sound, such as MIDI, and recorded sound.

MIDI vs Audio
MIDI is a way to play sound files without taking up too much space. MIDI transmits commands—information about how to play certain sounds—but it does not transmit audio signals.

MIDI devices act as a middle point between the sound source and the computer.

MIDI files take up very little memory in the computer, and they download faster than digital sound files.

Recorded Sound
The three most popular audio (recorded sound) formats are AU (audio format), WAV (waveform audio) and AIFF or AIF (Audio Interchange File Format). .EA is another common format, used specifically for the Web. These formats can be used on both Netscape and Internet Explorer, and they allow decent compression and decent sound quality.

Many formats allow for 8 and 16-bit resolution. With smaller resolution (such as 8-bit) the file size is smaller, but the quality of sound isn't as good.

Does Size Matter?
The number one consideration when working with sound on the Web is balance of file size and file quality. Sure, it would be nice if we could all put CD-quality stereo sound on our Web sites. It would also be nice if the pictures on our Web sites look exactly the same as they do on paper. But we all know that that's usually not a good idea. What's the point of having sound if your visitors need to wait 30 minutes in order to hear anything?

Better sound quality means more disk space and more waiting time. One minute of CD quality stereo sound takes up about 10MB of disk space, and takes about 10 minutes to hear it at modem speed. Your goal is to balance the sound quality with the file size. We'll show you how to do this in our Designing with Sound section.

Sizes and Rates
Different types of music sound differently depending on which format they're saved as, what the file size is, and what the sample rate is. As a general rule, when working with classical music, you'll want to keep the file size around 16-bit, and the rate at 44k, for the best quality sound. For rock, you'll want a 16-bit file size, and a 22 k sample rate. For speech, you can use an 8-bit file size, with an 11k sample rate.

The problem with using those guidelines for the Web, however, is that file size is much more important than sound quality, where in the non-Web world, sound quality is far more important than file size. When working with sounds for the Web, test specific compression rates for each of your sounds. All compression schemes make sound files sound worse, so you'll need to determine what files sizes work best for you and your readers. If you can use a smaller file size, without affecting the quality of sound too much, you should. It saves waiting time for your visitors.

Comment and Contribute






(Maximum characters: 1200). You have 1200 characters left.



Thanks for your registration, follow us on our social networks to keep up-to-date