As per my understanding (which may be wrong),
RGB composition is better done after a linear fit
LRGB composition should be done only in non-linear space, at least in PI.
In Siril using CLI, we do in linear.
So how is this being done in the Siril CLI? Is it being done in the background? Or are the two points I mentioned specific to PI and not a general requirement?
March 9, 2023, 11:55am
Hello, the Siril CLI
rgbcomp command is very simple and as you note it has two different modes of operation:
for RGB composition, it just copies the three input images as a color channel of the destination. It would work the same with linear or stretched images.
for LRGB composition, it makes an HSL conversion before writing the result. From my experience, the HSL mixing works better when images have more signal, so pre-stretched.
I am actually writing a new LRGB composition tutorial and hope to finish it this week.
Thank you. But I am not clear on one point.
When using the rgbcomp with lum option from command line, do we prestretch each channel then?
Or can we do rgb comp separately, stretch, then use rgbcomp again?
Look forward to the tutorial. Please do add the command line instructions as well.
Also, there was a discussion (old) on PI forum on this. Can I give the link or is that against the forum rules?
March 9, 2023, 1:16pm
we you mean the user, yes, you should the command does not do it implicitly.
If you do an LRGB composition, you can do what you want with the L and RGB images before combining them with
rgbcomp -lum= or with the RGB Composition tool, in particular running the PCC on the color image and stretching them.
I don’t think it’s against the rules to post it.
Yes the tutoral will include the command line aspect as well.
The very old PI post which you may have seen is here. Of interest is the suggestion for combining in linear space.
LRGB combination | PixInsight Forum
Subsequently, quite a few have reported better results with HSI/HSL approach. Even for HDR as objective was same to avoid washing out of colours.
Color-Corrected HDRMT | PixInsight Forum
I also came across this which may be interesting (though nothing new for you
LRGBCombination vs ChannelCombination for luminance data – Deep-sky Imaging (wordpress.com)
March 12, 2023, 10:28pm
The new tutorial is online:
Siril - RGB composition
I know it doesn’t answer all questions, but that’s all I could manage for now.
Thanks. Its quite comprehensive.
I didnt get an answer to my original question though
As you say, L and RGB should be nonlinear before combining.
But rgbcomp when it uses lum option still delivers a linear image.
So what is happening behind the scenes? Is there a stretch then a de-stretch, or is it a straight linear composition? Does a liner fit happen behind the scenes?
March 14, 2023, 12:17pm
I already answered above:
To clarify: the command only combines the data it gets as input, no stretching operation is done. If you use luminance-based composition, YOU need to pre-stretch the input images before passing them to rgbcomp.