Jimp - Image Processing icon

Jimp - Image Processing

Process images with Jimp - resize, crop, and transform

Ensure Max Size

AI-generated

Summary

Resize an input image to ensure it does not exceed specified maximum width and height dimensions while maintaining the aspect ratio.

Inputs

  • Binary Property (required) — Name of the binary property containing the input image file to be resized.
  • Max Width (required) — Maximum allowed width in pixels; image will be resized if it exceeds this width.
  • Max Height (required) — Maximum allowed height in pixels; image will be resized if it exceeds this height.
  • Output Property Name (required) — Name of the binary property where the resized image will be stored.
  • Options.Resize Algorithm — Algorithm to use for resizing the image, options include Bilinear (default), Bicubic, and Nearest Neighbor.
  • Options.Only Resize If Larger — If true (default), resize operation occurs only if the image exceeds maximum dimensions; if false, smaller images can be upscaled.

Output shape

a single output item with binary data containing the resized image stored under the specified output binary property, plus JSON metadata about original and new dimensions, whether resizing occurred, file size, mime type, and file name.

The output binary image preserves the original mime type and encodes data as base64. The operation respects aspect ratio and uses the selected resize algorithm. By default, images smaller than max dimensions are not upscaled unless 'Only Resize If Larger' is set to false. Errors occurring during image processing terminate the node unless 'Continue On Fail' is enabled.

Discussion