Fill holes by volume

Performs a volume-limited 3D fill holes operation on an input binary image.

Description

Performs a volume-limited 3D fill holes operation on an input binary image. This operation will change all background pixels in a region which is fully enclosed by foreground pixels to foreground. The volume of holes to be filled can be restricted with both minimum and maximum permissible holes. This image will be 8-bit with binary logic determined by the "Binary logic" parameter. Uses the plugin "MorphoLibJ".

Parameters

ParameterDescription
Input imageImage from workspace to apply fill holes operation to. This image will be 8-bit with binary logic determined by the "Binary logic" parameter.
Apply to input imageWhen selected, the post-operation image will overwrite the input image in the workspace. Otherwise, the image will be saved to the workspace with the name specified by the "Output image" parameter.
Output imageIf "Apply to input image" is not selected, the post-operation image will be saved to the workspace with this name.
Set minimum volumeWhen selected, a minimum permitted volume for binary holes can be set. Any holes with volumes smaller than this value will be removed.
Minimum permitted volumeIf "Set minimum volume" is selected, this is the minimum volume each hole must have for it to be retained. Volumes are specified in units controlled by the "Calibrated units" parameter.
Set maximum volumeWhen selected, a maximum permitted volume for binary holes can be set. Any holes with volumes larger than this value will be removed.
Maximum permitted volumeIf "Set maximum volume" is selected, this is the maximum volume each hole must have for it to be retained. Volumes are specified in units controlled by the "Calibrated units" parameter.
Calibrated unitsWhen selected, hole size limits are assumed to be specified in calibrated units (as defined by the "Input control" parameter "Spatial unit"). Otherwise, pixel units are assumed.
ConnectivityControls which adjacent pixels are considered:
  • "6" Only pixels immediately next to the active pixel are considered. These are the pixels on the four "cardinal" directions plus the pixels immediately above and below the current pixel. If working in 2D, 4-way connectivity is used.
  • "26" In addition to the core 6-pixels, all immediately diagonal pixels are used. If working in 2D, 8-way connectivity is used.
Binary logicControls whether objects are considered to be white (255 intensity) on a black (0 intensity) background, or black on a white background.
Enable multithreadingBreak the image down into strips, each one processed on a separate CPU thread. The overhead required to do this means it's best for large multi-core CPUs, but should be left disabled for small images or on CPUs with few cores.
Minimum strip width (px)Minimum width of each strip to be processed on a separate CPU thread. Measured in pixel units.