diff --git a/components/detournavigator/recastmesh.cpp b/components/detournavigator/recastmesh.cpp index 1a9982402b..00d6ae556a 100644 --- a/components/detournavigator/recastmesh.cpp +++ b/components/detournavigator/recastmesh.cpp @@ -19,5 +19,9 @@ namespace DetourNavigator + std::to_string(getTrianglesCount()) + ", areaTypes=" + std::to_string(mAreaTypes.size())); if (getVerticesCount()) rcCalcBounds(mVertices.data(), static_cast(getVerticesCount()), mBounds.mMin.ptr(), mBounds.mMax.ptr()); + mIndices.shrink_to_fit(); + mVertices.shrink_to_fit(); + mAreaTypes.shrink_to_fit(); + mWater.shrink_to_fit(); } }