There’re a few ways to analyze an image. Few of them are CIE LUV, CIE LAB and converting them to HSI, HSV, HSL, etc. CIE LUV and CIE LAB are similar for the case of “L” which is responsible for Lightness of an image. A and B (U and V) are responsible for red/green opponent colors and yellow/blue opponent colors respectively. CIE LAB is more suitable for coloured surface and dyes. CIE LUV is more suitable for the characterization of colour displays. Here, we’ll be using HSI instead because our interest is by changing a specified range of Hue of an image in to another range.
HSV (hue-saturation-value), HSI (hue-saturation-intensity) and HSL (hue-saturation-lightness) are the three most common cylindrical-coordinate representations of points in an RGB color model.
We’ll be using HSI here. Below is the model representing HSI.
Intensity is self-explanatory, it represents the lightness and darkness of a pixel. We’re able to tweak the colour of an image based on the Hue of an image. Hue is represented in degrees thus we’re able to specify the range/angle of the portion of hue that we want to deal with. From the image below, we’re able to clearly identify the hue range of an image:
For intensity, it’s responsible for the depth of a colour. For instance, for a fixed hue, we’re able to change the “strength” of that particular hue based on its saturation.
Below shows an input image ready to be scanned and modified:
My main goal is to provide a dusk feeling to that image, thus we’ve to specify the hue range that we want to work on. The range of hue is based mainly on the hue chart given above. Our main focus here will be on the sky and the grass. So we’ll have 2 colour in our mind, blue and green. We’ll add a bias on that two colour range.
We’ll need to provide a dull feeling as well, so we’ll make the colour of the sky a little dimmer by reducing its saturation.
The intensity is also reduced to provide a dull feel of the sky as well.
The results based on the manipulations given above is shown below:
I’ve also made a version where you can play around with the Hue, Saturation and Intensity of an image:
Source code of my implementation: Image Transformation