7 const std::string& sub_type_str,
8 int cell_num_faces,
int cell_material_id,
9 const std::vector<std::vector<uint64_t>> &proxy_faces)
11 const std::string fname = __FUNCTION__;
17 throw std::logic_error(fname +
": Unsupported cell primary type.");
28 throw std::logic_error(fname +
": Unsupported cell secondary type.");
32 cell->material_id = cell_material_id;
35 std::set<uint64_t> cell_vertex_id_set;
36 for (
auto& proxy_face : proxy_faces)
37 for (uint64_t fvid : proxy_face)
38 cell_vertex_id_set.insert(fvid);
41 cell->vertex_ids.reserve(cell_vertex_id_set.size());
42 for (uint64_t cvid : cell_vertex_id_set)
43 cell->vertex_ids.push_back(cvid);
46 cell->faces.reserve(cell_num_faces);
47 for (
auto& proxy_face : proxy_faces)
48 cell->faces.emplace_back(proxy_face);
MeshAttributes attributes_
std::vector< LightWeightCell * > raw_cells_
void PushProxyCell(const std::string &type_str, const std::string &sub_type_str, int cell_num_faces, int cell_material_id, const std::vector< std::vector< uint64_t > > &proxy_faces)