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

Side by Side Diff: content/browser/renderer_host/media/audio_input_renderer_host.cc

Issue 2531333005: Unit tests of AudioInputRendererHost. Some cleanups. (Closed)
Patch Set: Small comments describing tests. Created 4 years 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/browser/renderer_host/media/audio_input_renderer_host.h" 5 #include "content/browser/renderer_host/media/audio_input_renderer_host.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
11 #include "base/files/file.h" 11 #include "base/files/file.h"
12 #include "base/memory/ref_counted.h" 12 #include "base/memory/ref_counted.h"
13 #include "base/memory/shared_memory.h" 13 #include "base/memory/shared_memory.h"
14 #include "base/metrics/histogram_macros.h" 14 #include "base/metrics/histogram_macros.h"
15 #include "base/numerics/safe_math.h" 15 #include "base/numerics/safe_math.h"
16 #include "base/process/process.h" 16 #include "base/process/process.h"
17 #include "base/strings/string_number_conversions.h" 17 #include "base/strings/string_number_conversions.h"
18 #include "base/strings/stringprintf.h" 18 #include "base/strings/stringprintf.h"
19 #include "base/sync_socket.h"
19 #include "build/build_config.h" 20 #include "build/build_config.h"
21 #include "content/browser/bad_message.h"
20 #include "content/browser/media/capture/desktop_capture_device_uma_types.h" 22 #include "content/browser/media/capture/desktop_capture_device_uma_types.h"
21 #include "content/browser/media/capture/web_contents_audio_input_stream.h" 23 #include "content/browser/media/capture/web_contents_audio_input_stream.h"
22 #include "content/browser/media/media_internals.h" 24 #include "content/browser/media/media_internals.h"
23 #include "content/browser/renderer_host/media/audio_input_debug_writer.h" 25 #include "content/browser/renderer_host/media/audio_input_debug_writer.h"
24 #include "content/browser/renderer_host/media/audio_input_device_manager.h" 26 #include "content/browser/renderer_host/media/audio_input_device_manager.h"
25 #include "content/browser/renderer_host/media/audio_input_sync_writer.h" 27 #include "content/browser/renderer_host/media/audio_input_sync_writer.h"
26 #include "content/browser/renderer_host/media/media_stream_manager.h" 28 #include "content/browser/renderer_host/media/media_stream_manager.h"
27 #include "content/browser/webrtc/webrtc_internals.h" 29 #include "content/browser/webrtc/webrtc_internals.h"
28 #include "content/public/browser/web_contents_media_capture_id.h" 30 #include "content/public/browser/web_contents_media_capture_id.h"
29 #include "media/audio/audio_device_description.h" 31 #include "media/audio/audio_device_description.h"
(...skipping 11 matching lines...) Expand all
41 const base::FilePath::CharType kDebugRecordingFileNameExtension[] = 43 const base::FilePath::CharType kDebugRecordingFileNameExtension[] =
42 FILE_PATH_LITERAL("wav"); 44 FILE_PATH_LITERAL("wav");
43 #endif 45 #endif
44 46
45 void LogMessage(int stream_id, const std::string& msg, bool add_prefix) { 47 void LogMessage(int stream_id, const std::string& msg, bool add_prefix) {
46 std::ostringstream oss; 48 std::ostringstream oss;
47 oss << "[stream_id=" << stream_id << "] "; 49 oss << "[stream_id=" << stream_id << "] ";
48 if (add_prefix) 50 if (add_prefix)
49 oss << "AIRH::"; 51 oss << "AIRH::";
50 oss << msg; 52 oss << msg;
51 content::MediaStreamManager::SendMessageToNativeLog(oss.str()); 53 const std::string message = oss.str();
52 DVLOG(1) << oss.str(); 54 content::MediaStreamManager::SendMessageToNativeLog(message);
55 DVLOG(1) << message;
53 } 56 }
54 57
55 } // namespace 58 } // namespace
56 59
57 struct AudioInputRendererHost::AudioEntry { 60 struct AudioInputRendererHost::AudioEntry {
58 AudioEntry(); 61 AudioEntry();
59 ~AudioEntry(); 62 ~AudioEntry();
60 63
61 // The AudioInputController that manages the audio input stream. 64 // The AudioInputController that manages the audio input stream.
62 scoped_refptr<media::AudioInputController> controller; 65 scoped_refptr<media::AudioInputController> controller;
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 AudioMirroringManager* audio_mirroring_manager, 101 AudioMirroringManager* audio_mirroring_manager,
99 media::UserInputMonitor* user_input_monitor) 102 media::UserInputMonitor* user_input_monitor)
100 : BrowserMessageFilter(AudioMsgStart), 103 : BrowserMessageFilter(AudioMsgStart),
101 render_process_id_(render_process_id), 104 render_process_id_(render_process_id),
102 renderer_pid_(renderer_pid), 105 renderer_pid_(renderer_pid),
103 audio_manager_(audio_manager), 106 audio_manager_(audio_manager),
104 media_stream_manager_(media_stream_manager), 107 media_stream_manager_(media_stream_manager),
105 audio_mirroring_manager_(audio_mirroring_manager), 108 audio_mirroring_manager_(audio_mirroring_manager),
106 user_input_monitor_(user_input_monitor), 109 user_input_monitor_(user_input_monitor),
107 audio_log_(MediaInternals::GetInstance()->CreateAudioLog( 110 audio_log_(MediaInternals::GetInstance()->CreateAudioLog(
108 media::AudioLogFactory::AUDIO_INPUT_CONTROLLER)), 111 media::AudioLogFactory::AUDIO_INPUT_CONTROLLER)) {}
109 weak_factory_(this) {}
110 112
111 AudioInputRendererHost::~AudioInputRendererHost() { 113 AudioInputRendererHost::~AudioInputRendererHost() {
112 DCHECK_CURRENTLY_ON(BrowserThread::IO); 114 DCHECK_CURRENTLY_ON(BrowserThread::IO);
113 DCHECK(audio_entries_.empty()); 115 DCHECK(audio_entries_.empty());
114 } 116 }
115 117
116 #if BUILDFLAG(ENABLE_WEBRTC) 118 #if BUILDFLAG(ENABLE_WEBRTC)
117 void AudioInputRendererHost::EnableDebugRecording(const base::FilePath& file) { 119 void AudioInputRendererHost::EnableDebugRecording(const base::FilePath& file) {
118 DCHECK_CURRENTLY_ON(BrowserThread::IO); 120 DCHECK_CURRENTLY_ON(BrowserThread::IO);
119 base::FilePath file_with_extensions = 121 base::FilePath file_with_extensions =
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
177 void AudioInputRendererHost::set_renderer_pid(int32_t renderer_pid) { 179 void AudioInputRendererHost::set_renderer_pid(int32_t renderer_pid) {
178 DCHECK_CURRENTLY_ON(BrowserThread::IO); 180 DCHECK_CURRENTLY_ON(BrowserThread::IO);
179 renderer_pid_ = renderer_pid; 181 renderer_pid_ = renderer_pid;
180 } 182 }
181 183
182 void AudioInputRendererHost::DoCompleteCreation( 184 void AudioInputRendererHost::DoCompleteCreation(
183 media::AudioInputController* controller) { 185 media::AudioInputController* controller) {
184 DCHECK_CURRENTLY_ON(BrowserThread::IO); 186 DCHECK_CURRENTLY_ON(BrowserThread::IO);
185 187
186 AudioEntry* entry = LookupByController(controller); 188 AudioEntry* entry = LookupByController(controller);
187 if (!entry) { 189 DCHECK(entry);
188 NOTREACHED() << "AudioInputController is invalid."; 190 DCHECK(PeerHandle());
189 return; 191 DCHECK(entry->controller->SharedMemoryAndSyncSocketMode());
190 }
191
192 if (!PeerHandle()) {
193 NOTREACHED() << "Renderer process handle is invalid.";
194 DeleteEntryOnError(entry, INVALID_PEER_HANDLE);
195 return;
196 }
197
198 if (!entry->controller->SharedMemoryAndSyncSocketMode()) {
199 NOTREACHED() << "Only shared-memory/sync-socket mode is supported.";
200 DeleteEntryOnError(entry, INVALID_LATENCY_MODE);
201 return;
202 }
203 192
204 // Once the audio stream is created then complete the creation process by 193 // Once the audio stream is created then complete the creation process by
205 // mapping shared memory and sharing with the renderer process. 194 // mapping shared memory and sharing with the renderer process.
206 base::SharedMemoryHandle foreign_memory_handle; 195 base::SharedMemoryHandle foreign_memory_handle;
207 if (!entry->shared_memory.ShareToProcess(PeerHandle(), 196 if (!entry->shared_memory.ShareToProcess(PeerHandle(),
208 &foreign_memory_handle)) { 197 &foreign_memory_handle)) {
209 // If we failed to map and share the shared memory then close the audio 198 // If we failed to map and share the shared memory then close the audio
210 // stream and send an error message. 199 // stream and send an error message.
211 DeleteEntryOnError(entry, MEMORY_SHARING_FAILED); 200 DeleteEntryOnError(entry, MEMORY_SHARING_FAILED);
212 return; 201 return;
(...skipping 19 matching lines...) Expand all
232 entry->shared_memory.requested_size(), 221 entry->shared_memory.requested_size(),
233 entry->shared_memory_segment_count)); 222 entry->shared_memory_segment_count));
234 } 223 }
235 224
236 void AudioInputRendererHost::DoSendRecordingMessage( 225 void AudioInputRendererHost::DoSendRecordingMessage(
237 media::AudioInputController* controller) { 226 media::AudioInputController* controller) {
238 DCHECK_CURRENTLY_ON(BrowserThread::IO); 227 DCHECK_CURRENTLY_ON(BrowserThread::IO);
239 // TODO(henrika): See crbug.com/115262 for details on why this method 228 // TODO(henrika): See crbug.com/115262 for details on why this method
240 // should be implemented. 229 // should be implemented.
241 AudioEntry* entry = LookupByController(controller); 230 AudioEntry* entry = LookupByController(controller);
242 if (!entry) { 231 DCHECK(entry) << "AudioInputController is invalid.";
243 NOTREACHED() << "AudioInputController is invalid.";
244 return;
245 }
246 LogMessage( 232 LogMessage(
247 entry->stream_id, "DoSendRecordingMessage: stream is now started", true); 233 entry->stream_id, "DoSendRecordingMessage: stream is now started", true);
248 } 234 }
249 235
250 void AudioInputRendererHost::DoHandleError( 236 void AudioInputRendererHost::DoHandleError(
251 media::AudioInputController* controller, 237 media::AudioInputController* controller,
252 media::AudioInputController::ErrorCode error_code) { 238 media::AudioInputController::ErrorCode error_code) {
253 DCHECK_CURRENTLY_ON(BrowserThread::IO); 239 DCHECK_CURRENTLY_ON(BrowserThread::IO);
254 AudioEntry* entry = LookupByController(controller); 240 AudioEntry* entry = LookupByController(controller);
255 if (!entry) { 241 DCHECK(entry);
256 NOTREACHED() << "AudioInputController is invalid.";
257 return;
258 }
259 242
260 std::ostringstream oss; 243 std::ostringstream oss;
261 oss << "AIC reports error_code=" << error_code; 244 oss << "AIC reports error_code=" << error_code;
262 LogMessage(entry->stream_id, oss.str(), false); 245 LogMessage(entry->stream_id, oss.str(), false);
263 246
264 audio_log_->OnError(entry->stream_id); 247 audio_log_->OnError(entry->stream_id);
265 DeleteEntryOnError(entry, AUDIO_INPUT_CONTROLLER_ERROR); 248 DeleteEntryOnError(entry, AUDIO_INPUT_CONTROLLER_ERROR);
266 } 249 }
267 250
268 void AudioInputRendererHost::DoLog(media::AudioInputController* controller, 251 void AudioInputRendererHost::DoLog(media::AudioInputController* controller,
269 const std::string& message) { 252 const std::string& message) {
270 DCHECK_CURRENTLY_ON(BrowserThread::IO); 253 DCHECK_CURRENTLY_ON(BrowserThread::IO);
271 AudioEntry* entry = LookupByController(controller); 254 AudioEntry* entry = LookupByController(controller);
272 if (!entry) { 255 DCHECK(entry);
273 NOTREACHED() << "AudioInputController is invalid.";
274 return;
275 }
276 256
277 // Add stream ID and current audio level reported by AIC to native log. 257 // Add stream ID and current audio level reported by AIC to native log.
278 LogMessage(entry->stream_id, message, false); 258 LogMessage(entry->stream_id, message, false);
279 } 259 }
280 260
281 bool AudioInputRendererHost::OnMessageReceived(const IPC::Message& message) { 261 bool AudioInputRendererHost::OnMessageReceived(const IPC::Message& message) {
282 bool handled = true; 262 bool handled = true;
283 IPC_BEGIN_MESSAGE_MAP(AudioInputRendererHost, message) 263 IPC_BEGIN_MESSAGE_MAP(AudioInputRendererHost, message)
284 IPC_MESSAGE_HANDLER(AudioInputHostMsg_CreateStream, OnCreateStream) 264 IPC_MESSAGE_HANDLER(AudioInputHostMsg_CreateStream, OnCreateStream)
285 IPC_MESSAGE_HANDLER(AudioInputHostMsg_RecordStream, OnRecordStream) 265 IPC_MESSAGE_HANDLER(AudioInputHostMsg_RecordStream, OnRecordStream)
(...skipping 27 matching lines...) Expand all
313 #endif 293 #endif
314 } 294 }
315 295
316 void AudioInputRendererHost::DoCreateStream( 296 void AudioInputRendererHost::DoCreateStream(
317 int stream_id, 297 int stream_id,
318 int render_frame_id, 298 int render_frame_id,
319 int session_id, 299 int session_id,
320 const AudioInputHostMsg_CreateStream_Config& config) { 300 const AudioInputHostMsg_CreateStream_Config& config) {
321 DCHECK_CURRENTLY_ON(BrowserThread::IO); 301 DCHECK_CURRENTLY_ON(BrowserThread::IO);
322 302
323 std::ostringstream oss;
324 oss << "[stream_id=" << stream_id << "] "
325 << "AIRH::OnCreateStream(render_frame_id=" << render_frame_id
326 << ", session_id=" << session_id << ")";
327 DCHECK_GT(render_frame_id, 0); 303 DCHECK_GT(render_frame_id, 0);
328 304
329 // media::AudioParameters is validated in the deserializer. 305 // media::AudioParameters is validated in the deserializer.
330 if (LookupById(stream_id) != NULL) { 306 if (LookupById(stream_id)) {
331 SendErrorMessage(stream_id, STREAM_ALREADY_EXISTS); 307 SendErrorMessage(stream_id, STREAM_ALREADY_EXISTS);
332 MaybeUnregisterKeyboardMicStream(config); 308 MaybeUnregisterKeyboardMicStream(config);
333 return; 309 return;
334 } 310 }
335 311
312 // Check if we have the permission to open the device and which device to use.
313 const StreamDeviceInfo* info =
314 media_stream_manager_->audio_input_device_manager()
315 ->GetOpenedDeviceInfoById(session_id);
316 if (!info) {
317 SendErrorMessage(stream_id, PERMISSION_DENIED);
318 DLOG(WARNING) << "No permission has been granted to input stream with "
319 << "session_id=" << session_id;
320 MaybeUnregisterKeyboardMicStream(config);
321 return;
322 }
323
324 const MediaStreamType& type = info->device.type;
325 const std::string& device_id = info->device.id;
326 const std::string& device_name = info->device.name;
336 media::AudioParameters audio_params(config.params); 327 media::AudioParameters audio_params(config.params);
337 if (base::CommandLine::ForCurrentProcess()->HasSwitch( 328 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
338 switches::kUseFakeDeviceForMediaStream)) { 329 switches::kUseFakeDeviceForMediaStream)) {
339 audio_params.set_format(media::AudioParameters::AUDIO_FAKE); 330 audio_params.set_format(media::AudioParameters::AUDIO_FAKE);
340 } 331 }
341 332
342 // Check if we have the permission to open the device and which device to use. 333 std::ostringstream oss;
343 MediaStreamType type = MEDIA_NO_SERVICE; 334 oss << "[stream_id=" << stream_id << "] "
344 std::string device_name; 335 << "AIRH::OnCreateStream(render_frame_id=" << render_frame_id
345 std::string device_id = media::AudioDeviceDescription::kDefaultDeviceId; 336 << ", session_id=" << session_id << ")"
346 if (audio_params.format() != media::AudioParameters::AUDIO_FAKE) { 337 << ": device_name=" << device_name;
347 const StreamDeviceInfo* info = media_stream_manager_->
348 audio_input_device_manager()->GetOpenedDeviceInfoById(session_id);
349 if (!info) {
350 SendErrorMessage(stream_id, PERMISSION_DENIED);
351 DLOG(WARNING) << "No permission has been granted to input stream with "
352 << "session_id=" << session_id;
353 MaybeUnregisterKeyboardMicStream(config);
354 return;
355 }
356 type = info->device.type;
357 device_id = info->device.id;
358 device_name = info->device.name;
359 oss << ": device_name=" << device_name;
360 }
361 338
362 // Create a new AudioEntry structure. 339 // Create a new AudioEntry structure.
363 std::unique_ptr<AudioEntry> entry(new AudioEntry()); 340 std::unique_ptr<AudioEntry> entry(new AudioEntry());
364 341
365 const uint32_t segment_size = 342 const uint32_t segment_size =
366 (sizeof(media::AudioInputBufferParameters) + 343 (sizeof(media::AudioInputBufferParameters) +
367 media::AudioBus::CalculateMemorySize(audio_params)); 344 media::AudioBus::CalculateMemorySize(audio_params));
368 entry->shared_memory_segment_count = config.shared_memory_count; 345 entry->shared_memory_segment_count = config.shared_memory_count;
369 346
370 // Create the shared memory and share it with the renderer process 347 // Create the shared memory and share it with the renderer process
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
443 return; 420 return;
444 } 421 }
445 422
446 #if defined(OS_CHROMEOS) 423 #if defined(OS_CHROMEOS)
447 if (config.params.channel_layout() == 424 if (config.params.channel_layout() ==
448 media::CHANNEL_LAYOUT_STEREO_AND_KEYBOARD_MIC) { 425 media::CHANNEL_LAYOUT_STEREO_AND_KEYBOARD_MIC) {
449 entry->has_keyboard_mic = true; 426 entry->has_keyboard_mic = true;
450 } 427 }
451 #endif 428 #endif
452 429
453 MediaStreamManager::SendMessageToNativeLog(oss.str()); 430 const std::string log_message = oss.str();
454 DVLOG(1) << oss.str(); 431 MediaStreamManager::SendMessageToNativeLog(log_message);
432 DVLOG(1) << log_message;
455 433
456 // Since the controller was created successfully, create an entry and add it 434 // Since the controller was created successfully, create an entry and add it
457 // to the map. 435 // to the map.
458 entry->stream_id = stream_id; 436 entry->stream_id = stream_id;
459 audio_entries_.insert(std::make_pair(stream_id, entry.release())); 437 audio_entries_.insert(std::make_pair(stream_id, entry.release()));
460 audio_log_->OnCreated(stream_id, audio_params, device_id); 438 audio_log_->OnCreated(stream_id, audio_params, device_id);
461 MediaInternals::GetInstance()->SetWebContentsTitleForAudioLogEntry( 439 MediaInternals::GetInstance()->SetWebContentsTitleForAudioLogEntry(
462 stream_id, render_process_id_, render_frame_id, audio_log_.get()); 440 stream_id, render_process_id_, render_frame_id, audio_log_.get());
463 441
464 #if BUILDFLAG(ENABLE_WEBRTC) 442 #if BUILDFLAG(ENABLE_WEBRTC)
(...skipping 27 matching lines...) Expand all
492 470
493 AudioEntry* entry = LookupById(stream_id); 471 AudioEntry* entry = LookupById(stream_id);
494 472
495 if (entry) 473 if (entry)
496 CloseAndDeleteStream(entry); 474 CloseAndDeleteStream(entry);
497 } 475 }
498 476
499 void AudioInputRendererHost::OnSetVolume(int stream_id, double volume) { 477 void AudioInputRendererHost::OnSetVolume(int stream_id, double volume) {
500 DCHECK_CURRENTLY_ON(BrowserThread::IO); 478 DCHECK_CURRENTLY_ON(BrowserThread::IO);
501 479
480 if (volume < 0 || volume > 1) {
481 bad_message::ReceivedBadMessage(this,
482 bad_message::AIRH_VOLUME_OUT_OF_RANGE);
483 return;
484 }
485
502 AudioEntry* entry = LookupById(stream_id); 486 AudioEntry* entry = LookupById(stream_id);
503 if (!entry) { 487 if (!entry) {
504 SendErrorMessage(stream_id, INVALID_AUDIO_ENTRY); 488 SendErrorMessage(stream_id, INVALID_AUDIO_ENTRY);
505 return; 489 return;
506 } 490 }
507 491
508 entry->controller->SetVolume(volume); 492 entry->controller->SetVolume(volume);
509 audio_log_->OnSetVolume(stream_id, volume); 493 audio_log_->OnSetVolume(stream_id, volume);
510 } 494 }
511 495
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
568 CloseAndDeleteStream(entry); 552 CloseAndDeleteStream(entry);
569 } 553 }
570 554
571 AudioInputRendererHost::AudioEntry* AudioInputRendererHost::LookupById( 555 AudioInputRendererHost::AudioEntry* AudioInputRendererHost::LookupById(
572 int stream_id) { 556 int stream_id) {
573 DCHECK_CURRENTLY_ON(BrowserThread::IO); 557 DCHECK_CURRENTLY_ON(BrowserThread::IO);
574 558
575 AudioEntryMap::iterator i = audio_entries_.find(stream_id); 559 AudioEntryMap::iterator i = audio_entries_.find(stream_id);
576 if (i != audio_entries_.end()) 560 if (i != audio_entries_.end())
577 return i->second; 561 return i->second;
578 return NULL; 562 return nullptr;
579 } 563 }
580 564
581 AudioInputRendererHost::AudioEntry* AudioInputRendererHost::LookupByController( 565 AudioInputRendererHost::AudioEntry* AudioInputRendererHost::LookupByController(
582 media::AudioInputController* controller) { 566 media::AudioInputController* controller) {
583 DCHECK_CURRENTLY_ON(BrowserThread::IO); 567 DCHECK_CURRENTLY_ON(BrowserThread::IO);
584 568
585 // Iterate the map of entries. 569 // Iterate the map of entries.
586 // TODO(hclam): Implement a faster look up method. 570 // TODO(hclam): Implement a faster look up method.
587 for (AudioEntryMap::iterator i = audio_entries_.begin(); 571 for (AudioEntryMap::iterator i = audio_entries_.begin();
588 i != audio_entries_.end(); ++i) { 572 i != audio_entries_.end(); ++i) {
589 if (controller == i->second->controller.get()) 573 if (controller == i->second->controller.get())
590 return i->second; 574 return i->second;
591 } 575 }
592 return NULL; 576 return nullptr;
593 } 577 }
594 578
595 void AudioInputRendererHost::MaybeUnregisterKeyboardMicStream( 579 void AudioInputRendererHost::MaybeUnregisterKeyboardMicStream(
596 const AudioInputHostMsg_CreateStream_Config& config) { 580 const AudioInputHostMsg_CreateStream_Config& config) {
597 #if defined(OS_CHROMEOS) 581 #if defined(OS_CHROMEOS)
598 if (config.params.channel_layout() == 582 if (config.params.channel_layout() ==
599 media::CHANNEL_LAYOUT_STEREO_AND_KEYBOARD_MIC) { 583 media::CHANNEL_LAYOUT_STEREO_AND_KEYBOARD_MIC) {
600 media_stream_manager_->audio_input_device_manager() 584 media_stream_manager_->audio_input_device_manager()
601 ->UnregisterKeyboardMicStream(); 585 ->UnregisterKeyboardMicStream();
602 } 586 }
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
642 entry->controller->EnableDebugRecording( 626 entry->controller->EnableDebugRecording(
643 file_name.AddExtension(IntToStringType(stream_id)) 627 file_name.AddExtension(IntToStringType(stream_id))
644 .AddExtension(kDebugRecordingFileNameExtension)); 628 .AddExtension(kDebugRecordingFileNameExtension));
645 } 629 }
646 630
647 #undef IntToStringType 631 #undef IntToStringType
648 632
649 #endif // BUILDFLAG(ENABLE_WEBRTC) 633 #endif // BUILDFLAG(ENABLE_WEBRTC)
650 634
651 } // namespace content 635 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698