ACES 2.0 CAM DRT Development

While debugging my procedural Baselight DRT, I came across a slight discrepancy between the forward and inverse gamut compression.

The current gamut compressor uses a gamma approximation to the lower part of the gamut hull. This in turn uses a further approximation, which I came up with, to find the intersection between the compression vector and the curved boundary. This approximation does not land exactly on the boundary, but since our gamma curve is itself only an approximation anyway, and we are compressing rather than hard clipping at the boundary, I did not think it was an issue. However I have discovered that the use of the source JM value in the boundary finding gives a slightly different result when finding the boundary distance from the compressed colour for inverting than it did from the original colour for compressing.

I suspect the discrepancy is normally pretty small, but since our intent was to create a fully invertible gamut compression, it would be better if the normalisation distance used was identical in both directions.

If somebody with better mathematical skills than myself can find a way to find the exact intersection between a straight line and a power curve, that would be ideal. Otherwise I have been experimenting with a method which uses only the J-axis intersection value, not the pixel JM values, to calculate the normalising boundary distance. I will demonstrate that in tomorrow’s meeting.