Crop image

Crop an image in X and Y using pre-defined limits or limits based on the extents of objects in a collection.

Description

Crop an image in X and Y using pre-defined limits or limits based on the extents of objects in a collection. Any pixels outside the specified limits are discarded.

Note: The x-min, y-min, width and height limits used here are in the same order and format as those output by ImageJ's default rectangle region of interest tool (i.e. displayed in the status bar of the ImageJ control panel).

Parameters

ParameterDescription
Input imageImage from workspace to apply crop process to.
Apply to input imageSelect if the crop should be applied directly to the input image, or if it should be applied to a duplicate, then stored as a different image in the workspace.
Output imageName of the output image created during the cropping process if storing the cropped image as a new image in the workspace ("Apply to input image" parameter).
Limits modeControls how the limits for the cropped region are specified:
  • "Fixed values" The input image will be cropped to the region specified by the fixed values, "Left coordinate", "Top coordinate", "Width" and "Height".
  • "Object collection limits" The input image will be cropped to the region corresponding to the limits of the object collection specified by "Input objects"
Left coordinateLeft crop coordinate. All pixels with x-coordinates lower than this will be removed. Specified in pixel units with indexing starting at 0.
Top coordinateTop crop coordinate. All pixels with y-coordinates lower than this will be removed. Specified in pixel units with indexing starting at 0.
WidthWidth (number of columns) of the output cropped region. Specified in pixel units.
HeightHeight (number of rows) of the output cropped region. Specified in pixel units.
Input objectsWhen "Limits mode" is set to "Object collection limits", these are the objects that will be used to define the cropped region.