Type Method 型メソッド

grayscale(_:)

Returns a filter that applies a grayscale adjustment.

Declaration 宣言

static func grayscale(_ amount: Double) -> GraphicsContext.Filter

Return Value 戻り値

A filter that applies a grayscale adjustment.

Parameters パラメータ

amount

An amount that controls the effect. A value of one makes the image completely gray. A value of zero leaves the result unchanged. Other values apply a linear multiplier effect.

Discussion 議論

This filter is equivalent to the grayscale filter primitive defined by the Scalable Vector Graphics (SVG) specification.

See Also 参照

Manipulating Color