Skip to main content

ImageProcessors.LateResize

Scales an image to a specified size. The getting of the size is offloaded via closure after the image is loaded. The View has time to layout and provide non-zero size.

public struct LateResize: ImageProcessing 

Inheritance

ImageProcessing

Initializers

init(sizeProvider:)

Initializes the processor with size providing closure.

public init(sizeProvider: @escaping () -> CGSize) 

Parameters

  • sizeProvider: Closure to obtain size after the image is loaded.

Properties

identifier

public var identifier: String 

Methods

process(_:)

public func process(_ image: PlatformImage) -> PlatformImage? 

Did you find this page helpful?