Safety locations
Before you start, check the Starting navigation guide
Project setup
- Before proceeding, follow the Quickstart guide for Maps and the Quickstart guide for Navigation to create the
TomTomMapandTomTomNavigationobjects. These are essential for using the Navigation Visualization module, which displays Safety Locations during the navigation session. - Add the Navigation Visualization dependency to the
build.gradlefile of your application module, then synchronize the project:implementation("com.tomtom.sdk.maps.visualization:visualization:2.3.0-rc03")

Safety location types

By default all SafetyLocationTypes are enabled. You can hide specific types of safety locations by using the configuration API:
navigationVisualization.safetyLocationVisualization.hideSafetyLocations(hiddenSafetyLocations)Speed and danger zones on the route
Speed and danger zones are visualized as tubes with outlines along the route. Both zones include a Start Marker indicating the beginning of the zone and an End Marker showing where it ends.
Speed zone

Danger zone

Learn more
Since you have learned how to set up and display Safety locations, here are recommendations for the next steps: