Documentation of 'org.encog.util.downsample.RGBDownsample' Java class
RGBDownsample
org.encog.util.downsample

Class RGBDownsample

    • Constructor Detail

      • RGBDownsample

        public RGBDownsample()
    • Method Detail

      • downSample

        public double[] downSample(java.awt.Image image,
                                   int height,
                                   int width)
        Called to downsample the image and store it in the down sample component.
        Specified by:
        downSample in interface Downsample
        Parameters:
        image - The image to downsample.
        height - The height to downsample to.
        width - THe width to downsample to.
        Returns:
        The downsampled image.
      • downSampleRegion

        public void downSampleRegion(int x,
                                     int y)
        Called to downsample a region of the image.
        Parameters:
        x - The x coordinate of the resulting downsample.
        y - The y coordinate of the resulting downsample.
      • findBounds

        public void findBounds()
        This method is called to automatically crop the image so that whitespace is removed.
        Specified by:
        findBounds in interface Downsample
      • getCurrentBlue

        public int getCurrentBlue()
      • getCurrentGreen

        public int getCurrentGreen()
      • getCurrentRed

        public int getCurrentRed()
      • getDownSampleBottom

        public int getDownSampleBottom()
        Specified by:
        getDownSampleBottom in interface Downsample
        Returns:
        the downSampleBottom
      • getDownSampleLeft

        public int getDownSampleLeft()
        Specified by:
        getDownSampleLeft in interface Downsample
        Returns:
        the downSampleLeft
      • getDownSampleRight

        public int getDownSampleRight()
        Specified by:
        getDownSampleRight in interface Downsample
        Returns:
        the downSampleRight
      • getDownSampleTop

        public int getDownSampleTop()
        Specified by:
        getDownSampleTop in interface Downsample
        Returns:
        the downSampleTop
      • getImageHeight

        public int getImageHeight()
        Specified by:
        getImageHeight in interface Downsample
        Returns:
        the imageHeight
      • getImageWidth

        public int getImageWidth()
        Specified by:
        getImageWidth in interface Downsample
        Returns:
        the imageWidth
      • getPixelMap

        public int[] getPixelMap()
        Specified by:
        getPixelMap in interface Downsample
        Returns:
        the pixelMap
      • getRatioX

        public double getRatioX()
        Specified by:
        getRatioX in interface Downsample
        Returns:
        the ratioX
      • getRatioY

        public double getRatioY()
        Specified by:
        getRatioY in interface Downsample
        Returns:
        the ratioY
      • processImage

        public void processImage(java.awt.Image image)
        Process the image and prepare it to be downsampled.
        Specified by:
        processImage in interface Downsample
        Parameters:
        image - The image to downsample.
      • setCurrentBlue

        public void setCurrentBlue(int currentBlue)
        Set the current blue average.
        Parameters:
        currentBlue - The current blue average.
      • setCurrentGreen

        public void setCurrentGreen(int currentGreen)
        Set the current green average.
        Parameters:
        currentGreen - The current green average.
      • setCurrentRed

        public void setCurrentRed(int currentRed)
        Set the current red average.
        Parameters:
        currentRed - The current red average.
      • setPixelMap

        public void setPixelMap(int[] pixelMap)
        Set the pixel map.
        Parameters:
        pixelMap - The pixel map.
      • validate

        public void validate(int height,
                             int width)

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.