Class ContourPlot.BufferedImageFactory

  • Enclosing class:
    ContourPlot

    public static class ContourPlot.BufferedImageFactory
    extends java.lang.Object
    Class providing convenience methods for converting Images to BufferedImages.
    Since:
    1.0
    Author:
    hageldave
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.awt.image.BufferedImage get​(java.awt.Image img, int imgType)
      Creates a new BufferedImage of the specified imgType and same size as the provided image and draws the provided Image onto the new BufferedImage.
      static java.awt.image.BufferedImage getINT_ARGB​(int width, int height)
      Instancing method for BufferedImage of type BufferedImage.TYPE_INT_ARGB
      static java.awt.image.BufferedImage getINT_ARGB​(java.awt.Dimension d)
      Instancing method for BufferedImage of type BufferedImage.TYPE_INT_ARGB
      static java.awt.image.BufferedImage getINT_ARGB​(java.awt.Image img)
      shortcut for get(img, BufferedImage.TYPE_INT_ARGB).
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • BufferedImageFactory

        private BufferedImageFactory()
    • Method Detail

      • getINT_ARGB

        public static java.awt.image.BufferedImage getINT_ARGB​(java.awt.Image img)
        shortcut for get(img, BufferedImage.TYPE_INT_ARGB).
        Parameters:
        img - to be copied to BufferedImage of type INT_ARGB
        Returns:
        a BufferedImage copy of the provided Image
        Since:
        1.0
      • get

        public static java.awt.image.BufferedImage get​(java.awt.Image img,
                                                       int imgType)
        Creates a new BufferedImage of the specified imgType and same size as the provided image and draws the provided Image onto the new BufferedImage.
        Parameters:
        img - to be copied to BufferedImage
        imgType - of the BufferedImage. See BufferedImage(int, int, int) for details on the available imgTypes.
        Returns:
        a BufferedImage copy of the provided Image
        Since:
        1.0
      • getINT_ARGB

        public static java.awt.image.BufferedImage getINT_ARGB​(java.awt.Dimension d)
        Instancing method for BufferedImage of type BufferedImage.TYPE_INT_ARGB
        Parameters:
        d - dimension of the created BufferedImage
        Returns:
        a new BufferedImage of specified dimension and type TYPE_INT_ARGB
        Since:
        1.0
      • getINT_ARGB

        public static java.awt.image.BufferedImage getINT_ARGB​(int width,
                                                               int height)
        Instancing method for BufferedImage of type BufferedImage.TYPE_INT_ARGB
        Parameters:
        width - of the created BufferedImage
        height - of the created BufferedImage
        Returns:
        a new BufferedImage of specified dimension and type TYPE_INT_ARGB
        Since:
        1.0