Package com.sixlegs.png
Class PngImage
java.lang.Object
com.sixlegs.png.PngImage
- All Implemented Interfaces:
java.awt.Transparency
public class PngImage
extends java.lang.Object
implements java.awt.Transparency
-
Field Summary
Fields inherited from interface java.awt.Transparency
BITMASK, OPAQUE, TRANSLUCENT -
Constructor Summary
-
Method Summary
Modifier and Type Method Description protected java.awt.image.BufferedImagecreateImage(java.io.InputStream inputStream, java.awt.Dimension dimension)java.awt.ColorgetBackground()intgetBitDepth()intgetColorType()PngConfiggetConfig()floatgetGamma()short[]getGammaTable()intgetHeight()java.util.MapgetProperties()java.lang.ObjectgetProperty(java.lang.String string)intgetSamples()TextChunkgetTextChunk(java.lang.String string)intgetTransparency()intgetWidth()protected booleanhandlePass(java.awt.image.BufferedImage bufferedImage, int int1)protected booleanhandleProgress(java.awt.image.BufferedImage bufferedImage, float float1)protected voidhandleWarning(PngException pngException)booleanisInterlaced()protected booleanisMultipleOK(int int1)java.awt.image.BufferedImageread(java.io.File file)java.awt.image.BufferedImageread(java.io.InputStream inputStream, boolean boolean1)protected voidreadChunk(int int1, java.io.DataInput dataInput, long long1, int int2)Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
PngImage
public PngImage() -
PngImage
-
-
Method Details
-
getConfig
-
read
public java.awt.image.BufferedImage read(java.io.File file) throws java.io.IOException- Throws:
java.io.IOException
-
read
public java.awt.image.BufferedImage read(java.io.InputStream inputStream, boolean boolean1) throws java.io.IOException- Throws:
java.io.IOException
-
createImage
protected java.awt.image.BufferedImage createImage(java.io.InputStream inputStream, java.awt.Dimension dimension) throws java.io.IOException- Throws:
java.io.IOException
-
handlePass
protected boolean handlePass(java.awt.image.BufferedImage bufferedImage, int int1) -
handleProgress
protected boolean handleProgress(java.awt.image.BufferedImage bufferedImage, float float1) -
handleWarning
- Throws:
PngException
-
getWidth
public int getWidth() -
getHeight
public int getHeight() -
getBitDepth
public int getBitDepth() -
isInterlaced
public boolean isInterlaced() -
getColorType
public int getColorType() -
getTransparency
public int getTransparency()- Specified by:
getTransparencyin interfacejava.awt.Transparency
-
getSamples
public int getSamples() -
getGamma
public float getGamma() -
getGammaTable
public short[] getGammaTable() -
getBackground
public java.awt.Color getBackground() -
getProperty
public java.lang.Object getProperty(java.lang.String string) -
getProperties
public java.util.Map getProperties() -
getTextChunk
-
readChunk
protected void readChunk(int int1, java.io.DataInput dataInput, long long1, int int2) throws java.io.IOException- Throws:
java.io.IOException
-
isMultipleOK
protected boolean isMultipleOK(int int1)
-