Package java.awt.color

Examples of java.awt.color.ICC_ColorSpace


      if (icc_profile != null)
      {
        Boolean is_srgb = new IccProfileParser().issRGB(icc_profile);
        if (is_srgb == null || !is_srgb.booleanValue())
        {
          ICC_ColorSpace cs = new ICC_ColorSpace(icc_profile);

          ColorModel srgbCM = ColorModel.getRGBdefault();
          ColorSpace cs_sRGB = srgbCM.getColorSpace();

          result = new ColorTools().convertBetweenColorSpaces(result,
View Full Code Here


    /** {@inheritDoc} */
    public ICC_Profile getICCProfile() {
        ColorSpace cs = getColorSpace();
        if (cs instanceof ICC_ColorSpace) {
            ICC_ColorSpace icccs = (ICC_ColorSpace)cs;
            return icccs.getProfile();
        }
        return null;
    }
View Full Code Here

      System.out.println(prefix + ": " + "Unknown ColorSpace: "
          + cs.getClass().getName());
      return;
    }

    ICC_ColorSpace fICC_ColorSpace = (ICC_ColorSpace) cs;
    ICC_Profile fICC_Profile = fICC_ColorSpace.getProfile();

    byte bytes[] = fICC_Profile.getData();

    IccProfileParser parser = new IccProfileParser();
View Full Code Here

      if (icc_profile != null)
      {
        Boolean is_srgb = new IccProfileParser().issRGB(icc_profile);
        if (is_srgb == null || !is_srgb.booleanValue())
        {
          ICC_ColorSpace cs = new ICC_ColorSpace(icc_profile);

          ColorModel srgbCM = ColorModel.getRGBdefault();
          ColorSpace cs_sRGB = srgbCM.getColorSpace();

          result = new ColorTools().convertBetweenColorSpaces(result,
View Full Code Here

      throws ImageReadException, IOException {
    ICC_Profile icc = Sanselan.getICCProfile(file);
    if (icc == null)
      return src;

    ICC_ColorSpace cs = new ICC_ColorSpace(icc);

    BufferedImage dst = convertFromColorSpace(src, cs);
    return dst;
  }
View Full Code Here

    return dst;
  }

  public BufferedImage relabelColorSpace(BufferedImage bi, ICC_Profile profile)
      throws ImagingOpException {
    ICC_ColorSpace cs = new ICC_ColorSpace(profile);

    return relabelColorSpace(bi, cs);
  }
View Full Code Here

  }

  public BufferedImage convertBetweenICCProfiles(BufferedImage bi,
      ICC_Profile from, ICC_Profile to) {
    ICC_ColorSpace cs_from = new ICC_ColorSpace(from);
    ICC_ColorSpace cs_to = new ICC_ColorSpace(to);

    return convertBetweenColorSpaces(bi, cs_from, cs_to);
  }
View Full Code Here

    return convertBetweenColorSpaces(bi, cs_from, cs_to);
  }

  public BufferedImage convertToICCProfile(BufferedImage bi, ICC_Profile to) {
    ICC_ColorSpace cs_to = new ICC_ColorSpace(to);

    return convertToColorSpace(bi, cs_to);
  }
View Full Code Here

                    // FOP URI resolver did not find ICC profile - perhaps the
                    // Java VM can find it?
                    // iccProfile = ICC_Profile.getInstance(iccProfileSrc);
                }
                if (iccProfile != null) {
                    colorSpace = new ICC_ColorSpace(iccProfile);
                }
            } catch (Exception e) {
                // Ignore exception - will be logged a bit further down
                // (colorSpace == null case)
            }
View Full Code Here

        super(info);
        this.red = red;
        this.transparentColor = transparentColor;
        this.colorSpace = red.getColorModel().getColorSpace();
        if (this.colorSpace instanceof ICC_ColorSpace) {
            ICC_ColorSpace icccs = (ICC_ColorSpace) this.colorSpace;
            this.iccProfile = icccs.getProfile();
        } else {
            this.iccProfile = null;
        }
    }
View Full Code Here

TOP

Related Classes of java.awt.color.ICC_ColorSpace

Copyright © 2018 www.massapicom. 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.