Instance Property


The attenuation of ambient light due to local geometry variations on a surface.


@property(nonatomic, readonly, retain) MDLMaterialProperty *ambientOcclusion;


Ambient occlusion (AO) describes the accessibility of a point on a surface to the surrounding radiant environment and is typically used to attenuate ambient lighting. A renderer should not use AO data should to affect direct illumination.

The default AO value is zero. Typically, you assign a texture (such as that created with the generateAmbientOcclusionTextureWithQuality:attenuationFactor:objectsToConsider:vertexAttributeNamed:materialPropertyNamed: method of a mesh) to this material property to add shading based on the shape of the mesh.

See Also

Working with Shading Properties


The inherent color of the material, to be used as a modulator during shading.


The color emitted as radiance from a material’s surface.


The intensity of specular highlights on the material’s surface.


The index of refraction for the medium surrounding a material.


The index of refraction for a material itself.


The variation in the surface normal vectors in a material, relative to model coordinate space.


The scaling factor for ambient occlusion shading.

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