diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2017-02-20 23:21:04 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2017-02-20 23:21:47 +0300 |
commit | 4f2375b82f721cc8157bd91cd4ee5b56d6e98985 (patch) | |
tree | 02a23d0ff3c20b5ca01810dd03439e88e444a54e /source/blender/blenlib/BLI_math_color.h | |
parent | 5c39aad2838418146d1c61ae3d3304829f6d487c (diff) |
OpenGL immediate mode: interface_widgets.c
Added rgba_float_args_set_ch to BLI_math_color.h
Diffstat (limited to 'source/blender/blenlib/BLI_math_color.h')
-rw-r--r-- | source/blender/blenlib/BLI_math_color.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/blenlib/BLI_math_color.h b/source/blender/blenlib/BLI_math_color.h index c7abe6192f7..34fc52c12c0 100644 --- a/source/blender/blenlib/BLI_math_color.h +++ b/source/blender/blenlib/BLI_math_color.h @@ -141,6 +141,9 @@ MINLINE void float_to_byte_dither_v3(unsigned char b[3], const float f[3], float #define rgba_char_args_set_fl(col, r, g, b, a) \ rgba_char_args_set(col, (r) * 255, (g) * 255, (b) * 255, (a) * 255) +#define rgba_float_args_set_ch(col, r, g, b, a) \ + rgba_float_args_set(col, (r) / 255.0f, (g) / 255.0f, (b) / 255.0f, (a) / 255.0f) + MINLINE void rgba_char_args_set(char col[4], const char r, const char g, const char b, const char a); MINLINE void rgba_float_args_set(float col[4], const float r, const float g, const float b, const float a); MINLINE void rgba_char_args_test_set(char col[4], const char r, const char g, const char b, const char a); |