简体   繁体   English

Google Glass:活动中的语音命令

[英]Google Glass: voice command in activity

I am trying to figure out how to make a voice command possible in an activity itself after the Glassware has already started. 我正在尝试弄清楚在Glassware启动之后如何在活动本身中实现语音命令。 For example, after you take a picture you can use the OK, Glass share with commands. 例如,在拍照后,您可以使用“ OK, Glass share with命令。

I want the voice commands to be possible in a certain activity after launching the Glassware. 我希望启动Glassware后在某些活动中可以使用语音命令。

I've checked the documentation on Google, but couldn't find one that relates to what I need. 我已经检查了Google上的文档,但是找不到与我需要的文档相关的文档。

Thank you. 谢谢。

This sounds like it would be covered by contextual voice commands. 听起来好像上下文语音命令会覆盖它。 This isn't supported yet, but you may want to follow issue 273 on our issue tracker so you can get updates as the GDK evolves. 目前尚不支持此功能,但是您可能希望在我们的问题跟踪器上关注问题273 ,以便随着GDK的发展获得更新。

With XE19 contextual voice command is available, you need to add this line : 使用XE19上下文语音命令时,您需要添加以下行:

getWindow().requestFeature(WindowUtils.FEATURE_VOICE_COMMANDS);

Then set up a menu to show. 然后设置一个菜单显示。

Here is the documentation from Google : https://developers.google.com/glass/develop/gdk/voice#contextual_voice_commands 这是Google提供的文档: https : //developers.google.com/glass/develop/gdk/voice#contextual_voice_commands

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM