Class JDialogRawIO

All Implemented Interfaces:
DialogDefaultsInterface, ActionListener, FocusListener, ItemListener, WindowListener, ImageObserver, MenuContainer, Serializable, EventListener, Accessible, RootPaneContainer, WindowConstants

public class JDialogRawIO extends JDialogBase
Simple dialog to indicate type, dimensionality, of a raw image or image with a fixed length header in front of the image data. Checks the Preferences file, and will default to the most recently used JDialogRawIO values. The dialog will save the values chosen when [OK] is struck.
Version:
0.1 Aug 1, 1997, 0.2 Jun 20, 2001
Author:
Matthew J. McAuliffe, Ph.D., David Parsons
See Also:
  • Field Details

    • serialVersionUID

      private static final long serialVersionUID
      Use serialVersionUID for interoperability.
      See Also:
    • DEFAULT_IMAGE_TYPE

      private static final int DEFAULT_IMAGE_TYPE
      DOCUMENT ME!
      See Also:
    • DEFAULT_BIG_ENDIAN_BYTE_ORDER

      private static final boolean DEFAULT_BIG_ENDIAN_BYTE_ORDER
      DOCUMENT ME!
      See Also:
    • DEFAULT_DATA_OFFSET

      private static final int DEFAULT_DATA_OFFSET
      DOCUMENT ME!
      See Also:
    • DEFAULT_EXTENTS

      private static final String DEFAULT_EXTENTS
      DOCUMENT ME!
      See Also:
    • DEFAULT_RES

      private static final String DEFAULT_RES
      DOCUMENT ME!
      See Also:
    • DEFAULT_UNIT_INDEX

      private static final String DEFAULT_UNIT_INDEX
      DOCUMENT ME!
      See Also:
    • checkboxEnd

      private JCheckBox checkboxEnd
      DOCUMENT ME!
    • comboBoxUnitOfMeasure1

      private JComboBox comboBoxUnitOfMeasure1
      DOCUMENT ME!
    • comboBoxUnitOfMeasure2

      private JComboBox comboBoxUnitOfMeasure2
      DOCUMENT ME!
    • comboBoxUnitOfMeasure3

      private JComboBox comboBoxUnitOfMeasure3
      DOCUMENT ME!
    • comboBoxUnitOfMeasure4

      private JComboBox comboBoxUnitOfMeasure4
      DOCUMENT ME!
    • comboBoxUnitOfMeasure5

      private JComboBox comboBoxUnitOfMeasure5
      DOCUMENT ME!
    • dataType

      private int dataType
      DOCUMENT ME!
    • dimExtents

      private int[] dimExtents
      DOCUMENT ME!
    • endianess

      private boolean endianess
      DOCUMENT ME!
    • extents

      private int[] extents
      DOCUMENT ME!
    • labelOffset

      private JLabel labelOffset
      DOCUMENT ME!
    • offset

      private int offset
      DOCUMENT ME!
    • radioARGB

      private JRadioButton radioARGB
      DOCUMENT ME!
    • radioARGB_USHORT

      private JRadioButton radioARGB_USHORT
      DOCUMENT ME!
    • radioARGB_UINTEGER

      private JRadioButton radioARGB_UINTEGER
    • radioARGB_FLOAT

      private JRadioButton radioARGB_FLOAT
    • radioBool

      private JRadioButton radioBool
      DOCUMENT ME!
    • radioByte

      private JRadioButton radioByte
      DOCUMENT ME!
    • radioDouble

      private JRadioButton radioDouble
      DOCUMENT ME!
    • radioFloat

      private JRadioButton radioFloat
      DOCUMENT ME!
    • radioInt

      private JRadioButton radioInt
      DOCUMENT ME!
    • radioLong

      private JRadioButton radioLong
      DOCUMENT ME!
    • radioShort

      private JRadioButton radioShort
      DOCUMENT ME!
    • radioUByte

      private JRadioButton radioUByte
      DOCUMENT ME!
    • radioUInt

      private JRadioButton radioUInt
      DOCUMENT ME!
    • radioUShort

      private JRadioButton radioUShort
      DOCUMENT ME!
    • resolutions

      private float[] resolutions
      DOCUMENT ME!
    • textDim1

      private JTextField textDim1
      DOCUMENT ME!
    • textDim2

      private JTextField textDim2
      DOCUMENT ME!
    • textDim3

      private JTextField textDim3
      DOCUMENT ME!
    • textDim4

      private JTextField textDim4
      DOCUMENT ME!
    • textDim5

      private JTextField textDim5
      DOCUMENT ME!
    • textOffset

      private JTextField textOffset
      DOCUMENT ME!
    • textRes1

      private JTextField textRes1
      DOCUMENT ME!
    • textRes2

      private JTextField textRes2
      DOCUMENT ME!
    • textRes3

      private JTextField textRes3
      DOCUMENT ME!
    • textRes4

      private JTextField textRes4
      DOCUMENT ME!
    • textRes5

      private JTextField textRes5
      DOCUMENT ME!
    • unitsOfMeasure

      private int[] unitsOfMeasure
      DOCUMENT ME!
  • Constructor Details

    • JDialogRawIO

      public JDialogRawIO(Frame theParentFrame, String title)
      Creates new dialog for entering necessary info to read in RAW image.
      Parameters:
      theParentFrame - Parent frame
      title - Title of dialog frame
  • Method Details

    • actionPerformed

      public void actionPerformed(ActionEvent event)
      Closes dialog box when the OK button is pressed and sets the variables.
      Specified by:
      actionPerformed in interface ActionListener
      Overrides:
      actionPerformed in class JDialogBase
      Parameters:
      event - Event that triggers this function
    • extractExtents

      public void extractExtents(String commas)
      Inserts the values given by the preference file into the extents fields of the dialog.
      Parameters:
      commas - Delimited string representing the extents.
    • extractResolutions

      public void extractResolutions(String commas)
      Inserts the values given by the preference file into the resolutions fields of the dialog.
      Parameters:
      commas - Delimited string representing the resolutions.
    • extractUnitIndeces

      public void extractUnitIndeces(String commas)
      Inserts the values given by the preference file into the units of measure fields of the dialog.
      Parameters:
      commas - Delimited string representing the units of measure.
    • getDataType

      public int getDataType()
      Accessor that returns the data type.
      Returns:
      The data type
    • getEndianess

      public boolean getEndianess()
      Accessor that returns the endianess.
      Returns:
      boolean indicating the endianess
    • getExtents

      public int[] getExtents()
      Accessor that returns the extents.
      Returns:
      The extents in an array
    • getOffset

      public int getOffset()
      Accessor that returns the offset.
      Returns:
      The offset
    • getResolutions

      public float[] getResolutions()
      Accessor that returns the resolutions.
      Returns:
      The resolutions in an array
    • getUnitsOfMeasure

      public int[] getUnitsOfMeasure()
      Accessor that returns the units of measure for each dimension.
      Returns:
      Int array indicating the unit of measure
    • makeExtentsString

      public String makeExtentsString()
      Makes a single string out of the extents.
      Returns:
      String with extents separated by commas.
    • makeResolutionString

      public String makeResolutionString()
      Makes a single string out of the resolutions.
      Returns:
      String with resolutions separated by commas.
    • makeUnitString

      public String makeUnitString()
      Makes a single string out of the units of measure.
      Returns:
      String with units of measure separated by commas.
    • setBigEndian

      public void setBigEndian(boolean b)
      Marks the checkmark when true. Equivalent to checkboxEnd.setSelected(b)
      Parameters:
      b - Value for the checkbox "Big Endian"
    • setDataOffset

      public void setDataOffset(String o)
      Method to preset the image data offset.
      Parameters:
      o - The offset
    • setDataType

      public void setDataType(int t)
      Accessor that sets the appropriate radio button as given by the image-data type.
      Parameters:
      t - The data type
    • init

      private void init()
      Initializes the GUI components and makes the dialog visible.
    • setComboBox

      private void setComboBox(JComboBox cBox)
      Sets combo box choices that match resolution units listed in FileInfoBase in the same order.
      Parameters:
      cBox - Combo box to setup to display the units