# Get difference in level between two colors

I'm going to cast my own bathroom countertop in concrete. We are trying to match the floor tiles in black level, so I did three samples, each with a double amount of pigment than the last. Of course it didn't match.

The big big one is the target. You can use white pigment if you need to make it more less dark.

Of course a picture will never have the exact same shade as reality, but the difference in black level should be pretty accurate (since the 3 samples are from the same picture). So what I did was to use Gaussian blur on each color and this is what I got:

I would like to somehow get the black level of each sample, and calculate an average. Also, the difference between the tile and the lightest sample. I can use that to get the amount of pigment.

• Friendly reminder, your camera is nonlinear so to measure intensity you must inverse image, gamma correct up by 2.2 and then inverse for the LINEAR difference. Since your pigment is most likely linearish. Commented Nov 9, 2014 at 12:45
• Colors are about 87% (big base color), 91%, 94%, 96%, is the big color the reference with no pigment? Which is the target. However im not sure you can actually mix less pigment ;) Commented Nov 9, 2014 at 12:57
• The big big one is the target. You can use white pigment if you need to make it more less dark. What does the percentage represent? And how did calculate them? edit: ha, its teh percentage of black offcourse, but its sounds alot because its light grey :D Commented Nov 9, 2014 at 16:00
• @joojaa Photoshop’s 32bit mode is linear, which might be handy for this experiment. Commented Apr 12, 2015 at 8:45
• @MarkEdwards only if the image was loaded properly. If not then the mode is nonlinear that thinks it is linear. Which is the worst possible choice. Commented Apr 12, 2015 at 10:20

## 1 Answer

A problem you are facing is that you have other variables, mainly humidity and illumination.

In your shoots, there are some zones that look similar but as the dark color is to the center I assume they are still wet.

The only way I can think of is to continue doing the tests.

The approach of doubling the sample is good for the start, but only for a first macro step, because you are doing an exponential increase.

On a second phase, you probably need to do a "half" linear approach.

Imagine that the sample is between (B) and (C), now you make the proper measurements and divide the diference in half (d) and then half again (e)

The approach you are doing in Photoshop is interesting but In my opinion a bit usless, because, at the end it is a perceptive problem.

Take a look at this phenomenon:

https://en.wikipedia.org/wiki/Checker_shadow_illusion