Bug fix #2575
authorTon Roosendaal <ton@blender.org>
Thu, 26 May 2005 21:00:50 +0000 (21:00 +0000)
committerTon Roosendaal <ton@blender.org>
Thu, 26 May 2005 21:00:50 +0000 (21:00 +0000)
VertexPaint, FaceSelect draws with 'culled faces' but should therefor
check for negative scaling as well, set the glFrontFace() OK.

source/blender/src/drawobject.c

index dfb955397b37b4a695b75dee1246b7ebbfeb8e61..6ed33a42ef0592172f1bd55d34fe631d91822330 100644 (file)
@@ -1736,6 +1736,8 @@ static void draw_mesh_fancy(Object *ob, DerivedMesh *baseDM, DerivedMesh *realDM
        float *obExtVerts;
        DerivedMesh *dm = realDM?realDM:baseDM;
 
+       glFrontFace((ob->transflag&OB_NEG_SCALE)?GL_CW:GL_CCW);
+
        dl = find_displist(&ob->disp, DL_VERTS);
        obExtVerts = dl?dl->verts:NULL;