Skip to content

Commit

Permalink
loops over vol ref_cell
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike Park authored and Mike Park committed Apr 23, 2021
1 parent 5529b53 commit 00fab9c
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions src/ref_subcommand.c
Expand Up @@ -662,6 +662,7 @@ static REF_STATUS fossilize(REF_GRID ref_grid, const char *fossil_filename,
REF_GLOB global;
char filename[1024];
REF_INT self_intersections;
REF_INT group, cell_node;

if (ref_mpi_para(ref_mpi)) {
if (ref_mpi_once(ref_mpi)) printf("part %s\n", fossil_filename);
Expand Down Expand Up @@ -767,14 +768,14 @@ static REF_STATUS fossilize(REF_GRID ref_grid, const char *fossil_filename,
}
}

fossil_cell = ref_grid_tet(fossil_grid);
ref_cell = ref_grid_tet(ref_grid);
each_ref_cell_valid_cell_with_nodes(fossil_cell, cell, nodes) {
nodes[0] = f2g[nodes[0]];
nodes[1] = f2g[nodes[1]];
nodes[2] = f2g[nodes[2]];
nodes[3] = f2g[nodes[3]];
RSS(ref_cell_add(ref_cell, nodes, &new_cell), "insert tri");
each_ref_grid_3d_ref_cell(ref_grid, group, ref_cell) {
fossil_cell = ref_grid_cell(fossil_grid, group);
each_ref_cell_valid_cell_with_nodes(fossil_cell, cell, nodes) {
each_ref_cell_cell_node(ref_cell, cell_node) {
nodes[cell_node] = f2g[nodes[cell_node]];
}
RSS(ref_cell_add(ref_cell, nodes, &new_cell), "insert vol cell");
}
}

sprintf(filename, "%s-vol.plt", project);
Expand Down

0 comments on commit 00fab9c

Please sign in to comment.