
The only way I can imagine myself doing this is to process the middle greyscale image to isolate the highest and lowest ranges, making 2 alphas, and then brightening/darkening the first coloured image so it resembles the final outcome on the right, which might just be another way of saying what I want to do, but I don't think it would be accurate for all use-cases since I won't know how much to adjust each image. It's the best idea I can achieve with my current skills.
So, any advice is greatly appreciated.