writeMesh.C
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030 #include "sammMesh.H"
00031 #include "Time.H"
00032 #include "polyMesh.H"
00033
00034
00035
00036 void sammMesh::writeMesh()
00037 {
00038 if (isShapeMesh_)
00039 {
00040 Info << "This is a shapeMesh." << endl;
00041
00042 polyMesh pShapeMesh
00043 (
00044 IOobject
00045 (
00046 polyMesh::defaultRegion,
00047 runTime_.constant(),
00048 runTime_
00049 ),
00050 xferCopy(points_),
00051 cellShapes_,
00052 boundary_,
00053 patchNames_,
00054 patchTypes_,
00055 defaultFacesName_,
00056 defaultFacesType_,
00057 patchPhysicalTypes_
00058 );
00059
00060 Info << "Writing polyMesh" << endl;
00061 pShapeMesh.write();
00062 }
00063 else
00064 {
00065
00066
00067 createPolyMeshData();
00068
00069 Info << "This is a polyMesh" << endl;
00070
00071 polyMesh pMesh
00072 (
00073 IOobject
00074 (
00075 polyMesh::defaultRegion,
00076 runTime_.constant(),
00077 runTime_
00078 ),
00079 xferCopy(points_),
00080 xferCopy(meshFaces_),
00081 xferCopy(cellPolys_)
00082 );
00083
00084 pMesh.addPatches(polyBoundaryPatches(pMesh));
00085
00086 Info << "Writing polyMesh" << endl;
00087 pMesh.write();
00088 }
00089 }
00090
00091
00092
Copyright © 2000-2009 OpenCFD Ltd