Skip to content
Snippets Groups Projects
Commit 3ead28ed authored by mattijs's avatar mattijs
Browse files

ENH: moveDynamicMesh: add -overwrite option. Fixes #1233.

parent c404b910
Branches
Tags
No related merge requests found
...@@ -162,6 +162,7 @@ int main(int argc, char *argv[]) ...@@ -162,6 +162,7 @@ int main(int argc, char *argv[])
"Mesh motion and topological mesh changes utility" "Mesh motion and topological mesh changes utility"
); );
#include "addOverwriteOption.H"
#include "addRegionOption.H" #include "addRegionOption.H"
argList::addBoolOption argList::addBoolOption
( (
...@@ -180,6 +181,10 @@ int main(int argc, char *argv[]) ...@@ -180,6 +181,10 @@ int main(int argc, char *argv[])
Info<< "Writing VTK files with weights of AMI patches." << nl << endl; Info<< "Writing VTK files with weights of AMI patches." << nl << endl;
} }
const bool overwrite = args.found("overwrite");
const word oldInstance = mesh.pointsInstance();
pimpleControl pimple(mesh); pimpleControl pimple(mesh);
bool moveMeshOuterCorrectors bool moveMeshOuterCorrectors
...@@ -199,6 +204,15 @@ int main(int argc, char *argv[]) ...@@ -199,6 +204,15 @@ int main(int argc, char *argv[])
} }
} }
if (overwrite)
{
mesh.setInstance(oldInstance);
runTime.write();
runTime.printExecutionTime(Info);
break;
}
mesh.checkMesh(true); mesh.checkMesh(true);
if (checkAMI) if (checkAMI)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment