I am trying to use the fromCIEXYZ method of the ICC_ColorSpace class and
I am getting inaccurate results.  Specifically I am trying to convert
from CIEXYZ values to sRGB values.  

I create an instance of the CS_sRGB ICC_Profile and pass it to the
constructor of ICC_ColorSpace.  To convert an XYZ to sRGB I first apply
a Bradford chromatic adaptation to the XYZ data to convert it to D50 (2
degree observer).  I then pass this modified value to the fromCIEXYZ
method.  The resulting RGB value is scaled up to 255.  (I have also
tried removing the Bradford calculation and pass in XYZ data that is
known to be measured using D50 and get the same bad results.)

If I pass in XYZ data of 0.0 I would expect to get RGB values of 0.0 but
I don't the values range from 0.0 to about 1.4.  Also if I pass in XYZ
white point data, I expect to get RGB of 255, 255, 255; but I do not get
this, instead the values range from 249 to 253.

I have seen some postings that state the sRGB conversion does not work
properly.  Is this what I have found or am I doing something wrong?  Am
I doing the chromatic adaptation correctly?  The docs are long on this
method but still not super clear how one has to scale the input XYZ
data; am I also suppose to apply some chromatic adaptation to the sRGB
output?  Is sRGB output defined as D50 or D65?

-dh

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA2D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to