Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/editors/mesh/mesh_navmesh.c')
-rw-r--r--source/blender/editors/mesh/mesh_navmesh.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/source/blender/editors/mesh/mesh_navmesh.c b/source/blender/editors/mesh/mesh_navmesh.c
index 83a1261e981..21564d2d348 100644
--- a/source/blender/editors/mesh/mesh_navmesh.c
+++ b/source/blender/editors/mesh/mesh_navmesh.c
@@ -375,7 +375,7 @@ static Object *createRepresentation(bContext *C, struct recast_polyMesh *pmesh,
BM_vert_create(em->bm, co, NULL, 0);
}
- EDBM_index_arrays_init(em, 1, 0, 0);
+ EDBM_index_arrays_ensure(em, BM_VERT);
/* create faces */
for (j = 0; j < trinum; j++) {
@@ -399,8 +399,6 @@ static Object *createRepresentation(bContext *C, struct recast_polyMesh *pmesh,
polygonIdx = (int *)CustomData_bmesh_get(&em->bm->pdata, newFace->head.data, CD_RECAST);
*polygonIdx = i + 1; /* add 1 to avoid zero idx */
}
-
- EDBM_index_arrays_free(em);
}
recast_destroyPolyMesh(pmesh);