Location:

Map Display

Pre-import res and data resource packages before displaying the map (Note: This resource bundle can only be imported as a folder, as a resource import project; if packet.dat must be removed)

Display a 3D vector map with the following code example:

        (For complete code, see the MBMapController.m file of the SDKDemo project)
        #import <iNaviCore/MBMapView.h>
        @interface MBMapController ()
        // map view
        @property (nonatomic ,strong) MBMapView *mapView;
        }
        
        - (void)viewDidLoad {
            [super viewDidLoad];
            [self initMapView];
        }

        - (void)initMapView {
            if (baseMapView == nil) {
                baseMapView = [[MBMapView alloc]initWithFrame:self.view.bounds];
                [self.view addSubview:baseMapView];
            }
            [baseMapView setZoomLevel:8.0 animated:YES];
            [baseMapView loadStyleSheet:@"res/map4_style_sheet.json"];
            [baseMapView setStyleClass:@"DEFAULT"];
        
            baseMapView.delegate = self;
        }                
        

3D vector map display effect:

TOP