开发者

Android C++ Gesture Code

Is it possible to get gesture code to work with Android and C++? If so, 开发者_StackOverflow社区how can it be done?


The easiest way by far would be to pass the information from your MotionEvent and/or GestureDetector to your native code via the JNI. Exactly how you do this is up to you, but the basic principle is no different than that of any other communication between native and Java code.

If you are asking if you can acquire MotionEvents without going via the JNI, if it's even possible, it's far more hassle than it's worth. You could (and probably should) use a tool like SWIG to avoid the pain of writing JNI wrapper code manually.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜