Translating a specific colour(-code) to a 0-->1 number: Colour Toning -> L*a*b blending

To me, @age is right.

But to get the right number you have to know both:

  • the color space those patches refer to
  • the working profile you are using

Bear in mind that when using the Color Toning tool and adjusting by hand those numbers, both color spaces must be the same.

Your best bet would be following these steps:

  1. check the working profile you will be using in your image (you can’t change it from the moment you use the Color Toning tool onwards), and make sure it’s the same as the one the color patch is encoded with
  2. open the Gimp, create a selection or draw a square, open the foreground color selection dialog and enter the hexadecimal number there. Click Ok. Paint the square/selection with the new color.
  3. with the Color picker, control-click in one of the rulers and drag into the colored square. Then in the Sample points dialog, choose HSV. The value you need is the Hue (H), including decimals. Divide it by 360. Copy the result.
  4. go to RT: use or create a control point and in the Output (O) field, paste the calculated value (note the color is not an input, but an output color, that is, the color that will be added on top of your image).
  5. done

Now a couple tricky points:

  • make sure about which color space those hex patches refer to (usually they will refer to sRGB)
  • if you need to convert a color from one color space to another (sRGB in the hex patch, to ProPhoto in your working profile), do it in the Gimp, between points 2 and 3 (paint in the same color space of the reference patch, and after that convert to the working profile color space). By default the Gimp should create new images in sRGB color space, but check it beforehand, just in case.

I really haven’t checked it thoroughly with that exact toning method, but it should work.

Hope it helps

EDIT: I’ve changed the color picker dialog with the color samples dialog, because it seems the color picker only shows sRGB values, no matter which color space the image is in.

1 Like