Чтобы получить снимок вида:
-(UIImage *)pictureForView:(UIView*)view
{
UIGraphicsBeginImageContext(view.frame.size);
CGContextRef ctx = UIGraphicsGetCurrentContext();
[view.layer renderInContext:ctx];
UIImage *image = UIGraphicsGetImageFromCurrentImageContext();
UIGraphicsEndImageContext();
return image;
}
Это для всего взгляда - вам нужно вырезать из него нужный вам кусок. Или, может быть, просто отцентрируйте вид карты на нужном вам месте и сделайте максимальное увеличение. Тогда изображение всего вида, когда его размер уменьшен до размера миниатюры, может быть достаточно хорошим.
Чтобы обрезать изображение карты в нужном месте:
UIImage* mapImage = [self pictureForView:self.mapView];
MKCoordinateRegion mapRegion = self.mapView.region;
//pointOfInterest is assumed to be on the map view, e.g. get the coordinate of the pin
CLLocationCoordinate2D pointOfInterest = ????;
double mapLatFrom = mapRegion.center.latitude - mapRegion.span.latitudeDelta/2;
double mapLonFrom = mapRegion.center.longitude - mapRegion.span.longitudeDelta/2;
double cropX = ((pointOfInterest.latitude - mapLatFrom)/mapRegion.span.latitudeDelta)*mapView.frame.size.width - self.imageView.frame.size.width /2;
double cropY = ((pointOfInterest.longitude - mapLonFrom)/mapRegion.span.longitudeDelta)*mapView.frame.size.height - self.imageView.frame.size.height /2;
CGRect cropRect = CGRectMake(cropX, cropY, self.imageView.frame.size.width, self.imageView.frame.size.height);
CGImageRef imageRef = CGImageCreateWithImageInRect([mapImage CGImage], cropRect);
self.imageView.image = [UIImage imageWithCGImage:imageRef];
CGImageRelease(imageRef);