语音识别服务的Andr​​oid [英] Speech Recognition Service in Android

查看:105
本文介绍了语音识别服务的Andr​​oid的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个使用语音识别在活动Android应用程序。图形用户界面没有做任何事情,除了包含语音识别对象。我想这个端口转移到服务,这样我就可以跟我们​​的应用程序,同时它在后台运行。

I have an Android application that uses speech recognition in an Activity. The GUI doesn't do anything except for contain the speech recognition objects. I would like to port this over to a service so I can talk to the application while it's running in the background.

不过,据我所知,语音识别服务必须使用onActivityResult,这对于服务不可用。有没有办法要么包含一个服务的活动,例如不显示它的图形用户界面,或在服务执行活动的语音识别呢?

However, as far as I know, the speech recognition service has to use onActivityResult, which is unavailable for Services. Is there a way to either contain an Activity in a Service such that its GUI is not displayed, or perform speech recognition in a service instead of an activity?

推荐答案

请参阅<一href="http://stackoverflow.com/questions/4055830/googles-voice-search-speech-recognition-service">Google's语音搜索语音识别服务 - 它可能有一些有用的信息的链接。我不认为你可以做非GUI语音识别,因为识别器只露出了识别意图。

See Google's voice search speech recognition service - it might have some useful links to information. I don't think you can do non-Gui voice recognition because the recognizer is only exposed as the recognizer intent.

我不认为谷歌希望人们能够直接调用这个服务,它可能违背了服务条款的一些地方,如果你这样做,但检查出的 http://mikepultz.com/2011/03/accessing-google-speech-api-chrome-11/ 看Chrome浏览器背后的语音识别我怀疑该服务类似于Android的。

I don't think that Google wants people to call this service directly, and it likely violates some terms of service somewhere if you do, but check out http://mikepultz.com/2011/03/accessing-google-speech-api-chrome-11/ to see the service behind Chrome speech recognition which I suspect is similar to Android.

这篇关于语音识别服务的Andr​​oid的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆