Examples of PDSeparation


Examples of org.apache.pdfbox.pdmodel.graphics.color.PDSeparation

     * @param pdcs
     *            the color space object to check.
     */
    protected void processSeparationColorSpace(PDColorSpace pdcs)
    {
        PDSeparation separation = (PDSeparation) pdcs;
        try
        {

            PDColorSpace altCol = separation.getAlternateColorSpace();
            if (altCol != null)
            {
                ColorSpaces acs = ColorSpaces.valueOf(altCol.getName());
                switch (acs)
                {
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.color.PDSeparation

                    cm = csIndexed.createColorModel(bpc);
                }
            }
            else if (colorspace instanceof PDSeparation)
            {
                PDSeparation csSeparation = (PDSeparation)colorspace;
                int numberOfComponents = csSeparation.getAlternateColorSpace().getNumberOfComponents();
                PDFunction tintTransformFunc = csSeparation.getTintTransform();
                COSArray decode = getDecode();
                // we have to invert the tint-values,
                // if the Decode array exists and consists of (1,0)
                boolean invert = decode != null && decode.getInt(0) == 1;
                // TODO add interpolation for other decode values then 1,0
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.color.PDSeparation

                    cm = csIndexed.createColorModel(bpc);
                }
            }
            else if (colorspace instanceof PDSeparation)
            {
                PDSeparation csSeparation = (PDSeparation)colorspace;
                int numberOfComponents = csSeparation.getAlternateColorSpace().getNumberOfComponents();
                PDFunction tintTransformFunc = csSeparation.getTintTransform();
                COSArray decode = getDecode();
                // we have to invert the tint-values,
                // if the Decode array exists and consists of (1,0)
                boolean invert = decode != null && decode.getInt(0) == 1;
                // TODO add interpolation for other decode values then 1,0
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.color.PDSeparation

        PDColorState colorInstance = context.getGraphicsState().getNonStrokingColor();
        PDColorSpace colorSpace = colorInstance.getColorSpace();
       
        if (colorSpace != null)
        {
            PDSeparation sep = (PDSeparation) colorSpace;
            colorSpace = sep.getAlternateColorSpace();
            COSArray values = sep.calculateColorValues(arguments.get(0));
            colorInstance.setColorSpaceValue(values.toFloatArray());
        }
    }
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.color.PDSeparation

                    cm = new IndexColorModel(bpc, size+1, colorValues, 0, hasAlpha);
                }
            }
            else if (colorspace instanceof PDSeparation)
            {
                PDSeparation csSeparation = (PDSeparation)colorspace;
                int numberOfComponents = csSeparation.getAlternateColorSpace().getNumberOfComponents();
                PDFunction tintTransformFunc = csSeparation.getTintTransform();
                COSArray decode = getDecode();
                // we have to invert the tint-values,
                // if the Decode array exists and consists of (1,0)
                boolean invert = decode != null && decode.getInt(0) == 1;
                // TODO add interpolation for other decode values then 1,0
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.color.PDSeparation

        PDColorState colorInstance = context.getGraphicsState().getStrokingColor();
        PDColorSpace colorSpace = colorInstance.getColorSpace();

        if (colorSpace != null)
        {
            PDSeparation sep = (PDSeparation) colorSpace;
            colorSpace = sep.getAlternateColorSpace();
            COSArray values = sep.calculateColorValues(arguments.get(0));
            colorInstance.setColorSpaceValue(values.toFloatArray());
        }
    }
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.color.PDSeparation

   *          the list of error to update if the validation fails.
   * @return true if the color space is valid, false otherwise.
   */
  protected boolean processSeparationColorSpace(PDColorSpace pdcs,
      List<ValidationError> result) {
    PDSeparation separation = (PDSeparation) pdcs;
    try {

      PDColorSpace altCol = separation.getAlternateColorSpace();
      if (altCol != null) {
        ColorSpaces acs = ColorSpaces.valueOf(altCol.getName());
        switch (acs) {
        case Separation:
        case DeviceN:
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.color.PDSeparation

                    cm = csIndexed.createColorModel(bpc);
                }
            }
            else if (colorspace instanceof PDSeparation)
            {
                PDSeparation csSeparation = (PDSeparation)colorspace;
                int numberOfComponents = csSeparation.getAlternateColorSpace().getNumberOfComponents();
                PDFunction tintTransformFunc = csSeparation.getTintTransform();
                COSArray decode = getDecode();
                // we have to invert the tint-values,
                // if the Decode array exists and consists of (1,0)
                boolean invert = decode != null && decode.getInt(0) == 1;
                // TODO add interpolation for other decode values then 1,0
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.color.PDSeparation

     * @param pdcs
     *            the color space object to check.
     */
    protected void processSeparationColorSpace(PDColorSpace pdcs)
    {
        PDSeparation separation = (PDSeparation) pdcs;
        try
        {

            PDColorSpace altCol = separation.getAlternateColorSpace();
            if (altCol != null)
            {
                ColorSpaces acs = ColorSpaces.valueOf(altCol.getName());
                switch (acs)
                {
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.color.PDSeparation

                    cm = csIndexed.createColorModel(bpc);
                }
            }
            else if (colorspace instanceof PDSeparation)
            {
                PDSeparation csSeparation = (PDSeparation)colorspace;
                int numberOfComponents = csSeparation.getAlternateColorSpace().getNumberOfComponents();
                PDFunction tintTransformFunc = csSeparation.getTintTransform();
                COSArray decode = getDecode();
                // we have to invert the tint-values,
                // if the Decode array exists and consists of (1,0)
                boolean invert = decode != null && decode.getInt(0) == 1;
                // TODO add interpolation for other decode values then 1,0
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.