public class KeypointPNGEncoderAdapter extends java.lang.Object implements ImageEncoder
| Constructor and Description |
|---|
KeypointPNGEncoderAdapter() |
| Modifier and Type | Method and Description |
|---|---|
byte[] |
encode(java.awt.image.BufferedImage bufferedImage)
Encodes an image in PNG format.
|
void |
encode(java.awt.image.BufferedImage bufferedImage,
java.io.OutputStream outputStream)
Encodes an image in PNG format and writes it to an
OutputStream. |
float |
getQuality()
Get the quality of the image encoding.
|
boolean |
isEncodingAlpha()
Get whether the encoder should encode alpha transparency.
|
void |
setEncodingAlpha(boolean encodingAlpha)
Set whether the encoder should encode alpha transparency (supported).
|
void |
setQuality(float quality)
Set the quality of the image encoding (supported).
|
public KeypointPNGEncoderAdapter()
public float getQuality()
getQuality in interface ImageEncoderpublic void setQuality(float quality)
setQuality in interface ImageEncoderquality - A float representing the quality.public boolean isEncodingAlpha()
isEncodingAlpha in interface ImageEncoderpublic void setEncodingAlpha(boolean encodingAlpha)
setEncodingAlpha in interface ImageEncoderencodingAlpha - Whether the encoder should encode alpha
transparency.public byte[] encode(java.awt.image.BufferedImage bufferedImage) throws java.io.IOException
encode in interface ImageEncoderbufferedImage - The image to be encoded.java.io.IOException - if there is an IO problem.public void encode(java.awt.image.BufferedImage bufferedImage, java.io.OutputStream outputStream) throws java.io.IOException
OutputStream.encode in interface ImageEncoderbufferedImage - The image to be encoded.outputStream - The OutputStream to write the encoded image to.java.io.IOException - if there is an IO problem.