0

I have created gestures for my app in Gestures Builder. How do I play those gestures on emulator/device in my app. I have included the gesture file in my Raw resource.. Thnx in advance

user163
  • 3
  • 1

1 Answers1

0

You have to load the gestures in your app from your resource and then write code to recognize it.

Follow this tutorial here https://androidresearch.wordpress.com/tag/gesture-builder/

Klitos G.
  • 806
  • 5
  • 14
  • thnx a lot..@Klitos. G.. Gesture recognition worked.. But how do I play a saved gesture on a screen in an app ? – user163 Feb 24 '15 at 05:18
  • When you say "play" you mean you want to draw your gesture on your screen animated? If you need this, then take a look on the second part of the answer here http://stackoverflow.com/questions/25553687/gesture-automatically-draws-itself – Klitos G. Feb 24 '15 at 09:51
  • thnx again @Klitos G. I want to ask my user to draw a particular gesture that I will first show to him on Screen 1. When the user draws a gesture, I want the Gesture API to compare 'user-drawn' gesture with only one gesture from the file vs. all gestures in file as it's happening right now. Step 1 : User is shown a gesture to be drawn(on Screen 2) on Screen 1. Step 2 : User is asked to draw the same gesture. Step 3 : Inputs from Step 2 to be compared with gesture (id). – user163 Feb 24 '15 at 10:35
  • I think you do not need any more code than the given, but as you now have the code and a scenario, please ask a new question on how to implement this scenario. Basically you need the steps you describe translated into views inside an Activity(or Fragment). – Klitos G. Feb 24 '15 at 15:53