Hue Preserving Color Blending
|
Functions used in the shader. More...
Go to the source code of this file.
Functions | |
float3 | RGBtoHSV (float3 c) |
float3 | HSVtoRGB (float3 c) |
float3 | oppositeColor (float3 color1, float3 color2) |
bool | equalHue (float3 color1, float3 color2) |
Checking if the difference between two hues is less than threshold 0.05. | |
float3 | huePreservingColorAdd (float3 color1, float3 color2) |
Hue preserving blending function from paper. | |
Functions used in the shader.
Definition in file functions.cginc.
float3 HSVtoRGB | ( | float3 | c | ) |
transforming back to RGB HSV Ranges are all in [0, 1] from http://lolengine.net/blog/2013/07/27/rgb-to-hsv-in-glsl
Definition at line 22 of file functions.cginc.
float3 oppositeColor | ( | float3 | color1, |
float3 | color2 | ||
) |
takes opposite color of color1 (rotating hue 180deg), while maintaining saturation and value from color2 colors all in rgb
Definition at line 31 of file functions.cginc.
float3 RGBtoHSV | ( | float3 | c | ) |
transforming to hsv to be able to fetch hue from http://lolengine.net/blog/2013/07/27/rgb-to-hsv-in-glsl HSV Ranges are all in [0, 1]
Definition at line 8 of file functions.cginc.