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:
authorMike Erwin <significant.bit@gmail.com>2016-10-07 21:56:08 +0300
committerMike Erwin <significant.bit@gmail.com>2016-10-07 22:03:21 +0300
commitb613d25354cbf7743836e9b1c07f8c503c0a5695 (patch)
treeb4349432228d16946236ede1393478cd9f73f0af /source/blender/editors/interface/interface_widgets.c
parent5c23b863f8c62e88406911aa90682fba8d434c16 (diff)
Blender 2.8: OpenGL: replace old GL with the new immediate API in UI_draw_roundbox_gl_mode
I change UI_draw_roundbox_gl_mode to use immediate API. The rest of the change is the call to the function. I also make some change in UI_ThemeColor4(int colorid) for eg to make convenience to use. I would really like to know if it's the good way to do, if yes I will make all the change in the node_daw.c after, else say me what's wrong and how to deal with color else. Reviewers: merwin, dfelinto, Severin Reviewed By: merwin Subscribers: fablefox, Severin Tags: #bf_blender_2.8, #opengl_gfx Maniphest Tasks: T49043 Differential Revision: https://developer.blender.org/D2274
Diffstat (limited to 'source/blender/editors/interface/interface_widgets.c')
-rw-r--r--source/blender/editors/interface/interface_widgets.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/source/blender/editors/interface/interface_widgets.c b/source/blender/editors/interface/interface_widgets.c
index 321d4b3e1f5..62e676d2a6a 100644
--- a/source/blender/editors/interface/interface_widgets.c
+++ b/source/blender/editors/interface/interface_widgets.c
@@ -218,16 +218,15 @@ void ui_draw_anti_roundbox(int mode, float minx, float miny, float maxx, float m
int j;
glEnable(GL_BLEND);
- glGetFloatv(GL_CURRENT_COLOR, color);
+ glGetFloatv(GL_CURRENT_COLOR, color); // I will make the change in a futur patch, use as it is for now
if (use_alpha) {
color[3] = 0.5f;
}
color[3] *= 0.125f;
- glColor4fv(color);
for (j = 0; j < WIDGET_AA_JITTER; j++) {
glTranslate2fv(jit[j]);
- UI_draw_roundbox_gl_mode(mode, minx, miny, maxx, maxy, rad);
+ UI_draw_roundbox_gl_mode(mode, minx, miny, maxx, maxy, rad, color);
glTranslatef(-jit[j][0], -jit[j][1], 0.0f);
}