Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1908)

Unified Diff: content/renderer/media/webrtc_audio_device_impl.cc

Issue 1834323002: MediaStream audio: Refactor 3 separate "glue" implementations into one. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Reworked unit tests around structural changes, and added exhaustive media_stream_audio_unittest.cc. Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/renderer/media/webrtc_audio_device_impl.cc
diff --git a/content/renderer/media/webrtc_audio_device_impl.cc b/content/renderer/media/webrtc_audio_device_impl.cc
index 00807a909f1beedcee680bbaaf13922359385892..7f46506fada893b16edde60a8ebd81d4042d7cc5 100644
--- a/content/renderer/media/webrtc_audio_device_impl.cc
+++ b/content/renderer/media/webrtc_audio_device_impl.cc
@@ -4,15 +4,13 @@
#include "content/renderer/media/webrtc_audio_device_impl.h"
-#include "base/bind.h"
#include "base/metrics/histogram.h"
#include "base/strings/string_util.h"
#include "base/win/windows_version.h"
-#include "content/renderer/media/media_stream_audio_processor.h"
-#include "content/renderer/media/webrtc_audio_capturer.h"
+#include "content/renderer/media/webrtc/processed_local_audio_source.h"
#include "content/renderer/media/webrtc_audio_renderer.h"
-#include "content/renderer/render_thread_impl.h"
#include "media/audio/sample_rates.h"
+#include "media/base/audio_bus.h"
#include "media/base/audio_parameters.h"
using media::AudioParameters;
@@ -360,7 +358,7 @@ int32_t WebRtcAudioDeviceImpl::RecordingDelay(uint16_t* delay_ms) const {
DCHECK(signaling_thread_checker_.CalledOnValidThread());
// There is no way to report a correct delay value to WebRTC since there
- // might be multiple WebRtcAudioCapturer instances.
+ // might be multiple ProcessedLocalAudioSource instances.
NOTREACHED();
return -1;
}
@@ -421,7 +419,8 @@ bool WebRtcAudioDeviceImpl::SetAudioRenderer(WebRtcAudioRenderer* renderer) {
return true;
}
-void WebRtcAudioDeviceImpl::AddAudioCapturer(WebRtcAudioCapturer* capturer) {
+void WebRtcAudioDeviceImpl::AddAudioCapturer(
+ ProcessedLocalAudioSource* capturer) {
DCHECK(main_thread_checker_.CalledOnValidThread());
DVLOG(1) << "WebRtcAudioDeviceImpl::AddAudioCapturer()";
DCHECK(capturer);
@@ -433,7 +432,8 @@ void WebRtcAudioDeviceImpl::AddAudioCapturer(WebRtcAudioCapturer* capturer) {
capturers_.push_back(capturer);
}
-void WebRtcAudioDeviceImpl::RemoveAudioCapturer(WebRtcAudioCapturer* capturer) {
+void WebRtcAudioDeviceImpl::RemoveAudioCapturer(
+ ProcessedLocalAudioSource* capturer) {
DCHECK(main_thread_checker_.CalledOnValidThread());
DVLOG(1) << "WebRtcAudioDeviceImpl::RemoveAudioCapturer()";
DCHECK(capturer);

Powered by Google App Engine
This is Rietveld 408576698