All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class ij.ImagePlus

java.lang.Object
   |
   +----ij.ImagePlus

public class ImagePlus
extends Object
This class that supports five image types: 8, 16 and 32-bit grayscale, 8-bit indexed color, and RGB color.


Variable Index

 o COLOR_256
 o COLOR_RGB
 o GRAY16
 o GRAY32
 o GRAY8
 o HSB
 o reserved
 o RGBA

Constructor Index

 o ImagePlus(String, float[], int, int, ImageJ)
 o ImagePlus(String, Image, ImageJ)
 o ImagePlus(String, int, int, ImageJ)
 o ImagePlus(String, short[], int, int, ImageJ)
 o ImagePlus(String, String, ImageJ)

Method Index

 o createNewRoi(int, int)
 o draw()
Draws image and roi outline.
 o draw(int, int, int, int)
Draws image and roi outline using a clip rect.
 o getDepth()
If this is a stack, return the number of images, else return 1.
 o getHeight()
 o getImage()
Returns the current AWT image.
 o getLUT()
Returns the color look-up table.
 o getMask()
 o getPixel(int, int)
Returns a 4 element array.
 o getProcessor()
Returns a reference to the current ImageProcessor.
 o getRoi()
 o getStack()
 o getStatistics()
 o getTitle()
Returns the image name.
 o getType()
Returns the current image type.
 o getWidth()
 o getWidthFinal()
 o getWindow()
 o isInvertedLut()
Returns true is this is an inverted LUT that displays zero as white.
 o isProcessor()
 o killProcessor()
Removes the current ImageProcessor.
 o killRoi()
Deletes the current region of interest.
 o reserve()
 o setColor(Color)
 o setFileInfo(FileInfo)
Provides information needed to Revert.
 o setImage(float[], int, int, boolean)
Insert 32-bit real image.
 o setImage(Image)
Insert AWT image.
 o setImage(short[], int, int, boolean)
Insert 16-bit image.
 o setRoi(Rectangle)
 o setType(int)
 o setWindow(ImageWindow)
 o show()
Displays this image in a window.
 o unreserve()
 o updateAndDraw()
Creates a new AWT Image from the pixels in the ImageProcessor, then displays it.

Variables

 o GRAY8
 public static final int GRAY8
 o GRAY16
 public static final int GRAY16
 o GRAY32
 public static final int GRAY32
 o COLOR_256
 public static final int COLOR_256
 o COLOR_RGB
 public static final int COLOR_RGB
 o HSB
 public static final int HSB
 o RGBA
 public static final int RGBA
 o reserved
 protected boolean reserved

Constructors

 o ImagePlus
 public ImagePlus(String title,
                  Image img,
                  ImageJ ij)
 o ImagePlus
 public ImagePlus(String title,
                  short pixels[],
                  int width,
                  int height,
                  ImageJ ij)
 o ImagePlus
 public ImagePlus(String title,
                  float pixels[],
                  int width,
                  int height,
                  ImageJ ij)
 o ImagePlus
 public ImagePlus(String title,
                  int width,
                  int height,
                  ImageJ ij)
 o ImagePlus
 public ImagePlus(String title,
                  String urlString,
                  ImageJ ij)

Methods

 o reserve
 public synchronized boolean reserve()
 o unreserve
 public synchronized void unreserve()
 o draw
 public void draw()
Draws image and roi outline.

 o draw
 public void draw(int x,
                  int y,
                  int width,
                  int height)
Draws image and roi outline using a clip rect.

 o updateAndDraw
 public void updateAndDraw()
Creates a new AWT Image from the pixels in the ImageProcessor, then displays it.

 o show
 public void show()
Displays this image in a window.

 o getImage
 public Image getImage()
Returns the current AWT image.

 o setImage
 public void setImage(Image img)
Insert AWT image.

 o setImage
 public void setImage(short pixels16[],
                      int width,
                      int height,
                      boolean whiteIsZero)
Insert 16-bit image.

 o setImage
 public void setImage(float pixels32[],
                      int width,
                      int height,
                      boolean whiteIsZero)
Insert 32-bit real image.

 o setFileInfo
 public void setFileInfo(FileInfo fi)
Provides information needed to Revert.

 o getWindow
 public ImageWindow getWindow()
 o setWindow
 public void setWindow(ImageWindow win)
 o setColor
 public void setColor(Color c)
 o isProcessor
 public boolean isProcessor()
 o getProcessor
 public ImageProcessor getProcessor()
Returns a reference to the current ImageProcessor. If there is no ImageProcessor, it creates one.

 o killProcessor
 public void killProcessor()
Removes the current ImageProcessor.

 o getMask
 public int[] getMask()
 o getStatistics
 public ImageStatistics getStatistics()
 o getTitle
 public String getTitle()
Returns the image name.

 o getWidth
 public int getWidth()
 o getWidthFinal
 public final int getWidthFinal()
 o getHeight
 public int getHeight()
 o getDepth
 public int getDepth()
If this is a stack, return the number of images, else return 1.

 o getType
 public int getType()
Returns the current image type.

 o setType
 protected void setType(int type)
 o getLUT
 public LookUpTable getLUT()
Returns the color look-up table.

 o isInvertedLut
 public boolean isInvertedLut()
Returns true is this is an inverted LUT that displays zero as white.

 o getPixel
 public float[] getPixel(int x,
                         int y)
Returns a 4 element array. Grayscale values are retuned in the first element. RGB values are returned in the first 3 elements. For indexed color images, the index (0-255) is returned in the first element and the RGB values in the last three.

 o getStack
 public Stack getStack()
 o getRoi
 public Roi getRoi()
 o setRoi
 public void setRoi(Rectangle r)
 o createNewRoi
 public void createNewRoi(int x,
                          int y)
 o killRoi
 public void killRoi()
Deletes the current region of interest.


All Packages  Class Hierarchy  This Package  Previous  Next  Index