---
title: "init(values:width:height:)"
framework: accelerate
role: symbol
role_heading: Initializer
path: "accelerate/vimage/convolutionkernel2d/init(values:width:height:)"
---

# init(values:width:height:)

Returns a new convolution kernel structure with the width and height you specify.

## Declaration

```swift
init(values: [ComponentType], width: Int, height: Int)
```

## Parameters

- `values`: The kernel weights or structuring element values that must contain height * width elements.
- `width`: The width of the kernel that must be a positive, odd number.
- `height`: The height of the kernel that must be a positive, odd number.

## See Also

### Initializers

- [init(values:size:)](accelerate/vimage/convolutionkernel2d/init(values:size:).md)
