Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Fulop <Yam>2020-01-20 16:51:48 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2020-01-20 16:52:38 +0300
commit482f3c008be1ef7efe6d52fd3957a3f755bca170 (patch)
tree08d43675ad2d461050cef3176f39b7a5216b5d6a /source/blender/blenfont
parentb15073b9ee6bfed0c9c4c5433f503b63445b7d1c (diff)
Cleanup: use existing helper for float to uchar color conversion
Differential Revision: https://developer.blender.org/D6617
Diffstat (limited to 'source/blender/blenfont')
-rw-r--r--source/blender/blenfont/intern/blf.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/source/blender/blenfont/intern/blf.c b/source/blender/blenfont/intern/blf.c
index 10bb1bd3c9c..2b592c9e550 100644
--- a/source/blender/blenfont/intern/blf.c
+++ b/source/blender/blenfont/intern/blf.c
@@ -935,10 +935,7 @@ void blf_draw_buffer__start(FontBLF *font)
{
FontBufInfoBLF *buf_info = &font->buf_info;
- buf_info->col_char[0] = buf_info->col_init[0] * 255;
- buf_info->col_char[1] = buf_info->col_init[1] * 255;
- buf_info->col_char[2] = buf_info->col_init[2] * 255;
- buf_info->col_char[3] = buf_info->col_init[3] * 255;
+ rgba_float_to_uchar(buf_info->col_char, buf_info->col_init);
if (buf_info->display) {
copy_v4_v4(buf_info->col_float, buf_info->col_init);