The image geometry specifies the desired size of the image. It's format is:

  <width>x<height>{%}{!}{<}{>}

By default, the width and height are maximum values. That is, the image is expanded or contracted to fit the width and height value while maintaining the aspect ratio of the image. Append an exclamation point to the geometry to force the image size to exactly the size you specify. For example, if you specify 640x480! the image width is set to 640 pixels and height to 480. If only one factor is specified, both the width and height assume the value.

To specify a percentage width or height instead, append %. The image size is multiplied by the width and height percentages to obtain the final image dimensions. To increase the size of an image, use a value greater than 100 (e.g. 125%). To decrease an image's size, use a percentage less than 100.

Use > to change the dimensions of the image only if its size exceeds the geometry specification. < resizes the image only if its dimensions is less than the geometry specification. For example, if you specify 640x480> and the image size is 512x512, the image size does not change. However, if the image is 1024x1024, it is resized to 640x480.

Use < to change the dimensions of the image only if its size exceeds the geometry specification. > resizes the image only if its dimensions is less than the geometry specification. For example, if you specify 640x480> and the image size is 512x512, the image size does not change. However, if the image is 1024x1024, it is resized to 640x480.

There are 72 dots per inch in PostScript coordinates.

You have your choice of algorithms to resize your image. Choose from these algorithms:

Adaptive Resize
resize image with data dependent triangulation

Liquid Rescale
rescale image with seam carving.

Resize
scale the image using the selected scaling filter, support radius, and blur factor. The default is the Mitchell filter, general overall scaling filter that produces high-quality results. Set the blur factor to > 1.0 for more blurry and < 1.0 for more sharp

Scale
To scale a scanline from x pixels to y pixels, each new pixel represents x/y old pixels. To read x/y pixels, read (x/y rounded up) pixels but only count the required fraction of the last old pixel read in your new pixel. The remainder of the old pixel will be counted in the next new pixel.

Sample
scales image with pixel sampling. This algorithm does no introduce new colors into your image.

Resample
change the resolution of an image

Half Size
half the size of an image using a weighted average of a 4x4 cell centered at each reference pixel. The image geometry is ignored.

Double Size
double the size of an image using bi-linear interpolation. The image

Extent
set the image extent. The pixels scale or location do not change. If the image is enlarged, unfilled areas are set to the background color.

Thumbnail
Create a thumbnail from your image. If there are more than one image, they are tiled on a transparent background as defined by the tile geometry (see the optional scaling attributes).



[comment]