Initializer

init(reflectiveTexture:irradianceTexture:)

Initializes a light probe with the specified cube map textures.

Declaration

init(reflectiveTexture: MDLTexture?, irradianceTexture: MDLTexture?)

Parameters

reflectiveTexture

A cube map texture that contains a rendering of a scene as seen from the light probe’s position.

irradianceTexture

A cube map texture that contains samples of the total light arriving at the light probe’s position from every direction.

Return Value

A new light probe object.

Discussion

You can derive an irradiance map from a reflective texture with methods on the MDLTexture class, or when creating a light probe with the init(textureSize:forLocation:lightsToConsider:objectsToConsider:reflectiveCubemap:irradianceCubemap:) method.

Beta Software

This documentation contains preliminary information about an API or technology in development. This information is subject to change, and software implemented according to this documentation should be tested with final operating system software.

Learn more about using Apple's beta software