mirror of
https://github.com/OPM/opm-simulators.git
synced 2025-02-14 04:43:27 -06:00
Use correct relative path names in pvd file.
This commit is contained in:
parent
b31f33f567
commit
c743d0a8c0
@ -35,6 +35,8 @@
|
||||
#include <opm/models/io/baseoutputwriter.hh>
|
||||
#include <opm/models/parallel/tasklets.hh>
|
||||
|
||||
#include <opm/common/utility/FileSystem.hpp>
|
||||
|
||||
#include <opm/material/common/Valgrind.hpp>
|
||||
#include <opm/material/common/Unused.hpp>
|
||||
|
||||
@ -85,9 +87,12 @@ class VtkMultiWriter : public BaseOutputWriter
|
||||
|
||||
// determine name to write into the multi-file for the
|
||||
// current time step
|
||||
// The file names in the pvd file are relative, the path should therefore be stripped.
|
||||
const Opm::filesystem::path fullPath{fileName};
|
||||
const std::string localFileName = fullPath.filename();
|
||||
multiWriter_.multiFile_.precision(16);
|
||||
multiWriter_.multiFile_ << " <DataSet timestep=\"" << multiWriter_.curTime_ << "\" file=\""
|
||||
<< fileName << "\"/>\n";
|
||||
<< localFileName << "\"/>\n";
|
||||
}
|
||||
|
||||
private:
|
||||
|
Loading…
Reference in New Issue
Block a user