diff --git a/network_process/src/prim_gen/extract_mesh.cpp b/network_process/src/prim_gen/extract_mesh.cpp index 3425a51..37bf55f 100644 --- a/network_process/src/prim_gen/extract_mesh.cpp +++ b/network_process/src/prim_gen/extract_mesh.cpp @@ -195,7 +195,7 @@ void extract_iso_mesh(const std::array& tet_active_s const auto& face = faces[face_index]; face_verts.clear(); - for (unsigned long vId : face.vertices) { face_verts.emplace_back(iso_vId_of_vert[vId]); } + for (unsigned long vId : face.vertices) face_verts.emplace_back(iso_vId_of_vert[vId]); const face_header_t face_header{tet_index, face_index}; // face is on tet boundary if face.negative_cell is NONE uint32_t iso_face_index{static_cast(iso_faces.size())}; @@ -216,4 +216,8 @@ void extract_iso_mesh(const std::array& tet_active_s iso_faces[iso_face_index].headers.emplace_back(face_header); } } + + iso_pts.shrink_to_fit(); + iso_verts.shrink_to_fit(); + iso_faces.shrink_to_fit(); } \ No newline at end of file