Contents

sceneDepth

Data on the distance between a device’s rear camera and real-world objects in an AR experience.

Declaration

var sceneDepth: ARDepthData? { get }

Discussion

This property describes the distance between a device’s camera and objects or areas in the real world, including ARKit’s confidence in the estimated distance.

This property is nil by default. Add the sceneDepth frame semantic to your configuration’s frameSemantics to instruct the framework to populate this value with ARDepthData captured by the LiDAR scanner.

Call supportsFrameSemantics(_:) on your app’s configuration to support scene depth on select devices and configurations.

See Also

Accessing scene data