diff options
author | Ton Roosendaal <ton@blender.org> | 2004-10-27 13:25:55 +0400 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2004-10-27 13:25:55 +0400 |
commit | 0512a1032c6bddafe956e63a019cc5f2baf3a534 (patch) | |
tree | d679823bd2e74ee9617a8a161591acf643c62f94 /source | |
parent | 9719dc63e224c6fafab4ef18eae134e175d45ae7 (diff) |
Bug #1686
Subsurf, optimal; the outline-selected-draw now uses a normal wireframe
(not optimal) giving a nicer outline.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/src/drawobject.c | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/source/blender/src/drawobject.c b/source/blender/src/drawobject.c index 9bdbfc7ef9c..7575cab1bf1 100644 --- a/source/blender/src/drawobject.c +++ b/source/blender/src/drawobject.c @@ -3853,7 +3853,23 @@ static void drawSolidSelect(Object *ob, ListBase *lb) glLineWidth(2.0); glDepthMask(0); - if(ob->type==OB_MESH) drawmeshwire(ob); + if(ob->type==OB_MESH) { + /* optimal draw gives ugly outline, so we temporally disable it */ + Mesh *me= ob->data; + DispList *dl= me->disp.first; + DispListMesh *dlm=NULL; + short flag= 0; + + if(dl && dl->mesh) { + dlm= dl->mesh; + flag= dlm->flag & ME_OPT_EDGES; + dlm->flag &= ~ME_OPT_EDGES; + } + + drawmeshwire(ob); + + if(dlm && flag) dlm->flag |= flag; + } else drawDispListwire(lb); glLineWidth(1.0); |