During the past days I have been experimenting with local contrast enhancement, in view of improving the shadows/highlights tool in PhF.
The first step was to integrate the guided filter from RT, for edge-preserving blur.
Then I started to play with it to see how it can be used to enhance the local contrast.
The procedure is rather simple: extract the high-frequency local contrast by properly combining the original and blurred copies, and then superimpose the local contrast to the original version.
The usual way to do that is to subtract the blurred image from the original one, and then add back the result to the original. This is AFAIKk what GIMP grain extract and grain merge blend modes do.
However, I noticed that subtract/add approach affects the shadows in a rather “harsh” way, especially when working with linear RGB data.
However, this is not the only possible approach. If the subtraction is replaced by a division, and the addition by a multiplication, if have the impression that re output is more “natural”, with smoother shadows and a better enhancement of small-size highlights:
This work is in the perspective of re-injecting some lost local contrast after shadows/highlights adjustments, or to slightly increase the local contrast like shown above, but at a much lower strength…
Local contrast enhance has its uses of course. I used to use it a lot more than I do now because the result tends to look nice up close. But from ten feet away, when the eye sees a larger swath of the surround, often results of local contrast enhance alogirthms aren’t so nice. Or as my husband pronounced once when I proudly showed him my nicely “improved” image: “Looks spotty”.
For the particular test image in this thread, I’d use a very small Curves adjustment to slightly separate relative brights and darks in the trees, with the “stationary” point of the curves set at the peak of the histogram.
I have a filter that does it in two steps: first a small radius, then a larger one. The shadow problem doesn’t go away though, just less apparent and more spread out.
It makes the shadows more uneven per patch and also lifts certain shadows.
Yes, I would do something like that. I haven’t really experimented with curves and thresholds yet.