Class PdfType0Function

All Implemented Interfaces:

public class PdfType0Function extends AbstractPdfFunction<PdfStream>
  • Constructor Details

    • PdfType0Function

      public PdfType0Function (PdfStream pdfObject)
    • PdfType0Function

      public PdfType0Function (double[] domain, int[] size, double[] range, int order, int bitsPerSample, byte[] samples)
    • PdfType0Function

      public PdfType0Function (double[] domain, int[] size, double[] range, int order, int[] encode, double[] decode, int bitsPerSample, byte[] samples)
  • Method Details

    • getOrder

      public int getOrder()
    • setOrder

      public void setOrder (int order)
    • getSize

      public int[] getSize()
    • setSize

      public void setSize (int[] size)
    • getEncode

      public int[] getEncode()
    • setEncode

      public void setEncode (int[] encode)
    • getDecode

      public double[] getDecode()
    • setDecode

      public void setDecode (double[] decode)
    • checkCompatibilityWithColorSpace

      public boolean checkCompatibilityWithColorSpace (PdfColorSpace alternateSpace)
      Description copied from class: AbstractPdfFunction
      Chacks wether the output of the function matches in components with the passed by color space.
      Specified by:
      checkCompatibilityWithColorSpace in interface IPdfFunction
      checkCompatibilityWithColorSpace in class AbstractPdfFunction<PdfStream>
      alternateSpace - The color space to verify against
      True when compatible
    • setDomain

      public void setDomain (double[] domain)
      Description copied from class: AbstractPdfFunction
      The valid input domain, input will be clipped to this domain contains a min max pair per input component.

      (see ISO-320001 Table 38)

      Specified by:
      setDomain in interface IPdfFunction
      setDomain in class AbstractPdfFunction<PdfStream>
      domain - the new set of limits
    • setRange

      public void setRange (double[] range)
      Description copied from class: AbstractPdfFunction
      the valid output range, output will be clipped to this range contains a min max pair per output component.

      (see ISO-320001 Table 38)

      Specified by:
      setRange in interface IPdfFunction
      setRange in class AbstractPdfFunction<PdfStream>
      range - the new set of limts
    • calculate

      public double[] calculate (double[] input)
      Description copied from interface: IPdfFunction
      Calculates one set of input components to one set of output components.
      input - The input values size must contain IPdfFunction.getInputSize() items
      an array the size of IPdfFunction.getOutputSize() items containing the result
    • isWrappedObjectMustBeIndirect

      protected boolean isWrappedObjectMustBeIndirect()
      Description copied from class: PdfObjectWrapper
      Defines if the object behind this wrapper must be an indirect object in the resultant document.

      If this method returns true it doesn't necessarily mean that object must be in the indirect state at any moment, but rather defines that when the object will be written to the document it will be transformed into indirect object if it's not indirect yet.

      Return value of this method shouldn't depend on any logic, it should return always true or false.
      Specified by:
      isWrappedObjectMustBeIndirect in class PdfObjectWrapper<PdfStream>
      true if in the resultant document the object behind the wrapper must be indirect, otherwise false.