The image API works via query string parameters.
In order to request images of the correct width, height or processed in other ways, you simply add the relevant parameters to the URL. For example, to stretch to fill a 200 x 200 pixel box, you would use a URL like this:
Blurs the image by a value relative to the image size, between 0 and 100.
The maximum blur radius (r) in pixels which corresponds to a blur value of 100 is calculated using the following formula for the image width (w) and height (h):
For a 640x480 pixel image, a blur value of 100 translates into a blur radius of 80 pixels.
This guarantees that the same blur value will result in the same level of blurriness for the same image at different sizes.
The default blur value is 0 (no blur).
Specifies the device pixel ratio, between 0.1 and 10.0.
Acts as a multiplier for both the width and height. For example, using width=320&height=150&dpr=2 is equivalent to width=640&height=300.
This allows you to easily specify an image with the correct resolution for high dpi devices such as iPhones.
The default DPR is 1.0.
Allows you to specify which part of the image is used.
To crop an image, you specify four parameters – the origin x and y (which defines the top left of the crop rectangle) and the dimensions w and h (which define the size of the rectangle).
Cropping is applied before other transformations. In particular, the crop values refer to the dimensions of the image before it has been resized. Note also that resizing may cause additional cropping of some part of the image if mode=crop is used.
The default mode is fit.
The Saturation parameter refers to the saturation used by the camera when the image was captured.
Adjusts the saturation of the image, with values between -100and 100. A saturation value of -100 turns the image into grayscale.
The default value is 0 (no saturation adjustment).