com.jinsight.jetchart
Class PngEncoder

java.lang.Object
  extended bycom.jinsight.svg.PNGEnc
      extended bycom.jinsight.jetchart.PngEncoder

public class PngEncoder
extends PNGEnc

This class is merely an extension of com.jinsight.svg.PNGEnc, which is the real implementation of the PNG encoding algorithm. The PNGEnc class was originally held in the com.jinsight.jetchart package. However, after implementation of the SVG encoding classes it was moved to the com.jinsight.svg package. To provide seamless migration of applications developed with older versions of JetChart a subclass of PNGEnc had to be implemented and kept in the original JetChart package.

See Also:
PNGEnc

Field Summary
 
Fields inherited from class com.jinsight.svg.PNGEnc
bytePos, bytesPerPixel, compressionLevel, crc, crcValue, dataPos, ENCODE_ALPHA, encodeAlpha, endPos, filter, FILTER_LAST, FILTER_NONE, FILTER_SUB, FILTER_UP, hdrPos, height, image, leftBytes, maxPos, NO_ALPHA, out, pngBytes, priorRow, width
 
Constructor Summary
PngEncoder()
          Class constructor
PngEncoder(java.awt.Image image)
          Class constructor specifying Image to encode, with no alpha channel encoding.
PngEncoder(java.awt.Image image, boolean encodeAlpha)
          Class constructor specifying Image to encode, and whether to encode alpha.
PngEncoder(java.awt.Image image, boolean encodeAlpha, int whichFilter)
          Class constructor specifying Image to encode, whether to encode alpha, and filter to use.
PngEncoder(java.awt.Image image, boolean encodeAlpha, int whichFilter, int compLevel)
          Class constructor specifying Image source to encode, whether to encode alpha, filter to use, and compression level.
PngEncoder(java.awt.Image image, int compressionLevel, java.io.OutputStream out)
           
 
Methods inherited from class com.jinsight.svg.PNGEnc
encode, filterSub, filterUp, finalize, pngEncode, pngEncode, resizeByteArray, writeByte, writeBytes, writeBytes, writeEnd, writeHeader, writeImageData, writeInt2, writeInt4, writeString
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PngEncoder

public PngEncoder()
Class constructor


PngEncoder

public PngEncoder(java.awt.Image image)
Class constructor specifying Image to encode, with no alpha channel encoding.

Parameters:
image - A Java Image object which uses the DirectColorModel
See Also:
Image

PngEncoder

public PngEncoder(java.awt.Image image,
                  int compressionLevel,
                  java.io.OutputStream out)

PngEncoder

public PngEncoder(java.awt.Image image,
                  boolean encodeAlpha)
Class constructor specifying Image to encode, and whether to encode alpha.

Parameters:
image - A Java Image object which uses the DirectColorModel
encodeAlpha - Encode the alpha channel? false=no; true=yes
See Also:
Image

PngEncoder

public PngEncoder(java.awt.Image image,
                  boolean encodeAlpha,
                  int whichFilter)
Class constructor specifying Image to encode, whether to encode alpha, and filter to use.

Parameters:
image - A Java Image object which uses the DirectColorModel
encodeAlpha - Encode the alpha channel? false=no; true=yes
whichFilter - 0=none, 1=sub, 2=up
See Also:
Image

PngEncoder

public PngEncoder(java.awt.Image image,
                  boolean encodeAlpha,
                  int whichFilter,
                  int compLevel)
Class constructor specifying Image source to encode, whether to encode alpha, filter to use, and compression level.

Parameters:
image - A Java Image object
encodeAlpha - Encode the alpha channel? false=no; true=yes
whichFilter - 0=none, 1=sub, 2=up
compLevel - 0..9
See Also:
Image