Google지도 SDK를 통합하려고 시도 중이고 this link to start from google을 팔로우하고 있습니다. API 키를 만들고 appDelegate
에 사용했습니다. 내 ViewController.m
코드 아래에 쓴 및 필요한 모든 프레임 워크를 가져온 또한 -ObjC
다른 링커 플래그를 넣어 있지만 여전히 응용 프로그램이 런타임에 충돌이 있습니다. 중단 점을 사용했지만 로그가 표시되지 않았습니다. 아래는 전체 코드이며 콘센트는 사용하지 않았습니다.앱이 오류없이 충돌합니다.
#import "ViewController.h"
@interface ViewController()
@end
@implementation ViewController
- (void)viewDidLoad {
GMSCameraPosition *camera = [GMSCameraPosition cameraWithLatitude:-33.86
longitude:151.20 zoom:6];
mapView_ = [GMSMapView mapWithFrame:CGRectZero camera:camera]; // crashing here, even gave different frames rather CGRectZero
mapView_.myLocationEnabled = YES;
self.view = mapView_;
// Creates a marker in the center of the map.
GMSMarker *marker = [[GMSMarker alloc] init];
marker.position = CLLocationCoordinate2DMake(-33.86, 151.20);
marker.title = @"Sydney";
marker.snippet = @"Australia";
marker.map = mapView_;
}
@end
xcode 버전 및 iOS 시뮬레이터를 사용하고 계신가요? – iOS
Xcode 5.1.1 및 시뮬레이터 iOS 7.0을 사용하고 있습니다. – Apurv