mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
STYLE: use vtk::surfaceWriter instead of sampleSurface version
This commit is contained in:
@ -17,7 +17,6 @@ EXE_INC = \
|
||||
-I$(LIB_SRC)/fileFormats/lnInclude \
|
||||
-I$(LIB_SRC)/surfMesh/lnInclude \
|
||||
-I$(LIB_SRC)/meshTools/lnInclude \
|
||||
-I$(LIB_SRC)/sampling/lnInclude \
|
||||
-I$(LIB_SRC)/parallel/decompose/decompositionMethods/lnInclude \
|
||||
-I$(LIB_SRC)/parallel/decompose/decompose/lnInclude \
|
||||
-I$(LIB_SRC)/dynamicMesh/lnInclude \
|
||||
@ -27,7 +26,6 @@ EXE_INC = \
|
||||
LIB_LIBS = \
|
||||
${CGAL_LIBS} \
|
||||
-lmeshTools \
|
||||
-lsampling \
|
||||
-ldecompose \
|
||||
-ldynamicMesh \
|
||||
-lsnappyHexMesh
|
||||
|
||||
@ -26,7 +26,7 @@ License
|
||||
#include "automatic.H"
|
||||
#include "addToRunTimeSelectionTable.H"
|
||||
#include "triSurfaceMesh.H"
|
||||
#include "vtkSurfaceWriter.H"
|
||||
#include "foamVtkSurfaceWriter.H"
|
||||
#include "primitivePatchInterpolation.H"
|
||||
#include "Time.H"
|
||||
|
||||
@ -288,20 +288,23 @@ Foam::tmp<Foam::triSurfacePointScalarField> Foam::automatic::load()
|
||||
faces[fI] = surface_.triSurface::operator[](fI);
|
||||
}
|
||||
|
||||
vtkSurfaceWriter().write
|
||||
vtk::surfaceWriter vtkWriter
|
||||
(
|
||||
surface_.searchableSurface::time().constant()/"triSurface",
|
||||
surfaceName_.nameLessExt(),
|
||||
meshedSurfRef
|
||||
surface_.points(),
|
||||
faces,
|
||||
(
|
||||
surface_.points(),
|
||||
faces
|
||||
),
|
||||
"cellSize",
|
||||
pointCellSize,
|
||||
true,
|
||||
true
|
||||
surface_.searchableSurface::time().constant()
|
||||
/ "triSurface"
|
||||
/ surfaceName_.nameLessExt() + "_cellSize"
|
||||
)
|
||||
);
|
||||
|
||||
|
||||
vtkWriter.writeGeometry();
|
||||
|
||||
vtkWriter.beginPointData(1);
|
||||
|
||||
vtkWriter.write("cellSize", pointCellSize);
|
||||
}
|
||||
|
||||
return tPointCellSize;
|
||||
|
||||
@ -14,7 +14,6 @@ EXE_INC = \
|
||||
-I$(LIB_SRC)/fileFormats/lnInclude \
|
||||
-I$(LIB_SRC)/surfMesh/lnInclude \
|
||||
-I$(LIB_SRC)/meshTools/lnInclude \
|
||||
-I$(LIB_SRC)/sampling/lnInclude \
|
||||
-I$(LIB_SRC)/finiteVolume/lnInclude \
|
||||
-I$(LIB_SRC)/dynamicMesh/lnInclude \
|
||||
-I../vectorTools
|
||||
@ -25,6 +24,5 @@ EXE_LIBS = \
|
||||
-ldecompositionMethods /* -L$(FOAM_LIBBIN)/dummy -lscotchDecomp */ \
|
||||
-ldecompose \
|
||||
-lmeshTools \
|
||||
-lsampling \
|
||||
-ldynamicMesh \
|
||||
-lfiniteVolume
|
||||
|
||||
@ -41,7 +41,7 @@ Description
|
||||
#include "cellShape.H"
|
||||
#include "DynamicField.H"
|
||||
#include "isoSurfaceCell.H"
|
||||
#include "vtkSurfaceWriter.H"
|
||||
#include "foamVtkSurfaceWriter.H"
|
||||
#include "syncTools.H"
|
||||
#include "decompositionModel.H"
|
||||
|
||||
@ -739,14 +739,18 @@ int main(int argc, char *argv[])
|
||||
pointMergeMap
|
||||
);
|
||||
|
||||
vtkSurfaceWriter writer;
|
||||
writer.write
|
||||
(
|
||||
runTime.path(),
|
||||
"iso",
|
||||
mergedPoints,
|
||||
mergedFaces
|
||||
);
|
||||
if (Pstream::master())
|
||||
{
|
||||
vtk::surfaceWriter writer
|
||||
(
|
||||
mergedPoints,
|
||||
mergedFaces,
|
||||
(runTime.path() / "iso"),
|
||||
false // serial only
|
||||
);
|
||||
|
||||
writer.writeGeometry();
|
||||
}
|
||||
|
||||
Info<< "End\n" << endl;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user