blur(radius:opaque:)
Applies a Gaussian blur to the view.
Declaration
func blur(radius: CGFloat, opaque: Bool = false) -> some VisualEffect
Parameters
- radius:
The radial size of the blur. A blur is more diffuse when its radius is large.
- opaque:
A Boolean value that indicates whether the blur renderer permits transparency in the blur output. Set to
trueto create an opaque blur, or set tofalseto permit transparency.
Return Value
An effect that blurs the view.
Discussion
Use blur(radius:opaque:) to apply a gaussian blur effect to the rendering of the view.