Skip to main content

Editor.Components.DeviceTrackingMode

Enum

The same entity as in Lens Scripting.

Index

Enumeration Members

Example

const model = this.pluginSystem.findInterface(Editor.Model.IModel) as Editor.Model.IModel;
const scene = model.project.scene;

// Create a DeviceTracking component and set tracking mode
const obj = scene.createSceneObject('DeviceTracker');
const dt = obj.addComponent('DeviceTracking');
dt.deviceTrackingMode = Editor.Components.DeviceTrackingMode.Surface;
console.log(`deviceTrackingMode: ${dt.deviceTrackingMode}`);

Enumeration Members

Rotation

Rotation: number

Track device rotation only.


Surface

Surface: number

Track device position relative to detected surfaces.


World

World: number

Track device position and orientation in world space.

See also

Editor.Components.DeviceTracking.