Protocol

HasAnchoring

An interface that enables anchoring of virtual content to a real-world object in an AR scene.

Declaration

protocol HasAnchoring : Entity

Topics

Getting the Component

var anchoring: AnchoringComponent

The component that describes how the virtual content is anchored to the real world.

struct AnchoringComponent

A description of how virtual content can be anchored to the real world.

Identifying the AR Anchor

var anchorIdentifier: UUID?

The identifier of the AR anchor to which the entity is anchored, or nil if it isn’t currently anchored.

Moving the Anchor

func reanchor(AnchoringComponent.Target, preservingWorldTransform: Bool)

Changes the entity’s anchoring, preserving either the world transform or the local transform.

Relationships

Conforming Types

See Also

Configuring the Anchor

var anchoring: AnchoringComponent

The component that describes how virtual content is anchored to the real world.

struct AnchoringComponent

A description of how virtual content can be anchored to the real world.

var anchorIdentifier: UUID?

The identifier of the AR anchor with which the anchor entity is associated, or nil if it isn’t currently anchored.

func reanchor(AnchoringComponent.Target, preservingWorldTransform: Bool)

Changes the entity’s anchoring, preserving either the world transform or the local transform.