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 <memory> |
8 #include <string> | 9 #include <string> |
9 #include <utility> | 10 #include <utility> |
10 | 11 |
11 #include "base/compiler_specific.h" | 12 #include "base/compiler_specific.h" |
12 #include "base/macros.h" | 13 #include "base/macros.h" |
13 #include "base/memory/scoped_ptr.h" | |
14 #include "base/memory/scoped_vector.h" | 14 #include "base/memory/scoped_vector.h" |
15 #include "base/observer_list.h" | 15 #include "base/observer_list.h" |
16 #include "base/threading/thread.h" | 16 #include "base/threading/thread.h" |
17 #include "build/build_config.h" | 17 #include "build/build_config.h" |
18 #include "media/audio/audio_manager.h" | 18 #include "media/audio/audio_manager.h" |
19 | |
20 #include "media/audio/audio_output_dispatcher.h" | 19 #include "media/audio/audio_output_dispatcher.h" |
21 | 20 |
22 #if defined(OS_WIN) | 21 #if defined(OS_WIN) |
23 #include "base/win/scoped_com_initializer.h" | 22 #include "base/win/scoped_com_initializer.h" |
24 #endif | 23 #endif |
25 | 24 |
26 namespace media { | 25 namespace media { |
27 | 26 |
28 class AudioOutputDispatcher; | 27 class AudioOutputDispatcher; |
29 | 28 |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
80 void AddOutputDeviceChangeListener(AudioDeviceListener* listener) override; | 79 void AddOutputDeviceChangeListener(AudioDeviceListener* listener) override; |
81 void RemoveOutputDeviceChangeListener(AudioDeviceListener* listener) override; | 80 void RemoveOutputDeviceChangeListener(AudioDeviceListener* listener) override; |
82 | 81 |
83 AudioParameters GetDefaultOutputStreamParameters() override; | 82 AudioParameters GetDefaultOutputStreamParameters() override; |
84 AudioParameters GetOutputStreamParameters( | 83 AudioParameters GetOutputStreamParameters( |
85 const std::string& device_id) override; | 84 const std::string& device_id) override; |
86 AudioParameters GetInputStreamParameters( | 85 AudioParameters GetInputStreamParameters( |
87 const std::string& device_id) override; | 86 const std::string& device_id) override; |
88 std::string GetAssociatedOutputDeviceID( | 87 std::string GetAssociatedOutputDeviceID( |
89 const std::string& input_device_id) override; | 88 const std::string& input_device_id) override; |
90 scoped_ptr<AudioLog> CreateAudioLog( | 89 std::unique_ptr<AudioLog> CreateAudioLog( |
91 AudioLogFactory::AudioComponent component) override; | 90 AudioLogFactory::AudioComponent component) override; |
92 | 91 |
93 // AudioManagerBase: | 92 // AudioManagerBase: |
94 | 93 |
95 // Called internally by the audio stream when it has been closed. | 94 // Called internally by the audio stream when it has been closed. |
96 virtual void ReleaseOutputStream(AudioOutputStream* stream); | 95 virtual void ReleaseOutputStream(AudioOutputStream* stream); |
97 virtual void ReleaseInputStream(AudioInputStream* stream); | 96 virtual void ReleaseInputStream(AudioInputStream* stream); |
98 | 97 |
99 // Creates the output stream for the |AUDIO_PCM_LINEAR| format. The legacy | 98 // Creates the output stream for the |AUDIO_PCM_LINEAR| format. The legacy |
100 // name is also from |AUDIO_PCM_LINEAR|. | 99 // name is also from |AUDIO_PCM_LINEAR|. |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
185 | 184 |
186 // Proxy for creating AudioLog objects. | 185 // Proxy for creating AudioLog objects. |
187 AudioLogFactory* const audio_log_factory_; | 186 AudioLogFactory* const audio_log_factory_; |
188 | 187 |
189 DISALLOW_COPY_AND_ASSIGN(AudioManagerBase); | 188 DISALLOW_COPY_AND_ASSIGN(AudioManagerBase); |
190 }; | 189 }; |
191 | 190 |
192 } // namespace media | 191 } // namespace media |
193 | 192 |
194 #endif // MEDIA_AUDIO_AUDIO_MANAGER_BASE_H_ | 193 #endif // MEDIA_AUDIO_AUDIO_MANAGER_BASE_H_ |
OLD | NEW |