diff options
author | Mike Erwin <significant.bit@gmail.com> | 2017-01-16 03:26:35 +0300 |
---|---|---|
committer | Mike Erwin <significant.bit@gmail.com> | 2017-01-16 03:30:05 +0300 |
commit | 4e2c6ad8eeefcefe2683e4949cec47fd383b1a5f (patch) | |
tree | d223c1c1a61b115dc94e10cd2baae65ae51c915b /source/blender/gpu | |
parent | 7eb4c850d382b02fa2eea349ab6718ebbcd4b768 (diff) |
Updating outliner_draw_struct_marks to retained mode
Had to add a few utility functions to replace existing functions. Let me know if these are duplicates.
Reviewers: merwin
Reviewed By: merwin
Tags: #bf_blender_2.8
Maniphest Tasks: T49043
Differential Revision: https://developer.blender.org/D2434
Diffstat (limited to 'source/blender/gpu')
-rw-r--r-- | source/blender/gpu/GPU_immediate.h | 2 | ||||
-rw-r--r-- | source/blender/gpu/intern/gpu_immediate.c | 8 |
2 files changed, 10 insertions, 0 deletions
diff --git a/source/blender/gpu/GPU_immediate.h b/source/blender/gpu/GPU_immediate.h index f601d062d48..4a0840e22c0 100644 --- a/source/blender/gpu/GPU_immediate.h +++ b/source/blender/gpu/GPU_immediate.h @@ -46,3 +46,5 @@ void immUniformThemeColorShade(int color_id, int offset); void immUniformThemeColorShadeAlpha(int color_id, int color_offset, int alpha_offset); void immUniformThemeColorBlendShade(int color_id1, int color_id2, float fac, int offset); void immUniformThemeColorBlend(int color_id1, int color_id2, float fac); +void immThemeColorShadeAlpha(int colorid, int coloffset, int alphaoffset); + diff --git a/source/blender/gpu/intern/gpu_immediate.c b/source/blender/gpu/intern/gpu_immediate.c index 685c31dc3e0..5188ca4c0e2 100644 --- a/source/blender/gpu/intern/gpu_immediate.c +++ b/source/blender/gpu/intern/gpu_immediate.c @@ -28,6 +28,7 @@ #include "GPU_immediate.h" #include "GPU_matrix.h" #include "UI_resources.h" +#include "BLI_utildefines.h" #include "gpu_shader_private.h" @@ -71,3 +72,10 @@ void immUniformThemeColorBlend(int color_id1, int color_id2, float fac) UI_GetThemeColorBlend3ubv(color_id1, color_id2, fac, color); immUniformColor3ubv(color); } + +void immThemeColorShadeAlpha(int colorid, int coloffset, int alphaoffset) +{ + unsigned char col[4]; + UI_GetThemeColorShadeAlpha4ubv(colorid, coloffset, alphaoffset, col); + immUniformColor4ub(col[0], col[1], col[2], col[3]); +} |