Interface ImageEncoder

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      byte[] encode​(java.awt.image.RenderedImage image)
      Encodes an AWT image into a byte array in a particular format.
      float getQuality()
      Return the quality of the image encoding.
      boolean isEncodingAlpha()
      Returns whether to encode the alpha transparency.
      void setEncodingAlpha​(boolean encodeAlpha)
      Sets whether to encode the alpha transparency.
      void setQuality​(float quality)
      Sets the quality of the image encoding.
    • Method Detail

      • encode

        byte[] encode​(java.awt.image.RenderedImage image)
               throws java.io.IOException
        Encodes an AWT image into a byte array in a particular format.
        Throws:
        java.io.IOException
      • getQuality

        float getQuality()
        Return the quality of the image encoding.
      • setQuality

        void setQuality​(float quality)
        Sets the quality of the image encoding. Simply does nothing if the encoder does not support it.
      • isEncodingAlpha

        boolean isEncodingAlpha()
        Returns whether to encode the alpha transparency.
      • setEncodingAlpha

        void setEncodingAlpha​(boolean encodeAlpha)
        Sets whether to encode the alpha transparency. Simply does nothing if the encoder does not support it.