2

I want to check if user tapped on white or black portion of below image.

I can use UITapGestureRecognizer or hitTest:withEvent method to get touch position. But not sure if that position is in black or white portion.

enter image description here

I am actually looking for a generic solution that can be used on any other image. Like we could know if user clicked on Africa or UAE in below image.

enter image description here

Any help will be appreciated.

Khawar
  • 9,151
  • 9
  • 46
  • 67
  • 2
    Check this http://stackoverflow.com/questions/12770181/how-to-get-the-pixel-color-on-touch – kb920 Jan 29 '16 at 10:53

0 Answers0