Processing

Processor.AI is a fully integrated pipeline that allows you to upload, transform, optimize, and deliver your media at lightning-fast speeds.

To build a pipeline, append a semicolon to your original source url and a list of processors.

  https://   lightning.accelerator.net/ source bolts.jpeg   ; transform 100x100 format /lossless.webp

Transformations

Resize

x

Resizes and image to the provided height & width.

x

/mountains;

resize(

  • width 200
  • height 200
  • mode ResizeMode
  • anchor CropAnchor

)

.png

x
x

Options

The target width of the output canvas

The target height of the output canvas

The mode used to resize the image

  • Fits the image within the specified dimensions without upscaling or stretching
  • Crops the image to fit within the specified dimensions. Defaults to center. Specify an anchor to override.
  • Crops the image to fit the provided dimensions.
  • Pads the image to fit within the provided dimensions. Combine with a background filter to specify the backend color.
  • Scales the image to the exact dimensions

The anchor used to align the image in crop mode

  • Anchor the image to the top when cropping.
  • Anchor the image to the right when cropping.
  • Anchor the image to the bottom when cropping.
  • Anchor the image to the left when cropping.
  • Anchor the image to the center when cropping.
+ Article + Code + Content + Data

Crop

x

Crops the image to the provided rectangle.

x

/mountains;

crop(

  • x Integer
  • y Integer
  • width Integer
  • height Integer

)

.png

x
x

Options

The x coordinate to begin the crop

The y coordinate to begin the crop

+ Article + Code + Content + Data

Rotate

x

Rotates the image by the provided number of degrees. We automatically orient images containing an EXIF tag. To disable their behavior, include orient(none);

x

/mountains;

rotate(

  • angle Number

)

.png

x
+ Article + Code + Content + Data

Effects & Filters

Blur

x

Applies a Gaussian blur effect to the image.

x

/mountains;

blur(

  • radius Integer

)

.png

x
x

Options

The standard deviation to the Gaussian function

+ Article + Code + Content + Data

Brightness

x

Adjusts the brightness if an image.

x

/mountains;

brightness(

  • amount Number

)

.png

x
x

Options

The brightness adjustment to apply to the image.

+ Article + Code + Content + Data

Contrast

x

Adjusts the contrast of the image. 

x

/mountains;

contrast(

  • amount Number

)

.png

x
x

Options

The contrast adjustment to apply to the image.

+ Article + Code + Content + Data

Grayscale

x

Applies a grayscale filter to the image.

x

/mountains;

grayscale(

  • amount Integer

)

.png

x
x

Options

The percentage of the effect to apply. 0 is unchanged. 1 is fully grayscale.

+ Article + Code + Content + Data

Hue Rotation

x

Rotates the image's hue by the specified number of degrees.

x

/mountains;

rotateHue(

  • degrees Integer

)

.png

x
x
x

Options

The number of degrees, between 0 and 360, to rotate the hue

+ Article + Code + Content + Data

Invert

x

Inverts the colors of an image by the provided percentage.

x

/mountains;

invert(

  • amount Number

)

.png

x
+ Article + Code + Content + Data

Saturate

x

Applies a saturation filter to the image.

x

/mountains;

saturate(

  • amount Number

)

.png

x
x

Options

The amount of saturation to apply to the image

+ Article + Code + Content + Data

Sepia

x

Applies a sepia effect, or reddish-brown tint, to the image.

x

/mountains;

sepia(

  • amount Number

)

.png

x
x

Options

The amount of sepia to apply to the image.

+ Article + Code + Content + Data

Pixelate

x

Pixelates the image.

x

/mountains;

pixelate(

  • amount Integer

)

.png

x
x

Options

+ Article + Code + Content + Data

Format

Quality

x

Sets the quality of the output image.

You can also use the lossless filter when outputting to PNG or WebP.

x

/mountains;

quality(

  • amount Number

)

.png

x
x

Options

The quality

+ Article + Code + Content + Data

Quantize

x

Reduces the number of colors in the output image.

When formatting as a PNG, specifying less 256 or fewer colors will produce an 8 bit PNG.

x

/mountains;

quantize(

  • colorCount Number

)

.png

x
+ Article + Code + Content + Data
x

A pipeline ends with an output format.

format notes
JPEG PNG GIF WebP a b c d
x