public abstract class AbstractImageAdapter extends java.lang.Object implements PDFImage
Modifier and Type | Field and Description |
---|---|
protected org.apache.xmlgraphics.image.loader.Image |
image
the image
|
Constructor and Description |
---|
AbstractImageAdapter(org.apache.xmlgraphics.image.loader.Image image,
java.lang.String key)
Creates a new PDFImage from an Image instance.
|
Modifier and Type | Method and Description |
---|---|
protected java.awt.color.ICC_Profile |
getEffectiveICCProfile()
Returns the effective ICC profile for the image.
|
int |
getHeight()
Get the image height in pixels.
|
PDFICCStream |
getICCStream()
Get the ICC stream for this image.
|
protected java.awt.color.ColorSpace |
getImageColorSpace()
Returns the image's color space.
|
java.lang.String |
getKey()
Key to look up XObject.
|
java.lang.String |
getMask()
Get the PDF reference for a bitmap mask.
|
java.lang.String |
getSoftMask() |
PDFReference |
getSoftMaskReference()
Get the PDF reference for a soft mask.
|
PDFColor |
getTransparentColor()
Get the transparent color.
|
int |
getWidth()
Get the image width in pixels.
|
boolean |
isInverted() |
boolean |
isPS()
Check if this image is a PostScript image.
|
boolean |
isTransparent()
Check if this image has a transparent color transparency.
|
void |
populateXObjectDictionary(PDFDictionary dict)
Populates the XObject's dictionary with additional values.
|
void |
setup(PDFDocument doc)
Setup the PDF image for the current document.
|
static PDFDeviceColorSpace |
toPDFColorSpace(java.awt.color.ColorSpace cs)
Converts a ColorSpace object to a PDFColorSpace object.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getBitsPerComponent, getColorSpace, getFilterHint, getPDFFilter, outputContents
public AbstractImageAdapter(org.apache.xmlgraphics.image.loader.Image image, java.lang.String key)
image
- the imagekey
- XObject keypublic java.lang.String getKey()
protected java.awt.color.ColorSpace getImageColorSpace()
public void setup(PDFDocument doc)
protected java.awt.color.ICC_Profile getEffectiveICCProfile()
public int getWidth()
public int getHeight()
public boolean isTransparent()
isTransparent
in interface PDFImage
public PDFColor getTransparentColor()
getTransparentColor
in interface PDFImage
public java.lang.String getMask()
public java.lang.String getSoftMask()
public PDFReference getSoftMaskReference()
getSoftMaskReference
in interface PDFImage
public boolean isInverted()
isInverted
in interface PDFImage
public boolean isPS()
public PDFICCStream getICCStream()
getICCStream
in interface PDFImage
public void populateXObjectDictionary(PDFDictionary dict)
populateXObjectDictionary
in interface PDFImage
dict
- the dictionary to fillpublic static PDFDeviceColorSpace toPDFColorSpace(java.awt.color.ColorSpace cs)
cs
- ColorSpace instanceCopyright 1999-2010 The Apache Software Foundation. All Rights Reserved.