Use the Device Tracker to provide position and rotation updates of the device's location; computed from camera frames of the surroundings and sensor measurements. By using Vuforia Fusion to detect and utilize the platform native tracker or use Vuforia’s sensor-fusion technology, the Device Tracker can deliver robust extended tracking for all Vuforia Target types and enable Ground Plane experiences. Use the Device Tracker in your application for dynamic tracking of machines or toys and for navigating indoor environments.
Device Tracker and Vuforia Fusion
For the Device Tracker to function, you must enable Vuforia Fusion which detects what type of platform the application is running on. By doing so, the Device Tracker can benefit from the ARKit/ARCore or VISLAM or SLAM technologies to track the device’s position in relation to its environment. See here for more detailed information on Vuforia Fusion here.
Positional Device Tracker
The Positional Device Tracker inherits from the Device Tracker and it establishes the tracking of the device with respect to the environment in meters. While other trackers track images or objects, this tracker uses visual details of the environment in the camera view as well as, in some cases, the built-in inertial measurement unit (IMU) sensor to determine the six-degree-of-freedom pose of the device itself. In addition, the Positional Device Tracker delivers extended tracking on all Vuforia target types. See Device Tracker in Native for more information on using the device tracker. See also Device Tracker in Unity for instructions on enabling the Device Tracker in a Unity Project.
Static Device Tracker
In some scenarios, the device may be statically mounted (e.g. on a tripod) instead of being handheld. Examples include assembly lines where devices are fixed on a stand while providing instructions to the worker. Or it could be a standing tablet that track toys or board games from a single position. In such scenarios, there is a risk that the positional device tracker will not be able to initialize due to lack of device motion. In such use cases, you can set a static hint before initializing the device tracker. The hint will set the device tracker in a static mode that ensures that extended tracking and robustness against occlusions work even when the device is fixed to one position.
The default value is 0. Set the hint to 1 to enable static device tracking.
This hint needs to be set before the device tracker is initialized.
In Unity, this is best done by registering to the following callback in an
Device Tracker Dependent Vuforia Features
Some Vuforia target types are dependent on the Device Tracker and cannot function without initializing and enabling it.
- Area Targets
- Ground Plane
NOTE: While Model Targets can work without device tracking, it is highly recommended to enable it as it improves tracking of the object.
NOTE: Continuous tracking that allows users to resume an AR session from an interrupt also requires you to enable the Device Tracker.
Area Targets are tracked using the
AreaTracker which depends on the
PositionalDeviceTracker. These targets are built from scanned spaces and used to localizethe device within the environment. For more information on this, please see Area Target API Overview.
The Ground Plane feature utilizes the
PositionalDeviceTracker for maintaining a position and orientation in the world space for the device and anchors. This enables the
SmartTerrain logic to locate and track horizontal surfaces. Visit Ground Plane User Guide for more information.
Extended Tracking is the concept that a target's pose information will be available even when the Target is no longer in the field of view of the camera or cannot directly be tracked for other reasons. Extended Tracking utilizes the Device Tracker to improve tracking performance and sustain tracking even when the target is no longer in view.
In practice this means that after you point your device away from the initial Target, any augmentations maintain their positions with respect to the real world and are consistent with the initial reference frame defined by the target. The more detailed and feature-rich the environment, the better Extended Tracking works.
As the images show, the augmentations and tracking is sustained even when losing sight of the trackable.
Device Tracking States
While tracking an object or other target, users will likely find a position where tracking is limited or even lost. To accommodate for the different states the success of tracking a target can be in, a list of statuses is reported by the
DeviceTrackableResults. These can be used to improve the AR experience by, for example, notifying users to return to a better viewing position so tracking can be restored. See Interpreting Tracking State API Results for detailed information.
Also, there may be situations where the AR tracking is interrupted by for instance a call during the experience and the application is paused. Continuing the experience the application can now relocalize itself if duration and movement between pause and resume is limited. See Best Practices for Continued AR Experiences for more information.