Color-matching pictures in a series

I would like to introduce an experimental feature I’m working on : color-matching pictures.

It comes from the fact that, even with top-notch color science and using pictures shot in seemingly similar conditions, light may change during a shooting session. As a result, it may prove difficult to obtain a consistent look across pictures, because copy-pasting the history will yield slightly different results. When you have a secondary color-grading (set in color balance RGB or RGB curves), you don’t really to want fine-tune it on a per-image basis, because that will take forever. Instead, you want to adjust the illuminant and the exposure, that is chromaticity and brightness, because in theory, that will normalize all pictures to the same ground through (taking light variations into account), which in theory, should help color balance RGB to produce the same effect.

Notice, though, that “same effect” ≠ same look, because human vision is sensible to contrast and to surround, so ensuring the the same output colors is not enough to ensure the same overall perception (if, for example, one pic has 1/3 of bright sky and 2/3 of dark ground, and another has the opposite, the change in background will affect the perception of the subject in the foreground).

In any case, I recorded a video to show how to use it, and the code is on Github and working:

This also enables to match skin tones to an arbitrary hue, an use case I don’t endorse, but you take responsibility for the social consequences of your actions.


That’s a nice feature.

This being WIP: I was wondering if you could make the selected area sticky/remembered. At the moment you’ll have to manually select the area 4 times and I think this might be a problem when you want to be precise (that is what this enhancement is all about, right?).

Your attached video is a nice example: You select an area of the cheekbone that has a rather obvious highlights and shadows difference. Manually selecting this 4 times will introduce a difference and the bigger the difference in highlights and shadows the bigger the difference will be in the end-result.

Not being a developer I’m not sure how hard this will be to implement but I do think this would (greatly?) benefit the overall precision of this feature and its handling.

Very interesting. I noted with interest the remark about colorblind people. The tool could also be useful for timelapses whose lighting remain stable.


The problem is the ratio of the image may change and the subject will move between shots, so remembering the area will be useless in most cases, it needs to be adapted to follow the subject.

Yeah, of course. Kinda obvious… You might not even have the same cheek(bone) to match against in another one of the same series.

Got caught up in the moment and didn’t think it through :grin:


Have you given any thought to the use case of color-matching images of the same scene from different cameras? I think the current LUT-based schemes used by Davinci Resolve and others is to use a reference camera to pull the others into “compliance”, so to speak…


It should behave the same between cameras, provided they are profiled in the same conditions. The feature is only about bending colors to an arbitrary reference, so if your reference is the same between cameras, then the output color should be the same too.

Which might involve calibrating all cameras on the same stage using a color checker…

In any case, LUTs are nasty.

1 Like

Y’know, sometimes the simple thing is not so obvious. At least in the head of ggbutcher… :crazy_face:


Hi @anon41087856. I am so looking forward to this new feature. It will revolutionise how my workflow works for so many images. Especially when I am scanning negatives from days gone by and struggle to get pleasing colors. I hope it will be possible to save the target colors as presets for future use. It may be that we want to match a color, which could even be skin tone (I know that makes you cringe) to use as a starting point. There are just so many uses for this improvement. Keep up the good work. BTW, I have to scan lots of negative film and Epson, Vuescan, and Silverfast do such a poor job with color negatives, so I am hoping this concept could be combined into negadoctor to help with scans.

Looks like this got merged today…

1 Like

Tested today, really nice feature! Thanks @anon41087856 !

1 Like