The Explore AR template uses the Mapbox SDK to display maps. This document will show you how to link your Mapbox account with the Explore AR template.
- Input your Mapbox Access Token into the Explore AR template
- Change the Map Style using of the Explore AR template
Input your Mapbox Access Token
First, open the Explore AR template in Unity.
Find the Mapbox Menu
Click on the Mapbox menu and select “Setup”
The Mapbox Setup tab will appear. If you don’t already have a Mapbox account, you’ll need to create one. See the Appendix 1 for steps to create a Mapbox Token.
Once you have entered your Mapbox token, you can close the Mapbox Setup tab. At this point, you can press play to start Explore AR and use the default map.
Click the Play button to start the Explore AR template
If you want to use your own map style, read Appendix 2.
Appendix 1 – Create a Mapbox Token
Click the “Create a token” button
In the “Create a new access token” window, do the following:
- Enter a token name
- Make sure all the Public Scope Items are checked
- Under Secret Scopes, make sure “Styles:List” item is checked
- Click “Create Token”
Appendix 2 – Change the Mapbox Style
In the Explore AR template, find the Project tab and search for: ScenicMapImageFactory
Open the ScenicMapImageFactory in the Inspector.
Click the Search button
Enter your Mapbox Username.
You will then see a list of your Mapbox map styles from which you can choose.