MKMapView Image Markers

You must use your own well-formed tokens instead of the built-in contacts. I have a few questions. 1. Is it legal? I have a doubt, because there is no standard support for markers (contacts) with my own icon.

  1. How to make a marker with its own icon correctly? I found a post that actually describes how: http://www.arlingtondev.com/thoughts/?p=81 . I am new, but it looks like a β€œcrutch”, which I do not want to use in my clean code. Could you advise better? I had a lot of problems integrating this method and currenlty cannot move and animate icons, so I decided to ask stackoverflowers.
+4
source share
1 answer

Yes, you can. Check out the MKAnnotationView class specifically designed for this. In fact, MKPinAnnotationView inherits from it. Use the image field to specify an image.

+4
source

Source: https://habr.com/ru/post/1286637/


All Articles