Instance Method

initWithTransform:

Creates a new anchor object with the specified transform.

Declaration

- (instancetype)initWithTransform:(simd_float4x4)transform;

Parameters

transform

A matrix encoding the position, orientation, and scale of the anchor relative to the world coordinate space of the AR session the anchor is placed in.

World coordinate space in ARKit always follows a right-handed convention, but is oriented based on the session configuration. For details, see Understanding World Tracking.

Discussion

Use the addAnchor: method to begin tracking your custom anchor in an AR session.

See Also

Creating Anchors

- initWithName:transform:

Creates a new anchor object with the specified transform and a descriptive name.

name

A descriptive name for the anchor.