Beep6581 / RawTherapee

A powerful cross-platform raw photo processing program
https://rawtherapee.com
GNU General Public License v3.0
2.79k stars 316 forks source link

Wavelets Residual image Sh/Hi odd behavior #6194

Open TechXavAL opened 3 years ago

TechXavAL commented 3 years ago

Using this raw file from discuss, I've managed to get some odd behavior I'm not really sure how to describe.

With just color management options, a bit of lowering exposure and luminance highlights recovery, at the beginning the image looks like this:

original

With the RI module active, I try to recover highlights in a rather aggressive way: Highlights 100, Threshold 70

full-highl-rec

Strangely, the highest highlights are very little modified. So I lower the Threshold to 0 to better view the problem:

full-highl-rec-th0

The extreme highlights seem to be almost untouched (there's a bit of lightness reduction, indeed), while the rest of the highlights get quite dark (as expected).

But the most striking effect is when you lower the shadows slider. Note in the next image that Shadows threshold = 30 and Highlights threshold =50, so there shouldn't be any cross effect between sliders. However this is what happens:

full-highl-rec-shdneg

When setting Shadows to -1 (or any negative number, for that matter), the extreme highlights simply get blown out.

I know the Highlights recovery is set at 100, but from a user point of view, what you do with the shadows should have no effect on the highlights and vice versa.

Desmis commented 3 years ago

@TechXavAL

I don't think we can change this behavior ( maybe I'm wrong, maybe there is a solution, but I don't think so). Because in a jpg (I have not seen immediatly the raw - see below), there is no process like in Raw - "highlight reconstruction" (especially Color propagation)

in this case for positive values the SH algorithm used is exactly the same for residual as the SH algorithm of main -Exposure...and the results are similar (to the wavelet decomposition which has a weak effect), i.e. bad.

When the use of negative values that I added following our discussions, the algorithm used which is the old algo SH main is even worse for this kind of image

Oh, I had not seen that there was a raw, I look (i dowload the jpg, excuses me)

I look the raw file, and use "color propagation"...(but no gain). But the result is the same as SH main...you must acts on others parameters (white point, exposure, curves, local adjustmenst...) and my remark on negatives values is the same

Jacques

TechXavAL commented 3 years ago

Yes, the Shadows/Highlights tools gives the same results, aside that I can't check with negative Shadows values.

About:

When the use of negative values that I added following our discussions, the algorithm used which is the old algo SH main is even worse for this kind of image

I'm not really sure what «even worse» means. If the algorithm works exactly as in RT5.8 (the «old algo»), let's see what it can do in the current stable release (v.5.8):

This is the starting point: RT58_1

This is how I can select the highest highlights with the RI > Highlights threshold (I have set the RI > Highlights slider to -100 to better see which areas will be modified): RT58_2

In this case, with the old algo, I can select the part of the image I wish, without weird limits.

Now what I can get with sensible settings: RT58_3

It seems there's no change from the original image, but the highest highlights have been tamed down, as needed. No worse result here.

And if I wish to make a crazy processing to the shadows, the only thing I have to take care of is the Shadows threshold, so it doesn't «invade» the highlights: RT58_4

Note: take a look at the Shadows slider. It's set to -100 and the highlights are not touched in the slightest.

So again, I think the new implementation of the tool acts weird. And this is not an extreme case. This is just a usual case when shooting landscapes in full sunlight.

Is there any possibility to fix this behavior?

Desmis commented 3 years ago

@TechXavAL

I think there is no solution...Except new algorithm... ??...Or try "LA" with "Tone equalizer"

You can't have your cake and eat it too, but if someone has the solution, then let them do

Jacques

TechXavAL commented 3 years ago

@Desmis

I think there is no solution...Except new algorithm... ?

What about reimplementing the old algorithm for both Shadows and Highlights? It works well, with its own limits. And if this part of the code is used somewhere else, you would just have to point the RI module to another part of the code.

You can't have your cake and eat it too

Well, when I buy a cake, I like to eat it too... 😄

Desmis commented 3 years ago

For me, it will stay like that :)