These sections describe the Sound Filer tool:
Access the Sound Filer tool by typing soundfiler in a shell window, or by double-clicking the soundfiler icon on the MediaTools page of the Icon Catalog. See “IRIS Essentials” for information on how to open a shell window or locate an icon.
The Sound Filer software utility lets you play audio files on your system and convert audio files to different formats and sizes. To play audio files you must have an IRIS that supports audio.
Sound Filer is installed automatically as part of the standard system software on IRIS systems that support audio. To add it to a non-audio IRIS system you must install the audio.sw image. See the IRIS Software Installation Guide for instructions on installing software images.
You can open Sound Filer in one of several ways:
Double-click the soundfiler icon on the Media Tools page of the Icon Catalog.
Open a shell window, then type the word soundfiler.
Click the words Sound Filer to open Sound Filer now.
Use Sound Filer to find audio files, view information about file formats and sizes, play files, and convert files to different formats and sizes. Sound Filer is shown in Figure 8-1.
The fields in the lower half of the main window display information about the particular file you are viewing.
| File Name | The name of the audio file. | |
| File Format | The standard audio format in which the file is encoded; possible formats are AIFF (Audio Interchange File Format), AIFF-C, Sun/NeXT, MS RIFF WAVE, and raw sound data. These formats are described further in “Changing File Formats”. | |
| Size | The number of distinct locations in which the data is stored (sample frames), how long it takes to play (in seconds), and how much disk space (in kbytes) the file occupies. | |
| Format | The number of channels on which the file plays (1 = mono, 2 = stereo) and the format of the data (number of bits, type of numbers). | |
| Sampling Rate | The number of times per second (measured in kHz, where 1 kHz = 1000 times per second) the system reads the file when outputting audio. The greater the sampling rate, the larger the file, and the better the quality of the audio output. See “Reducing the Size (and Quality) of Audio Files” for more information on sampling rates. |
Find and display information about a file by scanning through directories or by typing the complete pathname of the file you want in the “File Name” field. A list of audio files and directories within the selected directory appears in the file display.
To find a file by scanning through directories:
Click the Up button to move to a previous directory.
Double-click on a directory within the display window to open that directory.
Click the Original button to move back to the directory you started with.
To display only audio files within a directory, click the Show only sound files checkbox.
You can view information about a particular audio file in one of two ways:
Select a file name that's displayed in the main window by clicking on it once.
Type the full pathname of a file in the “File Name” field, then press <Enter>.
You can play an audio file from the Sound Filer main window in one of two ways:
Select the audio file name (or type its full pathname in the “File Name” field then press <Enter>), then click the Play button.
Double-click the audio file name.
If you don't hear the audio, either the volume is too low, or you don't have audio support in your IRIS system. If you don't have audio support, error messages appear in your console window.
To stop playing the file, click the Stop button.
For example, to play the sample file named /usr/lib/sounds/prosonus/musictags/tag2.aiff, follow these steps:
Select the /usr/lib/sounds/prosonus/musictags/tag2.aiff file by clicking in the “File Name” field, then typing:
/usr/lib/sounds/prosonus/musictags/tag2.aiff
Press <Enter>.
Play tag2.aiff by clicking the Play button.
Several sample audio files are shipped in the standard system software distribution, but they are not installed by default when you install the system software. These files are contained in the software image called dmedia_tools.data.prosonus.
Installing this image creates a directory called /usr/lib/sounds/prosonus which contains several directories of audio files. You can play the files while they are in this directory, but you cannot create converted copies of them in this directory. If you plan to work with the audio files, copy them into your home directory where you can create, change, and remove copies and original files as you like.
To copy the entire directory of sample files into a directory named /usr/people/joe, follow these steps:
Open the /usr/lib/sounds Directory View window.
Make sure you can see the /usr/people/joe folder icon in the WorkSpace, or the open /usr/people/joe directory view window.
Press and hold down the <Alt> key on your keyboard, then drag the prosonus folder icon over the joe folder icon or into the joe directory view window.
The directory /usr/lib/sounds/prosonus contains several sample audio files. (See “Installing Sample Audio Files” in this chapter to install them on your system).
To view the contents of the /usr/lib/sounds/prosonus/musictags directory, then view information about the audio file named tag2.aiff, follow these steps:
In Sound Filer click in the “File Name” field, then type:
/usr/lib/sounds/prosonus/musictags
Press <Enter>.
View detailed information about the tag2.aiff file by selecting it.
Figure 8-2 shows the main window displaying information about the tag2.aiff file.
You may want to change the attributes of an audio file for several reasons:
to reduce the amount of disk space the file occupies
to put it in the correct format for a specific software application
to take advantage of the specific audio hardware on your system
For example, the Sound Filer can play an audio file that is in the Sun/NeXT file format, but you cannot insert that file into an IRIS Showcase document; you must first convert it to Audio Interchange File Format (AIFF) using Sound Filer. (For information on inserting an audio file into an IRIS Showcase document, see the IRIS Showcase User's Guide.)
Audio files can occupy a surprisingly large amount of disk space. For example, a file that contains one minute of music of the same quality level as a stereo CD occupies 10 megabytes on a hard disk.
The sampling rate is the variable that most affects the size of an audio file. When music is recorded, the recording device receives continuous audio, but records only a subset or a sampling of the sounds. The number of samples per second is called the sampling rate, and is measured in kiloHertz (kHz); 1 kHz = 1000 samples per second. The higher the sampling rate, the larger the file, and the better the quality of the audio output.
Whether the audio outputs to two channels (stereo) or one (mono) also effects the file's size; stereo files are twice as large as mono files.
If you don't mind reducing the quality of an audio file's output slightly, you can use Sound Filer to greatly reduce the size of the file. For example, a stereo audio file whose sampling rate is 44.1KHz (the rate at which stereo music CDs are recorded) and whose playing time is one second occupies 175 kbytes on a hard disk. You can use Sound Filer to create a copy of the file with an 8 kHz sampling rate and mono output that occupies only 16 kbytes on a hard disk.
To use Sound Filer to reduce the size and quality of the /usr/lib/sounds/prosonus/musictags/tag2.aiff file:
Select the /usr/lib/sounds/prosonus/musictags/tag2.aiff file by clicking in the “File Name” field, then typing:
/usr/lib/sounds/prosonus/musictags/tag2.aiff
Press <Enter>. Note that this file occupies 610 kbytes on the hard disk.
Click the Convert button.
You see the File Conversion window as shown in Figure 8-3.
This shows the current attributes of the file under the Input File heading on the left side of the window, and shows the possible attributes of the copy that you want to create under the Output File heading on the right side of the window.
Specify a name and location for the copy.
By default, Sound Filer places the copy in the same directory as the original and names it originalfile.out. You cannot write to the /usr/lib/sounds/prosonus/musictags directory, so you need to specify a new location, such as /usr/tmp.
Highlight /usr/lib/sounds/prosonus/musictags in the “File Name” field on the Output File side of the window.
Type: /usr/tmp
Specify a much lower sampling rate (8K) for the output file.
If the button in the “Rate” field on the right-hand (Output File) side of the window is not labelled 8K, position your cursor over the button.
Press and hold the left mouse button to see the menu.
Choose “8K”.
Change the output from stereo to mono.
If the button in the “Channels” field on the right-hand (Output File) side of the window is not labelled Mono, position your cursor over the button.
Press and hold the left mouse button to see the menu.
Choose “Mono”.
Click the Accept button.
You see a notifier saying that Sound Filer created a new file named tag2.aiff.out in /usr/tmp.
If you did not specify a new directory for this file, you see a notifier saying that Sound Filer couldn't create the new file. Type a different pathname in the “File Name” field on the Output File side of the conversion window, then click Accept again. If this still does not work, see “Understanding Permissions” for more information on permissions.
Play the new file to see if you can discern any change in quality.
In the Sound Filer main window, click in the “File Name” field, type the file's full pathname, then press <Enter>.
Click the Play button.
Note that the new file occupies only 55 kbytes.
You typically need to change the format of an audio file when you plan to use the file on different types of systems. Sound Filer can convert to and from these formats:
The table below shows the preferred file formats, numeric formats, number of bits per sound sample, and method for storing bytes for IRIS, Sun, NeXT, Apple Macintosh, and Multimedia PC (MPC) systems.
Table 8-1. Preferred audio file formats
Sun/NeXT | Apple Macintosh | Multimedia PC | |
|---|---|---|---|
Sun/NeXT | AIFF | MS RIFF WAVE | |
16-bit | 8-bit | 8-bit | 8-bit |
Integer | Mulaw | Integer | Integer |
2's complement | Unsigned | Unsigned | Unsigned |
Sound Filer can convert files to the preferred format of the system on which you will play the file. For example, to convert a file named /usr/tmp/sound.wav that is in MS RIFF WAVE format to the highest quality AIFF file that you can use with IRIS Showcase, follow these steps:
Select the sound.wav file by clicking in the “File Name” field, then typing:
/usr/tmp/sound.wav
Press <Enter>.
Click the Convert button. You see the File Conversion window.
This shows the attributes of the file under the Input File heading on the left-hand side of the window, and shows the possible attributes of the copy that you want to create under the Output File heading on the right-hand side of the window.
sound.wav has these attributes:
| File Format: | MS RIFF WAVE | |
| Sampling Rate: | 22.05 kHz | |
| Output channels: |
| |
| Data format: | Integer | |
| Bits per sample: |
| |
| Sign (byte storage) | Unsigned |
Specify a name and location for the copy. By default, Sound Filer places the copy in the same directory as the original file and names it originalfile.out. In this example, it would be named sound.wav.out.
The converted file will be in AIFF rather than MS RIFF WAVE; it's a good idea to give it a name that reflects its format, such as sound. aiff.
Change the file format to AIFF.
Position your cursor over the button in the “File Format” field labelled wave on the right-hand (Output File) side of the window.
Press and hold the left mouse button to see the menu.
Choose “Audio Interchange File Format”.
Keep the sampling rate at 22.05. The rate of the original file is the highest rate that the output file can have; Sound Filer cannot add samples to improve the quality of the original file.
If the button in the “Rate” field on the right-hand (Output File) side of the window is not labelled 22.05, position your cursor over the button.
Press and hold the left mouse button and choose “22.05” from the menu.
Keep the output mono. Sound Filer cannot create true stereo output from a mono file.
If the button in the “Channels” field on the right-hand (Output File) side of the window is not labelled Mono, position your cursor over the button.
Press down the left mouse button and choose “Mono” from the menu
Keep the bits per sample at 8. Sound Filer cannot increase the number of bits per sample to improve the quality.
If the number in the “Bits” field is not 8, highlight it, and type: 8
Change the data storage method to 2's Complement.
If the button in the “Sign” field on the right-hand (Output File) side of the window is not labelled 2's Complement, position your cursor over the button.
Press and hold the left mouse button and choose “2's Complement” from the menu.
Click the Accept button.
You see a notifier saying that Sound Filer created a new file; unless you specified a different pathname, the file is called sound.aiff and is located in /usr/tmp.
Play the new file to see if you can discern any change in quality.
In the Sound Filer main window, click in the “File Name” field, type the file's full pathname, then press <Enter>.
Click the Play button.