Contents

renderTargetArrayLength

The number of active layers that all attachments need to have for layered rendering.

Declaration

var renderTargetArrayLength: Int { get set }

Mentioned in

Discussion

The default value is 0, indicating that the GPU does not use layered rendering on this render pass.

The table below gives typical values you might set, depending on the type of texture being used as attachments in the render pass. Your vertex shader need to select the render target array index between 0 and the array length minus 1.

Texture Type

Typical Length

Type1darray or Type2darray

The length of the texture array (Arraylength)

Typecube

6

Typecubearray

6 times the length of the texture array (Arraylength)

See Also

Layered rendering