Can you please tell me if there is any library/API to detect if user draw a rectangle on screen using gesture?
Thank you.
Use android.gesture.Gesture to store a gesture. And android.gesture.GestureOverlayView to detect if user draw needed gesture.
Here is a good tutorial
Related
I am creating an app where a shape (circle, square, triangle...) pops up on the screen. The user then has to trace the shape shown on the screen in order to move on. The only documentation I have found is on simple gestures, but nothing on complex shape drawing gesture. Is anyone aware of any android constructs that achieve this? Any help is very appreciated!
so far I have looked into android canvas and the ability for the user to draw shapes. However, I cannot find a method that will match the drawn shape to a pattern. I also looked into gesture detection, but found that it was only used to detect basic gestures such as swipes
-Kelton
Try reading this Tracking Movement. It should work when you store data from movement and then compare it to your actual object
Is it possible to let the buttons move freely? like dragging it and moving it around with your finger or accelerometer.
Thank you very much for any advice you are willing to give me
http://developer.android.com/guide/topics/ui/drag-drop.html
Is this what you are looking for?
I am developing one application with drawing and all, One problem I am facing is I want single touch scaling image. I have done image scaling with multi touch but I am so stuck with single touch.
Example :-
I have one Rectangle on canvas. Now I want to scale and rotate that Rectangle with its one corner with one finger. I am finding this on google but not get perfect materiel or demo and else.
Please help me to find this.
For zooming with single touch this will help you
http://developer.sonymobile.com/wp/2010/05/18/android-one-finger-zoom-tutorial-part-1/
I need to move the position of the image with the direction of finger in the easiest way possible.I found out the direction of the finger touch but I don't know how to move the image in the direction of finger.thanks in advance.
This tutorial will be helpful to you:
http://www.zdnet.com/blog/burnette/how-to-use-multi-touch-in-android-2-part-5-implementing-the-drag-gesture/1789?tag=content;siu-container
I want to make android-screen as white-board so that by touch on screen I able to draw something on screen.
I know I have to use canvas, Path all these things. But how I can make that screen so that i able to draw a dot there?
For that what should i do with my activity?
How can I do that plz give me some sample code.
Thank you
So maybe you should take a look to this example:
http://developer.android.com/resources/samples/ApiDemos/src/com/example/android/apis/graphics/TouchPaint.html