Filestack Documentation

Class Shadow​Transform

public class ShadowTransform: Transform  

Applies a shadow border effect to the image.

ShadowTransform ShadowTransform Transform Transform ShadowTransform->Transform

Superclass

Transform

:nodoc:

Initializers

init()

public init()  

Initializes a ShadowTransform object.

Methods

blur(_:​)

@discardableResult
    func blur(_ value: Int) -> Self  

Adds the blur option.

Parameters

value Int

Sets the level of blur for the shadow effect. Valid range: 0...20

opacity(_:​)

@discardableResult
    func opacity(_ value: Int) -> Self  

Adds the opacity option.

Parameters

value Int

Sets the opacity level of the shadow effect. Vaid range: 0 to 100

vector(x:​y:​)

@discardableResult
    func vector(x: Int, y: Int) -> Self  

Adds the vector option.

Parameters

x Int

Sets the shadow's X offset. Valid range: -1000 to 1000

y Int

Sets the shadow's Y offset. Valid range: -1000 to 1000

color(_:​)

@discardableResult
    func color(_ value: UIColor) -> Self  

Adds the color option.

Parameters

value UIColor

Sets the shadow color.

background(_:​)

@discardableResult
    func background(_ value: UIColor) -> Self  

Adds the background option.

Parameters

value UIColor

Sets the background color to display behind the image, like a matte the shadow is cast on.