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 CHROME_BROWSER_SPEECH_TTS_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_SPEECH_TTS_CONTROLLER_H_ |
6 #define CHROME_BROWSER_SPEECH_TTS_CONTROLLER_H_ | 6 #define CHROME_BROWSER_SPEECH_TTS_CONTROLLER_H_ |
7 | 7 |
8 #include <queue> | 8 #include <queue> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
59 struct VoiceData { | 59 struct VoiceData { |
60 VoiceData(); | 60 VoiceData(); |
61 ~VoiceData(); | 61 ~VoiceData(); |
62 | 62 |
63 std::string name; | 63 std::string name; |
64 std::string lang; | 64 std::string lang; |
65 TtsGenderType gender; | 65 TtsGenderType gender; |
66 std::string extension_id; | 66 std::string extension_id; |
67 std::set<TtsEventType> events; | 67 std::set<TtsEventType> events; |
68 | 68 |
| 69 // If true, the synthesis engine is a remote network resource. |
| 70 // It may be higher latency and may incur bandwidth costs. |
| 71 bool remote; |
| 72 |
69 // If true, this is implemented by this platform's subclass of | 73 // If true, this is implemented by this platform's subclass of |
70 // TtsPlatformImpl. If false, this is implemented by an extension. | 74 // TtsPlatformImpl. If false, this is implemented by an extension. |
71 bool native; | 75 bool native; |
72 std::string native_voice_identifier; | 76 std::string native_voice_identifier; |
73 }; | 77 }; |
74 | 78 |
75 // Class that wants to receive events on utterances. | 79 // Class that wants to receive events on utterances. |
76 class UtteranceEventDelegate { | 80 class UtteranceEventDelegate { |
77 public: | 81 public: |
78 virtual ~UtteranceEventDelegate() {} | 82 virtual ~UtteranceEventDelegate() {} |
(...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
337 std::set<VoicesChangedDelegate*> voices_changed_delegates_; | 341 std::set<VoicesChangedDelegate*> voices_changed_delegates_; |
338 | 342 |
339 // A pointer to the platform implementation of text-to-speech, for | 343 // A pointer to the platform implementation of text-to-speech, for |
340 // dependency injection. | 344 // dependency injection. |
341 TtsPlatformImpl* platform_impl_; | 345 TtsPlatformImpl* platform_impl_; |
342 | 346 |
343 DISALLOW_COPY_AND_ASSIGN(TtsController); | 347 DISALLOW_COPY_AND_ASSIGN(TtsController); |
344 }; | 348 }; |
345 | 349 |
346 #endif // CHROME_BROWSER_SPEECH_TTS_CONTROLLER_H_ | 350 #endif // CHROME_BROWSER_SPEECH_TTS_CONTROLLER_H_ |
OLD | NEW |