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

Side by Side Diff: media/audio/fake_audio_manager.cc

Issue 1864483002: Forward output glitch information from stream WebRTC log (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 years, 6 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
« no previous file with comments | « media/audio/fake_audio_manager.h ('k') | media/audio/mac/audio_auhal_mac.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "media/audio/fake_audio_manager.h" 5 #include "media/audio/fake_audio_manager.h"
6 6
7 namespace media { 7 namespace media {
8 8
9 namespace { 9 namespace {
10 10
(...skipping 17 matching lines...) Expand all
28 Shutdown(); 28 Shutdown();
29 } 29 }
30 30
31 // Implementation of AudioManager. 31 // Implementation of AudioManager.
32 bool FakeAudioManager::HasAudioOutputDevices() { return false; } 32 bool FakeAudioManager::HasAudioOutputDevices() { return false; }
33 33
34 bool FakeAudioManager::HasAudioInputDevices() { return false; } 34 bool FakeAudioManager::HasAudioInputDevices() { return false; }
35 35
36 // Implementation of AudioManagerBase. 36 // Implementation of AudioManagerBase.
37 AudioOutputStream* FakeAudioManager::MakeLinearOutputStream( 37 AudioOutputStream* FakeAudioManager::MakeLinearOutputStream(
38 const AudioParameters& params) { 38 const AudioParameters& params,
39 const LogCallback& log_callback) {
39 return FakeAudioOutputStream::MakeFakeStream(this, params); 40 return FakeAudioOutputStream::MakeFakeStream(this, params);
40 } 41 }
41 42
42 AudioOutputStream* FakeAudioManager::MakeLowLatencyOutputStream( 43 AudioOutputStream* FakeAudioManager::MakeLowLatencyOutputStream(
43 const AudioParameters& params, 44 const AudioParameters& params,
44 const std::string& device_id) { 45 const std::string& device_id,
46 const LogCallback& log_callback) {
45 return FakeAudioOutputStream::MakeFakeStream(this, params); 47 return FakeAudioOutputStream::MakeFakeStream(this, params);
46 } 48 }
47 49
48 AudioInputStream* FakeAudioManager::MakeLinearInputStream( 50 AudioInputStream* FakeAudioManager::MakeLinearInputStream(
49 const AudioParameters& params, 51 const AudioParameters& params,
50 const std::string& device_id) { 52 const std::string& device_id,
53 const LogCallback& log_callback) {
51 return FakeAudioInputStream::MakeFakeStream(this, params); 54 return FakeAudioInputStream::MakeFakeStream(this, params);
52 } 55 }
53 56
54 AudioInputStream* FakeAudioManager::MakeLowLatencyInputStream( 57 AudioInputStream* FakeAudioManager::MakeLowLatencyInputStream(
55 const AudioParameters& params, 58 const AudioParameters& params,
56 const std::string& device_id) { 59 const std::string& device_id,
60 const LogCallback& log_callback) {
57 return FakeAudioInputStream::MakeFakeStream(this, params); 61 return FakeAudioInputStream::MakeFakeStream(this, params);
58 } 62 }
59 63
60 AudioParameters FakeAudioManager::GetPreferredOutputStreamParameters( 64 AudioParameters FakeAudioManager::GetPreferredOutputStreamParameters(
61 const std::string& output_device_id, 65 const std::string& output_device_id,
62 const AudioParameters& input_params) { 66 const AudioParameters& input_params) {
63 static const int kDefaultOutputBufferSize = 2048; 67 static const int kDefaultOutputBufferSize = 2048;
64 static const int kDefaultSampleRate = 48000; 68 static const int kDefaultSampleRate = 48000;
65 ChannelLayout channel_layout = CHANNEL_LAYOUT_STEREO; 69 ChannelLayout channel_layout = CHANNEL_LAYOUT_STEREO;
66 int sample_rate = kDefaultSampleRate; 70 int sample_rate = kDefaultSampleRate;
(...skipping 11 matching lines...) Expand all
78 } 82 }
79 83
80 AudioParameters FakeAudioManager::GetInputStreamParameters( 84 AudioParameters FakeAudioManager::GetInputStreamParameters(
81 const std::string& device_id) { 85 const std::string& device_id) {
82 return AudioParameters( 86 return AudioParameters(
83 AudioParameters::AUDIO_PCM_LOW_LATENCY, CHANNEL_LAYOUT_STEREO, 87 AudioParameters::AUDIO_PCM_LOW_LATENCY, CHANNEL_LAYOUT_STEREO,
84 kDefaultSampleRate, 16, kDefaultInputBufferSize); 88 kDefaultSampleRate, 16, kDefaultInputBufferSize);
85 } 89 }
86 90
87 } // namespace media 91 } // namespace media
OLDNEW
« no previous file with comments | « media/audio/fake_audio_manager.h ('k') | media/audio/mac/audio_auhal_mac.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698