Core Framework Releases
The Mapbox Navigation SDK Core Framework for Android allows you to build a custom navigation experience with the power of the Mapbox Directions API, Mapbox Map Matching, and Mapbox Maps.
v3.0.0-rc.5 latest - 30 March, 2024
- The new
ui-componentsmodule is now available. This module offers UI components that were previously accessible in Nav SDK v2. - Made
RouteShieldError#urlandRouteShieldOrigin#originalUrlnullable. They can be null in case the request had been cancelled before the URL was formed. - Improved road shield rendering behaviour for long text: now the closest length-wise available icon will be downloaded, previously it had been fixed to a maximum of 6 characters.
- Added a Copilot option that allows to provide a different user id for history recording context.
Mapbox dependencies:
- Mapbox Maps SDK
v11.2.2(release notes) - Mapbox Navigation Native
v304.0.0 - Mapbox Core Common
v24.2.3 - Mapbox Java
v6.15.0(release notes)
Previous versions
v1.0.0-beta.1 - 13 December, 2023
v1.0.0-beta.2 - 22 December, 2023
v1.0.0-beta.3 - 19 January, 2024
Changelog
- Introduced support of Mapbox Map Matching API, see
MapboxNavigation#requestMapMatching. - Support more options for
MapMatchingOptions. - Made
MapboxNavigationconstructor andonDestroyinternal. To create an instance ofMapboxNavigationuseMapboxNavigationProvider#create; to destroy it useMapboxNavigationProvider#destroy.
v1.0.0-beta.4 - 26 January, 2024
Changelog
- Improved
CustomRouterRuleto work independently from device network setup. - Removed
CustomRouterRule#baseUrl. NowCustomRouterRuleintercepts all route and route refresh requests to Mapbox Directions API. - Fixed a bug with multiple instances of cache which resulted in excessive memory consumption.
- Fixed an issue where reroute for multi-leg routes used to fail in case waypoint_names or waypoint_targets parameters were specified without an explicit waypoint_indices parameter.
- Improved Map Matching to avoid false deviation of the location puck to a parallel street.
- Improved handling of no storage available during navigation tiles downloading.
- Improved handling of invalid config in
DeviceProfile#customConfig. - Fixed a native crash in E-Horizon implementation caused by internal race condition.
- Made
MapboxReplayerconstructor public. - Removed
OnlineRouteAlternativesSwitch. UseNavigationRouteAlternativesObserverto receive an online alternative for the current offline route. UnlikeOnlineRouteAlternativesSwitch,NavigationRouteAlternativesObserverdoesn't switch to an online alternative automatically. - Changed structure of
NavigationRoute. Now it can represent routes received from Mapbox Map Matching API as well as Mapbox Directions API.NavigationRoute#directionsResponsehas been removed. UseNavigationRoute#waypoints,NavigationRoute#responseUUID, andNavigationRoute#responseMetadatato access data which used to be available viaNavigationRoute#directionsResponse.NavigationRoute#routeOptionshas been removed. Try to utilise data available inNavigationRoute, for example instead of using coordinates from route options, useNavigationRoute#waypoints. Temporary propertyNavigationRoute#evMaxChargehas been added to access maximum possible charge for the vehicle the route was requested for instead ofnavigationRoute.routeOptions.getUnrecognizedProperty("ev_max_charge"). - Added
MapMatchingSuccessfulResult#navigationRouteswhich represent routes that could be set to navigator usingMapboxNavigation#setNavigationRoutes. - Changed type of
MapMatchingSuccessfulResult#matchesfromList<NavigationRoute>toList<MapMatchingMatch>. Now every item fromMapMatchingSuccessfulResult#matchesrepresents a Match Object from Mapbox Map Matching API. - Changed LocationOptions API. Now custom location providers that emit mocked locations are allowed. In order to set a custom location provider, you now need to invoke
LocationOptions.Builder#locationProviderFactoryand pass a factory that will create a DeviceLocationProvider implementation based on a request parameter together will location provider type, which can be one of: REAL, MOCKED, MIXED. Note that if your provider can emit non-real locations, it must setisMockextra flag value to true for such locations. To set this flag, use:
Location.Builder#extra(Value.valueOf(hashMapOf(LocationExtraKeys.IS_MOCK to Value.valueOf(true/false))))
- Added Advanced Driver Assistance Systems (ADAS) functionality as an experimental API.
- Added
NavigationViewApi#recenterCamera()that allows to programatically recenter the camera position as if the recenter button was clicked.
v1.0.0-beta.5 - 02 February, 2024
Changelog
- The
maneuvermodule now offers only API related to maneuver logic. Views was removed from the module MapboxRecenterButton,MapboxRouteOverviewButton,MapboxRoadNameView,MapboxCameraModeButtonhave been removed from ui-maps module.MapboxExtendableButtonLayoutBindinghas been removed fromui-basemodule.- New module
libnavigation-tripdatais available. It accumulates core api fromlibnavui-shield,libnavui-tripprogress,libnavui-maneuver,libnavui-speedlimitmodules, which have been removed. - Introduced support for highlighting 3D buildings.
- Navigation Core Framework doesn't let creating
NavigationRoutefrom json anymore. UseMapboxNavigation#requestRoutesandMapboxNavigation#requestMapMatchingto requestNavigationRoutes. - Added
NavigationRoute#serializeandNavigationRoute#deserializeFromto support immediate transfer ofNavigationRoutebetween applications and processes with the same Navigation Core Framework version. - Fixed crash in CustomRouterRule caused by invalid url schema in request
v1.0.0-rc.1 - 06 February, 2024
Changelog
- Changed type of
RouterOrigin. Now it's an annotation which defines possible string values for router origin. RouterOrigin.Offboardis renamed toRouterOrigin.ONLINE.RouterOrigin.Onboardis renamed toRouterOrigin.OFFLINE.RouterOrigin.Customis removed.- Navigation Core Framework automatically updates alternative routes and switches to an online alternative in case of an offline primary route. Register
RoutesObserverto keep track of current routes. UseMapboxNavigation#setContinuousAlternativesEnabledto enable/disable automatic update. NavigationRouteAlternativesObserver,RouteAlternativesObserver,NavigationRouteAlternativesRequestCallback,MapboxNavigation#registerRouteAlternativesObserver,MapboxNavigation#requestAlternativeRouteswere removed in favour of automatic alternatives update.libnav-uimodule has been renamed tolibnavigation-voice. Package name has been changed tocom.mapbox.navigation.voice.- Added support for
RouteOptions#suppressVoiceInstructionLocalNamesto onboard router. - Changed the semantics of
Location#timestampthat you receive inonLocationMatcherResult, instead of being set to current system time it is now has location input time + lookahead (extrapolation) time. - Implement ADASIS message batching.
- Split
MapboxRouteLineOptionsintoMapboxRouteLineApiOptionsandMapboxRouteLineViewOptions. - Split
MapboxRouteLineOptions#displayRestrictedRoadSectionsintoMapboxRouteLineApiOptions#calculateRestrictedRoadSectionsandMapboxRouteLineViewOptions#displayRestrictedRoadSections. You can have a set-up where some of yourMapboxRouteLineViews display the restricted data and others don't. SetMapboxRouteLineApiOptions#calculateRestrictedRoadSectionsif at least one of yourMapboxRouteLineViews will display the restricted data. SetMapboxRouteLineViewOptions#displayRestrictedRoadSectionsonly to those views, who are going to display it. - Moved:
MapboxRouteLineOptions.Builder#withRouteLineBelowLayerIdtoMapboxRouteLineViewOptions.Builder#routeLineBelowLayerId;MapboxRouteLineOptions.Builder#withTolerancetoMapboxRouteLineViewOptions.Builder#tolerance;MapboxRouteLineOptions.Builder#withVanishingRouteLineEnabledtoMapboxRouteLineApiOptions.Builder#vanishingRouteLineEnabled;MapboxRouteLineOptions#styleInactiveRouteLegsIndependently,MapboxRouteLineOptions#vanishingRouteLineEnabledandMapboxRouteLineOptions#vanishingRouteLineUpdateIntervalNanotoMapboxRouteLineApiOptions.MapboxRouteLineOptions#softGradientTransition,MapboxRouteLineOptions#displaySoftGradientForTraffic,MapboxROuteLineOptions#shareLineGeometrySources,MapboxRouteLineOptions#lineDepthOcclusionFactor,MapboxRouteLineOptions#waypointLayerIconOffset,MapboxRouteLineOptions#waypointLayerIconAnchorandMapboxRouteLineOptions#iconPitchAlignmenttoMapboxRouteLineViewOptions.
- Removed
RouteLineResourcesclass:
routeLineColorResources,originWaypointIcon,destinationWaypointIcon,restrictedRoadDashArray,restrictedRoadOpacityandrestrictedRoadLineWidthwere moved toMapboxRouteLineViewOptionstrafficBackfillRoadClasseswas moved toMapboxRouteLineApiOptionsscaleExpressionproperties were moved toMapboxRouteLineViewOptions#scaleExpressionswrapper of typeRouteLineScaleExpressionsroundedLineCapproperty was removed
- Moved
congestionRangeproperties fromRouteLineColorResourcestoMapboxRouteLineApiOptions. - Removed
MapboxRouteLineOptions#routeStyleDescriptorsoption. - Removed the possibility of modify and reading data from
RouteLineSetValue,RouteLineClearValueandRouteLineUpdateValue. Do not use these classes on your side, just pass the objects betweenMapboxRouteLineAPIandMapboxRouteLineView. MapboxRouteLineAPI#optionsandMapboxRouteLineView#optionsproperties are no longer public.- Made
RouteLineExpressionProviderandRouteLineTrimExpressionProviderinternal. - Added a possibility to change a subset of
MapboxRouteLineViewOptionsin runtime without the need to recreate the components. The subset that can be changed is defined inMapboxRouteLineViewDynamicOptionsBuilder. To change the dynamic options in runtime, use the following code:
routeLineView.updateDynamicOptions(style) {
routeLineColorResources(newColors)
// ...
}
routeLineApi.getRouteDrawData {
routeLineView.renderRouteDrawData(style, it)
}
- Split
RouteLineConfig#optionsintoRouteLineConfig#apiOptionsandRouteLineConfig#viewOptions - Added
RouteLineConfig#viewOptionsUpdates. - Removed
MapboxRouteLineApi#showRouteWithLegIndexHighlighted,MapboxRouteLineApi#setPrimaryTrafficColorandMapboxRouteLineApi#setAlternativeTrafficColormethods. - Changed
MapboxRouteLineApi#setVanishingOffsetmethod behavior in the following way: if the route had not been set toMapboxRouteLineApiprior to the point whensetVanishingOffsetwas invoked, it will return an error now. Previously it used to return a value, which was, however, useless for rendering without the route. - Fixed an issue when soft gradient was not applied correctly in
MapboxRouteLineApi#setVanishingOffsetresult. - Fix adas tiles eviction algorithm
- Fixed a mapmatching issue where the position might have been snapped to the wrong part of a highway after leaving tunnel
- Improve GNSS jump detection for better pitch based map-matching in tunnels
- Eliminate border crossing object when moving to neutral waters and back
v1.0.0-rc.2 - 16 February, 2024
Changelog
- Removed
LongRoutesOptimisationOptions. Navigation Core Framework is now optimized to handle long routes by default. - Added billing explanation logs. Now Navigation SDK explains in the logs why certain Active Guidance or Free Drive Trip session started/stopped/paused/resumed. Billing explanations have
[BillingExplanation]prefix in the logcat. - Removed
NavigaitonRoute#deserializeFromandNavigationRoute#serializefrom public API because it's too easy to misuse them and create a leak of resources. RouterFailure.codehas been replaced withRouterFailure.type. SeeRouterFailureTypeto find all possible error types.- Improve map-matching on elevated roads.
- Added "mbx.RouteLine" history events. They will be collected automatically by NavSDK for both manual recorder and Copilot recorder when the recording is started.
You can enable route line events collection for Copilot using
CopilotOptions#shouldRecordRouteLineEventsoption. It is disabled by default. - Improved EHorizon path evaluation.
- Fixed leak of CarAppLifecycleOwner on every copilot start.
- Added Polish translation for UI elements.
v1.0.0-rc.3 - 01 March, 2024
Changelog
- Resolved an issue where a crash could occur if telemetry sending settings were changed after creating
MapboxNavigation. - Fixed an issue with vanishing route line not working for single-leg routes.
- Eliminated waiting for online route in case of reroute if onboard is ready. For rerouting return the route that was calculated sooner will be returned, and the back-online feature is expected to handle the case of switching back to online.
- Improved highway exits detection.
- Improved passed alternatives handling.
- Fixed an issue when onboard route calculation might have been cancelled if online router returned critical error.
- Fixed an issue in processing ETC signals when distant projections where treated as valid map-matched locations.
- Fixed leak of CarAppLifecycleOwner on every copilot start.
- Fixed ADASIS generator errors related to the split edges.
- Fixed ADAS cache tiles eviction mechanism.
- Started handling "unlilimited" speed limits in ADASIS.
- Started sending special type POSITION messages in OFF-ROAD mode.
- Fixed ANR
at com.mapbox.common.LifecycleUtils.hasServiceRunningInForeground(LifecycleUtils.kt:25).
Mapbox dependencies:
- Mapbox Maps SDK
v11.2.0(release notes) - Mapbox Navigation Native
v303.0.0 - Mapbox Core Common
v24.2.0 - Mapbox Java
v6.15.0(release notes)
v1.0.0-rc.4 - 18 March, 2024
Changelog
- Added experimental property
NavigationRoute#responseOriginAPIwhich describes API that Navigation CF used to generate data forNavigationRoute.NavigationRoute#responseOriginAPIcould be used to form expectations from navigation experience given the fact that routes withResponseOriginAPI.MAP_MATCHING_APIhas limited support currently. - Public data classes have been replaces with normal classes with generated
equals,hashCode,toString.copyfunction and destructuring declarations are not available for affected classes. Affected classes are:ExclusionViolation,TripNotificationData,MatchableOpenLr,MatchableGeometry,MatchablePoint,ReplayEvents,ReplayEventGetStatus,ReplayEventUpdateLocation,ReplayEventLocation,RerouteState.Failed,RerouteState.RouteFetched,RouteOptionsResult.Succes,RouteOptionsResult.Error,NavigationSessionState.FreeDrive,NavigationSessionState.ActiveGuidance,SearchResultsEvent,SearchResultUsedEvent,HistoryPoint,HistoryRoutablePoint,HistorySearchResult,SearchResultUsed,SearchResults,FocalPoint,ViewportData,NavigationRouteLine,RouteLineDistancesIndex,RouteLineScaleValue. - Added support of seamless switch to an alternative route in case of deviation to the alternative route from a route received via
MapboxNavigation#requestMapMatching. - Added
RerouteOptions#enableLegacyBehaviorForMapMatchedRoutewhich lets enable reroute logic from Nav SDK v2 for routes generated by Mapbox Map Matching API. - Changed reroute state transition in case of deviation from a primary route which is received via
MapboxNavigation#requestMapMatchingwhen no alternative routes available to switch to. Reroute state used to beIdle, but now performs the following transition:Idle->FetchingRoute->Failed->Idle.
Mapbox dependencies:
- Mapbox Maps SDK
v11.2.1(release notes) - Mapbox Navigation Native
v303.0.0-36f123f - Mapbox Core Common
v24.2.0 - Mapbox Java
v6.15.0(release notes)