[Bf-blender-cvs] [4eefba0] master: Fix 'hard crash' part of T45768 (when merging all vertices of a mesh, we have no more edges to draw).

Bastien Montagne noreply at git.blender.org
Wed Aug 12 11:43:35 CEST 2015


Commit: 4eefba091dfe8c7228c657d83ba1ae3fc62fd2b4
Author: Bastien Montagne
Date:   Wed Aug 12 11:42:35 2015 +0200
Branches: master
https://developer.blender.org/rB4eefba091dfe8c7228c657d83ba1ae3fc62fd2b4

Fix 'hard crash' part of T45768 (when merging all vertices of a mesh, we have no more edges to draw).

===================================================================

M	source/blender/blenkernel/intern/subsurf_ccg.c

===================================================================

diff --git a/source/blender/blenkernel/intern/subsurf_ccg.c b/source/blender/blenkernel/intern/subsurf_ccg.c
index 02a7f6c..69483a4 100644
--- a/source/blender/blenkernel/intern/subsurf_ccg.c
+++ b/source/blender/blenkernel/intern/subsurf_ccg.c
@@ -1834,7 +1834,7 @@ static void ccgDM_drawEdges(DerivedMesh *dm, bool drawLooseEdges, bool drawAllEd
 		}
 	}
 
-	if (ccgdm->drawInteriorEdges) {
+	if (gdo->edges && ccgdm->drawInteriorEdges) {
 		GPU_buffer_draw_elements(gdo->edges, GL_LINES, gdo->interior_offset * 2, gdo->totinterior * 2);
 	}
 	GPU_buffers_unbind();




More information about the Bf-blender-cvs mailing list