bellroy / elm-imgix / ImgIX.Stylize

The stylize parameters allow you to apply basic artistic effects to your images.


type Stylize

The Stylize type

Stylize

duotone : { colorA : ImgIX.Internals.Color.Color, colorB : ImgIX.Internals.Color.Color, alpha : Basics.Float } -> Stylize

Applies a duotone effect—a gradient with two different colors as its endpoints—to the image.

To achieve this effect, the image is first converted to greyscale. Two colors, usually contrasting, are then mapped to that gradient.

ColorA is mapped to the darker parts of the image, and colorB to the lighter parts.

If you were to set a light color as colorA and a dark color as colorB, you would create a duotone with a photo negative effect.

original

original

duotone { colorA: #ff0000, colorB: #00ff00, alpha: 0.2 }

duotone

gaussianBlur : Basics.Int -> Stylize

Applies a Gaussian style blur to your image, smoothing out image noise.

Valid values are in the range from 0 – 2000.

original

original

gaussianBlur 10

gaussianBlur

blur : Basics.Int -> Stylize

Same as gaussianBlur

halftone : Basics.Int -> Stylize

Applies a half-toning effect to the image.

Valid values are in the range 0 – 100. The default value is 0, which leaves the image unchanged. The value represents the width of the halftone dots.

original

original

halftone 10

halftone

monochrome : ImgIX.Internals.Color.Color -> Stylize

Applies an overall monochromatic hue change.

The higher the intensity defined by the alpha channel, the closer you will get to a duotone effect.

original

original

monochrome #33ff0000

monochrome

pixelate : Basics.Int -> Stylize

Applies a square pixellation effect to the image.

Valid values are in the range 0 – 100. The default value is 0, which leaves the image unchanged.

original

original

pixelate 10

pixelate

sepia : Basics.Int -> Stylize

Applies a sepia-toning effect to the image.

Valid values are in the range from 0 – 100. The default value is 0, which leaves the image unchanged.

original

original

sepia 80

sepia

Applying

toQueryParameters : List Stylize -> List Url.Builder.QueryParameter