Setting up RealAudio

Suppose you have a large audio file that you would like to distribute on your webpage. Since the file will take a long time to download (even with good compression), you would like to stream it in realtime to your audience, so the audio data plays as it is delivered, without being saved on the client's hard drive. RealAudio is one of the most popular streaming formats.

Converting an audio file to RealAudio

You start with, say, CD-quality audio in a .aiff or .wav file. First you need to convert this to RealAudio format. Many current commercial sound editors will export RealAudio files (for example, BIAS Peak on the Mac).

Creating a .ram file to prevent downloads

Suppose I've created a compressed RealAudio file, Gmoll.rm, and placed it in my public_html/WEBTUT directory. Common practice is to next create a .ram file that points to the .rm file. The .ram file only has one line:

pnm://userwww.sfsu.edu/~whsu/WEBTUT/Gmoll.rm

(The text after "pnm://" is the url for the .rm file.) Users can stream the file and listen to it, but the extra level of indirection prevents them from downloading the actual audio.

Embedding in an html file

Finally, you can embed the .ram in an html file. When the html file is displayed, you will see the RealPlayer plugin controls. Clicking on the play button will cause Gmoll.rm to be streamed from the server. Check out:

RealAudio example