Initializer

init(device:kernelWidth:kernelHeight:)

Initializes a box filter.

Declaration

init(device: MTLDevice, kernelWidth: Int, kernelHeight: Int)

Parameters

device

The Metal device the filter will run on.

kernelWidth

The width of the kernel. Must be an odd number.

kernelHeight

The height of the kernel. Must be an odd number.

Return Value

An initialized box filter object.