Class FileInfoSPM
- java.lang.Object
-
- gov.nih.mipav.model.structures.ModelSerialCloneable
-
- gov.nih.mipav.model.file.FileInfoBase
-
- gov.nih.mipav.model.file.FileInfoSPM
-
- All Implemented Interfaces:
java.io.Serializable
,java.lang.Cloneable
public class FileInfoSPM extends FileInfoBase
This structures contains the information that describes how an SPM image is stored on disk. We have extended this format to store image orientation and start locations. We have used unused variables to store these data. Almost all programs ignore these variables and should not have any problems reading images saved with MIPAV.Differences between MIPAV ANALYZE and SPM: In MIPAV ANALYZE we have location 60 cal_units 4 unsigned characters location 64 - X-axis orientation @see FileInfoBase for static variables that are set. location 66 - Y-axis orientation // All three unused variables are of short type. location 68 - Z-axis orientation In SPM we have location 60 cal_units 8 unsigned characters location 68 unused1
In MIPAV ANALYZE we have location 112 Funused1 - X-axis starting location (origin from upper left-hand corner) location 116 Funused2 - Y-axis starting location (origin from upper left-hand corner) location 120 Funused3 - Z-axis starting location (origin is the first image slice) In SPM we have location 112 Funused1 scale a floating point scale factor applied during memory mapping location 116 Funused2 location 120 Funused3
In MIPAV ANALYZE we have location 253 originator with 10 characters In SPM we have location 253 origin with 5 shorts. If the first 3 shorts of a 3D image are set to 0, 0, 0, the origin is assumed to be at the center of the volume, since in SPM the corner voxel is at 1, 1, 1. The position(x,y,z) in mm. is determined by the distance(x,y,z) from the origin multiplied by the vox_units(x,y,z).
In SPM the signed byte datatype was added with DT_BYTE = 130. MIPAV ANALYZE uses UNSIGNED_SHORT = 6 while SPM uses DT_UNSIGNED_SHORT = 132. The SPM standard also provides for an unsigned int = 136, but MIPAV does not used the unsigned int data type. Note that in SPM while DATA = datatype * 256 for swapped bytes, only datatype and not DATA is written to the file, so in this program we need never consider the multiplicative factors of 256.
RGB SPM images are store in chunky format rgb, rgb, rgb ......
- Version:
- 1.0 July, 2002
- Author:
- Matthew J. McAuliffe, Ph.D.
- See Also:
FileSPM
, Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class gov.nih.mipav.model.file.FileInfoBase
FileInfoBase.AxisOrientation, FileInfoBase.ImageOrientation, FileInfoBase.Modality, FileInfoBase.Unit, FileInfoBase.UnitType
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.String
aux_file
DOCUMENT ME!private short
bitpix
DOCUMENT ME!private float
cal_max
DOCUMENT ME!private float
cal_min
DOCUMENT ME!private java.lang.String
cal_units
DOCUMENT ME!private float
compressed
DOCUMENT ME!static byte
CORONAL_FLIPPED
DOCUMENT ME!static byte
CORONAL_UNFLIPPED
DOCUMENT ME!private java.lang.String
data_type
DOCUMENT ME!private short
datatype
DOCUMENT ME!private java.lang.String
db_name
DOCUMENT ME!private java.lang.String
descrip
DOCUMENT ME!private short
dim_un0
DOCUMENT ME!static int
DT_ALL
DOCUMENT ME!static int
DT_BINARY
DOCUMENT ME!static int
DT_BYTE
DOCUMENT ME!static int
DT_COMPLEX
DOCUMENT ME!static int
DT_DOUBLE
DOCUMENT ME!static int
DT_FLOAT
DOCUMENT ME!static int
DT_NONE
DOCUMENT ME!static int
DT_RGB
DOCUMENT ME!static int
DT_SIGNED_INT
DOCUMENT ME!static int
DT_SIGNED_SHORT
DOCUMENT ME!static int
DT_UNKNOWN
DOCUMENT ME!static int
DT_UNSIGNED_CHAR
DOCUMENT ME!static int
DT_UNSIGNED_INT
DOCUMENT ME!static int
DT_UNSIGNED_SHORT
DOCUMENT ME!private java.lang.String
exp_date
DOCUMENT ME!private java.lang.String
exp_time
DOCUMENT ME!private int
extents
DOCUMENT ME!private int
field_skip
DOCUMENT ME!private java.lang.String
generated
DOCUMENT ME!private int
glmax
DOCUMENT ME!private int
glmin
DOCUMENT ME!private java.lang.String
hist_un0
DOCUMENT ME!private char
hkey_un0
DOCUMENT ME!private int
omax
DOCUMENT ME!private int
omin
DOCUMENT ME!private byte
orient
DOCUMENT ME!private short[]
origin
DOCUMENT ME!private java.lang.String
patient_id
DOCUMENT ME!private char
regular
DOCUMENT ME!static byte
SAGITTAL_FLIPPED
DOCUMENT ME!static byte
SAGITTAL_UNFLIPPED
DOCUMENT ME!private float
scale
a floating point scale factor used during memory mapping.private java.lang.String
scannum
DOCUMENT ME!private static long
serialVersionUID
Use serialVersionUID for interoperability.private short
session_error
DOCUMENT ME!private int
sizeof_hdr
DOCUMENT ME!private int
smax
DOCUMENT ME!private int
smin
DOCUMENT ME!private int
start_field
DOCUMENT ME!static byte
TRANSVERSE_FLIPPED
DOCUMENT ME!static byte
TRANSVERSE_UNFLIPPED
DOCUMENT ME!static byte
UNKNOWN_ORIENT
The data_history substructure is not required, but the orient element is used to indicate individual slice orientation and determines whetther the SPM Movie program will attempt to flip the images before displaying a movie sequence. 0 - transverse unflipped 1 - coronal unflipped 2 - sagitttal unflipped 3 - transverse flipped 4 - coronal flipped 5 - sagitttal flippedprivate float
verified
DOCUMENT ME!private int
views
DOCUMENT ME!private int
vols_added
DOCUMENT ME!private float
vox_offset
public float pixdim = new float[8]; // image resolutions info mm or ms stored in FileInfoBase pixdim[0] = number of dimensions pixdim[1] = voxel width pixdim[2] = voxel height pixdim[3] = voxel thickness pixdim[4] = time.private java.lang.String
vox_units
public short dim[] = new short[8]; // image dimension data stored in FileInfoBase dim[0] = number of dimensions; usally 4 dim[1] = image width dim[2] = image height dim[3] = image depth (# of slices) dim[4] = volumes in image --- must be one for 3D image.-
Fields inherited from class gov.nih.mipav.model.file.FileInfoBase
ANGSTROMS, ANGSTROMS_STRING, AXIAL, axisOrientation, axisOrientationStr, BIOMAGNETIC_IMAGING, cameraMake, cameraModel, CENTIMETERS, CENTIMETERS_STRING, COLOR_FLOW_DOPPLER, COMPRESSION_BZIP2, COMPRESSION_GZIP, COMPRESSION_NONE, COMPRESSION_ZIP, COMPUTED_RADIOGRAPHY, COMPUTED_TOMOGRAPHY, conversionSpaceTimeUnits, CORONAL, DEGREES, DEGREES_STRING, DIAPHANOGRAPHY, DIGITAL_RADIOGRAPHY, DUPLEX_DOPPLER, ENDOSCOPY, exposureTime, EXTERNAL_CAMERA_PHOTOGRAPHY, FA, fileName, fileSuffix, FNumber, focalLength, focalLength35, GENERAL_MICROSCOPY, HARDCOPY, HOURS, HOURS_STRING, HZ, HZ_STRING, ICG, imageOrientation, INCHES, INCHES_STRING, INTRAORAL_RADIOGRAPHY, ISOSpeedRating, KILOMETERS, KILOMETERS_STRING, LASER_SURFACE_SCAN, MAGNETIC_RESONANCE, MAGNETIC_RESONANCE_ANGIOGRAPHY, MAGNETIC_RESONANCE_SPECTROSCOPY, MAMMOGRAPHY, METERS, METERS_STRING, MICROMETERS, MICROMETERS_STRING, MICROSEC, MICROSEC_STRING, MILES, MILES_STRING, MILLIMETERS, MILLIMETERS_STRING, MILLISEC, MILLISEC_STRING, MILS, MILS_STRING, MINUTES, MINUTES_STRING, modality, NANOMETERS, NANOMETERS_STRING, NANOSEC, NANOSEC_STRING, NUCLEAR_MEDICINE, ORI_A2P_TYPE, ORI_I2S_TYPE, ORI_L2R_TYPE, ORI_P2A_TYPE, ORI_R2L_TYPE, ORI_S2I_TYPE, ORI_UNKNOWN_TYPE, OTHER, PANORAMIC_XRAY, POSITRON_EMISSION_TOMOGRAPHY, PPM, PPM_STRING, RADIO_FLUOROSCOPY, RADIOGRAPHIC_IMAGING, RADIOTHERAPY_DOSE, RADIOTHERAPY_IMAGE, RADIOTHERAPY_PLAN, RADIOTHERAPY_RECORD, RADIOTHERAPY_STRUCTURE_SET, RADS, RADS_STRING, RED_FREE, SAGITTAL, SECONDS, SECONDS_STRING, SINGLE_PHOTON_EMISSION_COMPUTED_TOMOGRAPHY, SLIDE_MICROSCOPY, sUnits, tagDescription, tagName, THERMOGRAPHY, TRANSFORM_ANOTHER_DATASET, TRANSFORM_MNI_152, TRANSFORM_SCANNER_ANATOMICAL, TRANSFORM_TALAIRACH_TOURNOUX, TRANSFORM_UNKNOWN, tUnits, ULTRASOUND, unitsOfMeasure, UNKNOWN_MEASURE, UNKNOWN_MODALITY, UNKNOWN_STRING, XRAY_ANGIOGRAPHY
-
-
Constructor Summary
Constructors Constructor Description FileInfoSPM(java.lang.String name, java.lang.String directory, int format)
file info storage constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
displayAboutInfo(JDialogBase dlog, TransMatrix matrix)
displays the file information.java.lang.String
getAuxFile()
accessor to the aux_file string.short
getBitPix()
accessor to the bitpix value.float
getCalMax()
accessor to cal-max.float
getCalMin()
accessor to cal-min.java.lang.String
getCalUnits()
provides the string for cal units.float
getCompressed()
provides the compressed value.short
getDataTypeCode()
accessor to coded datatype value.java.lang.String
getDataTypeName()
Accessor to the 10 character string of data-type.java.lang.String
getDBname()
accessor to DB_name.java.lang.String
getDescription()
accessor to the current SPM-image description.short
getDim()
DOCUMENT ME!java.lang.String
getExperimentDate()
provides the current experiment date string.java.lang.String
getExperimentTime()
provides the current experiment time string.int
getFieldSkip()
provides the current field_skip value.int
getFileExtents()
DOCUMENT ME!java.lang.String
getGenerated()
provides the current generated string.int
getGLmax()
provides the value of glmax.int
getGLmin()
provides the value of glmin.java.lang.String
getHist()
DOCUMENT ME!char
getHkey()
DOCUMENT ME!int
getOmax()
provides current omax value.int
getOmin()
provides current omin value.byte
getOrientation()
provides the current orientation value.short[]
getOriginLoc()
DOCUMENT ME!java.lang.String
getPatientID()
provides the current patient id.char
getRegular()
provides the value of regular character.float
getScale()
DOCUMENT ME!java.lang.String
getScanNum()
provides the current scannum string.short
getSessionErr()
provide the value of session err.int
getSizeOfHeader()
DOCUMENT ME!int
getSmax()
provides current smax value.int
getSmin()
provides current smin value.int
getStartField()
provides the current value for the start_field.float
getVerified()
provides the verified value.int
getViews()
provides current views value.int
getVolsAdded()
provides the current vols_added value.float
getVoxOffset()
accessor to the vox offset value.java.lang.String
getVoxUnits()
provides the string for vox-units.private java.lang.String
selectOrientationText(int or)
selection of text for the table and the editpanel.void
setAuxFile(java.lang.String aux)
supplies auxiliary-file string; permits no more than 24 characters.void
setAxisOrientation(int[] axOrient)
Sets orientation of each axis.void
setBitPix(short bp)
sets bitpix; any value other than 1, 8, 16, 32, 64, or 24 gets set to the dissalowed trap value, -1.void
setCalMax(float cal)
sets cal-max. if supplied value is less than cal-min, the cal-min gets reset to the supplied value as well, so that cal-min is still no greater than cal-max.void
setCalMin(float cal)
sets cal-min. if supplied value is greater than cal-max, the cal-max gets reset to the supplied value as well, so that cal-max is still no less than cal-min.void
setCalUnits(java.lang.String cal)
allows no more than 8 characters for the string describing the cal units.void
setCompressed(float comp)
sets the compressed variable.void
setDataType(short dtype)
accessor to supply coded datatype.void
setDataType(java.lang.String dtype)
permits 10 charactar large string for data-type.void
setDBname(java.lang.String dbname)
18 character max to set the DB_NAME value.void
setDescription(java.lang.String description)
allows no more than 80 characters to fill in the SPM-image description.void
setDim(short un0)
DOCUMENT ME!void
setExperimentDate(java.lang.String date)
allows a maximum of 10 characters to set the experiment date string.void
setExperimentTime(java.lang.String time)
allows a maximum of 10 characters to set the experiment time string.void
setFieldSkip(int field)
supplies the submitted value to the field_sip variable.void
setFileExtents(int ext)
DOCUMENT ME!void
setGenerated(java.lang.String gen)
allows a maximum of 10 characters to set the generated string.void
setGLmax(int gl)
sets glmax. if supplied value is less than glmin, the glmin gets reset to the supplied value as well, so that glmin is still no greater than glmax.void
setGLmin(int gl)
sets glmin. if supplied value is greater than glmax, the glmax gets reset to the supplied value as well, so that glmax is still no less than glmin.void
setHist(java.lang.String hist)
DOCUMENT ME!void
setHkey(char hk)
DOCUMENT ME!void
setMipavOrigin(float[] mipavOrigin)
void
setOmax(int o)
sets omax. if supplied value is less than omin, the omin gets reset to the supplied value as well, so that omin is still no greater than omax.void
setOmin(int o)
sets omin. if supplied value is greater than omax, the omax gets reset to the supplied value as well, so that omax is still no less than omin.void
setOrientation(byte orientation)
Sets the image orientation converting from SPM specific orientation to general orientation.void
setOrigin(short[] origin)
DOCUMENT ME!void
setPatientID(java.lang.String IDnum)
allows a maximum of 10 characters to set the patient ID string.void
setRegular(char ch)
supply the value of regular character.void
setScale(float scale)
DOCUMENT ME!void
setScanNum(java.lang.String num)
allows a maximum of 10 characters to set the scannum string.void
setSessionErr(short s)
supply the value of session error.void
setSizeOfHeader(int size)
DOCUMENT ME!void
setSmax(int s)
sets smax. if supplied value is less than smin, the smin gets reset to the supplied value as well, so that smin is still no greater than smax.void
setSmin(int s)
sets smin. if supplied value is greater than smax, the smax gets reset to the supplied value as well, so that smax is still no less than smin.void
setStartField(int field)
supplies the submitted value to the start_field variable.protected java.lang.String
setString(java.lang.String str, int len)
verifies string is not larger than len length; strings larger than len, are clipped before being returned.void
setVerified(float veri)
supply the value to verified.void
setViews(int view)
sets the views variable.void
setVolsAdded(int vols)
supplies a value to the vols_added valiable.void
setVoxOffset(float vox)
sets vox offset value.void
setVoxUnits(java.lang.String vox)
allows no more than 4 characters for the string describing the vox units.void
stateChanged(java.util.Vector ce)
.void
updateFileInfos(FileInfoSPM fInfo)
Propogates the current file info to another FileInfoSPM except for the 3 start locations kept in funused1, funused2, funused3.-
Methods inherited from class gov.nih.mipav.model.file.FileInfoBase
copyCoreInfo, copyCoreInfo, displayAboutInfo, displayPrimaryInfo, finalize, getAboutInfo, getAllSameDimUnits, getAreaUnitsOfMeasureStr, getAxisDirection, getAxisOrientation, getAxisOrientation, getAxisOrientationFromStr, getAxisOrientationStr, getCameraMake, getCameraModel, getCompressionType, getDataType, getDataTypeFromStr, getEndianess, getEndianessFromStr, getExposureTime, getExtents, getFileDirectory, getFileFormat, getFileName, getFileSuffix, getFNumber, getFocalLength, getFocalLength35, getImageOrientation, getImageOrientationFromStr, getImageOrientationStr, getIs2_5D, getISOSpeedRating, getLPSOrigin, getLUT, getMax, getMaxB, getMaxG, getMaxR, getMin, getMinB, getMinG, getMinR, getModality, getModalityFromStr, getModalityStr, getModalityStr, getMultiFile, getNumOfBytesPerPixel, getOffset, getOrigin, getOrigin, getOriginalEndianess, getOriginAtSlice, getPhotometric, getPixelPadValue, getPrimaryInfo, getRescaleIntercept, getRescaleSlope, getResolution, getResolutions, getSize, getSliceThickness, getUnitsOfMeasure, getUnitsOfMeasure, getUnitsOfMeasureAbbrevStr, getUnitsOfMeasureAbbrevStr, getUnitsOfMeasureFromStr, getUnitsOfMeasureStr, getUnitsOfMeasureStr, getVolumeUnitsOfMeasureStr, isDicomOrdered, oppositeOrient, sameAxis, setAxisOrientation, setCameraMake, setCameraModel, setCompressionType, setDataType, setEndianess, setExposureTime, setExtents, setExtents, setFileDirectory, setFileFormat, setFileName, setFileSuffix, setFNumber, setFocalLength, setFocalLength35, setImageOrientation, setISOSpeedRating, setLUT, setMax, setMaxB, setMaxG, setMaxR, setMin, setMinB, setMinG, setMinR, setModality, setMultiFile, setOffset, setOrigin, setOrigin, setOriginalEndianess, setPhotometric, setPixelPadValue, setRescaleIntercept, setRescaleSlope, setResolutions, setResolutions, setSliceThickness, setTagDescription, setTagName, setUnitsOfMeasure, setUnitsOfMeasure, setUnitsOfMeasure, setUnitsOfMeasure, toString
-
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
-
DT_NONE
public static final int DT_NONE
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_UNKNOWN
public static final int DT_UNKNOWN
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_BINARY
public static final int DT_BINARY
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_BYTE
public static final int DT_BYTE
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_UNSIGNED_CHAR
public static final int DT_UNSIGNED_CHAR
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_SIGNED_SHORT
public static final int DT_SIGNED_SHORT
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_UNSIGNED_SHORT
public static final int DT_UNSIGNED_SHORT
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_SIGNED_INT
public static final int DT_SIGNED_INT
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_UNSIGNED_INT
public static final int DT_UNSIGNED_INT
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_FLOAT
public static final int DT_FLOAT
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_COMPLEX
public static final int DT_COMPLEX
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_DOUBLE
public static final int DT_DOUBLE
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_RGB
public static final int DT_RGB
DOCUMENT ME!- See Also:
- Constant Field Values
-
DT_ALL
public static final int DT_ALL
DOCUMENT ME!- See Also:
- Constant Field Values
-
UNKNOWN_ORIENT
public static final byte UNKNOWN_ORIENT
The data_history substructure is not required, but the orient element is used to indicate individual slice orientation and determines whetther the SPM Movie program will attempt to flip the images before displaying a movie sequence. 0 - transverse unflipped 1 - coronal unflipped 2 - sagitttal unflipped 3 - transverse flipped 4 - coronal flipped 5 - sagitttal flipped- See Also:
- Constant Field Values
-
TRANSVERSE_UNFLIPPED
public static final byte TRANSVERSE_UNFLIPPED
DOCUMENT ME!- See Also:
- Constant Field Values
-
CORONAL_UNFLIPPED
public static final byte CORONAL_UNFLIPPED
DOCUMENT ME!- See Also:
- Constant Field Values
-
SAGITTAL_UNFLIPPED
public static final byte SAGITTAL_UNFLIPPED
DOCUMENT ME!- See Also:
- Constant Field Values
-
TRANSVERSE_FLIPPED
public static final byte TRANSVERSE_FLIPPED
DOCUMENT ME!- See Also:
- Constant Field Values
-
CORONAL_FLIPPED
public static final byte CORONAL_FLIPPED
DOCUMENT ME!- See Also:
- Constant Field Values
-
SAGITTAL_FLIPPED
public static final byte SAGITTAL_FLIPPED
DOCUMENT ME!- See Also:
- Constant Field Values
-
aux_file
private java.lang.String aux_file
DOCUMENT ME!
-
bitpix
private short bitpix
DOCUMENT ME!
-
cal_max
private float cal_max
DOCUMENT ME!
-
cal_min
private float cal_min
DOCUMENT ME!
-
cal_units
private java.lang.String cal_units
DOCUMENT ME!
-
compressed
private float compressed
DOCUMENT ME!
-
data_type
private java.lang.String data_type
DOCUMENT ME!
-
datatype
private short datatype
DOCUMENT ME!
-
db_name
private java.lang.String db_name
DOCUMENT ME!
-
descrip
private java.lang.String descrip
DOCUMENT ME!
-
dim_un0
private short dim_un0
DOCUMENT ME!
-
exp_date
private java.lang.String exp_date
DOCUMENT ME!
-
exp_time
private java.lang.String exp_time
DOCUMENT ME!
-
extents
private int extents
DOCUMENT ME!
-
field_skip
private int field_skip
DOCUMENT ME!
-
generated
private java.lang.String generated
DOCUMENT ME!
-
glmax
private int glmax
DOCUMENT ME!
-
glmin
private int glmin
DOCUMENT ME!
-
hist_un0
private java.lang.String hist_un0
DOCUMENT ME!
-
hkey_un0
private char hkey_un0
DOCUMENT ME!
-
omax
private int omax
DOCUMENT ME!
-
omin
private int omin
DOCUMENT ME!
-
orient
private byte orient
DOCUMENT ME!
-
origin
private short[] origin
DOCUMENT ME!
-
patient_id
private java.lang.String patient_id
DOCUMENT ME!
-
regular
private char regular
DOCUMENT ME!
-
scale
private float scale
a floating point scale factor used during memory mapping.
-
scannum
private java.lang.String scannum
DOCUMENT ME!
-
session_error
private short session_error
DOCUMENT ME!
-
sizeof_hdr
private int sizeof_hdr
DOCUMENT ME!
-
smax
private int smax
DOCUMENT ME!
-
smin
private int smin
DOCUMENT ME!
-
start_field
private int start_field
DOCUMENT ME!
-
verified
private float verified
DOCUMENT ME!
-
views
private int views
DOCUMENT ME!
-
vols_added
private int vols_added
DOCUMENT ME!
-
vox_offset
private float vox_offset
public float pixdim = new float[8]; // image resolutions info mm or ms stored in FileInfoBase pixdim[0] = number of dimensions pixdim[1] = voxel width pixdim[2] = voxel height pixdim[3] = voxel thickness pixdim[4] = time.
-
vox_units
private java.lang.String vox_units
public short dim[] = new short[8]; // image dimension data stored in FileInfoBase dim[0] = number of dimensions; usally 4 dim[1] = image width dim[2] = image height dim[3] = image depth (# of slices) dim[4] = volumes in image --- must be one for 3D image.
-
-
Method Detail
-
displayAboutInfo
public void displayAboutInfo(JDialogBase dlog, TransMatrix matrix)
displays the file information.- Specified by:
displayAboutInfo
in classFileInfoBase
- Parameters:
dlog
- dialog box that is written tomatrix
- transformation matrix
-
getAuxFile
public java.lang.String getAuxFile()
accessor to the aux_file string.- Returns:
- String aux_file
-
getBitPix
public short getBitPix()
accessor to the bitpix value.- Returns:
- short the bitpix value.
-
getCalMax
public float getCalMax()
accessor to cal-max.- Returns:
- float cal_max
-
getCalMin
public float getCalMin()
accessor to cal-min.- Returns:
- float cal_min
-
getCalUnits
public java.lang.String getCalUnits()
provides the string for cal units.- Returns:
- String string for cal_units
-
getCompressed
public float getCompressed()
provides the compressed value.- Returns:
- float compressed
-
getDataTypeCode
public short getDataTypeCode()
accessor to coded datatype value.- Returns:
- short datatype
-
getDataTypeName
public java.lang.String getDataTypeName()
Accessor to the 10 character string of data-type.- Returns:
- String returns data_type
-
getDBname
public java.lang.String getDBname()
accessor to DB_name.- Returns:
- String database name
-
getDescription
public java.lang.String getDescription()
accessor to the current SPM-image description.- Returns:
- String description
-
getDim
public short getDim()
DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
getExperimentDate
public java.lang.String getExperimentDate()
provides the current experiment date string.- Returns:
- String the experiment date.
-
getExperimentTime
public java.lang.String getExperimentTime()
provides the current experiment time string.- Returns:
- String the experiment time
-
getFieldSkip
public int getFieldSkip()
provides the current field_skip value.- Returns:
- int the field_skip value
-
getFileExtents
public int getFileExtents()
DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
getGenerated
public java.lang.String getGenerated()
provides the current generated string.- Returns:
- String generated string
-
getGLmax
public int getGLmax()
provides the value of glmax.- Returns:
- int glmax
-
getGLmin
public int getGLmin()
provides the value of glmin.- Returns:
- int glmin
-
getHist
public java.lang.String getHist()
DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
getHkey
public char getHkey()
DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
getOmax
public int getOmax()
provides current omax value.- Returns:
- int the omax value
-
getOmin
public int getOmin()
provides current omin value.- Returns:
- int the omin value
-
getOrientation
public byte getOrientation()
provides the current orientation value.- Returns:
- byte orientation value
-
getOriginLoc
public short[] getOriginLoc()
DOCUMENT ME!- Returns:
- origin
-
getPatientID
public java.lang.String getPatientID()
provides the current patient id.- Returns:
- String the patient id
-
getRegular
public char getRegular()
provides the value of regular character.- Returns:
- char value of regular character
-
getScale
public float getScale()
DOCUMENT ME!- Returns:
- float scale
-
getScanNum
public java.lang.String getScanNum()
provides the current scannum string.- Returns:
- String current scannum string
-
getSessionErr
public short getSessionErr()
provide the value of session err.- Returns:
- short session_error
-
getSizeOfHeader
public int getSizeOfHeader()
DOCUMENT ME!- Returns:
- DOCUMENT ME!
-
getSmax
public int getSmax()
provides current smax value.- Returns:
- int the smax value
-
getSmin
public int getSmin()
provides current smin value.- Returns:
- int the smin value
-
getStartField
public int getStartField()
provides the current value for the start_field.- Returns:
- int the start_field
-
getVerified
public float getVerified()
provides the verified value.- Returns:
- float verified
-
getViews
public int getViews()
provides current views value.- Returns:
- int the view
-
getVolsAdded
public int getVolsAdded()
provides the current vols_added value.- Returns:
- int the vols_added
-
getVoxOffset
public float getVoxOffset()
accessor to the vox offset value.- Returns:
- float vox_offset
-
getVoxUnits
public java.lang.String getVoxUnits()
provides the string for vox-units.- Returns:
- String string for vox_units
-
setAuxFile
public void setAuxFile(java.lang.String aux)
supplies auxiliary-file string; permits no more than 24 characters.- Parameters:
aux
- DOCUMENT ME!
-
setAxisOrientation
public void setAxisOrientation(int[] axOrient)
Sets orientation of each axis.- Overrides:
setAxisOrientation
in classFileInfoBase
- Parameters:
axOrient
- axis orientation array- See Also:
FileInfoBase.getAxisOrientation()
-
setBitPix
public void setBitPix(short bp)
sets bitpix; any value other than 1, 8, 16, 32, 64, or 24 gets set to the dissalowed trap value, -1.- Parameters:
bp
- DOCUMENT ME!
-
setCalMax
public void setCalMax(float cal)
sets cal-max. if supplied value is less than cal-min, the cal-min gets reset to the supplied value as well, so that cal-min is still no greater than cal-max.- Parameters:
cal
- DOCUMENT ME!
-
setCalMin
public void setCalMin(float cal)
sets cal-min. if supplied value is greater than cal-max, the cal-max gets reset to the supplied value as well, so that cal-max is still no less than cal-min.- Parameters:
cal
- DOCUMENT ME!
-
setCalUnits
public void setCalUnits(java.lang.String cal)
allows no more than 8 characters for the string describing the cal units.- Parameters:
cal
- DOCUMENT ME!
-
setCompressed
public void setCompressed(float comp)
sets the compressed variable.- Parameters:
comp
- DOCUMENT ME!
-
setDataType
public void setDataType(java.lang.String dtype)
permits 10 charactar large string for data-type.- Parameters:
dtype
- DOCUMENT ME!
-
setDataType
public void setDataType(short dtype)
accessor to supply coded datatype.- Parameters:
dtype
- DOCUMENT ME!
-
setDBname
public void setDBname(java.lang.String dbname)
18 character max to set the DB_NAME value.- Parameters:
dbname
- DOCUMENT ME!
-
setDescription
public void setDescription(java.lang.String description)
allows no more than 80 characters to fill in the SPM-image description.- Parameters:
description
- DOCUMENT ME!
-
setDim
public void setDim(short un0)
DOCUMENT ME!- Parameters:
un0
- DOCUMENT ME!
-
setExperimentDate
public void setExperimentDate(java.lang.String date)
allows a maximum of 10 characters to set the experiment date string.- Parameters:
date
- DOCUMENT ME!
-
setExperimentTime
public void setExperimentTime(java.lang.String time)
allows a maximum of 10 characters to set the experiment time string.- Parameters:
time
- DOCUMENT ME!
-
setFieldSkip
public void setFieldSkip(int field)
supplies the submitted value to the field_sip variable.- Parameters:
field
- DOCUMENT ME!
-
setFileExtents
public void setFileExtents(int ext)
DOCUMENT ME!- Parameters:
ext
- DOCUMENT ME!
-
setGenerated
public void setGenerated(java.lang.String gen)
allows a maximum of 10 characters to set the generated string.- Parameters:
gen
- DOCUMENT ME!
-
setGLmax
public void setGLmax(int gl)
sets glmax. if supplied value is less than glmin, the glmin gets reset to the supplied value as well, so that glmin is still no greater than glmax.- Parameters:
gl
- DOCUMENT ME!
-
setGLmin
public void setGLmin(int gl)
sets glmin. if supplied value is greater than glmax, the glmax gets reset to the supplied value as well, so that glmax is still no less than glmin.- Parameters:
gl
- DOCUMENT ME!
-
setHist
public void setHist(java.lang.String hist)
DOCUMENT ME!- Parameters:
hist
- DOCUMENT ME!
-
setHkey
public void setHkey(char hk)
DOCUMENT ME!- Parameters:
hk
- DOCUMENT ME!
-
setOmax
public void setOmax(int o)
sets omax. if supplied value is less than omin, the omin gets reset to the supplied value as well, so that omin is still no greater than omax.- Parameters:
o
- DOCUMENT ME!
-
setOmin
public void setOmin(int o)
sets omin. if supplied value is greater than omax, the omax gets reset to the supplied value as well, so that omax is still no less than omin.- Parameters:
o
- DOCUMENT ME!
-
setOrientation
public void setOrientation(byte orientation)
Sets the image orientation converting from SPM specific orientation to general orientation. Value may be transverse, coronal, or sagittal.see the top of this document for all possible values. supplying a value other than one of these 6 possiblities sets the orientation to an impossible 'flag' value.
- See Also:
FileInfoBase.setImageOrientation(int)
-
setOrigin
public void setOrigin(short[] origin)
DOCUMENT ME!- Parameters:
origin
- DOCUMENT ME!
-
setMipavOrigin
public void setMipavOrigin(float[] mipavOrigin)
- Parameters:
mipavOrigin
-
-
setPatientID
public void setPatientID(java.lang.String IDnum)
allows a maximum of 10 characters to set the patient ID string.- Parameters:
IDnum
- DOCUMENT ME!
-
setRegular
public void setRegular(char ch)
supply the value of regular character.- Parameters:
ch
- DOCUMENT ME!
-
setScale
public void setScale(float scale)
DOCUMENT ME!- Parameters:
scale
- DOCUMENT ME!
-
setScanNum
public void setScanNum(java.lang.String num)
allows a maximum of 10 characters to set the scannum string.- Parameters:
num
- DOCUMENT ME!
-
setSessionErr
public void setSessionErr(short s)
supply the value of session error.- Parameters:
s
- DOCUMENT ME!
-
setSizeOfHeader
public void setSizeOfHeader(int size)
DOCUMENT ME!- Parameters:
size
- DOCUMENT ME!
-
setSmax
public void setSmax(int s)
sets smax. if supplied value is less than smin, the smin gets reset to the supplied value as well, so that smin is still no greater than smax.- Parameters:
s
- DOCUMENT ME!
-
setSmin
public void setSmin(int s)
sets smin. if supplied value is greater than smax, the smax gets reset to the supplied value as well, so that smax is still no less than smin.- Parameters:
s
- DOCUMENT ME!
-
setStartField
public void setStartField(int field)
supplies the submitted value to the start_field variable.- Parameters:
field
- DOCUMENT ME!
-
setVerified
public void setVerified(float veri)
supply the value to verified.- Parameters:
veri
- DOCUMENT ME!
-
setViews
public void setViews(int view)
sets the views variable.- Parameters:
view
- DOCUMENT ME!
-
setVolsAdded
public void setVolsAdded(int vols)
supplies a value to the vols_added valiable.- Parameters:
vols
- DOCUMENT ME!
-
setVoxOffset
public void setVoxOffset(float vox)
sets vox offset value.- Parameters:
vox
- DOCUMENT ME!
-
setVoxUnits
public void setVoxUnits(java.lang.String vox)
allows no more than 4 characters for the string describing the vox units.- Parameters:
vox
- DOCUMENT ME!
-
stateChanged
public void stateChanged(java.util.Vector ce)
.ce[0] = table 0 = primary, 1 = secondary, etC ce[1] = line of table ce[2] = string name eg, "Type" ce[3] = Vector codeValue eg, "B" ce[4] = string value eg, "Big" - Parameters:
ce
- DOCUMENT ME!
-
updateFileInfos
public void updateFileInfos(FileInfoSPM fInfo)
Propogates the current file info to another FileInfoSPM except for the 3 start locations kept in funused1, funused2, funused3.It does not copy over the datatypeCode. (though, aside from, "it isn't in the about table", I can't think of a reason why it shouldn't. but it doesn't.) Also, copied over is bitPix, aux_file.
Some variables, such as the unused1, unused2, unused3, are really taken from unused, rather than from the start locations as we are re-using the funused variables. This means that if the unused variables are not right to begin with, this certainly won't correct them!
- Parameters:
fInfo
- DOCUMENT ME!
-
setString
protected java.lang.String setString(java.lang.String str, int len)
verifies string is not larger than len length; strings larger than len, are clipped before being returned.- Returns:
- String new substring
- See Also:
String.substring(int, int)
-
selectOrientationText
private java.lang.String selectOrientationText(int or)
selection of text for the table and the editpanel.- Parameters:
or
- DOCUMENT ME!- Returns:
- String the orientation string
-
-