Business Navigation (navigation2)
Introduction
Demonstrate the use of industry navigation modules to realize path analysis and guidance of custom road networks.
Operation effect
Figure: Business navigation Operation Effect |
Location
Android Studio
- Product package: Product package\SampleCode\SampleCode_AndroidStudio\AndroidStudioSampleCode\navigation2
Data
Storage location
- Product package: Product package\SampleData\Navigation2Data
Deployment Location: mobile device internal storage\SampleData\Navigation2Data
Resource
Copy the "Product package\Resource\voice" folder to the assets folder in the project directory for navigation voice broadcasting.
License
Offline license, copy the license file to the "mobile device internal storage\SuperMap\License" folder.
Library
jar |
---|
com.supermap.data.jar, com.supermap.mapping.jar, com.supermap.navigation.jar |
so |
libimb2d.so, libAisound.so, libgnustl_shared.so, libQt5Core.so, libQt5Gui.so, libQt5Svg.so, libQt5Widgets.so(Note: Starting from version 11.1, the last five so libraries need to be added.) |
Key types/members
Control/Class | Method |
---|---|
Navigation2 | setNetWorkDataset(), loadModel(), load(), setStartPoint(), setDestinationPoint(), isGuiding(), cleanPath(), stopGuide(), startGuide(), routeAnalyst() |
Basic steps
- Tap button of Set start, and touch &hold one point on the map to set the start point.
- Tap button of Set end, and touch &hold one point on the map to set the end point.
- Tap button of Path analysis, to analyse the route and display the navi path;
- After finishing the route analysis, if you tap button of emulate navigation, emulation guidance will be started and the process will be displayed on the map.
- After finishing the route analysis, if you tap button of reality navigation, reality guidance will be started and the process will be displayed on the map
- When navigating, if you tap stop, navigation will be finished.
- Tap button of Clean up, you could clear navigation and to re-configure.