Class AlgorithmRGBConcat

  • All Implemented Interfaces:
    java.awt.event.ActionListener, java.awt.event.WindowListener, java.lang.Runnable, java.util.EventListener

    public class AlgorithmRGBConcat
    extends AlgorithmBase
    Simple algorithm that generates an RGB image from three gray images.
    Version:
    1.0 Dec 30, 1999
    Author:
    Matthew J. McAuliffe, Ph.D.
    • Field Detail

      • destImage

        private ModelImage destImage
        Destination image where results are to be stored. Must be of type RGB.
      • reMap

        private boolean reMap
        Flag indicating whether of not to remap the data. If true and srcImage data max is < remapHighestValue data will be remapped [0-remapHighestValue] else if image max > remapHighestValue data will automatically be remapped [0-remapHighestValue].
      • commonMapping

        public boolean commonMapping
        If true, map all colors based on image min and max. If false, map each color separately based on its own min and max.
      • remapHighestValue

        private float remapHighestValue
      • srcImageB

        private ModelImage srcImageB
        Source gray scale image to be stored in the BLUE channel.
      • srcImageG

        private ModelImage srcImageG
        Source gray scale image to be stored in the GREEN channel.
      • srcImageR

        private ModelImage srcImageR
        Source gray scale image to be stored in the RED channel.
      • performBoundsChecking

        private boolean performBoundsChecking
        flag for performing bounds checking...normally should be set to true unless negative numbers are desired
    • Constructor Detail

      • AlgorithmRGBConcat

        public AlgorithmRGBConcat​(ModelImage srcImgR,
                                  ModelImage srcImgG,
                                  ModelImage srcImgB,
                                  int dataType,
                                  boolean remap,
                                  boolean commonMapping,
                                  float remapHighestValue,
                                  boolean performBoundsChecking,
                                  boolean copyAllInfo)
        Creates a new AlgorithmRGBConcat object.
        Parameters:
        srcImgR - image model where result image of the Red channel is to be stored
        srcImgG - image model where result image of the Green channel is to be stored
        srcImgB - image model where result image of the Blue channel is to be stored
        dataType - Tells if srcImage will become ARGB, ARGB_USHORT, ARGB_UINTEGER, or ARGB_FLOAT
        remap - if true and srcImage data max is < remapHighestValue data will be remapped [0-remapHighestValue] else if image max > remapHighestValue data will automatically be remapped [0-remapHighestValue].
        commonMapping -
        remapHighestValue - The highest value that will occur if remapping occurs
        performBoundsChecking - flag for performing bounds checking...normally should be set to true unless negative numbers are desired
      • AlgorithmRGBConcat

        public AlgorithmRGBConcat​(ModelImage srcImgR,
                                  ModelImage srcImgG,
                                  ModelImage srcImgB,
                                  ModelImage destImg,
                                  boolean remap,
                                  boolean commonMapping,
                                  float remapHighestValue,
                                  boolean performBoundsChecking,
                                  boolean copyAllInfo)
        Creates a new AlgorithmRGBConcat object.
        Parameters:
        srcImgR - image model where result image of the Red channel is to be stored
        srcImgG - image model where result image of the Green channel is to be stored
        srcImgB - image model where result image of the Blue channel is to be stored
        destImg - destination image image model
        remap - if true and srcImage data max is < remapHighestValue data will be remapped [0-remapHighestValue] else if image max > remapHighestValue data will automatically be remapped [0-remapHighestValue].
        commonMapping -
        remapHighestValue - The highest value that will occur if remapping occurs * @param performBoundsChecking flag for performing bounds checking...normally should be set to true unless negative numbers are desired
        copyAllInfo -
      • AlgorithmRGBConcat

        public AlgorithmRGBConcat​(ModelImage srcImgR,
                                  ModelImage srcImgG,
                                  ModelImage srcImgB,
                                  ModelImage destImg,
                                  boolean remap,
                                  boolean commonMapping,
                                  float remapHighestValue,
                                  boolean performBoundsChecking)
        Creates a new AlgorithmRGBConcat object.
        Parameters:
        srcImgR - image model where result image of the Red channel is to be stored
        srcImgG - image model where result image of the Green channel is to be stored
        srcImgB - image model where result image of the Blue channel is to be stored
        destImg - destination image image model
        remap - if true and srcImage data max is < remapHighestValue data will be remapped [0-remapHighestValue] else if image max > remapHighestValue data will automatically be remapped [0-remapHighestValue].
        commonMapping -
        remapHighestValue - The highest value that will occur if remapping occurs * @param performBoundsChecking flag for performing bounds checking...normally should be set to true unless negative numbers are desired
      • AlgorithmRGBConcat

        public AlgorithmRGBConcat​(ModelImage srcImgR,
                                  ModelImage srcImgG,
                                  ModelImage srcImgB,
                                  int dataType,
                                  boolean remap,
                                  boolean commonMapping,
                                  float remapHighestValue,
                                  boolean performBoundsChecking)
        Creates a new AlgorithmRGBConcat object.
        Parameters:
        srcImgR - image model where result image of the Red channel is to be stored
        srcImgG - image model where result image of the Green channel is to be stored
        srcImgB - image model where result image of the Blue channel is to be stored
        dataType - Tells if srcImage will become ARGB, ARGB_USHORT, ARGB_UINTEGER, or ARGB_FLOAT
        remap - if true and srcImage data max is < remapHighestValue data will be remapped [0-remapHighestValue] else if image max > remapHighestValue data will automatically be remapped [0-remapHighestValue].
        commonMapping -
        remapHighestValue - The highest value that will occur if remapping occurs
        performBoundsChecking - flag for performing bounds checking...normally should be set to true unless negative numbers are desired
    • Method Detail

      • finalize

        public void finalize()
        Prepares this class for destruction.
        Overrides:
        finalize in class AlgorithmBase
      • getImageR

        public ModelImage getImageR()
        Accessor to get imageR.
        Returns:
        DOCUMENT ME!
      • calcStoreInDest

        private void calcStoreInDest()
        Concatenate the image and store the results in the destination image.
      • calcStoreInPlace

        private void calcStoreInPlace()
        Concatenate the image Must run getImageR after running this routine.