void GridIn<dim>::read_ucd (istream &in)
{
Assert (tria != 0, ExcNoTriangulationSelected());
- Assert ((1<=dim) && (dim<=2), ExcNotImplemented());
-
AssertThrow (in, ExcIO());
// skip comments at start of file
in >> cell_type;
if (((cell_type == "line") && (dim == 1)) ||
- ((cell_type == "quad") && (dim == 2)))
+ ((cell_type == "quad") && (dim == 2)) ||
+ ((cell_type == "hex" ) && (dim == 3)))
// found a cell
{
// allocate and read indices
AssertThrow (in, ExcIO());
- // do some clean-up on vertices
+ // do some clean-up on vertices...
delete_unused_vertices (vertices, cells, subcelldata);
+ // ... and cells
+ GridReordering<dim>::reorder_cells (cells);
tria->create_triangulation (vertices, cells, subcelldata);
};
AssertThrow (in, ExcIO());
- // do some clean-up on vertices
+ // do some clean-up on vertices...
delete_unused_vertices (vertices, cells, subcelldata);
-
- ofstream x1("x1");
- debug_output_grid (cells, vertices, x1);
+ // ...and cells
GridReordering<dim>::reorder_cells (cells);
- ofstream x2("x2");
- debug_output_grid (cells, vertices, x2);
tria->create_triangulation (vertices, cells, subcelldata);
};