Draft: Add a new blend mode, "tint"
This is a small patch to add a new blend mode that addresses the issues with existing modes for the Fast Color Overlay filter use case. As far as I know, there was no existing blend mode that:
- works with opaque background (scans) - unlike "normal"
- works with pure black color - unlike "color"
- does not bleed previous color - unlike "screen" or "overlay"
This is unoptimized, but should perform similarly (if not faster) than screen/overlay modes. I did look at the xsimd optimizations, and I think I understand how to add an optimized path, but it's a lot of boilerplate that probably should be handled in a more generic way.
Here's an example of the effect: https://krita-artists.org/t/layer-sketch-to-blue-for-inking-over-it/11246/162?u=yrh
Open questions:
- Is "Colorize" a suitable name? I don't recall this blend mode from other painting programs. Maybe it should be "Light Color", "Color Lighten", or "Tint"?
The behavior is similar to HSV Adjustment with Lightness bumped up somewhat. - Should we add other blend variants HSV/HSL/HSI? I think the current HSY is best (it desaturates following BT.601) and David suggested that maybe there's no need to clutter the UI. Adding these three is trivial.