| Index: media/audio/win/audio_low_latency_input_win.cc
|
| diff --git a/media/audio/win/audio_low_latency_input_win.cc b/media/audio/win/audio_low_latency_input_win.cc
|
| index 7fba7b0e4eaf1e3254945d3b5de272c27526405b..4169554081802754f48f49b995e88c20d641d1fb 100644
|
| --- a/media/audio/win/audio_low_latency_input_win.cc
|
| +++ b/media/audio/win/audio_low_latency_input_win.cc
|
| @@ -4,6 +4,8 @@
|
|
|
| #include "media/audio/win/audio_low_latency_input_win.h"
|
|
|
| +#include <objbase.h>
|
| +
|
| #include <cmath>
|
| #include <memory>
|
|
|
| @@ -124,7 +126,7 @@ bool WASAPIAudioInputStream::Open() {
|
| // Obtain an IAudioClient interface which enables us to create and initialize
|
| // an audio stream between an audio application and the audio engine.
|
| hr = endpoint_device_->Activate(__uuidof(IAudioClient), CLSCTX_INPROC_SERVER,
|
| - NULL, audio_client_.ReceiveVoid());
|
| + NULL, &audio_client_);
|
| if (FAILED(hr)) {
|
| open_result_ = OPEN_RESULT_ACTIVATION_FAILED;
|
| ReportOpenResult();
|
| @@ -377,7 +379,7 @@ void WASAPIAudioInputStream::Run() {
|
| audio_samples_ready_event_.Get()};
|
|
|
| base::win::ScopedComPtr<IAudioClock> audio_clock;
|
| - audio_client_->GetService(__uuidof(IAudioClock), audio_clock.ReceiveVoid());
|
| + audio_client_->GetService(IID_PPV_ARGS(&audio_clock));
|
|
|
| while (recording && !error) {
|
| HRESULT hr = S_FALSE;
|
| @@ -536,7 +538,7 @@ HRESULT WASAPIAudioInputStream::SetCaptureDevice() {
|
| endpoint_device_.Receive());
|
|
|
| endpoint_device_->Activate(__uuidof(IAudioEndpointVolume), CLSCTX_ALL, NULL,
|
| - system_audio_volume_.ReceiveVoid());
|
| + &system_audio_volume_);
|
| } else if (device_id_ == AudioDeviceDescription::kLoopbackInputDeviceId) {
|
| // Capture the default playback stream.
|
| hr = enumerator->GetDefaultAudioEndpoint(eRender, eConsole,
|
| @@ -777,7 +779,7 @@ HRESULT WASAPIAudioInputStream::InitializeAudioEngine() {
|
| device_id_ == AudioDeviceDescription::kLoopbackWithMuteDeviceId) {
|
| hr = endpoint_device_->Activate(
|
| __uuidof(IAudioClient), CLSCTX_INPROC_SERVER, NULL,
|
| - audio_render_client_for_loopback_.ReceiveVoid());
|
| + &audio_render_client_for_loopback_);
|
| if (FAILED(hr)) {
|
| open_result_ = OPEN_RESULT_LOOPBACK_ACTIVATE_FAILED;
|
| return hr;
|
| @@ -805,8 +807,7 @@ HRESULT WASAPIAudioInputStream::InitializeAudioEngine() {
|
|
|
| // Get access to the IAudioCaptureClient interface. This interface
|
| // enables us to read input data from the capture endpoint buffer.
|
| - hr = audio_client_->GetService(__uuidof(IAudioCaptureClient),
|
| - audio_capture_client_.ReceiveVoid());
|
| + hr = audio_client_->GetService(IID_PPV_ARGS(&audio_capture_client_));
|
| if (FAILED(hr)) {
|
| open_result_ = OPEN_RESULT_NO_CAPTURE_CLIENT;
|
| return hr;
|
| @@ -814,8 +815,7 @@ HRESULT WASAPIAudioInputStream::InitializeAudioEngine() {
|
|
|
| // Obtain a reference to the ISimpleAudioVolume interface which enables
|
| // us to control the master volume level of an audio session.
|
| - hr = audio_client_->GetService(__uuidof(ISimpleAudioVolume),
|
| - simple_audio_volume_.ReceiveVoid());
|
| + hr = audio_client_->GetService(IID_PPV_ARGS(&simple_audio_volume_));
|
| if (FAILED(hr))
|
| open_result_ = OPEN_RESULT_NO_AUDIO_VOLUME;
|
|
|
|
|