Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/interface/interface_widgets.c
| Context not available. | |||||
| unsigned char *col_pt = col_array; | unsigned char *col_pt = col_array; | ||||
| shadecolors4(col1, col2, wcol->inner, wcol->shadetop, wcol->shadedown); | shadecolors4(col1, col2, wcol->inner, wcol->shadetop, wcol->shadedown); | ||||
| glShadeModel(GL_SMOOTH); | |||||
| for (a = 0; a < wtb->totvert; a++, col_pt += 4) { | for (a = 0; a < wtb->totvert; a++, col_pt += 4) { | ||||
| round_box_shade_col4_r(col_pt, col1, col2, wtb->inner_uv[a][wtb->draw_shadedir ? 1 : 0]); | round_box_shade_col4_r(col_pt, col1, col2, wtb->inner_uv[a][wtb->draw_shadedir ? 1 : 0]); | ||||
| } | } | ||||
| Context not available. | |||||
| glDrawArrays(GL_POLYGON, 0, wtb->totvert); | glDrawArrays(GL_POLYGON, 0, wtb->totvert); | ||||
| glDisableClientState(GL_VERTEX_ARRAY); | glDisableClientState(GL_VERTEX_ARRAY); | ||||
| glDisableClientState(GL_COLOR_ARRAY); | glDisableClientState(GL_COLOR_ARRAY); | ||||
| glShadeModel(GL_FLAT); | |||||
| } | } | ||||
| } | } | ||||
| Context not available. | |||||
| ui_color_picker_to_rgb(0.0f, 0.0f, hsv[2], colcent, colcent + 1, colcent + 2); | ui_color_picker_to_rgb(0.0f, 0.0f, hsv[2], colcent, colcent + 1, colcent + 2); | ||||
| glShadeModel(GL_SMOOTH); | |||||
| glBegin(GL_TRIANGLE_FAN); | glBegin(GL_TRIANGLE_FAN); | ||||
| glColor3fv(colcent); | glColor3fv(colcent); | ||||
| glVertex2f(centx, centy); | glVertex2f(centx, centy); | ||||
| Context not available. | |||||
| } | } | ||||
| glEnd(); | glEnd(); | ||||
| glShadeModel(GL_FLAT); | |||||
| /* fully rounded outline */ | /* fully rounded outline */ | ||||
| glPushMatrix(); | glPushMatrix(); | ||||
| glTranslatef(centx, centy, 0.0f); | glTranslatef(centx, centy, 0.0f); | ||||
| Context not available. | |||||
| float col1[4][3]; /* right half, rect bottom to top */ | float col1[4][3]; /* right half, rect bottom to top */ | ||||
| /* draw series of gouraud rects */ | /* draw series of gouraud rects */ | ||||
| glShadeModel(GL_SMOOTH); | |||||
| switch (type) { | switch (type) { | ||||
| case UI_GRAD_SV: | case UI_GRAD_SV: | ||||
| Context not available. | |||||
| } | } | ||||
| glEnd(); | glEnd(); | ||||
| } | } | ||||
| glShadeModel(GL_FLAT); | |||||
| } | } | ||||
| bool ui_but_is_colorpicker_display_space(uiBut *but) | bool ui_but_is_colorpicker_display_space(uiBut *but) | ||||
| Context not available. | |||||