AnyImageModifier
public struct AnyImageModifier : ImageModifier
A wrapper for creating an ImageModifier
easier.
This type conforms to ImageModifier
and wraps an image modify block.
If the block
throws an error, the original image will be used.
-
Creates an
AnyImageModifier
with a givenmodify
block.Declaration
Swift
public init(modify: @escaping (Image) throws -> Image)
-
Modify an input
Image
. SeeImageModifier
protocol for more.Declaration
Swift
public func modify(_ image: Image) -> Image