Fix T60157: Applying subdivide GP modifier gets wrong fill

The problem was the triangulation cache was not initializated.
This commit is contained in:
Antonio Vazquez 2019-01-04 17:18:03 +01:00
parent 808510325e
commit 0d736d6896
Notes: blender-bot 2023-02-14 08:10:10 +01:00
Referenced by issue #60157, Applying subdivide GP modifier gets wrong fill
1 changed files with 1 additions and 0 deletions

View File

@ -744,6 +744,7 @@ void BKE_gpencil_subdivide(bGPDstroke *gps, int level, int flag)
gps->dvert = MEM_recallocN(gps->dvert, sizeof(*gps->dvert) * gps->totpoints);
}
gps->flag |= GP_STROKE_RECALC_GEOMETRY;
gps->tot_triangles = 0;
/* move points from last to first to new place */
i2 = gps->totpoints - 1;