Sharpening strategies in Darktable

This is not correct. The manual suggests that sensor and demosaic correction should come last. The order should be from largest to smallest corrections.

That is, your instances should appear in the following pipe order:

  1. denoise,
  2. local contrast enhancement,
  3. dehaze,
  4. lens blur correction,
  5. sensor and demosaic correction.

Maybe there’s some confusion due to the “pipe order”. What comes first is what is first in the pipe order, and that is represented bottom to top in the UI.

2 Likes

I’m not familiar with Lr, but I would have to say yes. Whatever sharpening module you use (say diffuse and sharpen), you can modify its coverage with a mask, exactly the same as any other module.
One of the most useful options is the details threshold: set a parametric mask, but don’t change any other settings…
image

6 Likes

Yes that was the problem - my bad!

1 Like

To be noted: details threshold is only available for raw (un-demosaiced) images. Not for JPG, and I think not for demosaiced DNG. Also, a bit of feathering is often needed, otherwise the mask itself can be noisy (which, with the processing, probably increases overall noise):
Without (overall + zoomed in):


With:


4 Likes

In addition to the mask shown above, the old sharpen module also has a threshold:
image

Thank you. I will try this method

Previously I have used the details threshold without feathering on some very noisy images and have never noticed a problem caused by this approach as I wanted to preserve detail for perceived sharpness but wanted to limit denoise which softens the image to just the areas without fine detail. I also used the thresholds slider to sharpen the details while not sharpening the noise in the smoother areas of the image. Based on the suggestion by someone else on this forum I now apply a very small amount of feathering when using the threshold slider. Often just one px. These seems to work well for me. I am really trying hard to get the best of both worlds with sharpening and denoising of high ISO images and DT does a good job.

1 Like

I believe the developer of the details threshold feature confirmed that feathering is NOT needed. Can you confirm again please @hannoschwalm ?

Well, yes: the “details feature” uses a special mask calculated from data in the demosaicer module. (It’s a sigmoid function on ‘scharr’ operator data) So this is a special mask as it is not derived from any data in the module you are working in. So it’s available in an identical way after sharpening or blurring or whatever you do in the pipe between demosaic and module in question.

Well, no: you may of course use feathering or shaped or parametric as you like further restricting the details.

Hope this helps and makes things more clear.

4 Likes

Thank you very much. This is exactly what I needed. Finally I can sharpen only what is in focus and not the whole frame :slight_smile:

1 Like