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 // AudioInputRendererHost serves audio related requests from audio capturer | 5 // AudioInputRendererHost serves audio related requests from audio capturer |
6 // which lives inside the render process and provide access to audio hardware. | 6 // which lives inside the render process and provide access to audio hardware. |
7 // | 7 // |
8 // Create stream sequence (AudioInputController = AIC): | 8 // Create stream sequence (AudioInputController = AIC): |
9 // | 9 // |
10 // AudioInputHostMsg_CreateStream -> OnCreateStream -> AIC::CreateLowLatency -> | 10 // AudioInputHostMsg_CreateStream -> OnCreateStream -> AIC::CreateLowLatency -> |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 | 82 |
83 virtual ~AudioInputRendererHost(); | 83 virtual ~AudioInputRendererHost(); |
84 | 84 |
85 // Methods called on IO thread ---------------------------------------------- | 85 // Methods called on IO thread ---------------------------------------------- |
86 | 86 |
87 // Audio related IPC message handlers. | 87 // Audio related IPC message handlers. |
88 | 88 |
89 // Creates an audio input stream with the specified format whose data is | 89 // Creates an audio input stream with the specified format whose data is |
90 // consumed by an entity in the render view referenced by |render_view_id|. | 90 // consumed by an entity in the render view referenced by |render_view_id|. |
91 // |session_id| is used to find out which device to be used for the stream. | 91 // |session_id| is used to find out which device to be used for the stream. |
92 // When it is AudioInputDeviceManager::kFakeOpenSessionId, it uses the the | 92 // Upon success/failure, the peer is notified via the |
93 // default device. Upon success/failure, the peer is notified via the | |
94 // NotifyStreamCreated message. | 93 // NotifyStreamCreated message. |
95 void OnCreateStream(int stream_id, | 94 void OnCreateStream(int stream_id, |
96 int render_view_id, | 95 int render_view_id, |
97 int session_id, | 96 int session_id, |
98 const AudioInputHostMsg_CreateStream_Config& config); | 97 const AudioInputHostMsg_CreateStream_Config& config); |
99 | 98 |
100 // Record the audio input stream referenced by |stream_id|. | 99 // Record the audio input stream referenced by |stream_id|. |
101 void OnRecordStream(int stream_id); | 100 void OnRecordStream(int stream_id); |
102 | 101 |
103 // Close the audio stream referenced by |stream_id|. | 102 // Close the audio stream referenced by |stream_id|. |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
150 | 149 |
151 // A map of stream IDs to audio sources. | 150 // A map of stream IDs to audio sources. |
152 AudioEntryMap audio_entries_; | 151 AudioEntryMap audio_entries_; |
153 | 152 |
154 DISALLOW_COPY_AND_ASSIGN(AudioInputRendererHost); | 153 DISALLOW_COPY_AND_ASSIGN(AudioInputRendererHost); |
155 }; | 154 }; |
156 | 155 |
157 } // namespace content | 156 } // namespace content |
158 | 157 |
159 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_AUDIO_INPUT_RENDERER_HOST_H_ | 158 #endif // CONTENT_BROWSER_RENDERER_HOST_MEDIA_AUDIO_INPUT_RENDERER_HOST_H_ |
OLD | NEW |