IAudioSessionManager Interface

Previous Next

IAudioSessionManager Interface

The IAudioSessionManager interface enables a client to access the session controls and volume controls for both cross-process and process-specific audio sessions. The client obtains a reference to an IAudioSessionManager interface by calling the IMMDevice::Activate method with parameter iid set to REFIID IID_IAudioSessionManager.

This interface enables clients to access the controls for an existing session without first opening a stream. This capability is useful for clients of higher-level APIs that are built on top of WASAPI and use session controls internally but do not give their clients access to session controls.

In Windows Vista, the higher-level APIs that use WASAPI include Media Foundation, DirectSound, the Windows multimedia waveInXxx, waveOutXxx, and mciXxx functions, and third-party APIs.

When a client creates an audio stream through a higher-level API, that API typically adds the stream to the default audio session for the client's process (the session that is identified by the session GUID value, GUID_NULL), but the same API might not provide a means for the client to access the controls for that session. In that case, the client can access the controls through the IAudioSessionManager interface.

For a code example that uses the IAudioSessionManager interface, see Audio Events for Legacy Audio Applications.

IAudioSessionManager inherits from the IUnknown interface. In addition to the methods inherited from IUnknown, IAudioSessionManager implements the following methods.

Method Description
GetAudioSessionControl Retrieves an audio session control.
GetSimpleAudioVolume Retrieves a simple audio volume control.

Requirements

Client: Windows Vista

Header: Include Audiopolicy.h.

See Also

Previous Next