java.lang.Object | |
↳ | org.jfree.chart.encoders.SunJPEGEncoderAdapter |
Adapter class for the Sun JPEG Encoder. The ImageEncoderFactory
will only return a reference to this class by default if the library has
been compiled under a JDK 1.4+ and is being run using a JRE 1.4+.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Creates a new
SunJPEGEncoderAdapter instance. |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Encodes an image in JPEG format.
| |||||||||||
Encodes an image in JPEG format and writes it to an output stream.
| |||||||||||
Returns the quality of the image encoding, which is a number in the
range 0.0f to 1.0f (higher values give better quality output, but larger
file sizes).
| |||||||||||
Returns
false always, indicating that this encoder does not
encode alpha transparency. | |||||||||||
Set whether the encoder should encode alpha transparency (this is not
supported for JPEG, so this method does nothing).
| |||||||||||
Set the quality of the image encoding.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() | |||||||||||
![]() |
Creates a new SunJPEGEncoderAdapter
instance.
Encodes an image in JPEG format.
bufferedImage | the image to be encoded (null not
permitted). |
---|
IOException | if there is an I/O problem. |
---|---|
NullPointerException | if bufferedImage is
null .
|
Encodes an image in JPEG format and writes it to an output stream.
bufferedImage | the image to be encoded (null not
permitted). |
---|---|
outputStream | the OutputStream to write the encoded image to
(null not permitted). |
IOException | if there is an I/O problem. |
---|---|
NullPointerException | if bufferedImage is
null .
|
Returns the quality of the image encoding, which is a number in the range 0.0f to 1.0f (higher values give better quality output, but larger file sizes). The default value is 0.95f.
Returns false
always, indicating that this encoder does not
encode alpha transparency.
false
.
Set whether the encoder should encode alpha transparency (this is not supported for JPEG, so this method does nothing).
encodingAlpha | ignored. |
---|
Set the quality of the image encoding.
quality | A float representing the quality (in the range 0.0f to 1.0f). |
---|