diff options
author | Antony Riakiotakis <kalast@gmail.com> | 2015-01-28 15:03:42 +0300 |
---|---|---|
committer | Antony Riakiotakis <kalast@gmail.com> | 2015-01-28 15:03:42 +0300 |
commit | 7a6d757a3b802f91cbfb834abe7756a31af39e9a (patch) | |
tree | 185e397cbed0199a0a22e1c590995f8d00382c59 /source/blender/editors/space_view3d | |
parent | 1678cb9af291c86fda2c5d1b65e6dca7554e3886 (diff) |
Add theme option for cliping border
Diffstat (limited to 'source/blender/editors/space_view3d')
-rw-r--r-- | source/blender/editors/space_view3d/view3d_draw.c | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/source/blender/editors/space_view3d/view3d_draw.c b/source/blender/editors/space_view3d/view3d_draw.c index 88cabcc6763..b8107834782 100644 --- a/source/blender/editors/space_view3d/view3d_draw.c +++ b/source/blender/editors/space_view3d/view3d_draw.c @@ -162,15 +162,15 @@ static void view3d_draw_clipping(RegionView3D *rv3d) /* fill in zero alpha for rendering & re-projection [#31530] */ unsigned char col[4]; - UI_GetThemeColorShade3ubv(TH_BACK, -8, col); - col[3] = 0; + UI_GetThemeColor4ubv(TH_V3D_CLIPPING_BORDER, col); glColor4ubv(col); + glEnable(GL_BLEND); glEnableClientState(GL_VERTEX_ARRAY); glVertexPointer(3, GL_FLOAT, 0, bb->vec); glDrawElements(GL_QUADS, sizeof(clipping_index) / sizeof(unsigned int), GL_UNSIGNED_INT, clipping_index); glDisableClientState(GL_VERTEX_ARRAY); - + glDisable(GL_BLEND); } } @@ -3089,15 +3089,6 @@ void ED_view3d_draw_offscreen(Scene *scene, View3D *v3d, ARegion *ar, int winx, G.f &= ~G_RENDER_OGL; } -/* get a color used for offscreen sky, returns color in sRGB space */ -void ED_view3d_offscreen_sky_color_get(Scene *scene, float sky_color[3]) -{ - if (scene->world) - linearrgb_to_srgb_v3_v3(sky_color, &scene->world->horr); - else - UI_GetThemeColor3fv(TH_BACK, sky_color); -} - /* utility func for ED_view3d_draw_offscreen */ ImBuf *ED_view3d_draw_offscreen_imbuf(Scene *scene, View3D *v3d, ARegion *ar, int sizex, int sizey, unsigned int flag, bool draw_background, int alpha_mode, char err_out[256]) |