EyeGestures NOT working in 19.1

对着背影说爱祢 提交于 2020-01-21 10:14:07

问题


I built an app to recognize EyeGestures using https://github.com/thorikawa/EyeGestureLib and it was working great in XE18.3 But after the 19.1 update, I'm getting an error that certain virtual methods were unable to resolve. However, these methods DO exist in my class EyeGestureManager. Is this due to the update? Is there something I can do to fix this for XE19.1 or do I have to wait until GDK officially supports eye gestures?

I/dalvikvm( 1829): Could not find method com.google.android.glass.eye.EyeGesture
Manager.stopDetector, referenced from method com.polysfactory.eyegesturedemo.Mai
nActivity.onStart
W/dalvikvm( 1829): VFY: unable to resolve virtual method 41: Lcom/google/android
/glass/eye/EyeGestureManager;.stopDetector (Lcom/google/android/glass/eye/EyeGes
ture;)Z
D/dalvikvm( 1829): VFY: replacing opcode 0x6e at 0x0008
I/dalvikvm( 1829): Could not find method com.google.android.glass.eye.EyeGesture
Manager.stopDetector, referenced from method com.polysfactory.eyegesturedemo.Mai
nActivity.onStop
W/dalvikvm( 1829): VFY: unable to resolve virtual method 41: Lcom/google/android
/glass/eye/EyeGestureManager;.stopDetector (Lcom/google/android/glass/eye/EyeGes
ture;)Z
D/dalvikvm( 1829): VFY: replacing opcode 0x6e at 0x0019
V/EyeGestureManager( 1829): Creating new EyeGestureManager for looper: Looper (m
ain, tid 1) {41a88990}
D/EyeGestureDemo( 1829): WINK:true
D/EyeGestureDemo( 1829): DOUBLE_WINK:false
D/EyeGestureDemo( 1829): BLINK:false
D/EyeGestureDemo( 1829): DOUBLE_BLINK:true
D/EyeGestureDemo( 1829): DON:true
D/EyeGestureDemo( 1829): DOFF:true
D/EyeGestureDemo( 1829): LOOK_AT_SCREEN:true
D/EyeGestureDemo( 1829): LOOK_AWAY_FROM_SCREEN:false
D/AndroidRuntime( 1829): Shutting down VM
W/dalvikvm( 1829): threadid=1: thread exiting with uncaught exception (group=0x4
1589bd8)
E/AndroidRuntime( 1829): FATAL EXCEPTION: main
E/AndroidRuntime( 1829): Process: com.polysfactory.eyegesturedemo, PID: 1829
E/AndroidRuntime( 1829): java.lang.NoSuchMethodError: com.google.android.glass.e
ye.EyeGestureManager.stopDetector
E/AndroidRuntime( 1829):        at com.polysfactory.eyegesturedemo.MainActivity.
onStart(MainActivity.java:59)
E/AndroidRuntime( 1829):        at android.app.Instrumentation.callActivityOnSta
rt(Instrumentation.java:1173)
E/AndroidRuntime( 1829):        at android.app.Activity.performStart(Activity.ja
va:5246)
E/AndroidRuntime( 1829):        at android.app.ActivityThread.performLaunchActiv
ity(ActivityThread.java:2208)
E/AndroidRuntime( 1829):        at android.app.ActivityThread.handleLaunchActivi
ty(ActivityThread.java:2285)
E/AndroidRuntime( 1829):        at android.app.ActivityThread.access$800(Activit
yThread.java:138)
E/AndroidRuntime( 1829):        at android.app.ActivityThread$H.handleMessage(Ac
tivityThread.java:1236)
E/AndroidRuntime( 1829):        at android.os.Handler.dispatchMessage(Handler.ja
va:102)
E/AndroidRuntime( 1829):        at android.os.Looper.loop(Looper.java:149)
E/AndroidRuntime( 1829):        at android.app.ActivityThread.main(ActivityThrea
d.java:5061)
E/AndroidRuntime( 1829):        at java.lang.reflect.Method.invokeNative(Native
Method)
E/AndroidRuntime( 1829):        at java.lang.reflect.Method.invoke(Method.java:5
15)
E/AndroidRuntime( 1829):        at com.android.internal.os.ZygoteInit$MethodAndA
rgsCaller.run(ZygoteInit.java:786)
E/AndroidRuntime( 1829):        at com.android.internal.os.ZygoteInit.main(Zygot
eInit.java:602)
E/AndroidRuntime( 1829):        at dalvik.system.NativeStart.main(Native Method)

回答1:


EyeGestureLib accesses 'hidden' APIs which seem to have changed as of XE19.1: https://github.com/thorikawa/EyeGestureLib/issues/2

Unfortunately, it looks like you'll either need to wait until the library is updated or an official wink gesture library is released.



来源:https://stackoverflow.com/questions/24876059/eyegestures-not-working-in-19-1

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!