DotScreen

public struct DotScreen: Filter

Simulates the dot patterns of a halftone screen.

let logo = Image("logo")
logo.apply(DotScreen())
canvas.add(logo)
  • The name of the Core Image filter.

    Declaration

    Swift

    public let filterName = "CIDotScreen"
  • The center of the pattern. Defaults to {0,0}

    Declaration

    Swift

    public var center: Point = Point()
  • The width of the dots. Defaults to 2.0

    Declaration

    Swift

    public var width: Double = 2.0
  • The angle of the pattern. Defaults to 0.0

    Declaration

    Swift

    public var angle: Double = 0
  • The sharpness of the edges of the pattern. Defaults to 0.5

    Declaration

    Swift

    public var sharpness: Double = 0.5
  • Initializes a new filter

    Declaration

    Swift

    public init() {}
  • Applies the properties of the receiver to create a new CIFilter object

    Declaration

    Swift

    public func createCoreImageFilter(inputImage: CIImage) -> CIFilter

    Parameters

    inputImage

    The image to use as input to the filter.

    Return Value

    The new CIFilter object.