Class Analyze75Image

All Implemented Interfaces:
ReadableImage, WritableImage, AutoCloseable, Cloneable

public class Analyze75Image extends ANZImage implements AutoCloseable
This class is a representation of a multi-dimensional image in the Analyze 7.5 format. An Analyze75Image can be created from two data sources (one for the header, the other for the image data), or it can be created afresh.

Image data for images loaded from disk remain on disk, and have their pixel loaded as required; image data loaded from streams or created afresh reside in memory.

Both big-endian and little-endian byte ordering are implemented and supported. When reading existing images, the byte order is auto-detected from the header file. When existing images are copied or modified, the original byte order is retained. For images newly-created from scratch by this package, the byte ordering is the native byte order.

N.B. The Analyze format requires that for BINARY images, individual slices must begin on a byte boundary. In this implementation, that restriction is removed. If you wish to maintain compatibility with Analyze and other programs that maintain this restriction, ensure that a multi-slice/multi-frame images have slices with a number of pixels that is a multiple of 8 (bits).

  • Field Details

    • COMPRESSED_PROPERTY_KEY

      public static final String COMPRESSED_PROPERTY_KEY
      The property value key for setting whether Analyze 7.5 images should be stored compressed, or uncompressed.
      See Also:
    • DEFAULT_COMPRESSED

      public static final boolean DEFAULT_COMPRESSED
      Whether to store Analyze 7.5 images compressed by default.
      See Also:
  • Constructor Details

    • Analyze75Image

      public Analyze75Image()
      Creates an uninitialised instance of an Analyze75Image. Needed so that newInstance() method can be called on the class.
    • Analyze75Image

      public Analyze75Image(short nCols, short nRows, short nSlices, short nFrames, ANZPixFormat dataType) throws ANZException
      Creates a new in-memory Analyze75Image. This image exists in memory, and will only be written with an explicit write() method call.
      Parameters:
      nCols - the number of columns in the image x-direction.
      nRows - the number of rows in the image y-direction.
      nSlices - the number of slice in the image.
      nFrames - the number of frames (time points) in the image.
      dataType - the ANZPixFormat for the image. If dataType is not one of the original Analyze 7.5 pixel formats, then an ANZException is thrown.
      Throws:
      ANZException - if the image cannot be created.
    • Analyze75Image

      public Analyze75Image(ANZPixFormat dataType, Short... dims) throws ANZException, IOException
      Creates a new in-memory Analyze75Image. This image exists in memory, and will only be written with an explicit write() method call.
      Parameters:
      dataType - an ANZPixFormat.
      dims - the number of samples in each of the image dimensions. The number of arguments supplied determines the dimensionality of the image.
      Throws:
      ANZException - if the header cannot be created.
      IOException - if an I/O error occurs.
    • Analyze75Image

      public Analyze75Image(String fileName, ANZPixFormat dataType, Short... dims) throws IOException, ANZException
      Creates a new disk-based Analyze75Image. After manipulation, a call to the close() method is necessary for any changes to be reflected on disk.
      Parameters:
      fileName - the root of the Analyze file name (i.e. without any ".img" ".hdr", ".img.gz" or ".hdr.gz" extension). If the fileName does have an extension, then this will be handled gracefully.
      dims - the number of samples in each of the image dimensions. The number of arguments supplied determines the dimensionality of the image.
      dataType - an ANZPixFormat.
      Throws:
      ANZException - if the header cannot be created.
      IOException - if an I/O error occurs.
    • Analyze75Image

      public Analyze75Image(Analyze75Header hdr) throws ANZException
      Creates a new in-memory Analyze75Image, using information from an existing Analyze75header. This image exists in memory, and will only be written with an explicit write() method call. The supplied Analyze75Header object is cloned and can therefore be re-used.
      Parameters:
      hdr - the Analyze75Header that will be used for dimensional information etc.
      Throws:
      ANZException - if the header supplied is invalid.
    • Analyze75Image

      public Analyze75Image(String fileName, short nCols, short nRows, short nSlices, short nFrames, ANZPixFormat dataType) throws IOException, ANZException
      Creates a new disk-based Analyze75Image. After manipulation, a call to the ANZImage.close() method is necessary for any changes to the header to be reflected on disk.
      Parameters:
      fileName - the root of the Analyze file name (i.e. without the ".img" or ".hdr" extension). If the fileName does have an extension, then this will be handled.
      nCols - the number of columns in the image x-direction.
      nRows - the number of rows in the image y-direction.
      nSlices - the number of slice in the image.
      nFrames - the number of frames (time points) in the image.
      dataType - the ANZPixFormat for the image. If dataType is not one of the original Analyze 7.5 pixel formats, then an ANZException is thrown.
      Throws:
      ANZException - if the Analyze75Image cannot be instantiated.
      IOException - if an I/O error occurs.
    • Analyze75Image

      public Analyze75Image(File f, Analyze75Header header) throws IOException, ANZException
      Creates a new disk-based Analyze75Image, using an existing header as a template for the new image. After manipulation, a call to the close() method is necessary for any changes to the header to be reflected on disk.
      Parameters:
      f - the File object that will form the root of the Analyze file name (i.e. without the ".img" or ".hdr" extension). If f's name does have an extension, then this will be handled.
      header - the Analyze75Header to use as the template.
      Throws:
      ANZException - if the new image cannot be created on disk.
      IOException - if an I/O error occurs.
    • Analyze75Image

      public Analyze75Image(String fileName, Analyze75Header header) throws ANZException, IOException
      Creates a new disk-based Analyze75Image, using an existing header as a template for the new image. After manipulation, a call to the close() method is necessary for any changes to the header to be reflected on disk.
      Parameters:
      fileName - the root of the Analyze file name (i.e. without the ".img" or ".hdr" extension). If the fileName does have an extension, then this will be handled.
      header - the Analyze75Header to use as the template.
      Throws:
      ANZException - if the new image cannot be created.
      IOException - if an I/O error occurs.
    • Analyze75Image

      public Analyze75Image(String fileName, String mode) throws InvalidImageException, IOException, FileNotFoundException
      Opens an existing Analyze75Image, with pixel data remaining on disk until requested.
      Parameters:
      fileName - the name of the image file.
      mode - the open mode. Can be either "r" (read-only) or "rw" (read-write).
      Throws:
      InvalidImageException - if the image cannot be opened or loaded, or if mode is invalid.
      FileNotFoundException - if the image file doesn't exist.
      IOException - if an I/O error occurs.
  • Method Details

    • getPreferredCompressed

      public static boolean getPreferredCompressed()
      Returns the user's preference about whether Analyze 7.5 images should be stored compressed.

      If the system property "analyze.compressed" exists, and the property value is either "true" or "false", then the user's preference is overridden by the property value.

      Returns:
      true if the user prefers to store Analyze 7.5 images compressed; false otherwise.
    • savePreferredCompressed

      public static void savePreferredCompressed(boolean compressed)
      Sets the user's preference about whether Analyze 7.5 images should be stored compressed.
      Parameters:
      compressed - true if the user prefers to store Analyze 7.5 images compressed.
    • getPreviewIcon

      public static PreviewIcon getPreviewIcon(File f, boolean withImagePreview)
      Returns the PreviewIcon for an Analyze75Image header, or null if the supplied File does not represent an Analyze 7.5 image header.
      Parameters:
      f - the File to be tested.
      withImagePreview - whether a image preview is to be generated. Generating an image preview will take longer than not generating one.
      Returns:
      PreviewIcon if the File produces an Analyze75Image header; null otherwise.
    • isFlipped

      public boolean isFlipped()
      Returns true if this Analyze75Image is flipped.
      Returns:
      true if this Analyze75Image is flipped; false otherwise.
    • getOrient

      public byte getOrient() throws InvalidImageException
      Gets the orientation of this Analyze75Image.
      Returns:
      the orientation code, one of:
      Throws:
      InvalidImageException - if the orientation cannot be gotten.
    • getNSliceLocations

      public int getNSliceLocations()
      For Analyze 7.5 images, all slices in a block are parallel and evenly-spaced. As long as the slice-separation is non-zero, the number of slice locations is equal to the dimensions of the slice dimension.
      Specified by:
      getNSliceLocations in interface ReadableImage
      Returns:
      1 if the slice separation is zero; the size of the slice dimension otherwise.
    • setImagePositionPatient

      public void setImagePositionPatient(org.jogamp.vecmath.Point3f position, int slice)
      This action is not supported by the Analyze 7.5 file format, so this method has no effect. All slices are parallel in a block, and the position of individual slices may not be set.
      Specified by:
      setImagePositionPatient in interface WritableImage
      Parameters:
      position - the position of the first pixel in the volume.
      slice - the slice number in the volume.
    • setImageOrientationPatient

      public void setImageOrientationPatient(org.jogamp.vecmath.Vector3f[] orientation, int slice)
      This action is not supported by the Analyze 7.5 file format, so this method has no effect. All slices are parallel in a block, and the position of individual slices may not be set.
      Specified by:
      setImageOrientationPatient in interface WritableImage
      Specified by:
      setImageOrientationPatient in class MultiSliceImage
      Parameters:
      orientation - the direction cosines of the image row, column and (optionally) slice directions respectively in Left,Posterior,Superior (LPS) coordinates.
      slice - the slice number in the volume.
    • supportsIntensityRescaling

      public boolean supportsIntensityRescaling()
      Returns false because Analyze 7.5 images do not support intensity rescaling.
      Specified by:
      supportsIntensityRescaling in interface WritableImage
      Returns:
      false.
    • getIntensityRescale

      public float[] getIntensityRescale()
      Intensity rescaling is not supported by Analyze 7.5 format, so this method always returns float[] [1.0f, 0.0f].
      Specified by:
      getIntensityRescale in interface ReadableImage
      Returns:
      the array [1.0f, 0.0f].
    • setIntensityRescale

      public void setIntensityRescale(float rescaleSlope, float rescaleIntercept) throws InvalidImageException
      Intensity rescaling is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setIntensityRescale in interface WritableImage
      Parameters:
      rescaleSlope - ignored.
      rescaleIntercept - ignored.
      Throws:
      InvalidImageException - if rescaling cannot be set for this image.
    • setRescaleUnits

      public void setRescaleUnits(com.xinapse.dicom.RescaleUnits units)
      This action is not supported by the Analyze file format, so this method does nothing.
      Specified by:
      setRescaleUnits in interface WritableImage
      Parameters:
      units - ignored.
    • setOrient

      public void setOrient(byte orient) throws ANZException
      Sets the orientation of this Analyze75Image.
      Parameters:
      orient - the orientation code for the image. Must be one of:
      Throws:
      ANZException - if the orient is invalid, or if the orientation cannot be set.
    • appendAuditInfo

      public void appendAuditInfo(String name, String value)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      appendAuditInfo in interface WritableImage
      Parameters:
      name - the audit information name.
      value - the audit information value.
    • getPatientPosition

      public PatientPosition getPatientPosition()
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getPatientPosition in interface ReadableImage
      Returns:
      null.
    • setPatientPosition

      public void setPatientPosition(PatientPosition position)
      This action is not supported by the Analyze file format, so this method does nothing.
      Specified by:
      setPatientPosition in interface WritableImage
      Parameters:
      position - the position in which the patient is lying in the scanning equipment. e.g. PatientPosition.HFS (head-first supine).
    • setScanTR

      public void setScanTR(Float TR)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setScanTR in interface WritableImage
      Parameters:
      TR - the scan repetition time.
    • setScanTI

      public void setScanTI(Float TI)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setScanTI in interface WritableImage
      Parameters:
      TI - the scan inversion time.
    • setScanTE

      public void setScanTE(Float TE)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setScanTE in interface WritableImage
      Parameters:
      TE - the scan echo time.
    • setScanTE

      public void setScanTE(Float TE, int slice)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setScanTE in interface WritableImage
      Parameters:
      TE - the scan echo time.
      slice - the slice number for which to set the TE.
    • setSaturationFreqOffsetPPM

      public void setSaturationFreqOffsetPPM(Float freqOffset)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setSaturationFreqOffsetPPM in interface WritableImage
      Parameters:
      freqOffset - the saturation frequency offset in PPM.
    • setSaturationFreqOffsetPPM

      public void setSaturationFreqOffsetPPM(Float freqOffset, int slice)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setSaturationFreqOffsetPPM in interface WritableImage
      Parameters:
      freqOffset - the saturation frequency offset in PPM.
      slice - the slice number for which to set the saturation frequency offset.
    • setEchoTrainLength

      public void setEchoTrainLength(Integer etl)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setEchoTrainLength in interface WritableImage
      Parameters:
      etl - the echo train length.
    • setFlipAngle

      public void setFlipAngle(Float flipAngle)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setFlipAngle in interface WritableImage
      Parameters:
      flipAngle - the scan flip angle.
    • getSliceThickness

      public Float getSliceThickness()
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getSliceThickness in interface ReadableImage
      Returns:
      null;
    • setSliceThickness

      public void setSliceThickness(Float thickness)
      This action is not supported by the Analyze file format, so this method does nothing.
      Specified by:
      setSliceThickness in interface WritableImage
      Parameters:
      thickness - ignored.
    • getScanDate

      public Date getScanDate()
      Scan dates are not supported by Analyze 7.5 format.
      Specified by:
      getScanDate in interface ReadableImage
      Returns:
      null always.
    • setScanDate

      public void setScanDate(Date scanDate)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setScanDate in interface WritableImage
      Parameters:
      scanDate - the new scan date/time.
    • getPulseSequence

      public String getPulseSequence()
      Pulse sequence names are not supported by Analyze 7.5 for,at.
      Specified by:
      getPulseSequence in interface ReadableImage
      Returns:
      null always.
    • setPulseSequence

      public void setPulseSequence(String seqName)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setPulseSequence in interface WritableImage
      Parameters:
      seqName - the new scanning sequence name.
    • getScanningSequence

      public PulseSequenceType getScanningSequence()
      Scan sequences are not supported by Analyze 7.5 format.
      Specified by:
      getScanningSequence in interface ReadableImage
      Returns:
      null.
    • setScanningSequence

      public void setScanningSequence(PulseSequenceType seq)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setScanningSequence in interface WritableImage
      Parameters:
      seq - the new scanning sequence name.
    • getSequenceVariant

      public PulseSequenceVariant getSequenceVariant()
      Scanning sequence variants are not supported by Analyze 7.5 format.
      Specified by:
      getSequenceVariant in interface ReadableImage
      Returns:
      null.
    • getSeriesDescription

      public String getSeriesDescription()
      Series descriptions are not supported by Analyze 7.5 format.
      Specified by:
      getSeriesDescription in interface ReadableImage
      Returns:
      null.
    • getSeriesNumber

      public Integer getSeriesNumber()
      Series numbers are not supported by Analyze 7.5 format.
      Specified by:
      getSeriesNumber in interface ReadableImage
      Returns:
      null.
    • setSequenceVariant

      public void setSequenceVariant(PulseSequenceVariant seqVar)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setSequenceVariant in interface WritableImage
      Parameters:
      seqVar - the new scanning sequence variant name.
    • setSeriesNumber

      public void setSeriesNumber(Integer seriesNumber)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setSeriesNumber in interface WritableImage
      Parameters:
      seriesNumber - the new series number.
    • setSeriesDescription

      public void setSeriesDescription(String description)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setSeriesDescription in interface WritableImage
      Parameters:
      description - the new series description.
    • getPatientName

      public String getPatientName()
      Patient names are not supported by Analyze 7.5 format.
      Specified by:
      getPatientName in interface ReadableImage
      Returns:
      null.
    • getPatientID

      public String getPatientID()
      Returns the Patient ID set in the image header.
      Specified by:
      getPatientID in interface ReadableImage
      Returns:
      the Patient ID set in the image header.
    • getPatientDoB

      public Date getPatientDoB()
      Patient's Birth Date is not supported by Analyze 7.5 format.
      Specified by:
      getPatientDoB in interface ReadableImage
      Returns:
      null.
    • getPatientSex

      public com.xinapse.dicom.Sex getPatientSex()
      Description copied from interface: ReadableImage
      Returns the patient sex for this image.
      Specified by:
      getPatientSex in interface ReadableImage
      Returns:
      the patient's sex image, or Sex.OTHER if the patient's sex can't be found.
    • getStudyID

      public String getStudyID()
      Study ID is not supported by Analyze 7.5 format.
      Specified by:
      getStudyID in interface ReadableImage
      Returns:
      null.
    • getScanTR

      public Float getScanTR()
      This action is not supported by the Analyze 7.5 format, so this method always returns null.
      Specified by:
      getScanTR in interface ReadableImage
      Returns:
      null always.
    • getScanTI

      public Float getScanTI()
      This action is not supported by the Analyze 7.5 format, so this method always returns null.
      Specified by:
      getScanTI in interface ReadableImage
      Returns:
      null always.
    • getScanTE

      public Float getScanTE()
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getScanTE in interface ReadableImage
      Returns:
      null always.
    • getScanTE

      public Float getScanTE(int index)
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getScanTE in interface ReadableImage
      Parameters:
      index - the index for which to return the echo time.
      Returns:
      null always.
    • getSaturationFreqOffsetPPM

      public Float getSaturationFreqOffsetPPM()
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getSaturationFreqOffsetPPM in interface ReadableImage
      Returns:
      null always.
    • getSaturationFreqOffsetPPM

      public Float getSaturationFreqOffsetPPM(int index)
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getSaturationFreqOffsetPPM in interface ReadableImage
      Parameters:
      index - the index for which to return the saturation frequency offset.
      Returns:
      null always.
    • getEchoTrainLength

      public Integer getEchoTrainLength()
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getEchoTrainLength in interface ReadableImage
      Returns:
      null always.
    • getFlipAngle

      public Float getFlipAngle()
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getFlipAngle in interface ReadableImage
      Returns:
      null always.
    • getSliceDWbValue

      public Float getSliceDWbValue(int slice)
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getSliceDWbValue in interface ReadableImage
      Parameters:
      slice - the slice number for which to get the b-value.
      Returns:
      null always.
    • getFrameDWbValue

      public Float getFrameDWbValue(int frame)
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getFrameDWbValue in interface ReadableImage
      Parameters:
      frame - the frame number for which to get the b-value.
      Returns:
      null always.
    • setSliceDWbValue

      public void setSliceDWbValue(float bValue, int slice)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setSliceDWbValue in interface WritableImage
      Parameters:
      bValue - the diffusion-weighting b-value.
      slice - the slice number for which to set the b-value.
    • setFrameDWbValue

      public void setFrameDWbValue(float bValue, int frame)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setFrameDWbValue in interface WritableImage
      Parameters:
      bValue - the diffusion-weighting b-value.
      frame - the frame number for which to set the b-value.
    • getSliceDWGradientVector

      public org.jogamp.vecmath.Vector3f getSliceDWGradientVector(int slice)
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getSliceDWGradientVector in interface ReadableImage
      Parameters:
      slice - the slice number for which to return the gradient-vector.
      Returns:
      null always.
    • getFrameDWGradientVector

      public org.jogamp.vecmath.Vector3f getFrameDWGradientVector(int frame)
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getFrameDWGradientVector in interface ReadableImage
      Parameters:
      frame - the frame number for which to return the gradient-vector.
      Returns:
      null always.
    • setSliceDWGradientVector

      public void setSliceDWGradientVector(org.jogamp.vecmath.Vector3f gradVec, int slice)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setSliceDWGradientVector in interface WritableImage
      Parameters:
      gradVec - the diffusion-weighting gradient vector.
      slice - the slice number for which to set the gradient vector.
    • setFrameDWGradientVector

      public void setFrameDWGradientVector(org.jogamp.vecmath.Vector3f gradVec, int frame)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setFrameDWGradientVector in interface WritableImage
      Parameters:
      gradVec - the diffusion-weighting gradient vector.
      frame - the frame number for which to set the gradient vector.
    • getSliceDWBMatrix

      public float[] getSliceDWBMatrix(int slice)
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getSliceDWBMatrix in interface ReadableImage
      Parameters:
      slice - the slice number for which to get the b-matrix.
      Returns:
      null always.
    • getFrameDWBMatrix

      public float[] getFrameDWBMatrix(int frame)
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getFrameDWBMatrix in interface ReadableImage
      Parameters:
      frame - the frame number for which to get the b-matrix.
      Returns:
      null always.
    • setSliceDWBMatrix

      public void setSliceDWBMatrix(float[] bMatrix, int slice)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setSliceDWBMatrix in interface WritableImage
      Parameters:
      bMatrix - the diffusion-weighting B-matrix.
      slice - the slice number for which to set the B-matrix.
    • setFrameDWBMatrix

      public void setFrameDWBMatrix(float[] bMatrix, int frame)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setFrameDWBMatrix in interface WritableImage
      Parameters:
      bMatrix - the diffusion-weighting B-matrix.
      frame - the frame number for which to set the B-matrix.
    • getSliceTriggerDelayMS

      public Float getSliceTriggerDelayMS(int slice)
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getSliceTriggerDelayMS in interface ReadableImage
      Parameters:
      slice - the slice number for which to get the trigger delay.
      Returns:
      null always.
    • getFrameTriggerDelayMS

      public Float getFrameTriggerDelayMS(int frame)
      This action is not supported by the Analyze file format, so this method always returns null.
      Specified by:
      getFrameTriggerDelayMS in interface ReadableImage
      Parameters:
      frame - the frame number for which to get the trigger delay.
      Returns:
      null always.
    • setSliceTriggerDelayMS

      public void setSliceTriggerDelayMS(float delay, int slice)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setSliceTriggerDelayMS in interface WritableImage
      Parameters:
      delay - the trigger delay (in milliseconds).
      slice - the slice number for which to set the trigger delay.
    • setFrameTriggerDelayMS

      public void setFrameTriggerDelayMS(float delay, int frame)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setFrameTriggerDelayMS in interface WritableImage
      Parameters:
      delay - the trigger delay (in milliseconds).
      frame - the frame number for which to set the trigger delay.
    • getRescaleUnits

      public com.xinapse.dicom.RescaleUnits getRescaleUnits()
      Description copied from interface: ReadableImage
      Returns the output units of Intensity Rescale Slope and Intensity Rescale Intercept, retrieved by getIntensityRescale().
      Specified by:
      getRescaleUnits in interface ReadableImage
      Overrides:
      getRescaleUnits in class ANZImage
      Returns:
      the RescaleUnits describing the physical meaning of the pixel intensity units. Returns the RescaleUnits.US if the physical meaning is unknown, or arbitrary.
    • setPatientName

      public void setPatientName(String patientName)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setPatientName in interface WritableImage
      Parameters:
      patientName - is ignored.
    • setPatientID

      public void setPatientID(String patientID)
      Description copied from interface: WritableImage
      Sets the patient ID for this image. If the new patient ID String is longer than is allowed by the image format, then it is truncated before being applied. No exception occurs if the image format does not support patient ID recording.
      N.B. For disk-based images, the changes in the patient ID will not be reflected on disk unless the close() method is called.
      Specified by:
      setPatientID in interface WritableImage
      Parameters:
      patientID - the new patient ID to be assigned to this image.
    • setPatientDoB

      public void setPatientDoB(Date patientDoB)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setPatientDoB in interface WritableImage
      Parameters:
      patientDoB - is ignored.
    • setPatientSex

      public void setPatientSex(com.xinapse.dicom.Sex sex)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setPatientSex in interface WritableImage
      Parameters:
      sex - is ignored.
    • setStudyID

      public void setStudyID(String studyID)
      This action is not supported by Analyze 7.5 format, so this method does nothing.
      Specified by:
      setStudyID in interface WritableImage
      Parameters:
      studyID - is ignored.
    • getMin

      public Double getMin() throws ANZException
      Description copied from interface: ReadableImage
      Returns the minimum pixel intensity in the image.
      Specified by:
      getMin in interface ReadableImage
      Overrides:
      getMin in class ANZImage
      Returns:
      the maximum pixel intensity as a Double, or null if the intensity min hasn't been calculated for this image.
      Throws:
      ANZException
    • getMax

      public Double getMax() throws ANZException
      Description copied from interface: ReadableImage
      Returns the maximum pixel intensity in the image.
      Specified by:
      getMax in interface ReadableImage
      Overrides:
      getMax in class ANZImage
      Returns:
      the maximum pixel intensity as a Double, or null if the intensity max hasn't been calculated for this image.
      Throws:
      ANZException
    • getImageTypeName

      public String getImageTypeName()
      Returns the human readable name for this type of image.
      Specified by:
      getImageTypeName in interface WritableImage
      Returns:
      the String "Analyze".
    • getCommonName

      public static String getCommonName()
      Returns the common name for this type of image.
      Returns:
      the String "Analyze".
    • main

      public static void main(String[] args)
      Run the self-test for the Analyze75Image class.
      Parameters:
      args - an array of image file names to try to open.