Class ICCColorSpaceWithIntent
java.lang.Object
java.awt.color.ColorSpace
java.awt.color.ICC_ColorSpace
org.apache.xmlgraphics.java2d.color.ICCColorSpaceWithIntent
- All Implemented Interfaces:
Serializable
,ColorSpaceOrigin
This class extends the ICCColorSpace class by providing
convenience methods to convert to sRGB using various
methods, forcing a given intent, such as perceptual or
relative colorimetric. It also additionally holds the name
and source URI of the color profile.
- See Also:
-
Field Summary
Fields inherited from class java.awt.color.ColorSpace
CS_CIEXYZ, CS_GRAY, CS_LINEAR_RGB, CS_PYCC, CS_sRGB, TYPE_2CLR, TYPE_3CLR, TYPE_4CLR, TYPE_5CLR, TYPE_6CLR, TYPE_7CLR, TYPE_8CLR, TYPE_9CLR, TYPE_ACLR, TYPE_BCLR, TYPE_CCLR, TYPE_CMY, TYPE_CMYK, TYPE_DCLR, TYPE_ECLR, TYPE_FCLR, TYPE_GRAY, TYPE_HLS, TYPE_HSV, TYPE_Lab, TYPE_Luv, TYPE_RGB, TYPE_XYZ, TYPE_YCbCr, TYPE_Yxy
-
Constructor Summary
ConstructorsConstructorDescriptionICCColorSpaceWithIntent
(ICC_Profile p, RenderingIntent intent, String profileName, String profileURI) Creates a new ICC-based color space. -
Method Summary
Modifier and TypeMethodDescriptionReturns the name of the profile used to identify the color space in a particular context.Returns the URI identifying the associate color profile.float[]
intendedToRGB
(float[] values) Returns the sRGB value obtained by forcing the conversion method to the intent passed to the constructor.Methods inherited from class java.awt.color.ICC_ColorSpace
fromCIEXYZ, fromRGB, getMaxValue, getMinValue, getProfile, toCIEXYZ, toRGB
Methods inherited from class java.awt.color.ColorSpace
getInstance, getName, getNumComponents, getType, isCS_sRGB
-
Constructor Details
-
ICCColorSpaceWithIntent
public ICCColorSpaceWithIntent(ICC_Profile p, RenderingIntent intent, String profileName, String profileURI) Creates a new ICC-based color space.- Parameters:
p
- the color profileintent
- the overriding rendering intent (useRenderingIntent.AUTO
to preserve the profile's)profileName
- the color profile nameprofileURI
- the source URI of the color profile
-
-
Method Details
-
intendedToRGB
public float[] intendedToRGB(float[] values) Returns the sRGB value obtained by forcing the conversion method to the intent passed to the constructor.- Parameters:
values
- the color values in the local color space- Returns:
- the sRGB values
-
getProfileName
Returns the name of the profile used to identify the color space in a particular context.- Specified by:
getProfileName
in interfaceColorSpaceOrigin
- Returns:
- the profile name
-
getProfileURI
Returns the URI identifying the associate color profile.- Specified by:
getProfileURI
in interfaceColorSpaceOrigin
- Returns:
- the profile URI
-