Class RadialShadingContext
java.lang.Object
org.apache.pdfbox.pdmodel.graphics.shading.ShadingContext
org.apache.pdfbox.pdmodel.graphics.shading.RadialShadingContext
- All Implemented Interfaces:
PaintContext
AWT PaintContext for radial shading.
Performance improvement done as part of GSoC2014, Tilman Hausherr is the
mentor.
- Author:
- Andreas Lehmkühler, Shaola Ren
-
Field Summary
Fields inherited from class org.apache.pdfbox.pdmodel.graphics.shading.ShadingContext
bboxRect, colorSpace, deviceBounds, maxBBoxX, maxBBoxY, minBBoxX, minBBoxY, outputColorModel, shading, shadingColorSpace, shadingTinttransform
-
Constructor Summary
ConstructorsConstructorDescriptionRadialShadingContext
(PDShadingType3 shading, ColorModel colorModel, AffineTransform xform, Matrix ctm, int pageHeight, Rectangle dBounds) Constructor creates an instance to be used for fill operations. -
Method Summary
Methods inherited from class org.apache.pdfbox.pdmodel.graphics.shading.ShadingContext
convertToRGB, getShadingTintTransform
-
Constructor Details
-
RadialShadingContext
public RadialShadingContext(PDShadingType3 shading, ColorModel colorModel, AffineTransform xform, Matrix ctm, int pageHeight, Rectangle dBounds) throws IOException Constructor creates an instance to be used for fill operations.- Parameters:
shading
- the shading type to be usedcolorModel
- the color model to be usedxform
- transformation for user to device spacectm
- the transformation matrixdBounds
- device boundspageHeight
- height of the current page- Throws:
IOException
-
-
Method Details
-
dispose
public void dispose()- Specified by:
dispose
in interfacePaintContext
-
getColorModel
- Specified by:
getColorModel
in interfacePaintContext
-
getRaster
- Specified by:
getRaster
in interfacePaintContext
-
getCoords
public float[] getCoords()Returns the coords values.- Returns:
- the coords values as array
-
getDomain
public float[] getDomain()Returns the domain values.- Returns:
- the domain values as array
-
getExtend
public boolean[] getExtend()Returns the extend values.- Returns:
- the extend values as array
-
getFunction
Returns the function.- Returns:
- the function
- Throws:
IOException
- if something goes wrong
-