public class PdfType3Function extends AbstractPdfFunction<PdfDictionary>
For more info see ISO 32000-1, section 7.10.4 "Type 3 (Stitching) Functions".
| Constructor and Description |
|---|
PdfType3Function(double[] domain, double[] range, List<AbstractPdfFunction extends PdfDictionary>> functions, double[] bounds, double[] encode)
(see ISO-320001 Table 41).
|
PdfType3Function(PdfDictionary dict)
Instantiates a new PdfType3Function instance based on passed PdfDictionary instance.
|
| Modifier and Type | Method and Description |
|---|---|
double[] |
calculate(double[] input)
Calculates one set of input components to one set of output components.
|
boolean |
checkCompatibilityWithColorSpace(PdfColorSpace alternateSpace)
Chacks wether the output of the function matches in components with the passed by color space.
|
double[] |
getBounds()
An array of k − 1 numbers that, in combination with Domain, shall define the intervals to which each function from the Functions array shall apply.
|
double[] |
getEncode()
An array of 2 × k numbers that, taken in pairs, shall map each subset of the domain defined by Domain and the Bounds array to the domain of the corresponding function.
|
Collection<IPdfFunction> |
getFunctions()
(Required) An array of k 1-input functions that shall make up the stitching function.
|
int |
getOutputSize()
Gets output size of function.
|
protected boolean |
isWrappedObjectMustBeIndirect()
Defines if the object behind this wrapper must be an indirect object in the resultant document.
|
void |
setBounds(double[] value)
(Required) An array of k − 1 numbers that, in combination with Domain, shall define the intervals to which each function from the Functions array shall apply.
|
void |
setEncode(double[] value)
(Required) An array of 2 × k numbers that, taken in pairs, shall map each subset of the domain defined by Domain and the Bounds array to the domain of the corresponding function.
|
void |
setFunctions(Iterable<AbstractPdfFunction extends PdfDictionary>> value)
(Required) An array of k 1-input functions that shall make up the stitching function.
|
calculateFromByteArray, calculateFromByteArray, clip, clipInput, clipOutput, getAsPdfObject, getDomain, getFunctionType, getInputSize, getRange, normalize, setDomain, setRangeensureObjectIsAddedToDocument, ensureUnderlyingObjectHasIndirectReference, flush, getPdfObject, isFlushed, makeIndirect, makeIndirect, markObjectAsIndirect, setForbidRelease, setModified, setPdfObject, unsetForbidReleasepublic PdfType3Function(PdfDictionary dict)
dict - the function dictionary
public PdfType3Function(double[] domain,
double[] range,
List<AbstractPdfFunction extends PdfDictionary>> functions,
double[] bounds,
double[] encode)
domain - the valid input domain, input will be clipped to this domain contains a min max pair per input component
range - the valid output range, oputput will be clipped to this range contains a min max pair per output component
functions - The list of functions to stitch*
bounds - (Required) An array of k − 1 numbers that, in combination with Domain, shall define the intervals to which each function from the Functions array shall apply. Bounds elements shall be in order of increasing value, and each value shall be within the domain defined by Domain.
encode - (Required) An array of 2 × k numbers that, taken in pairs, shall map each subset of the domain defined by Domain and the Bounds array to the domain of the corresponding function.
public Collection<IPdfFunction> getFunctions()
(see ISO-320001 Table 41)
public void setFunctions(Iterable<AbstractPdfFunction extends PdfDictionary>> value)
(see ISO-320001 Table 41)
value - the list of functions
public double[] getBounds()
(see ISO-320001 Table 41)
public void setBounds(double[] value)
(see ISO-320001 Table 41)
value - the new set of bounds
public double[] getEncode()
(see ISO-320001 Table 41)
public void setEncode(double[] value)
(see ISO-320001 Table 41)
value - the new set of encodings
public boolean checkCompatibilityWithColorSpace(PdfColorSpace alternateSpace)
AbstractPdfFunction
checkCompatibilityWithColorSpace in interface IPdfFunction
checkCompatibilityWithColorSpace in class AbstractPdfFunction<PdfDictionary>
alternateSpace - The color space to verify against
public int getOutputSize()
If Range field is absent, the output size of functions will be returned.
getOutputSize in interface IPdfFunction
getOutputSize in class AbstractPdfFunction<PdfDictionary>
public double[] calculate(double[] input)
IPdfFunction
input - The input values size must contain IPdfFunction.getInputSize() items
IPdfFunction.getOutputSize() items containing the result
protected boolean isWrappedObjectMustBeIndirect()
PdfObjectWrapper
isWrappedObjectMustBeIndirect in class PdfObjectWrapper<PdfDictionary>
Copyright © 1998–2022 iText Group NV. All rights reserved.