Contents

makeArray(of:channelCount:)

Returns an array of width * height * channelCount values that’s a copy of the buffer’s visible contents.

Declaration

func makeArray<U>(of scalarType: U.Type, channelCount: Int) -> [U]

Parameters

  • scalarType:

    The scalar type of each array element.

  • channelCount:

    The number of channels in the pixel buffer.

Return Value

An array of scalarType values that contains the source buffer’s contents.