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

Side by Side Diff: content/renderer/media/media_stream_audio_track.cc

Issue 2956063003: Add support for echoCancellation and deviceId to MediaStreamTrack.getSettings (Closed)
Patch Set: fix DCHECK Created 3 years, 5 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/media/media_stream_audio_track.h" 5 #include "content/renderer/media/media_stream_audio_track.h"
6 6
7 #include <vector>
8
7 #include "base/callback_helpers.h" 9 #include "base/callback_helpers.h"
8 #include "base/logging.h" 10 #include "base/logging.h"
9 #include "content/public/renderer/media_stream_audio_sink.h" 11 #include "content/public/renderer/media_stream_audio_sink.h"
10 #include "media/base/audio_bus.h" 12 #include "media/base/audio_bus.h"
11 #include "third_party/WebKit/public/platform/WebMediaStreamSource.h" 13 #include "third_party/WebKit/public/platform/WebMediaStreamSource.h"
12 14
13 namespace content { 15 namespace content {
14 16
15 MediaStreamAudioTrack::MediaStreamAudioTrack(bool is_local_track) 17 MediaStreamAudioTrack::MediaStreamAudioTrack(bool is_local_track)
16 : MediaStreamTrack(is_local_track), is_enabled_(1), weak_factory_(this) { 18 : MediaStreamTrack(is_local_track), is_enabled_(1), weak_factory_(this) {
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 if (!silent_bus_ || silent_bus_->channels() != audio_bus.channels() || 136 if (!silent_bus_ || silent_bus_->channels() != audio_bus.channels() ||
135 silent_bus_->frames() != audio_bus.frames()) { 137 silent_bus_->frames() != audio_bus.frames()) {
136 silent_bus_ = media::AudioBus::Create(audio_bus.channels(), 138 silent_bus_ = media::AudioBus::Create(audio_bus.channels(),
137 audio_bus.frames()); 139 audio_bus.frames());
138 silent_bus_->Zero(); 140 silent_bus_->Zero();
139 } 141 }
140 deliverer_.OnData(*silent_bus_, reference_time); 142 deliverer_.OnData(*silent_bus_, reference_time);
141 } 143 }
142 } 144 }
143 145
144 void MediaStreamAudioTrack::GetSettings(
145 blink::WebMediaStreamTrack::Settings& settings) {
146 // TODO(hta): Extract the real value.
147 settings.device_id = blink::WebString("audio device ID");
148 }
149
150 } // namespace content 146 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/media/media_stream_audio_track.h ('k') | content/renderer/media/user_media_client_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698