mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: change location of static ensight geometry (#2079)
Historically the "geometry" for static meshes was placed under
directly in the EnSight case directory.
Eg,
ensight/ensight.case
ensight/geometry
ensight/data/000001
ensight/data/000002 ...
This generally works ok, but relocating it to a constant data directory
Eg
ensight/ensight.case
ensight/data/constant/geometry
ensight/data/000001
ensight/data/000002 ...
Improves handling and avoids potential collisions when adding in
additional mesh regions
This commit is contained in:
@ -5,7 +5,7 @@
|
||||
\\ / A nd | www.openfoam.com
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
Copyright (C) 2016-2020 OpenCFD Ltd.
|
||||
Copyright (C) 2016-2021 OpenCFD Ltd.
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM.
|
||||
@ -522,10 +522,10 @@ void Foam::ensightCase::write() const
|
||||
|
||||
if (staticGeom)
|
||||
{
|
||||
// Steady
|
||||
// Static mesh: store under data/constant/geometry
|
||||
*os_
|
||||
<< setw(16) << "model:"
|
||||
<< geometryName
|
||||
<< (dataDirName/word("constant")/geometryName).c_str()
|
||||
<< nl;
|
||||
}
|
||||
else if (meshIndex >= 0)
|
||||
@ -681,13 +681,13 @@ Foam::ensightCase::newGeometry
|
||||
{
|
||||
// Moving mesh: write as "data/********/geometry"
|
||||
path = dataDir()/padded(timeIndex_);
|
||||
mkDir(path);
|
||||
}
|
||||
else
|
||||
{
|
||||
// Static mesh: write as "geometry"
|
||||
path = ensightDir_;
|
||||
// Static mesh: write as "data/constant/geometry"
|
||||
path = dataDir()/word("constant");
|
||||
}
|
||||
mkDir(path);
|
||||
|
||||
noteGeometry(moving); // note for later use
|
||||
|
||||
|
||||
@ -74,10 +74,10 @@ public:
|
||||
|
||||
// Public Data
|
||||
|
||||
//- The name for "data" subdirectory
|
||||
//- The name for data subdirectory: "data"
|
||||
static const char* dataDirName;
|
||||
|
||||
//- The name for geometry files
|
||||
//- The name for geometry files: "geometry"
|
||||
static const char* geometryName;
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user