B4A Library Google Glass Library

GlassB4a2.jpg


This library was made exclusively for the development of Google Glass.

She uses the template library available from Google that is GDK.JAR (The Glass Development Kit)

More detailed explanations are available on:
https://developers.google.com/glass/develop/overview


This first version is in correctly intercept touches on "TOUCH PAD" Google Glass, which can be:

public static final Gesture LONG_PRESS
public static final Gesture SWIPE_DOWN
public static final Gesture SWIPE_LEFT
public static final Gesture SWIPE_RIGHT
public static final Gesture SWIPE_UP
public static final Gesture TAP
public static final Gesture THREE_LONG_PRESS
public static final Gesture THREE_TAP
public static final Gesture TWO_LONG_PRESS
public static final Gesture TWO_SWIPE_DOWN
public static final Gesture TWO_SWIPE_LEFT
public static final Gesture TWO_SWIPE_RIGHT
public static final Gesture TWO_SWIPE_UP
public static final Gesture TWO_TAP

More detailed explanations are available on:
https://developers.google.com/glass.../android/glass/touchpad/GestureDetector?hl=es


Installation instructions:
- Copy the .xml and .jar files to your custom libraries folder
- Copy the res directory to your projects "Objects" folder
- Make all files copied to the Objects/res folder read only

- Extend your activity with glasslib class, putting this line in your Activity Attributes


#Region Activity Attributes
#Extends: com.visualnet.googleglass.glassActivity
#End Region




Version history:
V1.01:
- initial version with GestureDetector and the various types of Gesture

V1.02:
- included the original sounds and method to play sounds in your glass

GlassLib12.jpg



IMPORTANT: Whit this library, the Activity_Keypress in intercepted by Library, then you can control by gesture of Google Glass. Look the Example in B4A.

Have fun with it


Special Thanks to Nelson Pires (vpires)
 

Attachments

  • GoogleGlassTest.zip
    511.7 KB · Views: 236
  • GoogleGlassLib11.zip
    48.2 KB · Views: 171
  • GoogleGlassLib12.zip
    38.3 KB · Views: 215
Last edited:

Alberto Iglesias

Well-Known Member
Licensed User
Longtime User
lonleystar, I try tu put again your coverflow with a google glass, some questions:

* Can I change the "title" of image after add a image?
* Can I put an information more in one image? like description or ID? I think like addimage(...,...,"some text")
* In "select" property doing with a button to move through images, the movements can be more smooth? (like you do with your finger)?

Thank you

Alberto
 

ykucuk

Well-Known Member
Licensed User
Longtime User
Hello,

i am going to buy google glass.

there is v1,2 and finally 3

what is difference between them for developing app.

thank you
 

fbritop

Active Member
Licensed User
Longtime User
GlassB4a2.jpg


This library was made exclusively for the development of Google Glass.

She uses the template library available from Google that is GDK.JAR (The Glass Development Kit)

More detailed explanations are available on:
https://developers.google.com/glass/develop/overview


This first version is in correctly intercept touches on "TOUCH PAD" Google Glass, which can be:

public static final Gesture LONG_PRESS
public static final Gesture SWIPE_DOWN
public static final Gesture SWIPE_LEFT
public static final Gesture SWIPE_RIGHT
public static final Gesture SWIPE_UP
public static final Gesture TAP
public static final Gesture THREE_LONG_PRESS
public static final Gesture THREE_TAP
public static final Gesture TWO_LONG_PRESS
public static final Gesture TWO_SWIPE_DOWN
public static final Gesture TWO_SWIPE_LEFT
public static final Gesture TWO_SWIPE_RIGHT
public static final Gesture TWO_SWIPE_UP
public static final Gesture TWO_TAP

More detailed explanations are available on:
https://developers.google.com/glass.../android/glass/touchpad/GestureDetector?hl=es


Installation instructions:
- Copy the .xml and .jar files to your custom libraries folder
- Copy the res directory to your projects "Objects" folder
- Make all files copied to the Objects/res folder read only

- Extend your activity with glasslib class, putting this line in your Activity Attributes


#Region Activity Attributes
#Extends: com.visualnet.googleglass.glassActivity
#End Region




Version history:
V1.01:
- initial version with GestureDetector and the various types of Gesture

V1.02:
- included the original sounds and method to play sounds in your glass

GlassLib12.jpg



IMPORTANT: Whit this library, the Activity_Keypress in intercepted by Library, then you can control by gesture of Google Glass. Look the Example in B4A.

Have fun with it


Special Thanks to Nelson Pires (vpires)

Alberto
This looks like a great library. I have not yet put my hands over a google glass kit. I'm am, appart from developer, a fanatic of sailplane gilding in Santiago, Chile (Andes Mountains). One of the things I always try to do is put more technology over the gliders, where your eyes and focus has to be on outside conditions rather than monitoring your instruments (vario, speed, altitude, attitude, location, etc).

I for a long time have been searching for HUD devices (Head Up Displays) and it occur to me that google glass can be an excelent instrument to accomplish this.

A few questions I need to answer before proceeding with a proyect like this. Is google glass the only type of device than can be easilly connected to an android OS?. I now there is VR occulus devices, but of course I cannot be flying blind. How does the display connects to the android or the google glass operates in its own OS independantly? What interfaces do I have available to connect google glass to external information sources, for example I know that the Oudie Naviter flight computer transmits over a serial interface and bluetooth to share it's data. LX Nav flight computer transmits over serial RS 232 port, etc. How google glass can aquire information or capture data throught an external devices that acts like a proxy for sharing this information.

Any help would be more help to me in order to decide if a google glass device would be an option for designing a HUD internally in a glass.

Thanks in advance.
Felipe Brito
 

Alberto Iglesias

Well-Known Member
Licensed User
Longtime User
Hola Felipe, I´m brazilian/spanish....

Actualmente yo veo las Google Glass extremamente facil de programas y coger los datos que necesita, con la programacion B4A y mi libreria queda muy facil para eso.

Las GG és como se fuera un android normal y la pantalla és como si fuera a de uno movil, tal cual, pero mas pequeña.
El touch de la patilla de las gafas és lo que complica, por eso hice la libreria, que queda todo facil.

Puedes trabajar con ella de forma independiente si no utiliza ninguna conexion 3G, pues tiene Wifi incorporada, pero si quieres crear una app sin tener conexion , puedes guardar los datos internamente y después automaticamente subirlas a tu servidor o conectar por 3g/wifi.

En las GG ademas de estas conexiones, puedes hacer por Bluetooth o por USB, tal cual un android normal.

Una de mis aplicaciones cogia datos de una instituicion bancaria y ponia en la pantalla, hacia un simples HTTP GET, me retornava un JSON y lo parseaba en la pantalla. Recuerdo que la pantalla és pequeña por lo tanto no puedes tener muchissima informacion, por eso se hizo los "cards" de las glasses, para ir pasando el dedo y ir mirandotodo que desea.

Me lo compré las glasses en 2014, hice 3 apps que me rendieron 3 veces el valor de las glasses y luego que supe de la informacion que iban a descontinuarlas, las vendi, casi por lo mismo precio que las compré.

PERO, estan saliendo las Google Glass v2 y me las compraré sin duda. és un excelente gadget, además de muy util personalmente, puede ser rentable comercialmente haciendo apps.

Espero tener te ayudado con las informaciones, si necesitas mas, estaré por aqui para te ayudar

Un saludo

Alberto Iglesias
 

fbritop

Active Member
Licensed User
Longtime User
Thanks Alberto,
I will keep this post in English as it may help other users. I will try to aquire a device in order to test this kinds of apps. do you have any real videos where you can see what portion of the glass keeps an area occupied. Flying without total focus on the outside conditions is quite dangerous.

Thanks for all the info
Felipe Brito
 

potman100

Active Member
Licensed User
Longtime User
Hi Alberto

Firstly thanks for the Library for Glass, it will make developing app a lot easier.

Just wanted to ask a question about the glass camera, I want to look at developing a barcode scanning system
using Glass, so basically the Camera on the Glass would find and scan the barcode on an item I put in front of
it, do you think this would be possible with B4A ?

Regards

Potman100
 

potman100

Active Member
Licensed User
Longtime User
Thanks for the reply Alberto, I will have a look at your library store.

I need to get hold of a Glass, but just wanted to know if in theory what I want to do is possible.

Don't want to spend quite a lot of money if I won't be able to get this working.

Thanks

Darren
 
Top