forked from bartvdbraak/blender
clear the FGON edge flag when updating old meshes to polygons. (we may wan't to reuse the flag later)
This commit is contained in:
parent
a1b9608ddd
commit
e26ef899c3
@ -2061,8 +2061,11 @@ void BKE_mesh_convert_mfaces_to_mpolys(Mesh *mesh)
|
||||
|
||||
/*build edge hash*/
|
||||
me = mesh->medge;
|
||||
for (i=0; i<mesh->totedge; i++, me++) {
|
||||
for (i = 0; i < mesh->totedge; i++, me++) {
|
||||
BLI_edgehash_insert(eh, me->v1, me->v2, SET_INT_IN_POINTER(i));
|
||||
|
||||
/* unrelated but avoid having the FGON flag enabled, so we can reuse it later for something else */
|
||||
me->flag &= ~ME_FGON;
|
||||
}
|
||||
|
||||
j = 0; /*current loop index*/
|
||||
@ -2077,7 +2080,7 @@ void BKE_mesh_convert_mfaces_to_mpolys(Mesh *mesh)
|
||||
mp->mat_nr = mf->mat_nr;
|
||||
mp->flag = mf->flag;
|
||||
|
||||
#define ML(v1, v2) {ml->v = mf->v1; ml->e = GET_INT_FROM_POINTER(BLI_edgehash_lookup(eh, mf->v1, mf->v2)); ml++; j++;}
|
||||
# define ML(v1, v2) {ml->v = mf->v1; ml->e = GET_INT_FROM_POINTER(BLI_edgehash_lookup(eh, mf->v1, mf->v2)); ml++; j++;}
|
||||
|
||||
ML(v1, v2);
|
||||
ML(v2, v3);
|
||||
@ -2089,7 +2092,7 @@ void BKE_mesh_convert_mfaces_to_mpolys(Mesh *mesh)
|
||||
ML(v3, v1);
|
||||
}
|
||||
|
||||
#undef ML
|
||||
# undef ML
|
||||
|
||||
bm_corners_to_loops(mesh, i, mp->loopstart, numTex, numCol);
|
||||
}
|
||||
|
@ -257,7 +257,7 @@ typedef struct MRecast {
|
||||
/* medge->flag (1=SELECT)*/
|
||||
#define ME_EDGEDRAW (1<<1)
|
||||
#define ME_SEAM (1<<2)
|
||||
/* #define ME_FGON (1<<3) */ /* no longer used (now we have ngons) */
|
||||
#define ME_FGON (1<<3) /* no longer used (now we have ngons), only defined so we can clear it */
|
||||
/* reserve 16 for ME_HIDE */
|
||||
#define ME_EDGERENDER (1<<5)
|
||||
#define ME_LOOSEEDGE (1<<7)
|
||||
|
Loading…
Reference in New Issue
Block a user