Niantic Spatial VPS2
Niantic Spatial’s Visual Positioning System 2 (VPS2) unifies and extends the capabilities of the original VPS and the World Positioning System (WPS). It fuses device sensors, visual data, and cloud services to provide stable global geopositioning and precise map-relative localization when available.
VPS2 operates in two distinct modes: Coarse and Precise.
Core Concepts
- Geoposition: Latitude, longitude, and altitude in a global coordinate system.
- Heading: Heading relative to geographic north.
- Map-relative pose: A full six-degree of freedom (6DOF) pose—3D position (x, y, z) and 3D orientation (roll, pitch, yaw) expressed in the coordinate frame of a VPS map.
- Coarse localization: Global geoposition and heading without requiring a VPS map.
- Precise localization: Map-relative pose resolved against a VPS map.
Localization Modes
VPS2 uses different localization modes, depending on available data to estimate the device’s real-world position and heading. Each mode balances stability, accuracy, and global coverage based on the environment.
Coarse Localization
Coarse localization provides a global geoposition (latitude/longitude/altitude) and heading. Coarse localization:
- Works globally
- Does not require a VPS map
- Provides stable global alignment suitable for large-scale AR experiences
It operates through two methods:
Local Sensor Fusion
Formerly known as WPS (World Positioning System), this method fuses GPS and magnetometer data with device AR tracking locally on the device. It improves frame-to-frame stability beyond raw GPS and compass readings and is available globally without any cloud dependency.
Cloud-based Geopositioning (Experimental feature)
When enabled, VPS2 sends camera imagery to the cloud to compute an improved geoposition and heading. This can provide greater accuracy than local sensor fusion alone. Improvements are most apparent in dense urban environments, where multipath effects and signal obstruction frequently degrade GPS accuracy. Enable this via the Universal Localization Enabled configuration option.
Network requirements: VPS2 typically requires approximately four cloud localization requests per second during initialization to establish a stable initial geoposition and heading.
Cold start
In some regions, the first cloud geopositioning response may take 60 seconds or longer. Until this initial cloud response is received, global geoposition accuracy mirrors standard device GPS. This delay applies only to cloud-based coarse geopositioning. It does not affect VPS map localization once a VPS map is available and localization is attempted.
Precise Localization
In areas where a VPS Site is available and has been fully processed from a Scaniverse capture, VPS2 can localize the device to that Site. When localization succeeds, VPS2 returns a 6DOF map-relative pose expressed in the Site’s coordinate system. This is a stable local frame defined by the VPS map and intended for precise AR placement, persistence, and shared experiences.
Developers do not need to manually convert between AR space, map space, and global coordinates. The VPS2 transformer handles these conversions automatically.
Precise localization requires that your application has access to the Site and that you explicitly attempt localization, for example, by tracking the Site’s default anchor.
Precise localization enables:
- High-precision AR content placement
- Persistent and shared anchors
- Stable alignment to mapped real-world environments
When localized to a VPS map, VPS2 will often improve global geoposition and heading accuracy. However, improvements to absolute geoposition are not guaranteed, particularly for smaller maps.
As of NSDK 4.0 Beta, automatic precise localization is not available. To enable precise localization, explicitly attempt to localize to a Site by tracking the Site’s default anchor.
Geo-alignment and absolute accuracy
Each VPS map is aligned to geographic coordinates during processing. This alignment determines how map-relative poses convert to global latitude, longitude, altitude, and heading.
In the Scaniverse Web, you can manually adjust maps with the Georeference tool to better align the VPS map with geographic imagery. This adjustment affects global geoposition accuracy but does not change local map-relative accuracy. The following points are important:
- Satellite imagery is not guaranteed to be accurate and may be outdated.
- Satellite images typically show rooftops, which may occlude or obscure ground-level geometry.
- Indoor scans cannot always be precisely aligned to overhead imagery.
- Tall buildings and shadows can reduce visual clarity in satellite imagery.
- Rotation accuracy is critical. Small rotational misalignment between the VPS map and geographic north can produce increasing positional error as distance from the map origin increases. Positional offset remains constant, but rotational error is magnified as users move farther from the map center.
Global geoposition accuracy depends heavily on how precisely the VPS map is aligned to the real-world geographic coordinate system.
Applications should rely on:
- Map-relative pose for high-precision AR alignment.
- Geoposition accuracy values returned by the transformer to evaluate global alignment reliability.
Anchors
An anchor represents a persistent real-world pose used to attach virtual content.
Anchor accuracy depends on localization state:
- Limited: The device is not localized to a VPS map. The anchor pose is estimated using coarse localization and will not be as accurate or as stable in comparison to a Tracked state.
- Tracked: The device is localized to a VPS map. The anchor pose provides stable map-relative alignment.
An anchor may transition between Limited and Tracked as map localization is gained or lost. These two states allow developers to adapt UX behavior based on the expected precision and reliability of the anchor pose.
How VPS2 Fits Together
- The device runs local AR tracking.
- VPS2 establishes a global geoposition and heading (
Coarse). - If a VPS map is available, the device localizes to it (
Precise). - Anchors resolve relative to either:
- The global geoposition (
Limited), or - The VPS map (
Tracked).
- The global geoposition (
- The VPS2 transformer converts between AR space and global geoposition.
Best Practices
Camera orientation: Hold the device upright at approximately eye level, pointing toward visually distinctive features. Avoid low-texture surfaces, ground-only views, or sky.
Next Steps
End-to-end guide:
Using VPS2 with the Niantic SDK: