Share via


ISpMMSysAudio

Other versions of this page are also available for the following:

Windows Mobile Not SupportedWindows Embedded CE Supported

8/28/2008

This interface represents the audio implementation for the standard Windows multimedia layer (wave in and wave out). Audio objects created through an object token do not allow the ISpMMSysAudio::SetDeviceId method to work because the token specifies which audio device identifier to use. If an application wants to associate an audio object with a specific multimedia wave in or wave out device identifier, it should use CoCreateInstance with CLSID_SpMMAudioOut or CLSID_SpMMAudioIn and then use the ISpMMSysAudio::SetDeviceId method to select the device. In typical application development, this will not be necessary for two reasons:

Desktop applications will generally be using the shared recognizer instance which automatically sets itself to use the default audio device. This cannot be changed.

For the InProc recognizer instance, tokens exist to allow quick creation of the correct SpMMAudioIn or SpMMAudioOut for all the multimedia devices on the system.

For input devices, SAPI will attempt to automatically identify the microphone line on the input device. On non-English versions of Windows and on a small number of English systems, it may not be possible for SAPI to automatically detect the correct microphone line. In this case no error will be detected or returned. In such cases, if speech input is not being correctly detected, the user must set the microphone input line directly through Speech properties in Control Panel, Speech Recognition tab, Audio Settings, Properties. In particular, this may be necessary to adjust the microphone input line used on devices with multiple microphone inputs such as the SoundBlaster Live Platinum as the automatically chosen line may not be the input preferred by the user.

When to Implement

The following list shows what implements this interface.

  • SpMMAudioIn
  • SpMMAudioOut

Methods

The following table lists methods for the ISpMMSysAudio interface.

Method Description

GetDeviceId

Passes back the multimedia device identifier being used by the audio object.

GetLineId

Retrieves the line identifier associated with the multimedia device.

GetMMHandle

Passes back a multimedia audio stream handle.

Read

Read data from the multimedia audio device.

SetDeviceId

Sets the multimedia device identifier.

SetLineId

Sets the line identifier associated with the multimedia device.

Write

Write data to the multimedia audio device.

Requirements

Header sapi.h, sapi.idl
Library sapilib.lib
Windows Embedded CE Windows CE .NET 4.1 and later

See Also

Reference

SAPI Interfaces