Android How to detect area touch in image in one image - android

this example image for split area.
http://postimg.org/image/j35tjjk57/
i want to detect when user touch number in image.
how to programming.
thank you.

You need to define a Path for a region and then check whether your touch point is inside a path, how it is described there.

Related

Android ImageView ontouch

I want to implement body part selection in android. My requirement is, when I tap on specific part the image app should be able to identify the body part and color of the selected part should change.Attached a sample image for reference.
Any idea or suggestion at the earliest would be very much appreciated.
In your input, set x,y position each part of body.
Then you can calculate nearst part of touch x,y with simple code.
Or more complex, you can set rect.
In visual part, you can add another imageview overlay original image.
If your image is separated, you can use
imageView.setColorFilter()

Android - How to get raw touch screen data?

How to get an array/bitmap data from android touch screen?
(the shape and area of the touch).
Same question as this one Android: get raw bitmap data from touch events, but this is very old.
The data is processed in the kernel, is there any way I can get it?
It's not possible since your touchscreen only recognizes a few points. For example, try using any kind of a Paint app. You will see that your whole finger won't get noticed if you put it on the screen. Only a few dots will be painted.
Also notice that some phones don't support multi touches. I would recommend you to rethink about your app design. Maybe you could try let the user draw something to achieve a result you want.
Yes that's what I ment. Check cursor location.

Image Zoom, Pan and Sliced images

I have a image received from server. I have to provide Zoom and Pan functionality to it.
I also receive set of point of image, when clicked on these point of image i need to show a pop up.
Initially i thought of using default viewer for image but the pop up of click of specific point is out of question.
I cannot slice the image also
Point me to proper direction.
I think this library fulfills your requirements: https://github.com/chrisbanes/PhotoView

How to persist the gestures of the GestureOverLayView?

Suppose I am writing a word "abc" in my GestureOverlayView and while doing so I need to save all those alphabets in the screen until I press a clear button.Can anyone tell me a good way to do this..
I will write "a" which is taken as a gesture (not as stroke) i.e One thing I though of was like use a ImageView or SurfaceView on bottom of a GestureOverLayView.and Suppose when I draw "a" on GestureOverLayView then in the "onGesturePerformed" event it will take the Gesture and then get the strokes and then convert them into paths and then draw the paths onto the underlying ImageView or SurfaceView.Can anyone suggest me the code or guide me.I tried various combinations of them but couldn't solve it..
There's an app called GestureBuilder in the samples directory of the SDK. This app shows how to persist gestures drawn by the user.
I realize this is an old question, but you can "cheat" by increasing the fadeOffset to some ridiculously high number. This can be done either in the xml
android:fadeOffset = "some very large number"
whatever, or programatically,
yourgestureoverlayView.SetFadeOffset(some very large number in milliseconds)

android - how to move image when clicked?

I try to make an application which place a certain png file in the screen with coordinates, and when the user clicks it, the image will move to another location in the screen.
can you guys give the sample..?? I'm kinda confused on how to draw the image (using bitmap or button??) and how to move it ??
THX for the answer...
refer this
Image in Canvas with touch events

Categories

Resources