1. Limited time only! Sign up for a free 30min personal tutor trial with Chegg Tutors
    Dismiss Notice
Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Image processing: effect of illuminant on sRGB image

  1. Jul 4, 2013 #1
    1. The problem statement, all variables and given/known data

    Assume an image file is sRGB under D65. Generate the image as it would appear under illuminant A ( a 171x1 matrix).

    2. Relevant equations

    effect of illuminant:

    B = LA

    where A is the a color matching function, L is a diagonalized version of illuminant A, and B is the color matching function as a product of the illuminant. CMF's have the dimensions mxn where n is the number of primaries, and m is the sample count of the function. n is usually 3 because it's related to the 3 types of cones in the eye.

    t = A'g

    where g is the sampled spectrum, and t is the "tristimulus value". If using the color matching function for the CIEXYZ color-space, the tristimulus value has the form [X;Y;Z]. There are some manipulations to transform XYZ into other color-spaces (often utilizing a "white point", such as CIERGB, CIELab, etc).


    The effect of the spectrum due to illuminant:

    g = Lr

    3. The attempt at a solution

    I'm not sure where to really start here. I have sRGB with a white point D65, but since this is a tristimulus value, I really only know how to convert it to other tristimulus values. I could transform each pixel from sRGB to XYZ, multiply by the inverse XYZ CMF to convert back to a spectrum, adjust the XYZ CMF to account for the illuminant, adjust the spectrum for the illuminant, and use these to get a new XYZ tristimulus value, and convert back to sRGB...

    The kink in that plan was that the CMF, A, is not square, so I can't take the inverse. So either there is some linear algebra magic I'm not seeing, or there is something I can do with this illuminant vector to the tristimulus values.
     
  2. jcsd
  3. Jul 6, 2013 #2
    Haha...not a lot of image processing gurus out there I suppose?

    I think I may have found a clue to this problem, it is in this formula:

    B' = (A'Q)^-1 A'

    Where B is a new color matching functions with associated primaries Q by using color matching function A (which is associated with Primaries P). There is a note that says the columns of A'Q are the amount of the new primaries Q required to match the old primaries P, and that it will be a 3x3 matrix.

    Another formula says that if d is the color vector (tristimulus value?) associated with primaries P and d is the color vector associated with primaries Q, then

    d = (A'Q)^-1c

    So I have A, and I can get B using the luminance formula from the first post, and I have P because the primaries of RGB are well known......if I can find Q I think I can get it using the last formula.

    I'm not really sure how to solve this matrix equation for Q:

    B' = (A'Q)^-1 A'

    If A'Q is really a 3x3 matrix, and A' is a 3x171, then that means Q needs to be a 171x3 to get a 3x3 output.
     
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Have something to add?
Draft saved Draft deleted



Similar Discussions: Image processing: effect of illuminant on sRGB image
  1. Image Processing (Replies: 2)

Loading...