diff options
Diffstat (limited to 'source/blender/blenlib/intern/math_color.c')
-rw-r--r-- | source/blender/blenlib/intern/math_color.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/blenlib/intern/math_color.c b/source/blender/blenlib/intern/math_color.c index bdcf52ec521..9058ef43604 100644 --- a/source/blender/blenlib/intern/math_color.c +++ b/source/blender/blenlib/intern/math_color.c @@ -368,9 +368,9 @@ unsigned int rgb_to_cpack(float r, float g, float b) void cpack_to_rgb(unsigned int col, float *r_r, float *r_g, float *r_b) { - *r_r = ((float)(((col)) & 0xFF)) * (1.0f / 255.0f); - *r_g = ((float)(((col) >> 8) & 0xFF)) * (1.0f / 255.0f); - *r_b = ((float)(((col) >> 16) & 0xFF)) * (1.0f / 255.0f); + *r_r = ((float)(col & 0xFF)) * (1.0f / 255.0f); + *r_g = ((float)((col >> 8) & 0xFF)) * (1.0f / 255.0f); + *r_b = ((float)((col >> 16) & 0xFF)) * (1.0f / 255.0f); } void rgb_uchar_to_float(float r_col[3], const unsigned char col_ub[3]) |