Skip to content

Commit

Permalink
current filename for Unstructured/P4est (#1924)
Browse files Browse the repository at this point in the history
* current_filename

* fmt
  • Loading branch information
DanielDoehring authored Apr 29, 2024
1 parent 1ea9e3e commit 9a694b6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/meshes/mesh_io.jl
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,7 @@ function load_mesh_serial(mesh_file::AbstractString; n_cells_max, RealT)
mesh = UnstructuredMesh2D(mesh_filename; RealT = RealT,
periodicity = periodicity_,
unsaved_changes = false)
mesh.current_filename = mesh_file
elseif mesh_type == "P4estMesh"
p4est_filename, tree_node_coordinates,
nodes, boundary_names_ = h5open(mesh_file, "r") do file
Expand All @@ -317,7 +318,7 @@ function load_mesh_serial(mesh_file::AbstractString; n_cells_max, RealT)
p4est = load_p4est(p4est_file, Val(ndims))

mesh = P4estMesh{ndims}(p4est, tree_node_coordinates,
nodes, boundary_names, "", false, true)
nodes, boundary_names, mesh_file, false, true)
else
error("Unknown mesh type!")
end
Expand Down Expand Up @@ -405,7 +406,7 @@ function load_mesh_parallel(mesh_file::AbstractString; n_cells_max, RealT)
p4est = load_p4est(p4est_file, Val(ndims_))

mesh = P4estMesh{ndims_}(p4est, tree_node_coordinates,
nodes, boundary_names, "", false, true)
nodes, boundary_names, mesh_file, false, true)
else
error("Unknown mesh type!")
end
Expand Down

0 comments on commit 9a694b6

Please sign in to comment.