diff --git a/source/blender/blenkernel/intern/subsurf_ccg.c b/source/blender/blenkernel/intern/subsurf_ccg.c index 12d7409..5607170 100644 --- a/source/blender/blenkernel/intern/subsurf_ccg.c +++ b/source/blender/blenkernel/intern/subsurf_ccg.c @@ -1436,7 +1436,8 @@ static void ccgdm_getVertCos(DerivedMesh *dm, float (*cos)[3]) CCGEdge **edgeMap2; CCGVert **vertMap2; int index, totvert, totedge, totface; - + + BLI_lock_thread(LOCK_CUSTOM1); totvert = ccgSubSurf_getNumVerts(ss); vertMap2 = MEM_mallocN(totvert * sizeof(*vertMap2), "vertmap"); for (vi = ccgSubSurf_getVertIterator(ss); !ccgVertIterator_isStopped(vi); ccgVertIterator_next(vi)) { @@ -1464,6 +1465,8 @@ static void ccgdm_getVertCos(DerivedMesh *dm, float (*cos)[3]) } ccgFaceIterator_free(fi); + BLI_unlock_thread(LOCK_CUSTOM1); + i = 0; for (index = 0; index < totface; index++) { CCGFace *f = faceMap2[index];