org.icepdf.core.pobjects.graphics
Class DeviceCMYK

java.lang.Object
  extended by org.icepdf.core.pobjects.Dictionary
      extended by org.icepdf.core.pobjects.graphics.PColorSpace
          extended by org.icepdf.core.pobjects.graphics.DeviceCMYK

public class DeviceCMYK
extends PColorSpace

Device CMYK colour space definitions. The primary purpose of this colour space is to convert cymk colours to rgb. No ICC profile is used in this process and the generated rgb colour is just and approximation.


Field Summary
static double cmykBlackRatio
           
 
Fields inherited from class org.icepdf.core.pobjects.Dictionary
entries, inited, isDeleted, isNew, library, SUBTYPE_KEY, TYPE_KEY
 
Method Summary
 java.awt.Color getColor(float[] f)
          Converts a 4 component cmyk colour to rgb.
 int getNumComponents()
           
 
Methods inherited from class org.icepdf.core.pobjects.graphics.PColorSpace
getColorSpace, getColorSpace, getDescription, normaliseComponentsToFloats, reverse, reverseInPlace, reverseInPlace
 
Methods inherited from class org.icepdf.core.pobjects.Dictionary
getEntries, getFloat, getInt, getLibrary, getNumber, getObject, getObject, getPObjectReference, init, isDeleted, isNew, setDeleted, setNew, setPObjectReference, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

cmykBlackRatio

public static double cmykBlackRatio
Method Detail

getNumComponents

public int getNumComponents()
Specified by:
getNumComponents in class PColorSpace
Returns:

getColor

public java.awt.Color getColor(float[] f)
Converts a 4 component cmyk colour to rgb. With out a valid ICC colour profile this is just an approximation.

Specified by:
getColor in class PColorSpace
Parameters:
f - 4 component values of the cmyk, assumes compoents between 0.0 and 1.0
Returns:
valid rgb colour object.