Linux Mixer Utilities

As you've gathered by now, sound cards provide many different inputs and outputs, including

• Digital audio output

• Microphone input

Depending upon your sound card, you can have even more devices. For instance, some sound cards support two separate line inputs. Even if your speakers have their own volume control, it's often desirable to set the volume levels for various specific sound sources separately. For instance, suppose you play a MIDI file and adjust the volume appropriately. You might then want to play a CD, but need to adjust the volume again. When the system plays a sound to inform you that you've got new mail, it might then be too soft to hear—or loud enough to disturb the neighbors! In order to set all your sound sources to reasonable volumes simultaneously, Linux supports an application type known as a mixer.

It should be no surprise at this point that mixers come in both text-based and GUI varieties. The text-based versions are most useful to set the system's volume to a default value whenever you boot the computer. One of the most common such utilities is known as aumix, and you can run it in any of three ways:

• By specifying volume levels for particular inputs and outputs on the command line

• In interactive mode, by typing aumix and then adjusting mixer levels using a text-based interface

• By specifying mixer values in a configuration file, either .aumixrc in the user's home directory or /etc/aumixrc

This final option is generally the way aumix is used. To do so, call it with the -L switch—that is, aumix -L. The program then reads the configuration file, which looks something like this:

Chapter 10

vol:80:80:P

synth:32:32:P

pcm:30:30:P

line:50:50:P

mic:16:16:R

cd:32:32:P

igain:75:75:P

Each line stands for one input or output (vol for overall system volume, pcm for digital audio, and so on), and is followed by the left and right channel volumes (on a scale of 0-99) and a code indicating whether the device is set for playing (P) or recording (R).

GUI mixer utilities also abound, of course. For instance, Figure 10.13 shows GNOME's gmix utility, which enables you to adjust the volume levels in a point-and-click manner. You can also mute individual channels and click the Lock button to adjust both right and left levels simultaneously.

Figure 10.13

GUI mixers often feature icons and numerous buttons to enable and disable specific channels or features.

Figure 10.13

GUI mixers often feature icons and numerous buttons to enable and disable specific channels or features.

Unfortunately, there are several different mixer standards in common use. Most sound cards work with common utilities like aumix, gmix, or KDE's kmix, but sometimes you might need something more exotic. The ALSA drivers, for example, don't always work with the standard mixers. Fortunately, the ALSA utilities package includes its own mixers, so you need not go without this vital utility if you use the ALSA drivers. Even among the OSS drivers, though, specific cards sometimes require their own mixers. The gmix utility shown in Figure 10.13 supports multiple mixers, either for separate sound cards or as alternative means of accessing a single card.

Was this article helpful?

0 0
The Ultimate Computer Repair Guide

The Ultimate Computer Repair Guide

Read how to maintain and repair any desktop and laptop computer. This Ebook has articles with photos and videos that show detailed step by step pc repair and maintenance procedures. There are many links to online videos that explain how you can build, maintain, speed up, clean, and repair your computer yourself. Put the money that you were going to pay the PC Tech in your own pocket.

Get My Free Ebook


Post a comment