Package gov.nih.mipav.model.file
Class FileInfoBase
- java.lang.Object
-
- gov.nih.mipav.model.structures.ModelSerialCloneable
-
- gov.nih.mipav.model.file.FileInfoBase
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Cloneable
- Direct Known Subclasses:
FileInfoAfni,FileInfoAnalyze,FileInfoAvi,FileInfoBFLOAT,FileInfoBioRad,FileInfoBMP,FileInfoBRUKER,FileInfoCheshire,FileInfoCOR,FileInfoCZI,FileInfoDicom,FileInfoDM3,FileInfoFits,FileInfoGESigna4X,FileInfoGESigna5X,FileInfoICS,FileInfoInterfile,FileInfoJP2,FileInfoJSON,FileInfoLattice,FileInfoLIFF,FileInfoLSM,FileInfoMagnetomVision,FileInfoMATLAB,FileInfoMedVision,FileInfoMetaImage,FileInfoMGH,FileInfoMicroCat,FileInfoMinc,FileInfoMincHDF,FileInfoMRC,FileInfoNIFTI,FileInfoNRRD,FileInfoOME,FileInfoPARREC,FileInfoPGM,FileInfoPPM,FileInfoRaw,FileInfoSiemensText,FileInfoSPAR,FileInfoSPM,FileInfoSTK,FileInfoSVS,FileInfoTiff,FileInfoTMG,FileInfoTrackVis,FileInfoVista,FileInfoXML,FileInfoZVI
public abstract class FileInfoBase extends ModelSerialCloneable
This structure contains the basic information that describes how the image is stored on disk.Subclasses add additional information which is particular to that image-format.
This class needs work
1. fixing (making consistent what to do when null pointers encountered. see getStartLocation and getUnitsOfMeasure
- Version:
- 0.9 June 30, 1998
- Author:
- Matthew J. McAuliffe, Ph.D.
- See Also:
FileBase, Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classFileInfoBase.AxisOrientationstatic classFileInfoBase.ImageOrientationstatic classFileInfoBase.Modalitystatic classFileInfoBase.Unitstatic classFileInfoBase.UnitTypeEach unit has a unit type with a given base.
-
Field Summary
Fields Modifier and Type Field Description static intANGSTROMSUnit of measurement angstroms.static java.lang.StringANGSTROMS_STRINGString version of units of measurement - angstroms.static intAXIALAxial orientation.protected int[]axisOrientationaxis orientation used to support image ordering and display for medical images.static java.lang.String[]axisOrientationStrArray of axis orientation strings.static intBIOMAGNETIC_IMAGINGImage modality biomagnetic imaging.protected java.lang.StringcameraMakeprotected java.lang.StringcameraModelstatic intCENTIMETERSUnit of measurement centimeters.static java.lang.StringCENTIMETERS_STRINGString version of units of measurement - centimeters.static intCOLOR_FLOW_DOPPLERImage modality color flow doppler.static intCOMPRESSION_BZIP2Indicates bzip2 compression of an image.static intCOMPRESSION_GZIPIndicates gzip compression of an image.static intCOMPRESSION_NONEIndicates no compression.static intCOMPRESSION_ZIPIndicates zip compression of an image.private intcompressionTypeUsed to indicate if the raw data was also compression (0 = no, 1 = zip).static intCOMPUTED_RADIOGRAPHYImage modality CR.static intCOMPUTED_TOMOGRAPHYImage modality CT.static double[]conversionSpaceTimeUnitsDeprecated.should use enum conversionsstatic intCORONALCoronal orientation.private intdataTypeThe data type of the data (i.e. byte, short, float ...static intDEGREESstatic java.lang.StringDEGREES_STRINGString version of units of measurement - degrees.static intDIAPHANOGRAPHYImage modality diaphanography.static intDIGITAL_RADIOGRAPHYImage modality digital radiography.private float[]dimResolutionsPixel or voxel resolutions for each dimension - default = 1.0.static intDUPLEX_DOPPLERImage modality duplex doppler.private booleanendianessThe Endianess of the data.static intENDOSCOPYImage modality endoscopy.protected doubleexposureTimeprivate int[]extentsImage extents as decribed by the image file format.static intEXTERNAL_CAMERA_PHOTOGRAPHYImage modality external camera photography.static intFAImage modality Fluorescein Angiography.private intfileFormatFile format as defined in the Filebase.protected java.lang.StringfileNameThe file name which includes the path information.protected java.lang.StringfileSuffixFile suffix (ex.protected doubleFNumberprotected doublefocalLengthprotected doublefocalLength35static intGENERAL_MICROSCOPYImage modality general microscopy.static intHARDCOPYImage modality hard copy.static intHOURSUnit of measurement hours.static java.lang.StringHOURS_STRINGString version of units of measurement - hours.static intHZUnit of measurement hertz.static java.lang.StringHZ_STRINGString version of units of measurement - hertz.static intICGImage modality IndoCyanine Green.protected intimageOrientationIndicates the image orientation (i.e.private static java.lang.String[]imageOrientationStrArray of image orientation strings.static intINCHESUnit of measurement inches.static java.lang.StringINCHES_STRINGString version of units of measurement - inches.static intINTRAORAL_RADIOGRAPHYImage modality intraoral radiography.protected doubleISOSpeedRatingstatic intKILOMETERSUnit of measurement kilometers.static java.lang.StringKILOMETERS_STRINGString version of units of measurement - kilometers.static intLASER_SURFACE_SCANImage modality laser surface scan.private ModelLUTlutModelLUT associated with fileinfostatic intMAGNETIC_RESONANCEImage modality MR.static intMAGNETIC_RESONANCE_ANGIOGRAPHYImage modality MR angiography.static intMAGNETIC_RESONANCE_SPECTROSCOPYImage modality MR SPECT.static intMAMMOGRAPHYImage modality mammography.private doublemaxImage maximum intensity for single channel image.private doublemaxBImage maximum intensity for the blue channel of an RGB image.private doublemaxGImage maximum intensity for the green channel of an RGB image.private doublemaxRImage maximum intensity for the red channel of an RGB image.static intMETERSUnit of measurement meters.static java.lang.StringMETERS_STRINGString version of units of measurement - meters.static intMICROMETERSUnit of measurement micrometers.static java.lang.StringMICROMETERS_STRINGString version of units of measurement - micrometers.static intMICROSECUnit of measurement microseconds.static java.lang.StringMICROSEC_STRINGString version of units of measurement - microseconds.static intMILESUnit of measurement miles.static java.lang.StringMILES_STRINGString version of units of measurement - miles.static intMILLIMETERSUnit of measurement millimeters.static java.lang.StringMILLIMETERS_STRINGString version of units of measurement - millimeters.static intMILLISECUnit of measurement milliseconds.static java.lang.StringMILLISEC_STRINGString version of units of measurement - milliseconds.static intMILSUnits of measurement mil (thousandth of an inch)static java.lang.StringMILS_STRINGString version of units of measurement - mils.private doubleminImage minimum intensity for single channel image.private doubleminBImage minimum intensity for the blue channel of an RGB image.private doubleminGImage minimum intensity for the green channel of an RGB image.private doubleminRImage minimum intensity for the red channel of an RGB image.static intMINUTESUnit of measurement minutes.static java.lang.StringMINUTES_STRINGString version of units of measurement - minutes.protected intmodalityIndicates the modality (medical image type) of the dataset.private static java.lang.String[]modalityStrDeprecated.No longer needed since enum works nowprivate booleanmultiFileFlag that indicates whether or not the image is in multiple files (tiff).static intNANOMETERSUnit of measurement nanometers.static java.lang.StringNANOMETERS_STRINGString version of units of measurement - nanometers.static intNANOSECUnit of measurement nanoseconds.static java.lang.StringNANOSEC_STRINGString version of units of measurement - nanoseconds.static intNUCLEAR_MEDICINEImage modality nuclear medicine.private intoffsetNumber of bytes to the start the image data - ie. the header lengthstatic intORI_A2P_TYPEAxis orientation Anterior to Posterior.static intORI_I2S_TYPEAxis orientation Inferior to Superior.static intORI_L2R_TYPEAxis orientation Left to Right.static intORI_P2A_TYPEAxis orientation Posterior to Anterior.static intORI_R2L_TYPEAxis orientation Right to Left.static intORI_S2I_TYPEAxis orientation Superior to Inferior.static intORI_UNKNOWN_TYPEAxis orientation unknown.protected float[]originThe origin to support image locations (ie.private booleanoriginalEndianessUsed for checking for endianess changes in the ModelImage.reallocate(final int type) function.static intOTHERImage modality other.static intPANORAMIC_XRAYImage modality panoramtic X ray.private shortphotometricImage minimum intensity for single channel image.private java.lang.ShortpixelPadValueSome file formats have a pad value for pixels outside the acquisition domain.static intPOSITRON_EMISSION_TOMOGRAPHYImage modality PET.static intPPMUnit of measurement part-per-million.static java.lang.StringPPM_STRINGString version of units of measurement - part-per-million.static intRADIO_FLUOROSCOPYImage modality radio fluoroscopy.static intRADIOGRAPHIC_IMAGINGImage modality radiographic imaging.static intRADIOTHERAPY_DOSEImage modality radiotherapy dose.static intRADIOTHERAPY_IMAGEImage modality radiotherapy image.static intRADIOTHERAPY_PLANImage modality radiotherapy plan.static intRADIOTHERAPY_RECORDImage modality radiotherapy record.static intRADIOTHERAPY_STRUCTURE_SETImage modality radiotherapy structure set.static intRADSRadians per second.static java.lang.StringRADS_STRINGString version of units of measurement - radians per second.static intRED_FREEImage modality Red Free.private doublerescaleInterceptDICOM images have a rescale y-intercept value that we have also kept in the base.private doublerescaleSlopeDICOM images have a rescale slope value that we have also kept in the base.static intSAGITTALSagittal orientation.static intSECONDSUnit of measurement seconds.static java.lang.StringSECONDS_STRINGString version of units of measurement - seconds.private static longserialVersionUIDUse serialVersionUID for interoperability.static intSINGLE_PHOTON_EMISSION_COMPUTED_TOMOGRAPHYImage modality SPECT.private floatsliceThicknessThe thickness of individual slices in the image volume.static intSLIDE_MICROSCOPYImage modality slide microscopy.static java.lang.String[]sUnitsDeprecated.protected java.util.Vector<java.lang.String>tagDescriptionprotected java.util.Vector<java.lang.String>tagNamestatic intTHERMOGRAPHYImage modality thermography.static intTRANSFORM_ANOTHER_DATASETAnother Dataset transform ID.static intTRANSFORM_MNI_152MNI 152 transform ID.static intTRANSFORM_SCANNER_ANATOMICALScanner Anatomical transform ID.static intTRANSFORM_TALAIRACH_TOURNOUXTalairach Tournoux transform ID.static intTRANSFORM_UNKNOWNUnknown transform ID.static java.lang.String[]tUnitsDeprecated.static intULTRASOUNDImage modality ultrasound.protected FileInfoBase.Unit[]unitsOfMeasureDescribes the units of measure for the dataset.static intUNKNOWN_MEASUREUnit of measurement unknown.static intUNKNOWN_MODALITYImage modality unknown.static intUNKNOWN_ORIENTUnknown orientation.static java.lang.StringUNKNOWN_STRINGString version of units of measurement - unknown.static intXRAY_ANGIOGRAPHYImage modality X ray angiography.
-
Constructor Summary
Constructors Modifier Constructor Description protectedFileInfoBase(FileInfoBase copy)Internal constructor for clone usage.FileInfoBase(java.lang.String name, java.lang.String directory, int format)fileInfo constructor.
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static voidcopyCoreInfo(FileInfoBase[] originalInfo, FileInfoBase[] newInfo)Helper method to copy important file info type to another file info type.static voidcopyCoreInfo(FileInfoBase[] originalInfo, FileInfoBase[] newInfo, boolean[] listNoCopy)Helper method to copy core information from one fileinfo into another, this method also has a list of fileinfos NOT to copy (used by JDialogRemoveSlices).voiddisplayAboutInfo(JDialogBase dialog)Displays the file information.abstract voiddisplayAboutInfo(JDialogBase dialog, TransMatrix matrix)Abstract method which is used by the extending class to display information about the window.voiddisplayPrimaryInfo(JDialogText dialog, TransMatrix matrix)Method called by many extending classes to display basic information in the dialog common to all images.voidfinalize()Prepares this class for cleanup.java.lang.StringgetAboutInfo(TransMatrix matrix)Abstract method which is used by the extending class to return information about the file header.static int[]getAllSameDimUnits(int measure)Deprecated.should now use enumjava.lang.StringgetAreaUnitsOfMeasureStr()Returns the area unit for the data.int[]getAxisDirection()Get the direction for accessing each axis of data.int[]getAxisOrientation()Returns orientation of each axis.intgetAxisOrientation(int axis)Returns orientation of entered axis.static intgetAxisOrientationFromStr(java.lang.String s)Returns the axis orientation associated with a string.static java.lang.StringgetAxisOrientationStr(int m)Return the string associated with an axis orientation.java.lang.StringgetCameraMake()java.lang.StringgetCameraModel()intgetCompressionType()Gets the compression type.intgetDataType()Returns data type.static intgetDataTypeFromStr(java.lang.String s)Returns the image data type associated with a string.booleangetEndianess()Descibes file endianess.static booleangetEndianessFromStr(java.lang.String s)Returns the endianess associated with a string.doublegetExposureTime()int[]getExtents()Returns the dimensionality of the image.java.lang.StringgetFileDirectory()Returns counter to start of image data.intgetFileFormat()Returns file format.java.lang.StringgetFileName()Returns the file name.java.lang.StringgetFileSuffix()Returns the file suffix.doublegetFNumber()doublegetFocalLength()doublegetFocalLength35()intgetImageOrientation()Returns the image orientation.static intgetImageOrientationFromStr(java.lang.String s)Returns the image orientation associated with a string.static java.lang.StringgetImageOrientationStr(int m)Return the string associated with an image orientation.booleangetIs2_5D()Return whether or not the image's slices are time based.doublegetISOSpeedRating()float[]getLPSOrigin()DOCUMENT ME!ModelLUTgetLUT()Returns the LUT.doublegetMax()Returns max pixel value of the image.doublegetMaxB()Returns max blue pixel value of the image.doublegetMaxG()Returns max green pixel value of the image.doublegetMaxR()Returns max red pixel value of the image.doublegetMin()Returns min pixel value of the image.doublegetMinB()Returns min blue pixel value of the image.doublegetMinG()Returns min green pixel value of the image.doublegetMinR()Returns min red pixel value of the image.intgetModality()Returns the modality.static intgetModalityFromStr(java.lang.String s)Returns the modality associated with a string.static java.lang.String[]getModalityStr()Return all the modality strings as an array.static java.lang.StringgetModalityStr(int m)Return the string associated with a modality.booleangetMultiFile()Returns whether or not the image is in multiple files (tiff).static intgetNumOfBytesPerPixel(int dataType)Returns the number of bytes per pixel based on the data type.intgetOffset()Returns the header offset.float[]getOrigin()Returns the origin.floatgetOrigin(int axis)Returns the origin value of the requested axis.booleangetOriginalEndianess()float[]getOriginAtSlice(int slice)Gets the origin of a particular slice; resets for the z dimension.shortgetPhotometric()Photometric interpretion.java.lang.ShortgetPixelPadValue()Returns pixel pad value.java.lang.StringgetPrimaryInfo(TransMatrix matrix)Method called by many extending classes to return basic information in the dialog common to all images.doublegetRescaleIntercept()Returns the intercept.doublegetRescaleSlope()Returns the slope.floatgetResolution(int dim)Returns the resolution of the requested dimension.float[]getResolutions()Returns each dimension's resolution.intgetSize()Returns the size of the slice image in byte which represented by this object.floatgetSliceThickness()Returns the thickness of the image slices.int[]getUnitsOfMeasure()Returns the units of measure.intgetUnitsOfMeasure(int dim)Returns the units of measure for the given dimension.static java.lang.String[]getUnitsOfMeasureAbbrevStr()Deprecated.should now use enumstatic java.lang.StringgetUnitsOfMeasureAbbrevStr(int i)Deprecated.should now use enumstatic intgetUnitsOfMeasureFromStr(java.lang.String selectedOutput)Deprecated.should now use enumstatic java.lang.String[]getUnitsOfMeasureStr()Deprecated.should use enumstatic java.lang.StringgetUnitsOfMeasureStr(int xUnits)Deprecated.should now use enumjava.lang.StringgetVolumeUnitsOfMeasureStr()Returns the volume unit for the data.booleanisDicomOrdered()isDicomOrdered() returns true if the file is in dicom order, false otherwise.static intoppositeOrient(int orient)Helper method that returns the opposite axis orientation of the one sent in; that is, R2L for L2R, A2P for P2A, etc.static booleansameAxis(int axisA, int axisB)Helper method to determine if axis A and axis B are the same axis: that is, if both are the patient x-axis, they will be either R2L or L2R.voidsetAxisOrientation(int[] axOrient)Sets (copies) orientation of each axis.voidsetAxisOrientation(int axOrient, int axis)Sets the image orientation in the specified axis.voidsetCameraMake(java.lang.String cameraMake)voidsetCameraModel(java.lang.String cameraModel)voidsetCompressionType(int type)Sets the compression type.voidsetDataType(int type)Sets format of image data.voidsetEndianess(boolean endness)Describes file endianess.voidsetExposureTime(double exposureTime)voidsetExtents(int[] dims)Sets dimensionality of the images.voidsetExtents(int extent, int dim)Sets dimensionality for image, on a per dimension basis.voidsetFileDirectory(java.lang.String directory)DOCUMENT ME!voidsetFileFormat(int format)Sets the file format.voidsetFileName(java.lang.String fname)Sets the file name.voidsetFileSuffix(java.lang.String suffix)Sets the file suffix.voidsetFNumber(double FNumber)voidsetFocalLength(double focalLength)voidsetFocalLength35(double focalLength35)voidsetImageOrientation(int orient)Sets the image orientation.voidsetISOSpeedRating(double ISOSpeedRating)voidsetLUT(ModelLUT lut)Sets the model lutvoidsetMax(double Max)Sets max pixel value of image.voidsetMaxB(double Max)Sets max blue pixel value of image.voidsetMaxG(double Max)Sets max green pixel value of image.voidsetMaxR(double Max)Sets max red pixel value of image.voidsetMin(double Min)Sets min pixel value of image.voidsetMinB(double Min)Sets min blue pixel value of image.voidsetMinG(double Min)Sets min green pixel value of image.voidsetMinR(double Min)Sets min red pixel value of image.voidsetModality(int mod)Sets the modality.voidsetMultiFile(boolean flag)Sets the flag for multiple files.voidsetOffset(int off)Sets the header offset.voidsetOrigin(float[] originlocat)Sets the origin.voidsetOrigin(float originCoord, int axis)Sets the start location in the specified axis. creates the startLocations if the arrray has not yet been created.voidsetOriginalEndianess(boolean originalEndness)voidsetPhotometric(short value)Sets photometric interpretation.voidsetPixelPadValue(java.lang.Short value)Sets pixel pad value: used in some Dicom images.voidsetRescaleIntercept(double intercept)Sets the rescale intercept.voidsetRescaleSlope(double slope)Sets the rescale slope.voidsetResolutions(float[] resolutions)Sets the resolutions of the image.voidsetResolutions(float resolution, int dim)Sets the resolutions of the image, on a per dimension basis.voidsetSliceThickness(float thickness)Sets the thickness of the image slices.voidsetTagDescription(java.util.Vector<java.lang.String> tagDescription)voidsetTagName(java.util.Vector<java.lang.String> tagName)voidsetUnitsOfMeasure(int[] unitMeasure)Sets (copies) units of measure for image.voidsetUnitsOfMeasure(int unitMeasure, int dim)Sets units of measure for image, on a per dimension basis.voidsetUnitsOfMeasure(FileInfoBase.Unit[] unitMeasure)Sets (copies) units of measure for image.voidsetUnitsOfMeasure(FileInfoBase.Unit unitMeasure, int dim)Sets units of measure for image, on a per dimension basis.java.lang.StringtoString()Gives the information contained in FileInfo in a string.-
Methods inherited from class gov.nih.mipav.model.structures.ModelSerialCloneable
clone, nativeClone
-
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
Use serialVersionUID for interoperability.- See Also:
- Constant Field Values
-
sUnits
public static final java.lang.String[] sUnits
Deprecated.Array of space units: inches, mm, etc.
-
tUnits
public static final java.lang.String[] tUnits
Deprecated.Array of time units: seconds, minutes, etc.
-
UNKNOWN_MEASURE
public static final int UNKNOWN_MEASURE
Unit of measurement unknown.- See Also:
- Constant Field Values
-
INCHES
public static final int INCHES
Unit of measurement inches.- See Also:
- Constant Field Values
-
MILS
public static final int MILS
Units of measurement mil (thousandth of an inch)- See Also:
- Constant Field Values
-
CENTIMETERS
public static final int CENTIMETERS
Unit of measurement centimeters.- See Also:
- Constant Field Values
-
ANGSTROMS
public static final int ANGSTROMS
Unit of measurement angstroms.- See Also:
- Constant Field Values
-
NANOMETERS
public static final int NANOMETERS
Unit of measurement nanometers.- See Also:
- Constant Field Values
-
MICROMETERS
public static final int MICROMETERS
Unit of measurement micrometers.- See Also:
- Constant Field Values
-
MILLIMETERS
public static final int MILLIMETERS
Unit of measurement millimeters.- See Also:
- Constant Field Values
-
METERS
public static final int METERS
Unit of measurement meters.- See Also:
- Constant Field Values
-
KILOMETERS
public static final int KILOMETERS
Unit of measurement kilometers.- See Also:
- Constant Field Values
-
MILES
public static final int MILES
Unit of measurement miles.- See Also:
- Constant Field Values
-
NANOSEC
public static final int NANOSEC
Unit of measurement nanoseconds.- See Also:
- Constant Field Values
-
MICROSEC
public static final int MICROSEC
Unit of measurement microseconds.- See Also:
- Constant Field Values
-
MILLISEC
public static final int MILLISEC
Unit of measurement milliseconds.- See Also:
- Constant Field Values
-
SECONDS
public static final int SECONDS
Unit of measurement seconds.- See Also:
- Constant Field Values
-
MINUTES
public static final int MINUTES
Unit of measurement minutes.- See Also:
- Constant Field Values
-
HOURS
public static final int HOURS
Unit of measurement hours.- See Also:
- Constant Field Values
-
HZ
public static final int HZ
Unit of measurement hertz.- See Also:
- Constant Field Values
-
PPM
public static final int PPM
Unit of measurement part-per-million.- See Also:
- Constant Field Values
-
RADS
public static final int RADS
Radians per second.- See Also:
- Constant Field Values
-
DEGREES
public static final int DEGREES
- See Also:
- Constant Field Values
-
UNKNOWN_STRING
public static final java.lang.String UNKNOWN_STRING
String version of units of measurement - unknown.- See Also:
- Constant Field Values
-
INCHES_STRING
public static final java.lang.String INCHES_STRING
String version of units of measurement - inches.- See Also:
- Constant Field Values
-
MILS_STRING
public static final java.lang.String MILS_STRING
String version of units of measurement - mils.- See Also:
- Constant Field Values
-
CENTIMETERS_STRING
public static final java.lang.String CENTIMETERS_STRING
String version of units of measurement - centimeters.- See Also:
- Constant Field Values
-
ANGSTROMS_STRING
public static final java.lang.String ANGSTROMS_STRING
String version of units of measurement - angstroms.- See Also:
- Constant Field Values
-
NANOMETERS_STRING
public static final java.lang.String NANOMETERS_STRING
String version of units of measurement - nanometers.- See Also:
- Constant Field Values
-
MICROMETERS_STRING
public static final java.lang.String MICROMETERS_STRING
String version of units of measurement - micrometers.- See Also:
- Constant Field Values
-
MILLIMETERS_STRING
public static final java.lang.String MILLIMETERS_STRING
String version of units of measurement - millimeters.- See Also:
- Constant Field Values
-
METERS_STRING
public static final java.lang.String METERS_STRING
String version of units of measurement - meters.- See Also:
- Constant Field Values
-
KILOMETERS_STRING
public static final java.lang.String KILOMETERS_STRING
String version of units of measurement - kilometers.- See Also:
- Constant Field Values
-
MILES_STRING
public static final java.lang.String MILES_STRING
String version of units of measurement - miles.- See Also:
- Constant Field Values
-
NANOSEC_STRING
public static final java.lang.String NANOSEC_STRING
String version of units of measurement - nanoseconds.- See Also:
- Constant Field Values
-
MICROSEC_STRING
public static final java.lang.String MICROSEC_STRING
String version of units of measurement - microseconds.- See Also:
- Constant Field Values
-
MILLISEC_STRING
public static final java.lang.String MILLISEC_STRING
String version of units of measurement - milliseconds.- See Also:
- Constant Field Values
-
SECONDS_STRING
public static final java.lang.String SECONDS_STRING
String version of units of measurement - seconds.- See Also:
- Constant Field Values
-
MINUTES_STRING
public static final java.lang.String MINUTES_STRING
String version of units of measurement - minutes.- See Also:
- Constant Field Values
-
HOURS_STRING
public static final java.lang.String HOURS_STRING
String version of units of measurement - hours.- See Also:
- Constant Field Values
-
HZ_STRING
public static final java.lang.String HZ_STRING
String version of units of measurement - hertz.- See Also:
- Constant Field Values
-
PPM_STRING
public static final java.lang.String PPM_STRING
String version of units of measurement - part-per-million.- See Also:
- Constant Field Values
-
RADS_STRING
public static final java.lang.String RADS_STRING
String version of units of measurement - radians per second.- See Also:
- Constant Field Values
-
DEGREES_STRING
public static final java.lang.String DEGREES_STRING
String version of units of measurement - degrees.- See Also:
- Constant Field Values
-
conversionSpaceTimeUnits
public static final double[] conversionSpaceTimeUnits
Deprecated.should use enum conversionsConverting between space units. Conversion is to millimeters (the default). Table converts to mm by multiplication. Converts from mm by division. Example: inches * 25.4f = mm mm / 25.4f = inches. Converting between time units. Conversion is to seconds(the default). Table converts to seconds by multiplication. Converts from seconds by division. Example: minutes * 0.01667 = seconds seconds / 0.01667 = minutes. Hertz and radians per second convert to/from hz. parts-per-million does not convert.
-
UNKNOWN_MODALITY
public static final int UNKNOWN_MODALITY
Image modality unknown.- See Also:
- Constant Field Values
-
BIOMAGNETIC_IMAGING
public static final int BIOMAGNETIC_IMAGING
Image modality biomagnetic imaging.- See Also:
- Constant Field Values
-
COLOR_FLOW_DOPPLER
public static final int COLOR_FLOW_DOPPLER
Image modality color flow doppler.- See Also:
- Constant Field Values
-
COMPUTED_RADIOGRAPHY
public static final int COMPUTED_RADIOGRAPHY
Image modality CR.- See Also:
- Constant Field Values
-
COMPUTED_TOMOGRAPHY
public static final int COMPUTED_TOMOGRAPHY
Image modality CT.- See Also:
- Constant Field Values
-
DUPLEX_DOPPLER
public static final int DUPLEX_DOPPLER
Image modality duplex doppler.- See Also:
- Constant Field Values
-
DIAPHANOGRAPHY
public static final int DIAPHANOGRAPHY
Image modality diaphanography.- See Also:
- Constant Field Values
-
DIGITAL_RADIOGRAPHY
public static final int DIGITAL_RADIOGRAPHY
Image modality digital radiography.- See Also:
- Constant Field Values
-
ENDOSCOPY
public static final int ENDOSCOPY
Image modality endoscopy.- See Also:
- Constant Field Values
-
GENERAL_MICROSCOPY
public static final int GENERAL_MICROSCOPY
Image modality general microscopy.- See Also:
- Constant Field Values
-
HARDCOPY
public static final int HARDCOPY
Image modality hard copy.- See Also:
- Constant Field Values
-
INTRAORAL_RADIOGRAPHY
public static final int INTRAORAL_RADIOGRAPHY
Image modality intraoral radiography.- See Also:
- Constant Field Values
-
LASER_SURFACE_SCAN
public static final int LASER_SURFACE_SCAN
Image modality laser surface scan.- See Also:
- Constant Field Values
-
MAGNETIC_RESONANCE_ANGIOGRAPHY
public static final int MAGNETIC_RESONANCE_ANGIOGRAPHY
Image modality MR angiography.- See Also:
- Constant Field Values
-
MAMMOGRAPHY
public static final int MAMMOGRAPHY
Image modality mammography.- See Also:
- Constant Field Values
-
MAGNETIC_RESONANCE
public static final int MAGNETIC_RESONANCE
Image modality MR.- See Also:
- Constant Field Values
-
MAGNETIC_RESONANCE_SPECTROSCOPY
public static final int MAGNETIC_RESONANCE_SPECTROSCOPY
Image modality MR SPECT.- See Also:
- Constant Field Values
-
NUCLEAR_MEDICINE
public static final int NUCLEAR_MEDICINE
Image modality nuclear medicine.- See Also:
- Constant Field Values
-
OTHER
public static final int OTHER
Image modality other.- See Also:
- Constant Field Values
-
POSITRON_EMISSION_TOMOGRAPHY
public static final int POSITRON_EMISSION_TOMOGRAPHY
Image modality PET.- See Also:
- Constant Field Values
-
PANORAMIC_XRAY
public static final int PANORAMIC_XRAY
Image modality panoramtic X ray.- See Also:
- Constant Field Values
-
RADIO_FLUOROSCOPY
public static final int RADIO_FLUOROSCOPY
Image modality radio fluoroscopy.- See Also:
- Constant Field Values
-
RADIOGRAPHIC_IMAGING
public static final int RADIOGRAPHIC_IMAGING
Image modality radiographic imaging.- See Also:
- Constant Field Values
-
RADIOTHERAPY_DOSE
public static final int RADIOTHERAPY_DOSE
Image modality radiotherapy dose.- See Also:
- Constant Field Values
-
RADIOTHERAPY_IMAGE
public static final int RADIOTHERAPY_IMAGE
Image modality radiotherapy image.- See Also:
- Constant Field Values
-
RADIOTHERAPY_PLAN
public static final int RADIOTHERAPY_PLAN
Image modality radiotherapy plan.- See Also:
- Constant Field Values
-
RADIOTHERAPY_RECORD
public static final int RADIOTHERAPY_RECORD
Image modality radiotherapy record.- See Also:
- Constant Field Values
-
RADIOTHERAPY_STRUCTURE_SET
public static final int RADIOTHERAPY_STRUCTURE_SET
Image modality radiotherapy structure set.- See Also:
- Constant Field Values
-
SLIDE_MICROSCOPY
public static final int SLIDE_MICROSCOPY
Image modality slide microscopy.- See Also:
- Constant Field Values
-
SINGLE_PHOTON_EMISSION_COMPUTED_TOMOGRAPHY
public static final int SINGLE_PHOTON_EMISSION_COMPUTED_TOMOGRAPHY
Image modality SPECT.- See Also:
- Constant Field Values
-
THERMOGRAPHY
public static final int THERMOGRAPHY
Image modality thermography.- See Also:
- Constant Field Values
-
ULTRASOUND
public static final int ULTRASOUND
Image modality ultrasound.- See Also:
- Constant Field Values
-
XRAY_ANGIOGRAPHY
public static final int XRAY_ANGIOGRAPHY
Image modality X ray angiography.- See Also:
- Constant Field Values
-
EXTERNAL_CAMERA_PHOTOGRAPHY
public static final int EXTERNAL_CAMERA_PHOTOGRAPHY
Image modality external camera photography.- See Also:
- Constant Field Values
-
RED_FREE
public static final int RED_FREE
Image modality Red Free.- See Also:
- Constant Field Values
-
FA
public static final int FA
Image modality Fluorescein Angiography.- See Also:
- Constant Field Values
-
ICG
public static final int ICG
Image modality IndoCyanine Green.- See Also:
- Constant Field Values
-
modalityStr
private static final java.lang.String[] modalityStr
Deprecated.No longer needed since enum works nowArray of modality strings -- again, numbering starts at 1, not 0.
-
ORI_UNKNOWN_TYPE
public static final int ORI_UNKNOWN_TYPE
Axis orientation unknown.- See Also:
- Constant Field Values
-
ORI_R2L_TYPE
public static final int ORI_R2L_TYPE
Axis orientation Right to Left.- See Also:
- Constant Field Values
-
ORI_L2R_TYPE
public static final int ORI_L2R_TYPE
Axis orientation Left to Right.- See Also:
- Constant Field Values
-
ORI_P2A_TYPE
public static final int ORI_P2A_TYPE
Axis orientation Posterior to Anterior.- See Also:
- Constant Field Values
-
ORI_A2P_TYPE
public static final int ORI_A2P_TYPE
Axis orientation Anterior to Posterior.- See Also:
- Constant Field Values
-
ORI_I2S_TYPE
public static final int ORI_I2S_TYPE
Axis orientation Inferior to Superior.- See Also:
- Constant Field Values
-
ORI_S2I_TYPE
public static final int ORI_S2I_TYPE
Axis orientation Superior to Inferior.- See Also:
- Constant Field Values
-
axisOrientationStr
public static final java.lang.String[] axisOrientationStr
Array of axis orientation strings.
-
AXIAL
public static final int AXIAL
Axial orientation.- See Also:
- Constant Field Values
-
CORONAL
public static final int CORONAL
Coronal orientation.- See Also:
- Constant Field Values
-
SAGITTAL
public static final int SAGITTAL
Sagittal orientation.- See Also:
- Constant Field Values
-
UNKNOWN_ORIENT
public static final int UNKNOWN_ORIENT
Unknown orientation.- See Also:
- Constant Field Values
-
imageOrientationStr
private static final java.lang.String[] imageOrientationStr
Array of image orientation strings.
-
TRANSFORM_UNKNOWN
public static final int TRANSFORM_UNKNOWN
Unknown transform ID.- See Also:
- Constant Field Values
-
TRANSFORM_SCANNER_ANATOMICAL
public static final int TRANSFORM_SCANNER_ANATOMICAL
Scanner Anatomical transform ID.- See Also:
- Constant Field Values
-
TRANSFORM_ANOTHER_DATASET
public static final int TRANSFORM_ANOTHER_DATASET
Another Dataset transform ID.- See Also:
- Constant Field Values
-
TRANSFORM_TALAIRACH_TOURNOUX
public static final int TRANSFORM_TALAIRACH_TOURNOUX
Talairach Tournoux transform ID.- See Also:
- Constant Field Values
-
TRANSFORM_MNI_152
public static final int TRANSFORM_MNI_152
MNI 152 transform ID.- See Also:
- Constant Field Values
-
COMPRESSION_NONE
public static final int COMPRESSION_NONE
Indicates no compression.- See Also:
- Constant Field Values
-
COMPRESSION_ZIP
public static final int COMPRESSION_ZIP
Indicates zip compression of an image.- See Also:
- Constant Field Values
-
COMPRESSION_GZIP
public static final int COMPRESSION_GZIP
Indicates gzip compression of an image.- See Also:
- Constant Field Values
-
COMPRESSION_BZIP2
public static final int COMPRESSION_BZIP2
Indicates bzip2 compression of an image.- See Also:
- Constant Field Values
-
axisOrientation
protected int[] axisOrientation
axis orientation used to support image ordering and display for medical images. We support the right hand rule where the origin is the upper left hand of the image with the positive axis.x - left to right y - top to botton z - into the screen
-
fileName
protected java.lang.String fileName
The file name which includes the path information.
-
fileSuffix
protected java.lang.String fileSuffix
File suffix (ex. "jpg")
-
imageOrientation
protected int imageOrientation
Indicates the image orientation (i.e. Axial, Coronal, ...)
-
modality
protected int modality
Indicates the modality (medical image type) of the dataset.
-
origin
protected float[] origin
The origin to support image locations (ie. DICOM, MINC ...) it is relative to the image origin. the positive axis are right hand rule.x - left to right y - top to botton z - into the screen
-
compressionType
private int compressionType
Used to indicate if the raw data was also compression (0 = no, 1 = zip).
-
dataType
private int dataType
The data type of the data (i.e. byte, short, float ...
-
dimResolutions
private float[] dimResolutions
Pixel or voxel resolutions for each dimension - default = 1.0. The z-dim resolution should be the spacing between the centers of adjacent slices; sometimes this will match the slice thickness, but not always.
-
endianess
private boolean endianess
The Endianess of the data. Intel, DEC Alpha ***** LSB first byte LITTLE_ENDIAN (false) Motorola (MAC), SPARC (SUN), SGI IRIX MSB first byte BIG_ENDIAN (true)
-
originalEndianess
private boolean originalEndianess
Used for checking for endianess changes in the ModelImage.reallocate(final int type) function.
-
extents
private int[] extents
Image extents as decribed by the image file format.
-
fileFormat
private int fileFormat
File format as defined in the Filebase.
-
max
private double max
Image maximum intensity for single channel image.
-
maxB
private double maxB
Image maximum intensity for the blue channel of an RGB image.
-
maxG
private double maxG
Image maximum intensity for the green channel of an RGB image.
-
maxR
private double maxR
Image maximum intensity for the red channel of an RGB image.
-
min
private double min
Image minimum intensity for single channel image.
-
minB
private double minB
Image minimum intensity for the blue channel of an RGB image.
-
minG
private double minG
Image minimum intensity for the green channel of an RGB image.
-
minR
private double minR
Image minimum intensity for the red channel of an RGB image.
-
lut
private ModelLUT lut
ModelLUT associated with fileinfo
-
multiFile
private boolean multiFile
Flag that indicates whether or not the image is in multiple files (tiff).
-
offset
private int offset
Number of bytes to the start the image data - ie. the header length
-
photometric
private short photometric
Image minimum intensity for single channel image.
-
pixelPadValue
private java.lang.Short pixelPadValue
Some file formats have a pad value for pixels outside the acquisition domain.
-
rescaleIntercept
private double rescaleIntercept
DICOM images have a rescale y-intercept value that we have also kept in the base.
-
rescaleSlope
private double rescaleSlope
DICOM images have a rescale slope value that we have also kept in the base.
-
sliceThickness
private float sliceThickness
The thickness of individual slices in the image volume. Stored in dicom tag 0018,0050 and various other places in other file formats.
-
unitsOfMeasure
protected FileInfoBase.Unit[] unitsOfMeasure
Describes the units of measure for the dataset.
-
tagName
protected java.util.Vector<java.lang.String> tagName
-
tagDescription
protected java.util.Vector<java.lang.String> tagDescription
-
focalLength
protected double focalLength
-
focalLength35
protected double focalLength35
-
cameraMake
protected java.lang.String cameraMake
-
cameraModel
protected java.lang.String cameraModel
-
exposureTime
protected double exposureTime
-
FNumber
protected double FNumber
-
ISOSpeedRating
protected double ISOSpeedRating
-
-
Constructor Detail
-
FileInfoBase
public FileInfoBase(java.lang.String name, java.lang.String directory, int format)fileInfo constructor.- Parameters:
name- name of filedirectory- file directoryformat- file storage format -- see FileBase.java
-
FileInfoBase
protected FileInfoBase(FileInfoBase copy)
Internal constructor for clone usage.
-
-
Method Detail
-
displayAboutInfo
public abstract void displayAboutInfo(JDialogBase dialog, TransMatrix matrix)
Abstract method which is used by the extending class to display information about the window.- Parameters:
dialog- Area where image information is to be displayed.matrix- Transformation matrix
-
getAboutInfo
public java.lang.String getAboutInfo(TransMatrix matrix)
Abstract method which is used by the extending class to return information about the file header.- Parameters:
matrix- Transformation matrix- Returns:
- A string containing information from the image header.
-
copyCoreInfo
public static void copyCoreInfo(FileInfoBase[] originalInfo, FileInfoBase[] newInfo)
Helper method to copy important file info type to another file info type.- Parameters:
originalInfo- source file info.newInfo- destination file info.
-
copyCoreInfo
public static void copyCoreInfo(FileInfoBase[] originalInfo, FileInfoBase[] newInfo, boolean[] listNoCopy)
Helper method to copy core information from one fileinfo into another, this method also has a list of fileinfos NOT to copy (used by JDialogRemoveSlices).- Parameters:
originalInfo- FileInfoBase[] original file infos (longer list)newInfo- FileInfoBase[] new file infos (shorter list)listNoCopy- boolean[] boolean array of indices into the original fileinfos that should not be copied
-
getAxisOrientationFromStr
public static int getAxisOrientationFromStr(java.lang.String s)
Returns the axis orientation associated with a string.- Parameters:
s- String to test- Returns:
- axis orientation
-
getAxisOrientationStr
public static java.lang.String getAxisOrientationStr(int m)
Return the string associated with an axis orientation.- Parameters:
m- int representing the axis orientation (see the static definitions)- Returns:
- String representing the string associated with the axis orientation.
-
getDataTypeFromStr
public static int getDataTypeFromStr(java.lang.String s)
Returns the image data type associated with a string.- Parameters:
s- String to test- Returns:
- data type
-
getEndianessFromStr
public static boolean getEndianessFromStr(java.lang.String s)
Returns the endianess associated with a string.- Parameters:
s- String to test- Returns:
- Big endian or little endian
-
getImageOrientationFromStr
public static int getImageOrientationFromStr(java.lang.String s)
Returns the image orientation associated with a string.- Parameters:
s- String to test- Returns:
- image orientation
-
getImageOrientationStr
public static java.lang.String getImageOrientationStr(int m)
Return the string associated with an image orientation.- Parameters:
m- the orientation (see the static definitions)- Returns:
- the string associated with the orientation.
-
getModalityFromStr
public static int getModalityFromStr(java.lang.String s)
Returns the modality associated with a string.- Parameters:
s- String to test- Returns:
- modality
-
getModalityStr
public static java.lang.String[] getModalityStr()
Return all the modality strings as an array.- Returns:
- String[] - array containing the strings associated with modalities.
-
getModalityStr
public static java.lang.String getModalityStr(int m)
Return the string associated with a modality.- Parameters:
m- the modality (see the static definitions)- Returns:
- the string associated with the modality.
-
getNumOfBytesPerPixel
public static int getNumOfBytesPerPixel(int dataType)
Returns the number of bytes per pixel based on the data type.- Parameters:
dataType- the data type.- Returns:
- the number of bytes per pixel.
- Throws:
java.lang.IllegalArgumentException- DOCUMENT ME!
-
oppositeOrient
public static int oppositeOrient(int orient)
Helper method that returns the opposite axis orientation of the one sent in; that is, R2L for L2R, A2P for P2A, etc.- Parameters:
orient- DOCUMENT ME!- Returns:
- int Opposite image orientation
-
sameAxis
public static boolean sameAxis(int axisA, int axisB)Helper method to determine if axis A and axis B are the same axis: that is, if both are the patient x-axis, they will be either R2L or L2R.- Parameters:
axisA- Axis A: one of the defined ORI_ types.axisB- Axis B: one of the defined ORI_ types.- Returns:
- boolean
trueif axis A and axis B are the same axis
-
displayAboutInfo
public void displayAboutInfo(JDialogBase dialog)
Displays the file information.- Parameters:
dialog- dialog box that is written to
-
displayPrimaryInfo
public void displayPrimaryInfo(JDialogText dialog, TransMatrix matrix)
Method called by many extending classes to display basic information in the dialog common to all images.- Parameters:
dialog- Area where image information is to be displayed.matrix- Transformation matrix
-
getPrimaryInfo
public java.lang.String getPrimaryInfo(TransMatrix matrix)
Method called by many extending classes to return basic information in the dialog common to all images.- Parameters:
matrix- Transformation matrix- Returns:
- The basic image header infomation.
-
finalize
public void finalize()
Prepares this class for cleanup.- Overrides:
finalizein classjava.lang.Object
-
getAxisDirection
public int[] getAxisDirection()
Get the direction for accessing each axis of data. This is based on the values in the axisOrientation array.- Returns:
- int[] Array of +/-1 values with one entry for each axis. A -1 indicates that the direction is reversed.
-
getAxisOrientation
public int[] getAxisOrientation()
Returns orientation of each axis.- Returns:
- int[] orientation of each axis
- See Also:
setAxisOrientation(int[])
-
getAxisOrientation
public int getAxisOrientation(int axis)
Returns orientation of entered axis.- Parameters:
axis- Axis to get orientation for- Returns:
- int orientation of specified axis
- See Also:
setAxisOrientation(int, int)
-
getCompressionType
public int getCompressionType()
Gets the compression type.- Returns:
- the compression type
-
getDataType
public final int getDataType()
Returns data type.- Returns:
- int type of data in file
-
getEndianess
public final boolean getEndianess()
Descibes file endianess.- Returns:
- boolean
false= litteEndian formattrue= bigEndian format
-
getOriginalEndianess
public final boolean getOriginalEndianess()
-
getExtents
public final int[] getExtents()
Returns the dimensionality of the image.- Returns:
- int[] units (Inches or millimeters);
-
getFileDirectory
public final java.lang.String getFileDirectory()
Returns counter to start of image data.- Returns:
- String that indicates location of the file
-
getFileFormat
public final int getFileFormat()
Returns file format.- Returns:
- int file format (TIFF, raw, Analyze...)
-
getFileName
public final java.lang.String getFileName()
Returns the file name.- Returns:
- String indicating file name
-
getFileSuffix
public final java.lang.String getFileSuffix()
Returns the file suffix.- Returns:
- String representing the filename suffix
-
getImageOrientation
public final int getImageOrientation()
Returns the image orientation.- Returns:
- int representing orientation
-
getIs2_5D
public final boolean getIs2_5D()
Return whether or not the image's slices are time based.- Returns:
- boolean is 2.5 D
-
getLPSOrigin
public float[] getLPSOrigin()
DOCUMENT ME!- Returns:
- float[] LPSOrigin
-
getLUT
public ModelLUT getLUT()
Returns the LUT.
-
getMax
public final double getMax()
Returns max pixel value of the image.- Returns:
- double Returns double max pixel value of the image
-
getMaxB
public final double getMaxB()
Returns max blue pixel value of the image.- Returns:
- double Returns double blue max pixel value of the image
-
getMaxG
public final double getMaxG()
Returns max green pixel value of the image.- Returns:
- double Returns double green max pixel value of the image
-
getMaxR
public final double getMaxR()
Returns max red pixel value of the image.- Returns:
- double Returns double red max pixel value of the image
-
getMin
public final double getMin()
Returns min pixel value of the image.- Returns:
- double Returns double min pixel value of the image
-
getMinB
public final double getMinB()
Returns min blue pixel value of the image.- Returns:
- double Returns double blue min pixel value of the image
-
getMinG
public final double getMinG()
Returns min green pixel value of the image.- Returns:
- couble Returns double green min pixel value of the image
-
getMinR
public final double getMinR()
Returns min red pixel value of the image.- Returns:
- couble Returns double red min pixel value of the image
-
getModality
public final int getModality()
Returns the modality.- Returns:
- int indicating modality
-
getMultiFile
public final boolean getMultiFile()
Returns whether or not the image is in multiple files (tiff).- Returns:
- boolean true indicates multiple files, false o.w.
-
getOffset
public final int getOffset()
Returns the header offset.- Returns:
- int header offset
-
getOrigin
public float[] getOrigin()
Returns the origin.- Returns:
- float[] the origin
-
getOrigin
public float getOrigin(int axis)
Returns the origin value of the requested axis.- Parameters:
axis- requested axis; x is 0, y is 1, z is 2- Returns:
- float orientation of axis
-
getOriginAtSlice
public float[] getOriginAtSlice(int slice)
Gets the origin of a particular slice; resets for the z dimension.- Parameters:
slice- Z-dimension slice.- Returns:
- float[] New start locations
-
getPhotometric
public final short getPhotometric()
Photometric interpretion.1 indicates 0 is black 0 indicates 0 is white 2 RGB 3 indexed color LUT is saved with image 4 Transparency Mask - Returns:
- short Returns interpretation
-
getPixelPadValue
public final java.lang.Short getPixelPadValue()
Returns pixel pad value.- Returns:
- Short Returns pixel pad value
-
getRescaleIntercept
public final double getRescaleIntercept()
Returns the intercept.- Returns:
- double rescale intercept
-
getRescaleSlope
public final double getRescaleSlope()
Returns the slope.- Returns:
- double rescale slope
-
getResolution
public final float getResolution(int dim)
Returns the resolution of the requested dimension.- Parameters:
dim- The dimension to return the resolution of.- Returns:
- The resolution of one of the image dimensions.
-
getResolutions
public final float[] getResolutions()
Returns each dimension's resolution.- Returns:
- float[] dimension resolutions
-
getSize
public int getSize()
Returns the size of the slice image in byte which represented by this object.- Returns:
- the size of the slice image in byte which represented by this object.
-
getSliceThickness
public final float getSliceThickness()
Returns the thickness of the image slices.- Returns:
- slice thickness
-
getUnitsOfMeasure
public final int[] getUnitsOfMeasure()
Returns the units of measure.- Returns:
- int[] units (Inches or millimeters);
-
getUnitsOfMeasure
public int getUnitsOfMeasure(int dim)
Returns the units of measure for the given dimension.- Parameters:
dim- dimension index- Returns:
- int units (Inches or millimeters);
-
getVolumeUnitsOfMeasureStr
public java.lang.String getVolumeUnitsOfMeasureStr()
Returns the volume unit for the data. Assumes all three dimensions are the same units.- Returns:
- String associated volume unit of measure.
-
getAreaUnitsOfMeasureStr
public java.lang.String getAreaUnitsOfMeasureStr()
Returns the area unit for the data. Assumes both dimensions are the same units.- Returns:
- String associated volume unit of measure.
-
isDicomOrdered
public boolean isDicomOrdered()
isDicomOrdered() returns true if the file is in dicom order, false otherwise.- Returns:
- true if the file is in dicom order, false otherwise
-
setAxisOrientation
public void setAxisOrientation(int[] axOrient)
Sets (copies) orientation of each axis.- Parameters:
axOrient- axis orientation array- See Also:
getAxisOrientation()
-
setAxisOrientation
public void setAxisOrientation(int axOrient, int axis)Sets the image orientation in the specified axis. Creates the axisOrientation if the array has not yet been created.- Parameters:
axOrient- orientationaxis- axis of orientation; x is 0, y is 1, z is 2.
-
setCompressionType
public void setCompressionType(int type)
Sets the compression type.- Parameters:
type- compression type
-
setDataType
public final void setDataType(int type)
Sets format of image data.- Parameters:
type- data type defined in ModelStorageBase
-
setEndianess
public void setEndianess(boolean endness)
Describes file endianess.- Parameters:
endness- endianess of the file format
-
setOriginalEndianess
public void setOriginalEndianess(boolean originalEndness)
-
setExtents
public final void setExtents(int[] dims)
Sets dimensionality of the images.- Parameters:
dims- dimensionality for x,y, and z ... dimensions
-
setExtents
public void setExtents(int extent, int dim)Sets dimensionality for image, on a per dimension basis.- Parameters:
extent- Extent of this dimensiondim- Dimension to set extent in
-
setFileDirectory
public final void setFileDirectory(java.lang.String directory)
DOCUMENT ME!- Parameters:
directory- DOCUMENT ME!
-
setFileFormat
public final void setFileFormat(int format)
Sets the file format.- Parameters:
format- File format
-
setFileName
public void setFileName(java.lang.String fname)
Sets the file name.- Parameters:
fname- image file name
-
setFileSuffix
public final void setFileSuffix(java.lang.String suffix)
Sets the file suffix.- Parameters:
suffix- file suffix
-
setImageOrientation
public void setImageOrientation(int orient)
Sets the image orientation.- Parameters:
orient- Orientation.
-
setLUT
public void setLUT(ModelLUT lut)
Sets the model lut- Parameters:
reference- to the model lut for this file info (often shared between file infos to conserve space
-
setMax
public void setMax(double Max)
Sets max pixel value of image.- Parameters:
Max- max pixel value
-
setMaxB
public final void setMaxB(double Max)
Sets max blue pixel value of image.- Parameters:
Max- max blue pixel value
-
setMaxG
public void setMaxG(double Max)
Sets max green pixel value of image.- Parameters:
Max- max green pixel value
-
setMaxR
public void setMaxR(double Max)
Sets max red pixel value of image.- Parameters:
Max- max red pixel value
-
setMin
public final void setMin(double Min)
Sets min pixel value of image.- Parameters:
Min- Min pixel value
-
setMinB
public final void setMinB(double Min)
Sets min blue pixel value of image.- Parameters:
Min- min blue pixel value
-
setMinG
public final void setMinG(double Min)
Sets min green pixel value of image.- Parameters:
Min- min green pixel value
-
setMinR
public final void setMinR(double Min)
Sets min red pixel value of image.- Parameters:
Min- min red pixel value
-
setModality
public final void setModality(int mod)
Sets the modality.- Parameters:
mod- modality
-
setMultiFile
public final void setMultiFile(boolean flag)
Sets the flag for multiple files.- Parameters:
flag-trueindicates multiple files for image,falseo.w.
-
setOffset
public final void setOffset(int off)
Sets the header offset.- Parameters:
off- the header offset
-
setOrigin
public void setOrigin(float[] originlocat)
Sets the origin.- Parameters:
originlocat- origin location array- See Also:
#getStartLocations()
-
setOrigin
public void setOrigin(float originCoord, int axis)Sets the start location in the specified axis. creates the startLocations if the arrray has not yet been created.- Parameters:
originCoord- start locationaxis- axis of orientation; x is 0, y is 1, z is 2- See Also:
#getStartLocations(int)
-
setPhotometric
public void setPhotometric(short value)
Sets photometric interpretation.1 indicates 0 is black 0 indicates 0 is white 2 RGB 3 indexed color LUT is saved with image - Parameters:
value- photometric value
-
setPixelPadValue
public final void setPixelPadValue(java.lang.Short value)
Sets pixel pad value: used in some Dicom images.- Parameters:
value- pixel pad value
-
setRescaleIntercept
public final void setRescaleIntercept(double intercept)
Sets the rescale intercept.- Parameters:
intercept- the intercept
-
setRescaleSlope
public final void setRescaleSlope(double slope)
Sets the rescale slope.- Parameters:
slope- the slope
-
setResolutions
public final void setResolutions(float[] resolutions)
Sets the resolutions of the image.- Parameters:
resolutions- resolution object
-
setResolutions
public final void setResolutions(float resolution, int dim)Sets the resolutions of the image, on a per dimension basis.- Parameters:
resolution- Resolution for the dimensiondim- Dimension to set resolution in
-
setSliceThickness
public void setSliceThickness(float thickness)
Sets the thickness of the image slices.- Parameters:
thickness- The slice thickness.
-
setUnitsOfMeasure
public final void setUnitsOfMeasure(FileInfoBase.Unit[] unitMeasure)
Sets (copies) units of measure for image.- Parameters:
unitMeasure- unit of measure for a specified dimension
-
setUnitsOfMeasure
public final void setUnitsOfMeasure(int[] unitMeasure)
Sets (copies) units of measure for image.- Parameters:
unitMeasure- unit of measure for a specified dimension
-
setUnitsOfMeasure
public final void setUnitsOfMeasure(FileInfoBase.Unit unitMeasure, int dim)
Sets units of measure for image, on a per dimension basis.- Parameters:
unitMeasure- Unit of measure for the dimensiondim- Dimension to set unit of measure in
-
setUnitsOfMeasure
public final void setUnitsOfMeasure(int unitMeasure, int dim)Sets units of measure for image, on a per dimension basis.- Parameters:
unitMeasure- Unit of measure for the dimensiondim- Dimension to set unit of measure in
-
setTagName
public void setTagName(java.util.Vector<java.lang.String> tagName)
-
setTagDescription
public void setTagDescription(java.util.Vector<java.lang.String> tagDescription)
-
setFocalLength
public void setFocalLength(double focalLength)
-
getFocalLength
public double getFocalLength()
-
setFocalLength35
public void setFocalLength35(double focalLength35)
-
getFocalLength35
public double getFocalLength35()
-
setCameraMake
public void setCameraMake(java.lang.String cameraMake)
-
getCameraMake
public java.lang.String getCameraMake()
-
setCameraModel
public void setCameraModel(java.lang.String cameraModel)
-
getCameraModel
public java.lang.String getCameraModel()
-
setExposureTime
public void setExposureTime(double exposureTime)
-
getExposureTime
public double getExposureTime()
-
setFNumber
public void setFNumber(double FNumber)
-
getFNumber
public double getFNumber()
-
setISOSpeedRating
public void setISOSpeedRating(double ISOSpeedRating)
-
getISOSpeedRating
public double getISOSpeedRating()
-
toString
public java.lang.String toString()
Gives the information contained in FileInfo in a string.- Overrides:
toStringin classjava.lang.Object- Returns:
- String information contained in the FileInfo object
-
getUnitsOfMeasureAbbrevStr
public static java.lang.String getUnitsOfMeasureAbbrevStr(int i)
Deprecated.should now use enum- Parameters:
i-- Returns:
-
getUnitsOfMeasureStr
public static java.lang.String getUnitsOfMeasureStr(int xUnits)
Deprecated.should now use enum- Parameters:
xUnits-- Returns:
-
getUnitsOfMeasureFromStr
public static int getUnitsOfMeasureFromStr(java.lang.String selectedOutput)
Deprecated.should now use enum- Parameters:
selectedOutput-- Returns:
-
getAllSameDimUnits
public static int[] getAllSameDimUnits(int measure)
Deprecated.should now use enum- Parameters:
selectedOutput-- Returns:
-
getUnitsOfMeasureAbbrevStr
public static java.lang.String[] getUnitsOfMeasureAbbrevStr()
Deprecated.should now use enumReturn all the abbreviated units of measure strings as an array.- Returns:
- String[] - array containing the abbreviated strings associated with units of measure.
-
getUnitsOfMeasureStr
public static java.lang.String[] getUnitsOfMeasureStr()
Deprecated.should use enumReturn all the units of measure strings as an array.- Returns:
- String[] - array containing the strings associated with units of measure.
-
-