Tag: 地图

将离线地图embeddedIOS应用程序

如何将离线地图embeddediOS应用程序? 做苹果地图或谷歌地图提供这种能力? 我遇到过MapBox,但是不太清楚它是如何工作的,以及它是否提供了这种能力。

打开具有特定地址iOS 7的地图

我试图让我的应用程序打开苹果地图应用程序,并有地址被拉起来。 我试过这个: – (IBAction)openInMaps:(id)sender { NSString *addressString = @"http://maps.apple.com/?q=1 Infinite Loop, Cupertino, CA"; NSURL *url = [NSURL URLWithString:addressString]; [[UIApplication sharedApplication] openURL:url]; } 和这个 : – (IBAction)openInMaps:(id)sender { NSString *addressString = @"http://maps.apple.com/?q=1_Infinite_Loop,_Cupertino,_CA"; NSURL *url = [NSURL URLWithString:addressString]; [[UIApplication sharedApplication] openURL:url]; } 但button就像它挂钩到什么都没有。 但是这确实有效: – (IBAction)openInMaps:(id)sender { NSString *addressString = @"http://maps.apple.com/?q=Cupertino,CA"; NSURL *url = [NSURL URLWithString:addressString]; [[UIApplication […]

如何在iPhone应用程序中开发3D地图?

我正在开发一个增强现实应用程序,我需要为屏幕实现3D地图。 我知道我们可以使用MapKit框架在iPhone应用程序中开发2D地图。 但我无法find任何教程或博客如何在iPhone应用程序中实现3D地图。 任何帮助或教程这将是非常支持。

如何以编程方式select地图别针

我是Maps Concept的新手。 请一次find附件图像。 当我点击“别针”,我得到的消息说:“欣赏你的微笑”或任何文字…..现在我想要…当我们select表格视图时,我需要提出该消息针对这个引脚的用户交互)… 我使用下面的代码为这个地图和引脚。 -(void) viewWillAppear:(BOOL)animated { [super viewWillAppear:YES]; customLocation.latitude=[casesobjc.latitude_string doubleValue]; customLocation.longitude=[casesobjc.longitude_string doubleValue]; MapViewAnnotation *newAnnotation = [[MapViewAnnotation alloc] initWithTitle:casesobjc.locationForMap_string andCoordinate:customLocation]; [mapView addAnnotation:newAnnotation]; } – (MKAnnotationView *) mapView: (MKMapView *) mapView viewForAnnotation: (id<MKAnnotation>) annotation { MKPinAnnotationView *pin = (MKPinAnnotationView *) [mapView dequeueReusableAnnotationViewWithIdentifier: @"annotation_ID"]; if (pin == nil) { pin = [[MKPinAnnotationView alloc] initWithAnnotation: annotation reuseIdentifier: […]

确定点是否在边界框内

你如何确定给定的点是否在边界框内? 我的观点是48.847172,2.386597。 BoundingBox的: "48.7998602295", "48.8198640442", "2.46138595581", "2.48138619423"

如何使用Xcode 6(Swift)添加引脚(注释)

我对新语言很陌生,还没有用mapkit做过应用。 但我有地图和地区设置,但我挂在如何让用户添加引脚。 让我澄清,我甚至不知道从哪里开始,现在我所有的(针脚)是我的variables,但我甚至不确定这是否正确。 任何帮助将非常感激!! 我拥有的… var MyPins:MKPinAnnotatoinView! …… override func viewDidLoad() { super.viewDidLoad() Mapview代码 ….. …..}

在地图视图的可见矩形中显示MKMapViewAnnotations

我在path式视差表视图标题中显示MKMapView。 要创build效果,mapView边界大于用户可见的区域。 我需要设置地图视图区域,使得所有地图的注解都包含在MKMapView的可视区域中。 什么是最好的方法来做到这一点? 编辑清楚:这是一个用例。 mapView大小为320 x 380.然而,可见区域由rect(0.0,20.0,320.0,100.0)定义。 我需要设置区域,使得所有的注解都出现在mapView中的这个矩形中。

iOS打开地图应用程序的链接

我正在开发一个活动应用程序,我正在尝试添加一个“获取路线”button,在Apple地图或Google地图中打开路线。 我很高兴现在使用苹果地图,因为它很容易embeddedhttp://maps.apple.com/?q=XYZ() 。 我的应用程序正在显示带有UIWebView的HTML网站,所以这可能是问题所在,但是当您按下链接时,它实际上会在UIWebView打开并随机显示Google地图。 有一个函数可以放入我的HTML代码中,强制链接在本机Apple或Google Maps中打开?

CLGeocoder从给定的位置反向地理编码

给定经度和纬度不是我目前的位置我怎样才能使用GLGeocoder执行反向地理编码查找? self.geoCoder = [[CLGeocoder alloc] init]; self.locationManager = [[CLLocationManager alloc] init]; self.locationManager.delegate = self; // [self.locationManager startUpdatingLocation]; [self.geoCoder reverseGeocodeLocation: locationManager.location completionHandler: ^(NSArray *placemarks, NSError *error) { // [self.locationManager stopUpdatingLocation]; CLPlacemark *placemark = [placemarks objectAtIndex:0]; // Long address // NSString *locatedAt = [[placemark.addressDictionary valueForKey:@"FormattedAddressLines"] componentsJoinedByString:@", "]; // Short address NSString *locatedAt = [placemark subLocality]; cell.textLabel.text = […]

iOS:如何获得两个坐标之间的路线path

在我的项目中,我需要借助经度和纬度找出两个地点之间的path。 我正在使用下面的代码 – (void)viewDidLoad { [super viewDidLoad]; // Do any additional setup after loading the view, typically from a nib. [mapvw setDelegate:self]; [self mapp]; } -(void)mapp { CLLocationCoordinate2D coordinateArray[2]; coordinateArray[0] = CLLocationCoordinate2DMake(28.6129, 77.2295); coordinateArray[1] = CLLocationCoordinate2DMake(28.6562, 77.2410); self.routeLine = [MKPolyline polylineWithCoordinates:coordinateArray count:2]; [mapvw setVisibleMapRect:[self.routeLine boundingMapRect]]; //If you want the route to be visible [mapvw addOverlay:self.routeLine]; […]