Class ICCBasedColorSpace

java.lang.Object
com.datalogics.PDFL.ColorSpace
com.datalogics.PDFL.ICCBasedColorSpace

public class ICCBasedColorSpace extends ColorSpace
Works with the ICC color space. The International Color Consortium (ICC) developed the ICC color space in 1993 to serve as a universal standard for for printing or presenting content with digital devices, and across all operating systems and platforms.

The ICC color standard applies regardless the hardware or software involved, and is used to make sure that color images and text appear properly on a wide variety of platforms.

  • Constructor Details

    • ICCBasedColorSpace

      public ICCBasedColorSpace(PDFStream iccStream, int nComps)
      Create an ICC-based color stream.

      Parameters:
      iccStream - stream containing the ICC profile
      nComps - The number of components (1, 3, or 4)
    • ICCBasedColorSpace

      public ICCBasedColorSpace(PDFStream iccStream)
      Create an ICC-based color stream.

      Parameters:
      iccStream - stream containing the ICC profile
  • Method Details

    • delete

      public void delete()
      Overrides:
      delete in class ColorSpace
    • getAlternate

      public ColorSpace getAlternate()
      An alternate color space to be used in case the one specified in the stream data is not supported (for example, by applications designed for earlier versions of PDF). The alternate space may be any valid color space (except a Pattern color space) that has the number of components specified by N. If this entry is omitted and the application does not understand the ICC profile data, the color space used is DeviceGray, DeviceRGB, or DeviceCMYK, depending on whether the value of N is 1, 3, or 4, respectively.
    • setAlternate

      public void setAlternate(ColorSpace alternate)
      An alternate color space to be used in case the one specified in the stream data is not supported (for example, by applications designed for earlier versions of PDF). The alternate space may be any valid color space (except a Pattern color space) that has the number of components specified by N. If this entry is omitted and the application does not understand the ICC profile data, the color space used is DeviceGray, DeviceRGB, or DeviceCMYK, depending on whether the value of N is 1, 3, or 4, respectively.
    • getRange

      public List<Double> getRange()
      An array of 2 * NumComponents numbers [ min0 max0 min1 max1 ... ] specifying the minimum and maximum valid values of the corresponding color components. These values must match the information in the ICC profile. Default value: [ 0.0 1.0 0.0 1.0 ... ]
    • setRange

      public void setRange(List<Double> range)
      An array of 2 * NumComponents numbers [ min0 max0 min1 max1 ... ] specifying the minimum and maximum valid values of the corresponding color components. These values must match the information in the ICC profile. Default value: [ 0.0 1.0 0.0 1.0 ... ]
    • getStream

      public PDFStream getStream()
      The PDFStream containing the ICC-based data and other attributes.