---
title: kernelWidth
framework: metalperformanceshaders
role: symbol
role_heading: Instance Property
path: metalperformanceshaders/mpsimageconvolution/kernelwidth
---

# kernelWidth

The width of the filter window. Must be an odd number.

## Declaration

```swift
var kernelWidth: Int { get }
```

## See Also

### Properties

- [kernelHeight](metalperformanceshaders/mpsimageconvolution/kernelheight.md)
- [bias](metalperformanceshaders/mpsimageconvolution/bias.md)
