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 #include "content/renderer/pepper/pepper_platform_audio_output.h" | 5 #include "content/renderer/pepper/pepper_platform_audio_output.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/location.h" | 8 #include "base/location.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "base/single_thread_task_runner.h" | 10 #include "base/single_thread_task_runner.h" |
11 #include "base/threading/thread_task_runner_handle.h" | 11 #include "base/threading/thread_task_runner_handle.h" |
12 #include "build/build_config.h" | 12 #include "build/build_config.h" |
13 #include "content/child/child_process.h" | 13 #include "content/child/child_process.h" |
14 #include "content/common/media/audio_messages.h" | 14 #include "content/common/media/audio_messages.h" |
15 #include "content/renderer/media/audio_message_filter.h" | 15 #include "content/renderer/media/audio_message_filter.h" |
16 #include "content/renderer/pepper/audio_helper.h" | 16 #include "content/renderer/pepper/audio_helper.h" |
17 #include "content/renderer/render_thread_impl.h" | 17 #include "content/renderer/render_thread_impl.h" |
18 #include "media/base/audio_hardware_config.h" | |
19 #include "ppapi/shared_impl/ppb_audio_config_shared.h" | 18 #include "ppapi/shared_impl/ppb_audio_config_shared.h" |
20 | 19 |
21 namespace content { | 20 namespace content { |
22 | 21 |
23 // static | 22 // static |
24 PepperPlatformAudioOutput* PepperPlatformAudioOutput::Create( | 23 PepperPlatformAudioOutput* PepperPlatformAudioOutput::Create( |
25 int sample_rate, | 24 int sample_rate, |
26 int frames_per_buffer, | 25 int frames_per_buffer, |
27 int source_render_frame_id, | 26 int source_render_frame_id, |
28 AudioHelper* client) { | 27 AudioHelper* client) { |
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
187 return; | 186 return; |
188 | 187 |
189 ipc_->CloseStream(); | 188 ipc_->CloseStream(); |
190 ipc_.reset(); | 189 ipc_.reset(); |
191 | 190 |
192 Release(); // Release for the delegate, balances out the reference taken in | 191 Release(); // Release for the delegate, balances out the reference taken in |
193 // PepperPlatformAudioOutput::Create. | 192 // PepperPlatformAudioOutput::Create. |
194 } | 193 } |
195 | 194 |
196 } // namespace content | 195 } // namespace content |
OLD | NEW |