|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.qoppa.pdfWriter.ImageParam
This class is used in the PDFGraphics object to determine how to store images in
a PDF document when any of the drawImage methods are called. The class provides
settings to decide what type of image compression to use (deflate, JPEG or JBIG2)
and in the case of JPEG, what the compression quality should be.
Use instances of this object to make a call to PDFGraphics.setImageParams. After the
call is made, all images drawn to the graphics object will be output to the PDF in the
appropriate format.
JBIG2 compression is only available when the optional JBIG2 module has been purchased.
Field Summary | |
static int |
COMPRESSION_DEFLATE
Use Deflate compression when saving images to the PDF document. |
static int |
COMPRESSION_JBIG2
Use JBIG2 compression when saving images to the PDF document. |
static int |
COMPRESSION_JPEG
Use JPEG compression when saving images to the PDF document. |
Constructor Summary | |
ImageParam()
Constructs a default image parameters object. |
|
ImageParam(int compression)
Constructs an ImageParam object with the given compression type. |
|
ImageParam(int compression,
float quality)
Constructs an ImageParam object with the given compression type and quality setting. |
Method Summary | |
Object |
clone()
Clones this object. |
int |
getCompression()
Gets the compression type used when writing images to the PDF document. |
float |
getQuality()
Gets the current quality settings. |
void |
setCompression(int compression)
Sets the compression type used when writing images to the PDF document. |
void |
setQuality(float quality)
Sets the current quality setting. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int COMPRESSION_DEFLATE
public static final int COMPRESSION_JPEG
public static final int COMPRESSION_JBIG2
Constructor Detail |
public ImageParam()
public ImageParam(int compression)
compression
- The type of compression.public ImageParam(int compression, float quality)
compression
- The type of compression.quality
- The quality setting.Method Detail |
public int getCompression()
public void setCompression(int compression)
compression
- The new compression type.public float getQuality()
public void setQuality(float quality)
quality
- The new compression quality. The value will be bounded to >= 0.1 and <= 1.0public Object clone()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |