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

Side by Side Diff: content/browser/speech/speech_recognizer_impl.h

Issue 2582533002: Simplify AudioInputRendererHost IPC interface. (Closed)
Patch Set: Rebase. Created 3 years, 11 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 #ifndef CONTENT_BROWSER_SPEECH_SPEECH_RECOGNIZER_IMPL_H_ 5 #ifndef CONTENT_BROWSER_SPEECH_SPEECH_RECOGNIZER_IMPL_H_
6 #define CONTENT_BROWSER_SPEECH_SPEECH_RECOGNIZER_IMPL_H_ 6 #define CONTENT_BROWSER_SPEECH_SPEECH_RECOGNIZER_IMPL_H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 // OnAudioLevelsChange event accordingly. 125 // OnAudioLevelsChange event accordingly.
126 void UpdateSignalAndNoiseLevels(const float& rms, bool clip_detected); 126 void UpdateSignalAndNoiseLevels(const float& rms, bool clip_detected);
127 127
128 void CloseAudioControllerAsynchronously(); 128 void CloseAudioControllerAsynchronously();
129 129
130 // Callback called on IO thread by audio_controller->Close(). 130 // Callback called on IO thread by audio_controller->Close().
131 void OnAudioClosed(media::AudioInputController*); 131 void OnAudioClosed(media::AudioInputController*);
132 132
133 // AudioInputController::EventHandler methods. 133 // AudioInputController::EventHandler methods.
134 void OnCreated(media::AudioInputController* controller) override {} 134 void OnCreated(media::AudioInputController* controller) override {}
135 void OnRecording(media::AudioInputController* controller) override {}
136 void OnError(media::AudioInputController* controller, 135 void OnError(media::AudioInputController* controller,
137 media::AudioInputController::ErrorCode error_code) override; 136 media::AudioInputController::ErrorCode error_code) override;
138 void OnData(media::AudioInputController* controller, 137 void OnData(media::AudioInputController* controller,
139 const media::AudioBus* data) override; 138 const media::AudioBus* data) override;
140 void OnLog(media::AudioInputController* controller, 139 void OnLog(media::AudioInputController* controller,
141 const std::string& message) override {} 140 const std::string& message) override {}
142 141
143 // SpeechRecognitionEngineDelegate methods. 142 // SpeechRecognitionEngineDelegate methods.
144 void OnSpeechRecognitionEngineResults( 143 void OnSpeechRecognitionEngineResults(
145 const SpeechRecognitionResults& results) override; 144 const SpeechRecognitionResults& results) override;
(...skipping 20 matching lines...) Expand all
166 // Converts data between native input format and a WebSpeech specific 165 // Converts data between native input format and a WebSpeech specific
167 // output format. 166 // output format.
168 std::unique_ptr<SpeechRecognizerImpl::OnDataConverter> audio_converter_; 167 std::unique_ptr<SpeechRecognizerImpl::OnDataConverter> audio_converter_;
169 168
170 DISALLOW_COPY_AND_ASSIGN(SpeechRecognizerImpl); 169 DISALLOW_COPY_AND_ASSIGN(SpeechRecognizerImpl);
171 }; 170 };
172 171
173 } // namespace content 172 } // namespace content
174 173
175 #endif // CONTENT_BROWSER_SPEECH_SPEECH_RECOGNIZER_IMPL_H_ 174 #endif // CONTENT_BROWSER_SPEECH_SPEECH_RECOGNIZER_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698