| 7 | using namespace FEMeshFactory; |
| 8 | |
| 9 | FEMeshPtr FEMeshFactory::adapt(MeshPtr mesh) { |
| 10 | const size_t dim = mesh->get_dim(); |
| 11 | const size_t num_voxels = mesh->get_num_voxels(); |
| 12 | if (dim == 2) { |
| 13 | return FEMeshPtr(new TriangleMesh(mesh)); |
| 14 | } else if (dim == 3 && num_voxels == 0) { |
| 15 | return FEMeshPtr(new TriangleMesh(mesh)); |
| 16 | } else { |
| 17 | return FEMeshPtr(new TetrahedronMesh(mesh)); |
| 18 | } |
| 19 | } |
nothing calls this directly
no test coverage detected