|
xmlgraphics-commons 1.3.1 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.xmlgraphics.image.loader.impl.AbstractImageConverter
org.apache.xmlgraphics.image.loader.impl.ImageConverterG2D2Bitmap
public class ImageConverterG2D2Bitmap
This ImageConverter converts Graphics2D images to a BufferedImage.
Field Summary |
---|
Fields inherited from interface org.apache.xmlgraphics.image.loader.spi.ImageConverter |
---|
MEDIUM_CONVERSION_PENALTY, MINIMAL_CONVERSION_PENALTY, NO_CONVERSION_PENALTY |
Constructor Summary | |
---|---|
ImageConverterG2D2Bitmap()
|
Method Summary | |
---|---|
Image |
convert(Image src,
java.util.Map hints)
Converts an image into a different representation. |
ImageFlavor |
getSourceFlavor()
Returns the flavor that this converter expects. |
ImageFlavor |
getTargetFlavor()
Returns the flavor that this converter converts images into. |
protected java.awt.image.BufferedImage |
paintToBufferedImage(ImageGraphics2D g2dImage,
boolean gray,
boolean withAlpha,
int resolution)
Paints a Graphics2D image on a BufferedImage and returns this bitmap. |
protected void |
setRenderingHintsForBufferedImage(java.awt.Graphics2D g2d)
Sets rendering hints on the Graphics2D created for painting to a BufferedImage. |
Methods inherited from class org.apache.xmlgraphics.image.loader.impl.AbstractImageConverter |
---|
checkSourceFlavor, getConversionPenalty |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ImageConverterG2D2Bitmap()
Method Detail |
---|
public Image convert(Image src, java.util.Map hints)
src
- the source imagehints
- the conversion hints
protected java.awt.image.BufferedImage paintToBufferedImage(ImageGraphics2D g2dImage, boolean gray, boolean withAlpha, int resolution)
g2dImage
- the Graphics2D imagegray
- true if the generated image should be in grayscaleswithAlpha
- true if the generated image should have an alpha channelresolution
- the requested bitmap resolution
protected void setRenderingHintsForBufferedImage(java.awt.Graphics2D g2d)
g2d
- the Graphics2D instancepublic ImageFlavor getSourceFlavor()
public ImageFlavor getTargetFlavor()
|
xmlgraphics-commons 1.3.1 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |