Android NDK (C)
Unity (AR Foundation)
The ARCore Geospatial API utilizes data from Google Earth 3D models and Street View image data from Google Maps to enable your app for immersive, global-scale, location-based augmented reality experiences.
Google's Visual Positioning System (VPS) provides this data model, taken from billions of images worldwide. The images are converted into a high-definition, 3D point map for visual localization. Deep neural networks then identify and describe those parts of the image that are likely to be recognizable over long periods of time. This localization model consists of tens of trillions of points and spans all countries with Street View coverage.
Using GPS and other sensor data alone to determine location is not usually sufficient to achieve the precision required for AR applications. The Geospatial API uses device sensor data (such as GPS), and captured image data to determine precise location. It creates an image map that is processed to find the recognizable parts of the environment and matches them to the VPS localization model. The result is a very precise location and pose (position and orientation) for your app.
Anchors in ARCore also use image maps to determine pose. However, these image maps are locally-created, for example with the Cloud Anchors API. Sharing these image maps outside of the app that created them is not readily supported by the API and requires extra work.
The Geospatial API provides for an anchor's horizontal position (latitude and longitude) and vertical position (altitude) following the WGS84 specification. With the Geospatial API, you can place an anchor almost anywhere in the world at a given latitude, longitude and altitude. 3D building geometry is a still developing part of the VPS localization model, and placing anchors on geometric planes will be supported, too, as enhancements to these and other aspects of the VPS localization model are planned for future releases of the Geospatial API.
See the platform-specific developer guides above to learn how to get the latitude, longitude and altitude, and place anchors with the Geospatial API.