logo

Module 2

LOCATION SCANNING AND OPTIMIZATION
Because Custom Location AR  is anchored to a specific location, you will need to scan the location. This step is essential, and the reliability of your AR experience depends on a well-captured mesh. Ensure you fully understand the process, and practice scanning locations around your home or work area before heading to the actual location for your Lens. To put it simply — plan out the AR experience as best as possible before scanning. Consider which parts of the location the Snapchatter will interact with and, therefore, which parts of the location you should scan. Lastly, as you scan your location, note that Snapchat requires all Custom Location Lenses to include an Image Marker set to an image of the location itself for Lens review purposes.
This module will cover the basics of scanning, capturing larger meshes, optimization tips for optimal mesh capture, and testing your Lens.

Creating a Location Mesh

To scan your own location, open Snapchat’s Custom Location Creator Lens on a LiDAR-enabled device. Scan the Snapcode below to open the Custom Location Creator Lens and begin mesh capture. 
Note: While Custom Location AR can be experienced on Snapchat’s Spectacles, creating your own Location Mesh on Spectacles is currently unavailable.
If your device is not LiDAR-enabled, you will receive an error message.
The Custom Location Creator Lens enables you to scan the location and save the mesh you will use in your Lens Studio project. Once the Custom Location Creator Lens is opened, tap ‘Create New.’

Arriving on Location

Once you arrive at the location you want to scan, survey the area to figure out exactly what you would like to create. Take note of where you think Snapchatters will be when opening and engaging with the Lens. If you’re thinking about placing 3D objects into the scene, consider the surrounding space and any possible obstructions. Always take care to consider Snapchatters’ safety, and never create experiences that could pose a physical risk. For example, do not create a Lens that would encourage a Snapchatter to step into traffic or trespass on private property.

Scanning and Lens Settings

When launching the Creator Lens, leave all settings at default. As you become more experienced with scanning, you may want to start changing things, but the default settings should work for your first scan. Once you tap ‘Create New,’ follow the instructions and get closer to your location, as mesh scanning only works up to 5 meters, or 15 feet, using a LiDAR sensor.
For the best results, sweep your device over the physical objects you need to create the mesh for. Continue to sweep the scene in steady, archlike motions with your arm. As you scan your location, you will notice the progress bar fill, as each scan has a maximum mesh capacity. If you need to create more mesh without adding to the progress bar, try not moving the phone more than 10 centimeters (4 inches) at a time. Instead, rotate your wrist to capture more mesh. This will result in adding more mesh without adding perspective — perspective is only added when the phone is moved more than 10 centimeters (4 inches).

Creating Large Meshes

The Custom Location Creator Lens has a maximum storage of 10MB in scanned mesh. This does not contribute to the final Lens size, which has a maximum limit of 8MB. If you have to create a larger mesh, and the Create Mesh progress bar is running out, switch your settings from Combined to Separate Scan, then max out the mesh size. You may notice a slight misalignment, since the mesh and perspective scans aren’t started at the same time, but following these steps will enable you to access a much larger mesh. Don’t worry — mesh misalignment is not an issue, since the mesh simply serves to help you understand where to place your AR objects in Lens Studio (and occlude them if necessary). To keep the Lens file smaller, only create mesh where needed.

Verifying your Scan Results

While on location, you can test the tracking and content placement. Open the Custom Location Creator Lens and tap ‘View Your Uploads.’ A list of your previously scanned locations will appear. Select the location you’d like to test. During this step, you can press the ‘+’ button to perform an incremental scan of your location. This is useful in helping account for different lighting conditions or other environmental/physical changes. For example, you can capture perspectives during the morning, afternoon, and evening to maximize the chance that AR tracking will be successful at every time of day. Each incremental scan is saved as a new location mesh, so be sure to name it appropriately. We recommended limiting the number of incremental scans to three. Since Custom Location AR  tracking uses compressed CV data, multiple incremental scans will dilute your results.

Scanning the Floor

It may be helpful to create mesh for parts of the floor around the location to ensure more stable AR tracking. This is a simple solution that can help to improve the overall Snapchatter experience with little expense of the total mesh capture.