Reputation: 21
I'm trying to implement a white balancing workflow similar to what you see in Photoshop if you open a RAW image file. That is:
I'm trying to implement a similar workflow in another application (just to cut down on application jumping). Currently, I'm doing the following (where the 'source' is the image and the 'target' is the sampled color:
I'm basing this process off of this paper: https://www.hindawi.com/journals/mpe/2014/760123/
and i'm using precomputed transform matrices to transform from RGB to XYZ from here (D65 white point): http://brucelindbloom.com/index.html?Eqn_RGB_XYZ_Matrix.html
and the precomputed Bradford transform to transform from XYZ to LMS from here (again, D65 white point): was pulled from the hindawi paper above from part 2ii
I don't have any sample code. I'm trying to implement this in Substance Designer using the Pixel Processor. At this point I'm just curious if my overall approach is sound before diving into the specific implementation.
The output I'm getting from this is hue shifted towards green and too dark.
pre-white balancing in Photoshop:
after white balancing in Photoshop:
my results:
Am I calculating the scaling coefficients in the wrong space? I assume scaling the source texels should happen in LMS space..?
Upvotes: 2
Views: 426