Contents

vImageBuffer_GetSize(_:)

Returns the size, in pixels, of a vImage buffer.

Declaration

func vImageBuffer_GetSize(_ buf: UnsafePointer<vImage_Buffer>) -> CGSize

Parameters

  • buf:

    The vImage buffer to query.

Return Value

The size of the buffer.

Discussion

The vImage library defines a buffer’s width and height as vImagePixelCount values that may be larger than greatestFiniteMagnitude. This function rounds down the buffer’s dimensions to the nearest representable CGFloat values that are less than, or equal to, the size of the buffer.