Use the plane tracker to create a world effect in Spark AR Studio, placing 3D objects in people's environments.
A plane tracker will find a horizontal surface in the real world, like a floor to table. Objects that are children of the plane tracker will then appear when the surface is detected.
You can only add one plane tracker to a scene, but you can make multiple objects respond to the plane tracker.
Plane tracking effects are only visible through the camera on the back of the device.
To add a plane tracker to your project:
Because plane trackers only work through the back camera, the video in the Simulator will automatically be replaced by a video showing the world, rather than a person.
Your Viewport will look like this:
To make an object appear when the camera detects a surface, all you need to do is make the object a child of the plane tracker in the Scene panel. In Spark AR Studio, when one object is a child of another object, it'll respond to and take on any changes made to its parent object.
To do this, either:
When you've selected the plane tracker in the Scene panel, you'll see its properties in the Inspector.
Click the dropdown next to Layer to adjust which layer the plane tracker is assigned to.
Clear this box to stop the plane tracker and any children from being rendered in the scene.
Select this box to find a plane in world space as soon as your effect is opened.
You can't change the transformations for a plane tracker, because it isn't an object.
This sets camera-specific visibility. For the plane tracker, Enable For is set to Back Camera automatically and can't be changed. This means that the plane tracker will only be visible in the back camera of a mobile device.
You can use the Patch Editor to easily add interactivity to effects that use the plane tracker.
Because objects that are children of the plane tracker will appear on a real world surface, it's a good idea give people the ability to resize, move and rotate the object using screen interactions like taps and swipes. Learn how in this guide
When you've added a plane tracker to an effect, it's a good idea to add an instruction to let users know the effect should be viewed through the back camera. You can use the Patch Editor to do this.