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

Side by Side Diff: content/common/speech_recognition_messages.h

Issue 499233003: Binding media stream audio track to speech recognition [renderer] (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: SyncSocket leak and FIFO fixes. Test 8-192KHz for input. Created 6 years, 3 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
« no previous file with comments | « no previous file | content/content_renderer.gypi » ('j') | content/content_renderer.gypi » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 // Multiply-included message file, hence no include guard. 5 // Multiply-included message file, hence no include guard.
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/memory/shared_memory.h"
10 #include "base/process/process_handle.h"
burnik 2014/09/22 07:43:12 Include is deprecated. Removed in next patchset.
no longer working on chromium 2014/09/23 10:09:12 Acknowledged.
11 #include "base/sync_socket.h"
9 #include "content/public/common/speech_recognition_error.h" 12 #include "content/public/common/speech_recognition_error.h"
10 #include "content/public/common/speech_recognition_grammar.h" 13 #include "content/public/common/speech_recognition_grammar.h"
11 #include "content/public/common/speech_recognition_result.h" 14 #include "content/public/common/speech_recognition_result.h"
12 #include "ipc/ipc_message_macros.h" 15 #include "ipc/ipc_message_macros.h"
13 #include "ipc/ipc_param_traits.h" 16 #include "ipc/ipc_param_traits.h"
17 #include "media/audio/audio_parameters.h"
14 #include "ui/gfx/rect.h" 18 #include "ui/gfx/rect.h"
15 19
16 #define IPC_MESSAGE_START SpeechRecognitionMsgStart 20 #define IPC_MESSAGE_START SpeechRecognitionMsgStart
17 21
18 IPC_ENUM_TRAITS_MAX_VALUE(content::SpeechAudioErrorDetails, 22 IPC_ENUM_TRAITS_MAX_VALUE(content::SpeechAudioErrorDetails,
19 content::SPEECH_AUDIO_ERROR_DETAILS_LAST) 23 content::SPEECH_AUDIO_ERROR_DETAILS_LAST)
20 IPC_ENUM_TRAITS_MAX_VALUE(content::SpeechRecognitionErrorCode, 24 IPC_ENUM_TRAITS_MAX_VALUE(content::SpeechRecognitionErrorCode,
21 content::SPEECH_RECOGNITION_ERROR_LAST) 25 content::SPEECH_RECOGNITION_ERROR_LAST)
22 26
23 IPC_STRUCT_TRAITS_BEGIN(content::SpeechRecognitionError) 27 IPC_STRUCT_TRAITS_BEGIN(content::SpeechRecognitionError)
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 // Speech grammars to use. 59 // Speech grammars to use.
56 IPC_STRUCT_MEMBER(content::SpeechRecognitionGrammarArray, grammars) 60 IPC_STRUCT_MEMBER(content::SpeechRecognitionGrammarArray, grammars)
57 // URL of the page (or iframe if applicable). 61 // URL of the page (or iframe if applicable).
58 IPC_STRUCT_MEMBER(std::string, origin_url) 62 IPC_STRUCT_MEMBER(std::string, origin_url)
59 // Maximum number of hypotheses allowed for each results. 63 // Maximum number of hypotheses allowed for each results.
60 IPC_STRUCT_MEMBER(uint32, max_hypotheses) 64 IPC_STRUCT_MEMBER(uint32, max_hypotheses)
61 // Whether the user requested continuous recognition or not. 65 // Whether the user requested continuous recognition or not.
62 IPC_STRUCT_MEMBER(bool, continuous) 66 IPC_STRUCT_MEMBER(bool, continuous)
63 // Whether the user requested interim results or not. 67 // Whether the user requested interim results or not.
64 IPC_STRUCT_MEMBER(bool, interim_results) 68 IPC_STRUCT_MEMBER(bool, interim_results)
69 // Wheter user has set an audio track as input
70 IPC_STRUCT_MEMBER(bool, using_audio_track)
65 IPC_STRUCT_END() 71 IPC_STRUCT_END()
66 72
67 73
68 // Requests the speech recognition service to start speech recognition. 74 // Requests the speech recognition service to start speech recognition.
69 IPC_MESSAGE_CONTROL1(SpeechRecognitionHostMsg_StartRequest, 75 IPC_MESSAGE_CONTROL1(SpeechRecognitionHostMsg_StartRequest,
70 SpeechRecognitionHostMsg_StartRequest_Params) 76 SpeechRecognitionHostMsg_StartRequest_Params)
71 77
72 // Requests the speech recognition service to abort speech recognition on 78 // Requests the speech recognition service to abort speech recognition on
73 // behalf of the given |render_view_id| and |request_id|. If there are no 79 // behalf of the given |render_view_id| and |request_id|. If there are no
74 // sessions associated with the |request_id| in the render view, this call 80 // sessions associated with the |request_id| in the render view, this call
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
107 113
108 IPC_MESSAGE_ROUTED1(SpeechRecognitionMsg_AudioStarted, int /* request_id */) 114 IPC_MESSAGE_ROUTED1(SpeechRecognitionMsg_AudioStarted, int /* request_id */)
109 115
110 IPC_MESSAGE_ROUTED1(SpeechRecognitionMsg_SoundStarted, int /* request_id */) 116 IPC_MESSAGE_ROUTED1(SpeechRecognitionMsg_SoundStarted, int /* request_id */)
111 117
112 IPC_MESSAGE_ROUTED1(SpeechRecognitionMsg_SoundEnded, int /* request_id */) 118 IPC_MESSAGE_ROUTED1(SpeechRecognitionMsg_SoundEnded, int /* request_id */)
113 119
114 IPC_MESSAGE_ROUTED1(SpeechRecognitionMsg_AudioEnded, int /* request_id */) 120 IPC_MESSAGE_ROUTED1(SpeechRecognitionMsg_AudioEnded, int /* request_id */)
115 121
116 IPC_MESSAGE_ROUTED1(SpeechRecognitionMsg_Ended, int /* request_id */) 122 IPC_MESSAGE_ROUTED1(SpeechRecognitionMsg_Ended, int /* request_id */)
123
124 IPC_MESSAGE_ROUTED4(SpeechRecognitionMsg_AudioTrackReady,
125 int /* request_id */,
126 media::AudioParameters /* params */,
127 base::SharedMemoryHandle /* memory */,
128 base::SyncSocket::TransitDescriptor /* socket */)
OLDNEW
« no previous file with comments | « no previous file | content/content_renderer.gypi » ('j') | content/content_renderer.gypi » ('J')

Powered by Google App Engine
This is Rietveld 408576698