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:24] – [Implementation overview (HSL color space)] Igor Yefmov | isp:vibrancy [2019/06/04 22:04] – [Implementation overview (HSL color space)] Igor Yefmov | ||
---|---|---|---|
Line 88: | Line 88: | ||
The scale (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-1) \\ |
vibrancy \in [0..1]\\ | vibrancy \in [0..1]\\ | ||
saturation \in [0..100]\% | saturation \in [0..100]\% | ||
\] | \] | ||
<code c++> | <code c++> | ||
- | return 1. + (100 - _s) / 100. * _vib; | + | return 1. + (100 - _s) / 100. * (_vib - 1); |
}</ | }</ | ||
Once the scale (boost) value is calculated - just apply it to the pixels: | Once the scale (boost) value is calculated - just apply it to the pixels: |