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

Unified Diff: content/renderer/media/media_stream_audio_sink_owner.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: REBASE + Workaround to ensure MediaStreamAudioProcessor is destroyed on the main thread. Created 4 years, 7 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/media_stream_audio_sink_owner.cc
diff --git a/content/renderer/media/media_stream_audio_sink_owner.cc b/content/renderer/media/media_stream_audio_sink_owner.cc
deleted file mode 100644
index cee6a1d2a56ca50aeec384ee34fbb3537e42d3fa..0000000000000000000000000000000000000000
--- a/content/renderer/media/media_stream_audio_sink_owner.cc
+++ /dev/null
@@ -1,49 +0,0 @@
-// Copyright 2013 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "content/renderer/media/media_stream_audio_sink_owner.h"
-
-#include "content/public/renderer/media_stream_audio_sink.h"
-#include "media/base/audio_parameters.h"
-
-namespace content {
-
-MediaStreamAudioSinkOwner::MediaStreamAudioSinkOwner(MediaStreamAudioSink* sink)
- : delegate_(sink) {
-}
-
-void MediaStreamAudioSinkOwner::OnData(const media::AudioBus& audio_bus,
- base::TimeTicks estimated_capture_time) {
- base::AutoLock lock(lock_);
- if (delegate_)
- delegate_->OnData(audio_bus, estimated_capture_time);
-}
-
-void MediaStreamAudioSinkOwner::OnSetFormat(
- const media::AudioParameters& params) {
- base::AutoLock lock(lock_);
- if (delegate_)
- delegate_->OnSetFormat(params);
-}
-
-void MediaStreamAudioSinkOwner::OnReadyStateChanged(
- blink::WebMediaStreamSource::ReadyState state) {
- base::AutoLock lock(lock_);
- if (delegate_)
- delegate_->OnReadyStateChanged(state);
-}
-
-void MediaStreamAudioSinkOwner::Reset() {
- base::AutoLock lock(lock_);
- delegate_ = NULL;
-}
-
-bool MediaStreamAudioSinkOwner::IsEqual(
- const MediaStreamAudioSink* other) const {
- DCHECK(other);
- base::AutoLock lock(lock_);
- return (other == delegate_);
-}
-
-} // namespace content
« no previous file with comments | « content/renderer/media/media_stream_audio_sink_owner.h ('k') | content/renderer/media/media_stream_audio_source.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698