1. Home
  2. Docs
  3. Getting Started
  4. Setting Up a New Project
  5. Mapbox Setup

Mapbox Setup

Overview

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.

Topics:

  • 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.

Unity setup

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

play button

If you want to use your own map style, read Appendix 2.

Appendix 1 – Create a Mapbox Token

Click the “Create a token” button

mapbox ui

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”

mapbox ui

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.

placing mapbox token

Click the Search button

Enter your Mapbox Username.

You will then see a list of your Mapbox map styles from which you can choose.

Was this article helpful to you? Yes No

How can we help?