IMMMasterAudio

The IMMMasterAudio class provides behavior for modifying the master audio settings for all audio devices in the system. The application can set, query and save the headphones', speakers', and master volume settings for the system. When any of the multimedia devices are opened, they query the master audio settings and automatically adjust their settings accordingly.


IMMMasterAudio - Member Functions and Data by Group

Constructors & Destructor

You can construct and destruct objects of this class.


[view class]
~IMMMasterAudio
public:
virtual ~IMMMasterAudio()

Supported Platforms

Windows OS/2 AIX
Yes Yes No


[view class]
IMMMasterAudio
public:
IMMMasterAudio()

Supported Platforms

Windows OS/2 AIX
Yes Yes No


Headphones

Use these members to set, query, and save the headphones' setting.


[view class]
areHeadphonesEnabled
public:
bool areHeadphonesEnabled( SettingSource source = current, IMMDevice::CallType call = IMMDevice::wait ) const

Returns if the headphones' setting is enabled for the passed-in source (either the current setting or the saved setting); otherwise, returns false.

Supported Platforms

Windows OS/2 AIX
Yes Yes No


[view class]
disableHeadphones
public:
virtual IMMMasterAudio& disableHeadphones( IMMDevice::CallType call = IMMDevice::wait )

Turns the headphones' settings off.

Supported Platforms

Windows OS/2 AIX
Yes Yes No


[view class]
enableHeadphones
public:
virtual IMMMasterAudio& enableHeadphones( bool enable = true, IMMDevice::CallType call = IMMDevice::wait )

Turns the headphones' settings either off or on.

Supported Platforms

Windows OS/2 AIX
Yes Yes No


[view class]
saveHeadphonesSetting
public:
virtual IMMMasterAudio& saveHeadphonesSetting( IMMDevice::CallType call = IMMDevice::wait )

Saves the current headphones' setting of the operating system.

Supported Platforms

Windows OS/2 AIX
Yes Yes No


Speakers

Use these members to set, query, and save the speakers' setting.


[view class]
areSpeakersEnabled
public:
bool areSpeakersEnabled( SettingSource source = current, IMMDevice::CallType call = IMMDevice::wait ) const

Returns true if the speakers' setting is enabled for the passed-in source (either the current setting or the saved setting); otherwise, returns false.

Supported Platforms

Windows OS/2 AIX
Yes Yes No


[view class]
disableSpeakers
public:
virtual IMMMasterAudio& disableSpeakers( IMMDevice::CallType call = IMMDevice::wait )

Turns the speakers' setting off.

Supported Platforms

Windows OS/2 AIX
Yes Yes No


[view class]
enableSpeakers
public:
virtual IMMMasterAudio& enableSpeakers( bool enable = true, IMMDevice::CallType call = IMMDevice::wait )

Turns the speakers' setting either on or off.

Supported Platforms

Windows OS/2 AIX
Yes Yes No


[view class]
saveSpeakersSetting
public:
virtual IMMMasterAudio& saveSpeakersSetting( IMMDevice::CallType call = IMMDevice::wait )

Saves the current speakers' setting of the operating system.

Supported Platforms

Windows OS/2 AIX
Yes Yes No


Volume

Use these members to set, query, and save the master volume setting.


[view class]
saveVolume
public:
virtual IMMMasterAudio& saveVolume( IMMDevice::CallType call = IMMDevice::wait )

Saves the current master volume setting of the operating system.

Supported Platforms

Windows OS/2 AIX
Yes Yes No


[view class]
setVolume
public:
virtual IMMMasterAudio& setVolume( unsigned long volume, IMMDevice::CallType call = IMMDevice::wait )

Sets the master volume for the operating system.

Supported Platforms

Windows OS/2 AIX
Yes Yes No


[view class]
volume
public:
unsigned long volume( SettingSource source = current, IMMDevice::CallType call = IMMDevice::wait ) const

Returns the master volume setting for either the current setting or the saved setting to a percent of the maximum audio level.

Supported Platforms

Windows OS/2 AIX
Yes Yes No


IMMMasterAudio - Enumerations


[view class]
SettingSource
enum SettingSource { saved=0x00004000L, 
                     current=0x00008000L }

Enumeration that specifies which setting to query and set.

Supported Platforms

Windows OS/2 AIX
Yes Yes No


IMMMasterAudio - Inherited Member Functions and Data

Inherited Public Functions

INotifier
IStandardNotifier

Inherited Public Data

INotifier

Inherited Protected Functions

IStandardNotifier
INotifier

Inherited Protected Data