Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
isp:vibrancy [2019/05/09 00:23] – [Implementation overview (HSL color space)] Igor Yefmov | isp:vibrancy [2019/05/09 00:24] – [Implementation overview (HSL color space)] Igor Yefmov | ||
---|---|---|---|
Line 86: | Line 86: | ||
As was described before the main idea of the Vibrancy is that the lowest saturated colors get the most relative boost in Saturation while highly saturated colors get progressively lower boost, up to a "no boost" for the 100% saturated colors. | As was described before the main idea of the Vibrancy is that the lowest saturated colors get the most relative boost in Saturation while highly saturated colors get progressively lower boost, up to a "no boost" for the 100% saturated colors. | ||
- | The boost multiplier therefore depends on the vibrancy factor and the pixel' | + | The scale (boost) multiplier therefore depends on the vibrancy factor and the pixel' |
\[ | \[ | ||
scale = 1 + \frac{100 - saturation}{100} * vibrancy \\ | scale = 1 + \frac{100 - saturation}{100} * vibrancy \\ | ||
Line 95: | Line 95: | ||
return 1. + (100 - _s) / 100. * _vib; | return 1. + (100 - _s) / 100. * _vib; | ||
}</ | }</ | ||
- | Once the boost value is calculated - just apply it to the pixels: | + | Once the scale (boost) value is calculated - just apply it to the pixels: |
<code c++>// pseudo-code | <code c++>// pseudo-code | ||
void vibrancy(/ | void vibrancy(/ |