mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
ENH: blockMesh enhancements
- support non-uniform scaling, prescaling and cartesian coordinate
transformations.
Eg, stretch in one direction and then rotate
```
prescale (1.5 1 1);
transform
{
origin (0 0 0);
rotation
{
type axisAngle;
axis (0 0 1);
angle 45;
}
}
```
- support "transformed" versions of blockMesh vertices, topology.
With the additional of transformations etc, a simplistic application
of a single scale parameter is no longer sufficient.
new: blMesh.vertices(true);
old: blMesh.vertices() * blMesh.scaleFactor();
new: blMesh.topology(true);
old: N/A
- add individual edge access for blockDescriptor.
Saves copying and duplicate calculations.
- handle '(block face)' specification for curved faces,
which is ok for external block faces, but likely somewhat
questionable if used for internal block faces.
This commit is contained in:
@ -5,7 +5,7 @@
|
||||
\\ / A nd | www.openfoam.com
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
Copyright (C) 2020 OpenCFD Ltd.
|
||||
Copyright (C) 2020-2021 OpenCFD Ltd.
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM, distributed under GPL-3.0-or-later.
|
||||
@ -16,7 +16,8 @@ Description
|
||||
\*---------------------------------------------------------------------------*/
|
||||
|
||||
{
|
||||
const polyMesh& topoMesh = blocks.topology();
|
||||
refPtr<polyMesh> topoMeshPtr(blocks.topology(true));
|
||||
const polyMesh& topoMesh = topoMeshPtr();
|
||||
|
||||
// Write mesh as edges
|
||||
{
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
\\ / A nd | www.openfoam.com
|
||||
\\/ M anipulation |
|
||||
-------------------------------------------------------------------------------
|
||||
Copyright (C) 2020 OpenCFD Ltd.
|
||||
Copyright (C) 2020-2021 OpenCFD Ltd.
|
||||
-------------------------------------------------------------------------------
|
||||
License
|
||||
This file is part of OpenFOAM, distributed under GPL-3.0-or-later.
|
||||
@ -19,7 +19,9 @@ Description
|
||||
// Non-legacy and ASCII (mesh is small, want readable output)
|
||||
const vtk::outputOptions writeOpts = vtk::formatType::INLINE_ASCII;
|
||||
|
||||
const polyMesh& topoMesh = blocks.topology();
|
||||
refPtr<polyMesh> topoMeshPtr(blocks.topology(true));
|
||||
const polyMesh& topoMesh = topoMeshPtr();
|
||||
|
||||
const vtk::vtuCells topoCells(topoMesh, writeOpts);
|
||||
|
||||
vtk::internalMeshWriter writer
|
||||
|
||||
Reference in New Issue
Block a user