Results 1 to 3 of 3

Thread: SKViaPoints.h is missing in SKMaps.h (Cocoa Pod)

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Etablierter skobbler
    Join Date
    26.10.2015
    Posts
    36

    SKViaPoints.h is missing in SKMaps.h (Cocoa Pod)

    When I install the ScoutMaps-iOS-SDK cocoa pod, I can't use SKViaPoint because its include file is not imported in SKMaps.h

  2. #2
    Etablierter skobbler
    Join Date
    26.10.2015
    Posts
    36

    Crashes when using SKViaPoints

    I added SKViaMaps.h to SKMaps.h and it compiles. However, when I use SKViaPoints in a rout calculation, it crashes with
    "libc++abi.dylib: terminating with uncaught exception of type std::length_error: vector"

    Code:
    	var viaPoints = [SKViaPoint]()
    	viaPoints.append(SKViaPoint(2000, withCoordinate: CLLocationCoordinate2DMake(40.685623, -112.00685)))
    	viaPoints.append(SKViaPoint(2001, withCoordinate: CLLocationCoordinate2DMake(40.6956965462893, -112.010362744331)))
    	viaPoints.append(SKViaPoint(2002, withCoordinate: CLLocationCoordinate2DMake(40.6905431890973, -112.006948292255)))
    
    	let route = SKRouteSettings()
    	route.startCoordinate = annotations[0].location
    	route.destinationCoordinate = annotations[annotations.count-1].location
    	route.shouldBeRendered = renderRoute
    	route.routeMode = routeMode
    	route.maximumReturnedRoutes = UInt(maxRoutes)
    	route.requestAdvices = loadSteps
    
    	// Works fine if I comment out this line. Crashes with this line.
    	route.viaPoints = viaPoints.count > 0 ? viaPoints : nil
    	
    	SKRoutingService.sharedInstance().calculateRoute(route)

  3. #3
    Oberskobbler
    Join Date
    22.07.2014
    Posts
    399
    This is a known issue that unfortunately wasn't fixed for the CocoaPods integration. As we are working on the new build, this fix should be available in the next month.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •