|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectij.io.Opener
public class Opener
Opens tiff (and tiff stacks), dicom, fits, pgm, jpeg, bmp or gif images, and look-up tables, using a file open dialog or a path. Calls HandleExtraFileTypes plugin if the file type is unrecognised.
Field Summary | |
---|---|
static int |
BMP
|
static int |
CUSTOM
|
static int |
DICOM
|
static int |
FITS
|
static int |
GIF
|
static int |
JAVA_OR_TEXT
|
static int |
JPEG
|
static int |
LUT
|
static int |
PGM
|
static int |
PNG
|
static int |
ROI
|
static int |
TEXT
|
static int |
TIFF
|
static int |
TIFF_AND_DICOM
|
static int |
UNKNOWN
|
static int |
ZIP
|
Constructor Summary | |
---|---|
Opener()
|
Method Summary | |
---|---|
static void |
convertGrayJpegTo8Bits(ImagePlus imp)
If this image is grayscale, convert it to 8-bits. |
java.lang.String |
getDir(java.lang.String path)
|
int |
getFileType(java.lang.String path)
Attempts to determine the image file type by looking for 'magic numbers' and the file name extension. |
java.lang.String |
getName(java.lang.String path)
|
static boolean |
getOpenUsingPlugins()
Returns the state of the openUsingPlugins flag. |
void |
open()
Displays a file open dialog box and then opens the tiff, dicom, fits, pgm, jpeg, bmp, gif, lut, roi, or text file selected by the user. |
void |
open(java.lang.String path)
Opens and displays a tiff, dicom, fits, pgm, jpeg, bmp, gif, lut, roi, or text file. |
boolean |
openAndAddToRecent(java.lang.String path)
Opens the specified file and adds it to the File/Open Recent menu. |
ImagePlus |
openImage(java.lang.String path)
Attempts to open the specified file as a tiff, bmp, dicom, fits, pgm, gif or jpeg. |
ImagePlus |
openImage(java.lang.String directory,
java.lang.String name)
Attempts to open the specified file as a tiff, bmp, dicom, fits, pgm, gif or jpeg image. |
void |
openMultiple()
Displays a JFileChooser and then opens the tiff, dicom, fits, pgm, jpeg, bmp, gif, lut, roi, or text files selected by the user. |
Roi |
openRoi(java.lang.String path)
Attempts to open the specified ROI, returning null if unsuccessful. |
ImagePlus |
openTiff(java.io.InputStream in,
java.lang.String name)
Attempts to open the specified inputStream as a TIFF, returning an ImagePlus object if successful. |
ImagePlus |
openTiff(java.lang.String directory,
java.lang.String name)
Attempts to open the specified file as a tiff. |
ImagePlus |
openTiffStack(FileInfo[] info)
Attemps to open a tiff file as a stack. |
ImagePlus |
openURL(java.lang.String url)
Attempts to open the specified url as a tiff, zip compressed tiff, dicom, gif or jpeg. |
static void |
setOpenUsingPlugins(boolean b)
Open all images using HandleExtraFileTypes. |
void |
setSilentMode(boolean mode)
The "Opening: path" status message is not displayed in silent mode. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int UNKNOWN
public static final int TIFF
public static final int DICOM
public static final int FITS
public static final int PGM
public static final int JPEG
public static final int GIF
public static final int LUT
public static final int BMP
public static final int ZIP
public static final int JAVA_OR_TEXT
public static final int ROI
public static final int TEXT
public static final int PNG
public static final int TIFF_AND_DICOM
public static final int CUSTOM
Constructor Detail |
---|
public Opener()
Method Detail |
---|
public void open()
public void openMultiple()
public void open(java.lang.String path)
public boolean openAndAddToRecent(java.lang.String path)
public ImagePlus openImage(java.lang.String directory, java.lang.String name)
public ImagePlus openImage(java.lang.String path)
public ImagePlus openURL(java.lang.String url)
public static void convertGrayJpegTo8Bits(ImagePlus imp)
public ImagePlus openTiffStack(FileInfo[] info)
public ImagePlus openTiff(java.lang.String directory, java.lang.String name)
public ImagePlus openTiff(java.io.InputStream in, java.lang.String name)
public java.lang.String getName(java.lang.String path)
public java.lang.String getDir(java.lang.String path)
public Roi openRoi(java.lang.String path)
public int getFileType(java.lang.String path)
public void setSilentMode(boolean mode)
public static void setOpenUsingPlugins(boolean b)
public static boolean getOpenUsingPlugins()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |