public class ColorImages extends Object
| Modifier and Type | Method and Description | 
|---|---|
static ij.process.ColorProcessor | 
binaryOverlay(ij.process.ByteProcessor refImage,
             ij.process.ImageProcessor binaryMask,
             Color overlayColor,
             double overlayOpacity)
Applies an overlay of a binary image mask onto a grayscale image, using
 the specified color and opacity. 
 | 
static ij.ImagePlus | 
binaryOverlay(ij.ImagePlus imagePlus,
             ij.ImagePlus maskPlus,
             Color color)
Applies an overlay of a binary image mask onto a grayscale or color
 image, using the specified color. 
 | 
static ij.ImagePlus | 
binaryOverlay(ij.ImagePlus refImage,
             ij.ImagePlus binaryMask,
             Color overlayColor,
             double overlayOpacity)
Applies an overlay of a binary image mask onto a 2D or 3D  grayscale image, using
 the specified color and opacity. 
 | 
static ij.process.ImageProcessor | 
binaryOverlay(ij.process.ImageProcessor refImage,
             ij.process.ImageProcessor mask,
             Color color)
Applies an overlay of a binary image mask onto a grayscale or color
 image, using the specified color. 
 | 
static ij.ImageStack | 
binaryOverlay(ij.ImageStack refImage,
             ij.ImageStack mask,
             Color color)
Applies an overlay of a binary image mask onto a grayscale or color
 image, using the specified color. 
 | 
static ij.ImageStack | 
binaryOverlay(ij.ImageStack refImage,
             ij.ImageStack binaryMask,
             Color overlayColor,
             double overlayOpacity)
Computes the overlay of a binary image over a grayscale image, using an
 opacity for the binary layer. 
 | 
static ij.ImagePlus | 
labelMapOverlay(ij.ImagePlus refImage,
               ij.ImagePlus labelMap,
               double overlayOpacity)
Applies an overlay of a label map onto a 2D/3D grayscale image, using
 the specified opacity. 
 | 
static ij.process.ImageProcessor | 
labelMapOverlay(ij.process.ImageProcessor refImage,
               ij.process.ImageProcessor labelMap,
               double overlayOpacity)
Applies an overlay of a label map onto a grayscale image, using
 the specified opacity. 
 | 
static ij.ImageStack | 
labelMapOverlay(ij.ImageStack refImage,
               ij.ImageStack labelMap,
               double overlayOpacity)
Applies an overlay of a label map onto a 3D grayscale image, using
 the specified opacity. 
 | 
static HashMap<String,ij.process.ByteProcessor> | 
mapChannels(ij.process.ImageProcessor image)
Splits the channels of the color image and returns the new ByteImages
 into a Map, using channel names as key. 
 | 
static HashMap<String,ij.ImageStack> | 
mapChannels(ij.ImageStack image)
Splits the channels of the 3D color image into three new instances of
 ImageStack containing ByteProcessors. 
 | 
static ij.process.ColorProcessor | 
mergeChannels(Collection<ij.process.ImageProcessor> channels)
Creates a new ColorProcessor from a collection of three channels. 
 | 
static ij.process.ColorProcessor | 
mergeChannels(ij.process.ImageProcessor red,
             ij.process.ImageProcessor green,
             ij.process.ImageProcessor blue)
Creates a new ColorProcessor from the red, green and blue channels. 
 | 
static ij.ImageStack | 
mergeChannels(ij.ImageStack red,
             ij.ImageStack green,
             ij.ImageStack blue)
Creates a new color ImageStack from the red, green and blue ImageStack
 instances. 
 | 
static void | 
print(ij.process.ColorProcessor image)
Prints the content of the input color image on the console. 
 | 
static Collection<ij.process.ByteProcessor> | 
splitChannels(ij.process.ImageProcessor image)
Splits the channels of the color image into three new instances of
 ByteProcessor. 
 | 
static Collection<ij.ImageStack> | 
splitChannels(ij.ImageStack image)
Splits the channels of the color image into three new instances of
 ByteProcessor. 
 | 
public static final void print(ij.process.ColorProcessor image)
image - the color image to display on the consolepublic static final Collection<ij.process.ByteProcessor> splitChannels(ij.process.ImageProcessor image)
image - the original image, assumed to be a ColorProcessorpublic static final Collection<ij.ImageStack> splitChannels(ij.ImageStack image)
image - the original image, assumed to be a ColorProcessorpublic static final HashMap<String,ij.process.ByteProcessor> mapChannels(ij.process.ImageProcessor image)
 ColorProcessor colorImage = ...
 HashMap<String, ByteProcessor> channels = mapChannels(colorImage);
 ByteProcessor blue = channels.get("blue");
 image - the original image, assumed to be a ColorProcessorpublic static final HashMap<String,ij.ImageStack> mapChannels(ij.ImageStack image)
image - the original image, assumed to be a ColorProcessorpublic static final ij.process.ColorProcessor mergeChannels(Collection<ij.process.ImageProcessor> channels)
channels - a collection containing the red, green and blue channelsIllegalArgumentException - if the collection contains less than three channelspublic static final ij.process.ColorProcessor mergeChannels(ij.process.ImageProcessor red,
                                                            ij.process.ImageProcessor green,
                                                            ij.process.ImageProcessor blue)
red - the image for the red channel (must be a ByteProcessor)green - the image for the green channel (must be a ByteProcessor)blue - the image for the blue channel (must be a ByteProcessor)IllegalArgumentException - if one of the channel is not an instance of ByteProcessorpublic static final ij.ImageStack mergeChannels(ij.ImageStack red,
                                                ij.ImageStack green,
                                                ij.ImageStack blue)
red - the image for the red channel (must contain ByteProcessor instances)green - the image for the green channel (must contain ByteProcessor instances)blue - the image for the blue channel (must contain ByteProcessor instances)IllegalArgumentException - if one of the ImageStack does not contain instances of ByteProcessorpublic static final ij.ImagePlus binaryOverlay(ij.ImagePlus imagePlus,
                                               ij.ImagePlus maskPlus,
                                               Color color)
imagePlus - the original 2D or 3D image used as backgroundmaskPlus - the binary 2D or 3D mask imagecolor - the color used to display overlaypublic static final ij.process.ImageProcessor binaryOverlay(ij.process.ImageProcessor refImage,
                                                            ij.process.ImageProcessor mask,
                                                            Color color)
refImage - the original image used as backgroundmask - the binary mask imagecolor - the color used to display overlaypublic static final ij.ImageStack binaryOverlay(ij.ImageStack refImage,
                                                ij.ImageStack mask,
                                                Color color)
refImage - the original 3D image used as backgroundmask - the binary 3D mask imagecolor - the color used to display overlaypublic static final ij.ImagePlus binaryOverlay(ij.ImagePlus refImage,
                                               ij.ImagePlus binaryMask,
                                               Color overlayColor,
                                               double overlayOpacity)
refImage - the original 2D or 3D image used as backgroundbinaryMask - the binary mask imageoverlayColor - the color used to display overlayoverlayOpacity - the overlay opacity, between 0 and 1.public static final ij.process.ColorProcessor binaryOverlay(ij.process.ByteProcessor refImage,
                                                            ij.process.ImageProcessor binaryMask,
                                                            Color overlayColor,
                                                            double overlayOpacity)
refImage - the original 2D image used as backgroundbinaryMask - the binary mask imageoverlayColor - the color used to display overlayoverlayOpacity - the overlay opacity, between 0 and 1.public static final ij.ImageStack binaryOverlay(ij.ImageStack refImage,
                                                ij.ImageStack binaryMask,
                                                Color overlayColor,
                                                double overlayOpacity)
refImage - the grayscale image used as reference.binaryMask - the binary mask, with non zero values where a overlay must
            occuroverlayColor - the color used for painting overlayoverlayOpacity - the opacity used for painting overlay, between 0 (totally
            transparent) and 1 (totally opaque)public static final ij.ImagePlus labelMapOverlay(ij.ImagePlus refImage,
                                                 ij.ImagePlus labelMap,
                                                 double overlayOpacity)
refImage - the original 2D or 3D image used as backgroundlabelMap - the label map used as overlayoverlayOpacity - the overlay opacity, between 0 and 1.public static final ij.process.ImageProcessor labelMapOverlay(ij.process.ImageProcessor refImage,
                                                              ij.process.ImageProcessor labelMap,
                                                              double overlayOpacity)
refImage - the original 2D image used as backgroundlabelMap - the label map used as overlayoverlayOpacity - the overlay opacity, between 0 and 1.public static final ij.ImageStack labelMapOverlay(ij.ImageStack refImage,
                                                  ij.ImageStack labelMap,
                                                  double overlayOpacity)
refImage - the original 3D image used as backgroundlabelMap - the label map used as overlayoverlayOpacity - the overlay opacity, between 0 and 1.Copyright © 2014–2023 INRA-IJPB Modeling and Digital Imaging lab. All rights reserved.