IRTCClient::get_PreferredAudioDevice

The get_PreferredAudioDevice property gets the preferred audio device for audio capturing or rendering. This method retrieves the audio device set in IRTCClient::put_PreferredAudioDevice.

HRESULT get_PreferredAudioDevice(RTC_AUDIO_DEVICEenDevice,
BSTR*pbstrDeviceName);

Parameters

  • enDevice
    [in] An RTC_AUDIO_DEVICE enumeration that specifies the audio device type to return.
  • pbstrDeviceName
    [out] BSTR containing the device name. The caller is responsible for freeing this memory with SysFreeString.

Return Values

RTC methods may return an RTC_E_ constant.

Value Meaning
RTC_E_NO_DEVICE No preferred audio device.
RTC_E_CLIENT_NOT_INITIALIZED The client has not been initialized.

Requirements

Client: Requires Windows XP.
Server: Requires Windows Server 2003.
Redistributable: Requires Rtcdll.dll on Windows 2000, and Windows Me/98.
Header: Declared in Rtccore.h.
Library: Included as a resource in Rtcdll.dll.
GUID: IID_IRTCClient is defined as 07829e45-9a34-408e-a011-bddf13487cd1.

See Also

IRTCClient, RTC_AUDIO_DEVICE, IRTCClient::put_PreferredAudioDevice, IRTCClient::get_PreferredVideoDevice