Walking Routing
The walking calculation is the same as the walking calculation. The walking route planning is performed for the MBRouteRule by setting the calculation rules.
(For complete code, see MBNavigationBaseController.m of the SDKDemo project) // route query plan @property (nonatomic ,strong) MBRoutePlan *routePlan; // Initialize MBRoutePlan _routePlan = [[MBRoutePlan alloc]init]; // Simulation starting point MBPoiFavorite *startPoint = [[MBPoiFavorite alloc]init]; MBPoint startPos = {11639061,4001898}; startPoint.pos = *(&startPos); // simulation end point MBPoiFavorite *endPoint = [[MBPoiFavorite alloc]init]; MBPoint endPos = {11639743,3990885}; endPoint.pos = *(&endPos); // Set the starting point [_routePlan setStartPoint:startPoint]; // set the end point [_routePlan setEndPoint:endPoint]; // Set the calculation rules [_routePlan setRule:MBRouteRule_walk]; // Start counting [naviSession startRoute:_routePlan routeMethod:MBNaviSessionRouteMethod_multipleResult]; // MBNaviSessionDelegate - (void)naviSessionRouteStarted{ // Start counting } - (void)naviSessionResult:(MBRouteCollection *)routes{ // Calculate the road to complete // Get the routes collection, the routeBases in this collection, need to use when initiating navigation to obtain data } - (void)naviSessionRouteFailed:(MBTRouterError)errCode moreDetails:(NSString*)details{ // Calculating the road failed }