Fix #31164: constructive modifier followed by subsurf modifier did not show
face smoothing flags correctly. In fact it would do an invalid memory access, using the -1 original index.
This commit is contained in:
@@ -3134,8 +3134,6 @@ static CCGDerivedMesh *getCCGDerivedMesh(CCGSubSurf *ss,
|
||||
float *w2;
|
||||
int s, x, y;
|
||||
|
||||
origIndex = base_polyOrigIndex ? base_polyOrigIndex[origIndex] : origIndex;
|
||||
|
||||
w = get_ss_weights(&wtable, gridCuts, numVerts);
|
||||
|
||||
ccgdm->faceMap[index].startVert = vertNum;
|
||||
@@ -3146,6 +3144,8 @@ static CCGDerivedMesh *getCCGDerivedMesh(CCGSubSurf *ss,
|
||||
faceFlags->mat_nr = mpoly ? mpoly[origIndex].mat_nr : 0;
|
||||
faceFlags++;
|
||||
|
||||
origIndex = base_polyOrigIndex ? base_polyOrigIndex[origIndex] : origIndex;
|
||||
|
||||
/* set the face base vert */
|
||||
*((int *)ccgSubSurf_getFaceUserData(ss, f)) = vertNum;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user