Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6732561
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T10:39:55+00:00 2026-05-26T10:39:55+00:00

How can I make a preview icon like in the iPhone Map application? Screenshot

  • 0

How can I make a preview icon like in the iPhone Map application?

Screenshot http://img835.imageshack.us/img835/1619/img0016x.png

Is there a function for this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T10:39:56+00:00Added an answer on May 26, 2026 at 10:39 am

    In iOS 7 use MKMap​Snapshotter. From NSHipster:

    MKMapSnapshotOptions *options = [[MKMapSnapshotOptions alloc] init];
    options.region = self.mapView.region;
    options.size = self.mapView.frame.size;
    options.scale = [[UIScreen mainScreen] scale];
    
    NSURL *fileURL = [NSURL fileURLWithPath:@"path/to/snapshot.png"];
    
    MKMapSnapshotter *snapshotter = [[MKMapSnapshotter alloc] initWithOptions:options];
    [snapshotter startWithCompletionHandler:^(MKMapSnapshot *snapshot, NSError *error) {
        if (error) {
            NSLog(@"[Error] %@", error);
            return;
        }
    
        UIImage *image = snapshot.image;
        NSData *data = UIImagePNGRepresentation(image);
        [data writeToURL:fileURL atomically:YES];
    }];
    

    Before iOS7 do one of the following:

    • Add a live map and disable interaction.
    • Use the Google Static Maps API (explained below).
    • Create a MKMapView and render it to an image. I tried this (see previous edit) but couldn’t get the tiles to load. I tried calling needsLayout and other methods but didn’t work.

    Apple’s deal with Google is more reliable than a free API, but on the bright side, it is really simple. Documentation is at http://code.google.com/apis/maps/documentation/staticmaps/

    This is the minimum amount of parameters for practical use:
    http://maps.googleapis.com/maps/api/staticmap?center=40.416878,-3.703530&zoom=15&size=290×179&sensor=false

    A summary of the parameters:

    • center: this can be an address, or a latitude,longitude pair with up to 6 decimals (more than 6 are ignored).
    • format: png8 (default), png24, git, jpg, jpg-baseline.
    • language: Use any language. Default will be used if requested wasn’t available.
    • maptype: One of the following: roadmap, satellite, hybrid, terrain.
    • scale: 1,2,4. Use 2 to return twice the amount of pixels on retina displays. 4 is restricted to premium customers.
      Non paid resolution limits are 640×640 for 1 and 2.
    • sensor: true or false. Mandatory. It indicates if the user is being located using a device.
    • size: size in pixels.
    • zoom: 0 (whole planet) to 21.

    There is a few more to add polygons, custom markers, and style the map.

      NSData* data = [NSData dataWithContentsOfURL:@"http://maps.googleap..."];
      UIImage *img = [UIImage imageWithData:data];
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I asked How can I make the Preview Post button save and preview in
I can make a DAO recordset in VB6/Access do anything - add data, clean
I can make Firefox not display the ugly dotted focus outlines on links with
How can make a link within a facebox window that redirects it to another
I can make a single row IKImageBrowserView by setting the [imageBrowser setContentResizingMask:NSViewWidthSizable]; but in
Can someone tell me how I can make a table be 100% height in
Can someone tell me how I can make the following output? I have a
In C# you can make a block inside of a method that is not
so that you can make your program concurrent easily in the future.
I know that I can make a setter that checks to see if a

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.