Glass development 101
All example sources are in Github:
Example 00: Hello, World
https://github.com/j796160836/GlassWorkshop-Exercise00_HelloWorld
Example 01: New Hello, World
https://github.com/j796160836/GlassWorkshop-Exercise01_NewHelloWorld
Example 02: MyVoiceCommand
https://github.com/j796160836/GlassWorkshop-Exercise02_MyVoiceCommand
Example 03: UseCardBuilder
https://github.com/j796160836/GlassWorkshop-Exercise03_CardBuilder
25. VoiceTriggers.Command
• add an event
• calculate
• call me a car
• capture a panorama
• check me in
• check this out
• control my car
• control my home
• explore nearby
• explore the stars
• find a bike
• find a dentist
• find a doctor
• find a hospital
• find a passage
• find a place
• find a place to stay
• find a product
• find a recipe
• find a video
• find a website
• find reviews
• find the exchange rate
• find the price
• flip a coin
• give me feedback
• help me sign in
• keep me awake
• learn an instrument
• learn a song
https://developers.google.com/glass/develop/gdk/reference/com/google/android/glass/app/VoiceTriggers.Command
52. View view1 = new CardBuilder(context, CardBuilder.Layout.TEXT)
.setText("This is the TEXT layout.
The text size will adjust dynamically.")
.setFootnote("This is the footnote")
.setTimestamp("just now")
.getView();
CardBuilder
53. View view2 = new CardBuilder(context, CardBuilder.Layout.COLUMNS)
.setText("You can even put a centered icon on a COLUMNS card
instead of a mosaic.")
.setFootnote("This is the footnote")
.setTimestamp("just now")
.setIcon(R.drawable.ic_wifi)
.getView();
CardBuilder
54. public class MainActivity extends Activity {
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
View view1 = new CardBuilder(this, CardBuilder.Layout.TEXT)
.setText("This is the TEXT layout.")
.setFootnote("footnote")
.setTimestamp("just now")
.getView();
setContentView(view1);
}
}
MainActivity.java
62. Where To Go From Here?
• Check the development guide
https://developers.google.com/glass/develop/gdk/index
• Touch Gestures
• Card Scroller
• Slider
• Live Cards