public class Masking extends Object
Modifier and Type | Field and Description |
---|---|
static int |
CLOSE_OPEN_MASK
Performs a round of close/open operations when creating a mask.
|
static int |
NO_DUPLICATE
Avoid duplicating the source image when possible.
|
static int |
WHITE_MASK
Treats white pixels are masked.
|
Constructor and Description |
---|
Masking() |
Modifier and Type | Method and Description |
---|---|
static ij.process.ImageProcessor |
applyMask(ij.process.ImageProcessor source,
ij.process.ImageProcessor mask)
Apply a binary mask to another image by performing a AND operation.
|
static ij.process.ImageProcessor |
applyMask(ij.process.ImageProcessor source,
ij.process.ImageProcessor mask,
BinaryOperator operator,
int options)
Apply a binary mask to another image.
|
static ij.process.ImageProcessor |
createMask(ij.process.ImageProcessor processor,
ThresholdingMethod method,
int parameter)
Create a binary mask by thresholding a source image.
|
static ij.process.ImageProcessor |
createMask(ij.process.ImageProcessor processor,
ThresholdingMethod method,
int parameter,
int options)
Creates a binary mask by thresholding a source image.
|
public static final int WHITE_MASK
public static final int CLOSE_OPEN_MASK
public static final int NO_DUPLICATE
public static ij.process.ImageProcessor createMask(ij.process.ImageProcessor processor, ThresholdingMethod method, int parameter, int options)
processor
- the source image to create a mask frommethod
- the thresholding algorithm to applyparameter
- for the ThresholdingMethod.FIXED
method, this is
directly the threshold to apply; for the local thresholding
methods, this is the radius to consider; global thresholding
methods don't use this parameteroptions
- flags to alter the behavior of this method; see constant
fields defined in this classpublic static ij.process.ImageProcessor createMask(ij.process.ImageProcessor processor, ThresholdingMethod method, int parameter)
createMask(ImageProcessor, ThresholdingMethod, int, int)
but uses
the CLOSE_OPEN_MASK flag and does not allow to set other flags.processor
- the source image to create a mask frommethod
- the thresholding algorithm to applyparameter
- for the ThresholdingMethod.FIXED
method, this is
directly the threshold to apply; for the local thresholding
methods, this is the radius to consider; global thresholding
methods don't use this parameterpublic static ij.process.ImageProcessor applyMask(ij.process.ImageProcessor source, ij.process.ImageProcessor mask, BinaryOperator operator, int options)
source
- the image to apply the mask tomask
- the mask to applyoperator
- the binary operator defining the operation to perform with
the maskoptions
- flags to alter the behavior of this method; see constant
fields defined in this classfields defined in this classpublic static ij.process.ImageProcessor applyMask(ij.process.ImageProcessor source, ij.process.ImageProcessor mask)
applyMask(ImageProcessor, ImageProcessor, BinaryOperator, int)
but
with the default AND operation and without any flag.source
- the image to apply the mask tomask
- the mask to applyCopyright © 2021. All rights reserved.