Attenuation Classes
A version of this page is also available for
4/8/2010
Each waveform audio stream has an attenuation class associated it. An attenuation class can be thought of as secondary gain class that provides an additional level of volume control over the levels established by general audio gain classes. For more information, see Audio Gain Classes.
Whenever an application creates a new Waveform Audio stream, that stream is placed in class 0 by default. The application can change the audio stream's class by calling the waveOutMessage function with the MM_WOM_SETSECONDARYGAINCLASS message. You can set attenuation limits in for the attenuation classes with the MM_WOM_SETSECONDARYGAINLIMIT message.
Under normal operation, no additional attenuation is applied to any of the classes. For example, when a phone enabled device is receiving a phone call, the shell applies an additional amount of attenuation to each class. By default class 0 is muted and class 1 is attenuated by some amount with the assumption that phone is probably pressed against the user's ear.
The class system is also used to control whether the system volume affects streams. As a result it is possible to create an audio stream that is not affected by volume changes even if the user changes the global system volume.
The following table shows the available attenuation classes.
Attenuation Class | Description |
---|---|
0 |
Muted during call, affected by system volume. |
1 |
Attenuated during call, affected by system volume. |
2 |
Attenuated during call, unaffected by system volume. |
3 |
Muted during call, unaffected by system volume. |
4 |
Not attenuated during call, affected by system volume. |
5 |
Not attenuated during call, not affected by system volume. |