Interesting UI option I only just noticed

Hi @Aliks, a shortcut key would not be useful here because there is a much better way. If you are using a drawn mask in one module it can be used in any other module that comes after it. I do this all the time. However, the feather and blur adjustments do not get carried over, but that is no big deal. Hopefully the user manual has more details on this, but I will post some information below that I give to my students. If the mask is parametric you would need to turn that into a raster mask. Selecting raster mask allows you to use a drawm/parametric mask create in another module instance to use in the current module being adjusted. Also read about the mask manager module in the user guide. I don’t use the mask manager often but I know it is there if I need it.

image

Drawn masks

• The number of shapes that are used in the current mask is displayed in the “drawn mask” field.
• Clicking on that field opens a dropdown box with all shapes that have already been defined in the context of the current image but are not yet used in the current mask. You can click on any of these items in order to add it to the current mask. The list also contains shapes once generated but no longer in use. This way you can even get back a deleted shape.
• A polarity button allows the user to invert the drawn mask

1 Like

Thanks Terry, but maybe if I describe my use case, the benefit of a shortcut will be clearer.

I do a lot of (amateur) bird photography, and unlike the professionals, I am keen to preserve at least one photo of every bird I saw, no matter how poor the shot. A 10 day holiday can easily produce 3000 images of 200 bird species, but with varying quality . . . .

As you can imagine, efficient workflow is critical, so I start by applying a standard style to all images - (filmic, colorbalance, exposure compensation, highlight reconstruction, zoom in about 50%).

I can then look at each image and decide whether its worth working on. A good way to improve the shot is to mask on the outline of the bird, then use that mask to selectively enhance:

local contrast, often the HDR preset will help a lot
colorbalance, vibrant colours preset, to make the bird “pop” against the background
Diffuse/sharpen with lens deblur preset
tone equalizer - to let me boost detail in shaded areas of the bird

At this point I can quickly compare different shots of the same bird, to decide which is best, and then tweak to my hearts content.

This takes a lot of clicks to set up presets and feathering for each module, so what I really want is to get to my baseline with as few clicks as possible.

The only way I can think of is to set up a template image that I can copy. This would be an image with a single brush mask assigned and feathered to my 4 chosen modules. I can Ctrl-C and Ctrl-Shift-V onto my target image, and then move/modify the mask to cover the outline of the bird.

Complicated, but saves a lot of repetitive clicking.

Sounds like you’d benefit from raster masks: define your mask in one module then reuse it in other modules.

Not sure I understand - when I define a mask in Tone Equalizer, and then select another module, the defined mask is already available under the dropdown for “drawn mask - shape used” - and the manual implies this is already a raster mask without me having to do anything.

So in my template workflow described above, I go to a new image, copy in the template, go into mask manager and modify the mask to suit the new image - this modified mask is automatically available/used in all modules.

The downside of this workflow is that it is a bit harder to modify an existing mask than to create a new one.

I can see that shortcuts will not help here, but its always interesting to chat about alternative approaches - many thanks for all contributions!

No, a drawn shape is not a raster mask: you can change the shape wherever it is used, whereas a raster mask is fixed. Otoh, if you define a shape in a module, and then apply feathering/detail/blurring, the raster mask will reflect those settings, where the drawn shape will not.

So, in your case, the first module in pipeline order would use a drawn mask (perhaps from your “template”), the others will use the raster mask defined in that first module.

I must say that I am surprised to see the amount of editing you feel you need just to decide which images are worth working on…

Makes perfect sense - many thanks.

Regarding the amount of editing, you have to remember the bird is likely to be a smallish blob in the photographed image.

This image is a Hooded Merganser photographed last week at Cap Tourmente, Quebec:

  1. Basic undarktabled image:

About 60m away, and although I centred on the one bird, its clear the left hand bird is showing better.

  1. Next shot applies basic settings, filmic etc:

  2. zoom in on the left hand bird:

  3. Now I can see what it is, and take a view on image quality. I took 7 shots of this pair (probably male and female) and it would be good to get all 7 to stage 3 with as few clicks as possible

  4. Compare to another photo of the same bird a few seconds earlier:


    Image 4995 is better so its worth spending more time on this.

Sounds like maybe you have the raster mask sorted but if not in your case if the 7 images are similar enough that one mask will work then you can make a style for this that is your basic one. At the start of the style introduce an exposure module that is a no-op ie nothing added to the sliders. Then craft your mask. Now add your other modules based on the raster mask that can be taken from this module, ie select if from the list when you choose raster in say local contrast etc from your list above… Now save your style when you are done…

To use this on a new set of 7 for example …apply it and then go in and redescribe the mask in that exposure module and it will pass that along to the rest of the modules but the mask has been updated to mask what you want in the new image…

I think this is as automated as you can get it??

Todd, thanks for that - I hadn’t realised the “drawn mask” settings in each module are automatically saved when you create a style, even though the mask itself is not part of the style.

If you apply the style to a new image, then create a new mask, it automatically picks up the “drawn mask” settings, which is exactly what I want.

This makes my workflow quite a bit slicker.

You can use the raster mask to reuse masks created with the parametric sliders. So birds against the water or sky should be reasonably easy to select using the parametric mask.

And if its not clear…the raster mask is the combined/final mask of a module… So the final mask that you make in a module…say with all the drawn and parametric elements will be what you get when you select raster in another module above it in the pipeline and then select that source module as your raster mask option.

1 Like

Thanks Todd I did work that out eventually - I guess its a problem for the manual writers to join the dots between dev-speak and user-speak.

I understand how important it is for developers to know that the output of the masking process is converted to raster format. However, for users, its less relevant than knowing the implications for reusing the final mask.

In practice though, folks on this forum are incredibly helpful in sorting out what DT can and cant do.

The user has to be willing to look and read: darktable 4.0 user manual - raster masks

the final output of a module’s mask (the combined effect of any drawn and parameteric masks)

I’m not sure what else you’d want from that section.

Don’t get me wrong, I am talking about the difference between a manual scoring 8/10 for comprehensibility and 9/10.

Anyway, I did read the raster masks section 3 or 4 times, to puzzle out how to do what I wanted with masks. My issue ( and I stress its an issue with my understanding, not necessarily everyone else) was taking on board that “raster image” was synonymous with “final mask after feathering and blurring” as explained in rvietor’s email

maybe that paragraph is a candidate to include in the manual??

What I quoted above is from the manual. What isn’t clear about the first paragraph of that section?

Quote from Raster Masks section:

“As described in the previous sections, the final output of a module’s mask (the combined effect of any drawn and parameteric masks) is a grayscale raster image representing the extent to which the module’s effect should be applied to each pixel. This raster image is stored internally for active modules and can be subsequently reused by other modules in the pixelpipe.”

Firstly, the word raster is not used in the previous sections so its a bit tricky to link back to preceding explanations, and secondly the phrase “the combined effect of any drawn and parameteric masks” does not emphasise the critical feature that any settings like feather or blur are “locked in” to the final raster mask.

I’m happy to chat offline if this level of detail is useful to you.

From the manual (masks overview):

A mask can be regarded as a grayscale image where each pixel has a value between 0 and 1.0 (or between 0% and 100%). This value is the opacity and is used to determine how much a module affects each pixel.

Granted, the term “raster” isn’t used. However, pixel images are commonly referred to as “raster images” as opposed to “vector images” (which would describe a mask from e.g. a path). And the “final output of a module’s mask” includes all the settings, so also feathering, blur, details, and probably opacity…

Keep in mind that the darktable manual is primarily a reference manual. As such, it will use terms common in image processing without explanation or definition. An exception is made for terms related to colour, as there are too many, sometimes conflicting or overly vague, definitions in use.

1 Like

@hannoschwalm
Like you:

but no improvement on my part, as I’ve not got it to work yet on my Linux Mint 20.3 dt 4.2.

As for a mapping file, you said:

It seems to be some time before AP potentially finalizes any scene-referred Color Zones module or whatever module you were referring to.

So I wonder, could you possibly be kind to make available that file you already have?

For those who may find and read this thread and want more info about the use of loupdeck+ as a midi-controller with dt, be aware that @hannoschwalm has (as indicated in post 137) made available his current set-up and guidance for using it here:

Just reading this post again makes me recommend Ctrl-Shift-C for the copying stage as it brings up a list of options to copy and is better than Ctrl-C which copies some but not all modules.