Fit Images in MKMapview - iphone

I am using MKMapView , i want in my map the background image will display instead of map
i have some local images and i want that images will be shown instead of original map on
MKMapView
any help please?

You should be using CATiledLayer and a UIScrollView if you want to roll your own solution and need something pretty simple, or use https://github.com/route-me/route-me a native open source map library that enables you to use custom map tiles.

Related

Custom Map View

Here is the scenario...
I have a image of a map in jpeg format... I want to add it to my iPhone application and mark the coordinates in certain places (just like annotation in map kit ) and also when i move from one place to another place the current location should change and the new location should be marked in the image.
Is that possible ? How to achieve this instead of using the mkmapview ?
I found this tutorial how to add custom google maps, maybe you could use your image (.jpeg) as a overlay.
stiern.com/tutorials/adding-custom-google-maps-to-your-website
Sounds like you want to use an MKOverlay.
Essentially it boils down to looking at the TileMap sample code from WWDC 2010. It'll still load the Google Map in the background and your map over the top

Drawing route/lines on a custom map image (iphone)

I have a custom map image of an area.. There are about 9 regions and the number of distinct lines needed is only 11 (based on all possible routes).
What is the best way to draw a route on the map?
The brute force/hacky way is to create static images of every route possible- insane as it amounts to over a million images. Another way is to have layered images with the lines as images on top of the map (is this possible? Would zooming mess it up?)... Any other suggestions to tackle this? I could programmatically draw lines on top of the map but would it be responsive to zooming and such?
Note: The map image is a vectored image (svg) and does not contain GPS coordinates
Thank you!
You'll probably want to check out coreGraphics, it's perfectly suited for this task. Zooming and all.

Custom Map iPhone

I trying to figure out how to create a Custom Map like the following:
http://itunes.apple.com/us/app/mall-book-california/id342584415?mt=8
http://www.macworld.com/appguide/app.html?id=541350&expand=false
I just don't know where to start from, do I use UIWebView or MapKit?
Any help will be appreciated.
Thanks
What we did in our app is use a UIImageView on a UIScrollView. You need to take a screenshot of the object you will map on the google-map and precisely draw your overlay over it. Also you need to take the top left coordinate and bottom right coordinate of the screenshot you took from the map. Then put the overlay image inside an imageview, image view on scrollview, and scale your coordinate system on the scrollview with the coordinates you took from the map. Now you can precisely plot POI-s on your overlay. A note: The first thing we did is we overlaid the g-map with custom image view but it was really slow when scrolled, so don't even try it. Good luck with coding.
[EDIT] you take a large screenshot of an area on google map like this
http://www.metacafe.com/watch/1073912/google_maps_hack_how_to_save_large_maps/

iPhone - Add annotation to My own Map

I have an image plan of stores of exhibitors hall. So I need to add annotation to each store in the plan, which is a jpg file.
iPhone MapKit looks like supports only world map. Are there any way I can add my own picture and add annotation to it like google map annotation.
Thanks
I don't think you can do that.
What you can do is using a UIScrollView to scroll and zoom in/out your jpg plan and use subviews to simulate annotations. That's what I would do.
MapKit does not support custom tiles, so your only option is to implement your own map using UIScrollView (and potentially CATiledLayer if the map is large / has many zoom levels).

draw circle on MKMapview in iphone app

I am trying to draw circles around the current location on MKMapview.I tryied many codes but however no success. can any one suggest any links which should I refer. I am new to Iphone so dont have much knowledge about Quartz 2D.
I would think the simplest method to achieve your goal would be to use a custom PNG image with transparency and set the image property of a MKAnnotationView that you add to your current MKMapView.