| OLD | NEW |
| 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 #ifndef MEDIA_AUDIO_AUDIO_MANAGER_BASE_H_ | 5 #ifndef MEDIA_AUDIO_AUDIO_MANAGER_BASE_H_ |
| 6 #define MEDIA_AUDIO_AUDIO_MANAGER_BASE_H_ | 6 #define MEDIA_AUDIO_AUDIO_MANAGER_BASE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 virtual AudioParameters GetDefaultOutputStreamParameters() OVERRIDE; | 108 virtual AudioParameters GetDefaultOutputStreamParameters() OVERRIDE; |
| 109 virtual AudioParameters GetOutputStreamParameters( | 109 virtual AudioParameters GetOutputStreamParameters( |
| 110 const std::string& device_id) OVERRIDE; | 110 const std::string& device_id) OVERRIDE; |
| 111 | 111 |
| 112 virtual AudioParameters GetInputStreamParameters( | 112 virtual AudioParameters GetInputStreamParameters( |
| 113 const std::string& device_id) OVERRIDE; | 113 const std::string& device_id) OVERRIDE; |
| 114 | 114 |
| 115 virtual std::string GetAssociatedOutputDeviceID( | 115 virtual std::string GetAssociatedOutputDeviceID( |
| 116 const std::string& input_device_id) OVERRIDE; | 116 const std::string& input_device_id) OVERRIDE; |
| 117 | 117 |
| 118 virtual void FixWedgedAudio() OVERRIDE; | |
| 119 | |
| 120 protected: | 118 protected: |
| 121 AudioManagerBase(); | 119 AudioManagerBase(); |
| 122 | 120 |
| 123 // Shuts down the audio thread and releases all the audio output dispatchers | 121 // Shuts down the audio thread and releases all the audio output dispatchers |
| 124 // on the audio thread. All audio streams should be freed before Shutdown() | 122 // on the audio thread. All audio streams should be freed before Shutdown() |
| 125 // is called. This must be called in the destructor of every AudioManagerBase | 123 // is called. This must be called in the destructor of every AudioManagerBase |
| 126 // implementation. | 124 // implementation. |
| 127 void Shutdown(); | 125 void Shutdown(); |
| 128 | 126 |
| 129 void SetMaxOutputStreamsAllowed(int max) { max_num_output_streams_ = max; } | 127 void SetMaxOutputStreamsAllowed(int max) { max_num_output_streams_ = max; } |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 192 // Map of cached AudioOutputDispatcher instances. Must only be touched | 190 // Map of cached AudioOutputDispatcher instances. Must only be touched |
| 193 // from the audio thread (no locking). | 191 // from the audio thread (no locking). |
| 194 AudioOutputDispatchers output_dispatchers_; | 192 AudioOutputDispatchers output_dispatchers_; |
| 195 | 193 |
| 196 DISALLOW_COPY_AND_ASSIGN(AudioManagerBase); | 194 DISALLOW_COPY_AND_ASSIGN(AudioManagerBase); |
| 197 }; | 195 }; |
| 198 | 196 |
| 199 } // namespace media | 197 } // namespace media |
| 200 | 198 |
| 201 #endif // MEDIA_AUDIO_AUDIO_MANAGER_BASE_H_ | 199 #endif // MEDIA_AUDIO_AUDIO_MANAGER_BASE_H_ |
| OLD | NEW |