On a side note, combining linear L and RGB
is possible in PixInsight. However you must perform a YRGB combination instead of LRGB.
In this case, instead of the CIE L*a*b* space, the CIE XYZ space must be used. CIE XYZ is a linear color space; however, the underlying RGB working space must also be linear in order to preserve linearity in the combined image. The basic procedure would be as follows:
- Define a linear RGB working space. With the RGBWorkingSpace tool, set gamma = 1.0 (disable sRGB gamma function). In addition, I would define a
uniform RGB working space in the same operation. So the steps with RGBWorkingSpace are:
* Set the three luminance coefficients = 1.
* Define a
uniform energy illuminant by setting the six chromaticity coordinates = 0.333333.
* Disable the sRGB gamma function and set gamma = 1.
* Apply to
both the RGB and L images.
- Use the ChannelCombination tool to perform a YRGB combination. Select the CIE XYZ space, disable the X and Z components, and select the L image for the Y slot. Apply to the RGB image and you're done.
- To process the linear luminance of the combined YRGB image, you must select "Linear luminance" in the applied tools, when applicable (for example, Deconvolution and ATrousWaveletTransform allow you to select it).
- After the initial nonlinear stretch with HistogramTransformation, you may want to apply the default RGBWorkingSpace parameters, as a linear uniform space no longer will describe the image appropriately.
This
should work
EDITED AS OF 11 MAY 2023
Setting the three luminance coefficients to the same value and all chromaticity coordinates to 1/3 leads to a singular matrix, so the above procedure is not feasible as I described it back in 2010. See the
related thread where this problem was pointed out.
You can, however, try to perform a YRGB combination as described above in a linear RGB working space with gamma = 1 and equal luminance coefficients, but using the default chromaticity coordinates.