Class

AREnvironmentProbeAnchor

An object that provides environmental lighting information for a specific area of space in a world-tracking AR session.

Declaration

@interface AREnvironmentProbeAnchor : ARAnchor

Overview

Environment textures depict the view in all directions from a specific point in a scene. In 3D asset rendering, environment textures are the basis for image-based lighting algorithms where surfaces can realistically reflect light from their surroundings. ARKit can generate environment textures during an AR session using camera imagery, allowing SceneKit or a custom rendering engine to provide realistic image-based lighting for virtual objects in your AR experience.

To enable texture map generation for an AR session, set the environmentTexturing property:

In both cases, ARKit automatically generates environment textures as the session collects camera imagery. Use a delegate method such as session:didUpdateAnchors: to find out when a texture is available, and access it from the anchor's environmentTexture property.

If you display AR content using ARSCNView and the automaticallyUpdatesLighting option, SceneKit automatically retrieves AREnvironmentProbeAnchor texture maps and uses them to light the scene.

Topics

Creating Probe Anchors

- initWithTransform:extent:

Creates a new environment probe anchor.

- initWithName:transform:extent:

Creates a new anchor object with a descriptive name.

Accessing Texture Maps

environmentTexture

A cube map texture representing the view in all directions from the probe anchor's position.

Examining a Probe Anchor

extent

The area around the anchor's position to use when projecting its texture for parallax correction.

Relationships

Inherits From

See Also

Rendering Effects

Adding Realistic Reflections to an AR Experience

Use ARKit to generate environment probe textures from camera imagery and render reflective virtual objects.

ARLightEstimate

Estimated scene lighting information associated with a captured video frame in an AR session.

ARDirectionalLightEstimate

Estimated environmental lighting information associated with a captured video frame in a face-tracking AR session.